: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
name: (0,external_wp_i18n_namespaceObject._x)('Large', 'Size of a UI element'),
name: (0,external_wp_i18n_namespaceObject._x)('Extra Large', 'Size of a UI element'),
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/dimension-control/index.js
* `DimensionControl` is a component designed to provide a UI to control spacing and/or dimensions.
* This feature is still experimental. “Experimental” means this is an early implementation subject to drastic and breaking changes.
* import { __experimentalDimensionControl as DimensionControl } from '@wordpress/components';
* import { useState } from '@wordpress/element';
* export default function MyCustomDimensionControl() {
* const [ paddingSize, setPaddingSize ] = useState( '' );
* onChange={ ( value ) => setPaddingSize( value ) }
function DimensionControl(props) {
__next40pxDefaultSize = false,
sizes = dimension_control_sizes,
const onChangeSpacingSize = val => {
const theSize = findSizeBySlug(sizes, val);
if (!theSize || value === theSize.slug) {
} else if (typeof onChange === 'function') {
const formatSizesAsOptions = theSizes => {
const options = theSizes.map(({
label: (0,external_wp_i18n_namespaceObject.__)('Default'),
const selectLabel = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_ReactJSXRuntime_namespaceObject.Fragment, {
children: [icon && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(build_module_icon, {
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(select_control, {
__next40pxDefaultSize: __next40pxDefaultSize,
className: dist_clsx(className, 'block-editor-dimension-control'),
hideLabelFromVision: false,
onChange: onChangeSpacingSize,
options: formatSizesAsOptions(sizes)
/* harmony default export */ const dimension_control = (DimensionControl);
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/disabled/styles/disabled-styles.js
function disabled_styles_EMOTION_STRINGIFIED_CSS_ERROR_() { return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."; }
const disabled_styles_disabledStyles = true ? {
styles: "position:relative;pointer-events:none;&::after{content:'';position:absolute;top:0;right:0;bottom:0;left:0;}*{pointer-events:none;}"
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/disabled/index.js
const Context = (0,external_wp_element_namespaceObject.createContext)(false);
Provider: disabled_Provider
* `Disabled` is a component which disables descendant tabbable elements and
* prevents pointer interaction.
* _Note: this component may not behave as expected in browsers that don't
* support the `inert` HTML attribute. We recommend adding the official WICG
* polyfill when using this component in your project._
* @see https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/inert
* import { Button, Disabled, TextControl } from '@wordpress/components';
* import { useState } from '@wordpress/element';
* const MyDisabled = () => {
* const [ isDisabled, setIsDisabled ] = useState( true );
* let input = <TextControl label="Input" onChange={ () => {} } />;
* input = <Disabled>{ input }</Disabled>;
* const toggleDisabled = () => {
* setIsDisabled( ( state ) => ! state );
* <Button variant="primary" onClick={ toggleDisabled }>
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(disabled_Provider, {
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("div", {
// @ts-ignore Reason: inert is a recent HTML attribute
inert: isDisabled ? 'true' : undefined,
className: isDisabled ? cx(disabled_styles_disabledStyles, className, 'components-disabled') : undefined,
Disabled.Context = Context;
Disabled.Consumer = Consumer;
/* harmony default export */ const disabled = (Disabled);
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/disclosure/index.js
// eslint-disable-next-line no-restricted-imports
* Accessible Disclosure component that controls visibility of a section of
* content. It follows the WAI-ARIA Disclosure Pattern.
const UnforwardedDisclosureContent = ({
const disclosure = useDisclosureStore({
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(DisclosureContent, {
const disclosure_DisclosureContent = (0,external_wp_element_namespaceObject.forwardRef)(UnforwardedDisclosureContent);
/* harmony default export */ const disclosure = ((/* unused pure expression or super */ null && (disclosure_DisclosureContent)));
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/draggable/index.js
const dragImageClass = 'components-draggable__invisible-drag-image';
const cloneWrapperClass = 'components-draggable__clone';
const bodyClass = 'is-dragging-components-draggable';
* `Draggable` is a Component that provides a way to set up a cross-browser
* (including IE) customizable drag image and the transfer data for the drag
* event. It decouples the drag handle and the element to drag: use it by
* wrapping the component that will become the drag handle and providing the DOM
* ID of the element to drag.
* Note that the drag handle needs to declare the `draggable="true"` property
* and bind the `Draggable`s `onDraggableStart` and `onDraggableEnd` event
* handlers to its own `onDragStart` and `onDragEnd` respectively. `Draggable`
* takes care of the logic to setup the drag image and the transfer data, but is
* not concerned with creating an actual DOM element that is draggable.
* import { Draggable, Panel, PanelBody } from '@wordpress/components';
* import { Icon, more } from '@wordpress/icons';
* const MyDraggable = () => (
* <div id="draggable-panel">
* <Panel header="Draggable panel">
* <Draggable elementId="draggable-panel" transferData={ {} }>
* { ( { onDraggableStart, onDraggableEnd } ) => (
* className="example-drag-handle"
* onDragStart={ onDraggableStart }
* onDragEnd={ onDraggableEnd }
appendToOwnerDocument = false,
__experimentalTransferDataType: transferDataType = 'text',
__experimentalDragComponent: dragComponent
const dragComponentRef = (0,external_wp_element_namespaceObject.useRef)(null);
const cleanup = (0,external_wp_element_namespaceObject.useRef)(() => {});
* Removes the element clone, resets cursor, and removes drag listener.
* @param event The non-custom DragEvent.
* This method does a couple of things:
* - Clones the current element and spawns clone over original element.
* - Adds a fake temporary drag image to avoid browser defaults.
* - Adds dragover listener.
* @param event The non-custom DragEvent.
event.dataTransfer.setData(transferDataType, JSON.stringify(transferData));
const cloneWrapper = ownerDocument.createElement('div');
// Reset position to 0,0. Natural stacking order will position this lower, even with a transform otherwise.
cloneWrapper.style.top = '0';
cloneWrapper.style.left = '0';
const dragImage = ownerDocument.createElement('div');
// Set a fake drag image to avoid browser defaults. Remove from DOM
// right after. event.dataTransfer.setDragImage is not supported yet in
// IE, we need to check for its existence first.
if ('function' === typeof event.dataTransfer.setDragImage) {
dragImage.classList.add(dragImageClass);
ownerDocument.body.appendChild(dragImage);
event.dataTransfer.setDragImage(dragImage, 0, 0);
cloneWrapper.classList.add(cloneWrapperClass);
cloneWrapper.classList.add(cloneClassname);
// If a dragComponent is defined, the following logic will clone the
// HTML node and inject it into the cloneWrapper.
if (dragComponentRef.current) {
// Position dragComponent at the same position as the cursor.
cloneWrapper.style.transform = `translate( ${x}px, ${y}px )`;
const clonedDragComponent = ownerDocument.createElement('div');
clonedDragComponent.innerHTML = dragComponentRef.current.innerHTML;
cloneWrapper.appendChild(clonedDragComponent);
// Inject the cloneWrapper into the DOM.
ownerDocument.body.appendChild(cloneWrapper);
const element = ownerDocument.getElementById(elementId);
// Prepare element clone and append to element wrapper.
const elementRect = element.getBoundingClientRect();
const elementWrapper = element.parentNode;
const elementTopOffset = elementRect.top;
const elementLeftOffset = elementRect.left;
cloneWrapper.style.width = `${elementRect.width + clonePadding * 2}px`;
const clone = element.cloneNode(true);
clone.id = `clone-${elementId}`;
// Position clone right over the original element (20px padding).
x = elementLeftOffset - clonePadding;
y = elementTopOffset - clonePadding;
cloneWrapper.style.transform = `translate( ${x}px, ${y}px )`;
// Hack: Remove iFrames as it's causing the embeds drag clone to freeze.
Array.from(clone.querySelectorAll('iframe')).forEach(child => child.parentNode?.removeChild(child));
cloneWrapper.appendChild(clone);
// Inject the cloneWrapper into the DOM.
if (appendToOwnerDocument) {
ownerDocument.body.appendChild(cloneWrapper);
elementWrapper?.appendChild(cloneWrapper);
// Mark the current cursor coordinates.
let cursorLeft = event.clientX;
let cursorTop = event.clientY;
// Skip doing any work if mouse has not moved.
if (cursorLeft === e.clientX && cursorTop === e.clientY) {
const nextX = x + e.clientX - cursorLeft;
const nextY = y + e.clientY - cursorTop;
cloneWrapper.style.transform = `translate( ${nextX}px, ${nextY}px )`;
// Aim for 60fps (16 ms per frame) for now. We can potentially use requestAnimationFrame (raf) instead,
// note that browsers may throttle raf below 60fps in certain conditions.
const throttledDragOver = (0,external_wp_compose_namespaceObject.throttle)(over, 16);
ownerDocument.addEventListener('dragover', throttledDragOver);
// Update cursor to 'grabbing', document wide.
ownerDocument.body.classList.add(bodyClass);
cleanup.current = () => {
if (cloneWrapper && cloneWrapper.parentNode) {
cloneWrapper.parentNode.removeChild(cloneWrapper);
if (dragImage && dragImage.parentNode) {
dragImage.parentNode.removeChild(dragImage);
ownerDocument.body.classList.remove(bodyClass);
ownerDocument.removeEventListener('dragover', throttledDragOver);
(0,external_wp_element_namespaceObject.useEffect)(() => () => {
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_ReactJSXRuntime_namespaceObject.Fragment, {
}), dragComponent && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("div", {
className: "components-draggable-drag-component-root",
/* harmony default export */ const draggable = (Draggable);
;// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/upload.js
const upload = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.SVG, {
xmlns: "http://www.w3.org/2000/svg",
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.Path, {
d: "M18.5 15v3.5H13V6.7l4.5 4.1 1-1.1-6.2-5.8-5.8 5.8 1 1.1 4-4v11.7h-6V15H4v5h16v-5z"
/* harmony default export */ const library_upload = (upload);
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/drop-zone/index.js
const drop_zone_backdrop = {