Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/clone/wp-inclu.../js/dist
File: block-editor.js
getBlockName,
[41000] Fix | Delete
isFirstMultiSelectedBlock,
[41001] Fix | Delete
getMultiSelectedBlockClientIds,
[41002] Fix | Delete
hasSelectedInnerBlock,
[41003] Fix | Delete
getBlocksByName,
[41004] Fix | Delete
getBlockIndex,
[41005] Fix | Delete
isBlockMultiSelected,
[41006] Fix | Delete
isBlockSubtreeDisabled,
[41007] Fix | Delete
isBlockHighlighted,
[41008] Fix | Delete
__unstableIsFullySelected,
[41009] Fix | Delete
__unstableSelectionHasUnmergeableBlock,
[41010] Fix | Delete
isBlockBeingDragged,
[41011] Fix | Delete
isDragging,
[41012] Fix | Delete
hasBlockMovingClientId,
[41013] Fix | Delete
canInsertBlockType,
[41014] Fix | Delete
__unstableHasActiveBlockOverlayActive,
[41015] Fix | Delete
__unstableGetEditorMode,
[41016] Fix | Delete
getSelectedBlocksInitialCaretPosition
[41017] Fix | Delete
} = unlock(select(store));
[41018] Fix | Delete
const blockWithoutAttributes = getBlockWithoutAttributes(clientId);
[41019] Fix | Delete
[41020] Fix | Delete
// This is a temporary fix.
[41021] Fix | Delete
// This function should never be called when a block is not
[41022] Fix | Delete
// present in the state. It happens now because the order in
[41023] Fix | Delete
// withSelect rendering is not correct.
[41024] Fix | Delete
if (!blockWithoutAttributes) {
[41025] Fix | Delete
return;
[41026] Fix | Delete
}
[41027] Fix | Delete
const {
[41028] Fix | Delete
hasBlockSupport: _hasBlockSupport,
[41029] Fix | Delete
getActiveBlockVariation
[41030] Fix | Delete
} = select(external_wp_blocks_namespaceObject.store);
[41031] Fix | Delete
const attributes = getBlockAttributes(clientId);
[41032] Fix | Delete
const {
[41033] Fix | Delete
name: blockName,
[41034] Fix | Delete
isValid
[41035] Fix | Delete
} = blockWithoutAttributes;
[41036] Fix | Delete
const blockType = (0,external_wp_blocks_namespaceObject.getBlockType)(blockName);
[41037] Fix | Delete
const {
[41038] Fix | Delete
supportsLayout,
[41039] Fix | Delete
__unstableIsPreviewMode: isPreviewMode
[41040] Fix | Delete
} = getSettings();
[41041] Fix | Delete
const hasLightBlockWrapper = blockType?.apiVersion > 1;
[41042] Fix | Delete
const previewContext = {
[41043] Fix | Delete
isPreviewMode,
[41044] Fix | Delete
blockWithoutAttributes,
[41045] Fix | Delete
name: blockName,
[41046] Fix | Delete
attributes,
[41047] Fix | Delete
isValid,
[41048] Fix | Delete
themeSupportsLayout: supportsLayout,
[41049] Fix | Delete
index: getBlockIndex(clientId),
[41050] Fix | Delete
isReusable: (0,external_wp_blocks_namespaceObject.isReusableBlock)(blockType),
[41051] Fix | Delete
className: hasLightBlockWrapper ? attributes.className : undefined,
[41052] Fix | Delete
defaultClassName: hasLightBlockWrapper ? (0,external_wp_blocks_namespaceObject.getBlockDefaultClassName)(blockName) : undefined,
[41053] Fix | Delete
blockTitle: blockType?.title
[41054] Fix | Delete
};
[41055] Fix | Delete
[41056] Fix | Delete
// When in preview mode, we can avoid a lot of selection and
[41057] Fix | Delete
// editing related selectors.
[41058] Fix | Delete
if (isPreviewMode) {
[41059] Fix | Delete
return previewContext;
[41060] Fix | Delete
}
[41061] Fix | Delete
const _isSelected = isBlockSelected(clientId);
[41062] Fix | Delete
const canRemove = canRemoveBlock(clientId);
[41063] Fix | Delete
const canMove = canMoveBlock(clientId);
[41064] Fix | Delete
const match = getActiveBlockVariation(blockName, attributes);
[41065] Fix | Delete
const isMultiSelected = isBlockMultiSelected(clientId);
[41066] Fix | Delete
const checkDeep = true;
[41067] Fix | Delete
const isAncestorOfSelectedBlock = hasSelectedInnerBlock(clientId, checkDeep);
[41068] Fix | Delete
const movingClientId = hasBlockMovingClientId();
[41069] Fix | Delete
const blockEditingMode = getBlockEditingMode(clientId);
[41070] Fix | Delete
const multiple = (0,external_wp_blocks_namespaceObject.hasBlockSupport)(blockName, 'multiple', true);
[41071] Fix | Delete
[41072] Fix | Delete
// For block types with `multiple` support, there is no "original
[41073] Fix | Delete
// block" to be found in the content, as the block itself is valid.
[41074] Fix | Delete
const blocksWithSameName = multiple ? [] : getBlocksByName(blockName);
[41075] Fix | Delete
const isInvalid = blocksWithSameName.length && blocksWithSameName[0] !== clientId;
[41076] Fix | Delete
return {
[41077] Fix | Delete
...previewContext,
[41078] Fix | Delete
mode: getBlockMode(clientId),
[41079] Fix | Delete
isSelectionEnabled: isSelectionEnabled(),
[41080] Fix | Delete
isLocked: !!getTemplateLock(rootClientId),
[41081] Fix | Delete
templateLock: getTemplateLock(clientId),
[41082] Fix | Delete
canRemove,
[41083] Fix | Delete
canMove,
[41084] Fix | Delete
isSelected: _isSelected,
[41085] Fix | Delete
isTemporarilyEditingAsBlocks: getTemporarilyEditingAsBlocks() === clientId,
[41086] Fix | Delete
blockEditingMode,
[41087] Fix | Delete
mayDisplayControls: _isSelected || isFirstMultiSelectedBlock(clientId) && getMultiSelectedBlockClientIds().every(id => getBlockName(id) === blockName),
[41088] Fix | Delete
mayDisplayParentControls: _hasBlockSupport(getBlockName(clientId), '__experimentalExposeControlsToChildren', false) && hasSelectedInnerBlock(clientId),
[41089] Fix | Delete
blockApiVersion: blockType?.apiVersion || 1,
[41090] Fix | Delete
blockTitle: match?.title || blockType?.title,
[41091] Fix | Delete
isSubtreeDisabled: blockEditingMode === 'disabled' && isBlockSubtreeDisabled(clientId),
[41092] Fix | Delete
hasOverlay: __unstableHasActiveBlockOverlayActive(clientId) && !isDragging(),
[41093] Fix | Delete
initialPosition: _isSelected && (__unstableGetEditorMode() === 'edit' || __unstableGetEditorMode() === 'zoom-out') // Don't recalculate the initialPosition when toggling in/out of zoom-out mode
[41094] Fix | Delete
? getSelectedBlocksInitialCaretPosition() : undefined,
[41095] Fix | Delete
isHighlighted: isBlockHighlighted(clientId),
[41096] Fix | Delete
isMultiSelected,
[41097] Fix | Delete
isPartiallySelected: isMultiSelected && !__unstableIsFullySelected() && !__unstableSelectionHasUnmergeableBlock(),
[41098] Fix | Delete
isDragging: isBlockBeingDragged(clientId),
[41099] Fix | Delete
hasChildSelected: isAncestorOfSelectedBlock,
[41100] Fix | Delete
isBlockMovingMode: !!movingClientId,
[41101] Fix | Delete
canInsertMovingBlock: movingClientId && canInsertBlockType(getBlockName(movingClientId), rootClientId),
[41102] Fix | Delete
isEditingDisabled: blockEditingMode === 'disabled',
[41103] Fix | Delete
hasEditableOutline: blockEditingMode !== 'disabled' && getBlockEditingMode(rootClientId) === 'disabled',
[41104] Fix | Delete
originalBlockClientId: isInvalid ? blocksWithSameName[0] : false
[41105] Fix | Delete
};
[41106] Fix | Delete
}, [clientId, rootClientId]);
[41107] Fix | Delete
const {
[41108] Fix | Delete
isPreviewMode,
[41109] Fix | Delete
// Fill values that end up as a public API and may not be defined in
[41110] Fix | Delete
// preview mode.
[41111] Fix | Delete
mode = 'visual',
[41112] Fix | Delete
isSelectionEnabled = false,
[41113] Fix | Delete
isLocked = false,
[41114] Fix | Delete
canRemove = false,
[41115] Fix | Delete
canMove = false,
[41116] Fix | Delete
blockWithoutAttributes,
[41117] Fix | Delete
name,
[41118] Fix | Delete
attributes,
[41119] Fix | Delete
isValid,
[41120] Fix | Delete
isSelected = false,
[41121] Fix | Delete
themeSupportsLayout,
[41122] Fix | Delete
isTemporarilyEditingAsBlocks,
[41123] Fix | Delete
blockEditingMode,
[41124] Fix | Delete
mayDisplayControls,
[41125] Fix | Delete
mayDisplayParentControls,
[41126] Fix | Delete
index,
[41127] Fix | Delete
blockApiVersion,
[41128] Fix | Delete
blockTitle,
[41129] Fix | Delete
isSubtreeDisabled,
[41130] Fix | Delete
hasOverlay,
[41131] Fix | Delete
initialPosition,
[41132] Fix | Delete
isHighlighted,
[41133] Fix | Delete
isMultiSelected,
[41134] Fix | Delete
isPartiallySelected,
[41135] Fix | Delete
isReusable,
[41136] Fix | Delete
isDragging,
[41137] Fix | Delete
hasChildSelected,
[41138] Fix | Delete
isBlockMovingMode,
[41139] Fix | Delete
canInsertMovingBlock,
[41140] Fix | Delete
templateLock,
[41141] Fix | Delete
isEditingDisabled,
[41142] Fix | Delete
hasEditableOutline,
[41143] Fix | Delete
className,
[41144] Fix | Delete
defaultClassName,
[41145] Fix | Delete
originalBlockClientId
[41146] Fix | Delete
} = selectedProps;
[41147] Fix | Delete
[41148] Fix | Delete
// Users of the editor.BlockListBlock filter used to be able to
[41149] Fix | Delete
// access the block prop.
[41150] Fix | Delete
// Ideally these blocks would rely on the clientId prop only.
[41151] Fix | Delete
// This is kept for backward compatibility reasons.
[41152] Fix | Delete
const block = (0,external_wp_element_namespaceObject.useMemo)(() => ({
[41153] Fix | Delete
...blockWithoutAttributes,
[41154] Fix | Delete
attributes
[41155] Fix | Delete
}), [blockWithoutAttributes, attributes]);
[41156] Fix | Delete
[41157] Fix | Delete
// Block is sometimes not mounted at the right time, causing it be
[41158] Fix | Delete
// undefined see issue for more info
[41159] Fix | Delete
// https://github.com/WordPress/gutenberg/issues/17013
[41160] Fix | Delete
if (!selectedProps) {
[41161] Fix | Delete
return null;
[41162] Fix | Delete
}
[41163] Fix | Delete
const privateContext = {
[41164] Fix | Delete
isPreviewMode,
[41165] Fix | Delete
clientId,
[41166] Fix | Delete
className,
[41167] Fix | Delete
index,
[41168] Fix | Delete
mode,
[41169] Fix | Delete
name,
[41170] Fix | Delete
blockApiVersion,
[41171] Fix | Delete
blockTitle,
[41172] Fix | Delete
isSelected,
[41173] Fix | Delete
isSubtreeDisabled,
[41174] Fix | Delete
hasOverlay,
[41175] Fix | Delete
initialPosition,
[41176] Fix | Delete
blockEditingMode,
[41177] Fix | Delete
isHighlighted,
[41178] Fix | Delete
isMultiSelected,
[41179] Fix | Delete
isPartiallySelected,
[41180] Fix | Delete
isReusable,
[41181] Fix | Delete
isDragging,
[41182] Fix | Delete
hasChildSelected,
[41183] Fix | Delete
isBlockMovingMode,
[41184] Fix | Delete
canInsertMovingBlock,
[41185] Fix | Delete
templateLock,
[41186] Fix | Delete
isEditingDisabled,
[41187] Fix | Delete
hasEditableOutline,
[41188] Fix | Delete
isTemporarilyEditingAsBlocks,
[41189] Fix | Delete
defaultClassName,
[41190] Fix | Delete
mayDisplayControls,
[41191] Fix | Delete
mayDisplayParentControls,
[41192] Fix | Delete
originalBlockClientId,
[41193] Fix | Delete
themeSupportsLayout
[41194] Fix | Delete
};
[41195] Fix | Delete
[41196] Fix | Delete
// Here we separate between the props passed to BlockListBlock and any other
[41197] Fix | Delete
// information we selected for internal use. BlockListBlock is a filtered
[41198] Fix | Delete
// component and thus ALL the props are PUBLIC API.
[41199] Fix | Delete
[41200] Fix | Delete
// Note that the context value doesn't have to be memoized in this case
[41201] Fix | Delete
// because when it changes, this component will be re-rendered anyway, and
[41202] Fix | Delete
// none of the consumers (BlockListBlock and useBlockProps) are memoized or
[41203] Fix | Delete
// "pure". This is different from the public BlockEditContext, where
[41204] Fix | Delete
// consumers might be memoized or "pure".
[41205] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(PrivateBlockContext.Provider, {
[41206] Fix | Delete
value: privateContext,
[41207] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(BlockListBlock, {
[41208] Fix | Delete
...props,
[41209] Fix | Delete
mode,
[41210] Fix | Delete
isSelectionEnabled,
[41211] Fix | Delete
isLocked,
[41212] Fix | Delete
canRemove,
[41213] Fix | Delete
canMove,
[41214] Fix | Delete
// Users of the editor.BlockListBlock filter used to be able
[41215] Fix | Delete
// to access the block prop. Ideally these blocks would rely
[41216] Fix | Delete
// on the clientId prop only. This is kept for backward
[41217] Fix | Delete
// compatibility reasons.
[41218] Fix | Delete
block,
[41219] Fix | Delete
name,
[41220] Fix | Delete
attributes,
[41221] Fix | Delete
isValid,
[41222] Fix | Delete
isSelected
[41223] Fix | Delete
})
[41224] Fix | Delete
});
[41225] Fix | Delete
}
[41226] Fix | Delete
/* harmony default export */ const block_list_block = ((0,external_wp_element_namespaceObject.memo)(BlockListBlockProvider));
[41227] Fix | Delete
[41228] Fix | Delete
;// CONCATENATED MODULE: external ["wp","htmlEntities"]
[41229] Fix | Delete
const external_wp_htmlEntities_namespaceObject = window["wp"]["htmlEntities"];
[41230] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/inserter/tips.js
[41231] Fix | Delete
/**
[41232] Fix | Delete
* WordPress dependencies
[41233] Fix | Delete
*/
[41234] Fix | Delete
[41235] Fix | Delete
[41236] Fix | Delete
[41237] Fix | Delete
[41238] Fix | Delete
const globalTips = [(0,external_wp_element_namespaceObject.createInterpolateElement)((0,external_wp_i18n_namespaceObject.__)('While writing, you can press <kbd>/</kbd> to quickly insert new blocks.'), {
[41239] Fix | Delete
kbd: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("kbd", {})
[41240] Fix | Delete
}), (0,external_wp_element_namespaceObject.createInterpolateElement)((0,external_wp_i18n_namespaceObject.__)('Indent a list by pressing <kbd>space</kbd> at the beginning of a line.'), {
[41241] Fix | Delete
kbd: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("kbd", {})
[41242] Fix | Delete
}), (0,external_wp_element_namespaceObject.createInterpolateElement)((0,external_wp_i18n_namespaceObject.__)('Outdent a list by pressing <kbd>backspace</kbd> at the beginning of a line.'), {
[41243] Fix | Delete
kbd: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("kbd", {})
[41244] Fix | Delete
}), (0,external_wp_i18n_namespaceObject.__)('Drag files into the editor to automatically insert media blocks.'), (0,external_wp_i18n_namespaceObject.__)("Change a block's type by pressing the block icon on the toolbar.")];
[41245] Fix | Delete
function Tips() {
[41246] Fix | Delete
const [randomIndex] = (0,external_wp_element_namespaceObject.useState)(
[41247] Fix | Delete
// Disable Reason: I'm not generating an HTML id.
[41248] Fix | Delete
// eslint-disable-next-line no-restricted-syntax
[41249] Fix | Delete
Math.floor(Math.random() * globalTips.length));
[41250] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Tip, {
[41251] Fix | Delete
children: globalTips[randomIndex]
[41252] Fix | Delete
});
[41253] Fix | Delete
}
[41254] Fix | Delete
/* harmony default export */ const tips = (Tips);
[41255] Fix | Delete
[41256] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/chevron-right.js
[41257] Fix | Delete
/**
[41258] Fix | Delete
* WordPress dependencies
[41259] Fix | Delete
*/
[41260] Fix | Delete
[41261] Fix | Delete
[41262] Fix | Delete
const chevronRight = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.SVG, {
[41263] Fix | Delete
xmlns: "http://www.w3.org/2000/svg",
[41264] Fix | Delete
viewBox: "0 0 24 24",
[41265] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.Path, {
[41266] Fix | Delete
d: "M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"
[41267] Fix | Delete
})
[41268] Fix | Delete
});
[41269] Fix | Delete
/* harmony default export */ const chevron_right = (chevronRight);
[41270] Fix | Delete
[41271] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/chevron-left.js
[41272] Fix | Delete
/**
[41273] Fix | Delete
* WordPress dependencies
[41274] Fix | Delete
*/
[41275] Fix | Delete
[41276] Fix | Delete
[41277] Fix | Delete
const chevronLeft = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.SVG, {
[41278] Fix | Delete
xmlns: "http://www.w3.org/2000/svg",
[41279] Fix | Delete
viewBox: "0 0 24 24",
[41280] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.Path, {
[41281] Fix | Delete
d: "M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"
[41282] Fix | Delete
})
[41283] Fix | Delete
});
[41284] Fix | Delete
/* harmony default export */ const chevron_left = (chevronLeft);
[41285] Fix | Delete
[41286] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-card/index.js
[41287] Fix | Delete
/**
[41288] Fix | Delete
* External dependencies
[41289] Fix | Delete
*/
[41290] Fix | Delete
[41291] Fix | Delete
[41292] Fix | Delete
/**
[41293] Fix | Delete
* WordPress dependencies
[41294] Fix | Delete
*/
[41295] Fix | Delete
[41296] Fix | Delete
[41297] Fix | Delete
[41298] Fix | Delete
[41299] Fix | Delete
[41300] Fix | Delete
[41301] Fix | Delete
/**
[41302] Fix | Delete
* Internal dependencies
[41303] Fix | Delete
*/
[41304] Fix | Delete
[41305] Fix | Delete
[41306] Fix | Delete
[41307] Fix | Delete
[41308] Fix | Delete
function BlockCard({
[41309] Fix | Delete
title,
[41310] Fix | Delete
icon,
[41311] Fix | Delete
description,
[41312] Fix | Delete
blockType,
[41313] Fix | Delete
className
[41314] Fix | Delete
}) {
[41315] Fix | Delete
if (blockType) {
[41316] Fix | Delete
external_wp_deprecated_default()('`blockType` property in `BlockCard component`', {
[41317] Fix | Delete
since: '5.7',
[41318] Fix | Delete
alternative: '`title, icon and description` properties'
[41319] Fix | Delete
});
[41320] Fix | Delete
({
[41321] Fix | Delete
title,
[41322] Fix | Delete
icon,
[41323] Fix | Delete
description
[41324] Fix | Delete
} = blockType);
[41325] Fix | Delete
}
[41326] Fix | Delete
const {
[41327] Fix | Delete
parentNavBlockClientId
[41328] Fix | Delete
} = (0,external_wp_data_namespaceObject.useSelect)(select => {
[41329] Fix | Delete
const {
[41330] Fix | Delete
getSelectedBlockClientId,
[41331] Fix | Delete
getBlockParentsByBlockName
[41332] Fix | Delete
} = select(store);
[41333] Fix | Delete
const _selectedBlockClientId = getSelectedBlockClientId();
[41334] Fix | Delete
return {
[41335] Fix | Delete
parentNavBlockClientId: getBlockParentsByBlockName(_selectedBlockClientId, 'core/navigation', true)[0]
[41336] Fix | Delete
};
[41337] Fix | Delete
}, []);
[41338] Fix | Delete
const {
[41339] Fix | Delete
selectBlock
[41340] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[41341] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)("div", {
[41342] Fix | Delete
className: dist_clsx('block-editor-block-card', className),
[41343] Fix | Delete
children: [parentNavBlockClientId &&
[41344] Fix | Delete
/*#__PURE__*/
[41345] Fix | Delete
// This is only used by the Navigation block for now. It's not ideal having Navigation block specific code here.
[41346] Fix | Delete
(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Button, {
[41347] Fix | Delete
onClick: () => selectBlock(parentNavBlockClientId),
[41348] Fix | Delete
label: (0,external_wp_i18n_namespaceObject.__)('Go to parent Navigation block'),
[41349] Fix | Delete
style:
[41350] Fix | Delete
// TODO: This style override is also used in ToolsPanelHeader.
[41351] Fix | Delete
// It should be supported out-of-the-box by Button.
[41352] Fix | Delete
{
[41353] Fix | Delete
minWidth: 24,
[41354] Fix | Delete
padding: 0
[41355] Fix | Delete
},
[41356] Fix | Delete
icon: (0,external_wp_i18n_namespaceObject.isRTL)() ? chevron_right : chevron_left,
[41357] Fix | Delete
size: "small"
[41358] Fix | Delete
}), /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(block_icon, {
[41359] Fix | Delete
icon: icon,
[41360] Fix | Delete
showColors: true
[41361] Fix | Delete
}), /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_wp_components_namespaceObject.__experimentalVStack, {
[41362] Fix | Delete
spacing: 1,
[41363] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("h2", {
[41364] Fix | Delete
className: "block-editor-block-card__title",
[41365] Fix | Delete
children: title
[41366] Fix | Delete
}), description && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.__experimentalText, {
[41367] Fix | Delete
className: "block-editor-block-card__description",
[41368] Fix | Delete
children: description
[41369] Fix | Delete
})]
[41370] Fix | Delete
})]
[41371] Fix | Delete
});
[41372] Fix | Delete
}
[41373] Fix | Delete
/* harmony default export */ const block_card = (BlockCard);
[41374] Fix | Delete
[41375] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/provider/with-registry-provider.js
[41376] Fix | Delete
/**
[41377] Fix | Delete
* WordPress dependencies
[41378] Fix | Delete
*/
[41379] Fix | Delete
[41380] Fix | Delete
[41381] Fix | Delete
[41382] Fix | Delete
[41383] Fix | Delete
/**
[41384] Fix | Delete
* Internal dependencies
[41385] Fix | Delete
*/
[41386] Fix | Delete
[41387] Fix | Delete
[41388] Fix | Delete
[41389] Fix | Delete
function getSubRegistry(subRegistries, registry, useSubRegistry) {
[41390] Fix | Delete
if (!useSubRegistry) {
[41391] Fix | Delete
return registry;
[41392] Fix | Delete
}
[41393] Fix | Delete
let subRegistry = subRegistries.get(registry);
[41394] Fix | Delete
if (!subRegistry) {
[41395] Fix | Delete
subRegistry = (0,external_wp_data_namespaceObject.createRegistry)({}, registry);
[41396] Fix | Delete
subRegistry.registerStore(STORE_NAME, storeConfig);
[41397] Fix | Delete
subRegistries.set(registry, subRegistry);
[41398] Fix | Delete
}
[41399] Fix | Delete
return subRegistry;
[41400] Fix | Delete
}
[41401] Fix | Delete
const withRegistryProvider = (0,external_wp_compose_namespaceObject.createHigherOrderComponent)(WrappedComponent => ({
[41402] Fix | Delete
useSubRegistry = true,
[41403] Fix | Delete
...props
[41404] Fix | Delete
}) => {
[41405] Fix | Delete
const registry = (0,external_wp_data_namespaceObject.useRegistry)();
[41406] Fix | Delete
const [subRegistries] = (0,external_wp_element_namespaceObject.useState)(() => new WeakMap());
[41407] Fix | Delete
const subRegistry = getSubRegistry(subRegistries, registry, useSubRegistry);
[41408] Fix | Delete
if (subRegistry === registry) {
[41409] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(WrappedComponent, {
[41410] Fix | Delete
registry: registry,
[41411] Fix | Delete
...props
[41412] Fix | Delete
});
[41413] Fix | Delete
}
[41414] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_data_namespaceObject.RegistryProvider, {
[41415] Fix | Delete
value: subRegistry,
[41416] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(WrappedComponent, {
[41417] Fix | Delete
registry: subRegistry,
[41418] Fix | Delete
...props
[41419] Fix | Delete
})
[41420] Fix | Delete
});
[41421] Fix | Delete
}, 'withRegistryProvider');
[41422] Fix | Delete
/* harmony default export */ const with_registry_provider = (withRegistryProvider);
[41423] Fix | Delete
[41424] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/provider/use-block-sync.js
[41425] Fix | Delete
/**
[41426] Fix | Delete
* WordPress dependencies
[41427] Fix | Delete
*/
[41428] Fix | Delete
[41429] Fix | Delete
[41430] Fix | Delete
[41431] Fix | Delete
[41432] Fix | Delete
/**
[41433] Fix | Delete
* Internal dependencies
[41434] Fix | Delete
*/
[41435] Fix | Delete
[41436] Fix | Delete
[41437] Fix | Delete
const use_block_sync_noop = () => {};
[41438] Fix | Delete
[41439] Fix | Delete
/**
[41440] Fix | Delete
* A function to call when the block value has been updated in the block-editor
[41441] Fix | Delete
* store.
[41442] Fix | Delete
*
[41443] Fix | Delete
* @callback onBlockUpdate
[41444] Fix | Delete
* @param {Object[]} blocks The updated blocks.
[41445] Fix | Delete
* @param {Object} options The updated block options, such as selectionStart
[41446] Fix | Delete
* and selectionEnd.
[41447] Fix | Delete
*/
[41448] Fix | Delete
[41449] Fix | Delete
/**
[41450] Fix | Delete
* useBlockSync is a side effect which handles bidirectional sync between the
[41451] Fix | Delete
* block-editor store and a controlling data source which provides blocks. This
[41452] Fix | Delete
* is most commonly used by the BlockEditorProvider to synchronize the contents
[41453] Fix | Delete
* of the block-editor store with the root entity, like a post.
[41454] Fix | Delete
*
[41455] Fix | Delete
* Another example would be the template part block, which provides blocks from
[41456] Fix | Delete
* a separate entity data source than a root entity. This hook syncs edits to
[41457] Fix | Delete
* the template part in the block editor back to the entity and vice-versa.
[41458] Fix | Delete
*
[41459] Fix | Delete
* Here are some of its basic functions:
[41460] Fix | Delete
* - Initalizes the block-editor store for the given clientID to the blocks
[41461] Fix | Delete
* given via props.
[41462] Fix | Delete
* - Adds incoming changes (like undo) to the block-editor store.
[41463] Fix | Delete
* - Adds outgoing changes (like editing content) to the controlling entity,
[41464] Fix | Delete
* determining if a change should be considered persistent or not.
[41465] Fix | Delete
* - Handles edge cases and race conditions which occur in those operations.
[41466] Fix | Delete
* - Ignores changes which happen to other entities (like nested inner block
[41467] Fix | Delete
* controllers.
[41468] Fix | Delete
* - Passes selection state from the block-editor store to the controlling entity.
[41469] Fix | Delete
*
[41470] Fix | Delete
* @param {Object} props Props for the block sync hook
[41471] Fix | Delete
* @param {string} props.clientId The client ID of the inner block controller.
[41472] Fix | Delete
* If none is passed, then it is assumed to be a
[41473] Fix | Delete
* root controller rather than an inner block
[41474] Fix | Delete
* controller.
[41475] Fix | Delete
* @param {Object[]} props.value The control value for the blocks. This value
[41476] Fix | Delete
* is used to initalize the block-editor store
[41477] Fix | Delete
* and for resetting the blocks to incoming
[41478] Fix | Delete
* changes like undo.
[41479] Fix | Delete
* @param {Object} props.selection The selection state responsible to restore the selection on undo/redo.
[41480] Fix | Delete
* @param {onBlockUpdate} props.onChange Function to call when a persistent
[41481] Fix | Delete
* change has been made in the block-editor blocks
[41482] Fix | Delete
* for the given clientId. For example, after
[41483] Fix | Delete
* this function is called, an entity is marked
[41484] Fix | Delete
* dirty because it has changes to save.
[41485] Fix | Delete
* @param {onBlockUpdate} props.onInput Function to call when a non-persistent
[41486] Fix | Delete
* change has been made in the block-editor blocks
[41487] Fix | Delete
* for the given clientId. When this is called,
[41488] Fix | Delete
* controlling sources do not become dirty.
[41489] Fix | Delete
*/
[41490] Fix | Delete
function useBlockSync({
[41491] Fix | Delete
clientId = null,
[41492] Fix | Delete
value: controlledBlocks,
[41493] Fix | Delete
selection: controlledSelection,
[41494] Fix | Delete
onChange = use_block_sync_noop,
[41495] Fix | Delete
onInput = use_block_sync_noop
[41496] Fix | Delete
}) {
[41497] Fix | Delete
const registry = (0,external_wp_data_namespaceObject.useRegistry)();
[41498] Fix | Delete
const {
[41499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function