@wordpress/edit-post 8.32.0 → 8.32.1-next.ff1cebbba.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/build/commands/use-commands.js +54 -47
- package/build/commands/use-commands.js.map +7 -1
- package/build/components/back-button/fullscreen-mode-close.js +127 -118
- package/build/components/back-button/fullscreen-mode-close.js.map +7 -1
- package/build/components/back-button/index.js +56 -54
- package/build/components/back-button/index.js.map +7 -1
- package/build/components/browser-url/index.js +45 -44
- package/build/components/browser-url/index.js.map +7 -1
- package/build/components/editor-initialization/index.js +24 -18
- package/build/components/editor-initialization/index.js.map +7 -1
- package/build/components/editor-initialization/listener-hooks.js +42 -43
- package/build/components/editor-initialization/listener-hooks.js.map +7 -1
- package/build/components/init-pattern-modal/index.js +100 -79
- package/build/components/init-pattern-modal/index.js.map +7 -1
- package/build/components/keyboard-shortcuts/index.js +37 -33
- package/build/components/keyboard-shortcuts/index.js.map +7 -1
- package/build/components/layout/index.js +447 -467
- package/build/components/layout/index.js.map +7 -1
- package/build/components/layout/use-padding-appender.js +66 -59
- package/build/components/layout/use-padding-appender.js.map +7 -1
- package/build/components/layout/use-should-iframe.js +36 -30
- package/build/components/layout/use-should-iframe.js.map +7 -1
- package/build/components/meta-boxes/index.js +46 -33
- package/build/components/meta-boxes/index.js.map +7 -1
- package/build/components/meta-boxes/meta-box-visibility.js +37 -22
- package/build/components/meta-boxes/meta-box-visibility.js.map +7 -1
- package/build/components/meta-boxes/meta-boxes-area/index.js +62 -53
- package/build/components/meta-boxes/meta-boxes-area/index.js.map +7 -1
- package/build/components/meta-boxes/use-meta-box-initialization.js +37 -32
- package/build/components/meta-boxes/use-meta-box-initialization.js.map +7 -1
- package/build/components/more-menu/index.js +64 -44
- package/build/components/more-menu/index.js.map +7 -1
- package/build/components/more-menu/manage-patterns-menu-item.js +39 -37
- package/build/components/more-menu/manage-patterns-menu-item.js.map +7 -1
- package/build/components/more-menu/welcome-guide-menu-item.js +39 -21
- package/build/components/more-menu/welcome-guide-menu-item.js.map +7 -1
- package/build/components/preferences-modal/enable-custom-fields.js +76 -66
- package/build/components/preferences-modal/enable-custom-fields.js.map +7 -1
- package/build/components/preferences-modal/enable-panel.js +47 -43
- package/build/components/preferences-modal/enable-panel.js.map +7 -1
- package/build/components/preferences-modal/index.js +51 -39
- package/build/components/preferences-modal/index.js.map +7 -1
- package/build/components/preferences-modal/meta-boxes-section.js +65 -52
- package/build/components/preferences-modal/meta-boxes-section.js.map +7 -1
- package/build/components/welcome-guide/default.js +134 -97
- package/build/components/welcome-guide/default.js.map +7 -1
- package/build/components/welcome-guide/image.js +34 -23
- package/build/components/welcome-guide/image.js.map +7 -1
- package/build/components/welcome-guide/index.js +51 -38
- package/build/components/welcome-guide/index.js.map +7 -1
- package/build/components/welcome-guide/template.js +65 -45
- package/build/components/welcome-guide/template.js.map +7 -1
- package/build/deprecated.js +84 -110
- package/build/deprecated.js.map +7 -1
- package/build/hooks/use-navigate-to-entity-record.js +60 -78
- package/build/hooks/use-navigate-to-entity-record.js.map +7 -1
- package/build/index.js +101 -136
- package/build/index.js.map +7 -1
- package/build/lock-unlock.js +31 -15
- package/build/lock-unlock.js.map +7 -1
- package/build/store/actions.js +239 -431
- package/build/store/actions.js.map +7 -1
- package/build/store/constants.js +33 -26
- package/build/store/constants.js.map +7 -1
- package/build/store/index.js +44 -32
- package/build/store/index.js.map +7 -1
- package/build/store/reducer.js +50 -57
- package/build/store/reducer.js.map +7 -1
- package/build/store/selectors.js +288 -459
- package/build/store/selectors.js.map +7 -1
- package/build/utils/meta-boxes.js +31 -19
- package/build/utils/meta-boxes.js.map +7 -1
- package/build-module/commands/use-commands.js +35 -40
- package/build-module/commands/use-commands.js.map +7 -1
- package/build-module/components/back-button/fullscreen-mode-close.js +102 -110
- package/build-module/components/back-button/fullscreen-mode-close.js.map +7 -1
- package/build-module/components/back-button/index.js +28 -47
- package/build-module/components/back-button/index.js.map +7 -1
- package/build-module/components/browser-url/index.js +23 -38
- package/build-module/components/browser-url/index.js.map +7 -1
- package/build-module/components/editor-initialization/index.js +6 -13
- package/build-module/components/editor-initialization/index.js.map +7 -1
- package/build-module/components/editor-initialization/listener-hooks.js +20 -34
- package/build-module/components/editor-initialization/listener-hooks.js.map +7 -1
- package/build-module/components/init-pattern-modal/index.js +90 -74
- package/build-module/components/init-pattern-modal/index.js.map +7 -1
- package/build-module/components/keyboard-shortcuts/index.js +21 -26
- package/build-module/components/keyboard-shortcuts/index.js.map +7 -1
- package/build-module/components/layout/index.js +439 -448
- package/build-module/components/layout/index.js.map +7 -1
- package/build-module/components/layout/use-padding-appender.js +44 -54
- package/build-module/components/layout/use-padding-appender.js.map +7 -1
- package/build-module/components/layout/use-should-iframe.js +15 -25
- package/build-module/components/layout/use-should-iframe.js.map +7 -1
- package/build-module/components/meta-boxes/index.js +18 -26
- package/build-module/components/meta-boxes/index.js.map +7 -1
- package/build-module/components/meta-boxes/meta-box-visibility.js +18 -15
- package/build-module/components/meta-boxes/meta-box-visibility.js.map +7 -1
- package/build-module/components/meta-boxes/meta-boxes-area/index.js +30 -44
- package/build-module/components/meta-boxes/meta-boxes-area/index.js.map +7 -1
- package/build-module/components/meta-boxes/use-meta-box-initialization.js +14 -25
- package/build-module/components/meta-boxes/use-meta-box-initialization.js.map +7 -1
- package/build-module/components/more-menu/index.js +36 -37
- package/build-module/components/more-menu/index.js.map +7 -1
- package/build-module/components/more-menu/manage-patterns-menu-item.js +21 -31
- package/build-module/components/more-menu/manage-patterns-menu-item.js.map +7 -1
- package/build-module/components/more-menu/welcome-guide-menu-item.js +22 -16
- package/build-module/components/more-menu/welcome-guide-menu-item.js.map +7 -1
- package/build-module/components/preferences-modal/enable-custom-fields.js +51 -56
- package/build-module/components/preferences-modal/enable-custom-fields.js.map +7 -1
- package/build-module/components/preferences-modal/enable-panel.js +30 -38
- package/build-module/components/preferences-modal/enable-panel.js.map +7 -1
- package/build-module/components/preferences-modal/index.js +24 -34
- package/build-module/components/preferences-modal/index.js.map +7 -1
- package/build-module/components/preferences-modal/meta-boxes-section.js +34 -45
- package/build-module/components/preferences-modal/meta-boxes-section.js.map +7 -1
- package/build-module/components/welcome-guide/default.js +107 -91
- package/build-module/components/welcome-guide/default.js.map +7 -1
- package/build-module/components/welcome-guide/image.js +16 -18
- package/build-module/components/welcome-guide/image.js.map +7 -1
- package/build-module/components/welcome-guide/index.js +23 -31
- package/build-module/components/welcome-guide/index.js.map +7 -1
- package/build-module/components/welcome-guide/template.js +38 -39
- package/build-module/components/welcome-guide/template.js.map +7 -1
- package/build-module/deprecated.js +62 -103
- package/build-module/deprecated.js.map +7 -1
- package/build-module/hooks/use-navigate-to-entity-record.js +42 -73
- package/build-module/hooks/use-navigate-to-entity-record.js.map +7 -1
- package/build-module/index.js +70 -95
- package/build-module/index.js.map +7 -1
- package/build-module/lock-unlock.js +8 -7
- package/build-module/lock-unlock.js.map +7 -1
- package/build-module/store/actions.js +158 -368
- package/build-module/store/actions.js.map +7 -1
- package/build-module/store/constants.js +9 -21
- package/build-module/store/constants.js.map +7 -1
- package/build-module/store/index.js +10 -22
- package/build-module/store/index.js.map +7 -1
- package/build-module/store/reducer.js +28 -51
- package/build-module/store/reducer.js.map +7 -1
- package/build-module/store/selectors.js +232 -442
- package/build-module/store/selectors.js.map +7 -1
- package/build-module/utils/meta-boxes.js +9 -13
- package/build-module/utils/meta-boxes.js.map +7 -1
- package/build-style/classic-rtl.css +0 -154
- package/build-style/classic.css +0 -154
- package/build-style/style-rtl.css +135 -110
- package/build-style/style.css +135 -110
- package/package.json +39 -31
- package/src/classic.scss +3 -0
- package/src/components/back-button/style.scss +3 -0
- package/src/components/layout/index.js +3 -2
- package/src/components/layout/style.scss +4 -0
- package/src/components/meta-boxes/meta-boxes-area/style.scss +3 -0
- package/src/components/welcome-guide/style.scss +3 -0
- package/src/style.scss +8 -4
- package/build/components/header/header-toolbar/index.native.js +0 -204
- package/build/components/header/header-toolbar/index.native.js.map +0 -1
- package/build/components/header/index.native.js +0 -59
- package/build/components/header/index.native.js.map +0 -1
- package/build/components/layout/index.native.js +0 -166
- package/build/components/layout/index.native.js.map +0 -1
- package/build/components/visual-editor/header.native.js +0 -63
- package/build/components/visual-editor/header.native.js.map +0 -1
- package/build/components/visual-editor/index.native.js +0 -44
- package/build/components/visual-editor/index.native.js.map +0 -1
- package/build/editor.native.js +0 -157
- package/build/editor.native.js.map +0 -1
- package/build/index.native.js +0 -58
- package/build/index.native.js.map +0 -1
- package/build-module/components/header/header-toolbar/index.native.js +0 -196
- package/build-module/components/header/header-toolbar/index.native.js.map +0 -1
- package/build-module/components/header/index.native.js +0 -50
- package/build-module/components/header/index.native.js.map +0 -1
- package/build-module/components/layout/index.native.js +0 -158
- package/build-module/components/layout/index.native.js.map +0 -1
- package/build-module/components/visual-editor/header.native.js +0 -56
- package/build-module/components/visual-editor/header.native.js.map +0 -1
- package/build-module/components/visual-editor/index.native.js +0 -35
- package/build-module/components/visual-editor/index.native.js.map +0 -1
- package/build-module/editor.native.js +0 -149
- package/build-module/editor.native.js.map +0 -1
- package/build-module/index.native.js +0 -45
- package/build-module/index.native.js.map +0 -1
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{"version":3,"names":["_clsx","_interopRequireDefault","require","_editor","_data","_blockEditor","_plugins","_i18n","_element","_icons","_notices","_preferences","_commands","_blockLibrary","_url","_htmlEntities","_coreData","_components","_compose","_backButton","_editorInitialization","_keyboardShortcuts","_initPatternModal","_browserUrl","_metaBoxes","_moreMenu","_welcomeGuide","_store","_lockUnlock","_useCommands","_usePaddingAppender","_useShouldIframe","_useNavigateToEntityRecord","_useMetaBoxInitialization","_jsxRuntime","getLayoutStyles","unlock","blockEditorPrivateApis","useCommandContext","commandsPrivateApis","Editor","FullscreenMode","NavigableRegion","editorPrivateApis","BlockKeyboardShortcuts","blockLibraryPrivateApis","DESIGN_POST_TYPES","useEditorStyles","additionalStyles","hasThemeStyleSupport","editorSettings","useSelect","select","editPostStore","isFeatureActive","editorStore","getEditorSettings","addedStyles","join","useMemo","_editorSettings$style","_editorSettings$defau","_editorSettings$style2","_editorSettings$style3","presetStyles","styles","filter","style","__unstableType","defaultEditorStyles","hasThemeStyles","length","disableLayoutStyles","push","css","selector","hasBlockGapSupport","hasFallbackGapSupport","fallbackGapValue","baseStyles","MetaBoxesMain","isLegacy","isOpen","openHeight","hasAnyVisible","get","preferencesStore","isMetaBoxLocationVisible","set","setPreference","useDispatch","metaBoxesMainRef","useRef","isShort","useMediaQuery","min","max","setHeightConstraints","useState","effectSizeConstraints","useRefEffect","node","container","closest","noticeLists","querySelectorAll","resizeHandle","querySelector","deriveConstraints","fullHeight","offsetHeight","nextMax","element","nextMin","observer","window","ResizeObserver","observe","disconnect","resizeDataRef","separatorRef","separatorHelpId","useId","applyHeight","candidateHeight","isPersistent","isInstant","Math","current","ariaValueNow","getAriaValueNow","updateSize","height","width","getRenderValues","useEvent","useEffect","fresh","undefined","usedOpenHeight","usedHeight","contents","jsxs","className","hidden","children","jsx","default","location","isAutoHeight","round","usedAriaValueNow","persistIsOpen","to","onSeparatorKeyDown","event","delta","ArrowUp","ArrowDown","key","pane","resizable","fromHeight","nextHeight","preventDefault","paneLabel","__","toggle","onClick","detail","isToggleInferred","onMouseDown","stopPropagation","onTouchStart","Icon","icon","chevronUp","chevronDown","separator","Fragment","Tooltip","text","ref","role","onKeyDown","VisuallyHidden","id","paneProps","as","defaultSize","minHeight","maxHeight","enable","top","handleClasses","handleComponent","onPointerDown","pointerId","target","parentElement","contains","setPointerCapture","onResizeStart","timeStamp","direction","elementRef","classList","add","maxDelta","onResize","newDelta","abs","state","onResizeStop","remove","duration","wasSeparator","nextIsOpen","ResizableBox","Layout","postId","initialPostId","postType","initialPostType","settings","initialEdits","useEditPostCommands","shouldIframe","useShouldIframe","createErrorNotice","noticesStore","currentPost","currentPostId","currentPostType","onNavigateToEntityRecord","onNavigateToPreviousEntityRecord","useNavigateToEntityRecord","isEditingTemplate","mode","isFullscreenActive","hasResolvedMode","hasActiveMetaboxes","hasBlockSelected","showIconLabels","isDistractionFree","showMetaBoxes","isWelcomeGuideVisible","templateId","enablePaddingAppender","isDevicePreview","_getPostType$viewable","hasMetaBoxes","canUser","getPostType","getTemplateId","coreStore","supportsTemplateMode","isViewable","viewable","canViewTemplate","kind","name","getBlockSelectionStart","isZoomOut","blockEditorStore","getEditorMode","getRenderingMode","getDefaultRenderingMode","getDeviceType","isRenderingPostOnly","isNotDesignPostType","includes","isDirectlyEditingPattern","_templateId","defaultMode","useMetaBoxInitialization","editableResolvedTemplateId","getTemplateAutoDraftId","paddingAppenderRef","paddingStyle","usePaddingAppender","commandContext","defaultRenderingMode","document","body","navigateRegionsProps","useNavigateRegions","clsx","onPluginAreaError","sprintf","createSuccessNotice","onActionPerformed","useCallback","actionId","items","href","addQueryArgs","trashed","post_type","type","ids","newItem","title","rendered","decodeEntities","actions","label","post","action","initialPost","backButton","useViewportMatch","SlotFillProvider","ErrorBoundary","canCopyContent","forceIsDirty","contentRef","disableIframe","autoFocus","extraSidebarPanels","extraContent","PostLockedModal","isActive","UnsavedChangesWarning","AutosaveMonitor","LocalAutosaveMonitor","EditorKeyboardShortcutsRegister","PluginArea","onError","EditorSnackbars","_default","exports"],"sources":["@wordpress/edit-post/src/components/layout/index.js"],"sourcesContent":["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tAutosaveMonitor,\n\tLocalAutosaveMonitor,\n\tUnsavedChangesWarning,\n\tEditorKeyboardShortcutsRegister,\n\tEditorSnackbars,\n\tErrorBoundary,\n\tPostLockedModal,\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport {\n\tprivateApis as blockEditorPrivateApis,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport { PluginArea } from '@wordpress/plugins';\nimport { __, sprintf } from '@wordpress/i18n';\nimport {\n\tuseCallback,\n\tuseEffect,\n\tuseMemo,\n\tuseId,\n\tuseRef,\n\tuseState,\n} from '@wordpress/element';\nimport { chevronDown, chevronUp } from '@wordpress/icons';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport { privateApis as commandsPrivateApis } from '@wordpress/commands';\nimport { privateApis as blockLibraryPrivateApis } from '@wordpress/block-library';\nimport { addQueryArgs } from '@wordpress/url';\nimport { decodeEntities } from '@wordpress/html-entities';\nimport { store as coreStore } from '@wordpress/core-data';\nimport {\n\tIcon,\n\tResizableBox,\n\tSlotFillProvider,\n\tTooltip,\n\tVisuallyHidden,\n\t__unstableUseNavigateRegions as useNavigateRegions,\n} from '@wordpress/components';\nimport {\n\tuseEvent,\n\tuseMediaQuery,\n\tuseRefEffect,\n\tuseViewportMatch,\n} from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport BackButton from '../back-button';\nimport EditorInitialization from '../editor-initialization';\nimport EditPostKeyboardShortcuts from '../keyboard-shortcuts';\nimport InitPatternModal from '../init-pattern-modal';\nimport BrowserURL from '../browser-url';\nimport MetaBoxes from '../meta-boxes';\nimport PostEditorMoreMenu from '../more-menu';\nimport WelcomeGuide from '../welcome-guide';\nimport { store as editPostStore } from '../../store';\nimport { unlock } from '../../lock-unlock';\nimport useEditPostCommands from '../../commands/use-commands';\nimport { usePaddingAppender } from './use-padding-appender';\nimport { useShouldIframe } from './use-should-iframe';\nimport useNavigateToEntityRecord from '../../hooks/use-navigate-to-entity-record';\nimport { useMetaBoxInitialization } from '../meta-boxes/use-meta-box-initialization';\n\nconst { getLayoutStyles } = unlock( blockEditorPrivateApis );\nconst { useCommandContext } = unlock( commandsPrivateApis );\nconst { Editor, FullscreenMode, NavigableRegion } = unlock( editorPrivateApis );\nconst { BlockKeyboardShortcuts } = unlock( blockLibraryPrivateApis );\nconst DESIGN_POST_TYPES = [\n\t'wp_template',\n\t'wp_template_part',\n\t'wp_block',\n\t'wp_navigation',\n\t'wp_registered_template',\n];\n\nfunction useEditorStyles( ...additionalStyles ) {\n\tconst { hasThemeStyleSupport, editorSettings } = useSelect( ( select ) => {\n\t\treturn {\n\t\t\thasThemeStyleSupport:\n\t\t\t\tselect( editPostStore ).isFeatureActive( 'themeStyles' ),\n\t\t\teditorSettings: select( editorStore ).getEditorSettings(),\n\t\t};\n\t}, [] );\n\n\tconst addedStyles = additionalStyles.join( '\\n' );\n\n\t// Compute the default styles.\n\treturn useMemo( () => {\n\t\tconst presetStyles =\n\t\t\teditorSettings.styles?.filter(\n\t\t\t\t( style ) =>\n\t\t\t\t\tstyle.__unstableType && style.__unstableType !== 'theme'\n\t\t\t) ?? [];\n\n\t\tconst defaultEditorStyles = [\n\t\t\t...( editorSettings?.defaultEditorStyles ?? [] ),\n\t\t\t...presetStyles,\n\t\t];\n\n\t\t// Has theme styles if the theme supports them and if some styles were not preset styles (in which case they're theme styles).\n\t\tconst hasThemeStyles =\n\t\t\thasThemeStyleSupport &&\n\t\t\tpresetStyles.length !== ( editorSettings.styles?.length ?? 0 );\n\n\t\t// If theme styles are not present or displayed, ensure that\n\t\t// base layout styles are still present in the editor.\n\t\tif ( ! editorSettings.disableLayoutStyles && ! hasThemeStyles ) {\n\t\t\tdefaultEditorStyles.push( {\n\t\t\t\tcss: getLayoutStyles( {\n\t\t\t\t\tstyle: {},\n\t\t\t\t\tselector: 'body',\n\t\t\t\t\thasBlockGapSupport: false,\n\t\t\t\t\thasFallbackGapSupport: true,\n\t\t\t\t\tfallbackGapValue: '0.5em',\n\t\t\t\t} ),\n\t\t\t} );\n\t\t}\n\n\t\tconst baseStyles = hasThemeStyles\n\t\t\t? editorSettings.styles ?? []\n\t\t\t: defaultEditorStyles;\n\n\t\tif ( addedStyles ) {\n\t\t\treturn [ ...baseStyles, { css: addedStyles } ];\n\t\t}\n\n\t\treturn baseStyles;\n\t}, [\n\t\teditorSettings.defaultEditorStyles,\n\t\teditorSettings.disableLayoutStyles,\n\t\teditorSettings.styles,\n\t\thasThemeStyleSupport,\n\t\taddedStyles,\n\t] );\n}\n\n/**\n * @param {Object} props\n * @param {boolean} props.isLegacy True when the editor canvas is not in an iframe.\n */\nfunction MetaBoxesMain( { isLegacy } ) {\n\tconst [ isOpen, openHeight, hasAnyVisible ] = useSelect( ( select ) => {\n\t\tconst { get } = select( preferencesStore );\n\t\tconst { isMetaBoxLocationVisible } = select( editPostStore );\n\t\treturn [\n\t\t\t!! get( 'core/edit-post', 'metaBoxesMainIsOpen' ),\n\t\t\tget( 'core/edit-post', 'metaBoxesMainOpenHeight' ),\n\t\t\tisMetaBoxLocationVisible( 'normal' ) ||\n\t\t\t\tisMetaBoxLocationVisible( 'advanced' ) ||\n\t\t\t\tisMetaBoxLocationVisible( 'side' ),\n\t\t];\n\t}, [] );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst metaBoxesMainRef = useRef();\n\tconst isShort = useMediaQuery( '(max-height: 549px)' );\n\n\tconst [ { min, max }, setHeightConstraints ] = useState( () => ( {} ) );\n\t// Keeps the resizable area’s size constraints updated taking into account\n\t// editor notices. The constraints are also used to derive the value for the\n\t// aria-valuenow attribute on the separator.\n\tconst effectSizeConstraints = useRefEffect( ( node ) => {\n\t\tconst container = node.closest(\n\t\t\t'.interface-interface-skeleton__content'\n\t\t);\n\t\tif ( ! container ) {\n\t\t\treturn;\n\t\t}\n\t\tconst noticeLists = container.querySelectorAll(\n\t\t\t':scope > .components-notice-list'\n\t\t);\n\t\tconst resizeHandle = container.querySelector(\n\t\t\t'.edit-post-meta-boxes-main__presenter'\n\t\t);\n\t\tconst deriveConstraints = () => {\n\t\t\tconst fullHeight = container.offsetHeight;\n\t\t\tlet nextMax = fullHeight;\n\t\t\tfor ( const element of noticeLists ) {\n\t\t\t\tnextMax -= element.offsetHeight;\n\t\t\t}\n\t\t\tconst nextMin = resizeHandle.offsetHeight;\n\t\t\tsetHeightConstraints( { min: nextMin, max: nextMax } );\n\t\t};\n\t\tconst observer = new window.ResizeObserver( deriveConstraints );\n\t\tobserver.observe( container );\n\t\tfor ( const element of noticeLists ) {\n\t\t\tobserver.observe( element );\n\t\t}\n\t\treturn () => observer.disconnect();\n\t}, [] );\n\n\tconst resizeDataRef = useRef( {} );\n\tconst separatorRef = useRef();\n\tconst separatorHelpId = useId();\n\n\t/**\n\t * @param {number|'auto'} [candidateHeight] Height in pixels or 'auto'.\n\t * @param {boolean} isPersistent Whether to persist the height in preferences.\n\t * @param {boolean} isInstant Whether to update the height in the DOM.\n\t */\n\tconst applyHeight = (\n\t\tcandidateHeight = 'auto',\n\t\tisPersistent,\n\t\tisInstant\n\t) => {\n\t\tif ( candidateHeight === 'auto' ) {\n\t\t\tisPersistent = false; // Just in case — “auto” should never persist.\n\t\t} else {\n\t\t\tcandidateHeight = Math.min( max, Math.max( min, candidateHeight ) );\n\t\t}\n\t\tif ( isPersistent ) {\n\t\t\tsetPreference(\n\t\t\t\t'core/edit-post',\n\t\t\t\t'metaBoxesMainOpenHeight',\n\t\t\t\tcandidateHeight\n\t\t\t);\n\t\t}\n\t\t// Updates aria-valuenow only when not persisting the value because otherwise\n\t\t// it's done by the render that persisting the value causes.\n\t\telse if ( ! isShort ) {\n\t\t\tseparatorRef.current.ariaValueNow =\n\t\t\t\tgetAriaValueNow( candidateHeight );\n\t\t}\n\t\tif ( isInstant ) {\n\t\t\tmetaBoxesMainRef.current.updateSize( {\n\t\t\t\theight: candidateHeight,\n\t\t\t\t// Oddly, when the event that triggered this was not from the mouse (e.g. keydown),\n\t\t\t\t// if `width` is left unspecified a subsequent drag gesture applies a fixed\n\t\t\t\t// width and the pane fails to widen/narrow with parent width changes from\n\t\t\t\t// sidebars opening/closing or window resizes.\n\t\t\t\twidth: 'auto',\n\t\t\t} );\n\t\t}\n\t};\n\tconst getRenderValues = useEvent( () => ( { isOpen, openHeight, min } ) );\n\t// Sets the height to 'auto' when not resizable (isShort) and to the\n\t// preferred height when resizable.\n\tuseEffect( () => {\n\t\tconst fresh = getRenderValues();\n\t\t// Tests for `min` having a value to skip the first render.\n\t\tif ( fresh.min !== undefined && metaBoxesMainRef.current ) {\n\t\t\tconst usedOpenHeight = isShort ? 'auto' : fresh.openHeight;\n\t\t\tconst usedHeight = fresh.isOpen ? usedOpenHeight : fresh.min;\n\t\t\tapplyHeight( usedHeight, false, true );\n\t\t}\n\t}, [ isShort ] );\n\n\tif ( ! hasAnyVisible ) {\n\t\treturn;\n\t}\n\n\tconst contents = (\n\t\t<div\n\t\t\t// The class name 'edit-post-layout__metaboxes' is retained because some plugins use it.\n\t\t\tclassName=\"edit-post-layout__metaboxes edit-post-meta-boxes-main__liner\"\n\t\t\thidden={ ! isOpen }\n\t\t>\n\t\t\t<MetaBoxes location=\"normal\" />\n\t\t\t<MetaBoxes location=\"advanced\" />\n\t\t</div>\n\t);\n\n\tif ( isLegacy ) {\n\t\treturn contents;\n\t}\n\n\tconst isAutoHeight = openHeight === undefined;\n\tconst getAriaValueNow = ( height ) =>\n\t\tMath.round( ( ( height - min ) / ( max - min ) ) * 100 );\n\tconst usedAriaValueNow =\n\t\tmax === undefined || isAutoHeight ? 50 : getAriaValueNow( openHeight );\n\n\tconst persistIsOpen = ( to = ! isOpen ) =>\n\t\tsetPreference( 'core/edit-post', 'metaBoxesMainIsOpen', to );\n\n\t// TODO: Support more/all keyboard interactions from the window splitter pattern:\n\t// https://www.w3.org/WAI/ARIA/apg/patterns/windowsplitter/\n\tconst onSeparatorKeyDown = ( event ) => {\n\t\tconst delta = { ArrowUp: 20, ArrowDown: -20 }[ event.key ];\n\t\tif ( delta ) {\n\t\t\tconst pane = metaBoxesMainRef.current.resizable;\n\t\t\tconst fromHeight = isAutoHeight ? pane.offsetHeight : openHeight;\n\t\t\tconst nextHeight = delta + fromHeight;\n\t\t\tapplyHeight( nextHeight, true, true );\n\t\t\tpersistIsOpen( nextHeight > min );\n\t\t\tevent.preventDefault();\n\t\t}\n\t};\n\tconst paneLabel = __( 'Meta Boxes' );\n\n\tconst toggle = (\n\t\t<button\n\t\t\taria-expanded={ isOpen }\n\t\t\tonClick={ ( { detail } ) => {\n\t\t\t\tconst { isToggleInferred } = resizeDataRef.current;\n\t\t\t\tif ( isShort || ! detail || isToggleInferred ) {\n\t\t\t\t\tpersistIsOpen();\n\t\t\t\t\tconst usedOpenHeight = isShort ? 'auto' : openHeight;\n\t\t\t\t\tconst usedHeight = isOpen ? min : usedOpenHeight;\n\t\t\t\t\tapplyHeight( usedHeight, false, true );\n\t\t\t\t}\n\t\t\t} }\n\t\t\t// Prevents resizing in short viewports.\n\t\t\t{ ...( isShort && {\n\t\t\t\tonMouseDown: ( event ) => event.stopPropagation(),\n\t\t\t\tonTouchStart: ( event ) => event.stopPropagation(),\n\t\t\t} ) }\n\t\t>\n\t\t\t{ paneLabel }\n\t\t\t<Icon icon={ isOpen ? chevronUp : chevronDown } />\n\t\t</button>\n\t);\n\n\tconst separator = ! isShort && (\n\t\t<>\n\t\t\t<Tooltip text={ __( 'Drag to resize' ) }>\n\t\t\t\t<button // eslint-disable-line jsx-a11y/role-supports-aria-props\n\t\t\t\t\tref={ separatorRef }\n\t\t\t\t\trole=\"separator\" // eslint-disable-line jsx-a11y/no-interactive-element-to-noninteractive-role\n\t\t\t\t\taria-valuenow={ usedAriaValueNow }\n\t\t\t\t\taria-label={ __( 'Drag to resize' ) }\n\t\t\t\t\taria-describedby={ separatorHelpId }\n\t\t\t\t\tonKeyDown={ onSeparatorKeyDown }\n\t\t\t\t/>\n\t\t\t</Tooltip>\n\t\t\t<VisuallyHidden id={ separatorHelpId }>\n\t\t\t\t{ __(\n\t\t\t\t\t'Use up and down arrow keys to resize the meta box panel.'\n\t\t\t\t) }\n\t\t\t</VisuallyHidden>\n\t\t</>\n\t);\n\n\tconst paneProps = /** @type {Parameters<typeof ResizableBox>[0]} */ ( {\n\t\tas: NavigableRegion,\n\t\tref: metaBoxesMainRef,\n\t\tclassName: 'edit-post-meta-boxes-main',\n\t\tdefaultSize: { height: isOpen ? openHeight : 0 },\n\t\tminHeight: min,\n\t\tmaxHeight: max,\n\t\tenable: { top: true },\n\t\thandleClasses: { top: 'edit-post-meta-boxes-main__presenter' },\n\t\thandleComponent: {\n\t\t\ttop: (\n\t\t\t\t<>\n\t\t\t\t\t{ toggle }\n\t\t\t\t\t{ separator }\n\t\t\t\t</>\n\t\t\t),\n\t\t},\n\t\t// Avoids hiccups while dragging over objects like iframes and ensures that\n\t\t// the event to end the drag is captured by the target (resize handle)\n\t\t// whether or not it’s under the pointer.\n\t\tonPointerDown: ( { pointerId, target } ) => {\n\t\t\tif ( separatorRef.current?.parentElement.contains( target ) ) {\n\t\t\t\ttarget.setPointerCapture( pointerId );\n\t\t\t}\n\t\t},\n\t\tonResizeStart: ( { timeStamp }, direction, elementRef ) => {\n\t\t\tif ( isAutoHeight ) {\n\t\t\t\t// Sets the starting height to avoid visual jumps in height and\n\t\t\t\t// aria-valuenow being `NaN` for the first (few) resize events.\n\t\t\t\tapplyHeight( elementRef.offsetHeight, false, true );\n\t\t\t}\n\t\t\telementRef.classList.add( 'is-resizing' );\n\t\t\tresizeDataRef.current = { timeStamp, maxDelta: 0 };\n\t\t},\n\t\tonResize: ( event, direction, elementRef, delta ) => {\n\t\t\tconst { maxDelta } = resizeDataRef.current;\n\t\t\tconst newDelta = Math.abs( delta.height );\n\t\t\tresizeDataRef.current.maxDelta = Math.max( maxDelta, newDelta );\n\t\t\tapplyHeight( metaBoxesMainRef.current.state.height );\n\t\t},\n\t\tonResizeStop: ( event, direction, elementRef ) => {\n\t\t\telementRef.classList.remove( 'is-resizing' );\n\t\t\tconst duration = event.timeStamp - resizeDataRef.current.timeStamp;\n\t\t\tconst wasSeparator = event.target === separatorRef.current;\n\t\t\tconst { maxDelta } = resizeDataRef.current;\n\t\t\tconst isToggleInferred =\n\t\t\t\tmaxDelta < 1 || ( duration < 144 && maxDelta < 5 );\n\t\t\tif ( isShort || ( ! wasSeparator && isToggleInferred ) ) {\n\t\t\t\tresizeDataRef.current.isToggleInferred = true;\n\t\t\t} else {\n\t\t\t\tconst { height } = metaBoxesMainRef.current.state;\n\t\t\t\tconst nextIsOpen = height > min;\n\t\t\t\tpersistIsOpen( nextIsOpen );\n\t\t\t\t// Persists height only if still open. This is so that when closed by a drag the\n\t\t\t\t// prior height can be restored by the toggle button instead of having to drag\n\t\t\t\t// the pane open again. Also, if already closed, a click on the separator won’t\n\t\t\t\t// persist the height as the minimum.\n\t\t\t\tif ( nextIsOpen ) {\n\t\t\t\t\tapplyHeight( height, true );\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t} );\n\n\treturn (\n\t\t<ResizableBox aria-label={ paneLabel } { ...paneProps }>\n\t\t\t<meta ref={ effectSizeConstraints } />\n\t\t\t{ contents }\n\t\t</ResizableBox>\n\t);\n}\n\nfunction Layout( {\n\tpostId: initialPostId,\n\tpostType: initialPostType,\n\tsettings,\n\tinitialEdits,\n} ) {\n\tuseEditPostCommands();\n\tconst shouldIframe = useShouldIframe();\n\tconst { createErrorNotice } = useDispatch( noticesStore );\n\tconst {\n\t\tcurrentPost: { postId: currentPostId, postType: currentPostType },\n\t\tonNavigateToEntityRecord,\n\t\tonNavigateToPreviousEntityRecord,\n\t} = useNavigateToEntityRecord(\n\t\tinitialPostId,\n\t\tinitialPostType,\n\t\t'post-only'\n\t);\n\tconst isEditingTemplate = currentPostType === 'wp_template';\n\tconst {\n\t\tmode,\n\t\tisFullscreenActive,\n\t\thasResolvedMode,\n\t\thasActiveMetaboxes,\n\t\thasBlockSelected,\n\t\tshowIconLabels,\n\t\tisDistractionFree,\n\t\tshowMetaBoxes,\n\t\tisWelcomeGuideVisible,\n\t\ttemplateId,\n\t\tenablePaddingAppender,\n\t\tisDevicePreview,\n\t} = useSelect(\n\t\t( select ) => {\n\t\t\tconst { get } = select( preferencesStore );\n\t\t\tconst { isFeatureActive, hasMetaBoxes } = select( editPostStore );\n\t\t\tconst { canUser, getPostType, getTemplateId } = unlock(\n\t\t\t\tselect( coreStore )\n\t\t\t);\n\n\t\t\tconst supportsTemplateMode = settings.supportsTemplateMode;\n\t\t\tconst isViewable =\n\t\t\t\tgetPostType( currentPostType )?.viewable ?? false;\n\t\t\tconst canViewTemplate = canUser( 'read', {\n\t\t\t\tkind: 'postType',\n\t\t\t\tname: 'wp_template',\n\t\t\t} );\n\t\t\tconst { getBlockSelectionStart, isZoomOut } = unlock(\n\t\t\t\tselect( blockEditorStore )\n\t\t\t);\n\t\t\tconst {\n\t\t\t\tgetEditorMode,\n\t\t\t\tgetRenderingMode,\n\t\t\t\tgetDefaultRenderingMode,\n\t\t\t\tgetDeviceType,\n\t\t\t} = unlock( select( editorStore ) );\n\t\t\tconst isRenderingPostOnly = getRenderingMode() === 'post-only';\n\t\t\tconst isNotDesignPostType =\n\t\t\t\t! DESIGN_POST_TYPES.includes( currentPostType );\n\t\t\tconst isDirectlyEditingPattern =\n\t\t\t\tcurrentPostType === 'wp_block' &&\n\t\t\t\t! onNavigateToPreviousEntityRecord;\n\t\t\tconst _templateId = getTemplateId( currentPostType, currentPostId );\n\t\t\tconst defaultMode = getDefaultRenderingMode( currentPostType );\n\n\t\t\treturn {\n\t\t\t\tmode: getEditorMode(),\n\t\t\t\tisFullscreenActive: isFeatureActive( 'fullscreenMode' ),\n\t\t\t\thasActiveMetaboxes: hasMetaBoxes(),\n\t\t\t\thasResolvedMode:\n\t\t\t\t\tdefaultMode === 'template-locked'\n\t\t\t\t\t\t? !! _templateId\n\t\t\t\t\t\t: defaultMode !== undefined,\n\t\t\t\thasBlockSelected: !! getBlockSelectionStart(),\n\t\t\t\tshowIconLabels: get( 'core', 'showIconLabels' ),\n\t\t\t\tisDistractionFree: get( 'core', 'distractionFree' ),\n\t\t\t\tshowMetaBoxes:\n\t\t\t\t\t( isNotDesignPostType && ! isZoomOut() ) ||\n\t\t\t\t\tisDirectlyEditingPattern,\n\t\t\t\tisWelcomeGuideVisible: isFeatureActive( 'welcomeGuide' ),\n\t\t\t\ttemplateId:\n\t\t\t\t\tsupportsTemplateMode &&\n\t\t\t\t\tisViewable &&\n\t\t\t\t\tcanViewTemplate &&\n\t\t\t\t\t! isEditingTemplate\n\t\t\t\t\t\t? _templateId\n\t\t\t\t\t\t: null,\n\t\t\t\tenablePaddingAppender:\n\t\t\t\t\t! isZoomOut() && isRenderingPostOnly && isNotDesignPostType,\n\t\t\t\tisDevicePreview: getDeviceType() !== 'Desktop',\n\t\t\t};\n\t\t},\n\t\t[\n\t\t\tcurrentPostType,\n\t\t\tcurrentPostId,\n\t\t\tisEditingTemplate,\n\t\t\tsettings.supportsTemplateMode,\n\t\t\tonNavigateToPreviousEntityRecord,\n\t\t]\n\t);\n\n\tuseMetaBoxInitialization( hasActiveMetaboxes && hasResolvedMode );\n\n\tconst editableResolvedTemplateId = useSelect(\n\t\t( select ) => {\n\t\t\tif ( typeof templateId !== 'string' ) {\n\t\t\t\treturn templateId;\n\t\t\t}\n\t\t\treturn unlock( select( coreStore ) ).getTemplateAutoDraftId(\n\t\t\t\ttemplateId\n\t\t\t);\n\t\t},\n\t\t[ templateId ]\n\t);\n\tconst [ paddingAppenderRef, paddingStyle ] = usePaddingAppender(\n\t\tenablePaddingAppender\n\t);\n\n\t// Set the right context for the command palette\n\tconst commandContext = hasBlockSelected\n\t\t? 'block-selection-edit'\n\t\t: 'entity-edit';\n\tuseCommandContext( commandContext );\n\tconst editorSettings = useMemo(\n\t\t() => ( {\n\t\t\t...settings,\n\t\t\tonNavigateToEntityRecord,\n\t\t\tonNavigateToPreviousEntityRecord,\n\t\t\tdefaultRenderingMode: 'post-only',\n\t\t} ),\n\t\t[ settings, onNavigateToEntityRecord, onNavigateToPreviousEntityRecord ]\n\t);\n\tconst styles = useEditorStyles( paddingStyle );\n\n\t// We need to add the show-icon-labels class to the body element so it is applied to modals.\n\tif ( showIconLabels ) {\n\t\tdocument.body.classList.add( 'show-icon-labels' );\n\t} else {\n\t\tdocument.body.classList.remove( 'show-icon-labels' );\n\t}\n\n\tconst navigateRegionsProps = useNavigateRegions();\n\n\tconst className = clsx( 'edit-post-layout', 'is-mode-' + mode, {\n\t\t'has-metaboxes': hasActiveMetaboxes,\n\t} );\n\n\tfunction onPluginAreaError( name ) {\n\t\tcreateErrorNotice(\n\t\t\tsprintf(\n\t\t\t\t/* translators: %s: plugin name */\n\t\t\t\t__(\n\t\t\t\t\t'The \"%s\" plugin has encountered an error and cannot be rendered.'\n\t\t\t\t),\n\t\t\t\tname\n\t\t\t)\n\t\t);\n\t}\n\n\tconst { createSuccessNotice } = useDispatch( noticesStore );\n\n\tconst onActionPerformed = useCallback(\n\t\t( actionId, items ) => {\n\t\t\tswitch ( actionId ) {\n\t\t\t\tcase 'move-to-trash':\n\t\t\t\t\t{\n\t\t\t\t\t\tdocument.location.href = addQueryArgs( 'edit.php', {\n\t\t\t\t\t\t\ttrashed: 1,\n\t\t\t\t\t\t\tpost_type: items[ 0 ].type,\n\t\t\t\t\t\t\tids: items[ 0 ].id,\n\t\t\t\t\t\t} );\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'duplicate-post':\n\t\t\t\t\t{\n\t\t\t\t\t\tconst newItem = items[ 0 ];\n\t\t\t\t\t\tconst title =\n\t\t\t\t\t\t\ttypeof newItem.title === 'string'\n\t\t\t\t\t\t\t\t? newItem.title\n\t\t\t\t\t\t\t\t: newItem.title?.rendered;\n\t\t\t\t\t\tcreateSuccessNotice(\n\t\t\t\t\t\t\tsprintf(\n\t\t\t\t\t\t\t\t// translators: %s: Title of the created post or template, e.g: \"Hello world\".\n\t\t\t\t\t\t\t\t__( '\"%s\" successfully created.' ),\n\t\t\t\t\t\t\t\tdecodeEntities( title ) || __( '(no title)' )\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\ttype: 'snackbar',\n\t\t\t\t\t\t\t\tid: 'duplicate-post-action',\n\t\t\t\t\t\t\t\tactions: [\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tlabel: __( 'Edit' ),\n\t\t\t\t\t\t\t\t\t\tonClick: () => {\n\t\t\t\t\t\t\t\t\t\t\tconst postId = newItem.id;\n\t\t\t\t\t\t\t\t\t\t\tdocument.location.href =\n\t\t\t\t\t\t\t\t\t\t\t\taddQueryArgs( 'post.php', {\n\t\t\t\t\t\t\t\t\t\t\t\t\tpost: postId,\n\t\t\t\t\t\t\t\t\t\t\t\t\taction: 'edit',\n\t\t\t\t\t\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[ createSuccessNotice ]\n\t);\n\n\tconst initialPost = useMemo( () => {\n\t\treturn {\n\t\t\ttype: initialPostType,\n\t\t\tid: initialPostId,\n\t\t};\n\t}, [ initialPostType, initialPostId ] );\n\n\tconst backButton =\n\t\tuseViewportMatch( 'medium' ) && isFullscreenActive ? (\n\t\t\t<BackButton initialPost={ initialPost } />\n\t\t) : null;\n\n\treturn (\n\t\t<SlotFillProvider>\n\t\t\t<ErrorBoundary canCopyContent>\n\t\t\t\t<WelcomeGuide postType={ currentPostType } />\n\t\t\t\t<div\n\t\t\t\t\tclassName={ navigateRegionsProps.className }\n\t\t\t\t\t{ ...navigateRegionsProps }\n\t\t\t\t\tref={ navigateRegionsProps.ref }\n\t\t\t\t>\n\t\t\t\t\t<Editor\n\t\t\t\t\t\tsettings={ editorSettings }\n\t\t\t\t\t\tinitialEdits={ initialEdits }\n\t\t\t\t\t\tpostType={ currentPostType }\n\t\t\t\t\t\tpostId={ currentPostId }\n\t\t\t\t\t\ttemplateId={ editableResolvedTemplateId }\n\t\t\t\t\t\tclassName={ className }\n\t\t\t\t\t\tstyles={ styles }\n\t\t\t\t\t\tforceIsDirty={ hasActiveMetaboxes }\n\t\t\t\t\t\tcontentRef={ paddingAppenderRef }\n\t\t\t\t\t\tdisableIframe={ ! shouldIframe }\n\t\t\t\t\t\t// We should auto-focus the canvas (title) on load.\n\t\t\t\t\t\t// eslint-disable-next-line jsx-a11y/no-autofocus\n\t\t\t\t\t\tautoFocus={ ! isWelcomeGuideVisible }\n\t\t\t\t\t\tonActionPerformed={ onActionPerformed }\n\t\t\t\t\t\textraSidebarPanels={\n\t\t\t\t\t\t\tshowMetaBoxes && <MetaBoxes location=\"side\" />\n\t\t\t\t\t\t}\n\t\t\t\t\t\textraContent={\n\t\t\t\t\t\t\t! isDistractionFree &&\n\t\t\t\t\t\t\tshowMetaBoxes && (\n\t\t\t\t\t\t\t\t<MetaBoxesMain\n\t\t\t\t\t\t\t\t\tisLegacy={\n\t\t\t\t\t\t\t\t\t\t! shouldIframe || isDevicePreview\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t>\n\t\t\t\t\t\t<PostLockedModal />\n\t\t\t\t\t\t<EditorInitialization />\n\t\t\t\t\t\t<FullscreenMode isActive={ isFullscreenActive } />\n\t\t\t\t\t\t<BrowserURL />\n\t\t\t\t\t\t<UnsavedChangesWarning />\n\t\t\t\t\t\t<AutosaveMonitor />\n\t\t\t\t\t\t<LocalAutosaveMonitor />\n\t\t\t\t\t\t<EditPostKeyboardShortcuts />\n\t\t\t\t\t\t<EditorKeyboardShortcutsRegister />\n\t\t\t\t\t\t<BlockKeyboardShortcuts />\n\t\t\t\t\t\t<InitPatternModal />\n\t\t\t\t\t\t<PluginArea onError={ onPluginAreaError } />\n\t\t\t\t\t\t<PostEditorMoreMenu />\n\t\t\t\t\t\t{ backButton }\n\t\t\t\t\t\t<EditorSnackbars />\n\t\t\t\t\t</Editor>\n\t\t\t\t</div>\n\t\t\t</ErrorBoundary>\n\t\t</SlotFillProvider>\n\t);\n}\n\nexport default Layout;\n"],"mappings":";;;;;;;AAGA,IAAAA,KAAA,GAAAC,sBAAA,CAAAC,OAAA;AAKA,IAAAC,OAAA,GAAAD,OAAA;AAWA,IA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,EAAC/I,OAAA,CAAAiU,eAAe,IAAE,CAAC,eACnB,IAAAlS,WAAA,CAAAgH,GAAA,EAAC/I,OAAA,CAAAkU,oBAAoB,IAAE,CAAC,eACxB,IAAAnS,WAAA,CAAAgH,GAAA,EAAC7H,kBAAA,CAAA8H,OAAyB,IAAE,CAAC,eAC7B,IAAAjH,WAAA,CAAAgH,GAAA,EAAC/I,OAAA,CAAAmU,+BAA+B,IAAE,CAAC,eACnC,IAAApS,WAAA,CAAAgH,GAAA,EAACtG,sBAAsB,IAAE,CAAC,eAC1B,IAAAV,WAAA,CAAAgH,GAAA,EAAC5H,iBAAA,CAAA6H,OAAgB,IAAE,CAAC,eACpB,IAAAjH,WAAA,CAAAgH,GAAA,EAAC5I,QAAA,CAAAiU,UAAU;YAACC,OAAO,EAAGxC;UAAmB,CAAE,CAAC,eAC5C,IAAA9P,WAAA,CAAAgH,GAAA,EAACzH,SAAA,CAAA0H,OAAkB,IAAE,CAAC,EACpBmK,UAAU,eACZ,IAAApR,WAAA,CAAAgH,GAAA,EAAC/I,OAAA,CAAAsU,eAAe,IAAE,CAAC;QAAA,CACZ;MAAC,CACL,CAAC;IAAA,CACQ;EAAC,CACC,CAAC;AAErB;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAxL,OAAA,GAEcwE,MAAM","ignoreList":[]}
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/layout/index.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * External dependencies\n */\nimport clsx from 'clsx';\n\n/**\n * WordPress dependencies\n */\nimport { NavigableRegion } from '@wordpress/admin-ui';\nimport {\n\tAutosaveMonitor,\n\tLocalAutosaveMonitor,\n\tUnsavedChangesWarning,\n\tEditorKeyboardShortcutsRegister,\n\tEditorSnackbars,\n\tErrorBoundary,\n\tPostLockedModal,\n\tstore as editorStore,\n\tprivateApis as editorPrivateApis,\n} from '@wordpress/editor';\nimport { useSelect, useDispatch } from '@wordpress/data';\nimport {\n\tprivateApis as blockEditorPrivateApis,\n\tstore as blockEditorStore,\n} from '@wordpress/block-editor';\nimport { PluginArea } from '@wordpress/plugins';\nimport { __, sprintf } from '@wordpress/i18n';\nimport {\n\tuseCallback,\n\tuseEffect,\n\tuseMemo,\n\tuseId,\n\tuseRef,\n\tuseState,\n} from '@wordpress/element';\nimport { chevronDown, chevronUp } from '@wordpress/icons';\nimport { store as noticesStore } from '@wordpress/notices';\nimport { store as preferencesStore } from '@wordpress/preferences';\nimport { privateApis as commandsPrivateApis } from '@wordpress/commands';\nimport { privateApis as blockLibraryPrivateApis } from '@wordpress/block-library';\nimport { addQueryArgs } from '@wordpress/url';\nimport { decodeEntities } from '@wordpress/html-entities';\nimport { store as coreStore } from '@wordpress/core-data';\nimport {\n\tIcon,\n\tResizableBox,\n\tSlotFillProvider,\n\tTooltip,\n\tVisuallyHidden,\n\t__unstableUseNavigateRegions as useNavigateRegions,\n} from '@wordpress/components';\nimport {\n\tuseEvent,\n\tuseMediaQuery,\n\tuseRefEffect,\n\tuseViewportMatch,\n} from '@wordpress/compose';\n\n/**\n * Internal dependencies\n */\nimport BackButton from '../back-button';\nimport EditorInitialization from '../editor-initialization';\nimport EditPostKeyboardShortcuts from '../keyboard-shortcuts';\nimport InitPatternModal from '../init-pattern-modal';\nimport BrowserURL from '../browser-url';\nimport MetaBoxes from '../meta-boxes';\nimport PostEditorMoreMenu from '../more-menu';\nimport WelcomeGuide from '../welcome-guide';\nimport { store as editPostStore } from '../../store';\nimport { unlock } from '../../lock-unlock';\nimport useEditPostCommands from '../../commands/use-commands';\nimport { usePaddingAppender } from './use-padding-appender';\nimport { useShouldIframe } from './use-should-iframe';\nimport useNavigateToEntityRecord from '../../hooks/use-navigate-to-entity-record';\nimport { useMetaBoxInitialization } from '../meta-boxes/use-meta-box-initialization';\n\nconst { getLayoutStyles } = unlock( blockEditorPrivateApis );\nconst { useCommandContext } = unlock( commandsPrivateApis );\nconst { Editor, FullscreenMode } = unlock( editorPrivateApis );\nconst { BlockKeyboardShortcuts } = unlock( blockLibraryPrivateApis );\nconst DESIGN_POST_TYPES = [\n\t'wp_template',\n\t'wp_template_part',\n\t'wp_block',\n\t'wp_navigation',\n\t'wp_registered_template',\n];\n\nfunction useEditorStyles( ...additionalStyles ) {\n\tconst { hasThemeStyleSupport, editorSettings } = useSelect( ( select ) => {\n\t\treturn {\n\t\t\thasThemeStyleSupport:\n\t\t\t\tselect( editPostStore ).isFeatureActive( 'themeStyles' ),\n\t\t\teditorSettings: select( editorStore ).getEditorSettings(),\n\t\t};\n\t}, [] );\n\n\tconst addedStyles = additionalStyles.join( '\\n' );\n\n\t// Compute the default styles.\n\treturn useMemo( () => {\n\t\tconst presetStyles =\n\t\t\teditorSettings.styles?.filter(\n\t\t\t\t( style ) =>\n\t\t\t\t\tstyle.__unstableType && style.__unstableType !== 'theme'\n\t\t\t) ?? [];\n\n\t\tconst defaultEditorStyles = [\n\t\t\t...( editorSettings?.defaultEditorStyles ?? [] ),\n\t\t\t...presetStyles,\n\t\t];\n\n\t\t// Has theme styles if the theme supports them and if some styles were not preset styles (in which case they're theme styles).\n\t\tconst hasThemeStyles =\n\t\t\thasThemeStyleSupport &&\n\t\t\tpresetStyles.length !== ( editorSettings.styles?.length ?? 0 );\n\n\t\t// If theme styles are not present or displayed, ensure that\n\t\t// base layout styles are still present in the editor.\n\t\tif ( ! editorSettings.disableLayoutStyles && ! hasThemeStyles ) {\n\t\t\tdefaultEditorStyles.push( {\n\t\t\t\tcss: getLayoutStyles( {\n\t\t\t\t\tstyle: {},\n\t\t\t\t\tselector: 'body',\n\t\t\t\t\thasBlockGapSupport: false,\n\t\t\t\t\thasFallbackGapSupport: true,\n\t\t\t\t\tfallbackGapValue: '0.5em',\n\t\t\t\t} ),\n\t\t\t} );\n\t\t}\n\n\t\tconst baseStyles = hasThemeStyles\n\t\t\t? editorSettings.styles ?? []\n\t\t\t: defaultEditorStyles;\n\n\t\tif ( addedStyles ) {\n\t\t\treturn [ ...baseStyles, { css: addedStyles } ];\n\t\t}\n\n\t\treturn baseStyles;\n\t}, [\n\t\teditorSettings.defaultEditorStyles,\n\t\teditorSettings.disableLayoutStyles,\n\t\teditorSettings.styles,\n\t\thasThemeStyleSupport,\n\t\taddedStyles,\n\t] );\n}\n\n/**\n * @param {Object} props\n * @param {boolean} props.isLegacy True when the editor canvas is not in an iframe.\n */\nfunction MetaBoxesMain( { isLegacy } ) {\n\tconst [ isOpen, openHeight, hasAnyVisible ] = useSelect( ( select ) => {\n\t\tconst { get } = select( preferencesStore );\n\t\tconst { isMetaBoxLocationVisible } = select( editPostStore );\n\t\treturn [\n\t\t\t!! get( 'core/edit-post', 'metaBoxesMainIsOpen' ),\n\t\t\tget( 'core/edit-post', 'metaBoxesMainOpenHeight' ),\n\t\t\tisMetaBoxLocationVisible( 'normal' ) ||\n\t\t\t\tisMetaBoxLocationVisible( 'advanced' ) ||\n\t\t\t\tisMetaBoxLocationVisible( 'side' ),\n\t\t];\n\t}, [] );\n\tconst { set: setPreference } = useDispatch( preferencesStore );\n\tconst metaBoxesMainRef = useRef();\n\tconst isShort = useMediaQuery( '(max-height: 549px)' );\n\n\tconst [ { min, max }, setHeightConstraints ] = useState( () => ( {} ) );\n\t// Keeps the resizable area\u2019s size constraints updated taking into account\n\t// editor notices. The constraints are also used to derive the value for the\n\t// aria-valuenow attribute on the separator.\n\tconst effectSizeConstraints = useRefEffect( ( node ) => {\n\t\tconst container = node.closest(\n\t\t\t'.interface-interface-skeleton__content'\n\t\t);\n\t\tif ( ! container ) {\n\t\t\treturn;\n\t\t}\n\t\tconst noticeLists = container.querySelectorAll(\n\t\t\t':scope > .components-notice-list'\n\t\t);\n\t\tconst resizeHandle = container.querySelector(\n\t\t\t'.edit-post-meta-boxes-main__presenter'\n\t\t);\n\t\tconst deriveConstraints = () => {\n\t\t\tconst fullHeight = container.offsetHeight;\n\t\t\tlet nextMax = fullHeight;\n\t\t\tfor ( const element of noticeLists ) {\n\t\t\t\tnextMax -= element.offsetHeight;\n\t\t\t}\n\t\t\tconst nextMin = resizeHandle.offsetHeight;\n\t\t\tsetHeightConstraints( { min: nextMin, max: nextMax } );\n\t\t};\n\t\tconst observer = new window.ResizeObserver( deriveConstraints );\n\t\tobserver.observe( container );\n\t\tfor ( const element of noticeLists ) {\n\t\t\tobserver.observe( element );\n\t\t}\n\t\treturn () => observer.disconnect();\n\t}, [] );\n\n\tconst resizeDataRef = useRef( {} );\n\tconst separatorRef = useRef();\n\tconst separatorHelpId = useId();\n\n\t/**\n\t * @param {number|'auto'} [candidateHeight] Height in pixels or 'auto'.\n\t * @param {boolean} isPersistent Whether to persist the height in preferences.\n\t * @param {boolean} isInstant Whether to update the height in the DOM.\n\t */\n\tconst applyHeight = (\n\t\tcandidateHeight = 'auto',\n\t\tisPersistent,\n\t\tisInstant\n\t) => {\n\t\tif ( candidateHeight === 'auto' ) {\n\t\t\tisPersistent = false; // Just in case \u2014 \u201Cauto\u201D should never persist.\n\t\t} else {\n\t\t\tcandidateHeight = Math.min( max, Math.max( min, candidateHeight ) );\n\t\t}\n\t\tif ( isPersistent ) {\n\t\t\tsetPreference(\n\t\t\t\t'core/edit-post',\n\t\t\t\t'metaBoxesMainOpenHeight',\n\t\t\t\tcandidateHeight\n\t\t\t);\n\t\t}\n\t\t// Updates aria-valuenow only when not persisting the value because otherwise\n\t\t// it's done by the render that persisting the value causes.\n\t\telse if ( ! isShort ) {\n\t\t\tseparatorRef.current.ariaValueNow =\n\t\t\t\tgetAriaValueNow( candidateHeight );\n\t\t}\n\t\tif ( isInstant ) {\n\t\t\tmetaBoxesMainRef.current.updateSize( {\n\t\t\t\theight: candidateHeight,\n\t\t\t\t// Oddly, when the event that triggered this was not from the mouse (e.g. keydown),\n\t\t\t\t// if `width` is left unspecified a subsequent drag gesture applies a fixed\n\t\t\t\t// width and the pane fails to widen/narrow with parent width changes from\n\t\t\t\t// sidebars opening/closing or window resizes.\n\t\t\t\twidth: 'auto',\n\t\t\t} );\n\t\t}\n\t};\n\tconst getRenderValues = useEvent( () => ( { isOpen, openHeight, min } ) );\n\t// Sets the height to 'auto' when not resizable (isShort) and to the\n\t// preferred height when resizable.\n\tuseEffect( () => {\n\t\tconst fresh = getRenderValues();\n\t\t// Tests for `min` having a value to skip the first render.\n\t\tif ( fresh.min !== undefined && metaBoxesMainRef.current ) {\n\t\t\tconst usedOpenHeight = isShort ? 'auto' : fresh.openHeight;\n\t\t\tconst usedHeight = fresh.isOpen ? usedOpenHeight : fresh.min;\n\t\t\tapplyHeight( usedHeight, false, true );\n\t\t}\n\t}, [ isShort ] );\n\n\tif ( ! hasAnyVisible ) {\n\t\treturn;\n\t}\n\n\tconst contents = (\n\t\t<div\n\t\t\t// The class name 'edit-post-layout__metaboxes' is retained because some plugins use it.\n\t\t\tclassName=\"edit-post-layout__metaboxes edit-post-meta-boxes-main__liner\"\n\t\t\thidden={ ! isLegacy && ! isOpen }\n\t\t>\n\t\t\t<MetaBoxes location=\"normal\" />\n\t\t\t<MetaBoxes location=\"advanced\" />\n\t\t</div>\n\t);\n\n\tif ( isLegacy ) {\n\t\treturn contents;\n\t}\n\n\tconst isAutoHeight = openHeight === undefined;\n\tconst getAriaValueNow = ( height ) =>\n\t\tMath.round( ( ( height - min ) / ( max - min ) ) * 100 );\n\tconst usedAriaValueNow =\n\t\tmax === undefined || isAutoHeight ? 50 : getAriaValueNow( openHeight );\n\n\tconst persistIsOpen = ( to = ! isOpen ) =>\n\t\tsetPreference( 'core/edit-post', 'metaBoxesMainIsOpen', to );\n\n\t// TODO: Support more/all keyboard interactions from the window splitter pattern:\n\t// https://www.w3.org/WAI/ARIA/apg/patterns/windowsplitter/\n\tconst onSeparatorKeyDown = ( event ) => {\n\t\tconst delta = { ArrowUp: 20, ArrowDown: -20 }[ event.key ];\n\t\tif ( delta ) {\n\t\t\tconst pane = metaBoxesMainRef.current.resizable;\n\t\t\tconst fromHeight = isAutoHeight ? pane.offsetHeight : openHeight;\n\t\t\tconst nextHeight = delta + fromHeight;\n\t\t\tapplyHeight( nextHeight, true, true );\n\t\t\tpersistIsOpen( nextHeight > min );\n\t\t\tevent.preventDefault();\n\t\t}\n\t};\n\tconst paneLabel = __( 'Meta Boxes' );\n\n\tconst toggle = (\n\t\t<button\n\t\t\taria-expanded={ isOpen }\n\t\t\tonClick={ ( { detail } ) => {\n\t\t\t\tconst { isToggleInferred } = resizeDataRef.current;\n\t\t\t\tif ( isShort || ! detail || isToggleInferred ) {\n\t\t\t\t\tpersistIsOpen();\n\t\t\t\t\tconst usedOpenHeight = isShort ? 'auto' : openHeight;\n\t\t\t\t\tconst usedHeight = isOpen ? min : usedOpenHeight;\n\t\t\t\t\tapplyHeight( usedHeight, false, true );\n\t\t\t\t}\n\t\t\t} }\n\t\t\t// Prevents resizing in short viewports.\n\t\t\t{ ...( isShort && {\n\t\t\t\tonMouseDown: ( event ) => event.stopPropagation(),\n\t\t\t\tonTouchStart: ( event ) => event.stopPropagation(),\n\t\t\t} ) }\n\t\t>\n\t\t\t{ paneLabel }\n\t\t\t<Icon icon={ isOpen ? chevronUp : chevronDown } />\n\t\t</button>\n\t);\n\n\tconst separator = ! isShort && (\n\t\t<>\n\t\t\t<Tooltip text={ __( 'Drag to resize' ) }>\n\t\t\t\t<button // eslint-disable-line jsx-a11y/role-supports-aria-props\n\t\t\t\t\tref={ separatorRef }\n\t\t\t\t\trole=\"separator\" // eslint-disable-line jsx-a11y/no-interactive-element-to-noninteractive-role\n\t\t\t\t\taria-valuenow={ usedAriaValueNow }\n\t\t\t\t\taria-label={ __( 'Drag to resize' ) }\n\t\t\t\t\taria-describedby={ separatorHelpId }\n\t\t\t\t\tonKeyDown={ onSeparatorKeyDown }\n\t\t\t\t/>\n\t\t\t</Tooltip>\n\t\t\t<VisuallyHidden id={ separatorHelpId }>\n\t\t\t\t{ __(\n\t\t\t\t\t'Use up and down arrow keys to resize the meta box panel.'\n\t\t\t\t) }\n\t\t\t</VisuallyHidden>\n\t\t</>\n\t);\n\n\tconst paneProps = /** @type {Parameters<typeof ResizableBox>[0]} */ ( {\n\t\tas: NavigableRegion,\n\t\tref: metaBoxesMainRef,\n\t\tclassName: 'edit-post-meta-boxes-main',\n\t\tdefaultSize: { height: isOpen ? openHeight : 0 },\n\t\tminHeight: min,\n\t\tmaxHeight: max,\n\t\tenable: { top: true },\n\t\thandleClasses: { top: 'edit-post-meta-boxes-main__presenter' },\n\t\thandleComponent: {\n\t\t\ttop: (\n\t\t\t\t<>\n\t\t\t\t\t{ toggle }\n\t\t\t\t\t{ separator }\n\t\t\t\t</>\n\t\t\t),\n\t\t},\n\t\t// Avoids hiccups while dragging over objects like iframes and ensures that\n\t\t// the event to end the drag is captured by the target (resize handle)\n\t\t// whether or not it\u2019s under the pointer.\n\t\tonPointerDown: ( { pointerId, target } ) => {\n\t\t\tif ( separatorRef.current?.parentElement.contains( target ) ) {\n\t\t\t\ttarget.setPointerCapture( pointerId );\n\t\t\t}\n\t\t},\n\t\tonResizeStart: ( { timeStamp }, direction, elementRef ) => {\n\t\t\tif ( isAutoHeight ) {\n\t\t\t\t// Sets the starting height to avoid visual jumps in height and\n\t\t\t\t// aria-valuenow being `NaN` for the first (few) resize events.\n\t\t\t\tapplyHeight( elementRef.offsetHeight, false, true );\n\t\t\t}\n\t\t\telementRef.classList.add( 'is-resizing' );\n\t\t\tresizeDataRef.current = { timeStamp, maxDelta: 0 };\n\t\t},\n\t\tonResize: ( event, direction, elementRef, delta ) => {\n\t\t\tconst { maxDelta } = resizeDataRef.current;\n\t\t\tconst newDelta = Math.abs( delta.height );\n\t\t\tresizeDataRef.current.maxDelta = Math.max( maxDelta, newDelta );\n\t\t\tapplyHeight( metaBoxesMainRef.current.state.height );\n\t\t},\n\t\tonResizeStop: ( event, direction, elementRef ) => {\n\t\t\telementRef.classList.remove( 'is-resizing' );\n\t\t\tconst duration = event.timeStamp - resizeDataRef.current.timeStamp;\n\t\t\tconst wasSeparator = event.target === separatorRef.current;\n\t\t\tconst { maxDelta } = resizeDataRef.current;\n\t\t\tconst isToggleInferred =\n\t\t\t\tmaxDelta < 1 || ( duration < 144 && maxDelta < 5 );\n\t\t\tif ( isShort || ( ! wasSeparator && isToggleInferred ) ) {\n\t\t\t\tresizeDataRef.current.isToggleInferred = true;\n\t\t\t} else {\n\t\t\t\tconst { height } = metaBoxesMainRef.current.state;\n\t\t\t\tconst nextIsOpen = height > min;\n\t\t\t\tpersistIsOpen( nextIsOpen );\n\t\t\t\t// Persists height only if still open. This is so that when closed by a drag the\n\t\t\t\t// prior height can be restored by the toggle button instead of having to drag\n\t\t\t\t// the pane open again. Also, if already closed, a click on the separator won\u2019t\n\t\t\t\t// persist the height as the minimum.\n\t\t\t\tif ( nextIsOpen ) {\n\t\t\t\t\tapplyHeight( height, true );\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t} );\n\n\treturn (\n\t\t<ResizableBox aria-label={ paneLabel } { ...paneProps }>\n\t\t\t<meta ref={ effectSizeConstraints } />\n\t\t\t{ contents }\n\t\t</ResizableBox>\n\t);\n}\n\nfunction Layout( {\n\tpostId: initialPostId,\n\tpostType: initialPostType,\n\tsettings,\n\tinitialEdits,\n} ) {\n\tuseEditPostCommands();\n\tconst shouldIframe = useShouldIframe();\n\tconst { createErrorNotice } = useDispatch( noticesStore );\n\tconst {\n\t\tcurrentPost: { postId: currentPostId, postType: currentPostType },\n\t\tonNavigateToEntityRecord,\n\t\tonNavigateToPreviousEntityRecord,\n\t} = useNavigateToEntityRecord(\n\t\tinitialPostId,\n\t\tinitialPostType,\n\t\t'post-only'\n\t);\n\tconst isEditingTemplate = currentPostType === 'wp_template';\n\tconst {\n\t\tmode,\n\t\tisFullscreenActive,\n\t\thasResolvedMode,\n\t\thasActiveMetaboxes,\n\t\thasBlockSelected,\n\t\tshowIconLabels,\n\t\tisDistractionFree,\n\t\tshowMetaBoxes,\n\t\tisWelcomeGuideVisible,\n\t\ttemplateId,\n\t\tenablePaddingAppender,\n\t\tisDevicePreview,\n\t} = useSelect(\n\t\t( select ) => {\n\t\t\tconst { get } = select( preferencesStore );\n\t\t\tconst { isFeatureActive, hasMetaBoxes } = select( editPostStore );\n\t\t\tconst { canUser, getPostType, getTemplateId } = unlock(\n\t\t\t\tselect( coreStore )\n\t\t\t);\n\n\t\t\tconst supportsTemplateMode = settings.supportsTemplateMode;\n\t\t\tconst isViewable =\n\t\t\t\tgetPostType( currentPostType )?.viewable ?? false;\n\t\t\tconst canViewTemplate = canUser( 'read', {\n\t\t\t\tkind: 'postType',\n\t\t\t\tname: 'wp_template',\n\t\t\t} );\n\t\t\tconst { getBlockSelectionStart, isZoomOut } = unlock(\n\t\t\t\tselect( blockEditorStore )\n\t\t\t);\n\t\t\tconst {\n\t\t\t\tgetEditorMode,\n\t\t\t\tgetRenderingMode,\n\t\t\t\tgetDefaultRenderingMode,\n\t\t\t\tgetDeviceType,\n\t\t\t} = unlock( select( editorStore ) );\n\t\t\tconst isRenderingPostOnly = getRenderingMode() === 'post-only';\n\t\t\tconst isNotDesignPostType =\n\t\t\t\t! DESIGN_POST_TYPES.includes( currentPostType );\n\t\t\tconst isDirectlyEditingPattern =\n\t\t\t\tcurrentPostType === 'wp_block' &&\n\t\t\t\t! onNavigateToPreviousEntityRecord;\n\t\t\tconst _templateId = getTemplateId( currentPostType, currentPostId );\n\t\t\tconst defaultMode = getDefaultRenderingMode( currentPostType );\n\n\t\t\treturn {\n\t\t\t\tmode: getEditorMode(),\n\t\t\t\tisFullscreenActive: isFeatureActive( 'fullscreenMode' ),\n\t\t\t\thasActiveMetaboxes: hasMetaBoxes(),\n\t\t\t\thasResolvedMode:\n\t\t\t\t\tdefaultMode === 'template-locked'\n\t\t\t\t\t\t? !! _templateId\n\t\t\t\t\t\t: defaultMode !== undefined,\n\t\t\t\thasBlockSelected: !! getBlockSelectionStart(),\n\t\t\t\tshowIconLabels: get( 'core', 'showIconLabels' ),\n\t\t\t\tisDistractionFree: get( 'core', 'distractionFree' ),\n\t\t\t\tshowMetaBoxes:\n\t\t\t\t\t( isNotDesignPostType && ! isZoomOut() ) ||\n\t\t\t\t\tisDirectlyEditingPattern,\n\t\t\t\tisWelcomeGuideVisible: isFeatureActive( 'welcomeGuide' ),\n\t\t\t\ttemplateId:\n\t\t\t\t\tsupportsTemplateMode &&\n\t\t\t\t\tisViewable &&\n\t\t\t\t\tcanViewTemplate &&\n\t\t\t\t\t! isEditingTemplate\n\t\t\t\t\t\t? _templateId\n\t\t\t\t\t\t: null,\n\t\t\t\tenablePaddingAppender:\n\t\t\t\t\t! isZoomOut() && isRenderingPostOnly && isNotDesignPostType,\n\t\t\t\tisDevicePreview: getDeviceType() !== 'Desktop',\n\t\t\t};\n\t\t},\n\t\t[\n\t\t\tcurrentPostType,\n\t\t\tcurrentPostId,\n\t\t\tisEditingTemplate,\n\t\t\tsettings.supportsTemplateMode,\n\t\t\tonNavigateToPreviousEntityRecord,\n\t\t]\n\t);\n\n\tuseMetaBoxInitialization( hasActiveMetaboxes && hasResolvedMode );\n\n\tconst editableResolvedTemplateId = useSelect(\n\t\t( select ) => {\n\t\t\tif ( typeof templateId !== 'string' ) {\n\t\t\t\treturn templateId;\n\t\t\t}\n\t\t\treturn unlock( select( coreStore ) ).getTemplateAutoDraftId(\n\t\t\t\ttemplateId\n\t\t\t);\n\t\t},\n\t\t[ templateId ]\n\t);\n\tconst [ paddingAppenderRef, paddingStyle ] = usePaddingAppender(\n\t\tenablePaddingAppender\n\t);\n\n\t// Set the right context for the command palette\n\tconst commandContext = hasBlockSelected\n\t\t? 'block-selection-edit'\n\t\t: 'entity-edit';\n\tuseCommandContext( commandContext );\n\tconst editorSettings = useMemo(\n\t\t() => ( {\n\t\t\t...settings,\n\t\t\tonNavigateToEntityRecord,\n\t\t\tonNavigateToPreviousEntityRecord,\n\t\t\tdefaultRenderingMode: 'post-only',\n\t\t} ),\n\t\t[ settings, onNavigateToEntityRecord, onNavigateToPreviousEntityRecord ]\n\t);\n\tconst styles = useEditorStyles( paddingStyle );\n\n\t// We need to add the show-icon-labels class to the body element so it is applied to modals.\n\tif ( showIconLabels ) {\n\t\tdocument.body.classList.add( 'show-icon-labels' );\n\t} else {\n\t\tdocument.body.classList.remove( 'show-icon-labels' );\n\t}\n\n\tconst navigateRegionsProps = useNavigateRegions();\n\n\tconst className = clsx( 'edit-post-layout', 'is-mode-' + mode, {\n\t\t'has-metaboxes': hasActiveMetaboxes,\n\t} );\n\n\tfunction onPluginAreaError( name ) {\n\t\tcreateErrorNotice(\n\t\t\tsprintf(\n\t\t\t\t/* translators: %s: plugin name */\n\t\t\t\t__(\n\t\t\t\t\t'The \"%s\" plugin has encountered an error and cannot be rendered.'\n\t\t\t\t),\n\t\t\t\tname\n\t\t\t)\n\t\t);\n\t}\n\n\tconst { createSuccessNotice } = useDispatch( noticesStore );\n\n\tconst onActionPerformed = useCallback(\n\t\t( actionId, items ) => {\n\t\t\tswitch ( actionId ) {\n\t\t\t\tcase 'move-to-trash':\n\t\t\t\t\t{\n\t\t\t\t\t\tdocument.location.href = addQueryArgs( 'edit.php', {\n\t\t\t\t\t\t\ttrashed: 1,\n\t\t\t\t\t\t\tpost_type: items[ 0 ].type,\n\t\t\t\t\t\t\tids: items[ 0 ].id,\n\t\t\t\t\t\t} );\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'duplicate-post':\n\t\t\t\t\t{\n\t\t\t\t\t\tconst newItem = items[ 0 ];\n\t\t\t\t\t\tconst title =\n\t\t\t\t\t\t\ttypeof newItem.title === 'string'\n\t\t\t\t\t\t\t\t? newItem.title\n\t\t\t\t\t\t\t\t: newItem.title?.rendered;\n\t\t\t\t\t\tcreateSuccessNotice(\n\t\t\t\t\t\t\tsprintf(\n\t\t\t\t\t\t\t\t// translators: %s: Title of the created post or template, e.g: \"Hello world\".\n\t\t\t\t\t\t\t\t__( '\"%s\" successfully created.' ),\n\t\t\t\t\t\t\t\tdecodeEntities( title ) || __( '(no title)' )\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\ttype: 'snackbar',\n\t\t\t\t\t\t\t\tid: 'duplicate-post-action',\n\t\t\t\t\t\t\t\tactions: [\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tlabel: __( 'Edit' ),\n\t\t\t\t\t\t\t\t\t\tonClick: () => {\n\t\t\t\t\t\t\t\t\t\t\tconst postId = newItem.id;\n\t\t\t\t\t\t\t\t\t\t\tdocument.location.href =\n\t\t\t\t\t\t\t\t\t\t\t\taddQueryArgs( 'post.php', {\n\t\t\t\t\t\t\t\t\t\t\t\t\tpost: postId,\n\t\t\t\t\t\t\t\t\t\t\t\t\taction: 'edit',\n\t\t\t\t\t\t\t\t\t\t\t\t} );\n\t\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[ createSuccessNotice ]\n\t);\n\n\tconst initialPost = useMemo( () => {\n\t\treturn {\n\t\t\ttype: initialPostType,\n\t\t\tid: initialPostId,\n\t\t};\n\t}, [ initialPostType, initialPostId ] );\n\n\tconst backButton =\n\t\tuseViewportMatch( 'medium' ) && isFullscreenActive ? (\n\t\t\t<BackButton initialPost={ initialPost } />\n\t\t) : null;\n\n\treturn (\n\t\t<SlotFillProvider>\n\t\t\t<ErrorBoundary canCopyContent>\n\t\t\t\t<WelcomeGuide postType={ currentPostType } />\n\t\t\t\t<div\n\t\t\t\t\tclassName={ navigateRegionsProps.className }\n\t\t\t\t\t{ ...navigateRegionsProps }\n\t\t\t\t\tref={ navigateRegionsProps.ref }\n\t\t\t\t>\n\t\t\t\t\t<Editor\n\t\t\t\t\t\tsettings={ editorSettings }\n\t\t\t\t\t\tinitialEdits={ initialEdits }\n\t\t\t\t\t\tpostType={ currentPostType }\n\t\t\t\t\t\tpostId={ currentPostId }\n\t\t\t\t\t\ttemplateId={ editableResolvedTemplateId }\n\t\t\t\t\t\tclassName={ className }\n\t\t\t\t\t\tstyles={ styles }\n\t\t\t\t\t\tforceIsDirty={ hasActiveMetaboxes }\n\t\t\t\t\t\tcontentRef={ paddingAppenderRef }\n\t\t\t\t\t\tdisableIframe={ ! shouldIframe }\n\t\t\t\t\t\t// We should auto-focus the canvas (title) on load.\n\t\t\t\t\t\t// eslint-disable-next-line jsx-a11y/no-autofocus\n\t\t\t\t\t\tautoFocus={ ! isWelcomeGuideVisible }\n\t\t\t\t\t\tonActionPerformed={ onActionPerformed }\n\t\t\t\t\t\textraSidebarPanels={\n\t\t\t\t\t\t\tshowMetaBoxes && <MetaBoxes location=\"side\" />\n\t\t\t\t\t\t}\n\t\t\t\t\t\textraContent={\n\t\t\t\t\t\t\t! isDistractionFree &&\n\t\t\t\t\t\t\tshowMetaBoxes && (\n\t\t\t\t\t\t\t\t<MetaBoxesMain\n\t\t\t\t\t\t\t\t\tisLegacy={\n\t\t\t\t\t\t\t\t\t\t! shouldIframe || isDevicePreview\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t}\n\t\t\t\t\t>\n\t\t\t\t\t\t<PostLockedModal />\n\t\t\t\t\t\t<EditorInitialization />\n\t\t\t\t\t\t<FullscreenMode isActive={ isFullscreenActive } />\n\t\t\t\t\t\t<BrowserURL />\n\t\t\t\t\t\t<UnsavedChangesWarning />\n\t\t\t\t\t\t<AutosaveMonitor />\n\t\t\t\t\t\t<LocalAutosaveMonitor />\n\t\t\t\t\t\t<EditPostKeyboardShortcuts />\n\t\t\t\t\t\t<EditorKeyboardShortcutsRegister />\n\t\t\t\t\t\t<BlockKeyboardShortcuts />\n\t\t\t\t\t\t<InitPatternModal />\n\t\t\t\t\t\t<PluginArea onError={ onPluginAreaError } />\n\t\t\t\t\t\t<PostEditorMoreMenu />\n\t\t\t\t\t\t{ backButton }\n\t\t\t\t\t\t<EditorSnackbars />\n\t\t\t\t\t</Editor>\n\t\t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AAAC,SAAA,EAA0B;AAAA,cAC3B,4CAAC,iDAAgC;AAAA,cACjC,4CAAC,0BAAuB;AAAA,cACxB,4CAAC,0BAAAC,SAAA,EAAiB;AAAA,cAClB,4CAAC,6BAAW,SAAU,mBAAoB;AAAA,cAC1C,4CAAC,iBAAAC,SAAA,EAAmB;AAAA,cAClB;AAAA,cACF,4CAAC,iCAAgB;AAAA;AAAA;AAAA,QAClB;AAAA;AAAA,IACD;AAAA,KACD,GACD;AAEF;AAEA,IAAO,iBAAQ;",
|
|
6
|
+
"names": ["blockEditorPrivateApis", "commandsPrivateApis", "editorPrivateApis", "blockLibraryPrivateApis", "editPostStore", "editorStore", "preferencesStore", "MetaBoxes", "useEditPostCommands", "noticesStore", "useNavigateToEntityRecord", "coreStore", "blockEditorStore", "useNavigateRegions", "clsx", "BackButton", "WelcomeGuide", "EditorInitialization", "BrowserURL", "EditPostKeyboardShortcuts", "InitPatternModal", "PostEditorMoreMenu"]
|
|
7
|
+
}
|
|
@@ -1,65 +1,72 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var use_padding_appender_exports = {};
|
|
19
|
+
__export(use_padding_appender_exports, {
|
|
20
|
+
usePaddingAppender: () => usePaddingAppender
|
|
5
21
|
});
|
|
6
|
-
exports
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
/**
|
|
12
|
-
* WordPress dependencies
|
|
13
|
-
*/
|
|
14
|
-
|
|
15
|
-
// Ruleset to add space for the typewriter effect. When typing in the last
|
|
16
|
-
// block, there needs to be room to scroll up.
|
|
22
|
+
module.exports = __toCommonJS(use_padding_appender_exports);
|
|
23
|
+
var import_data = require("@wordpress/data");
|
|
24
|
+
var import_compose = require("@wordpress/compose");
|
|
25
|
+
var import_block_editor = require("@wordpress/block-editor");
|
|
26
|
+
var import_blocks = require("@wordpress/blocks");
|
|
17
27
|
const CSS = ':root :where(.editor-styles-wrapper)::after {content: ""; display: block; height: 40vh;}';
|
|
18
28
|
function usePaddingAppender(enabled) {
|
|
19
|
-
const registry = (0,
|
|
20
|
-
const effect = (0,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
29
|
+
const registry = (0, import_data.useRegistry)();
|
|
30
|
+
const effect = (0, import_compose.useRefEffect)(
|
|
31
|
+
(node) => {
|
|
32
|
+
function onMouseDown(event) {
|
|
33
|
+
if (event.target !== node && // Tests for the parent element because in the iframed editor if the click is
|
|
34
|
+
// below the padding the target will be the parent element (html) and should
|
|
35
|
+
// still be treated as intent to append.
|
|
36
|
+
event.target !== node.parentElement) {
|
|
37
|
+
return;
|
|
38
|
+
}
|
|
39
|
+
const lastChild = node.lastElementChild;
|
|
40
|
+
if (!lastChild) {
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
const lastChildRect = lastChild.getBoundingClientRect();
|
|
44
|
+
if (event.clientY < lastChildRect.bottom) {
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
event.preventDefault();
|
|
48
|
+
const blockOrder = registry.select(import_block_editor.store).getBlockOrder("");
|
|
49
|
+
const lastBlockClientId = blockOrder[blockOrder.length - 1];
|
|
50
|
+
const lastBlock = registry.select(import_block_editor.store).getBlock(lastBlockClientId);
|
|
51
|
+
const { selectBlock, insertDefaultBlock } = registry.dispatch(import_block_editor.store);
|
|
52
|
+
if (lastBlock && (0, import_blocks.isUnmodifiedDefaultBlock)(lastBlock)) {
|
|
53
|
+
selectBlock(lastBlockClientId);
|
|
54
|
+
} else {
|
|
55
|
+
insertDefaultBlock();
|
|
56
|
+
}
|
|
28
57
|
}
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
return;
|
|
38
|
-
}
|
|
39
|
-
event.preventDefault();
|
|
40
|
-
const blockOrder = registry.select(_blockEditor.store).getBlockOrder('');
|
|
41
|
-
const lastBlockClientId = blockOrder[blockOrder.length - 1];
|
|
42
|
-
const lastBlock = registry.select(_blockEditor.store).getBlock(lastBlockClientId);
|
|
43
|
-
const {
|
|
44
|
-
selectBlock,
|
|
45
|
-
insertDefaultBlock
|
|
46
|
-
} = registry.dispatch(_blockEditor.store);
|
|
47
|
-
if (lastBlock && (0, _blocks.isUnmodifiedDefaultBlock)(lastBlock)) {
|
|
48
|
-
selectBlock(lastBlockClientId);
|
|
49
|
-
} else {
|
|
50
|
-
insertDefaultBlock();
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
const {
|
|
54
|
-
ownerDocument
|
|
55
|
-
} = node;
|
|
56
|
-
// Adds the listener on the document so that in the iframed editor clicks below the
|
|
57
|
-
// padding can be handled as they too should be treated as intent to append.
|
|
58
|
-
ownerDocument.addEventListener('mousedown', onMouseDown);
|
|
59
|
-
return () => {
|
|
60
|
-
ownerDocument.removeEventListener('mousedown', onMouseDown);
|
|
61
|
-
};
|
|
62
|
-
}, [registry]);
|
|
58
|
+
const { ownerDocument } = node;
|
|
59
|
+
ownerDocument.addEventListener("mousedown", onMouseDown);
|
|
60
|
+
return () => {
|
|
61
|
+
ownerDocument.removeEventListener("mousedown", onMouseDown);
|
|
62
|
+
};
|
|
63
|
+
},
|
|
64
|
+
[registry]
|
|
65
|
+
);
|
|
63
66
|
return enabled ? [effect, CSS] : [];
|
|
64
67
|
}
|
|
65
|
-
|
|
68
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
69
|
+
0 && (module.exports = {
|
|
70
|
+
usePaddingAppender
|
|
71
|
+
});
|
|
72
|
+
//# sourceMappingURL=use-padding-appender.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/layout/use-padding-appender.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useRegistry } from '@wordpress/data';\nimport { useRefEffect } from '@wordpress/compose';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\nimport { isUnmodifiedDefaultBlock } from '@wordpress/blocks';\n\n// Ruleset to add space for the typewriter effect. When typing in the last\n// block, there needs to be room to scroll up.\nconst CSS =\n\t':root :where(.editor-styles-wrapper)::after {content: \"\"; display: block; height: 40vh;}';\n\nexport function usePaddingAppender( enabled ) {\n\tconst registry = useRegistry();\n\tconst effect = useRefEffect(\n\t\t( node ) => {\n\t\t\tfunction onMouseDown( event ) {\n\t\t\t\tif (\n\t\t\t\t\tevent.target !== node &&\n\t\t\t\t\t// Tests for the parent element because in the iframed editor if the click is\n\t\t\t\t\t// below the padding the target will be the parent element (html) and should\n\t\t\t\t\t// still be treated as intent to append.\n\t\t\t\t\tevent.target !== node.parentElement\n\t\t\t\t) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// Only handle clicks under the last child.\n\t\t\t\tconst lastChild = node.lastElementChild;\n\t\t\t\tif ( ! lastChild ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tconst lastChildRect = lastChild.getBoundingClientRect();\n\t\t\t\tif ( event.clientY < lastChildRect.bottom ) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\tevent.preventDefault();\n\n\t\t\t\tconst blockOrder = registry\n\t\t\t\t\t.select( blockEditorStore )\n\t\t\t\t\t.getBlockOrder( '' );\n\t\t\t\tconst lastBlockClientId = blockOrder[ blockOrder.length - 1 ];\n\n\t\t\t\tconst lastBlock = registry\n\t\t\t\t\t.select( blockEditorStore )\n\t\t\t\t\t.getBlock( lastBlockClientId );\n\t\t\t\tconst { selectBlock, insertDefaultBlock } =\n\t\t\t\t\tregistry.dispatch( blockEditorStore );\n\n\t\t\t\tif ( lastBlock && isUnmodifiedDefaultBlock( lastBlock ) ) {\n\t\t\t\t\tselectBlock( lastBlockClientId );\n\t\t\t\t} else {\n\t\t\t\t\tinsertDefaultBlock();\n\t\t\t\t}\n\t\t\t}\n\t\t\tconst { ownerDocument } = node;\n\t\t\t// Adds the listener on the document so that in the iframed editor clicks below the\n\t\t\t// padding can be handled as they too should be treated as intent to append.\n\t\t\townerDocument.addEventListener( 'mousedown', onMouseDown );\n\t\t\treturn () => {\n\t\t\t\townerDocument.removeEventListener( 'mousedown', onMouseDown );\n\t\t\t};\n\t\t},\n\t\t[ registry ]\n\t);\n\treturn enabled ? [ effect, CSS ] : [];\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,kBAA4B;AAC5B,qBAA6B;AAC7B,0BAA0C;AAC1C,oBAAyC;AAIzC,MAAM,MACL;AAEM,SAAS,mBAAoB,SAAU;AAC7C,QAAM,eAAW,yBAAY;AAC7B,QAAM,aAAS;AAAA,IACd,CAAE,SAAU;AACX,eAAS,YAAa,OAAQ;AAC7B,YACC,MAAM,WAAW;AAAA;AAAA;AAAA,QAIjB,MAAM,WAAW,KAAK,eACrB;AACD;AAAA,QACD;AAGA,cAAM,YAAY,KAAK;AACvB,YAAK,CAAE,WAAY;AAClB;AAAA,QACD;AAEA,cAAM,gBAAgB,UAAU,sBAAsB;AACtD,YAAK,MAAM,UAAU,cAAc,QAAS;AAC3C;AAAA,QACD;AAEA,cAAM,eAAe;AAErB,cAAM,aAAa,SACjB,OAAQ,oBAAAA,KAAiB,EACzB,cAAe,EAAG;AACpB,cAAM,oBAAoB,WAAY,WAAW,SAAS,CAAE;AAE5D,cAAM,YAAY,SAChB,OAAQ,oBAAAA,KAAiB,EACzB,SAAU,iBAAkB;AAC9B,cAAM,EAAE,aAAa,mBAAmB,IACvC,SAAS,SAAU,oBAAAA,KAAiB;AAErC,YAAK,iBAAa,wCAA0B,SAAU,GAAI;AACzD,sBAAa,iBAAkB;AAAA,QAChC,OAAO;AACN,6BAAmB;AAAA,QACpB;AAAA,MACD;AACA,YAAM,EAAE,cAAc,IAAI;AAG1B,oBAAc,iBAAkB,aAAa,WAAY;AACzD,aAAO,MAAM;AACZ,sBAAc,oBAAqB,aAAa,WAAY;AAAA,MAC7D;AAAA,IACD;AAAA,IACA,CAAE,QAAS;AAAA,EACZ;AACA,SAAO,UAAU,CAAE,QAAQ,GAAI,IAAI,CAAC;AACrC;",
|
|
6
|
+
"names": ["blockEditorStore"]
|
|
7
|
+
}
|
|
@@ -1,43 +1,49 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
Object.
|
|
4
|
-
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var use_should_iframe_exports = {};
|
|
19
|
+
__export(use_should_iframe_exports, {
|
|
20
|
+
useShouldIframe: () => useShouldIframe
|
|
5
21
|
});
|
|
6
|
-
exports
|
|
7
|
-
var
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
/**
|
|
13
|
-
* WordPress dependencies
|
|
14
|
-
*/
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Internal dependencies
|
|
18
|
-
*/
|
|
19
|
-
|
|
22
|
+
module.exports = __toCommonJS(use_should_iframe_exports);
|
|
23
|
+
var import_editor = require("@wordpress/editor");
|
|
24
|
+
var import_data = require("@wordpress/data");
|
|
25
|
+
var import_blocks = require("@wordpress/blocks");
|
|
26
|
+
var import_block_editor = require("@wordpress/block-editor");
|
|
27
|
+
var import_lock_unlock = require("../../lock-unlock");
|
|
20
28
|
const isGutenbergPlugin = globalThis.IS_GUTENBERG_PLUGIN ? true : false;
|
|
21
29
|
function useShouldIframe() {
|
|
22
|
-
return (0,
|
|
23
|
-
const {
|
|
24
|
-
getEditorSettings,
|
|
25
|
-
getCurrentPostType,
|
|
26
|
-
getDeviceType
|
|
27
|
-
} = select(_editor.store);
|
|
30
|
+
return (0, import_data.useSelect)((select) => {
|
|
31
|
+
const { getEditorSettings, getCurrentPostType, getDeviceType } = select(import_editor.store);
|
|
28
32
|
return (
|
|
29
33
|
// If the theme is block based and the Gutenberg plugin is active,
|
|
30
34
|
// we ALWAYS use the iframe for consistency across the post and site
|
|
31
35
|
// editor.
|
|
32
|
-
isGutenbergPlugin && getEditorSettings().__unstableIsBlockBasedTheme ||
|
|
33
|
-
// We also still want to iframe all the special
|
|
36
|
+
isGutenbergPlugin && getEditorSettings().__unstableIsBlockBasedTheme || // We also still want to iframe all the special
|
|
34
37
|
// editor features and modes such as device previews, zoom out, and
|
|
35
38
|
// template/pattern editing.
|
|
36
|
-
getDeviceType() !==
|
|
37
|
-
// Finally, still iframe the editor if all blocks are v3 (which means
|
|
39
|
+
getDeviceType() !== "Desktop" || ["wp_template", "wp_block"].includes(getCurrentPostType()) || (0, import_lock_unlock.unlock)(select(import_block_editor.store)).isZoomOut() || // Finally, still iframe the editor if all blocks are v3 (which means
|
|
38
40
|
// they are marked as iframe-compatible).
|
|
39
|
-
select(
|
|
41
|
+
select(import_blocks.store).getBlockTypes().every((type) => type.apiVersion >= 3)
|
|
40
42
|
);
|
|
41
43
|
}, []);
|
|
42
44
|
}
|
|
43
|
-
|
|
45
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
46
|
+
0 && (module.exports = {
|
|
47
|
+
useShouldIframe
|
|
48
|
+
});
|
|
49
|
+
//# sourceMappingURL=use-should-iframe.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/layout/use-should-iframe.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { store as editorStore } from '@wordpress/editor';\nimport { useSelect } from '@wordpress/data';\nimport { store as blocksStore } from '@wordpress/blocks';\nimport { store as blockEditorStore } from '@wordpress/block-editor';\n\n/**\n * Internal dependencies\n */\nimport { unlock } from '../../lock-unlock';\n\nconst isGutenbergPlugin = globalThis.IS_GUTENBERG_PLUGIN ? true : false;\n\nexport function useShouldIframe() {\n\treturn useSelect( ( select ) => {\n\t\tconst { getEditorSettings, getCurrentPostType, getDeviceType } =\n\t\t\tselect( editorStore );\n\t\treturn (\n\t\t\t// If the theme is block based and the Gutenberg plugin is active,\n\t\t\t// we ALWAYS use the iframe for consistency across the post and site\n\t\t\t// editor.\n\t\t\t( isGutenbergPlugin &&\n\t\t\t\tgetEditorSettings().__unstableIsBlockBasedTheme ) ||\n\t\t\t// We also still want to iframe all the special\n\t\t\t// editor features and modes such as device previews, zoom out, and\n\t\t\t// template/pattern editing.\n\t\t\tgetDeviceType() !== 'Desktop' ||\n\t\t\t[ 'wp_template', 'wp_block' ].includes( getCurrentPostType() ) ||\n\t\t\tunlock( select( blockEditorStore ) ).isZoomOut() ||\n\t\t\t// Finally, still iframe the editor if all blocks are v3 (which means\n\t\t\t// they are marked as iframe-compatible).\n\t\t\tselect( blocksStore )\n\t\t\t\t.getBlockTypes()\n\t\t\t\t.every( ( type ) => type.apiVersion >= 3 )\n\t\t);\n\t}, [] );\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGA,oBAAqC;AACrC,kBAA0B;AAC1B,oBAAqC;AACrC,0BAA0C;AAK1C,yBAAuB;AAEvB,MAAM,oBAAoB,WAAW,sBAAsB,OAAO;AAE3D,SAAS,kBAAkB;AACjC,aAAO,uBAAW,CAAE,WAAY;AAC/B,UAAM,EAAE,mBAAmB,oBAAoB,cAAc,IAC5D,OAAQ,cAAAA,KAAY;AACrB;AAAA;AAAA;AAAA;AAAA,MAIG,qBACD,kBAAkB,EAAE;AAAA;AAAA;AAAA,MAIrB,cAAc,MAAM,aACpB,CAAE,eAAe,UAAW,EAAE,SAAU,mBAAmB,CAAE,SAC7D,2BAAQ,OAAQ,oBAAAC,KAAiB,CAAE,EAAE,UAAU;AAAA;AAAA,MAG/C,OAAQ,cAAAC,KAAY,EAClB,cAAc,EACd,MAAO,CAAE,SAAU,KAAK,cAAc,CAAE;AAAA;AAAA,EAE5C,GAAG,CAAC,CAAE;AACP;",
|
|
6
|
+
"names": ["editorStore", "blockEditorStore", "blocksStore"]
|
|
7
|
+
}
|
|
@@ -1,35 +1,48 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
var
|
|
4
|
-
Object.
|
|
5
|
-
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __export = (target, all) => {
|
|
8
|
+
for (var name in all)
|
|
9
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
25
|
+
mod
|
|
26
|
+
));
|
|
27
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
28
|
+
var meta_boxes_exports = {};
|
|
29
|
+
__export(meta_boxes_exports, {
|
|
30
|
+
default: () => MetaBoxes
|
|
6
31
|
});
|
|
7
|
-
exports
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
*/
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
location
|
|
23
|
-
}) {
|
|
24
|
-
const metaBoxes = (0, _data.useSelect)(select => select(_store.store).getMetaBoxesPerLocation(location), [location]);
|
|
25
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
26
|
-
children: [(metaBoxes !== null && metaBoxes !== void 0 ? metaBoxes : []).map(({
|
|
27
|
-
id
|
|
28
|
-
}) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_metaBoxVisibility.default, {
|
|
29
|
-
id: id
|
|
30
|
-
}, id)), /*#__PURE__*/(0, _jsxRuntime.jsx)(_metaBoxesArea.default, {
|
|
31
|
-
location: location
|
|
32
|
-
})]
|
|
33
|
-
});
|
|
32
|
+
module.exports = __toCommonJS(meta_boxes_exports);
|
|
33
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
34
|
+
var import_data = require("@wordpress/data");
|
|
35
|
+
var import_meta_boxes_area = __toESM(require("./meta-boxes-area"));
|
|
36
|
+
var import_meta_box_visibility = __toESM(require("./meta-box-visibility"));
|
|
37
|
+
var import_store = require("../../store");
|
|
38
|
+
function MetaBoxes({ location }) {
|
|
39
|
+
const metaBoxes = (0, import_data.useSelect)(
|
|
40
|
+
(select) => select(import_store.store).getMetaBoxesPerLocation(location),
|
|
41
|
+
[location]
|
|
42
|
+
);
|
|
43
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
44
|
+
(metaBoxes ?? []).map(({ id }) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_meta_box_visibility.default, { id }, id)),
|
|
45
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_meta_boxes_area.default, { location })
|
|
46
|
+
] });
|
|
34
47
|
}
|
|
35
|
-
//# sourceMappingURL=index.js.map
|
|
48
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/components/meta-boxes/index.js"],
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { useSelect } from '@wordpress/data';\n\n/**\n * Internal dependencies\n */\nimport MetaBoxesArea from './meta-boxes-area';\nimport MetaBoxVisibility from './meta-box-visibility';\nimport { store as editPostStore } from '../../store';\n\nexport default function MetaBoxes( { location } ) {\n\tconst metaBoxes = useSelect(\n\t\t( select ) =>\n\t\t\tselect( editPostStore ).getMetaBoxesPerLocation( location ),\n\t\t[ location ]\n\t);\n\treturn (\n\t\t<>\n\t\t\t{ ( metaBoxes ?? [] ).map( ( { id } ) => (\n\t\t\t\t<MetaBoxVisibility key={ id } id={ id } />\n\t\t\t) ) }\n\t\t\t<MetaBoxesArea location={ location } />\n\t\t</>\n\t);\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAmBE;AAhBF,kBAA0B;AAK1B,6BAA0B;AAC1B,iCAA8B;AAC9B,mBAAuC;AAExB,SAAR,UAA4B,EAAE,SAAS,GAAI;AACjD,QAAM,gBAAY;AAAA,IACjB,CAAE,WACD,OAAQ,aAAAA,KAAc,EAAE,wBAAyB,QAAS;AAAA,IAC3D,CAAE,QAAS;AAAA,EACZ;AACA,SACC,4EACK;AAAA,kBAAa,CAAC,GAAI,IAAK,CAAE,EAAE,GAAG,MACjC,4CAAC,2BAAAC,SAAA,EAA6B,MAAL,EAAe,CACvC;AAAA,IACF,4CAAC,uBAAAC,SAAA,EAAc,UAAsB;AAAA,KACtC;AAEF;",
|
|
6
|
+
"names": ["editPostStore", "MetaBoxVisibility", "MetaBoxesArea"]
|
|
7
|
+
}
|