Change record status: 
Project: 
Introduced in branch: 
12.1.x
Introduced in version: 
12.1.0
Description: 

File and image fields have a new field storage setting, uri_scheme_field. It is a boolean and defaults to FALSE.

When the setting is enabled, the file widget shows an Upload destination radios element for each file. Editors can choose any writable, visible stream wrapper, for example public or private. New uploads are stored in the selected scheme. When the entity is saved, an existing file is moved to the selected scheme. The path inside the scheme stays the same.

A post-update function adds uri_scheme_field: false to existing file and image field storages. Sites that ship field storage config should add this key to their YAML files:

settings:
  uri_scheme: public
  uri_scheme_field: false

The managed_file element has two new properties, #uri_scheme_field and #uri_scheme_default. FileWidget sets them. When both are set, new uploads use the uri_scheme value in the submitted input.

Impacts: 
Site builders, administrators, editors