@wordpress/edit-site 6.34.0 → 6.35.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 +2 -0
- package/build/components/add-new-pattern/index.js +6 -4
- package/build/components/add-new-pattern/index.js.map +1 -1
- package/build/components/add-new-post/index.js +3 -1
- package/build/components/add-new-post/index.js.map +1 -1
- package/build/components/add-new-template/add-custom-generic-template-modal-content.js +3 -1
- package/build/components/add-new-template/add-custom-generic-template-modal-content.js.map +1 -1
- package/build/components/add-new-template/add-custom-template-modal-content.js +4 -2
- package/build/components/add-new-template/add-custom-template-modal-content.js.map +1 -1
- package/build/components/add-new-template/index.js +7 -5
- package/build/components/add-new-template/index.js.map +1 -1
- package/build/components/add-new-template/utils.js +14 -12
- package/build/components/add-new-template/utils.js.map +1 -1
- package/build/components/app/index.js +4 -2
- package/build/components/app/index.js.map +1 -1
- package/build/components/block-editor/use-editor-iframe-props.js +3 -1
- package/build/components/block-editor/use-editor-iframe-props.js.map +1 -1
- package/build/components/block-editor/use-navigate-to-entity-record.js +3 -1
- package/build/components/block-editor/use-navigate-to-entity-record.js.map +1 -1
- package/build/components/block-editor/use-site-editor-settings.js +3 -1
- package/build/components/block-editor/use-site-editor-settings.js.map +1 -1
- package/build/components/canvas-loader/index.js +5 -3
- package/build/components/canvas-loader/index.js.map +1 -1
- package/build/components/dataviews-actions/index.js +5 -3
- package/build/components/dataviews-actions/index.js.map +1 -1
- package/build/components/editor/index.js +17 -24
- package/build/components/editor/index.js.map +2 -2
- package/build/components/editor/site-preview.js +3 -1
- package/build/components/editor/site-preview.js.map +1 -1
- package/build/components/editor/use-adapt-editor-to-canvas.js +2 -0
- package/build/components/editor/use-adapt-editor-to-canvas.js.map +1 -1
- package/build/components/editor/use-editor-title.js +3 -1
- package/build/components/editor/use-editor-title.js.map +1 -1
- package/build/components/editor/use-resolve-edited-entity.js +5 -3
- package/build/components/editor/use-resolve-edited-entity.js.map +1 -1
- package/build/components/layout/animation.js +3 -1
- package/build/components/layout/animation.js.map +1 -1
- package/build/components/layout/hooks.js +3 -1
- package/build/components/layout/hooks.js.map +1 -1
- package/build/components/layout/index.js +6 -4
- package/build/components/layout/index.js.map +1 -1
- package/build/components/media/index.js +3 -1
- package/build/components/media/index.js.map +1 -1
- package/build/components/more-menu/index.js +4 -2
- package/build/components/more-menu/index.js.map +1 -1
- package/build/components/more-menu/site-export.js +3 -1
- package/build/components/more-menu/site-export.js.map +1 -1
- package/build/components/more-menu/welcome-guide-menu-item.js +3 -1
- package/build/components/more-menu/welcome-guide-menu-item.js.map +1 -1
- package/build/components/page-patterns/actions.js +3 -1
- package/build/components/page-patterns/actions.js.map +1 -1
- package/build/components/page-patterns/delete-category-menu-item.js +4 -2
- package/build/components/page-patterns/delete-category-menu-item.js.map +1 -1
- package/build/components/page-patterns/fields.js +8 -6
- package/build/components/page-patterns/fields.js.map +1 -1
- package/build/components/page-patterns/index.js +10 -8
- package/build/components/page-patterns/index.js.map +2 -2
- package/build/components/page-patterns/rename-category-menu-item.js +4 -2
- package/build/components/page-patterns/rename-category-menu-item.js.map +1 -1
- package/build/components/page-patterns/search-items.js +10 -8
- package/build/components/page-patterns/search-items.js.map +1 -1
- package/build/components/page-patterns/use-pattern-settings.js +2 -0
- package/build/components/page-patterns/use-pattern-settings.js.map +1 -1
- package/build/components/page-patterns/use-patterns.js +8 -6
- package/build/components/page-patterns/use-patterns.js.map +1 -1
- package/build/components/page-patterns/utils.js +3 -1
- package/build/components/page-patterns/utils.js.map +1 -1
- package/build/components/page-templates/fields.js +14 -12
- package/build/components/page-templates/fields.js.map +2 -2
- package/build/components/page-templates/hooks.js +2 -0
- package/build/components/page-templates/hooks.js.map +1 -1
- package/build/components/page-templates/index.js +16 -11
- package/build/components/page-templates/index.js.map +2 -2
- package/build/components/page-templates/view-utils.js +8 -2
- package/build/components/page-templates/view-utils.js.map +2 -2
- package/build/components/pagination/index.js +3 -1
- package/build/components/pagination/index.js.map +1 -1
- package/build/components/plugin-template-setting-panel/index.js +5 -3
- package/build/components/plugin-template-setting-panel/index.js.map +1 -1
- package/build/components/post-edit/index.js +5 -3
- package/build/components/post-edit/index.js.map +1 -1
- package/build/components/post-list/index.js +8 -6
- package/build/components/post-list/index.js.map +1 -1
- package/build/components/post-list/view-utils.js +5 -3
- package/build/components/post-list/view-utils.js.map +1 -1
- package/build/components/resizable-frame/index.js +10 -8
- package/build/components/resizable-frame/index.js.map +1 -1
- package/build/components/routes/use-title.js +3 -1
- package/build/components/routes/use-title.js.map +1 -1
- package/build/components/save-button/index.js +4 -2
- package/build/components/save-button/index.js.map +1 -1
- package/build/components/save-hub/index.js +3 -1
- package/build/components/save-hub/index.js.map +1 -1
- package/build/components/save-keyboard-shortcut/index.js +3 -1
- package/build/components/save-keyboard-shortcut/index.js.map +1 -1
- package/build/components/save-panel/index.js +7 -5
- package/build/components/save-panel/index.js.map +1 -1
- package/build/components/sidebar/index.js +4 -2
- package/build/components/sidebar/index.js.map +1 -1
- package/build/components/sidebar-button/index.js +3 -1
- package/build/components/sidebar-button/index.js.map +1 -1
- package/build/components/sidebar-dataviews/dataview-item.js +4 -2
- package/build/components/sidebar-dataviews/dataview-item.js.map +1 -1
- package/build/components/sidebar-dataviews/index.js +4 -2
- package/build/components/sidebar-dataviews/index.js.map +1 -1
- package/build/components/sidebar-global-styles/index.js +7 -5
- package/build/components/sidebar-global-styles/index.js.map +1 -1
- package/build/components/sidebar-navigation-item/index.js +4 -2
- package/build/components/sidebar-navigation-item/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen/index.js +4 -2
- package/build/components/sidebar-navigation-screen/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-details-footer/index.js +3 -1
- package/build/components/sidebar-navigation-screen-details-footer/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-global-styles/content.js +4 -2
- package/build/components/sidebar-navigation-screen-global-styles/content.js.map +1 -1
- package/build/components/sidebar-navigation-screen-global-styles/index.js +4 -2
- package/build/components/sidebar-navigation-screen-global-styles/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-main/index.js +3 -1
- package/build/components/sidebar-navigation-screen-main/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/delete-confirm-dialog.js +3 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/delete-confirm-dialog.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/index.js +5 -3
- package/build/components/sidebar-navigation-screen-navigation-menu/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/more-menu.js +5 -3
- package/build/components/sidebar-navigation-screen-navigation-menu/more-menu.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/navigation-menu-editor.js +4 -2
- package/build/components/sidebar-navigation-screen-navigation-menu/navigation-menu-editor.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/rename-modal.js +4 -2
- package/build/components/sidebar-navigation-screen-navigation-menu/rename-modal.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js +3 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/use-navigation-menu-handlers.js +3 -1
- package/build/components/sidebar-navigation-screen-navigation-menu/use-navigation-menu-handlers.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/build-navigation-label.js +2 -0
- package/build/components/sidebar-navigation-screen-navigation-menus/build-navigation-label.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/constants.js +3 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/constants.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/index.js +4 -2
- package/build/components/sidebar-navigation-screen-navigation-menus/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/leaf-more-menu.js +5 -3
- package/build/components/sidebar-navigation-screen-navigation-menus/leaf-more-menu.js.map +1 -1
- package/build/components/sidebar-navigation-screen-navigation-menus/navigation-menu-content.js +6 -4
- package/build/components/sidebar-navigation-screen-navigation-menus/navigation-menu-content.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/category-item.js +3 -1
- package/build/components/sidebar-navigation-screen-patterns/category-item.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/index.js +4 -2
- package/build/components/sidebar-navigation-screen-patterns/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/use-default-pattern-categories.js +2 -0
- package/build/components/sidebar-navigation-screen-patterns/use-default-pattern-categories.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/use-pattern-categories.js +2 -0
- package/build/components/sidebar-navigation-screen-patterns/use-pattern-categories.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/use-template-part-areas.js +3 -1
- package/build/components/sidebar-navigation-screen-patterns/use-template-part-areas.js.map +1 -1
- package/build/components/sidebar-navigation-screen-patterns/use-theme-patterns.js +2 -0
- package/build/components/sidebar-navigation-screen-patterns/use-theme-patterns.js.map +1 -1
- package/build/components/sidebar-navigation-screen-templates-browse/content.js +5 -3
- package/build/components/sidebar-navigation-screen-templates-browse/content.js.map +1 -1
- package/build/components/sidebar-navigation-screen-templates-browse/index.js +3 -1
- package/build/components/sidebar-navigation-screen-templates-browse/index.js.map +1 -1
- package/build/components/sidebar-navigation-screen-unsupported/index.js +3 -1
- package/build/components/sidebar-navigation-screen-unsupported/index.js.map +1 -1
- package/build/components/site-editor-routes/home.js +4 -2
- package/build/components/site-editor-routes/home.js.map +1 -1
- package/build/components/site-editor-routes/index.js +3 -1
- package/build/components/site-editor-routes/index.js.map +1 -1
- package/build/components/site-editor-routes/navigation-item.js +5 -3
- package/build/components/site-editor-routes/navigation-item.js.map +1 -1
- package/build/components/site-editor-routes/navigation.js +5 -3
- package/build/components/site-editor-routes/navigation.js.map +1 -1
- package/build/components/site-editor-routes/notfound.js +4 -2
- package/build/components/site-editor-routes/notfound.js.map +1 -1
- package/build/components/site-editor-routes/page-item.js +4 -2
- package/build/components/site-editor-routes/page-item.js.map +1 -1
- package/build/components/site-editor-routes/pages.js +5 -3
- package/build/components/site-editor-routes/pages.js.map +1 -1
- package/build/components/site-editor-routes/pattern-item.js +4 -2
- package/build/components/site-editor-routes/pattern-item.js.map +1 -1
- package/build/components/site-editor-routes/patterns.js +4 -2
- package/build/components/site-editor-routes/patterns.js.map +1 -1
- package/build/components/site-editor-routes/stylebook.js +5 -3
- package/build/components/site-editor-routes/stylebook.js.map +1 -1
- package/build/components/site-editor-routes/styles.js +6 -4
- package/build/components/site-editor-routes/styles.js.map +1 -1
- package/build/components/site-editor-routes/template-item.js +5 -3
- package/build/components/site-editor-routes/template-item.js.map +1 -1
- package/build/components/site-editor-routes/template-part-item.js +4 -2
- package/build/components/site-editor-routes/template-part-item.js.map +1 -1
- package/build/components/site-editor-routes/templates.js +4 -2
- package/build/components/site-editor-routes/templates.js.map +1 -1
- package/build/components/site-editor-routes/utils.js +2 -0
- package/build/components/site-editor-routes/utils.js.map +1 -1
- package/build/components/site-hub/index.js +6 -4
- package/build/components/site-hub/index.js.map +1 -1
- package/build/components/site-icon/index.js +3 -1
- package/build/components/site-icon/index.js.map +1 -1
- package/build/components/welcome-guide/editor.js +3 -1
- package/build/components/welcome-guide/editor.js.map +1 -1
- package/build/components/welcome-guide/image.js +2 -0
- package/build/components/welcome-guide/image.js.map +1 -1
- package/build/components/welcome-guide/index.js +3 -1
- package/build/components/welcome-guide/index.js.map +1 -1
- package/build/components/welcome-guide/page.js +3 -1
- package/build/components/welcome-guide/page.js.map +1 -1
- package/build/components/welcome-guide/template.js +3 -1
- package/build/components/welcome-guide/template.js.map +1 -1
- package/build/deprecated.js +5 -3
- package/build/deprecated.js.map +1 -1
- package/build/hooks/commands/use-common-commands.js +7 -5
- package/build/hooks/commands/use-common-commands.js.map +1 -1
- package/build/hooks/commands/use-set-command-context.js +4 -2
- package/build/hooks/commands/use-set-command-context.js.map +1 -1
- package/build/index.js +4 -5
- package/build/index.js.map +2 -2
- package/build/lock-unlock.js +3 -1
- package/build/lock-unlock.js.map +1 -1
- package/build/store/actions.js +14 -12
- package/build/store/actions.js.map +1 -1
- package/build/store/constants.js +3 -1
- package/build/store/constants.js.map +1 -1
- package/build/store/index.js +4 -2
- package/build/store/index.js.map +1 -1
- package/build/store/private-actions.js +2 -0
- package/build/store/private-actions.js.map +1 -1
- package/build/store/private-selectors.js +2 -0
- package/build/store/private-selectors.js.map +1 -1
- package/build/store/reducer.js +2 -0
- package/build/store/reducer.js.map +1 -1
- package/build/store/selectors.js +11 -9
- package/build/store/selectors.js.map +1 -1
- package/build/utils/constants.js +18 -16
- package/build/utils/constants.js.map +1 -1
- package/build/utils/get-filtered-template-parts.js +3 -1
- package/build/utils/get-filtered-template-parts.js.map +1 -1
- package/build/utils/is-previewing-theme.js +2 -0
- package/build/utils/is-previewing-theme.js.map +1 -1
- package/build/utils/is-template-removable.js +2 -0
- package/build/utils/is-template-removable.js.map +1 -1
- package/build/utils/is-template-revertable.js +2 -0
- package/build/utils/is-template-revertable.js.map +2 -2
- package/build/utils/use-activate-theme.js +3 -1
- package/build/utils/use-activate-theme.js.map +1 -1
- package/build/utils/use-actual-current-theme.js +3 -1
- package/build/utils/use-actual-current-theme.js.map +1 -1
- package/build-module/components/add-new-pattern/index.js +5 -4
- package/build-module/components/add-new-pattern/index.js.map +1 -1
- package/build-module/components/add-new-post/index.js +2 -1
- package/build-module/components/add-new-post/index.js.map +1 -1
- package/build-module/components/add-new-template/add-custom-generic-template-modal-content.js +2 -1
- package/build-module/components/add-new-template/add-custom-generic-template-modal-content.js.map +1 -1
- package/build-module/components/add-new-template/add-custom-template-modal-content.js +3 -2
- package/build-module/components/add-new-template/add-custom-template-modal-content.js.map +1 -1
- package/build-module/components/add-new-template/index.js +6 -5
- package/build-module/components/add-new-template/index.js.map +1 -1
- package/build-module/components/add-new-template/utils.js +13 -12
- package/build-module/components/add-new-template/utils.js.map +1 -1
- package/build-module/components/app/index.js +3 -2
- package/build-module/components/app/index.js.map +1 -1
- package/build-module/components/block-editor/use-editor-iframe-props.js +2 -1
- package/build-module/components/block-editor/use-editor-iframe-props.js.map +1 -1
- package/build-module/components/block-editor/use-navigate-to-entity-record.js +2 -1
- package/build-module/components/block-editor/use-navigate-to-entity-record.js.map +1 -1
- package/build-module/components/block-editor/use-site-editor-settings.js +2 -1
- package/build-module/components/block-editor/use-site-editor-settings.js.map +1 -1
- package/build-module/components/canvas-loader/index.js +4 -3
- package/build-module/components/canvas-loader/index.js.map +1 -1
- package/build-module/components/dataviews-actions/index.js +4 -3
- package/build-module/components/dataviews-actions/index.js.map +1 -1
- package/build-module/components/editor/index.js +16 -24
- package/build-module/components/editor/index.js.map +2 -2
- package/build-module/components/editor/site-preview.js +2 -1
- package/build-module/components/editor/site-preview.js.map +1 -1
- package/build-module/components/editor/use-adapt-editor-to-canvas.js +1 -0
- package/build-module/components/editor/use-adapt-editor-to-canvas.js.map +1 -1
- package/build-module/components/editor/use-editor-title.js +2 -1
- package/build-module/components/editor/use-editor-title.js.map +1 -1
- package/build-module/components/editor/use-resolve-edited-entity.js +4 -3
- package/build-module/components/editor/use-resolve-edited-entity.js.map +1 -1
- package/build-module/components/layout/animation.js +2 -1
- package/build-module/components/layout/animation.js.map +1 -1
- package/build-module/components/layout/hooks.js +2 -1
- package/build-module/components/layout/hooks.js.map +1 -1
- package/build-module/components/layout/index.js +5 -4
- package/build-module/components/layout/index.js.map +1 -1
- package/build-module/components/media/index.js +2 -1
- package/build-module/components/media/index.js.map +1 -1
- package/build-module/components/more-menu/index.js +3 -2
- package/build-module/components/more-menu/index.js.map +1 -1
- package/build-module/components/more-menu/site-export.js +2 -1
- package/build-module/components/more-menu/site-export.js.map +1 -1
- package/build-module/components/more-menu/welcome-guide-menu-item.js +2 -1
- package/build-module/components/more-menu/welcome-guide-menu-item.js.map +1 -1
- package/build-module/components/page-patterns/actions.js +2 -1
- package/build-module/components/page-patterns/actions.js.map +1 -1
- package/build-module/components/page-patterns/delete-category-menu-item.js +3 -2
- package/build-module/components/page-patterns/delete-category-menu-item.js.map +1 -1
- package/build-module/components/page-patterns/fields.js +7 -6
- package/build-module/components/page-patterns/fields.js.map +1 -1
- package/build-module/components/page-patterns/index.js +9 -8
- package/build-module/components/page-patterns/index.js.map +2 -2
- package/build-module/components/page-patterns/rename-category-menu-item.js +3 -2
- package/build-module/components/page-patterns/rename-category-menu-item.js.map +1 -1
- package/build-module/components/page-patterns/search-items.js +11 -10
- package/build-module/components/page-patterns/search-items.js.map +1 -1
- package/build-module/components/page-patterns/use-pattern-settings.js +1 -0
- package/build-module/components/page-patterns/use-pattern-settings.js.map +1 -1
- package/build-module/components/page-patterns/use-patterns.js +7 -6
- package/build-module/components/page-patterns/use-patterns.js.map +1 -1
- package/build-module/components/page-patterns/utils.js +2 -1
- package/build-module/components/page-patterns/utils.js.map +1 -1
- package/build-module/components/page-templates/fields.js +13 -12
- package/build-module/components/page-templates/fields.js.map +2 -2
- package/build-module/components/page-templates/hooks.js +1 -0
- package/build-module/components/page-templates/hooks.js.map +1 -1
- package/build-module/components/page-templates/index.js +15 -11
- package/build-module/components/page-templates/index.js.map +2 -2
- package/build-module/components/page-templates/view-utils.js +7 -2
- package/build-module/components/page-templates/view-utils.js.map +2 -2
- package/build-module/components/pagination/index.js +2 -1
- package/build-module/components/pagination/index.js.map +1 -1
- package/build-module/components/plugin-template-setting-panel/index.js +4 -3
- package/build-module/components/plugin-template-setting-panel/index.js.map +1 -1
- package/build-module/components/post-edit/index.js +4 -3
- package/build-module/components/post-edit/index.js.map +1 -1
- package/build-module/components/post-list/index.js +7 -6
- package/build-module/components/post-list/index.js.map +1 -1
- package/build-module/components/post-list/view-utils.js +4 -3
- package/build-module/components/post-list/view-utils.js.map +1 -1
- package/build-module/components/resizable-frame/index.js +9 -8
- package/build-module/components/resizable-frame/index.js.map +1 -1
- package/build-module/components/routes/use-title.js +2 -1
- package/build-module/components/routes/use-title.js.map +1 -1
- package/build-module/components/save-button/index.js +3 -2
- package/build-module/components/save-button/index.js.map +1 -1
- package/build-module/components/save-hub/index.js +2 -1
- package/build-module/components/save-hub/index.js.map +1 -1
- package/build-module/components/save-keyboard-shortcut/index.js +2 -1
- package/build-module/components/save-keyboard-shortcut/index.js.map +1 -1
- package/build-module/components/save-panel/index.js +6 -5
- package/build-module/components/save-panel/index.js.map +1 -1
- package/build-module/components/sidebar/index.js +3 -2
- package/build-module/components/sidebar/index.js.map +1 -1
- package/build-module/components/sidebar-button/index.js +2 -1
- package/build-module/components/sidebar-button/index.js.map +1 -1
- package/build-module/components/sidebar-dataviews/dataview-item.js +3 -2
- package/build-module/components/sidebar-dataviews/dataview-item.js.map +1 -1
- package/build-module/components/sidebar-dataviews/index.js +3 -2
- package/build-module/components/sidebar-dataviews/index.js.map +1 -1
- package/build-module/components/sidebar-global-styles/index.js +6 -5
- package/build-module/components/sidebar-global-styles/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-item/index.js +3 -2
- package/build-module/components/sidebar-navigation-item/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen/index.js +3 -2
- package/build-module/components/sidebar-navigation-screen/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-details-footer/index.js +2 -1
- package/build-module/components/sidebar-navigation-screen-details-footer/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-global-styles/content.js +3 -2
- package/build-module/components/sidebar-navigation-screen-global-styles/content.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-global-styles/index.js +3 -2
- package/build-module/components/sidebar-navigation-screen-global-styles/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-main/index.js +2 -1
- package/build-module/components/sidebar-navigation-screen-main/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/delete-confirm-dialog.js +2 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/delete-confirm-dialog.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/index.js +4 -3
- package/build-module/components/sidebar-navigation-screen-navigation-menu/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/more-menu.js +4 -3
- package/build-module/components/sidebar-navigation-screen-navigation-menu/more-menu.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/navigation-menu-editor.js +3 -2
- package/build-module/components/sidebar-navigation-screen-navigation-menu/navigation-menu-editor.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/rename-modal.js +3 -2
- package/build-module/components/sidebar-navigation-screen-navigation-menu/rename-modal.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js +2 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/single-navigation-menu.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/use-navigation-menu-handlers.js +2 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menu/use-navigation-menu-handlers.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/build-navigation-label.js +1 -0
- package/build-module/components/sidebar-navigation-screen-navigation-menus/build-navigation-label.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/constants.js +2 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/constants.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/index.js +3 -2
- package/build-module/components/sidebar-navigation-screen-navigation-menus/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/leaf-more-menu.js +5 -4
- package/build-module/components/sidebar-navigation-screen-navigation-menus/leaf-more-menu.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-navigation-menus/navigation-menu-content.js +5 -4
- package/build-module/components/sidebar-navigation-screen-navigation-menus/navigation-menu-content.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/category-item.js +2 -1
- package/build-module/components/sidebar-navigation-screen-patterns/category-item.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/index.js +3 -2
- package/build-module/components/sidebar-navigation-screen-patterns/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/use-default-pattern-categories.js +1 -0
- package/build-module/components/sidebar-navigation-screen-patterns/use-default-pattern-categories.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/use-pattern-categories.js +1 -0
- package/build-module/components/sidebar-navigation-screen-patterns/use-pattern-categories.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/use-template-part-areas.js +2 -1
- package/build-module/components/sidebar-navigation-screen-patterns/use-template-part-areas.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-patterns/use-theme-patterns.js +1 -0
- package/build-module/components/sidebar-navigation-screen-patterns/use-theme-patterns.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-templates-browse/content.js +4 -3
- package/build-module/components/sidebar-navigation-screen-templates-browse/content.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-templates-browse/index.js +2 -1
- package/build-module/components/sidebar-navigation-screen-templates-browse/index.js.map +1 -1
- package/build-module/components/sidebar-navigation-screen-unsupported/index.js +2 -1
- package/build-module/components/sidebar-navigation-screen-unsupported/index.js.map +1 -1
- package/build-module/components/site-editor-routes/home.js +3 -2
- package/build-module/components/site-editor-routes/home.js.map +1 -1
- package/build-module/components/site-editor-routes/index.js +2 -1
- package/build-module/components/site-editor-routes/index.js.map +1 -1
- package/build-module/components/site-editor-routes/navigation-item.js +4 -3
- package/build-module/components/site-editor-routes/navigation-item.js.map +1 -1
- package/build-module/components/site-editor-routes/navigation.js +4 -3
- package/build-module/components/site-editor-routes/navigation.js.map +1 -1
- package/build-module/components/site-editor-routes/notfound.js +3 -2
- package/build-module/components/site-editor-routes/notfound.js.map +1 -1
- package/build-module/components/site-editor-routes/page-item.js +3 -2
- package/build-module/components/site-editor-routes/page-item.js.map +1 -1
- package/build-module/components/site-editor-routes/pages.js +4 -3
- package/build-module/components/site-editor-routes/pages.js.map +1 -1
- package/build-module/components/site-editor-routes/pattern-item.js +3 -2
- package/build-module/components/site-editor-routes/pattern-item.js.map +1 -1
- package/build-module/components/site-editor-routes/patterns.js +3 -2
- package/build-module/components/site-editor-routes/patterns.js.map +1 -1
- package/build-module/components/site-editor-routes/stylebook.js +4 -3
- package/build-module/components/site-editor-routes/stylebook.js.map +1 -1
- package/build-module/components/site-editor-routes/styles.js +5 -4
- package/build-module/components/site-editor-routes/styles.js.map +1 -1
- package/build-module/components/site-editor-routes/template-item.js +4 -3
- package/build-module/components/site-editor-routes/template-item.js.map +1 -1
- package/build-module/components/site-editor-routes/template-part-item.js +3 -2
- package/build-module/components/site-editor-routes/template-part-item.js.map +1 -1
- package/build-module/components/site-editor-routes/templates.js +3 -2
- package/build-module/components/site-editor-routes/templates.js.map +1 -1
- package/build-module/components/site-editor-routes/utils.js +1 -0
- package/build-module/components/site-editor-routes/utils.js.map +1 -1
- package/build-module/components/site-hub/index.js +5 -4
- package/build-module/components/site-hub/index.js.map +1 -1
- package/build-module/components/site-icon/index.js +2 -1
- package/build-module/components/site-icon/index.js.map +1 -1
- package/build-module/components/welcome-guide/editor.js +2 -1
- package/build-module/components/welcome-guide/editor.js.map +1 -1
- package/build-module/components/welcome-guide/image.js +1 -0
- package/build-module/components/welcome-guide/image.js.map +1 -1
- package/build-module/components/welcome-guide/index.js +2 -1
- package/build-module/components/welcome-guide/index.js.map +1 -1
- package/build-module/components/welcome-guide/page.js +2 -1
- package/build-module/components/welcome-guide/page.js.map +1 -1
- package/build-module/components/welcome-guide/template.js +2 -1
- package/build-module/components/welcome-guide/template.js.map +1 -1
- package/build-module/deprecated.js +4 -3
- package/build-module/deprecated.js.map +1 -1
- package/build-module/hooks/commands/use-common-commands.js +6 -5
- package/build-module/hooks/commands/use-common-commands.js.map +1 -1
- package/build-module/hooks/commands/use-set-command-context.js +3 -2
- package/build-module/hooks/commands/use-set-command-context.js.map +1 -1
- package/build-module/index.js +6 -7
- package/build-module/index.js.map +2 -2
- package/build-module/lock-unlock.js +2 -1
- package/build-module/lock-unlock.js.map +1 -1
- package/build-module/store/actions.js +13 -12
- package/build-module/store/actions.js.map +1 -1
- package/build-module/store/constants.js +2 -1
- package/build-module/store/constants.js.map +1 -1
- package/build-module/store/index.js +3 -2
- package/build-module/store/index.js.map +1 -1
- package/build-module/store/private-actions.js +1 -0
- package/build-module/store/private-actions.js.map +1 -1
- package/build-module/store/private-selectors.js +1 -0
- package/build-module/store/private-selectors.js.map +1 -1
- package/build-module/store/reducer.js +1 -0
- package/build-module/store/reducer.js.map +1 -1
- package/build-module/store/selectors.js +10 -9
- package/build-module/store/selectors.js.map +1 -1
- package/build-module/utils/constants.js +17 -16
- package/build-module/utils/constants.js.map +1 -1
- package/build-module/utils/get-filtered-template-parts.js +2 -1
- package/build-module/utils/get-filtered-template-parts.js.map +1 -1
- package/build-module/utils/is-previewing-theme.js +1 -0
- package/build-module/utils/is-previewing-theme.js.map +1 -1
- package/build-module/utils/is-template-removable.js +1 -0
- package/build-module/utils/is-template-removable.js.map +1 -1
- package/build-module/utils/is-template-revertable.js +1 -0
- package/build-module/utils/is-template-revertable.js.map +2 -2
- package/build-module/utils/use-activate-theme.js +2 -1
- package/build-module/utils/use-activate-theme.js.map +1 -1
- package/build-module/utils/use-actual-current-theme.js +2 -1
- package/build-module/utils/use-actual-current-theme.js.map +1 -1
- package/build-style/style-rtl.css +41 -40
- package/build-style/style.css +41 -40
- package/package.json +46 -46
- package/src/components/editor/index.js +11 -27
- package/src/components/page-patterns/index.js +1 -1
- package/src/components/page-templates/fields.js +3 -3
- package/src/components/page-templates/index.js +11 -7
- package/src/components/page-templates/view-utils.js +7 -0
- package/src/index.js +0 -4
- package/src/utils/is-template-revertable.js +1 -2
- package/build/components/posts-app/index.js +0 -49
- package/build/components/posts-app/index.js.map +0 -7
- package/build/components/posts-app-routes/index.js +0 -44
- package/build/components/posts-app-routes/index.js.map +0 -7
- package/build/components/posts-app-routes/post-item.js +0 -59
- package/build/components/posts-app-routes/post-item.js.map +0 -7
- package/build/components/posts-app-routes/posts.js +0 -104
- package/build/components/posts-app-routes/posts.js.map +0 -7
- package/build/posts.js +0 -94
- package/build/posts.js.map +0 -7
- package/build-module/components/posts-app/index.js +0 -19
- package/build-module/components/posts-app/index.js.map +0 -7
- package/build-module/components/posts-app-routes/index.js +0 -20
- package/build-module/components/posts-app-routes/index.js.map +0 -7
- package/build-module/components/posts-app-routes/post-item.js +0 -25
- package/build-module/components/posts-app-routes/post-item.js.map +0 -7
- package/build-module/components/posts-app-routes/posts.js +0 -70
- package/build-module/components/posts-app-routes/posts.js.map +0 -7
- package/build-module/posts.js +0 -67
- package/build-module/posts.js.map +0 -7
- package/build-style/posts-rtl.css +0 -3105
- package/build-style/posts.css +0 -3105
- package/src/components/posts-app/index.js +0 -27
- package/src/components/posts-app-routes/index.js +0 -25
- package/src/components/posts-app-routes/post-item.js +0 -27
- package/src/components/posts-app-routes/posts.js +0 -79
- package/src/posts.js +0 -91
- package/src/posts.scss +0 -57
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// packages/edit-site/src/store/index.js
|
|
1
2
|
import { createReduxStore, register } from "@wordpress/data";
|
|
2
3
|
import reducer from "./reducer";
|
|
3
4
|
import * as actions from "./actions";
|
|
@@ -6,12 +7,12 @@ import * as selectors from "./selectors";
|
|
|
6
7
|
import * as privateSelectors from "./private-selectors";
|
|
7
8
|
import { STORE_NAME } from "./constants";
|
|
8
9
|
import { unlock } from "../lock-unlock";
|
|
9
|
-
|
|
10
|
+
var storeConfig = {
|
|
10
11
|
reducer,
|
|
11
12
|
actions,
|
|
12
13
|
selectors
|
|
13
14
|
};
|
|
14
|
-
|
|
15
|
+
var store = createReduxStore(STORE_NAME, storeConfig);
|
|
15
16
|
register(store);
|
|
16
17
|
unlock(store).registerPrivateSelectors(privateSelectors);
|
|
17
18
|
unlock(store).registerPrivateActions(privateActions);
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/store/index.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { createReduxStore, register } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport reducer from './reducer';\nimport * as actions from './actions';\nimport * as privateActions from './private-actions';\nimport * as selectors from './selectors';\nimport * as privateSelectors from './private-selectors';\nimport { STORE_NAME } from './constants';\nimport { unlock } from '../lock-unlock';\n\nexport const storeConfig = {\n\treducer,\n\tactions,\n\tselectors,\n};\n\nexport const store = createReduxStore( STORE_NAME, storeConfig );\nregister( store );\nunlock( store ).registerPrivateSelectors( privateSelectors );\nunlock( store ).registerPrivateActions( privateActions );\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,kBAAkB,gBAAgB;AAK3C,OAAO,aAAa;AACpB,YAAY,aAAa;AACzB,YAAY,oBAAoB;AAChC,YAAY,eAAe;AAC3B,YAAY,sBAAsB;AAClC,SAAS,kBAAkB;AAC3B,SAAS,cAAc;AAEhB,
|
|
5
|
+
"mappings": ";AAGA,SAAS,kBAAkB,gBAAgB;AAK3C,OAAO,aAAa;AACpB,YAAY,aAAa;AACzB,YAAY,oBAAoB;AAChC,YAAY,eAAe;AAC3B,YAAY,sBAAsB;AAClC,SAAS,kBAAkB;AAC3B,SAAS,cAAc;AAEhB,IAAM,cAAc;AAAA,EAC1B;AAAA,EACA;AAAA,EACA;AACD;AAEO,IAAM,QAAQ,iBAAkB,YAAY,WAAY;AAC/D,SAAU,KAAM;AAChB,OAAQ,KAAM,EAAE,yBAA0B,gBAAiB;AAC3D,OAAQ,KAAM,EAAE,uBAAwB,cAAe;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/store/private-actions.js"],
|
|
4
4
|
"sourcesContent": ["export function registerRoute( route ) {\n\treturn {\n\t\ttype: 'REGISTER_ROUTE',\n\t\troute,\n\t};\n}\n\nexport function unregisterRoute( name ) {\n\treturn {\n\t\ttype: 'UNREGISTER_ROUTE',\n\t\tname,\n\t};\n}\n"],
|
|
5
|
-
"mappings": "AAAO,SAAS,cAAe,OAAQ;AACtC,SAAO;AAAA,IACN,MAAM;AAAA,IACN;AAAA,EACD;AACD;AAEO,SAAS,gBAAiB,MAAO;AACvC,SAAO;AAAA,IACN,MAAM;AAAA,IACN;AAAA,EACD;AACD;",
|
|
5
|
+
"mappings": ";AAAO,SAAS,cAAe,OAAQ;AACtC,SAAO;AAAA,IACN,MAAM;AAAA,IACN;AAAA,EACD;AACD;AAEO,SAAS,gBAAiB,MAAO;AACvC,SAAO;AAAA,IACN,MAAM;AAAA,IACN;AAAA,EACD;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/store/private-selectors.js"],
|
|
4
4
|
"sourcesContent": ["export function getRoutes( state ) {\n\treturn state.routes;\n}\n"],
|
|
5
|
-
"mappings": "AAAO,SAAS,UAAW,OAAQ;AAClC,SAAO,MAAM;AACd;",
|
|
5
|
+
"mappings": ";AAAO,SAAS,UAAW,OAAQ;AAClC,SAAO,MAAM;AACd;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/store/reducer.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { combineReducers } from '@wordpress/data';\n\n/**\n * Reducer returning the settings.\n *\n * @param {Object} state Current state.\n * @param {Object} action Dispatched action.\n *\n * @return {Object} Updated state.\n */\nexport function settings( state = {}, action ) {\n\tswitch ( action.type ) {\n\t\tcase 'UPDATE_SETTINGS':\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\t...action.settings,\n\t\t\t};\n\t}\n\n\treturn state;\n}\n\n/**\n * Reducer keeping track of the currently edited Post Type,\n * Post Id and the context provided to fill the content of the block editor.\n *\n * @param {Object} state Current edited post.\n * @param {Object} action Dispatched action.\n *\n * @return {Object} Updated state.\n */\nexport function editedPost( state = {}, action ) {\n\tswitch ( action.type ) {\n\t\tcase 'SET_EDITED_POST':\n\t\t\treturn {\n\t\t\t\tpostType: action.postType,\n\t\t\t\tid: action.id,\n\t\t\t\tcontext: action.context,\n\t\t\t};\n\t\tcase 'SET_EDITED_POST_CONTEXT':\n\t\t\treturn {\n\t\t\t\t...state,\n\t\t\t\tcontext: action.context,\n\t\t\t};\n\t}\n\n\treturn state;\n}\n\n/**\n * Reducer to set the save view panel open or closed.\n *\n * @param {Object} state Current state.\n * @param {Object} action Dispatched action.\n */\nexport function saveViewPanel( state = false, action ) {\n\tswitch ( action.type ) {\n\t\tcase 'SET_IS_SAVE_VIEW_OPENED':\n\t\t\treturn action.isOpen;\n\t}\n\treturn state;\n}\n\nfunction routes( state = [], action ) {\n\tswitch ( action.type ) {\n\t\tcase 'REGISTER_ROUTE':\n\t\t\treturn [ ...state, action.route ];\n\t\tcase 'UNREGISTER_ROUTE':\n\t\t\treturn state.filter( ( route ) => route.name !== action.name );\n\t}\n\n\treturn state;\n}\n\nexport default combineReducers( {\n\tsettings,\n\teditedPost,\n\tsaveViewPanel,\n\troutes,\n} );\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,uBAAuB;AAUzB,SAAS,SAAU,QAAQ,CAAC,GAAG,QAAS;AAC9C,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO;AAAA,QACN,GAAG;AAAA,QACH,GAAG,OAAO;AAAA,MACX;AAAA,EACF;AAEA,SAAO;AACR;AAWO,SAAS,WAAY,QAAQ,CAAC,GAAG,QAAS;AAChD,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO;AAAA,QACN,UAAU,OAAO;AAAA,QACjB,IAAI,OAAO;AAAA,QACX,SAAS,OAAO;AAAA,MACjB;AAAA,IACD,KAAK;AACJ,aAAO;AAAA,QACN,GAAG;AAAA,QACH,SAAS,OAAO;AAAA,MACjB;AAAA,EACF;AAEA,SAAO;AACR;AAQO,SAAS,cAAe,QAAQ,OAAO,QAAS;AACtD,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO,OAAO;AAAA,EAChB;AACA,SAAO;AACR;AAEA,SAAS,OAAQ,QAAQ,CAAC,GAAG,QAAS;AACrC,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO,CAAE,GAAG,OAAO,OAAO,KAAM;AAAA,IACjC,KAAK;AACJ,aAAO,MAAM,OAAQ,CAAE,UAAW,MAAM,SAAS,OAAO,IAAK;AAAA,EAC/D;AAEA,SAAO;AACR;AAEA,IAAO,kBAAQ,gBAAiB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,CAAE;",
|
|
5
|
+
"mappings": ";AAGA,SAAS,uBAAuB;AAUzB,SAAS,SAAU,QAAQ,CAAC,GAAG,QAAS;AAC9C,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO;AAAA,QACN,GAAG;AAAA,QACH,GAAG,OAAO;AAAA,MACX;AAAA,EACF;AAEA,SAAO;AACR;AAWO,SAAS,WAAY,QAAQ,CAAC,GAAG,QAAS;AAChD,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO;AAAA,QACN,UAAU,OAAO;AAAA,QACjB,IAAI,OAAO;AAAA,QACX,SAAS,OAAO;AAAA,MACjB;AAAA,IACD,KAAK;AACJ,aAAO;AAAA,QACN,GAAG;AAAA,QACH,SAAS,OAAO;AAAA,MACjB;AAAA,EACF;AAEA,SAAO;AACR;AAQO,SAAS,cAAe,QAAQ,OAAO,QAAS;AACtD,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO,OAAO;AAAA,EAChB;AACA,SAAO;AACR;AAEA,SAAS,OAAQ,QAAQ,CAAC,GAAG,QAAS;AACrC,UAAS,OAAO,MAAO;AAAA,IACtB,KAAK;AACJ,aAAO,CAAE,GAAG,OAAO,OAAO,KAAM;AAAA,IACjC,KAAK;AACJ,aAAO,MAAM,OAAQ,CAAE,UAAW,MAAM,SAAS,OAAO,IAAK;AAAA,EAC/D;AAEA,SAAO;AACR;AAEA,IAAO,kBAAQ,gBAAiB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,CAAE;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// packages/edit-site/src/store/selectors.js
|
|
1
2
|
import { store as coreDataStore } from "@wordpress/core-data";
|
|
2
3
|
import { createRegistrySelector, createSelector } from "@wordpress/data";
|
|
3
4
|
import deprecated from "@wordpress/deprecated";
|
|
@@ -8,7 +9,7 @@ import { store as blockEditorStore } from "@wordpress/block-editor";
|
|
|
8
9
|
import { unlock } from "../lock-unlock";
|
|
9
10
|
import { TEMPLATE_PART_POST_TYPE } from "../utils/constants";
|
|
10
11
|
import getFilteredTemplatePartBlocks from "../utils/get-filtered-template-parts";
|
|
11
|
-
|
|
12
|
+
var isFeatureActive = createRegistrySelector(
|
|
12
13
|
(select) => (_, featureName) => {
|
|
13
14
|
deprecated(`select( 'core/edit-site' ).isFeatureActive`, {
|
|
14
15
|
since: "6.0",
|
|
@@ -20,7 +21,7 @@ const isFeatureActive = createRegistrySelector(
|
|
|
20
21
|
);
|
|
21
22
|
}
|
|
22
23
|
);
|
|
23
|
-
|
|
24
|
+
var __experimentalGetPreviewDeviceType = createRegistrySelector(
|
|
24
25
|
(select) => () => {
|
|
25
26
|
deprecated(
|
|
26
27
|
`select( 'core/edit-site' ).__experimentalGetPreviewDeviceType`,
|
|
@@ -33,7 +34,7 @@ const __experimentalGetPreviewDeviceType = createRegistrySelector(
|
|
|
33
34
|
return select(editorStore).getDeviceType();
|
|
34
35
|
}
|
|
35
36
|
);
|
|
36
|
-
|
|
37
|
+
var getCanUserCreateMedia = createRegistrySelector(
|
|
37
38
|
(select) => () => {
|
|
38
39
|
deprecated(
|
|
39
40
|
`wp.data.select( 'core/edit-site' ).getCanUserCreateMedia()`,
|
|
@@ -45,7 +46,7 @@ const getCanUserCreateMedia = createRegistrySelector(
|
|
|
45
46
|
return select(coreDataStore).canUser("create", "media");
|
|
46
47
|
}
|
|
47
48
|
);
|
|
48
|
-
|
|
49
|
+
var getReusableBlocks = createRegistrySelector((select) => () => {
|
|
49
50
|
deprecated(`select( 'core/edit-site' ).getReusableBlocks()`, {
|
|
50
51
|
since: "6.5",
|
|
51
52
|
version: "6.8",
|
|
@@ -91,14 +92,14 @@ function getPage(state) {
|
|
|
91
92
|
});
|
|
92
93
|
return { context: state.editedPost.context };
|
|
93
94
|
}
|
|
94
|
-
|
|
95
|
+
var isInserterOpened = createRegistrySelector((select) => () => {
|
|
95
96
|
deprecated(`select( 'core/edit-site' ).isInserterOpened`, {
|
|
96
97
|
since: "6.5",
|
|
97
98
|
alternative: `select( 'core/editor' ).isInserterOpened`
|
|
98
99
|
});
|
|
99
100
|
return select(editorStore).isInserterOpened();
|
|
100
101
|
});
|
|
101
|
-
|
|
102
|
+
var __experimentalGetInsertionPoint = createRegistrySelector(
|
|
102
103
|
(select) => () => {
|
|
103
104
|
deprecated(
|
|
104
105
|
`select( 'core/edit-site' ).__experimentalGetInsertionPoint`,
|
|
@@ -110,7 +111,7 @@ const __experimentalGetInsertionPoint = createRegistrySelector(
|
|
|
110
111
|
return unlock(select(editorStore)).getInserter();
|
|
111
112
|
}
|
|
112
113
|
);
|
|
113
|
-
|
|
114
|
+
var isListViewOpened = createRegistrySelector((select) => () => {
|
|
114
115
|
deprecated(`select( 'core/edit-site' ).isListViewOpened`, {
|
|
115
116
|
since: "6.5",
|
|
116
117
|
alternative: `select( 'core/editor' ).isListViewOpened`
|
|
@@ -131,7 +132,7 @@ function getBlocksAndTemplateParts(select) {
|
|
|
131
132
|
const blocks = getBlocksByClientId(clientIds);
|
|
132
133
|
return [blocks, templateParts];
|
|
133
134
|
}
|
|
134
|
-
|
|
135
|
+
var getCurrentTemplateTemplateParts = createRegistrySelector(
|
|
135
136
|
(select) => createSelector(
|
|
136
137
|
() => {
|
|
137
138
|
deprecated(
|
|
@@ -149,7 +150,7 @@ const getCurrentTemplateTemplateParts = createRegistrySelector(
|
|
|
149
150
|
() => getBlocksAndTemplateParts(select)
|
|
150
151
|
)
|
|
151
152
|
);
|
|
152
|
-
|
|
153
|
+
var getEditorMode = createRegistrySelector((select) => () => {
|
|
153
154
|
return select(preferencesStore).get("core", "editorMode");
|
|
154
155
|
});
|
|
155
156
|
function getCurrentTemplateNavigationPanelSubMenu() {
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/store/selectors.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { store as coreDataStore } from '@wordpress/core-data';\nimport { createRegistrySelector, createSelector } from '@wordpress/data';\nimport deprecated from '@wordpress/deprecated';\nimport { Platform } from '@wordpress/element';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport { store as editorStore } from '@wordpress/editor';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport { unlock } from '../lock-unlock';\nimport { TEMPLATE_PART_POST_TYPE } from '../utils/constants';\nimport getFilteredTemplatePartBlocks from '../utils/get-filtered-template-parts';\n\n/**\n * @typedef {'template'|'template_type'} TemplateType Template type.\n */\n\n/**\n * Returns whether the given feature is enabled or not.\n *\n * @deprecated\n * @param {Object} state Global application state.\n * @param {string} featureName Feature slug.\n *\n * @return {boolean} Is active.\n */\nexport const isFeatureActive = createRegistrySelector(\n\t( select ) => ( _, featureName ) => {\n\t\tdeprecated( `select( 'core/edit-site' ).isFeatureActive`, {\n\t\t\tsince: '6.0',\n\t\t\talternative: `select( 'core/preferences' ).get`,\n\t\t} );\n\n\t\treturn !! select( preferencesStore ).get(\n\t\t\t'core/edit-site',\n\t\t\tfeatureName\n\t\t);\n\t}\n);\n\n/**\n * Returns the current editing canvas device type.\n *\n * @deprecated\n *\n * @param {Object} state Global application state.\n *\n * @return {string} Device type.\n */\nexport const __experimentalGetPreviewDeviceType = createRegistrySelector(\n\t( select ) => () => {\n\t\tdeprecated(\n\t\t\t`select( 'core/edit-site' ).__experimentalGetPreviewDeviceType`,\n\t\t\t{\n\t\t\t\tsince: '6.5',\n\t\t\t\tversion: '6.7',\n\t\t\t\talternative: `select( 'core/editor' ).getDeviceType`,\n\t\t\t}\n\t\t);\n\t\treturn select( editorStore ).getDeviceType();\n\t}\n);\n\n/**\n * Returns whether the current user can create media or not.\n *\n * @param {Object} state Global application state.\n *\n * @return {Object} Whether the current user can create media or not.\n */\nexport const getCanUserCreateMedia = createRegistrySelector(\n\t( select ) => () => {\n\t\tdeprecated(\n\t\t\t`wp.data.select( 'core/edit-site' ).getCanUserCreateMedia()`,\n\t\t\t{\n\t\t\t\tsince: '6.7',\n\t\t\t\talternative: `wp.data.select( 'core' ).canUser( 'create', { kind: 'postType', type: 'attachment' } )`,\n\t\t\t}\n\t\t);\n\n\t\treturn select( coreDataStore ).canUser( 'create', 'media' );\n\t}\n);\n\n/**\n * Returns any available Reusable blocks.\n *\n * @param {Object} state Global application state.\n *\n * @return {Array} The available reusable blocks.\n */\nexport const getReusableBlocks = createRegistrySelector( ( select ) => () => {\n\tdeprecated( `select( 'core/edit-site' ).getReusableBlocks()`, {\n\t\tsince: '6.5',\n\t\tversion: '6.8',\n\t\talternative: `select( 'core/core' ).getEntityRecords( 'postType', 'wp_block' )`,\n\t} );\n\tconst isWeb = Platform.OS === 'web';\n\treturn isWeb\n\t\t? select( coreDataStore ).getEntityRecords( 'postType', 'wp_block', {\n\t\t\t\tper_page: -1,\n\t\t } )\n\t\t: [];\n} );\n\n/**\n * Returns the site editor settings.\n *\n * @param {Object} state Global application state.\n *\n * @return {Object} Settings.\n */\nexport function getSettings( state ) {\n\t// It is important that we don't inject anything into these settings locally.\n\t// The reason for this is that we have an effect in place that calls setSettings based on the previous value of getSettings.\n\t// If we add computed settings here, we'll be adding these computed settings to the state which is very unexpected.\n\treturn state.settings;\n}\n\n/**\n * @deprecated\n */\nexport function getHomeTemplateId() {\n\tdeprecated( \"select( 'core/edit-site' ).getHomeTemplateId\", {\n\t\tsince: '6.2',\n\t\tversion: '6.4',\n\t} );\n}\n\n/**\n * Returns the current edited post type (wp_template or wp_template_part).\n *\n * @deprecated\n * @param {Object} state Global application state.\n *\n * @return {?TemplateType} Template type.\n */\nexport function getEditedPostType( state ) {\n\tdeprecated( \"select( 'core/edit-site' ).getEditedPostType\", {\n\t\tsince: '6.8',\n\t\talternative: \"select( 'core/editor' ).getCurrentPostType\",\n\t} );\n\treturn state.editedPost.postType;\n}\n\n/**\n * Returns the ID of the currently edited template or template part.\n *\n * @deprecated\n * @param {Object} state Global application state.\n *\n * @return {?string} Post ID.\n */\nexport function getEditedPostId( state ) {\n\tdeprecated( \"select( 'core/edit-site' ).getEditedPostId\", {\n\t\tsince: '6.8',\n\t\talternative: \"select( 'core/editor' ).getCurrentPostId\",\n\t} );\n\treturn state.editedPost.id;\n}\n\n/**\n * Returns the edited post's context object.\n *\n * @deprecated\n * @param {Object} state Global application state.\n *\n * @return {Object} Page.\n */\nexport function getEditedPostContext( state ) {\n\tdeprecated( \"select( 'core/edit-site' ).getEditedPostContext\", {\n\t\tsince: '6.8',\n\t} );\n\n\treturn state.editedPost.context;\n}\n\n/**\n * Returns the current page object.\n *\n * @deprecated\n * @param {Object} state Global application state.\n *\n * @return {Object} Page.\n */\nexport function getPage( state ) {\n\tdeprecated( \"select( 'core/edit-site' ).getPage\", {\n\t\tsince: '6.8',\n\t} );\n\n\treturn { context: state.editedPost.context };\n}\n\n/**\n * Returns true if the inserter is opened.\n *\n * @deprecated\n *\n * @param {Object} state Global application state.\n *\n * @return {boolean} Whether the inserter is opened.\n */\nexport const isInserterOpened = createRegistrySelector( ( select ) => () => {\n\tdeprecated( `select( 'core/edit-site' ).isInserterOpened`, {\n\t\tsince: '6.5',\n\t\talternative: `select( 'core/editor' ).isInserterOpened`,\n\t} );\n\treturn select( editorStore ).isInserterOpened();\n} );\n\n/**\n * Get the insertion point for the inserter.\n *\n * @deprecated\n *\n * @param {Object} state Global application state.\n *\n * @return {Object} The root client ID, index to insert at and starting filter value.\n */\nexport const __experimentalGetInsertionPoint = createRegistrySelector(\n\t( select ) => () => {\n\t\tdeprecated(\n\t\t\t`select( 'core/edit-site' ).__experimentalGetInsertionPoint`,\n\t\t\t{\n\t\t\t\tsince: '6.5',\n\t\t\t\tversion: '6.7',\n\t\t\t}\n\t\t);\n\t\treturn unlock( select( editorStore ) ).getInserter();\n\t}\n);\n\n/**\n * Returns true if the list view is opened.\n *\n * @param {Object} state Global application state.\n *\n * @return {boolean} Whether the list view is opened.\n */\nexport const isListViewOpened = createRegistrySelector( ( select ) => () => {\n\tdeprecated( `select( 'core/edit-site' ).isListViewOpened`, {\n\t\tsince: '6.5',\n\t\talternative: `select( 'core/editor' ).isListViewOpened`,\n\t} );\n\treturn select( editorStore ).isListViewOpened();\n} );\n\n/**\n * Returns the current opened/closed state of the save panel.\n *\n * @param {Object} state Global application state.\n *\n * @return {boolean} True if the save panel should be open; false if closed.\n */\nexport function isSaveViewOpened( state ) {\n\treturn state.saveViewPanel;\n}\n\nfunction getBlocksAndTemplateParts( select ) {\n\tconst templateParts = select( coreDataStore ).getEntityRecords(\n\t\t'postType',\n\t\tTEMPLATE_PART_POST_TYPE,\n\t\t{ per_page: -1 }\n\t);\n\n\tconst { getBlocksByName, getBlocksByClientId } = select( blockEditorStore );\n\n\tconst clientIds = getBlocksByName( 'core/template-part' );\n\tconst blocks = getBlocksByClientId( clientIds );\n\treturn [ blocks, templateParts ];\n}\n\n/**\n * Returns the template parts and their blocks for the current edited template.\n *\n * @deprecated\n * @param {Object} state Global application state.\n * @return {Array} Template parts and their blocks in an array.\n */\nexport const getCurrentTemplateTemplateParts = createRegistrySelector(\n\t( select ) =>\n\t\tcreateSelector(\n\t\t\t() => {\n\t\t\t\tdeprecated(\n\t\t\t\t\t`select( 'core/edit-site' ).getCurrentTemplateTemplateParts()`,\n\t\t\t\t\t{\n\t\t\t\t\t\tsince: '6.7',\n\t\t\t\t\t\tversion: '6.9',\n\t\t\t\t\t\talternative: `select( 'core/block-editor' ).getBlocksByName( 'core/template-part' )`,\n\t\t\t\t\t}\n\t\t\t\t);\n\n\t\t\t\treturn getFilteredTemplatePartBlocks(\n\t\t\t\t\t...getBlocksAndTemplateParts( select )\n\t\t\t\t);\n\t\t\t},\n\t\t\t() => getBlocksAndTemplateParts( select )\n\t\t)\n);\n\n/**\n * Returns the current editing mode.\n *\n * @param {Object} state Global application state.\n *\n * @return {string} Editing mode.\n */\nexport const getEditorMode = createRegistrySelector( ( select ) => () => {\n\treturn select( preferencesStore ).get( 'core', 'editorMode' );\n} );\n\n/**\n * @deprecated\n */\nexport function getCurrentTemplateNavigationPanelSubMenu() {\n\tdeprecated(\n\t\t\"dispatch( 'core/edit-site' ).getCurrentTemplateNavigationPanelSubMenu\",\n\t\t{\n\t\t\tsince: '6.2',\n\t\t\tversion: '6.4',\n\t\t}\n\t);\n}\n\n/**\n * @deprecated\n */\nexport function getNavigationPanelActiveMenu() {\n\tdeprecated( \"dispatch( 'core/edit-site' ).getNavigationPanelActiveMenu\", {\n\t\tsince: '6.2',\n\t\tversion: '6.4',\n\t} );\n}\n\n/**\n * @deprecated\n */\nexport function isNavigationOpened() {\n\tdeprecated( \"dispatch( 'core/edit-site' ).isNavigationOpened\", {\n\t\tsince: '6.2',\n\t\tversion: '6.4',\n\t} );\n}\n\n/**\n * Whether or not the editor has a page loaded into it.\n *\n * @see setPage\n * @deprecated\n * @param {Object} state Global application state.\n *\n * @return {boolean} Whether or not the editor has a page loaded into it.\n */\nexport function isPage( state ) {\n\tdeprecated( \"select( 'core/edit-site' ).isPage\", {\n\t\tsince: '6.8',\n\t\talternative: \"select( 'core/editor' ).getCurrentPostType\",\n\t} );\n\n\treturn !! state.editedPost.context?.postId;\n}\n\n/**\n * Whether or not the editor allows only page content to be edited.\n *\n * @deprecated\n *\n * @return {boolean} Whether or not focus is on editing page content.\n */\nexport function hasPageContentFocus() {\n\tdeprecated( `select( 'core/edit-site' ).hasPageContentFocus`, {\n\t\tsince: '6.5',\n\t} );\n\n\treturn false;\n}\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,SAAS,qBAAqB;AACvC,SAAS,wBAAwB,sBAAsB;AACvD,OAAO,gBAAgB;AACvB,SAAS,gBAAgB;AACzB,SAAS,SAAS,wBAAwB;AAC1C,SAAS,SAAS,mBAAmB;AACrC,SAAS,SAAS,wBAAwB;AAK1C,SAAS,cAAc;AACvB,SAAS,+BAA+B;AACxC,OAAO,mCAAmC;AAenC,
|
|
5
|
+
"mappings": ";AAGA,SAAS,SAAS,qBAAqB;AACvC,SAAS,wBAAwB,sBAAsB;AACvD,OAAO,gBAAgB;AACvB,SAAS,gBAAgB;AACzB,SAAS,SAAS,wBAAwB;AAC1C,SAAS,SAAS,mBAAmB;AACrC,SAAS,SAAS,wBAAwB;AAK1C,SAAS,cAAc;AACvB,SAAS,+BAA+B;AACxC,OAAO,mCAAmC;AAenC,IAAM,kBAAkB;AAAA,EAC9B,CAAE,WAAY,CAAE,GAAG,gBAAiB;AACnC,eAAY,8CAA8C;AAAA,MACzD,OAAO;AAAA,MACP,aAAa;AAAA,IACd,CAAE;AAEF,WAAO,CAAC,CAAE,OAAQ,gBAAiB,EAAE;AAAA,MACpC;AAAA,MACA;AAAA,IACD;AAAA,EACD;AACD;AAWO,IAAM,qCAAqC;AAAA,EACjD,CAAE,WAAY,MAAM;AACnB;AAAA,MACC;AAAA,MACA;AAAA,QACC,OAAO;AAAA,QACP,SAAS;AAAA,QACT,aAAa;AAAA,MACd;AAAA,IACD;AACA,WAAO,OAAQ,WAAY,EAAE,cAAc;AAAA,EAC5C;AACD;AASO,IAAM,wBAAwB;AAAA,EACpC,CAAE,WAAY,MAAM;AACnB;AAAA,MACC;AAAA,MACA;AAAA,QACC,OAAO;AAAA,QACP,aAAa;AAAA,MACd;AAAA,IACD;AAEA,WAAO,OAAQ,aAAc,EAAE,QAAS,UAAU,OAAQ;AAAA,EAC3D;AACD;AASO,IAAM,oBAAoB,uBAAwB,CAAE,WAAY,MAAM;AAC5E,aAAY,kDAAkD;AAAA,IAC7D,OAAO;AAAA,IACP,SAAS;AAAA,IACT,aAAa;AAAA,EACd,CAAE;AACF,QAAM,QAAQ,SAAS,OAAO;AAC9B,SAAO,QACJ,OAAQ,aAAc,EAAE,iBAAkB,YAAY,YAAY;AAAA,IAClE,UAAU;AAAA,EACV,CAAE,IACF,CAAC;AACL,CAAE;AASK,SAAS,YAAa,OAAQ;AAIpC,SAAO,MAAM;AACd;AAKO,SAAS,oBAAoB;AACnC,aAAY,gDAAgD;AAAA,IAC3D,OAAO;AAAA,IACP,SAAS;AAAA,EACV,CAAE;AACH;AAUO,SAAS,kBAAmB,OAAQ;AAC1C,aAAY,gDAAgD;AAAA,IAC3D,OAAO;AAAA,IACP,aAAa;AAAA,EACd,CAAE;AACF,SAAO,MAAM,WAAW;AACzB;AAUO,SAAS,gBAAiB,OAAQ;AACxC,aAAY,8CAA8C;AAAA,IACzD,OAAO;AAAA,IACP,aAAa;AAAA,EACd,CAAE;AACF,SAAO,MAAM,WAAW;AACzB;AAUO,SAAS,qBAAsB,OAAQ;AAC7C,aAAY,mDAAmD;AAAA,IAC9D,OAAO;AAAA,EACR,CAAE;AAEF,SAAO,MAAM,WAAW;AACzB;AAUO,SAAS,QAAS,OAAQ;AAChC,aAAY,sCAAsC;AAAA,IACjD,OAAO;AAAA,EACR,CAAE;AAEF,SAAO,EAAE,SAAS,MAAM,WAAW,QAAQ;AAC5C;AAWO,IAAM,mBAAmB,uBAAwB,CAAE,WAAY,MAAM;AAC3E,aAAY,+CAA+C;AAAA,IAC1D,OAAO;AAAA,IACP,aAAa;AAAA,EACd,CAAE;AACF,SAAO,OAAQ,WAAY,EAAE,iBAAiB;AAC/C,CAAE;AAWK,IAAM,kCAAkC;AAAA,EAC9C,CAAE,WAAY,MAAM;AACnB;AAAA,MACC;AAAA,MACA;AAAA,QACC,OAAO;AAAA,QACP,SAAS;AAAA,MACV;AAAA,IACD;AACA,WAAO,OAAQ,OAAQ,WAAY,CAAE,EAAE,YAAY;AAAA,EACpD;AACD;AASO,IAAM,mBAAmB,uBAAwB,CAAE,WAAY,MAAM;AAC3E,aAAY,+CAA+C;AAAA,IAC1D,OAAO;AAAA,IACP,aAAa;AAAA,EACd,CAAE;AACF,SAAO,OAAQ,WAAY,EAAE,iBAAiB;AAC/C,CAAE;AASK,SAAS,iBAAkB,OAAQ;AACzC,SAAO,MAAM;AACd;AAEA,SAAS,0BAA2B,QAAS;AAC5C,QAAM,gBAAgB,OAAQ,aAAc,EAAE;AAAA,IAC7C;AAAA,IACA;AAAA,IACA,EAAE,UAAU,GAAG;AAAA,EAChB;AAEA,QAAM,EAAE,iBAAiB,oBAAoB,IAAI,OAAQ,gBAAiB;AAE1E,QAAM,YAAY,gBAAiB,oBAAqB;AACxD,QAAM,SAAS,oBAAqB,SAAU;AAC9C,SAAO,CAAE,QAAQ,aAAc;AAChC;AASO,IAAM,kCAAkC;AAAA,EAC9C,CAAE,WACD;AAAA,IACC,MAAM;AACL;AAAA,QACC;AAAA,QACA;AAAA,UACC,OAAO;AAAA,UACP,SAAS;AAAA,UACT,aAAa;AAAA,QACd;AAAA,MACD;AAEA,aAAO;AAAA,QACN,GAAG,0BAA2B,MAAO;AAAA,MACtC;AAAA,IACD;AAAA,IACA,MAAM,0BAA2B,MAAO;AAAA,EACzC;AACF;AASO,IAAM,gBAAgB,uBAAwB,CAAE,WAAY,MAAM;AACxE,SAAO,OAAQ,gBAAiB,EAAE,IAAK,QAAQ,YAAa;AAC7D,CAAE;AAKK,SAAS,2CAA2C;AAC1D;AAAA,IACC;AAAA,IACA;AAAA,MACC,OAAO;AAAA,MACP,SAAS;AAAA,IACV;AAAA,EACD;AACD;AAKO,SAAS,+BAA+B;AAC9C,aAAY,6DAA6D;AAAA,IACxE,OAAO;AAAA,IACP,SAAS;AAAA,EACV,CAAE;AACH;AAKO,SAAS,qBAAqB;AACpC,aAAY,mDAAmD;AAAA,IAC9D,OAAO;AAAA,IACP,SAAS;AAAA,EACV,CAAE;AACH;AAWO,SAAS,OAAQ,OAAQ;AAC/B,aAAY,qCAAqC;AAAA,IAChD,OAAO;AAAA,IACP,aAAa;AAAA,EACd,CAAE;AAEF,SAAO,CAAC,CAAE,MAAM,WAAW,SAAS;AACrC;AASO,SAAS,sBAAsB;AACrC,aAAY,kDAAkD;AAAA,IAC7D,OAAO;AAAA,EACR,CAAE;AAEF,SAAO;AACR;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,41 +1,42 @@
|
|
|
1
|
+
// packages/edit-site/src/utils/constants.js
|
|
1
2
|
import { __ } from "@wordpress/i18n";
|
|
2
3
|
import { privateApis as patternPrivateApis } from "@wordpress/patterns";
|
|
3
4
|
import { unlock } from "../lock-unlock";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
var NAVIGATION_POST_TYPE = "wp_navigation";
|
|
6
|
+
var TEMPLATE_POST_TYPE = "wp_template";
|
|
7
|
+
var TEMPLATE_PART_POST_TYPE = "wp_template_part";
|
|
8
|
+
var TEMPLATE_ORIGINS = {
|
|
8
9
|
custom: "custom",
|
|
9
10
|
theme: "theme",
|
|
10
11
|
plugin: "plugin"
|
|
11
12
|
};
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
var TEMPLATE_PART_AREA_DEFAULT_CATEGORY = "uncategorized";
|
|
14
|
+
var TEMPLATE_PART_ALL_AREAS_CATEGORY = "all-parts";
|
|
15
|
+
var {
|
|
15
16
|
PATTERN_TYPES,
|
|
16
17
|
PATTERN_DEFAULT_CATEGORY,
|
|
17
18
|
PATTERN_USER_CATEGORY,
|
|
18
19
|
EXCLUDED_PATTERN_SOURCES,
|
|
19
20
|
PATTERN_SYNC_TYPES
|
|
20
21
|
} = unlock(patternPrivateApis);
|
|
21
|
-
|
|
22
|
+
var FOCUSABLE_ENTITIES = [
|
|
22
23
|
TEMPLATE_PART_POST_TYPE,
|
|
23
24
|
NAVIGATION_POST_TYPE,
|
|
24
25
|
PATTERN_TYPES.user
|
|
25
26
|
];
|
|
26
|
-
|
|
27
|
+
var POST_TYPE_LABELS = {
|
|
27
28
|
[TEMPLATE_POST_TYPE]: __("Template"),
|
|
28
29
|
[TEMPLATE_PART_POST_TYPE]: __("Template part"),
|
|
29
30
|
[PATTERN_TYPES.user]: __("Pattern"),
|
|
30
31
|
[NAVIGATION_POST_TYPE]: __("Navigation")
|
|
31
32
|
};
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
33
|
+
var LAYOUT_GRID = "grid";
|
|
34
|
+
var LAYOUT_TABLE = "table";
|
|
35
|
+
var LAYOUT_LIST = "list";
|
|
36
|
+
var OPERATOR_IS = "is";
|
|
37
|
+
var OPERATOR_IS_NOT = "isNot";
|
|
38
|
+
var OPERATOR_IS_ANY = "isAny";
|
|
39
|
+
var OPERATOR_IS_NONE = "isNone";
|
|
39
40
|
export {
|
|
40
41
|
EXCLUDED_PATTERN_SOURCES,
|
|
41
42
|
FOCUSABLE_ENTITIES,
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/constants.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { privateApis as patternPrivateApis } from '@wordpress/patterns';\n\n/**\n * Internal dependencies\n */\nimport { unlock } from '../lock-unlock';\n\n// Navigation\nexport const NAVIGATION_POST_TYPE = 'wp_navigation';\n\n// Templates.\nexport const TEMPLATE_POST_TYPE = 'wp_template';\nexport const TEMPLATE_PART_POST_TYPE = 'wp_template_part';\nexport const TEMPLATE_ORIGINS = {\n\tcustom: 'custom',\n\ttheme: 'theme',\n\tplugin: 'plugin',\n};\nexport const TEMPLATE_PART_AREA_DEFAULT_CATEGORY = 'uncategorized';\nexport const TEMPLATE_PART_ALL_AREAS_CATEGORY = 'all-parts';\n\n// Patterns.\nexport const {\n\tPATTERN_TYPES,\n\tPATTERN_DEFAULT_CATEGORY,\n\tPATTERN_USER_CATEGORY,\n\tEXCLUDED_PATTERN_SOURCES,\n\tPATTERN_SYNC_TYPES,\n} = unlock( patternPrivateApis );\n\n// Entities that are editable in focus mode.\nexport const FOCUSABLE_ENTITIES = [\n\tTEMPLATE_PART_POST_TYPE,\n\tNAVIGATION_POST_TYPE,\n\tPATTERN_TYPES.user,\n];\n\nexport const POST_TYPE_LABELS = {\n\t[ TEMPLATE_POST_TYPE ]: __( 'Template' ),\n\t[ TEMPLATE_PART_POST_TYPE ]: __( 'Template part' ),\n\t[ PATTERN_TYPES.user ]: __( 'Pattern' ),\n\t[ NAVIGATION_POST_TYPE ]: __( 'Navigation' ),\n};\n\n// DataViews constants\nexport const LAYOUT_GRID = 'grid';\nexport const LAYOUT_TABLE = 'table';\nexport const LAYOUT_LIST = 'list';\n\nexport const OPERATOR_IS = 'is';\nexport const OPERATOR_IS_NOT = 'isNot';\nexport const OPERATOR_IS_ANY = 'isAny';\nexport const OPERATOR_IS_NONE = 'isNone';\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,UAAU;AACnB,SAAS,eAAe,0BAA0B;AAKlD,SAAS,cAAc;AAGhB,
|
|
5
|
+
"mappings": ";AAGA,SAAS,UAAU;AACnB,SAAS,eAAe,0BAA0B;AAKlD,SAAS,cAAc;AAGhB,IAAM,uBAAuB;AAG7B,IAAM,qBAAqB;AAC3B,IAAM,0BAA0B;AAChC,IAAM,mBAAmB;AAAA,EAC/B,QAAQ;AAAA,EACR,OAAO;AAAA,EACP,QAAQ;AACT;AACO,IAAM,sCAAsC;AAC5C,IAAM,mCAAmC;AAGzC,IAAM;AAAA,EACZ;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,IAAI,OAAQ,kBAAmB;AAGxB,IAAM,qBAAqB;AAAA,EACjC;AAAA,EACA;AAAA,EACA,cAAc;AACf;AAEO,IAAM,mBAAmB;AAAA,EAC/B,CAAE,kBAAmB,GAAG,GAAI,UAAW;AAAA,EACvC,CAAE,uBAAwB,GAAG,GAAI,eAAgB;AAAA,EACjD,CAAE,cAAc,IAAK,GAAG,GAAI,SAAU;AAAA,EACtC,CAAE,oBAAqB,GAAG,GAAI,YAAa;AAC5C;AAGO,IAAM,cAAc;AACpB,IAAM,eAAe;AACrB,IAAM,cAAc;AAEpB,IAAM,cAAc;AACpB,IAAM,kBAAkB;AACxB,IAAM,kBAAkB;AACxB,IAAM,mBAAmB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
// packages/edit-site/src/utils/get-filtered-template-parts.js
|
|
1
2
|
import { isTemplatePart } from "@wordpress/blocks";
|
|
2
|
-
|
|
3
|
+
var EMPTY_ARRAY = [];
|
|
3
4
|
function getFilteredTemplatePartBlocks(blocks = EMPTY_ARRAY, templateParts) {
|
|
4
5
|
const templatePartsById = templateParts ? (
|
|
5
6
|
// Key template parts by their ID.
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/get-filtered-template-parts.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { isTemplatePart } from '@wordpress/blocks';\n\nconst EMPTY_ARRAY = [];\n\n/**\n * Get a flattened and filtered list of template parts and the matching block for that template part.\n *\n * Takes a list of blocks defined within a template, and a list of template parts, and returns a\n * flattened list of template parts and the matching block for that template part.\n *\n * @param {Array} blocks Blocks to flatten.\n * @param {?Array} templateParts Available template parts.\n * @return {Array} An array of template parts and their blocks.\n */\nexport default function getFilteredTemplatePartBlocks(\n\tblocks = EMPTY_ARRAY,\n\ttemplateParts\n) {\n\tconst templatePartsById = templateParts\n\t\t? // Key template parts by their ID.\n\t\t templateParts.reduce(\n\t\t\t\t( newTemplateParts, part ) => ( {\n\t\t\t\t\t...newTemplateParts,\n\t\t\t\t\t[ part.id ]: part,\n\t\t\t\t} ),\n\t\t\t\t{}\n\t\t )\n\t\t: {};\n\n\tconst result = [];\n\n\t// Iterate over all blocks, recursing into inner blocks.\n\t// Output will be based on a depth-first traversal.\n\tconst stack = [ ...blocks ];\n\twhile ( stack.length ) {\n\t\tconst { innerBlocks, ...block } = stack.shift();\n\t\t// Place inner blocks at the beginning of the stack to preserve order.\n\t\tstack.unshift( ...innerBlocks );\n\n\t\tif ( isTemplatePart( block ) ) {\n\t\t\tconst {\n\t\t\t\tattributes: { theme, slug },\n\t\t\t} = block;\n\t\t\tconst templatePartId = `${ theme }//${ slug }`;\n\t\t\tconst templatePart = templatePartsById[ templatePartId ];\n\n\t\t\t// Only add to output if the found template part block is in the list of available template parts.\n\t\t\tif ( templatePart ) {\n\t\t\t\tresult.push( {\n\t\t\t\t\ttemplatePart,\n\t\t\t\t\tblock,\n\t\t\t\t} );\n\t\t\t}\n\t\t}\n\t}\n\n\treturn result;\n}\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,sBAAsB;AAE/B,
|
|
5
|
+
"mappings": ";AAGA,SAAS,sBAAsB;AAE/B,IAAM,cAAc,CAAC;AAYN,SAAR,8BACN,SAAS,aACT,eACC;AACD,QAAM,oBAAoB;AAAA;AAAA,IAEvB,cAAc;AAAA,MACd,CAAE,kBAAkB,UAAY;AAAA,QAC/B,GAAG;AAAA,QACH,CAAE,KAAK,EAAG,GAAG;AAAA,MACd;AAAA,MACA,CAAC;AAAA,IACD;AAAA,MACA,CAAC;AAEJ,QAAM,SAAS,CAAC;AAIhB,QAAM,QAAQ,CAAE,GAAG,MAAO;AAC1B,SAAQ,MAAM,QAAS;AACtB,UAAM,EAAE,aAAa,GAAG,MAAM,IAAI,MAAM,MAAM;AAE9C,UAAM,QAAS,GAAG,WAAY;AAE9B,QAAK,eAAgB,KAAM,GAAI;AAC9B,YAAM;AAAA,QACL,YAAY,EAAE,OAAO,KAAK;AAAA,MAC3B,IAAI;AACJ,YAAM,iBAAiB,GAAI,KAAM,KAAM,IAAK;AAC5C,YAAM,eAAe,kBAAmB,cAAe;AAGvD,UAAK,cAAe;AACnB,eAAO,KAAM;AAAA,UACZ;AAAA,UACA;AAAA,QACD,CAAE;AAAA,MACH;AAAA,IACD;AAAA,EACD;AAEA,SAAO;AACR;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/is-previewing-theme.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { getQueryArg } from '@wordpress/url';\n\nexport function isPreviewingTheme() {\n\treturn !! getQueryArg( window.location.href, 'wp_theme_preview' );\n}\n\nexport function currentlyPreviewingTheme() {\n\tif ( isPreviewingTheme() ) {\n\t\treturn getQueryArg( window.location.href, 'wp_theme_preview' );\n\t}\n\treturn null;\n}\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,mBAAmB;AAErB,SAAS,oBAAoB;AACnC,SAAO,CAAC,CAAE,YAAa,OAAO,SAAS,MAAM,kBAAmB;AACjE;AAEO,SAAS,2BAA2B;AAC1C,MAAK,kBAAkB,GAAI;AAC1B,WAAO,YAAa,OAAO,SAAS,MAAM,kBAAmB;AAAA,EAC9D;AACA,SAAO;AACR;",
|
|
5
|
+
"mappings": ";AAGA,SAAS,mBAAmB;AAErB,SAAS,oBAAoB;AACnC,SAAO,CAAC,CAAE,YAAa,OAAO,SAAS,MAAM,kBAAmB;AACjE;AAEO,SAAS,2BAA2B;AAC1C,MAAK,kBAAkB,GAAI;AAC1B,WAAO,YAAa,OAAO,SAAS,MAAM,kBAAmB;AAAA,EAC9D;AACA,SAAO;AACR;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/is-template-removable.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * Internal dependencies\n */\nimport { TEMPLATE_ORIGINS } from './constants';\n\n/**\n * Check if a template is removable.\n *\n * @param {Object} template The template entity to check.\n * @return {boolean} Whether the template is removable.\n */\nexport default function isTemplateRemovable( template ) {\n\tif ( ! template ) {\n\t\treturn false;\n\t}\n\n\treturn (\n\t\ttemplate.source === TEMPLATE_ORIGINS.custom &&\n\t\t! Boolean( template.plugin ) &&\n\t\t! template.has_theme_file\n\t);\n}\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,wBAAwB;AAQlB,SAAR,oBAAsC,UAAW;AACvD,MAAK,CAAE,UAAW;AACjB,WAAO;AAAA,EACR;AAEA,SACC,SAAS,WAAW,iBAAiB,UACrC,CAAE,QAAS,SAAS,MAAO,KAC3B,CAAE,SAAS;AAEb;",
|
|
5
|
+
"mappings": ";AAGA,SAAS,wBAAwB;AAQlB,SAAR,oBAAsC,UAAW;AACvD,MAAK,CAAE,UAAW;AACjB,WAAO;AAAA,EACR;AAEA,SACC,SAAS,WAAW,iBAAiB,UACrC,CAAE,QAAS,SAAS,MAAO,KAC3B,CAAE,SAAS;AAEb;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/is-template-revertable.js"],
|
|
4
|
-
"sourcesContent": ["/**\n * Internal dependencies\n */\nimport { TEMPLATE_ORIGINS } from './constants';\n\n/**\n * Check if a template is revertable to its original theme-provided template file.\n *\n * @param {Object} template The template entity to check.\n * @return {boolean} Whether the template is revertable.\n */\nexport default function isTemplateRevertable( template ) {\n\tif ( ! template ) {\n\t\treturn false;\n\t}\n\
|
|
5
|
-
"mappings": "AAGA,SAAS,wBAAwB;AAQlB,SAAR,qBAAuC,UAAW;AACxD,MAAK,CAAE,UAAW;AACjB,WAAO;AAAA,EACR;AAEA,SACC,UAAU,WAAW,iBAAiB,WACpC,QAAS,UAAU,MAAO,KAAK,UAAU;
|
|
4
|
+
"sourcesContent": ["/**\n * Internal dependencies\n */\nimport { TEMPLATE_ORIGINS } from './constants';\n\n/**\n * Check if a template is revertable to its original theme-provided template file.\n *\n * @param {Object} template The template entity to check.\n * @return {boolean} Whether the template is revertable.\n */\nexport default function isTemplateRevertable( template ) {\n\tif ( ! template ) {\n\t\treturn false;\n\t}\n\n\treturn (\n\t\ttemplate?.source === TEMPLATE_ORIGINS.custom &&\n\t\t( Boolean( template?.plugin ) || template?.has_theme_file )\n\t);\n}\n"],
|
|
5
|
+
"mappings": ";AAGA,SAAS,wBAAwB;AAQlB,SAAR,qBAAuC,UAAW;AACxD,MAAK,CAAE,UAAW;AACjB,WAAO;AAAA,EACR;AAEA,SACC,UAAU,WAAW,iBAAiB,WACpC,QAAS,UAAU,MAAO,KAAK,UAAU;AAE7C;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
// packages/edit-site/src/utils/use-activate-theme.js
|
|
1
2
|
import { store as coreStore } from "@wordpress/core-data";
|
|
2
3
|
import { useDispatch } from "@wordpress/data";
|
|
3
4
|
import { privateApis as routerPrivateApis } from "@wordpress/router";
|
|
@@ -7,7 +8,7 @@ import {
|
|
|
7
8
|
isPreviewingTheme,
|
|
8
9
|
currentlyPreviewingTheme
|
|
9
10
|
} from "./is-previewing-theme";
|
|
10
|
-
|
|
11
|
+
var { useHistory, useLocation } = unlock(routerPrivateApis);
|
|
11
12
|
function useActivateTheme() {
|
|
12
13
|
const history = useHistory();
|
|
13
14
|
const { path } = useLocation();
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/use-activate-theme.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { store as coreStore } from '@wordpress/core-data';\nimport { useDispatch } from '@wordpress/data';\nimport { privateApis as routerPrivateApis } from '@wordpress/router';\nimport { addQueryArgs } from '@wordpress/url';\n\n/**\n * Internal dependencies\n */\nimport { unlock } from '../lock-unlock';\nimport {\n\tisPreviewingTheme,\n\tcurrentlyPreviewingTheme,\n} from './is-previewing-theme';\n\nconst { useHistory, useLocation } = unlock( routerPrivateApis );\n\n/**\n * This should be refactored to use the REST API, once the REST API can activate themes.\n *\n * @return {Function} A function that activates the theme.\n */\nexport function useActivateTheme() {\n\tconst history = useHistory();\n\tconst { path } = useLocation();\n\tconst { startResolution, finishResolution } = useDispatch( coreStore );\n\n\treturn async () => {\n\t\tif ( isPreviewingTheme() ) {\n\t\t\tconst activationURL =\n\t\t\t\t'themes.php?action=activate&stylesheet=' +\n\t\t\t\tcurrentlyPreviewingTheme() +\n\t\t\t\t'&_wpnonce=' +\n\t\t\t\twindow.WP_BLOCK_THEME_ACTIVATE_NONCE;\n\t\t\tstartResolution( 'activateTheme' );\n\t\t\tawait window.fetch( activationURL );\n\t\t\tfinishResolution( 'activateTheme' );\n\t\t\t// Remove the wp_theme_preview query param: we've finished activating\n\t\t\t// the queue and are switching to normal Site Editor.\n\t\t\thistory.navigate( addQueryArgs( path, { wp_theme_preview: '' } ) );\n\t\t}\n\t};\n}\n"],
|
|
5
|
-
"mappings": "AAGA,SAAS,SAAS,iBAAiB;AACnC,SAAS,mBAAmB;AAC5B,SAAS,eAAe,yBAAyB;AACjD,SAAS,oBAAoB;AAK7B,SAAS,cAAc;AACvB;AAAA,EACC;AAAA,EACA;AAAA,OACM;AAEP,
|
|
5
|
+
"mappings": ";AAGA,SAAS,SAAS,iBAAiB;AACnC,SAAS,mBAAmB;AAC5B,SAAS,eAAe,yBAAyB;AACjD,SAAS,oBAAoB;AAK7B,SAAS,cAAc;AACvB;AAAA,EACC;AAAA,EACA;AAAA,OACM;AAEP,IAAM,EAAE,YAAY,YAAY,IAAI,OAAQ,iBAAkB;AAOvD,SAAS,mBAAmB;AAClC,QAAM,UAAU,WAAW;AAC3B,QAAM,EAAE,KAAK,IAAI,YAAY;AAC7B,QAAM,EAAE,iBAAiB,iBAAiB,IAAI,YAAa,SAAU;AAErE,SAAO,YAAY;AAClB,QAAK,kBAAkB,GAAI;AAC1B,YAAM,gBACL,2CACA,yBAAyB,IACzB,eACA,OAAO;AACR,sBAAiB,eAAgB;AACjC,YAAM,OAAO,MAAO,aAAc;AAClC,uBAAkB,eAAgB;AAGlC,cAAQ,SAAU,aAAc,MAAM,EAAE,kBAAkB,GAAG,CAAE,CAAE;AAAA,IAClE;AAAA,EACD;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
// packages/edit-site/src/utils/use-actual-current-theme.js
|
|
1
2
|
import apiFetch from "@wordpress/api-fetch";
|
|
2
3
|
import { useState, useEffect } from "@wordpress/element";
|
|
3
4
|
import { addQueryArgs } from "@wordpress/url";
|
|
4
|
-
|
|
5
|
+
var ACTIVE_THEMES_URL = "/wp/v2/themes?status=active";
|
|
5
6
|
function useActualCurrentTheme() {
|
|
6
7
|
const [currentTheme, setCurrentTheme] = useState();
|
|
7
8
|
useEffect(() => {
|
|
@@ -2,6 +2,6 @@
|
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/utils/use-actual-current-theme.js"],
|
|
4
4
|
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport apiFetch from '@wordpress/api-fetch';\nimport { useState, useEffect } from '@wordpress/element';\nimport { addQueryArgs } from '@wordpress/url';\n\nconst ACTIVE_THEMES_URL = '/wp/v2/themes?status=active';\n\nexport function useActualCurrentTheme() {\n\tconst [ currentTheme, setCurrentTheme ] = useState();\n\n\tuseEffect( () => {\n\t\t// Set the `wp_theme_preview` to empty string to bypass the createThemePreviewMiddleware.\n\t\tconst path = addQueryArgs( ACTIVE_THEMES_URL, {\n\t\t\tcontext: 'edit',\n\t\t\twp_theme_preview: '',\n\t\t} );\n\n\t\tapiFetch( { path } )\n\t\t\t.then( ( activeThemes ) => setCurrentTheme( activeThemes[ 0 ] ) )\n\t\t\t// Do nothing\n\t\t\t.catch( () => {} );\n\t}, [] );\n\n\treturn currentTheme;\n}\n"],
|
|
5
|
-
"mappings": "AAGA,OAAO,cAAc;AACrB,SAAS,UAAU,iBAAiB;AACpC,SAAS,oBAAoB;AAE7B,
|
|
5
|
+
"mappings": ";AAGA,OAAO,cAAc;AACrB,SAAS,UAAU,iBAAiB;AACpC,SAAS,oBAAoB;AAE7B,IAAM,oBAAoB;AAEnB,SAAS,wBAAwB;AACvC,QAAM,CAAE,cAAc,eAAgB,IAAI,SAAS;AAEnD,YAAW,MAAM;AAEhB,UAAM,OAAO,aAAc,mBAAmB;AAAA,MAC7C,SAAS;AAAA,MACT,kBAAkB;AAAA,IACnB,CAAE;AAEF,aAAU,EAAE,KAAK,CAAE,EACjB,KAAM,CAAE,iBAAkB,gBAAiB,aAAc,CAAE,CAAE,CAAE,EAE/D,MAAO,MAAM;AAAA,IAAC,CAAE;AAAA,EACnB,GAAG,CAAC,CAAE;AAEN,SAAO;AACR;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -1234,45 +1234,8 @@
|
|
|
1234
1234
|
grid-column: span 2;
|
|
1235
1235
|
}
|
|
1236
1236
|
}
|
|
1237
|
-
.dataviews-
|
|
1238
|
-
|
|
1239
|
-
}
|
|
1240
|
-
|
|
1241
|
-
.dataviews-field-control__actions {
|
|
1242
|
-
position: absolute;
|
|
1243
|
-
top: -9999em;
|
|
1244
|
-
}
|
|
1245
|
-
|
|
1246
|
-
.dataviews-field-control__actions.dataviews-field-control__actions {
|
|
1247
|
-
gap: 4px;
|
|
1248
|
-
}
|
|
1249
|
-
|
|
1250
|
-
.dataviews-field-control__field:hover .dataviews-field-control__actions,
|
|
1251
|
-
.dataviews-field-control__field:focus-within .dataviews-field-control__actions,
|
|
1252
|
-
.dataviews-field-control__field.is-interacting .dataviews-field-control__actions {
|
|
1253
|
-
position: unset;
|
|
1254
|
-
top: unset;
|
|
1255
|
-
}
|
|
1256
|
-
|
|
1257
|
-
.dataviews-field-control__icon {
|
|
1258
|
-
display: flex;
|
|
1259
|
-
width: 24px;
|
|
1260
|
-
}
|
|
1261
|
-
|
|
1262
|
-
.dataviews-field-control__label-sub-label-container {
|
|
1263
|
-
flex-grow: 1;
|
|
1264
|
-
}
|
|
1265
|
-
|
|
1266
|
-
.dataviews-field-control__label {
|
|
1267
|
-
display: block;
|
|
1268
|
-
}
|
|
1269
|
-
|
|
1270
|
-
.dataviews-field-control__sub-label {
|
|
1271
|
-
margin-top: 8px;
|
|
1272
|
-
margin-bottom: 0;
|
|
1273
|
-
font-size: 11px;
|
|
1274
|
-
font-style: normal;
|
|
1275
|
-
color: #757575;
|
|
1237
|
+
.dataviews-view-config__label {
|
|
1238
|
+
text-wrap: nowrap;
|
|
1276
1239
|
}
|
|
1277
1240
|
|
|
1278
1241
|
.dataviews-view-grid-items {
|
|
@@ -1758,7 +1721,6 @@ div.dataviews-view-list {
|
|
|
1758
1721
|
.dataviews-view-table td.dataviews-view-table__checkbox-column,
|
|
1759
1722
|
.dataviews-view-table th.dataviews-view-table__checkbox-column {
|
|
1760
1723
|
padding-left: 0;
|
|
1761
|
-
width: 1%;
|
|
1762
1724
|
}
|
|
1763
1725
|
|
|
1764
1726
|
.dataviews-view-table td.dataviews-view-table__checkbox-column .dataviews-view-table__cell-content-wrapper,
|
|
@@ -1880,6 +1842,7 @@ div.dataviews-view-list {
|
|
|
1880
1842
|
min-height: 32px;
|
|
1881
1843
|
display: flex;
|
|
1882
1844
|
align-items: center;
|
|
1845
|
+
white-space: nowrap;
|
|
1883
1846
|
}
|
|
1884
1847
|
|
|
1885
1848
|
.dataviews-view-table tbody .dataviews-view-table__cell-content-wrapper.dataviews-view-table__cell-align-end {
|
|
@@ -2003,6 +1966,11 @@ div.dataviews-view-list {
|
|
|
2003
1966
|
color: #1e1e1e;
|
|
2004
1967
|
}
|
|
2005
1968
|
|
|
1969
|
+
/* Column width intents via colgroup: make non-primary columns shrink-to-fit */
|
|
1970
|
+
.dataviews-view-table col[class^=dataviews-view-table__col-]:not(.dataviews-view-table__col-primary) {
|
|
1971
|
+
width: 1%;
|
|
1972
|
+
}
|
|
1973
|
+
|
|
2006
1974
|
.dataviews-view-picker-grid .dataviews-view-picker-grid__card {
|
|
2007
1975
|
height: 100%;
|
|
2008
1976
|
justify-content: flex-start;
|
|
@@ -2162,6 +2130,35 @@ div.dataviews-view-list {
|
|
|
2162
2130
|
padding: 0 48px;
|
|
2163
2131
|
}
|
|
2164
2132
|
|
|
2133
|
+
.dataviews-view-picker-table tbody:focus-visible[aria-activedescendant] {
|
|
2134
|
+
outline: none;
|
|
2135
|
+
}
|
|
2136
|
+
|
|
2137
|
+
.dataviews-view-picker-table tbody:focus-visible [data-active-item=true] {
|
|
2138
|
+
outline: 2px solid var(--wp-admin-theme-color);
|
|
2139
|
+
}
|
|
2140
|
+
|
|
2141
|
+
.dataviews-view-picker-table .dataviews-selection-checkbox .components-checkbox-control__input.components-checkbox-control__input {
|
|
2142
|
+
pointer-events: none;
|
|
2143
|
+
opacity: 1;
|
|
2144
|
+
}
|
|
2145
|
+
|
|
2146
|
+
.dataviews-view-picker-table .dataviews-view-table__row {
|
|
2147
|
+
cursor: pointer;
|
|
2148
|
+
}
|
|
2149
|
+
|
|
2150
|
+
.dataviews-view-picker-table .dataviews-view-table__row.is-selected {
|
|
2151
|
+
background-color: rgba(var(--wp-admin-theme-color--rgb), 0.04);
|
|
2152
|
+
}
|
|
2153
|
+
|
|
2154
|
+
.dataviews-view-picker-table .dataviews-view-table__row.is-hovered {
|
|
2155
|
+
background-color: rgba(var(--wp-admin-theme-color--rgb), 0.08);
|
|
2156
|
+
}
|
|
2157
|
+
|
|
2158
|
+
.dataviews-view-picker-table .dataviews-view-table__row.is-selected.is-hovered {
|
|
2159
|
+
background-color: rgba(var(--wp-admin-theme-color--rgb), 0.12);
|
|
2160
|
+
}
|
|
2161
|
+
|
|
2165
2162
|
.dataviews-controls__datetime {
|
|
2166
2163
|
border: none;
|
|
2167
2164
|
padding: 0;
|
|
@@ -2300,6 +2297,10 @@ div.dataviews-view-list {
|
|
|
2300
2297
|
gap: 16px;
|
|
2301
2298
|
}
|
|
2302
2299
|
|
|
2300
|
+
.dataforms-layouts-details__content {
|
|
2301
|
+
padding-top: 12px;
|
|
2302
|
+
}
|
|
2303
|
+
|
|
2303
2304
|
.dataforms-layouts-row__field-control {
|
|
2304
2305
|
width: 100%;
|
|
2305
2306
|
}
|