@wordpress/editor 13.32.0 → 13.34.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/README.md +355 -20
- package/build/bindings/index.js.map +1 -1
- package/build/bindings/pattern-overrides.js.map +1 -1
- package/build/bindings/post-meta.js +12 -30
- package/build/bindings/post-meta.js.map +1 -1
- package/build/components/autocompleters/index.js.map +1 -1
- package/build/components/autocompleters/user.js.map +1 -1
- package/build/components/autosave-monitor/index.js +24 -11
- package/build/components/autosave-monitor/index.js.map +1 -1
- package/build/components/block-manager/category.js.map +1 -1
- package/build/components/block-manager/checklist.js.map +1 -1
- package/build/components/block-manager/index.js.map +1 -1
- package/build/components/block-removal-warnings/index.js.map +1 -1
- package/build/components/block-settings-menu/plugin-block-settings-menu-item.js.map +1 -1
- package/build/components/character-count/index.js +5 -0
- package/build/components/character-count/index.js.map +1 -1
- package/build/components/collapsible-block-toolbar/index.js +73 -0
- package/build/components/collapsible-block-toolbar/index.js.map +1 -0
- package/build/components/commands/index.js +19 -0
- package/build/components/commands/index.js.map +1 -1
- package/build/components/commands/index.native.js.map +1 -1
- package/build/components/deprecated.js.map +1 -1
- package/build/components/deprecated.native.js.map +1 -1
- package/build/components/document-bar/index.js.map +1 -1
- package/build/components/document-outline/check.js +8 -0
- package/build/components/document-outline/check.js.map +1 -1
- package/build/components/document-outline/index.js +11 -0
- package/build/components/document-outline/index.js.map +1 -1
- package/build/components/document-outline/item.js.map +1 -1
- package/build/components/document-tools/index.js +1 -8
- package/build/components/document-tools/index.js.map +1 -1
- package/build/components/editor-canvas/edit-template-blocks-notification.js +13 -2
- package/build/components/editor-canvas/edit-template-blocks-notification.js.map +1 -1
- package/build/components/editor-canvas/index.js +2 -2
- package/build/components/editor-canvas/index.js.map +1 -1
- package/build/components/editor-help/add-blocks.native.js.map +1 -1
- package/build/components/editor-help/customize-blocks.native.js.map +1 -1
- package/build/components/editor-help/help-detail-navigation-screen.native.js.map +1 -1
- package/build/components/editor-help/help-get-support-button.native.js.map +1 -1
- package/build/components/editor-help/help-section-title.native.js.map +1 -1
- package/build/components/editor-help/help-topic-row.native.js.map +1 -1
- package/build/components/editor-help/icon-move-blocks.native.js.map +1 -1
- package/build/components/editor-help/index.native.js.map +1 -1
- package/build/components/editor-help/intro-to-blocks.native.js.map +1 -1
- package/build/components/editor-help/move-blocks.native.js.map +1 -1
- package/build/components/editor-help/remove-blocks.native.js.map +1 -1
- package/build/components/editor-help/view-sections.native.js.map +1 -1
- package/build/components/editor-history/redo.js +11 -0
- package/build/components/editor-history/redo.js.map +1 -1
- package/build/components/editor-history/undo.js +11 -0
- package/build/components/editor-history/undo.js.map +1 -1
- package/build/components/editor-notices/index.js.map +1 -1
- package/build/components/editor-snackbars/index.js +6 -0
- package/build/components/editor-snackbars/index.js.map +1 -1
- package/build/components/entities-saved-states/entity-record-item.js.map +1 -1
- package/build/components/entities-saved-states/entity-type-list.js.map +1 -1
- package/build/components/entities-saved-states/hooks/use-is-dirty.js.map +1 -1
- package/build/components/entities-saved-states/index.js.map +1 -1
- package/build/components/error-boundary/index.js.map +1 -1
- package/build/components/error-boundary/index.native.js.map +1 -1
- package/build/components/global-keyboard-shortcuts/index.js +31 -0
- package/build/components/global-keyboard-shortcuts/index.js.map +1 -1
- package/build/components/global-keyboard-shortcuts/register-shortcuts.js +52 -0
- package/build/components/global-keyboard-shortcuts/register-shortcuts.js.map +1 -1
- package/build/components/index.js +33 -1
- package/build/components/index.js.map +1 -1
- package/build/components/index.native.js.map +1 -1
- package/build/components/inserter-sidebar/index.js +1 -4
- package/build/components/inserter-sidebar/index.js.map +1 -1
- package/build/components/keyboard-shortcut-help-modal/config.js +82 -0
- package/build/components/keyboard-shortcut-help-modal/config.js.map +1 -0
- package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +49 -0
- package/build/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +1 -0
- package/build/components/keyboard-shortcut-help-modal/index.js +126 -0
- package/build/components/keyboard-shortcut-help-modal/index.js.map +1 -0
- package/build/components/keyboard-shortcut-help-modal/shortcut.js +55 -0
- package/build/components/keyboard-shortcut-help-modal/shortcut.js.map +1 -0
- package/build/components/list-view-sidebar/index.js +1 -1
- package/build/components/list-view-sidebar/index.js.map +1 -1
- package/build/components/list-view-sidebar/list-view-outline.js.map +1 -1
- package/build/components/local-autosave-monitor/index.js.map +1 -1
- package/build/components/media-categories/index.js.map +1 -1
- package/build/components/mode-switcher/index.js.map +1 -1
- package/build/components/more-menu/copy-content-menu-item.js +59 -0
- package/build/components/more-menu/copy-content-menu-item.js.map +1 -0
- package/build/components/more-menu/index.js +119 -0
- package/build/components/more-menu/index.js.map +1 -0
- package/build/components/more-menu/tools-more-menu-group.js +23 -0
- package/build/components/more-menu/tools-more-menu-group.js.map +1 -0
- package/build/components/more-menu/view-more-menu-group.js +24 -0
- package/build/components/more-menu/view-more-menu-group.js.map +1 -0
- package/build/components/offline-status/index.native.js.map +1 -1
- package/build/components/page-attributes/check.js +8 -0
- package/build/components/page-attributes/check.js.map +1 -1
- package/build/components/page-attributes/order.js +7 -0
- package/build/components/page-attributes/order.js.map +1 -1
- package/build/components/page-attributes/panel.js +14 -8
- package/build/components/page-attributes/panel.js.map +1 -1
- package/build/components/page-attributes/parent.js +7 -0
- package/build/components/page-attributes/parent.js.map +1 -1
- package/build/components/pattern-overrides-panel/index.js.map +1 -1
- package/build/components/plugin-document-setting-panel/index.js.map +1 -1
- package/build/components/plugin-more-menu-item/index.js +78 -0
- package/build/components/plugin-more-menu-item/index.js.map +1 -0
- package/build/components/plugin-post-publish-panel/index.js +1 -1
- package/build/components/plugin-post-publish-panel/index.js.map +1 -1
- package/build/components/plugin-post-status-info/index.js +73 -0
- package/build/components/plugin-post-status-info/index.js.map +1 -0
- package/build/components/plugin-pre-publish-panel/index.js +1 -1
- package/build/components/plugin-pre-publish-panel/index.js.map +1 -1
- package/build/components/plugin-sidebar/index.js +108 -0
- package/build/components/plugin-sidebar/index.js.map +1 -0
- package/build/components/plugin-sidebar-more-menu-item/index.js +71 -0
- package/build/components/plugin-sidebar-more-menu-item/index.js.map +1 -0
- package/build/components/post-actions/actions.js +316 -20
- package/build/components/post-actions/actions.js.map +1 -1
- package/build/components/post-actions/index.js +160 -0
- package/build/components/post-actions/index.js.map +1 -0
- package/build/components/post-author/check.js +9 -0
- package/build/components/post-author/check.js.map +1 -1
- package/build/components/post-author/combobox.js.map +1 -1
- package/build/components/post-author/constants.js.map +1 -1
- package/build/components/post-author/hook.js.map +1 -1
- package/build/components/post-author/index.js +6 -0
- package/build/components/post-author/index.js.map +1 -1
- package/build/components/post-author/panel.js +5 -0
- package/build/components/post-author/panel.js.map +1 -1
- package/build/components/post-author/select.js.map +1 -1
- package/build/components/post-card-panel/index.js +14 -15
- package/build/components/post-card-panel/index.js.map +1 -1
- package/build/components/post-comments/index.js.map +1 -1
- package/build/components/post-content-information/index.js +72 -0
- package/build/components/post-content-information/index.js.map +1 -0
- package/build/components/post-discussion/panel.js +9 -7
- package/build/components/post-discussion/panel.js.map +1 -1
- package/build/components/post-excerpt/check.js +7 -18
- package/build/components/post-excerpt/check.js.map +1 -1
- package/build/components/post-excerpt/index.js +52 -12
- package/build/components/post-excerpt/index.js.map +1 -1
- package/build/components/post-excerpt/panel.js +118 -7
- package/build/components/post-excerpt/panel.js.map +1 -1
- package/build/components/post-excerpt/plugin.js +2 -2
- package/build/components/post-excerpt/plugin.js.map +1 -1
- package/build/components/post-featured-image/check.js.map +1 -1
- package/build/components/post-featured-image/index.js +1 -1
- package/build/components/post-featured-image/index.js.map +1 -1
- package/build/components/post-featured-image/panel.js.map +1 -1
- package/build/components/post-format/check.js.map +1 -1
- package/build/components/post-format/index.js.map +1 -1
- package/build/components/post-last-edited-panel/index.js +33 -0
- package/build/components/post-last-edited-panel/index.js.map +1 -0
- package/build/components/post-last-revision/check.js.map +1 -1
- package/build/components/post-last-revision/index.js.map +1 -1
- package/build/components/post-last-revision/panel.js.map +1 -1
- package/build/components/post-locked-modal/index.js.map +1 -1
- package/build/components/post-panel-row/index.js.map +1 -1
- package/build/components/post-pending-status/check.js.map +1 -1
- package/build/components/post-pending-status/index.js.map +1 -1
- package/build/components/post-pingbacks/index.js.map +1 -1
- package/build/components/post-preview-button/index.js.map +1 -1
- package/build/components/post-publish-button/index.js +31 -31
- package/build/components/post-publish-button/index.js.map +1 -1
- package/build/components/post-publish-button/label.js +51 -43
- package/build/components/post-publish-button/label.js.map +1 -1
- package/build/components/post-publish-button/post-publish-button-or-toggle.js +100 -0
- package/build/components/post-publish-button/post-publish-button-or-toggle.js.map +1 -0
- package/build/components/post-publish-panel/index.js.map +1 -1
- package/build/components/post-publish-panel/maybe-category-panel.js.map +1 -1
- package/build/components/post-publish-panel/maybe-post-format-panel.js.map +1 -1
- package/build/components/post-publish-panel/maybe-tags-panel.js.map +1 -1
- package/build/components/post-publish-panel/maybe-upload-media.js.map +1 -1
- package/build/components/post-publish-panel/postpublish.js.map +1 -1
- package/build/components/post-publish-panel/prepublish.js.map +1 -1
- package/build/components/post-saved-state/index.js +10 -6
- package/build/components/post-saved-state/index.js.map +1 -1
- package/build/components/post-schedule/check.js.map +1 -1
- package/build/components/post-schedule/index.js.map +1 -1
- package/build/components/post-schedule/label.js.map +1 -1
- package/build/components/post-schedule/panel.js +9 -1
- package/build/components/post-schedule/panel.js.map +1 -1
- package/build/components/post-slug/check.js.map +1 -1
- package/build/components/post-slug/index.js +43 -68
- package/build/components/post-slug/index.js.map +1 -1
- package/build/components/post-status/index.js +239 -0
- package/build/components/post-status/index.js.map +1 -0
- package/build/components/post-sticky/check.js.map +1 -1
- package/build/components/post-sticky/index.js.map +1 -1
- package/build/components/post-switch-to-draft-button/index.js +6 -1
- package/build/components/post-switch-to-draft-button/index.js.map +1 -1
- package/build/components/post-sync-status/index.js.map +1 -1
- package/build/components/post-taxonomies/check.js.map +1 -1
- package/build/components/post-taxonomies/flat-term-selector.js.map +1 -1
- package/build/components/post-taxonomies/hierarchical-term-selector.js.map +1 -1
- package/build/components/post-taxonomies/index.js.map +1 -1
- package/build/components/post-taxonomies/most-used-terms.js.map +1 -1
- package/build/components/post-taxonomies/panel.js.map +1 -1
- package/build/components/post-template/block-theme.js +8 -4
- package/build/components/post-template/block-theme.js.map +1 -1
- package/build/components/post-template/classic-theme.js +0 -1
- package/build/components/post-template/classic-theme.js.map +1 -1
- package/build/components/post-template/create-new-template-modal.js.map +1 -1
- package/build/components/post-template/create-new-template.js.map +1 -1
- package/build/components/post-template/hooks.js.map +1 -1
- package/build/components/post-template/panel.js.map +1 -1
- package/build/components/post-template/reset-default-template.js.map +1 -1
- package/build/components/post-template/swap-template-button.js +2 -5
- package/build/components/post-template/swap-template-button.js.map +1 -1
- package/build/components/post-text-editor/index.js.map +1 -1
- package/build/components/post-title/constants.js.map +1 -1
- package/build/components/post-title/index.js.map +1 -1
- package/build/components/post-title/index.native.js.map +1 -1
- package/build/components/post-title/post-title-raw.js.map +1 -1
- package/build/components/post-title/use-post-title-focus.js.map +1 -1
- package/build/components/post-title/use-post-title.js.map +1 -1
- package/build/components/post-trash/check.js +23 -25
- package/build/components/post-trash/check.js.map +1 -1
- package/build/components/post-trash/index.js +2 -1
- package/build/components/post-trash/index.js.map +1 -1
- package/build/components/post-type-support-check/index.js.map +1 -1
- package/build/components/post-url/check.js.map +1 -1
- package/build/components/post-url/index.js +45 -19
- package/build/components/post-url/index.js.map +1 -1
- package/build/components/post-url/label.js.map +1 -1
- package/build/components/post-url/panel.js +15 -8
- package/build/components/post-url/panel.js.map +1 -1
- package/build/components/post-view-link/index.js.map +1 -1
- package/build/components/post-visibility/check.js.map +1 -1
- package/build/components/post-visibility/index.js +2 -1
- package/build/components/post-visibility/index.js.map +1 -1
- package/build/components/post-visibility/label.js.map +1 -1
- package/build/components/post-visibility/utils.js.map +1 -1
- package/build/components/preferences-modal/enable-panel.js.map +1 -1
- package/build/components/preferences-modal/enable-plugin-document-setting-panel.js.map +1 -1
- package/build/components/preferences-modal/enable-publish-sidebar.js +34 -0
- package/build/components/preferences-modal/enable-publish-sidebar.js.map +1 -0
- package/build/components/preferences-modal/index.js +26 -18
- package/build/components/preferences-modal/index.js.map +1 -1
- package/build/components/preview-dropdown/index.js +3 -1
- package/build/components/preview-dropdown/index.js.map +1 -1
- package/build/components/provider/disable-non-page-content-blocks.js +23 -16
- package/build/components/provider/disable-non-page-content-blocks.js.map +1 -1
- package/build/components/provider/index.js +4 -2
- package/build/components/provider/index.js.map +1 -1
- package/build/components/provider/index.native.js +6 -1
- package/build/components/provider/index.native.js.map +1 -1
- package/build/components/provider/navigation-block-editing-mode.js.map +1 -1
- package/build/components/provider/use-auto-switch-editor-sidebars.js +52 -0
- package/build/components/provider/use-auto-switch-editor-sidebars.js.map +1 -0
- package/build/components/provider/use-block-editor-settings.js +64 -43
- package/build/components/provider/use-block-editor-settings.js.map +1 -1
- package/build/components/provider/use-block-editor-settings.native.js.map +1 -1
- package/build/components/provider/use-hide-blocks-from-inserter.js.map +1 -1
- package/build/components/provider/with-registry-provider.js +1 -0
- package/build/components/provider/with-registry-provider.js.map +1 -1
- package/build/components/save-publish-panels/index.js +89 -0
- package/build/components/save-publish-panels/index.js.map +1 -0
- package/build/components/start-page-options/index.js +143 -0
- package/build/components/start-page-options/index.js.map +1 -0
- package/build/components/table-of-contents/index.js.map +1 -1
- package/build/components/table-of-contents/panel.js.map +1 -1
- package/build/components/template-areas/index.js.map +1 -1
- package/build/components/template-validation-notice/index.js +23 -29
- package/build/components/template-validation-notice/index.js.map +1 -1
- package/build/components/theme-support-check/index.js +10 -16
- package/build/components/theme-support-check/index.js.map +1 -1
- package/build/components/time-to-read/index.js.map +1 -1
- package/build/components/unsaved-changes-warning/index.js.map +1 -1
- package/build/components/word-count/index.js.map +1 -1
- package/build/hooks/custom-sources-backwards-compatibility.js.map +1 -1
- package/build/hooks/default-autocompleters.js.map +1 -1
- package/build/hooks/index.js.map +1 -1
- package/build/hooks/index.native.js.map +1 -1
- package/build/hooks/pattern-overrides.js +22 -10
- package/build/hooks/pattern-overrides.js.map +1 -1
- package/build/hooks/use-select-nearest-editable-block.js.map +1 -1
- package/build/index.js.map +1 -1
- package/build/index.native.js.map +1 -1
- package/build/lock-unlock.js.map +1 -1
- package/build/private-apis.js +38 -3
- package/build/private-apis.js.map +1 -1
- package/build/store/actions.js.map +1 -1
- package/build/store/actions.native.js.map +1 -1
- package/build/store/constants.js +8 -1
- package/build/store/constants.js.map +1 -1
- package/build/store/defaults.js.map +1 -1
- package/build/store/index.js +1 -1
- package/build/store/index.js.map +1 -1
- package/build/store/local-autosave.js.map +1 -1
- package/build/store/private-actions.js +177 -4
- package/build/store/private-actions.js.map +1 -1
- package/build/store/private-selectors.js +1 -7
- package/build/store/private-selectors.js.map +1 -1
- package/build/store/reducer.js.map +1 -1
- package/build/store/reducer.native.js.map +1 -1
- package/build/store/selectors.js +8 -11
- package/build/store/selectors.js.map +1 -1
- package/build/store/selectors.native.js.map +1 -1
- package/build/store/utils/get-filtered-template-parts.js.map +1 -1
- package/build/store/utils/is-template-revertable.js +28 -0
- package/build/store/utils/is-template-revertable.js.map +1 -0
- package/build/store/utils/notice-builder.js.map +1 -1
- package/build/utils/get-template-part-icon.js.map +1 -1
- package/build/utils/index.js.map +1 -1
- package/build/utils/index.native.js.map +1 -1
- package/build/utils/media-upload/index.js.map +1 -1
- package/build/utils/media-upload/index.native.js.map +1 -1
- package/build/utils/terms.js.map +1 -1
- package/build/utils/url.js.map +1 -1
- package/build-module/bindings/index.js.map +1 -1
- package/build-module/bindings/pattern-overrides.js.map +1 -1
- package/build-module/bindings/post-meta.js +14 -31
- package/build-module/bindings/post-meta.js.map +1 -1
- package/build-module/components/autocompleters/index.js.map +1 -1
- package/build-module/components/autocompleters/user.js.map +1 -1
- package/build-module/components/autosave-monitor/index.js +24 -12
- package/build-module/components/autosave-monitor/index.js.map +1 -1
- package/build-module/components/block-manager/category.js.map +1 -1
- package/build-module/components/block-manager/checklist.js.map +1 -1
- package/build-module/components/block-manager/index.js.map +1 -1
- package/build-module/components/block-removal-warnings/index.js.map +1 -1
- package/build-module/components/block-settings-menu/plugin-block-settings-menu-item.js.map +1 -1
- package/build-module/components/character-count/index.js +6 -0
- package/build-module/components/character-count/index.js.map +1 -1
- package/build-module/components/collapsible-block-toolbar/index.js +65 -0
- package/build-module/components/collapsible-block-toolbar/index.js.map +1 -0
- package/build-module/components/commands/index.js +20 -1
- package/build-module/components/commands/index.js.map +1 -1
- package/build-module/components/commands/index.native.js.map +1 -1
- package/build-module/components/deprecated.js.map +1 -1
- package/build-module/components/deprecated.native.js.map +1 -1
- package/build-module/components/document-bar/index.js.map +1 -1
- package/build-module/components/document-outline/check.js +9 -0
- package/build-module/components/document-outline/check.js.map +1 -1
- package/build-module/components/document-outline/index.js +11 -0
- package/build-module/components/document-outline/index.js.map +1 -1
- package/build-module/components/document-outline/item.js.map +1 -1
- package/build-module/components/document-tools/index.js +2 -9
- package/build-module/components/document-tools/index.js.map +1 -1
- package/build-module/components/editor-canvas/edit-template-blocks-notification.js +13 -2
- package/build-module/components/editor-canvas/edit-template-blocks-notification.js.map +1 -1
- package/build-module/components/editor-canvas/index.js +2 -2
- package/build-module/components/editor-canvas/index.js.map +1 -1
- package/build-module/components/editor-help/add-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/customize-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/help-detail-navigation-screen.native.js.map +1 -1
- package/build-module/components/editor-help/help-get-support-button.native.js.map +1 -1
- package/build-module/components/editor-help/help-section-title.native.js.map +1 -1
- package/build-module/components/editor-help/help-topic-row.native.js.map +1 -1
- package/build-module/components/editor-help/icon-move-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/index.native.js.map +1 -1
- package/build-module/components/editor-help/intro-to-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/move-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/remove-blocks.native.js.map +1 -1
- package/build-module/components/editor-help/view-sections.native.js.map +1 -1
- package/build-module/components/editor-history/redo.js +11 -0
- package/build-module/components/editor-history/redo.js.map +1 -1
- package/build-module/components/editor-history/undo.js +11 -0
- package/build-module/components/editor-history/undo.js.map +1 -1
- package/build-module/components/editor-notices/index.js.map +1 -1
- package/build-module/components/editor-snackbars/index.js +6 -0
- package/build-module/components/editor-snackbars/index.js.map +1 -1
- package/build-module/components/entities-saved-states/entity-record-item.js.map +1 -1
- package/build-module/components/entities-saved-states/entity-type-list.js.map +1 -1
- package/build-module/components/entities-saved-states/hooks/use-is-dirty.js.map +1 -1
- package/build-module/components/entities-saved-states/index.js.map +1 -1
- package/build-module/components/error-boundary/index.js.map +1 -1
- package/build-module/components/error-boundary/index.native.js.map +1 -1
- package/build-module/components/global-keyboard-shortcuts/index.js +32 -0
- package/build-module/components/global-keyboard-shortcuts/index.js.map +1 -1
- package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js +53 -0
- package/build-module/components/global-keyboard-shortcuts/register-shortcuts.js.map +1 -1
- package/build-module/components/index.js +4 -0
- package/build-module/components/index.js.map +1 -1
- package/build-module/components/index.native.js.map +1 -1
- package/build-module/components/inserter-sidebar/index.js +2 -5
- package/build-module/components/inserter-sidebar/index.js.map +1 -1
- package/build-module/components/keyboard-shortcut-help-modal/config.js +75 -0
- package/build-module/components/keyboard-shortcut-help-modal/config.js.map +1 -0
- package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +41 -0
- package/build-module/components/keyboard-shortcut-help-modal/dynamic-shortcut.js.map +1 -0
- package/build-module/components/keyboard-shortcut-help-modal/index.js +118 -0
- package/build-module/components/keyboard-shortcut-help-modal/index.js.map +1 -0
- package/build-module/components/keyboard-shortcut-help-modal/shortcut.js +48 -0
- package/build-module/components/keyboard-shortcut-help-modal/shortcut.js.map +1 -0
- package/build-module/components/list-view-sidebar/index.js +1 -1
- package/build-module/components/list-view-sidebar/index.js.map +1 -1
- package/build-module/components/list-view-sidebar/list-view-outline.js.map +1 -1
- package/build-module/components/local-autosave-monitor/index.js.map +1 -1
- package/build-module/components/media-categories/index.js.map +1 -1
- package/build-module/components/mode-switcher/index.js.map +1 -1
- package/build-module/components/more-menu/copy-content-menu-item.js +52 -0
- package/build-module/components/more-menu/copy-content-menu-item.js.map +1 -0
- package/build-module/components/more-menu/index.js +111 -0
- package/build-module/components/more-menu/index.js.map +1 -0
- package/build-module/components/more-menu/tools-more-menu-group.js +16 -0
- package/build-module/components/more-menu/tools-more-menu-group.js.map +1 -0
- package/build-module/components/more-menu/view-more-menu-group.js +17 -0
- package/build-module/components/more-menu/view-more-menu-group.js.map +1 -0
- package/build-module/components/offline-status/index.native.js.map +1 -1
- package/build-module/components/page-attributes/check.js +9 -0
- package/build-module/components/page-attributes/check.js.map +1 -1
- package/build-module/components/page-attributes/order.js +7 -0
- package/build-module/components/page-attributes/order.js.map +1 -1
- package/build-module/components/page-attributes/panel.js +13 -6
- package/build-module/components/page-attributes/panel.js.map +1 -1
- package/build-module/components/page-attributes/parent.js +7 -0
- package/build-module/components/page-attributes/parent.js.map +1 -1
- package/build-module/components/pattern-overrides-panel/index.js.map +1 -1
- package/build-module/components/plugin-document-setting-panel/index.js.map +1 -1
- package/build-module/components/plugin-more-menu-item/index.js +73 -0
- package/build-module/components/plugin-more-menu-item/index.js.map +1 -0
- package/build-module/components/plugin-post-publish-panel/index.js +1 -1
- package/build-module/components/plugin-post-publish-panel/index.js.map +1 -1
- package/build-module/components/plugin-post-status-info/index.js +66 -0
- package/build-module/components/plugin-post-status-info/index.js.map +1 -0
- package/build-module/components/plugin-pre-publish-panel/index.js +1 -1
- package/build-module/components/plugin-pre-publish-panel/index.js.map +1 -1
- package/build-module/components/plugin-sidebar/index.js +102 -0
- package/build-module/components/plugin-sidebar/index.js.map +1 -0
- package/build-module/components/plugin-sidebar-more-menu-item/index.js +65 -0
- package/build-module/components/plugin-sidebar-more-menu-item/index.js.map +1 -0
- package/build-module/components/post-actions/actions.js +317 -19
- package/build-module/components/post-actions/actions.js.map +1 -1
- package/build-module/components/post-actions/index.js +153 -0
- package/build-module/components/post-actions/index.js.map +1 -0
- package/build-module/components/post-author/check.js +10 -0
- package/build-module/components/post-author/check.js.map +1 -1
- package/build-module/components/post-author/combobox.js.map +1 -1
- package/build-module/components/post-author/constants.js.map +1 -1
- package/build-module/components/post-author/hook.js.map +1 -1
- package/build-module/components/post-author/index.js +6 -0
- package/build-module/components/post-author/index.js.map +1 -1
- package/build-module/components/post-author/panel.js +6 -0
- package/build-module/components/post-author/panel.js.map +1 -1
- package/build-module/components/post-author/select.js.map +1 -1
- package/build-module/components/post-card-panel/index.js +16 -17
- package/build-module/components/post-card-panel/index.js.map +1 -1
- package/build-module/components/post-comments/index.js.map +1 -1
- package/build-module/components/post-content-information/index.js +66 -0
- package/build-module/components/post-content-information/index.js.map +1 -0
- package/build-module/components/post-discussion/panel.js +8 -6
- package/build-module/components/post-discussion/panel.js.map +1 -1
- package/build-module/components/post-excerpt/check.js +8 -18
- package/build-module/components/post-excerpt/check.js.map +1 -1
- package/build-module/components/post-excerpt/index.js +52 -11
- package/build-module/components/post-excerpt/index.js.map +1 -1
- package/build-module/components/post-excerpt/panel.js +118 -8
- package/build-module/components/post-excerpt/panel.js.map +1 -1
- package/build-module/components/post-excerpt/plugin.js +2 -2
- package/build-module/components/post-excerpt/plugin.js.map +1 -1
- package/build-module/components/post-featured-image/check.js.map +1 -1
- package/build-module/components/post-featured-image/index.js +1 -1
- package/build-module/components/post-featured-image/index.js.map +1 -1
- package/build-module/components/post-featured-image/panel.js.map +1 -1
- package/build-module/components/post-format/check.js.map +1 -1
- package/build-module/components/post-format/index.js.map +1 -1
- package/build-module/components/post-last-edited-panel/index.js +26 -0
- package/build-module/components/post-last-edited-panel/index.js.map +1 -0
- package/build-module/components/post-last-revision/check.js.map +1 -1
- package/build-module/components/post-last-revision/index.js.map +1 -1
- package/build-module/components/post-last-revision/panel.js.map +1 -1
- package/build-module/components/post-locked-modal/index.js.map +1 -1
- package/build-module/components/post-panel-row/index.js.map +1 -1
- package/build-module/components/post-pending-status/check.js.map +1 -1
- package/build-module/components/post-pending-status/index.js.map +1 -1
- package/build-module/components/post-pingbacks/index.js.map +1 -1
- package/build-module/components/post-preview-button/index.js.map +1 -1
- package/build-module/components/post-publish-button/index.js +31 -31
- package/build-module/components/post-publish-button/index.js.map +1 -1
- package/build-module/components/post-publish-button/label.js +51 -42
- package/build-module/components/post-publish-button/label.js.map +1 -1
- package/build-module/components/post-publish-button/post-publish-button-or-toggle.js +91 -0
- package/build-module/components/post-publish-button/post-publish-button-or-toggle.js.map +1 -0
- package/build-module/components/post-publish-panel/index.js.map +1 -1
- package/build-module/components/post-publish-panel/maybe-category-panel.js.map +1 -1
- package/build-module/components/post-publish-panel/maybe-post-format-panel.js.map +1 -1
- package/build-module/components/post-publish-panel/maybe-tags-panel.js.map +1 -1
- package/build-module/components/post-publish-panel/maybe-upload-media.js.map +1 -1
- package/build-module/components/post-publish-panel/postpublish.js.map +1 -1
- package/build-module/components/post-publish-panel/prepublish.js.map +1 -1
- package/build-module/components/post-saved-state/index.js +10 -6
- package/build-module/components/post-saved-state/index.js.map +1 -1
- package/build-module/components/post-schedule/check.js.map +1 -1
- package/build-module/components/post-schedule/index.js.map +1 -1
- package/build-module/components/post-schedule/label.js.map +1 -1
- package/build-module/components/post-schedule/panel.js +9 -1
- package/build-module/components/post-schedule/panel.js.map +1 -1
- package/build-module/components/post-slug/check.js.map +1 -1
- package/build-module/components/post-slug/index.js +44 -68
- package/build-module/components/post-slug/index.js.map +1 -1
- package/build-module/components/post-status/index.js +231 -0
- package/build-module/components/post-status/index.js.map +1 -0
- package/build-module/components/post-sticky/check.js.map +1 -1
- package/build-module/components/post-sticky/index.js.map +1 -1
- package/build-module/components/post-switch-to-draft-button/index.js +7 -1
- package/build-module/components/post-switch-to-draft-button/index.js.map +1 -1
- package/build-module/components/post-sync-status/index.js.map +1 -1
- package/build-module/components/post-taxonomies/check.js.map +1 -1
- package/build-module/components/post-taxonomies/flat-term-selector.js.map +1 -1
- package/build-module/components/post-taxonomies/hierarchical-term-selector.js.map +1 -1
- package/build-module/components/post-taxonomies/index.js.map +1 -1
- package/build-module/components/post-taxonomies/most-used-terms.js.map +1 -1
- package/build-module/components/post-taxonomies/panel.js.map +1 -1
- package/build-module/components/post-template/block-theme.js +9 -5
- package/build-module/components/post-template/block-theme.js.map +1 -1
- package/build-module/components/post-template/classic-theme.js +0 -1
- package/build-module/components/post-template/classic-theme.js.map +1 -1
- package/build-module/components/post-template/create-new-template-modal.js.map +1 -1
- package/build-module/components/post-template/create-new-template.js.map +1 -1
- package/build-module/components/post-template/hooks.js.map +1 -1
- package/build-module/components/post-template/panel.js.map +1 -1
- package/build-module/components/post-template/reset-default-template.js.map +1 -1
- package/build-module/components/post-template/swap-template-button.js +3 -6
- package/build-module/components/post-template/swap-template-button.js.map +1 -1
- package/build-module/components/post-text-editor/index.js.map +1 -1
- package/build-module/components/post-title/constants.js.map +1 -1
- package/build-module/components/post-title/index.js.map +1 -1
- package/build-module/components/post-title/index.native.js.map +1 -1
- package/build-module/components/post-title/post-title-raw.js.map +1 -1
- package/build-module/components/post-title/use-post-title-focus.js.map +1 -1
- package/build-module/components/post-title/use-post-title.js.map +1 -1
- package/build-module/components/post-trash/check.js +24 -26
- package/build-module/components/post-trash/check.js.map +1 -1
- package/build-module/components/post-trash/index.js +2 -1
- package/build-module/components/post-trash/index.js.map +1 -1
- package/build-module/components/post-type-support-check/index.js.map +1 -1
- package/build-module/components/post-url/check.js.map +1 -1
- package/build-module/components/post-url/index.js +47 -21
- package/build-module/components/post-url/index.js.map +1 -1
- package/build-module/components/post-url/label.js.map +1 -1
- package/build-module/components/post-url/panel.js +15 -8
- package/build-module/components/post-url/panel.js.map +1 -1
- package/build-module/components/post-view-link/index.js.map +1 -1
- package/build-module/components/post-visibility/check.js.map +1 -1
- package/build-module/components/post-visibility/index.js +2 -1
- package/build-module/components/post-visibility/index.js.map +1 -1
- package/build-module/components/post-visibility/label.js.map +1 -1
- package/build-module/components/post-visibility/utils.js.map +1 -1
- package/build-module/components/preferences-modal/enable-panel.js.map +1 -1
- package/build-module/components/preferences-modal/enable-plugin-document-setting-panel.js.map +1 -1
- package/build-module/components/preferences-modal/enable-publish-sidebar.js +27 -0
- package/build-module/components/preferences-modal/enable-publish-sidebar.js.map +1 -0
- package/build-module/components/preferences-modal/index.js +26 -18
- package/build-module/components/preferences-modal/index.js.map +1 -1
- package/build-module/components/preview-dropdown/index.js +3 -1
- package/build-module/components/preview-dropdown/index.js.map +1 -1
- package/build-module/components/provider/disable-non-page-content-blocks.js +24 -17
- package/build-module/components/provider/disable-non-page-content-blocks.js.map +1 -1
- package/build-module/components/provider/index.js +5 -3
- package/build-module/components/provider/index.js.map +1 -1
- package/build-module/components/provider/index.native.js.map +1 -1
- package/build-module/components/provider/navigation-block-editing-mode.js.map +1 -1
- package/build-module/components/provider/use-auto-switch-editor-sidebars.js +46 -0
- package/build-module/components/provider/use-auto-switch-editor-sidebars.js.map +1 -0
- package/build-module/components/provider/use-block-editor-settings.js +66 -45
- package/build-module/components/provider/use-block-editor-settings.js.map +1 -1
- package/build-module/components/provider/use-block-editor-settings.native.js.map +1 -1
- package/build-module/components/provider/use-hide-blocks-from-inserter.js.map +1 -1
- package/build-module/components/provider/with-registry-provider.js +1 -0
- package/build-module/components/provider/with-registry-provider.js.map +1 -1
- package/build-module/components/save-publish-panels/index.js +80 -0
- package/build-module/components/save-publish-panels/index.js.map +1 -0
- package/build-module/components/start-page-options/index.js +136 -0
- package/build-module/components/start-page-options/index.js.map +1 -0
- package/build-module/components/table-of-contents/index.js.map +1 -1
- package/build-module/components/table-of-contents/panel.js.map +1 -1
- package/build-module/components/template-areas/index.js.map +1 -1
- package/build-module/components/template-validation-notice/index.js +25 -31
- package/build-module/components/template-validation-notice/index.js.map +1 -1
- package/build-module/components/theme-support-check/index.js +11 -16
- package/build-module/components/theme-support-check/index.js.map +1 -1
- package/build-module/components/time-to-read/index.js.map +1 -1
- package/build-module/components/unsaved-changes-warning/index.js.map +1 -1
- package/build-module/components/word-count/index.js.map +1 -1
- package/build-module/hooks/custom-sources-backwards-compatibility.js.map +1 -1
- package/build-module/hooks/default-autocompleters.js.map +1 -1
- package/build-module/hooks/index.js.map +1 -1
- package/build-module/hooks/index.native.js.map +1 -1
- package/build-module/hooks/pattern-overrides.js +22 -10
- package/build-module/hooks/pattern-overrides.js.map +1 -1
- package/build-module/hooks/use-select-nearest-editable-block.js.map +1 -1
- package/build-module/index.js.map +1 -1
- package/build-module/index.native.js.map +1 -1
- package/build-module/lock-unlock.js.map +1 -1
- package/build-module/private-apis.js +36 -3
- package/build-module/private-apis.js.map +1 -1
- package/build-module/store/actions.js.map +1 -1
- package/build-module/store/actions.native.js.map +1 -1
- package/build-module/store/constants.js +7 -0
- package/build-module/store/constants.js.map +1 -1
- package/build-module/store/defaults.js.map +1 -1
- package/build-module/store/index.js.map +1 -1
- package/build-module/store/local-autosave.js.map +1 -1
- package/build-module/store/private-actions.js +174 -4
- package/build-module/store/private-actions.js.map +1 -1
- package/build-module/store/private-selectors.js +1 -6
- package/build-module/store/private-selectors.js.map +1 -1
- package/build-module/store/reducer.js.map +1 -1
- package/build-module/store/reducer.native.js.map +1 -1
- package/build-module/store/selectors.js +4 -7
- package/build-module/store/selectors.js.map +1 -1
- package/build-module/store/selectors.native.js.map +1 -1
- package/build-module/store/utils/get-filtered-template-parts.js.map +1 -1
- package/build-module/store/utils/is-template-revertable.js +22 -0
- package/build-module/store/utils/is-template-revertable.js.map +1 -0
- package/build-module/store/utils/notice-builder.js.map +1 -1
- package/build-module/utils/get-template-part-icon.js.map +1 -1
- package/build-module/utils/index.js.map +1 -1
- package/build-module/utils/index.native.js.map +1 -1
- package/build-module/utils/media-upload/index.js.map +1 -1
- package/build-module/utils/media-upload/index.native.js.map +1 -1
- package/build-module/utils/terms.js.map +1 -1
- package/build-module/utils/url.js.map +1 -1
- package/build-style/style-rtl.css +703 -53
- package/build-style/style.css +703 -53
- package/package.json +35 -35
- package/src/bindings/post-meta.js +11 -27
- package/src/components/autosave-monitor/index.js +23 -11
- package/src/components/character-count/index.js +5 -0
- package/src/components/collapsible-block-toolbar/index.js +77 -0
- package/src/components/collapsible-block-toolbar/style.scss +80 -0
- package/src/components/commands/index.js +20 -1
- package/src/components/document-outline/check.js +8 -0
- package/src/components/document-outline/index.js +10 -0
- package/src/components/document-tools/index.js +16 -19
- package/src/components/editor-canvas/edit-template-blocks-notification.js +16 -2
- package/src/components/editor-canvas/index.js +4 -4
- package/src/components/editor-history/redo.js +10 -0
- package/src/components/editor-history/undo.js +10 -0
- package/src/components/editor-snackbars/index.js +5 -0
- package/src/components/entities-saved-states/style.scss +7 -0
- package/src/components/error-boundary/style.native.scss +1 -1
- package/src/components/global-keyboard-shortcuts/index.js +32 -0
- package/src/components/global-keyboard-shortcuts/register-shortcuts.js +61 -0
- package/src/components/index.js +4 -0
- package/src/components/inserter-sidebar/index.js +2 -5
- package/src/components/keyboard-shortcut-help-modal/config.js +62 -0
- package/src/components/keyboard-shortcut-help-modal/dynamic-shortcut.js +43 -0
- package/src/components/keyboard-shortcut-help-modal/index.js +160 -0
- package/src/components/keyboard-shortcut-help-modal/shortcut.js +67 -0
- package/src/components/keyboard-shortcut-help-modal/style.scss +61 -0
- package/src/components/list-view-sidebar/index.js +1 -1
- package/src/components/list-view-sidebar/style.scss +2 -2
- package/src/components/more-menu/copy-content-menu-item.js +51 -0
- package/src/components/more-menu/index.js +158 -0
- package/src/components/more-menu/tools-more-menu-group.js +11 -0
- package/src/components/more-menu/view-more-menu-group.js +13 -0
- package/src/components/page-attributes/check.js +8 -0
- package/src/components/page-attributes/order.js +6 -0
- package/src/components/page-attributes/panel.js +21 -17
- package/src/components/page-attributes/parent.js +6 -0
- package/src/components/plugin-more-menu-item/index.js +73 -0
- package/src/components/plugin-post-publish-panel/index.js +1 -1
- package/src/components/plugin-post-status-info/index.js +63 -0
- package/src/components/plugin-pre-publish-panel/index.js +1 -1
- package/src/components/plugin-sidebar/index.js +98 -0
- package/src/components/plugin-sidebar-more-menu-item/index.js +64 -0
- package/src/components/post-actions/actions.js +413 -18
- package/src/components/post-actions/index.js +190 -0
- package/src/components/post-actions/style.scss +3 -0
- package/src/components/post-author/check.js +9 -0
- package/src/components/post-author/index.js +5 -0
- package/src/components/post-author/panel.js +5 -0
- package/src/components/post-card-panel/index.js +28 -23
- package/src/components/post-card-panel/style.scss +2 -6
- package/src/components/post-content-information/index.js +83 -0
- package/src/components/post-content-information/style.scss +6 -0
- package/src/components/post-discussion/panel.js +24 -20
- package/src/components/post-excerpt/check.js +8 -18
- package/src/components/post-excerpt/index.js +66 -15
- package/src/components/post-excerpt/panel.js +196 -19
- package/src/components/post-excerpt/plugin.js +2 -2
- package/src/components/post-excerpt/style.scss +24 -0
- package/src/components/post-featured-image/index.js +1 -1
- package/src/components/post-featured-image/style.scss +2 -8
- package/src/components/post-last-edited-panel/index.js +35 -0
- package/src/components/post-last-edited-panel/style.scss +6 -0
- package/src/components/post-panel-row/style.scss +3 -3
- package/src/components/post-publish-button/index.js +23 -36
- package/src/components/post-publish-button/label.js +54 -39
- package/src/components/post-publish-button/post-publish-button-or-toggle.js +102 -0
- package/src/components/post-publish-button/test/index.js +15 -26
- package/src/components/post-publish-button/test/label.js +44 -21
- package/src/components/post-publish-button/test/post-publish-button-or-toggle.js +63 -0
- package/src/components/post-publish-panel/style.scss +43 -0
- package/src/components/post-publish-panel/test/__snapshots__/index.js.snap +225 -75
- package/src/components/post-saved-state/index.js +13 -6
- package/src/components/post-saved-state/test/index.js +4 -0
- package/src/components/post-schedule/panel.js +23 -1
- package/src/components/post-schedule/style.scss +2 -4
- package/src/components/post-slug/index.js +50 -68
- package/src/components/post-slug/test/index.js +29 -6
- package/src/components/post-status/index.js +318 -0
- package/src/components/post-status/style.scss +74 -0
- package/src/components/post-switch-to-draft-button/index.js +5 -0
- package/src/components/post-template/block-theme.js +33 -24
- package/src/components/post-template/classic-theme.js +0 -1
- package/src/components/post-template/swap-template-button.js +3 -6
- package/src/components/post-text-editor/style.scss +1 -1
- package/src/components/post-title/style.scss +1 -1
- package/src/components/post-trash/check.js +19 -19
- package/src/components/post-trash/index.js +1 -0
- package/src/components/post-url/index.js +132 -101
- package/src/components/post-url/panel.js +21 -8
- package/src/components/post-url/style.scss +8 -6
- package/src/components/post-visibility/index.js +1 -0
- package/src/components/preferences-modal/enable-publish-sidebar.js +28 -0
- package/src/components/preferences-modal/index.js +40 -22
- package/src/components/preview-dropdown/index.js +3 -1
- package/src/components/provider/disable-non-page-content-blocks.js +23 -21
- package/src/components/provider/index.js +17 -8
- package/src/components/provider/use-auto-switch-editor-sidebars.js +49 -0
- package/src/components/provider/use-block-editor-settings.js +59 -33
- package/src/components/provider/with-registry-provider.js +1 -0
- package/src/components/save-publish-panels/index.js +96 -0
- package/src/components/save-publish-panels/style.scss +36 -0
- package/src/components/start-page-options/index.js +140 -0
- package/src/components/start-page-options/style.scss +26 -0
- package/src/components/template-validation-notice/index.js +48 -50
- package/src/components/theme-support-check/index.js +9 -16
- package/src/components/theme-support-check/test/index.js +44 -43
- package/src/hooks/pattern-overrides.js +25 -14
- package/src/private-apis.js +33 -2
- package/src/store/constants.js +7 -0
- package/src/store/private-actions.js +269 -4
- package/src/store/private-selectors.js +1 -6
- package/src/store/selectors.js +4 -7
- package/src/store/utils/is-template-revertable.js +23 -0
- package/src/style.scss +10 -2
- package/src/components/post-publish-button/style.scss +0 -8
- package/src/components/provider/test/disable-non-page-content-blocks.js +0 -111
- package/src/components/template-validation-notice/style.scss +0 -9
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -128,7 +128,29 @@ Example:
|
|
|
128
128
|
|
|
129
129
|
### AutosaveMonitor
|
|
130
130
|
|
|
131
|
-
|
|
131
|
+
Monitors the changes made to the edited post and triggers autosave if necessary.
|
|
132
|
+
|
|
133
|
+
The logic is straightforward: a check is performed every `props.interval` seconds. If any changes are detected, `props.autosave()` is called. The time between the change and the autosave varies but is no larger than `props.interval` seconds. Refer to the code below for more details, such as the specific way of detecting changes.
|
|
134
|
+
|
|
135
|
+
There are two caveats:
|
|
136
|
+
|
|
137
|
+
- If `props.isAutosaveable` happens to be false at a time of checking for changes, the check is retried every second.
|
|
138
|
+
- The timer may be disabled by setting `props.disableIntervalChecks` to `true`. In that mode, any change will immediately trigger `props.autosave()`.
|
|
139
|
+
|
|
140
|
+
_Usage_
|
|
141
|
+
|
|
142
|
+
```jsx
|
|
143
|
+
<AutosaveMonitor interval={ 30000 } />
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
_Parameters_
|
|
147
|
+
|
|
148
|
+
- _props_ `Object`: - The properties passed to the component.
|
|
149
|
+
- _props.autosave_ `Function`: - The function to call when changes need to be saved.
|
|
150
|
+
- _props.interval_ `number`: - The maximum time in seconds between an unsaved change and an autosave.
|
|
151
|
+
- _props.isAutosaveable_ `boolean`: - If false, the check for changes is retried every second.
|
|
152
|
+
- _props.disableIntervalChecks_ `boolean`: - If true, disables the timer and any change will immediately trigger `props.autosave()`.
|
|
153
|
+
- _props.isDirty_ `boolean`: - Indicates if there are unsaved changes.
|
|
132
154
|
|
|
133
155
|
### BlockAlignmentToolbar
|
|
134
156
|
|
|
@@ -188,7 +210,11 @@ Undocumented declaration.
|
|
|
188
210
|
|
|
189
211
|
### CharacterCount
|
|
190
212
|
|
|
191
|
-
|
|
213
|
+
Renders the character count of the post content.
|
|
214
|
+
|
|
215
|
+
_Returns_
|
|
216
|
+
|
|
217
|
+
- `number`: The character count.
|
|
192
218
|
|
|
193
219
|
### cleanForSlug
|
|
194
220
|
|
|
@@ -232,27 +258,71 @@ Undocumented declaration.
|
|
|
232
258
|
|
|
233
259
|
### DocumentOutline
|
|
234
260
|
|
|
235
|
-
|
|
261
|
+
Renders a document outline component.
|
|
262
|
+
|
|
263
|
+
_Parameters_
|
|
264
|
+
|
|
265
|
+
- _props_ `Object`: Props.
|
|
266
|
+
- _props.onSelect_ `Function`: Function to be called when an outline item is selected.
|
|
267
|
+
- _props.isTitleSupported_ `boolean`: Indicates whether the title is supported.
|
|
268
|
+
- _props.hasOutlineItemsDisabled_ `boolean`: Indicates whether the outline items are disabled.
|
|
269
|
+
|
|
270
|
+
_Returns_
|
|
271
|
+
|
|
272
|
+
- `Component`: The component to be rendered.
|
|
236
273
|
|
|
237
274
|
### DocumentOutlineCheck
|
|
238
275
|
|
|
239
|
-
|
|
276
|
+
Component check if there are any headings (core/heading blocks) present in the document.
|
|
277
|
+
|
|
278
|
+
_Parameters_
|
|
279
|
+
|
|
280
|
+
- _props_ `Object`: Props.
|
|
281
|
+
- _props.children_ `Element`: Children to be rendered.
|
|
282
|
+
|
|
283
|
+
_Returns_
|
|
284
|
+
|
|
285
|
+
- `Component|null`: The component to be rendered or null if there are headings.
|
|
240
286
|
|
|
241
287
|
### EditorHistoryRedo
|
|
242
288
|
|
|
243
|
-
|
|
289
|
+
Renders the redo button for the editor history.
|
|
290
|
+
|
|
291
|
+
_Parameters_
|
|
292
|
+
|
|
293
|
+
- _props_ `Object`: - Props.
|
|
294
|
+
- _ref_ `Ref`: - Forwarded ref.
|
|
295
|
+
|
|
296
|
+
_Returns_
|
|
297
|
+
|
|
298
|
+
- `Component`: The component to be rendered.
|
|
244
299
|
|
|
245
300
|
### EditorHistoryUndo
|
|
246
301
|
|
|
247
|
-
|
|
302
|
+
Renders the undo button for the editor history.
|
|
303
|
+
|
|
304
|
+
_Parameters_
|
|
305
|
+
|
|
306
|
+
- _props_ `Object`: - Props.
|
|
307
|
+
- _ref_ `Ref`: - Forwarded ref.
|
|
308
|
+
|
|
309
|
+
_Returns_
|
|
310
|
+
|
|
311
|
+
- `Component`: The component to be rendered.
|
|
248
312
|
|
|
249
313
|
### EditorKeyboardShortcuts
|
|
250
314
|
|
|
251
|
-
|
|
315
|
+
Component handles the keyboard shortcuts for the editor.
|
|
316
|
+
|
|
317
|
+
It provides functionality for various keyboard shortcuts such as toggling editor mode, toggling distraction-free mode, undo/redo, saving the post, toggling list view, and toggling the sidebar.
|
|
252
318
|
|
|
253
319
|
### EditorKeyboardShortcutsRegister
|
|
254
320
|
|
|
255
|
-
|
|
321
|
+
Component for registering editor keyboard shortcuts.
|
|
322
|
+
|
|
323
|
+
_Returns_
|
|
324
|
+
|
|
325
|
+
- `Element`: The component to be rendered.
|
|
256
326
|
|
|
257
327
|
### EditorNotices
|
|
258
328
|
|
|
@@ -264,7 +334,11 @@ Undocumented declaration.
|
|
|
264
334
|
|
|
265
335
|
### EditorSnackbars
|
|
266
336
|
|
|
267
|
-
|
|
337
|
+
Renders the editor snackbars component.
|
|
338
|
+
|
|
339
|
+
_Returns_
|
|
340
|
+
|
|
341
|
+
- `JSX.Element`: The rendered component.
|
|
268
342
|
|
|
269
343
|
### EntitiesSavedStates
|
|
270
344
|
|
|
@@ -370,19 +444,40 @@ _Parameters_
|
|
|
370
444
|
|
|
371
445
|
### PageAttributesCheck
|
|
372
446
|
|
|
373
|
-
|
|
447
|
+
Wrapper component that renders its children only if the post type supports page attributes.
|
|
448
|
+
|
|
449
|
+
_Parameters_
|
|
450
|
+
|
|
451
|
+
- _props_ `Object`: - The component props.
|
|
452
|
+
- _props.children_ `Element`: - The child components to render.
|
|
453
|
+
|
|
454
|
+
_Returns_
|
|
455
|
+
|
|
456
|
+
- `Component|null`: The rendered child components or null if page attributes are not supported.
|
|
374
457
|
|
|
375
458
|
### PageAttributesOrder
|
|
376
459
|
|
|
377
|
-
|
|
460
|
+
Renders the Page Attributes Order component. A number input in an editor interface for setting the order of a given page.
|
|
461
|
+
|
|
462
|
+
_Returns_
|
|
463
|
+
|
|
464
|
+
- `Component`: The component to be rendered.
|
|
378
465
|
|
|
379
466
|
### PageAttributesPanel
|
|
380
467
|
|
|
381
|
-
|
|
468
|
+
Renders the Page Attributes Panel component.
|
|
469
|
+
|
|
470
|
+
_Returns_
|
|
471
|
+
|
|
472
|
+
- `Component`: The component to be rendered.
|
|
382
473
|
|
|
383
474
|
### PageAttributesParent
|
|
384
475
|
|
|
385
|
-
|
|
476
|
+
Renders the Page Attributes Parent component. A dropdown menu in an editor interface for selecting the parent page of a given page.
|
|
477
|
+
|
|
478
|
+
_Returns_
|
|
479
|
+
|
|
480
|
+
- `Component|null`: The component to be rendered. Return null if post type is not hierarchical.
|
|
386
481
|
|
|
387
482
|
### PageTemplate
|
|
388
483
|
|
|
@@ -515,6 +610,63 @@ _Returns_
|
|
|
515
610
|
|
|
516
611
|
- `Component`: The component to be rendered.
|
|
517
612
|
|
|
613
|
+
### PluginMoreMenuItem
|
|
614
|
+
|
|
615
|
+
Renders a menu item in `Plugins` group in `More Menu` drop down, and can be used to as a button or link depending on the props provided. The text within the component appears as the menu item label.
|
|
616
|
+
|
|
617
|
+
_Usage_
|
|
618
|
+
|
|
619
|
+
```js
|
|
620
|
+
// Using ES5 syntax
|
|
621
|
+
var __ = wp.i18n.__;
|
|
622
|
+
var PluginMoreMenuItem = wp.editor.PluginMoreMenuItem;
|
|
623
|
+
var moreIcon = wp.element.createElement( 'svg' ); //... svg element.
|
|
624
|
+
|
|
625
|
+
function onButtonClick() {
|
|
626
|
+
alert( 'Button clicked.' );
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
function MyButtonMoreMenuItem() {
|
|
630
|
+
return wp.element.createElement(
|
|
631
|
+
PluginMoreMenuItem,
|
|
632
|
+
{
|
|
633
|
+
icon: moreIcon,
|
|
634
|
+
onClick: onButtonClick,
|
|
635
|
+
},
|
|
636
|
+
__( 'My button title' )
|
|
637
|
+
);
|
|
638
|
+
}
|
|
639
|
+
```
|
|
640
|
+
|
|
641
|
+
```jsx
|
|
642
|
+
// Using ESNext syntax
|
|
643
|
+
import { __ } from '@wordpress/i18n';
|
|
644
|
+
import { PluginMoreMenuItem } from '@wordpress/editor';
|
|
645
|
+
import { more } from '@wordpress/icons';
|
|
646
|
+
|
|
647
|
+
function onButtonClick() {
|
|
648
|
+
alert( 'Button clicked.' );
|
|
649
|
+
}
|
|
650
|
+
|
|
651
|
+
const MyButtonMoreMenuItem = () => (
|
|
652
|
+
<PluginMoreMenuItem icon={ more } onClick={ onButtonClick }>
|
|
653
|
+
{ __( 'My button title' ) }
|
|
654
|
+
</PluginMoreMenuItem>
|
|
655
|
+
);
|
|
656
|
+
```
|
|
657
|
+
|
|
658
|
+
_Parameters_
|
|
659
|
+
|
|
660
|
+
- _props_ `Object`: Component properties.
|
|
661
|
+
- _props.href_ `[string]`: When `href` is provided then the menu item is represented as an anchor rather than button. It corresponds to the `href` attribute of the anchor.
|
|
662
|
+
- _props.icon_ `[WPBlockTypeIconRender]`: The [Dashicon](https://developer.wordpress.org/resource/dashicons/) icon slug string, or an SVG WP element, to be rendered to the left of the menu item label.
|
|
663
|
+
- _props.onClick_ `[Function]`: The callback function to be executed when the user clicks the menu item.
|
|
664
|
+
- _props.other_ `[...*]`: Any additional props are passed through to the underlying [Button](/packages/components/src/button/README.md) component.
|
|
665
|
+
|
|
666
|
+
_Returns_
|
|
667
|
+
|
|
668
|
+
- `Component`: The component to be rendered.
|
|
669
|
+
|
|
518
670
|
### PluginPostPublishPanel
|
|
519
671
|
|
|
520
672
|
Renders provided content to the post-publish panel in the publish flow (side panel that opens after a user publishes the post).
|
|
@@ -524,7 +676,7 @@ _Usage_
|
|
|
524
676
|
```jsx
|
|
525
677
|
// Using ESNext syntax
|
|
526
678
|
import { __ } from '@wordpress/i18n';
|
|
527
|
-
import { PluginPostPublishPanel } from '@wordpress/
|
|
679
|
+
import { PluginPostPublishPanel } from '@wordpress/editor';
|
|
528
680
|
|
|
529
681
|
const MyPluginPostPublishPanel = () => (
|
|
530
682
|
<PluginPostPublishPanel
|
|
@@ -550,6 +702,50 @@ _Returns_
|
|
|
550
702
|
|
|
551
703
|
- `Component`: The component to be rendered.
|
|
552
704
|
|
|
705
|
+
### PluginPostStatusInfo
|
|
706
|
+
|
|
707
|
+
Renders a row in the Summary panel of the Document sidebar. It should be noted that this is named and implemented around the function it serves and not its location, which may change in future iterations.
|
|
708
|
+
|
|
709
|
+
_Usage_
|
|
710
|
+
|
|
711
|
+
```js
|
|
712
|
+
// Using ES5 syntax
|
|
713
|
+
var __ = wp.i18n.__;
|
|
714
|
+
var PluginPostStatusInfo = wp.editor.PluginPostStatusInfo;
|
|
715
|
+
|
|
716
|
+
function MyPluginPostStatusInfo() {
|
|
717
|
+
return React.createElement(
|
|
718
|
+
PluginPostStatusInfo,
|
|
719
|
+
{
|
|
720
|
+
className: 'my-plugin-post-status-info',
|
|
721
|
+
},
|
|
722
|
+
__( 'My post status info' )
|
|
723
|
+
);
|
|
724
|
+
}
|
|
725
|
+
```
|
|
726
|
+
|
|
727
|
+
```jsx
|
|
728
|
+
// Using ESNext syntax
|
|
729
|
+
import { __ } from '@wordpress/i18n';
|
|
730
|
+
import { PluginPostStatusInfo } from '@wordpress/editor';
|
|
731
|
+
|
|
732
|
+
const MyPluginPostStatusInfo = () => (
|
|
733
|
+
<PluginPostStatusInfo className="my-plugin-post-status-info">
|
|
734
|
+
{ __( 'My post status info' ) }
|
|
735
|
+
</PluginPostStatusInfo>
|
|
736
|
+
);
|
|
737
|
+
```
|
|
738
|
+
|
|
739
|
+
_Parameters_
|
|
740
|
+
|
|
741
|
+
- _props_ `Object`: Component properties.
|
|
742
|
+
- _props.className_ `[string]`: An optional class name added to the row.
|
|
743
|
+
- _props.children_ `Element`: Children to be rendered.
|
|
744
|
+
|
|
745
|
+
_Returns_
|
|
746
|
+
|
|
747
|
+
- `Component`: The component to be rendered.
|
|
748
|
+
|
|
553
749
|
### PluginPrePublishPanel
|
|
554
750
|
|
|
555
751
|
Renders provided content to the pre-publish side panel in the publish flow (side panel that opens when a user first pushes "Publish" from the main editor).
|
|
@@ -559,7 +755,7 @@ _Usage_
|
|
|
559
755
|
```jsx
|
|
560
756
|
// Using ESNext syntax
|
|
561
757
|
import { __ } from '@wordpress/i18n';
|
|
562
|
-
import { PluginPrePublishPanel } from '@wordpress/
|
|
758
|
+
import { PluginPrePublishPanel } from '@wordpress/editor';
|
|
563
759
|
|
|
564
760
|
const MyPluginPrePublishPanel = () => (
|
|
565
761
|
<PluginPrePublishPanel
|
|
@@ -585,17 +781,141 @@ _Returns_
|
|
|
585
781
|
|
|
586
782
|
- `Component`: The component to be rendered.
|
|
587
783
|
|
|
784
|
+
### PluginSidebar
|
|
785
|
+
|
|
786
|
+
Renders a sidebar when activated. The contents within the `PluginSidebar` will appear as content within the sidebar. It also automatically renders a corresponding `PluginSidebarMenuItem` component when `isPinnable` flag is set to `true`. If you wish to display the sidebar, you can with use the `PluginSidebarMoreMenuItem` component or the `wp.data.dispatch` API:
|
|
787
|
+
|
|
788
|
+
```js
|
|
789
|
+
wp.data
|
|
790
|
+
.dispatch( 'core/edit-post' )
|
|
791
|
+
.openGeneralSidebar( 'plugin-name/sidebar-name' );
|
|
792
|
+
```
|
|
793
|
+
|
|
794
|
+
_Related_
|
|
795
|
+
|
|
796
|
+
- PluginSidebarMoreMenuItem
|
|
797
|
+
|
|
798
|
+
_Usage_
|
|
799
|
+
|
|
800
|
+
```js
|
|
801
|
+
// Using ES5 syntax
|
|
802
|
+
var __ = wp.i18n.__;
|
|
803
|
+
var el = React.createElement;
|
|
804
|
+
var PanelBody = wp.components.PanelBody;
|
|
805
|
+
var PluginSidebar = wp.editor.PluginSidebar;
|
|
806
|
+
var moreIcon = React.createElement( 'svg' ); //... svg element.
|
|
807
|
+
|
|
808
|
+
function MyPluginSidebar() {
|
|
809
|
+
return el(
|
|
810
|
+
PluginSidebar,
|
|
811
|
+
{
|
|
812
|
+
name: 'my-sidebar',
|
|
813
|
+
title: 'My sidebar title',
|
|
814
|
+
icon: moreIcon,
|
|
815
|
+
},
|
|
816
|
+
el( PanelBody, {}, __( 'My sidebar content' ) )
|
|
817
|
+
);
|
|
818
|
+
}
|
|
819
|
+
```
|
|
820
|
+
|
|
821
|
+
```jsx
|
|
822
|
+
// Using ESNext syntax
|
|
823
|
+
import { __ } from '@wordpress/i18n';
|
|
824
|
+
import { PanelBody } from '@wordpress/components';
|
|
825
|
+
import { PluginSidebar } from '@wordpress/editor';
|
|
826
|
+
import { more } from '@wordpress/icons';
|
|
827
|
+
|
|
828
|
+
const MyPluginSidebar = () => (
|
|
829
|
+
<PluginSidebar name="my-sidebar" title="My sidebar title" icon={ more }>
|
|
830
|
+
<PanelBody>{ __( 'My sidebar content' ) }</PanelBody>
|
|
831
|
+
</PluginSidebar>
|
|
832
|
+
);
|
|
833
|
+
```
|
|
834
|
+
|
|
835
|
+
_Parameters_
|
|
836
|
+
|
|
837
|
+
- _props_ `Object`: Element props.
|
|
838
|
+
- _props.name_ `string`: A string identifying the sidebar. Must be unique for every sidebar registered within the scope of your plugin.
|
|
839
|
+
- _props.className_ `[string]`: An optional class name added to the sidebar body.
|
|
840
|
+
- _props.title_ `string`: Title displayed at the top of the sidebar.
|
|
841
|
+
- _props.isPinnable_ `[boolean]`: Whether to allow to pin sidebar to the toolbar. When set to `true` it also automatically renders a corresponding menu item.
|
|
842
|
+
- _props.icon_ `[WPBlockTypeIconRender]`: The [Dashicon](https://developer.wordpress.org/resource/dashicons/) icon slug string, or an SVG WP element, to be rendered when the sidebar is pinned to toolbar.
|
|
843
|
+
|
|
844
|
+
### PluginSidebarMoreMenuItem
|
|
845
|
+
|
|
846
|
+
Renders a menu item in `Plugins` group in `More Menu` drop down, and can be used to activate the corresponding `PluginSidebar` component. The text within the component appears as the menu item label.
|
|
847
|
+
|
|
848
|
+
_Usage_
|
|
849
|
+
|
|
850
|
+
```js
|
|
851
|
+
// Using ES5 syntax
|
|
852
|
+
var __ = wp.i18n.__;
|
|
853
|
+
var PluginSidebarMoreMenuItem = wp.editor.PluginSidebarMoreMenuItem;
|
|
854
|
+
var moreIcon = React.createElement( 'svg' ); //... svg element.
|
|
855
|
+
|
|
856
|
+
function MySidebarMoreMenuItem() {
|
|
857
|
+
return React.createElement(
|
|
858
|
+
PluginSidebarMoreMenuItem,
|
|
859
|
+
{
|
|
860
|
+
target: 'my-sidebar',
|
|
861
|
+
icon: moreIcon,
|
|
862
|
+
},
|
|
863
|
+
__( 'My sidebar title' )
|
|
864
|
+
);
|
|
865
|
+
}
|
|
866
|
+
```
|
|
867
|
+
|
|
868
|
+
```jsx
|
|
869
|
+
// Using ESNext syntax
|
|
870
|
+
import { __ } from '@wordpress/i18n';
|
|
871
|
+
import { PluginSidebarMoreMenuItem } from '@wordpress/editor';
|
|
872
|
+
import { more } from '@wordpress/icons';
|
|
873
|
+
|
|
874
|
+
const MySidebarMoreMenuItem = () => (
|
|
875
|
+
<PluginSidebarMoreMenuItem target="my-sidebar" icon={ more }>
|
|
876
|
+
{ __( 'My sidebar title' ) }
|
|
877
|
+
</PluginSidebarMoreMenuItem>
|
|
878
|
+
);
|
|
879
|
+
```
|
|
880
|
+
|
|
881
|
+
_Parameters_
|
|
882
|
+
|
|
883
|
+
- _props_ `Object`: Component props.
|
|
884
|
+
- _props.target_ `string`: A string identifying the target sidebar you wish to be activated by this menu item. Must be the same as the `name` prop you have given to that sidebar.
|
|
885
|
+
- _props.icon_ `[WPBlockTypeIconRender]`: The [Dashicon](https://developer.wordpress.org/resource/dashicons/) icon slug string, or an SVG WP element, to be rendered to the left of the menu item label.
|
|
886
|
+
|
|
887
|
+
_Returns_
|
|
888
|
+
|
|
889
|
+
- `Component`: The component to be rendered.
|
|
890
|
+
|
|
588
891
|
### PostAuthor
|
|
589
892
|
|
|
590
|
-
|
|
893
|
+
Renders the component for selecting the post author.
|
|
894
|
+
|
|
895
|
+
_Returns_
|
|
896
|
+
|
|
897
|
+
- `Component`: The component to be rendered.
|
|
591
898
|
|
|
592
899
|
### PostAuthorCheck
|
|
593
900
|
|
|
594
|
-
|
|
901
|
+
Wrapper component that renders its children only if the post type supports the author.
|
|
902
|
+
|
|
903
|
+
_Parameters_
|
|
904
|
+
|
|
905
|
+
- _props_ `Object`: The component props.
|
|
906
|
+
- _props.children_ `Element`: Children to be rendered.
|
|
907
|
+
|
|
908
|
+
_Returns_
|
|
909
|
+
|
|
910
|
+
- `Component|null`: The component to be rendered. Return `null` if the post type doesn't supports the author or if there are no authors available.
|
|
595
911
|
|
|
596
912
|
### PostAuthorPanel
|
|
597
913
|
|
|
598
|
-
|
|
914
|
+
Renders the Post Author Panel component.
|
|
915
|
+
|
|
916
|
+
_Returns_
|
|
917
|
+
|
|
918
|
+
- `Component`: The component to be rendered.
|
|
599
919
|
|
|
600
920
|
### PostComments
|
|
601
921
|
|
|
@@ -607,11 +927,26 @@ Undocumented declaration.
|
|
|
607
927
|
|
|
608
928
|
### PostExcerpt
|
|
609
929
|
|
|
610
|
-
|
|
930
|
+
Renders an editable textarea for the post excerpt. Templates, template parts and patterns use the `excerpt` field as a description semantically. Additionally templates and template parts override the `excerpt` field as `description` in REST API. So this component handles proper labeling and updating the edited entity.
|
|
931
|
+
|
|
932
|
+
_Parameters_
|
|
933
|
+
|
|
934
|
+
- _props_ `Object`: - Component props.
|
|
935
|
+
- _props.hideLabelFromVision_ `[boolean]`: - Whether to visually hide the textarea's label.
|
|
936
|
+
- _props.updateOnBlur_ `[boolean]`: - Whether to update the post on change or use local state and update on blur.
|
|
611
937
|
|
|
612
938
|
### PostExcerptCheck
|
|
613
939
|
|
|
614
|
-
|
|
940
|
+
Component for checking if the post type supports the excerpt field.
|
|
941
|
+
|
|
942
|
+
_Parameters_
|
|
943
|
+
|
|
944
|
+
- _props_ `Object`: Props.
|
|
945
|
+
- _props.children_ `Element`: Children to be rendered.
|
|
946
|
+
|
|
947
|
+
_Returns_
|
|
948
|
+
|
|
949
|
+
- `Component`: The component to be rendered.
|
|
615
950
|
|
|
616
951
|
### PostExcerptPanel
|
|
617
952
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_blocks","require","_data","_lockUnlock","_patternOverrides","_interopRequireDefault","_postMeta","registerBlockBindingsSource","unlock","dispatch","blocksStore","postMeta","process","env","IS_GUTENBERG_PLUGIN","patternOverrides"],"sources":["@wordpress/editor/src/bindings/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { store as blocksStore } from '@wordpress/blocks';\nimport { dispatch } from '@wordpress/data';\n/**\n * Internal dependencies\n */\nimport { unlock } from '../lock-unlock';\nimport patternOverrides from './pattern-overrides';\nimport postMeta from './post-meta';\n\nconst { registerBlockBindingsSource } = unlock( dispatch( blocksStore ) );\nregisterBlockBindingsSource( postMeta );\n\nif ( process.env.IS_GUTENBERG_PLUGIN ) {\n\tregisterBlockBindingsSource( patternOverrides );\n}\n"],"mappings":";;;AAGA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAIA,IAAAE,WAAA,GAAAF,OAAA;AACA,IAAAG,iBAAA,GAAAC,sBAAA,CAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAD,sBAAA,CAAAJ,OAAA;AAVA;AACA;AACA;;AAGA;AACA;AACA;;AAKA,MAAM;EAAEM;AAA4B,CAAC,GAAG,IAAAC,kBAAM,EAAE,IAAAC,cAAQ,EAAEC,aAAY,CAAE,CAAC;AACzEH,2BAA2B,CAAEI,iBAAS,CAAC;AAEvC,IAAKC,OAAO,CAACC,GAAG,CAACC,mBAAmB,EAAG;EACtCP,2BAA2B,CAAEQ,yBAAiB,CAAC;AAChD"}
|
|
1
|
+
{"version":3,"names":["_blocks","require","_data","_lockUnlock","_patternOverrides","_interopRequireDefault","_postMeta","registerBlockBindingsSource","unlock","dispatch","blocksStore","postMeta","process","env","IS_GUTENBERG_PLUGIN","patternOverrides"],"sources":["@wordpress/editor/src/bindings/index.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { store as blocksStore } from '@wordpress/blocks';\nimport { dispatch } from '@wordpress/data';\n/**\n * Internal dependencies\n */\nimport { unlock } from '../lock-unlock';\nimport patternOverrides from './pattern-overrides';\nimport postMeta from './post-meta';\n\nconst { registerBlockBindingsSource } = unlock( dispatch( blocksStore ) );\nregisterBlockBindingsSource( postMeta );\n\nif ( process.env.IS_GUTENBERG_PLUGIN ) {\n\tregisterBlockBindingsSource( patternOverrides );\n}\n"],"mappings":";;;AAGA,IAAAA,OAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAIA,IAAAE,WAAA,GAAAF,OAAA;AACA,IAAAG,iBAAA,GAAAC,sBAAA,CAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAD,sBAAA,CAAAJ,OAAA;AAVA;AACA;AACA;;AAGA;AACA;AACA;;AAKA,MAAM;EAAEM;AAA4B,CAAC,GAAG,IAAAC,kBAAM,EAAE,IAAAC,cAAQ,EAAEC,aAAY,CAAE,CAAC;AACzEH,2BAA2B,CAAEI,iBAAS,CAAC;AAEvC,IAAKC,OAAO,CAACC,GAAG,CAACC,mBAAmB,EAAG;EACtCP,2BAA2B,CAAEQ,yBAAiB,CAAC;AAChD","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_i18n","require","_default","exports","default","name","label","_x","useSource","lockAttributesEditing"],"sources":["@wordpress/editor/src/bindings/pattern-overrides.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { _x } from '@wordpress/i18n';\n\nexport default {\n\tname: 'core/pattern-overrides',\n\tlabel: _x( 'Pattern Overrides', 'block bindings source' ),\n\tuseSource: null,\n\tlockAttributesEditing: false,\n};\n"],"mappings":";;;;;;AAGA,IAAAA,KAAA,GAAAC,OAAA;AAHA;AACA;AACA;AAFA,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAKe;EACdC,IAAI,EAAE,wBAAwB;EAC9BC,KAAK,EAAE,IAAAC,QAAE,EAAE,mBAAmB,EAAE,uBAAwB,CAAC;EACzDC,SAAS,EAAE,IAAI;EACfC,qBAAqB,EAAE;AACxB,CAAC"}
|
|
1
|
+
{"version":3,"names":["_i18n","require","_default","exports","default","name","label","_x","useSource","lockAttributesEditing"],"sources":["@wordpress/editor/src/bindings/pattern-overrides.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { _x } from '@wordpress/i18n';\n\nexport default {\n\tname: 'core/pattern-overrides',\n\tlabel: _x( 'Pattern Overrides', 'block bindings source' ),\n\tuseSource: null,\n\tlockAttributesEditing: false,\n};\n"],"mappings":";;;;;;AAGA,IAAAA,KAAA,GAAAC,OAAA;AAHA;AACA;AACA;AAFA,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAKe;EACdC,IAAI,EAAE,wBAAwB;EAC9BC,KAAK,EAAE,IAAAC,QAAE,EAAE,mBAAmB,EAAE,uBAAwB,CAAC;EACzDC,SAAS,EAAE,IAAI;EACfC,qBAAqB,EAAE;AACxB,CAAC","ignoreList":[]}
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.default = void 0;
|
|
7
7
|
var _coreData = require("@wordpress/core-data");
|
|
8
|
-
var _data = require("@wordpress/data");
|
|
9
8
|
var _i18n = require("@wordpress/i18n");
|
|
10
9
|
var _store = require("../store");
|
|
11
10
|
/**
|
|
@@ -17,35 +16,18 @@ var _store = require("../store");
|
|
|
17
16
|
var _default = exports.default = {
|
|
18
17
|
name: 'core/post-meta',
|
|
19
18
|
label: (0, _i18n._x)('Post Meta', 'block bindings source'),
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
const postType = context.postType ? context.postType : getCurrentPostType();
|
|
31
|
-
|
|
32
|
-
if (postType === 'wp_template') {
|
|
33
|
-
return {
|
|
34
|
-
placeholder: metaKey
|
|
35
|
-
};
|
|
36
|
-
}
|
|
37
|
-
const metaValue = meta[metaKey];
|
|
38
|
-
const updateMetaValue = newValue => {
|
|
39
|
-
setMeta({
|
|
40
|
-
...meta,
|
|
41
|
-
[metaKey]: newValue
|
|
42
|
-
});
|
|
43
|
-
};
|
|
44
|
-
return {
|
|
45
|
-
placeholder: metaKey,
|
|
46
|
-
value: metaValue,
|
|
47
|
-
updateValue: updateMetaValue
|
|
48
|
-
};
|
|
19
|
+
getPlaceholder({
|
|
20
|
+
args
|
|
21
|
+
}) {
|
|
22
|
+
return args.key;
|
|
23
|
+
},
|
|
24
|
+
getValue({
|
|
25
|
+
registry,
|
|
26
|
+
context,
|
|
27
|
+
args
|
|
28
|
+
}) {
|
|
29
|
+
const postType = context.postType ? context.postType : registry.select(_store.store).getCurrentPostType();
|
|
30
|
+
return registry.select(_coreData.store).getEditedEntityRecord('postType', postType, context.postId).meta?.[args.key];
|
|
49
31
|
}
|
|
50
32
|
};
|
|
51
33
|
//# sourceMappingURL=post-meta.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_coreData","require","
|
|
1
|
+
{"version":3,"names":["_coreData","require","_i18n","_store","_default","exports","default","name","label","_x","getPlaceholder","args","key","getValue","registry","context","postType","select","editorStore","getCurrentPostType","coreDataStore","getEditedEntityRecord","postId","meta"],"sources":["@wordpress/editor/src/bindings/post-meta.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { store as coreDataStore } from '@wordpress/core-data';\nimport { _x } from '@wordpress/i18n';\n\n/**\n * Internal dependencies\n */\nimport { store as editorStore } from '../store';\n\nexport default {\n\tname: 'core/post-meta',\n\tlabel: _x( 'Post Meta', 'block bindings source' ),\n\tgetPlaceholder( { args } ) {\n\t\treturn args.key;\n\t},\n\tgetValue( { registry, context, args } ) {\n\t\tconst postType = context.postType\n\t\t\t? context.postType\n\t\t\t: registry.select( editorStore ).getCurrentPostType();\n\n\t\treturn registry\n\t\t\t.select( coreDataStore )\n\t\t\t.getEditedEntityRecord( 'postType', postType, context.postId )\n\t\t\t.meta?.[ args.key ];\n\t},\n};\n"],"mappings":";;;;;;AAGA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAKA,IAAAE,MAAA,GAAAF,OAAA;AATA;AACA;AACA;AAIA;AACA;AACA;AAFA,IAAAG,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAKe;EACdC,IAAI,EAAE,gBAAgB;EACtBC,KAAK,EAAE,IAAAC,QAAE,EAAE,WAAW,EAAE,uBAAwB,CAAC;EACjDC,cAAcA,CAAE;IAAEC;EAAK,CAAC,EAAG;IAC1B,OAAOA,IAAI,CAACC,GAAG;EAChB,CAAC;EACDC,QAAQA,CAAE;IAAEC,QAAQ;IAAEC,OAAO;IAAEJ;EAAK,CAAC,EAAG;IACvC,MAAMK,QAAQ,GAAGD,OAAO,CAACC,QAAQ,GAC9BD,OAAO,CAACC,QAAQ,GAChBF,QAAQ,CAACG,MAAM,CAAEC,YAAY,CAAC,CAACC,kBAAkB,CAAC,CAAC;IAEtD,OAAOL,QAAQ,CACbG,MAAM,CAAEG,eAAc,CAAC,CACvBC,qBAAqB,CAAE,UAAU,EAAEL,QAAQ,EAAED,OAAO,CAACO,MAAO,CAAC,CAC7DC,IAAI,GAAIZ,IAAI,CAACC,GAAG,CAAE;EACrB;AACD,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_user","_interopRequireDefault","require"],"sources":["@wordpress/editor/src/components/autocompleters/index.js"],"sourcesContent":["export { default as userAutocompleter } from './user';\n"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,KAAA,GAAAC,sBAAA,CAAAC,OAAA"}
|
|
1
|
+
{"version":3,"names":["_user","_interopRequireDefault","require"],"sources":["@wordpress/editor/src/components/autocompleters/index.js"],"sourcesContent":["export { default as userAutocompleter } from './user';\n"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,KAAA,GAAAC,sBAAA,CAAAC,OAAA","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_element","require","_data","_coreData","getUserLabel","user","avatar","avatar_urls","_react","createElement","className","alt","src","Fragment","name","slug","_default","exports","default","triggerPrefix","useItems","filterValue","users","useSelect","select","getUsers","coreStore","context","search","encodeURIComponent","options","useMemo","map","key","value","label","getOptionCompletion"],"sources":["@wordpress/editor/src/components/autocompleters/user.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useMemo } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/** @typedef {import('@wordpress/components').WPCompleter} WPCompleter */\n\nexport function getUserLabel( user ) {\n\tconst avatar =\n\t\tuser.avatar_urls && user.avatar_urls[ 24 ] ? (\n\t\t\t<img\n\t\t\t\tclassName=\"editor-autocompleters__user-avatar\"\n\t\t\t\talt=\"\"\n\t\t\t\tsrc={ user.avatar_urls[ 24 ] }\n\t\t\t/>\n\t\t) : (\n\t\t\t<span className=\"editor-autocompleters__no-avatar\"></span>\n\t\t);\n\n\treturn (\n\t\t<>\n\t\t\t{ avatar }\n\t\t\t<span className=\"editor-autocompleters__user-name\">\n\t\t\t\t{ user.name }\n\t\t\t</span>\n\t\t\t<span className=\"editor-autocompleters__user-slug\">\n\t\t\t\t{ user.slug }\n\t\t\t</span>\n\t\t</>\n\t);\n}\n\n/**\n * A user mentions completer.\n *\n * @type {WPCompleter}\n */\nexport default {\n\tname: 'users',\n\tclassName: 'editor-autocompleters__user',\n\ttriggerPrefix: '@',\n\n\tuseItems( filterValue ) {\n\t\tconst users = useSelect(\n\t\t\t( select ) => {\n\t\t\t\tconst { getUsers } = select( coreStore );\n\t\t\t\treturn getUsers( {\n\t\t\t\t\tcontext: 'view',\n\t\t\t\t\tsearch: encodeURIComponent( filterValue ),\n\t\t\t\t} );\n\t\t\t},\n\t\t\t[ filterValue ]\n\t\t);\n\n\t\tconst options = useMemo(\n\t\t\t() =>\n\t\t\t\tusers\n\t\t\t\t\t? users.map( ( user ) => ( {\n\t\t\t\t\t\t\tkey: `user-${ user.slug }`,\n\t\t\t\t\t\t\tvalue: user,\n\t\t\t\t\t\t\tlabel: getUserLabel( user ),\n\t\t\t\t\t } ) )\n\t\t\t\t\t: [],\n\t\t\t[ users ]\n\t\t);\n\n\t\treturn [ options ];\n\t},\n\n\tgetOptionCompletion( user ) {\n\t\treturn `@${ user.slug }`;\n\t},\n};\n"],"mappings":";;;;;;;;AAGA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AALA;AACA;AACA;;AAKA;;AAEO,SAASG,YAAYA,CAAEC,IAAI,EAAG;EACpC,MAAMC,MAAM,GACXD,IAAI,CAACE,WAAW,IAAIF,IAAI,CAACE,WAAW,CAAE,EAAE,CAAE,GACzC,IAAAC,MAAA,CAAAC,aAAA;IACCC,SAAS,EAAC,oCAAoC;IAC9CC,GAAG,EAAC,EAAE;IACNC,GAAG,EAAGP,IAAI,CAACE,WAAW,CAAE,EAAE;EAAI,CAC9B,CAAC,GAEF,IAAAC,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,CAAO,CACzD;EAEF,OACC,IAAAF,MAAA,CAAAC,aAAA,EAAAD,MAAA,CAAAK,QAAA,QACGP,MAAM,EACR,IAAAE,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,GAC/CL,IAAI,CAACS,IACF,CAAC,EACP,IAAAN,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,GAC/CL,IAAI,CAACU,IACF,CACL,CAAC;AAEL;;AAEA;AACA;AACA;AACA;AACA;AAJA,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAKe;EACdJ,IAAI,EAAE,OAAO;EACbJ,SAAS,EAAE,6BAA6B;EACxCS,aAAa,EAAE,GAAG;EAElBC,QAAQA,CAAEC,WAAW,EAAG;IACvB,MAAMC,KAAK,GAAG,IAAAC,eAAS,EACpBC,MAAM,IAAM;MACb,MAAM;QAAEC;MAAS,CAAC,GAAGD,MAAM,CAAEE,eAAU,CAAC;MACxC,OAAOD,QAAQ,CAAE;QAChBE,OAAO,EAAE,MAAM;QACfC,MAAM,EAAEC,kBAAkB,CAAER,WAAY;MACzC,CAAE,CAAC;IACJ,CAAC,EACD,CAAEA,WAAW,CACd,CAAC;IAED,MAAMS,OAAO,GAAG,IAAAC,gBAAO,EACtB,MACCT,KAAK,GACFA,KAAK,CAACU,GAAG,CAAI3B,IAAI,KAAQ;MACzB4B,GAAG,EAAG,QAAQ5B,IAAI,CAACU,IAAM,EAAC;MAC1BmB,KAAK,EAAE7B,IAAI;MACX8B,KAAK,EAAE/B,YAAY,CAAEC,IAAK;IAC1B,CAAC,CAAG,CAAC,GACL,EAAE,EACN,CAAEiB,KAAK,CACR,CAAC;IAED,OAAO,CAAEQ,OAAO,CAAE;EACnB,CAAC;EAEDM,mBAAmBA,CAAE/B,IAAI,EAAG;IAC3B,OAAQ,IAAIA,IAAI,CAACU,IAAM,EAAC;EACzB;AACD,CAAC"}
|
|
1
|
+
{"version":3,"names":["_element","require","_data","_coreData","getUserLabel","user","avatar","avatar_urls","_react","createElement","className","alt","src","Fragment","name","slug","_default","exports","default","triggerPrefix","useItems","filterValue","users","useSelect","select","getUsers","coreStore","context","search","encodeURIComponent","options","useMemo","map","key","value","label","getOptionCompletion"],"sources":["@wordpress/editor/src/components/autocompleters/user.js"],"sourcesContent":["/**\n * WordPress dependencies\n */\nimport { useMemo } from '@wordpress/element';\nimport { useSelect } from '@wordpress/data';\nimport { store as coreStore } from '@wordpress/core-data';\n\n/** @typedef {import('@wordpress/components').WPCompleter} WPCompleter */\n\nexport function getUserLabel( user ) {\n\tconst avatar =\n\t\tuser.avatar_urls && user.avatar_urls[ 24 ] ? (\n\t\t\t<img\n\t\t\t\tclassName=\"editor-autocompleters__user-avatar\"\n\t\t\t\talt=\"\"\n\t\t\t\tsrc={ user.avatar_urls[ 24 ] }\n\t\t\t/>\n\t\t) : (\n\t\t\t<span className=\"editor-autocompleters__no-avatar\"></span>\n\t\t);\n\n\treturn (\n\t\t<>\n\t\t\t{ avatar }\n\t\t\t<span className=\"editor-autocompleters__user-name\">\n\t\t\t\t{ user.name }\n\t\t\t</span>\n\t\t\t<span className=\"editor-autocompleters__user-slug\">\n\t\t\t\t{ user.slug }\n\t\t\t</span>\n\t\t</>\n\t);\n}\n\n/**\n * A user mentions completer.\n *\n * @type {WPCompleter}\n */\nexport default {\n\tname: 'users',\n\tclassName: 'editor-autocompleters__user',\n\ttriggerPrefix: '@',\n\n\tuseItems( filterValue ) {\n\t\tconst users = useSelect(\n\t\t\t( select ) => {\n\t\t\t\tconst { getUsers } = select( coreStore );\n\t\t\t\treturn getUsers( {\n\t\t\t\t\tcontext: 'view',\n\t\t\t\t\tsearch: encodeURIComponent( filterValue ),\n\t\t\t\t} );\n\t\t\t},\n\t\t\t[ filterValue ]\n\t\t);\n\n\t\tconst options = useMemo(\n\t\t\t() =>\n\t\t\t\tusers\n\t\t\t\t\t? users.map( ( user ) => ( {\n\t\t\t\t\t\t\tkey: `user-${ user.slug }`,\n\t\t\t\t\t\t\tvalue: user,\n\t\t\t\t\t\t\tlabel: getUserLabel( user ),\n\t\t\t\t\t } ) )\n\t\t\t\t\t: [],\n\t\t\t[ users ]\n\t\t);\n\n\t\treturn [ options ];\n\t},\n\n\tgetOptionCompletion( user ) {\n\t\treturn `@${ user.slug }`;\n\t},\n};\n"],"mappings":";;;;;;;;AAGA,IAAAA,QAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AACA,IAAAE,SAAA,GAAAF,OAAA;AALA;AACA;AACA;;AAKA;;AAEO,SAASG,YAAYA,CAAEC,IAAI,EAAG;EACpC,MAAMC,MAAM,GACXD,IAAI,CAACE,WAAW,IAAIF,IAAI,CAACE,WAAW,CAAE,EAAE,CAAE,GACzC,IAAAC,MAAA,CAAAC,aAAA;IACCC,SAAS,EAAC,oCAAoC;IAC9CC,GAAG,EAAC,EAAE;IACNC,GAAG,EAAGP,IAAI,CAACE,WAAW,CAAE,EAAE;EAAI,CAC9B,CAAC,GAEF,IAAAC,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,CAAO,CACzD;EAEF,OACC,IAAAF,MAAA,CAAAC,aAAA,EAAAD,MAAA,CAAAK,QAAA,QACGP,MAAM,EACR,IAAAE,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,GAC/CL,IAAI,CAACS,IACF,CAAC,EACP,IAAAN,MAAA,CAAAC,aAAA;IAAMC,SAAS,EAAC;EAAkC,GAC/CL,IAAI,CAACU,IACF,CACL,CAAC;AAEL;;AAEA;AACA;AACA;AACA;AACA;AAJA,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAKe;EACdJ,IAAI,EAAE,OAAO;EACbJ,SAAS,EAAE,6BAA6B;EACxCS,aAAa,EAAE,GAAG;EAElBC,QAAQA,CAAEC,WAAW,EAAG;IACvB,MAAMC,KAAK,GAAG,IAAAC,eAAS,EACpBC,MAAM,IAAM;MACb,MAAM;QAAEC;MAAS,CAAC,GAAGD,MAAM,CAAEE,eAAU,CAAC;MACxC,OAAOD,QAAQ,CAAE;QAChBE,OAAO,EAAE,MAAM;QACfC,MAAM,EAAEC,kBAAkB,CAAER,WAAY;MACzC,CAAE,CAAC;IACJ,CAAC,EACD,CAAEA,WAAW,CACd,CAAC;IAED,MAAMS,OAAO,GAAG,IAAAC,gBAAO,EACtB,MACCT,KAAK,GACFA,KAAK,CAACU,GAAG,CAAI3B,IAAI,KAAQ;MACzB4B,GAAG,EAAG,QAAQ5B,IAAI,CAACU,IAAM,EAAC;MAC1BmB,KAAK,EAAE7B,IAAI;MACX8B,KAAK,EAAE/B,YAAY,CAAEC,IAAK;IAC1B,CAAC,CAAG,CAAC,GACL,EAAE,EACN,CAAEiB,KAAK,CACR,CAAC;IAED,OAAO,CAAEQ,OAAO,CAAE;EACnB,CAAC;EAEDM,mBAAmBA,CAAE/B,IAAI,EAAG;IAC3B,OAAQ,IAAIA,IAAI,CAACU,IAAM,EAAC;EACzB;AACD,CAAC","ignoreList":[]}
|
|
@@ -17,17 +17,6 @@ var _store = require("../../store");
|
|
|
17
17
|
* Internal dependencies
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
|
-
/**
|
|
21
|
-
* AutosaveMonitor invokes `props.autosave()` within at most `interval` seconds after an unsaved change is detected.
|
|
22
|
-
*
|
|
23
|
-
* The logic is straightforward: a check is performed every `props.interval` seconds. If any changes are detected, `props.autosave()` is called.
|
|
24
|
-
* The time between the change and the autosave varies but is no larger than `props.interval` seconds. Refer to the code below for more details, such as
|
|
25
|
-
* the specific way of detecting changes.
|
|
26
|
-
*
|
|
27
|
-
* There are two caveats:
|
|
28
|
-
* * If `props.isAutosaveable` happens to be false at a time of checking for changes, the check is retried every second.
|
|
29
|
-
* * The timer may be disabled by setting `props.disableIntervalChecks` to `true`. In that mode, any change will immediately trigger `props.autosave()`.
|
|
30
|
-
*/
|
|
31
20
|
class AutosaveMonitor extends _element.Component {
|
|
32
21
|
constructor(props) {
|
|
33
22
|
super(props);
|
|
@@ -84,6 +73,30 @@ class AutosaveMonitor extends _element.Component {
|
|
|
84
73
|
return null;
|
|
85
74
|
}
|
|
86
75
|
}
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* Monitors the changes made to the edited post and triggers autosave if necessary.
|
|
79
|
+
*
|
|
80
|
+
* The logic is straightforward: a check is performed every `props.interval` seconds. If any changes are detected, `props.autosave()` is called.
|
|
81
|
+
* The time between the change and the autosave varies but is no larger than `props.interval` seconds. Refer to the code below for more details, such as
|
|
82
|
+
* the specific way of detecting changes.
|
|
83
|
+
*
|
|
84
|
+
* There are two caveats:
|
|
85
|
+
* * If `props.isAutosaveable` happens to be false at a time of checking for changes, the check is retried every second.
|
|
86
|
+
* * The timer may be disabled by setting `props.disableIntervalChecks` to `true`. In that mode, any change will immediately trigger `props.autosave()`.
|
|
87
|
+
*
|
|
88
|
+
* @param {Object} props - The properties passed to the component.
|
|
89
|
+
* @param {Function} props.autosave - The function to call when changes need to be saved.
|
|
90
|
+
* @param {number} props.interval - The maximum time in seconds between an unsaved change and an autosave.
|
|
91
|
+
* @param {boolean} props.isAutosaveable - If false, the check for changes is retried every second.
|
|
92
|
+
* @param {boolean} props.disableIntervalChecks - If true, disables the timer and any change will immediately trigger `props.autosave()`.
|
|
93
|
+
* @param {boolean} props.isDirty - Indicates if there are unsaved changes.
|
|
94
|
+
*
|
|
95
|
+
* @example
|
|
96
|
+
* ```jsx
|
|
97
|
+
* <AutosaveMonitor interval={30000} />
|
|
98
|
+
* ```
|
|
99
|
+
*/
|
|
87
100
|
exports.AutosaveMonitor = AutosaveMonitor;
|
|
88
101
|
var _default = exports.default = (0, _compose.compose)([(0, _data.withSelect)((select, ownProps) => {
|
|
89
102
|
const {
|