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
*/
[53500] Fix | Delete
const supports_hasTextColorSupport = nameOrType => {
[53501] Fix | Delete
const colorSupport = (0,external_wp_blocks_namespaceObject.getBlockSupport)(nameOrType, supports_COLOR_SUPPORT_KEY);
[53502] Fix | Delete
return colorSupport && colorSupport.text !== false;
[53503] Fix | Delete
};
[53504] Fix | Delete
[53505] Fix | Delete
/**
[53506] Fix | Delete
* Get block support for color properties.
[53507] Fix | Delete
*
[53508] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53509] Fix | Delete
* @param {string} feature Color feature to get.
[53510] Fix | Delete
*
[53511] Fix | Delete
* @return {unknown} The block support.
[53512] Fix | Delete
*/
[53513] Fix | Delete
const getColorSupport = (nameOrType, feature) => getBlockSupport(nameOrType, [supports_COLOR_SUPPORT_KEY, feature]);
[53514] Fix | Delete
[53515] Fix | Delete
/**
[53516] Fix | Delete
* Returns true if the block defines support for custom class name.
[53517] Fix | Delete
*
[53518] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53519] Fix | Delete
* @return {boolean} Whether the block supports the feature.
[53520] Fix | Delete
*/
[53521] Fix | Delete
const hasCustomClassNameSupport = nameOrType => (0,external_wp_blocks_namespaceObject.hasBlockSupport)(nameOrType, CUSTOM_CLASS_NAME_SUPPORT_KEY, true);
[53522] Fix | Delete
[53523] Fix | Delete
/**
[53524] Fix | Delete
* Returns the block support value for custom class name, if defined.
[53525] Fix | Delete
*
[53526] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53527] Fix | Delete
* @return {unknown} The block support value.
[53528] Fix | Delete
*/
[53529] Fix | Delete
const getCustomClassNameSupport = nameOrType => getBlockSupport(nameOrType, CUSTOM_CLASS_NAME_SUPPORT_KEY, true);
[53530] Fix | Delete
[53531] Fix | Delete
/**
[53532] Fix | Delete
* Returns true if the block defines support for font family.
[53533] Fix | Delete
*
[53534] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53535] Fix | Delete
* @return {boolean} Whether the block supports the feature.
[53536] Fix | Delete
*/
[53537] Fix | Delete
const hasFontFamilySupport = nameOrType => (0,external_wp_blocks_namespaceObject.hasBlockSupport)(nameOrType, supports_FONT_FAMILY_SUPPORT_KEY);
[53538] Fix | Delete
[53539] Fix | Delete
/**
[53540] Fix | Delete
* Returns the block support value for font family, if defined.
[53541] Fix | Delete
*
[53542] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53543] Fix | Delete
* @return {unknown} The block support value.
[53544] Fix | Delete
*/
[53545] Fix | Delete
const getFontFamilySupport = nameOrType => getBlockSupport(nameOrType, supports_FONT_FAMILY_SUPPORT_KEY);
[53546] Fix | Delete
[53547] Fix | Delete
/**
[53548] Fix | Delete
* Returns true if the block defines support for font size.
[53549] Fix | Delete
*
[53550] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53551] Fix | Delete
* @return {boolean} Whether the block supports the feature.
[53552] Fix | Delete
*/
[53553] Fix | Delete
const hasFontSizeSupport = nameOrType => (0,external_wp_blocks_namespaceObject.hasBlockSupport)(nameOrType, supports_FONT_SIZE_SUPPORT_KEY);
[53554] Fix | Delete
[53555] Fix | Delete
/**
[53556] Fix | Delete
* Returns the block support value for font size, if defined.
[53557] Fix | Delete
*
[53558] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53559] Fix | Delete
* @return {unknown} The block support value.
[53560] Fix | Delete
*/
[53561] Fix | Delete
const getFontSizeSupport = nameOrType => getBlockSupport(nameOrType, supports_FONT_SIZE_SUPPORT_KEY);
[53562] Fix | Delete
[53563] Fix | Delete
/**
[53564] Fix | Delete
* Returns true if the block defines support for layout.
[53565] Fix | Delete
*
[53566] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53567] Fix | Delete
* @return {boolean} Whether the block supports the feature.
[53568] Fix | Delete
*/
[53569] Fix | Delete
const hasLayoutSupport = nameOrType => (0,external_wp_blocks_namespaceObject.hasBlockSupport)(nameOrType, LAYOUT_SUPPORT_KEY);
[53570] Fix | Delete
[53571] Fix | Delete
/**
[53572] Fix | Delete
* Returns the block support value for layout, if defined.
[53573] Fix | Delete
*
[53574] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53575] Fix | Delete
* @return {unknown} The block support value.
[53576] Fix | Delete
*/
[53577] Fix | Delete
const getLayoutSupport = nameOrType => getBlockSupport(nameOrType, LAYOUT_SUPPORT_KEY);
[53578] Fix | Delete
[53579] Fix | Delete
/**
[53580] Fix | Delete
* Returns true if the block defines support for style.
[53581] Fix | Delete
*
[53582] Fix | Delete
* @param {string|Object} nameOrType Block name or type object.
[53583] Fix | Delete
* @return {boolean} Whether the block supports the feature.
[53584] Fix | Delete
*/
[53585] Fix | Delete
const supports_hasStyleSupport = nameOrType => supports_styleSupportKeys.some(key => (0,external_wp_blocks_namespaceObject.hasBlockSupport)(nameOrType, key));
[53586] Fix | Delete
[53587] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/use-paste-styles/index.js
[53588] Fix | Delete
/**
[53589] Fix | Delete
* WordPress dependencies
[53590] Fix | Delete
*/
[53591] Fix | Delete
[53592] Fix | Delete
[53593] Fix | Delete
[53594] Fix | Delete
[53595] Fix | Delete
[53596] Fix | Delete
[53597] Fix | Delete
/**
[53598] Fix | Delete
* Internal dependencies
[53599] Fix | Delete
*/
[53600] Fix | Delete
[53601] Fix | Delete
[53602] Fix | Delete
[53603] Fix | Delete
/**
[53604] Fix | Delete
* Determine if the copied text looks like serialized blocks or not.
[53605] Fix | Delete
* Since plain text will always get parsed into a freeform block,
[53606] Fix | Delete
* we check that if the parsed blocks is anything other than that.
[53607] Fix | Delete
*
[53608] Fix | Delete
* @param {string} text The copied text.
[53609] Fix | Delete
* @return {boolean} True if the text looks like serialized blocks, false otherwise.
[53610] Fix | Delete
*/
[53611] Fix | Delete
function hasSerializedBlocks(text) {
[53612] Fix | Delete
try {
[53613] Fix | Delete
const blocks = (0,external_wp_blocks_namespaceObject.parse)(text, {
[53614] Fix | Delete
__unstableSkipMigrationLogs: true,
[53615] Fix | Delete
__unstableSkipAutop: true
[53616] Fix | Delete
});
[53617] Fix | Delete
if (blocks.length === 1 && blocks[0].name === 'core/freeform') {
[53618] Fix | Delete
// It's likely that the text is just plain text and not serialized blocks.
[53619] Fix | Delete
return false;
[53620] Fix | Delete
}
[53621] Fix | Delete
return true;
[53622] Fix | Delete
} catch (err) {
[53623] Fix | Delete
// Parsing error, the text is not serialized blocks.
[53624] Fix | Delete
// (Even though that it technically won't happen)
[53625] Fix | Delete
return false;
[53626] Fix | Delete
}
[53627] Fix | Delete
}
[53628] Fix | Delete
[53629] Fix | Delete
/**
[53630] Fix | Delete
* Style attributes are attributes being added in `block-editor/src/hooks/*`.
[53631] Fix | Delete
* (Except for some unrelated to style like `anchor` or `settings`.)
[53632] Fix | Delete
* They generally represent the default block supports.
[53633] Fix | Delete
*/
[53634] Fix | Delete
const STYLE_ATTRIBUTES = {
[53635] Fix | Delete
align: hasAlignSupport,
[53636] Fix | Delete
borderColor: nameOrType => supports_hasBorderSupport(nameOrType, 'color'),
[53637] Fix | Delete
backgroundColor: supports_hasBackgroundColorSupport,
[53638] Fix | Delete
textAlign: hasTextAlignSupport,
[53639] Fix | Delete
textColor: supports_hasTextColorSupport,
[53640] Fix | Delete
gradient: supports_hasGradientSupport,
[53641] Fix | Delete
className: hasCustomClassNameSupport,
[53642] Fix | Delete
fontFamily: hasFontFamilySupport,
[53643] Fix | Delete
fontSize: hasFontSizeSupport,
[53644] Fix | Delete
layout: hasLayoutSupport,
[53645] Fix | Delete
style: supports_hasStyleSupport
[53646] Fix | Delete
};
[53647] Fix | Delete
[53648] Fix | Delete
/**
[53649] Fix | Delete
* Get the "style attributes" from a given block to a target block.
[53650] Fix | Delete
*
[53651] Fix | Delete
* @param {WPBlock} sourceBlock The source block.
[53652] Fix | Delete
* @param {WPBlock} targetBlock The target block.
[53653] Fix | Delete
* @return {Object} the filtered attributes object.
[53654] Fix | Delete
*/
[53655] Fix | Delete
function getStyleAttributes(sourceBlock, targetBlock) {
[53656] Fix | Delete
return Object.entries(STYLE_ATTRIBUTES).reduce((attributes, [attributeKey, hasSupport]) => {
[53657] Fix | Delete
// Only apply the attribute if both blocks support it.
[53658] Fix | Delete
if (hasSupport(sourceBlock.name) && hasSupport(targetBlock.name)) {
[53659] Fix | Delete
// Override attributes that are not present in the block to their defaults.
[53660] Fix | Delete
attributes[attributeKey] = sourceBlock.attributes[attributeKey];
[53661] Fix | Delete
}
[53662] Fix | Delete
return attributes;
[53663] Fix | Delete
}, {});
[53664] Fix | Delete
}
[53665] Fix | Delete
[53666] Fix | Delete
/**
[53667] Fix | Delete
* Update the target blocks with style attributes recursively.
[53668] Fix | Delete
*
[53669] Fix | Delete
* @param {WPBlock[]} targetBlocks The target blocks to be updated.
[53670] Fix | Delete
* @param {WPBlock[]} sourceBlocks The source blocks to get th style attributes from.
[53671] Fix | Delete
* @param {Function} updateBlockAttributes The function to update the attributes.
[53672] Fix | Delete
*/
[53673] Fix | Delete
function recursivelyUpdateBlockAttributes(targetBlocks, sourceBlocks, updateBlockAttributes) {
[53674] Fix | Delete
for (let index = 0; index < Math.min(sourceBlocks.length, targetBlocks.length); index += 1) {
[53675] Fix | Delete
updateBlockAttributes(targetBlocks[index].clientId, getStyleAttributes(sourceBlocks[index], targetBlocks[index]));
[53676] Fix | Delete
recursivelyUpdateBlockAttributes(targetBlocks[index].innerBlocks, sourceBlocks[index].innerBlocks, updateBlockAttributes);
[53677] Fix | Delete
}
[53678] Fix | Delete
}
[53679] Fix | Delete
[53680] Fix | Delete
/**
[53681] Fix | Delete
* A hook to return a pasteStyles event function for handling pasting styles to blocks.
[53682] Fix | Delete
*
[53683] Fix | Delete
* @return {Function} A function to update the styles to the blocks.
[53684] Fix | Delete
*/
[53685] Fix | Delete
function usePasteStyles() {
[53686] Fix | Delete
const registry = (0,external_wp_data_namespaceObject.useRegistry)();
[53687] Fix | Delete
const {
[53688] Fix | Delete
updateBlockAttributes
[53689] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[53690] Fix | Delete
const {
[53691] Fix | Delete
createSuccessNotice,
[53692] Fix | Delete
createWarningNotice,
[53693] Fix | Delete
createErrorNotice
[53694] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(external_wp_notices_namespaceObject.store);
[53695] Fix | Delete
return (0,external_wp_element_namespaceObject.useCallback)(async targetBlocks => {
[53696] Fix | Delete
let html = '';
[53697] Fix | Delete
try {
[53698] Fix | Delete
// `http:` sites won't have the clipboard property on navigator.
[53699] Fix | Delete
// (with the exception of localhost.)
[53700] Fix | Delete
if (!window.navigator.clipboard) {
[53701] Fix | Delete
createErrorNotice((0,external_wp_i18n_namespaceObject.__)('Unable to paste styles. This feature is only available on secure (https) sites in supporting browsers.'), {
[53702] Fix | Delete
type: 'snackbar'
[53703] Fix | Delete
});
[53704] Fix | Delete
return;
[53705] Fix | Delete
}
[53706] Fix | Delete
html = await window.navigator.clipboard.readText();
[53707] Fix | Delete
} catch (error) {
[53708] Fix | Delete
// Possibly the permission is denied.
[53709] Fix | Delete
createErrorNotice((0,external_wp_i18n_namespaceObject.__)('Unable to paste styles. Please allow browser clipboard permissions before continuing.'), {
[53710] Fix | Delete
type: 'snackbar'
[53711] Fix | Delete
});
[53712] Fix | Delete
return;
[53713] Fix | Delete
}
[53714] Fix | Delete
[53715] Fix | Delete
// Abort if the copied text is empty or doesn't look like serialized blocks.
[53716] Fix | Delete
if (!html || !hasSerializedBlocks(html)) {
[53717] Fix | Delete
createWarningNotice((0,external_wp_i18n_namespaceObject.__)("Unable to paste styles. Block styles couldn't be found within the copied content."), {
[53718] Fix | Delete
type: 'snackbar'
[53719] Fix | Delete
});
[53720] Fix | Delete
return;
[53721] Fix | Delete
}
[53722] Fix | Delete
const copiedBlocks = (0,external_wp_blocks_namespaceObject.parse)(html);
[53723] Fix | Delete
if (copiedBlocks.length === 1) {
[53724] Fix | Delete
// Apply styles of the block to all the target blocks.
[53725] Fix | Delete
registry.batch(() => {
[53726] Fix | Delete
recursivelyUpdateBlockAttributes(targetBlocks, targetBlocks.map(() => copiedBlocks[0]), updateBlockAttributes);
[53727] Fix | Delete
});
[53728] Fix | Delete
} else {
[53729] Fix | Delete
registry.batch(() => {
[53730] Fix | Delete
recursivelyUpdateBlockAttributes(targetBlocks, copiedBlocks, updateBlockAttributes);
[53731] Fix | Delete
});
[53732] Fix | Delete
}
[53733] Fix | Delete
if (targetBlocks.length === 1) {
[53734] Fix | Delete
const title = (0,external_wp_blocks_namespaceObject.getBlockType)(targetBlocks[0].name)?.title;
[53735] Fix | Delete
createSuccessNotice((0,external_wp_i18n_namespaceObject.sprintf)(
[53736] Fix | Delete
// Translators: Name of the block being pasted, e.g. "Paragraph".
[53737] Fix | Delete
(0,external_wp_i18n_namespaceObject.__)('Pasted styles to %s.'), title), {
[53738] Fix | Delete
type: 'snackbar'
[53739] Fix | Delete
});
[53740] Fix | Delete
} else {
[53741] Fix | Delete
createSuccessNotice((0,external_wp_i18n_namespaceObject.sprintf)(
[53742] Fix | Delete
// Translators: The number of the blocks.
[53743] Fix | Delete
(0,external_wp_i18n_namespaceObject.__)('Pasted styles to %d blocks.'), targetBlocks.length), {
[53744] Fix | Delete
type: 'snackbar'
[53745] Fix | Delete
});
[53746] Fix | Delete
}
[53747] Fix | Delete
}, [registry.batch, updateBlockAttributes, createSuccessNotice, createWarningNotice, createErrorNotice]);
[53748] Fix | Delete
}
[53749] Fix | Delete
[53750] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-actions/index.js
[53751] Fix | Delete
/**
[53752] Fix | Delete
* WordPress dependencies
[53753] Fix | Delete
*/
[53754] Fix | Delete
[53755] Fix | Delete
[53756] Fix | Delete
[53757] Fix | Delete
/**
[53758] Fix | Delete
* Internal dependencies
[53759] Fix | Delete
*/
[53760] Fix | Delete
[53761] Fix | Delete
[53762] Fix | Delete
[53763] Fix | Delete
function BlockActions({
[53764] Fix | Delete
clientIds,
[53765] Fix | Delete
children,
[53766] Fix | Delete
__experimentalUpdateSelection: updateSelection
[53767] Fix | Delete
}) {
[53768] Fix | Delete
const {
[53769] Fix | Delete
getDefaultBlockName,
[53770] Fix | Delete
getGroupingBlockName
[53771] Fix | Delete
} = (0,external_wp_data_namespaceObject.useSelect)(external_wp_blocks_namespaceObject.store);
[53772] Fix | Delete
const selected = (0,external_wp_data_namespaceObject.useSelect)(select => {
[53773] Fix | Delete
const {
[53774] Fix | Delete
canInsertBlockType,
[53775] Fix | Delete
getBlockRootClientId,
[53776] Fix | Delete
getBlocksByClientId,
[53777] Fix | Delete
getDirectInsertBlock,
[53778] Fix | Delete
canMoveBlocks,
[53779] Fix | Delete
canRemoveBlocks
[53780] Fix | Delete
} = select(store);
[53781] Fix | Delete
const blocks = getBlocksByClientId(clientIds);
[53782] Fix | Delete
const rootClientId = getBlockRootClientId(clientIds[0]);
[53783] Fix | Delete
const canInsertDefaultBlock = canInsertBlockType(getDefaultBlockName(), rootClientId);
[53784] Fix | Delete
const directInsertBlock = rootClientId ? getDirectInsertBlock(rootClientId) : null;
[53785] Fix | Delete
return {
[53786] Fix | Delete
canMove: canMoveBlocks(clientIds),
[53787] Fix | Delete
canRemove: canRemoveBlocks(clientIds),
[53788] Fix | Delete
canInsertBlock: canInsertDefaultBlock || !!directInsertBlock,
[53789] Fix | Delete
canCopyStyles: blocks.every(block => {
[53790] Fix | Delete
return !!block && ((0,external_wp_blocks_namespaceObject.hasBlockSupport)(block.name, 'color') || (0,external_wp_blocks_namespaceObject.hasBlockSupport)(block.name, 'typography'));
[53791] Fix | Delete
}),
[53792] Fix | Delete
canDuplicate: blocks.every(block => {
[53793] Fix | Delete
return !!block && (0,external_wp_blocks_namespaceObject.hasBlockSupport)(block.name, 'multiple', true) && canInsertBlockType(block.name, rootClientId);
[53794] Fix | Delete
})
[53795] Fix | Delete
};
[53796] Fix | Delete
}, [clientIds, getDefaultBlockName]);
[53797] Fix | Delete
const {
[53798] Fix | Delete
getBlocksByClientId,
[53799] Fix | Delete
getBlocks
[53800] Fix | Delete
} = (0,external_wp_data_namespaceObject.useSelect)(store);
[53801] Fix | Delete
const {
[53802] Fix | Delete
canMove,
[53803] Fix | Delete
canRemove,
[53804] Fix | Delete
canInsertBlock,
[53805] Fix | Delete
canCopyStyles,
[53806] Fix | Delete
canDuplicate
[53807] Fix | Delete
} = selected;
[53808] Fix | Delete
const {
[53809] Fix | Delete
removeBlocks,
[53810] Fix | Delete
replaceBlocks,
[53811] Fix | Delete
duplicateBlocks,
[53812] Fix | Delete
insertAfterBlock,
[53813] Fix | Delete
insertBeforeBlock,
[53814] Fix | Delete
flashBlock,
[53815] Fix | Delete
setBlockMovingClientId,
[53816] Fix | Delete
setNavigationMode,
[53817] Fix | Delete
selectBlock
[53818] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[53819] Fix | Delete
const notifyCopy = useNotifyCopy();
[53820] Fix | Delete
const pasteStyles = usePasteStyles();
[53821] Fix | Delete
return children({
[53822] Fix | Delete
canCopyStyles,
[53823] Fix | Delete
canDuplicate,
[53824] Fix | Delete
canInsertBlock,
[53825] Fix | Delete
canMove,
[53826] Fix | Delete
canRemove,
[53827] Fix | Delete
onDuplicate() {
[53828] Fix | Delete
return duplicateBlocks(clientIds, updateSelection);
[53829] Fix | Delete
},
[53830] Fix | Delete
onRemove() {
[53831] Fix | Delete
return removeBlocks(clientIds, updateSelection);
[53832] Fix | Delete
},
[53833] Fix | Delete
onInsertBefore() {
[53834] Fix | Delete
insertBeforeBlock(clientIds[0]);
[53835] Fix | Delete
},
[53836] Fix | Delete
onInsertAfter() {
[53837] Fix | Delete
insertAfterBlock(clientIds[clientIds.length - 1]);
[53838] Fix | Delete
},
[53839] Fix | Delete
onMoveTo() {
[53840] Fix | Delete
setNavigationMode(true);
[53841] Fix | Delete
selectBlock(clientIds[0]);
[53842] Fix | Delete
setBlockMovingClientId(clientIds[0]);
[53843] Fix | Delete
},
[53844] Fix | Delete
onGroup() {
[53845] Fix | Delete
if (!clientIds.length) {
[53846] Fix | Delete
return;
[53847] Fix | Delete
}
[53848] Fix | Delete
const groupingBlockName = getGroupingBlockName();
[53849] Fix | Delete
[53850] Fix | Delete
// Activate the `transform` on `core/group` which does the conversion.
[53851] Fix | Delete
const newBlocks = (0,external_wp_blocks_namespaceObject.switchToBlockType)(getBlocksByClientId(clientIds), groupingBlockName);
[53852] Fix | Delete
if (!newBlocks) {
[53853] Fix | Delete
return;
[53854] Fix | Delete
}
[53855] Fix | Delete
replaceBlocks(clientIds, newBlocks);
[53856] Fix | Delete
},
[53857] Fix | Delete
onUngroup() {
[53858] Fix | Delete
if (!clientIds.length) {
[53859] Fix | Delete
return;
[53860] Fix | Delete
}
[53861] Fix | Delete
const innerBlocks = getBlocks(clientIds[0]);
[53862] Fix | Delete
if (!innerBlocks.length) {
[53863] Fix | Delete
return;
[53864] Fix | Delete
}
[53865] Fix | Delete
replaceBlocks(clientIds, innerBlocks);
[53866] Fix | Delete
},
[53867] Fix | Delete
onCopy() {
[53868] Fix | Delete
if (clientIds.length === 1) {
[53869] Fix | Delete
flashBlock(clientIds[0]);
[53870] Fix | Delete
}
[53871] Fix | Delete
notifyCopy('copy', clientIds);
[53872] Fix | Delete
},
[53873] Fix | Delete
async onPasteStyles() {
[53874] Fix | Delete
await pasteStyles(getBlocksByClientId(clientIds));
[53875] Fix | Delete
}
[53876] Fix | Delete
});
[53877] Fix | Delete
}
[53878] Fix | Delete
[53879] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-settings-menu/block-html-convert-button.js
[53880] Fix | Delete
/**
[53881] Fix | Delete
* WordPress dependencies
[53882] Fix | Delete
*/
[53883] Fix | Delete
[53884] Fix | Delete
[53885] Fix | Delete
[53886] Fix | Delete
[53887] Fix | Delete
[53888] Fix | Delete
/**
[53889] Fix | Delete
* Internal dependencies
[53890] Fix | Delete
*/
[53891] Fix | Delete
[53892] Fix | Delete
[53893] Fix | Delete
function BlockHTMLConvertButton({
[53894] Fix | Delete
clientId
[53895] Fix | Delete
}) {
[53896] Fix | Delete
const block = (0,external_wp_data_namespaceObject.useSelect)(select => select(store).getBlock(clientId), [clientId]);
[53897] Fix | Delete
const {
[53898] Fix | Delete
replaceBlocks
[53899] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[53900] Fix | Delete
if (!block || block.name !== 'core/html') {
[53901] Fix | Delete
return null;
[53902] Fix | Delete
}
[53903] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.MenuItem, {
[53904] Fix | Delete
onClick: () => replaceBlocks(clientId, (0,external_wp_blocks_namespaceObject.rawHandler)({
[53905] Fix | Delete
HTML: (0,external_wp_blocks_namespaceObject.getBlockContent)(block)
[53906] Fix | Delete
})),
[53907] Fix | Delete
children: (0,external_wp_i18n_namespaceObject.__)('Convert to Blocks')
[53908] Fix | Delete
});
[53909] Fix | Delete
}
[53910] Fix | Delete
/* harmony default export */ const block_html_convert_button = (BlockHTMLConvertButton);
[53911] Fix | Delete
[53912] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-settings-menu/block-settings-menu-first-item.js
[53913] Fix | Delete
/**
[53914] Fix | Delete
* WordPress dependencies
[53915] Fix | Delete
*/
[53916] Fix | Delete
[53917] Fix | Delete
const {
[53918] Fix | Delete
Fill: __unstableBlockSettingsMenuFirstItem,
[53919] Fix | Delete
Slot: block_settings_menu_first_item_Slot
[53920] Fix | Delete
} = (0,external_wp_components_namespaceObject.createSlotFill)('__unstableBlockSettingsMenuFirstItem');
[53921] Fix | Delete
__unstableBlockSettingsMenuFirstItem.Slot = block_settings_menu_first_item_Slot;
[53922] Fix | Delete
/* harmony default export */ const block_settings_menu_first_item = (__unstableBlockSettingsMenuFirstItem);
[53923] Fix | Delete
[53924] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-settings-menu/block-parent-selector-menu-item.js
[53925] Fix | Delete
/**
[53926] Fix | Delete
* WordPress dependencies
[53927] Fix | Delete
*/
[53928] Fix | Delete
[53929] Fix | Delete
[53930] Fix | Delete
[53931] Fix | Delete
[53932] Fix | Delete
[53933] Fix | Delete
[53934] Fix | Delete
/**
[53935] Fix | Delete
* Internal dependencies
[53936] Fix | Delete
*/
[53937] Fix | Delete
[53938] Fix | Delete
[53939] Fix | Delete
[53940] Fix | Delete
[53941] Fix | Delete
function BlockParentSelectorMenuItem({
[53942] Fix | Delete
parentClientId,
[53943] Fix | Delete
parentBlockType
[53944] Fix | Delete
}) {
[53945] Fix | Delete
const isSmallViewport = (0,external_wp_compose_namespaceObject.useViewportMatch)('medium', '<');
[53946] Fix | Delete
const {
[53947] Fix | Delete
selectBlock
[53948] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[53949] Fix | Delete
[53950] Fix | Delete
// Allows highlighting the parent block outline when focusing or hovering
[53951] Fix | Delete
// the parent block selector within the child.
[53952] Fix | Delete
const menuItemRef = (0,external_wp_element_namespaceObject.useRef)();
[53953] Fix | Delete
const gesturesProps = useShowHoveredOrFocusedGestures({
[53954] Fix | Delete
ref: menuItemRef,
[53955] Fix | Delete
highlightParent: true
[53956] Fix | Delete
});
[53957] Fix | Delete
if (!isSmallViewport) {
[53958] Fix | Delete
return null;
[53959] Fix | Delete
}
[53960] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.MenuItem, {
[53961] Fix | Delete
...gesturesProps,
[53962] Fix | Delete
ref: menuItemRef,
[53963] Fix | Delete
icon: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(block_icon, {
[53964] Fix | Delete
icon: parentBlockType.icon
[53965] Fix | Delete
}),
[53966] Fix | Delete
onClick: () => selectBlock(parentClientId),
[53967] Fix | Delete
children: (0,external_wp_i18n_namespaceObject.sprintf)( /* translators: %s: Name of the block's parent. */
[53968] Fix | Delete
(0,external_wp_i18n_namespaceObject.__)('Select parent block (%s)'), parentBlockType.title)
[53969] Fix | Delete
});
[53970] Fix | Delete
}
[53971] Fix | Delete
[53972] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/block-editor/build-module/components/block-settings-menu/block-settings-dropdown.js
[53973] Fix | Delete
/**
[53974] Fix | Delete
* WordPress dependencies
[53975] Fix | Delete
*/
[53976] Fix | Delete
[53977] Fix | Delete
[53978] Fix | Delete
[53979] Fix | Delete
[53980] Fix | Delete
[53981] Fix | Delete
[53982] Fix | Delete
[53983] Fix | Delete
[53984] Fix | Delete
[53985] Fix | Delete
[53986] Fix | Delete
/**
[53987] Fix | Delete
* Internal dependencies
[53988] Fix | Delete
*/
[53989] Fix | Delete
[53990] Fix | Delete
[53991] Fix | Delete
[53992] Fix | Delete
[53993] Fix | Delete
[53994] Fix | Delete
[53995] Fix | Delete
[53996] Fix | Delete
[53997] Fix | Delete
[53998] Fix | Delete
[53999] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function