You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Description
#5015 's version for beta
branch. @JessChowdhury
- [X] I have read and understand the
[CONTRIBUTING.md](https://github.com/payloadcms/payload/blob/main/CONTRIBUTING.md)
document in this repository.
## Type of change
<!-- Please delete options that are not relevant. -->
- [X] New feature (non-breaking change which adds functionality)
- [X] This change requires a documentation update
## Checklist:
- [X] I have added tests that prove my fix is effective or that my
feature works
- [X] Existing test suite passes locally with my changes
- [X] I have made corresponding changes to the documentation
Copy file name to clipboardExpand all lines: docs/fields/upload.mdx
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,6 +57,7 @@ export const MyUploadField: Field = {
57
57
|**`access`**| Provide Field Access Control to denote what users can see and do with this field's data. [More details](../access-control/fields). |
58
58
|**`hidden`**| Restrict this field's visibility from all APIs entirely. Will still be saved to the database, but will not appear in any API or the Admin Panel. |
59
59
|**`defaultValue`**| Provide data to be used for this field's default value. [More](/docs/fields/overview#default-values)|
60
+
|**`displayPreview`**| Enable displaying preview of the uploaded file. Overrides related Collection's `displayPreview` option. [More](/docs/upload/overview#collection-upload-options). |
60
61
|**`localized`**| Enable localization for this field. Requires [localization to be enabled](/docs/configuration/localization) in the Base config. |
61
62
|**`required`**| Require this field to have a value. |
Copy file name to clipboardExpand all lines: docs/upload/overview.mdx
+1Lines changed: 1 addition & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -94,6 +94,7 @@ _An asterisk denotes that an option is required._
94
94
|**`adminThumbnail`**| Set the way that the [Admin Panel](../admin/overview) will display thumbnails for this Collection. [More](#admin-thumbnails)|
95
95
|**`crop`**| Set to `false` to disable the cropping tool in the [Admin Panel](../admin/overview). Crop is enabled by default. [More](#crop-and-focal-point-selector)|
96
96
|**`disableLocalStorage`**| Completely disable uploading files to disk locally. [More](#disabling-local-upload-storage)|
97
+
|**`displayPreview`**| Enable displaying preview of the uploaded file in Upload fields related to this Collection. Can be locally overridden by `displayPreview` option in Upload field. [More](/docs/fields/upload#config-options). |
97
98
|**`externalFileHeaderFilter`**| Accepts existing headers and returns the headers after filtering or modifying. |
98
99
|**`filesRequiredOnCreate`**| Mandate file data on creation, default is true. |
99
100
|**`focalPoint`**| Set to `false` to disable the focal point selection tool in the [Admin Panel](../admin/overview). The focal point selector is only available when `imageSizes` or `resizeOptions` are defined. [More](#crop-and-focal-point-selector)|
0 commit comments