feat(16.2-01): translatable plugin fields, element uploads and save notices in the admin
- MLPluginField wraps PluginField in the MLField locale switcher; the
element gets the active content locale and that locale's string
- isMLField treats a translatable plugin field as a locale map in the form
state, FormView adopt and the relation child modal
- summer-upload posts the file with the admin session to the field upload
route and answers summer-upload-result {id, url} or {id, error}
- noticeLines shows meta.notices under each field as a warning status line
(text only) and in the saved toast; the stored value is reloaded
- docs/backend/field-types.md documents the full element contract;
modules/boardwalk/dist rebuilt
This commit is contained in:
@@ -98,5 +98,18 @@ export const WIDGET_RESULT_EVENT = 'summer-result'
|
||||
*/
|
||||
export const FIELD_CHANGE_EVENT = 'summer-change'
|
||||
|
||||
/**
|
||||
* Event a plugin field type's element dispatches (bubbling) to upload a file,
|
||||
* with detail {id, file}: the element's own request id and the File. The SPA
|
||||
* posts it with the admin session to the field upload route.
|
||||
*/
|
||||
export const FIELD_UPLOAD_EVENT = 'summer-upload'
|
||||
|
||||
/**
|
||||
* Event the SPA dispatches on the element when an upload ends, with detail
|
||||
* {id, url} on success or {id, error} with a message on failure.
|
||||
*/
|
||||
export const FIELD_UPLOAD_RESULT_EVENT = 'summer-upload-result'
|
||||
|
||||
/** How long a widget waits for its custom element to be defined. */
|
||||
export const WIDGET_TIMEOUT = 5000
|
||||
|
||||
Reference in New Issue
Block a user