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: components.js
const listener = event => {
[34500] Fix | Delete
// Do nothing if clicking ref's element or descendent elements, or if the ref is not referencing an element
[34501] Fix | Delete
if (!ref.current || ref.current.contains(event.target)) {
[34502] Fix | Delete
return;
[34503] Fix | Delete
}
[34504] Fix | Delete
handler(event);
[34505] Fix | Delete
};
[34506] Fix | Delete
document.addEventListener('mousedown', listener);
[34507] Fix | Delete
document.addEventListener('touchstart', listener);
[34508] Fix | Delete
return () => {
[34509] Fix | Delete
document.removeEventListener('mousedown', listener);
[34510] Fix | Delete
document.removeEventListener('touchstart', listener);
[34511] Fix | Delete
};
[34512] Fix | Delete
// Disable reason: `ref` is a ref object and should not be included in a
[34513] Fix | Delete
// hook's dependency list.
[34514] Fix | Delete
// eslint-disable-next-line react-hooks/exhaustive-deps
[34515] Fix | Delete
}, [handler]);
[34516] Fix | Delete
}
[34517] Fix | Delete
[34518] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/autocomplete/index.js
[34519] Fix | Delete
/**
[34520] Fix | Delete
* External dependencies
[34521] Fix | Delete
*/
[34522] Fix | Delete
[34523] Fix | Delete
[34524] Fix | Delete
/**
[34525] Fix | Delete
* WordPress dependencies
[34526] Fix | Delete
*/
[34527] Fix | Delete
[34528] Fix | Delete
[34529] Fix | Delete
[34530] Fix | Delete
[34531] Fix | Delete
[34532] Fix | Delete
[34533] Fix | Delete
/**
[34534] Fix | Delete
* Internal dependencies
[34535] Fix | Delete
*/
[34536] Fix | Delete
[34537] Fix | Delete
[34538] Fix | Delete
[34539] Fix | Delete
[34540] Fix | Delete
[34541] Fix | Delete
[34542] Fix | Delete
const getNodeText = node => {
[34543] Fix | Delete
if (node === null) {
[34544] Fix | Delete
return '';
[34545] Fix | Delete
}
[34546] Fix | Delete
switch (typeof node) {
[34547] Fix | Delete
case 'string':
[34548] Fix | Delete
case 'number':
[34549] Fix | Delete
return node.toString();
[34550] Fix | Delete
break;
[34551] Fix | Delete
case 'boolean':
[34552] Fix | Delete
return '';
[34553] Fix | Delete
break;
[34554] Fix | Delete
case 'object':
[34555] Fix | Delete
{
[34556] Fix | Delete
if (node instanceof Array) {
[34557] Fix | Delete
return node.map(getNodeText).join('');
[34558] Fix | Delete
}
[34559] Fix | Delete
if ('props' in node) {
[34560] Fix | Delete
return getNodeText(node.props.children);
[34561] Fix | Delete
}
[34562] Fix | Delete
break;
[34563] Fix | Delete
}
[34564] Fix | Delete
default:
[34565] Fix | Delete
return '';
[34566] Fix | Delete
}
[34567] Fix | Delete
return '';
[34568] Fix | Delete
};
[34569] Fix | Delete
const EMPTY_FILTERED_OPTIONS = [];
[34570] Fix | Delete
function useAutocomplete({
[34571] Fix | Delete
record,
[34572] Fix | Delete
onChange,
[34573] Fix | Delete
onReplace,
[34574] Fix | Delete
completers,
[34575] Fix | Delete
contentRef
[34576] Fix | Delete
}) {
[34577] Fix | Delete
const instanceId = (0,external_wp_compose_namespaceObject.useInstanceId)(useAutocomplete);
[34578] Fix | Delete
const [selectedIndex, setSelectedIndex] = (0,external_wp_element_namespaceObject.useState)(0);
[34579] Fix | Delete
const [filteredOptions, setFilteredOptions] = (0,external_wp_element_namespaceObject.useState)(EMPTY_FILTERED_OPTIONS);
[34580] Fix | Delete
const [filterValue, setFilterValue] = (0,external_wp_element_namespaceObject.useState)('');
[34581] Fix | Delete
const [autocompleter, setAutocompleter] = (0,external_wp_element_namespaceObject.useState)(null);
[34582] Fix | Delete
const [AutocompleterUI, setAutocompleterUI] = (0,external_wp_element_namespaceObject.useState)(null);
[34583] Fix | Delete
const backspacing = (0,external_wp_element_namespaceObject.useRef)(false);
[34584] Fix | Delete
function insertCompletion(replacement) {
[34585] Fix | Delete
if (autocompleter === null) {
[34586] Fix | Delete
return;
[34587] Fix | Delete
}
[34588] Fix | Delete
const end = record.start;
[34589] Fix | Delete
const start = end - autocompleter.triggerPrefix.length - filterValue.length;
[34590] Fix | Delete
const toInsert = (0,external_wp_richText_namespaceObject.create)({
[34591] Fix | Delete
html: (0,external_wp_element_namespaceObject.renderToString)(replacement)
[34592] Fix | Delete
});
[34593] Fix | Delete
onChange((0,external_wp_richText_namespaceObject.insert)(record, toInsert, start, end));
[34594] Fix | Delete
}
[34595] Fix | Delete
function select(option) {
[34596] Fix | Delete
const {
[34597] Fix | Delete
getOptionCompletion
[34598] Fix | Delete
} = autocompleter || {};
[34599] Fix | Delete
if (option.isDisabled) {
[34600] Fix | Delete
return;
[34601] Fix | Delete
}
[34602] Fix | Delete
if (getOptionCompletion) {
[34603] Fix | Delete
const completion = getOptionCompletion(option.value, filterValue);
[34604] Fix | Delete
const isCompletionObject = obj => {
[34605] Fix | Delete
return obj !== null && typeof obj === 'object' && 'action' in obj && obj.action !== undefined && 'value' in obj && obj.value !== undefined;
[34606] Fix | Delete
};
[34607] Fix | Delete
const completionObject = isCompletionObject(completion) ? completion : {
[34608] Fix | Delete
action: 'insert-at-caret',
[34609] Fix | Delete
value: completion
[34610] Fix | Delete
};
[34611] Fix | Delete
if ('replace' === completionObject.action) {
[34612] Fix | Delete
onReplace([completionObject.value]);
[34613] Fix | Delete
// When replacing, the component will unmount, so don't reset
[34614] Fix | Delete
// state (below) on an unmounted component.
[34615] Fix | Delete
return;
[34616] Fix | Delete
} else if ('insert-at-caret' === completionObject.action) {
[34617] Fix | Delete
insertCompletion(completionObject.value);
[34618] Fix | Delete
}
[34619] Fix | Delete
}
[34620] Fix | Delete
[34621] Fix | Delete
// Reset autocomplete state after insertion rather than before
[34622] Fix | Delete
// so insertion events don't cause the completion menu to redisplay.
[34623] Fix | Delete
reset();
[34624] Fix | Delete
}
[34625] Fix | Delete
function reset() {
[34626] Fix | Delete
setSelectedIndex(0);
[34627] Fix | Delete
setFilteredOptions(EMPTY_FILTERED_OPTIONS);
[34628] Fix | Delete
setFilterValue('');
[34629] Fix | Delete
setAutocompleter(null);
[34630] Fix | Delete
setAutocompleterUI(null);
[34631] Fix | Delete
}
[34632] Fix | Delete
[34633] Fix | Delete
/**
[34634] Fix | Delete
* Load options for an autocompleter.
[34635] Fix | Delete
*
[34636] Fix | Delete
* @param {Array} options
[34637] Fix | Delete
*/
[34638] Fix | Delete
function onChangeOptions(options) {
[34639] Fix | Delete
setSelectedIndex(options.length === filteredOptions.length ? selectedIndex : 0);
[34640] Fix | Delete
setFilteredOptions(options);
[34641] Fix | Delete
}
[34642] Fix | Delete
function handleKeyDown(event) {
[34643] Fix | Delete
backspacing.current = event.key === 'Backspace';
[34644] Fix | Delete
if (!autocompleter) {
[34645] Fix | Delete
return;
[34646] Fix | Delete
}
[34647] Fix | Delete
if (filteredOptions.length === 0) {
[34648] Fix | Delete
return;
[34649] Fix | Delete
}
[34650] Fix | Delete
if (event.defaultPrevented) {
[34651] Fix | Delete
return;
[34652] Fix | Delete
}
[34653] Fix | Delete
switch (event.key) {
[34654] Fix | Delete
case 'ArrowUp':
[34655] Fix | Delete
{
[34656] Fix | Delete
const newIndex = (selectedIndex === 0 ? filteredOptions.length : selectedIndex) - 1;
[34657] Fix | Delete
setSelectedIndex(newIndex);
[34658] Fix | Delete
// See the related PR as to why this is necessary: https://github.com/WordPress/gutenberg/pull/54902.
[34659] Fix | Delete
if ((0,external_wp_keycodes_namespaceObject.isAppleOS)()) {
[34660] Fix | Delete
(0,external_wp_a11y_namespaceObject.speak)(getNodeText(filteredOptions[newIndex].label), 'assertive');
[34661] Fix | Delete
}
[34662] Fix | Delete
break;
[34663] Fix | Delete
}
[34664] Fix | Delete
case 'ArrowDown':
[34665] Fix | Delete
{
[34666] Fix | Delete
const newIndex = (selectedIndex + 1) % filteredOptions.length;
[34667] Fix | Delete
setSelectedIndex(newIndex);
[34668] Fix | Delete
if ((0,external_wp_keycodes_namespaceObject.isAppleOS)()) {
[34669] Fix | Delete
(0,external_wp_a11y_namespaceObject.speak)(getNodeText(filteredOptions[newIndex].label), 'assertive');
[34670] Fix | Delete
}
[34671] Fix | Delete
break;
[34672] Fix | Delete
}
[34673] Fix | Delete
case 'Escape':
[34674] Fix | Delete
setAutocompleter(null);
[34675] Fix | Delete
setAutocompleterUI(null);
[34676] Fix | Delete
event.preventDefault();
[34677] Fix | Delete
break;
[34678] Fix | Delete
case 'Enter':
[34679] Fix | Delete
select(filteredOptions[selectedIndex]);
[34680] Fix | Delete
break;
[34681] Fix | Delete
case 'ArrowLeft':
[34682] Fix | Delete
case 'ArrowRight':
[34683] Fix | Delete
reset();
[34684] Fix | Delete
return;
[34685] Fix | Delete
default:
[34686] Fix | Delete
return;
[34687] Fix | Delete
}
[34688] Fix | Delete
[34689] Fix | Delete
// Any handled key should prevent original behavior. This relies on
[34690] Fix | Delete
// the early return in the default case.
[34691] Fix | Delete
event.preventDefault();
[34692] Fix | Delete
}
[34693] Fix | Delete
[34694] Fix | Delete
// textContent is a primitive (string), memoizing is not strictly necessary
[34695] Fix | Delete
// but this is a preemptive performance improvement, since the autocompleter
[34696] Fix | Delete
// is a potential bottleneck for the editor type metric.
[34697] Fix | Delete
const textContent = (0,external_wp_element_namespaceObject.useMemo)(() => {
[34698] Fix | Delete
if ((0,external_wp_richText_namespaceObject.isCollapsed)(record)) {
[34699] Fix | Delete
return (0,external_wp_richText_namespaceObject.getTextContent)((0,external_wp_richText_namespaceObject.slice)(record, 0));
[34700] Fix | Delete
}
[34701] Fix | Delete
return '';
[34702] Fix | Delete
}, [record]);
[34703] Fix | Delete
(0,external_wp_element_namespaceObject.useEffect)(() => {
[34704] Fix | Delete
if (!textContent) {
[34705] Fix | Delete
if (autocompleter) {
[34706] Fix | Delete
reset();
[34707] Fix | Delete
}
[34708] Fix | Delete
return;
[34709] Fix | Delete
}
[34710] Fix | Delete
[34711] Fix | Delete
// Find the completer with the highest triggerPrefix index in the
[34712] Fix | Delete
// textContent.
[34713] Fix | Delete
const completer = completers.reduce((lastTrigger, currentCompleter) => {
[34714] Fix | Delete
const triggerIndex = textContent.lastIndexOf(currentCompleter.triggerPrefix);
[34715] Fix | Delete
const lastTriggerIndex = lastTrigger !== null ? textContent.lastIndexOf(lastTrigger.triggerPrefix) : -1;
[34716] Fix | Delete
return triggerIndex > lastTriggerIndex ? currentCompleter : lastTrigger;
[34717] Fix | Delete
}, null);
[34718] Fix | Delete
if (!completer) {
[34719] Fix | Delete
if (autocompleter) {
[34720] Fix | Delete
reset();
[34721] Fix | Delete
}
[34722] Fix | Delete
return;
[34723] Fix | Delete
}
[34724] Fix | Delete
const {
[34725] Fix | Delete
allowContext,
[34726] Fix | Delete
triggerPrefix
[34727] Fix | Delete
} = completer;
[34728] Fix | Delete
const triggerIndex = textContent.lastIndexOf(triggerPrefix);
[34729] Fix | Delete
const textWithoutTrigger = textContent.slice(triggerIndex + triggerPrefix.length);
[34730] Fix | Delete
const tooDistantFromTrigger = textWithoutTrigger.length > 50; // 50 chars seems to be a good limit.
[34731] Fix | Delete
// This is a final barrier to prevent the effect from completing with
[34732] Fix | Delete
// an extremely long string, which causes the editor to slow-down
[34733] Fix | Delete
// significantly. This could happen, for example, if `matchingWhileBackspacing`
[34734] Fix | Delete
// is true and one of the "words" end up being too long. If that's the case,
[34735] Fix | Delete
// it will be caught by this guard.
[34736] Fix | Delete
if (tooDistantFromTrigger) {
[34737] Fix | Delete
return;
[34738] Fix | Delete
}
[34739] Fix | Delete
const mismatch = filteredOptions.length === 0;
[34740] Fix | Delete
const wordsFromTrigger = textWithoutTrigger.split(/\s/);
[34741] Fix | Delete
// We need to allow the effect to run when not backspacing and if there
[34742] Fix | Delete
// was a mismatch. i.e when typing a trigger + the match string or when
[34743] Fix | Delete
// clicking in an existing trigger word on the page. We do that if we
[34744] Fix | Delete
// detect that we have one word from trigger in the current textual context.
[34745] Fix | Delete
//
[34746] Fix | Delete
// Ex.: "Some text @a" <-- "@a" will be detected as the trigger word and
[34747] Fix | Delete
// allow the effect to run. It will run until there's a mismatch.
[34748] Fix | Delete
const hasOneTriggerWord = wordsFromTrigger.length === 1;
[34749] Fix | Delete
// This is used to allow the effect to run when backspacing and if
[34750] Fix | Delete
// "touching" a word that "belongs" to a trigger. We consider a "trigger
[34751] Fix | Delete
// word" any word up to the limit of 3 from the trigger character.
[34752] Fix | Delete
// Anything beyond that is ignored if there's a mismatch. This allows
[34753] Fix | Delete
// us to "escape" a mismatch when backspacing, but still imposing some
[34754] Fix | Delete
// sane limits.
[34755] Fix | Delete
//
[34756] Fix | Delete
// Ex: "Some text @marcelo sekkkk" <--- "kkkk" caused a mismatch, but
[34757] Fix | Delete
// if the user presses backspace here, it will show the completion popup again.
[34758] Fix | Delete
const matchingWhileBackspacing = backspacing.current && wordsFromTrigger.length <= 3;
[34759] Fix | Delete
if (mismatch && !(matchingWhileBackspacing || hasOneTriggerWord)) {
[34760] Fix | Delete
if (autocompleter) {
[34761] Fix | Delete
reset();
[34762] Fix | Delete
}
[34763] Fix | Delete
return;
[34764] Fix | Delete
}
[34765] Fix | Delete
const textAfterSelection = (0,external_wp_richText_namespaceObject.getTextContent)((0,external_wp_richText_namespaceObject.slice)(record, undefined, (0,external_wp_richText_namespaceObject.getTextContent)(record).length));
[34766] Fix | Delete
if (allowContext && !allowContext(textContent.slice(0, triggerIndex), textAfterSelection)) {
[34767] Fix | Delete
if (autocompleter) {
[34768] Fix | Delete
reset();
[34769] Fix | Delete
}
[34770] Fix | Delete
return;
[34771] Fix | Delete
}
[34772] Fix | Delete
if (/^\s/.test(textWithoutTrigger) || /\s\s+$/.test(textWithoutTrigger)) {
[34773] Fix | Delete
if (autocompleter) {
[34774] Fix | Delete
reset();
[34775] Fix | Delete
}
[34776] Fix | Delete
return;
[34777] Fix | Delete
}
[34778] Fix | Delete
if (!/[\u0000-\uFFFF]*$/.test(textWithoutTrigger)) {
[34779] Fix | Delete
if (autocompleter) {
[34780] Fix | Delete
reset();
[34781] Fix | Delete
}
[34782] Fix | Delete
return;
[34783] Fix | Delete
}
[34784] Fix | Delete
const safeTrigger = escapeRegExp(completer.triggerPrefix);
[34785] Fix | Delete
const text = remove_accents_default()(textContent);
[34786] Fix | Delete
const match = text.slice(text.lastIndexOf(completer.triggerPrefix)).match(new RegExp(`${safeTrigger}([\u0000-\uFFFF]*)$`));
[34787] Fix | Delete
const query = match && match[1];
[34788] Fix | Delete
setAutocompleter(completer);
[34789] Fix | Delete
setAutocompleterUI(() => completer !== autocompleter ? getAutoCompleterUI(completer) : AutocompleterUI);
[34790] Fix | Delete
setFilterValue(query === null ? '' : query);
[34791] Fix | Delete
// Temporarily disabling exhaustive-deps to avoid introducing unexpected side effecst.
[34792] Fix | Delete
// See https://github.com/WordPress/gutenberg/pull/41820
[34793] Fix | Delete
// eslint-disable-next-line react-hooks/exhaustive-deps
[34794] Fix | Delete
}, [textContent]);
[34795] Fix | Delete
const {
[34796] Fix | Delete
key: selectedKey = ''
[34797] Fix | Delete
} = filteredOptions[selectedIndex] || {};
[34798] Fix | Delete
const {
[34799] Fix | Delete
className
[34800] Fix | Delete
} = autocompleter || {};
[34801] Fix | Delete
const isExpanded = !!autocompleter && filteredOptions.length > 0;
[34802] Fix | Delete
const listBoxId = isExpanded ? `components-autocomplete-listbox-${instanceId}` : undefined;
[34803] Fix | Delete
const activeId = isExpanded ? `components-autocomplete-item-${instanceId}-${selectedKey}` : null;
[34804] Fix | Delete
const hasSelection = record.start !== undefined;
[34805] Fix | Delete
return {
[34806] Fix | Delete
listBoxId,
[34807] Fix | Delete
activeId,
[34808] Fix | Delete
onKeyDown: withIgnoreIMEEvents(handleKeyDown),
[34809] Fix | Delete
popover: hasSelection && AutocompleterUI && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(AutocompleterUI, {
[34810] Fix | Delete
className: className,
[34811] Fix | Delete
filterValue: filterValue,
[34812] Fix | Delete
instanceId: instanceId,
[34813] Fix | Delete
listBoxId: listBoxId,
[34814] Fix | Delete
selectedIndex: selectedIndex,
[34815] Fix | Delete
onChangeOptions: onChangeOptions,
[34816] Fix | Delete
onSelect: select,
[34817] Fix | Delete
value: record,
[34818] Fix | Delete
contentRef: contentRef,
[34819] Fix | Delete
reset: reset
[34820] Fix | Delete
})
[34821] Fix | Delete
};
[34822] Fix | Delete
}
[34823] Fix | Delete
function useLastDifferentValue(value) {
[34824] Fix | Delete
const history = (0,external_wp_element_namespaceObject.useRef)(new Set());
[34825] Fix | Delete
history.current.add(value);
[34826] Fix | Delete
[34827] Fix | Delete
// Keep the history size to 2.
[34828] Fix | Delete
if (history.current.size > 2) {
[34829] Fix | Delete
history.current.delete(Array.from(history.current)[0]);
[34830] Fix | Delete
}
[34831] Fix | Delete
return Array.from(history.current)[0];
[34832] Fix | Delete
}
[34833] Fix | Delete
function useAutocompleteProps(options) {
[34834] Fix | Delete
const ref = (0,external_wp_element_namespaceObject.useRef)(null);
[34835] Fix | Delete
const onKeyDownRef = (0,external_wp_element_namespaceObject.useRef)();
[34836] Fix | Delete
const {
[34837] Fix | Delete
record
[34838] Fix | Delete
} = options;
[34839] Fix | Delete
const previousRecord = useLastDifferentValue(record);
[34840] Fix | Delete
const {
[34841] Fix | Delete
popover,
[34842] Fix | Delete
listBoxId,
[34843] Fix | Delete
activeId,
[34844] Fix | Delete
onKeyDown
[34845] Fix | Delete
} = useAutocomplete({
[34846] Fix | Delete
...options,
[34847] Fix | Delete
contentRef: ref
[34848] Fix | Delete
});
[34849] Fix | Delete
onKeyDownRef.current = onKeyDown;
[34850] Fix | Delete
const mergedRefs = (0,external_wp_compose_namespaceObject.useMergeRefs)([ref, (0,external_wp_compose_namespaceObject.useRefEffect)(element => {
[34851] Fix | Delete
function _onKeyDown(event) {
[34852] Fix | Delete
onKeyDownRef.current?.(event);
[34853] Fix | Delete
}
[34854] Fix | Delete
element.addEventListener('keydown', _onKeyDown);
[34855] Fix | Delete
return () => {
[34856] Fix | Delete
element.removeEventListener('keydown', _onKeyDown);
[34857] Fix | Delete
};
[34858] Fix | Delete
}, [])]);
[34859] Fix | Delete
[34860] Fix | Delete
// We only want to show the popover if the user has typed something.
[34861] Fix | Delete
const didUserInput = record.text !== previousRecord?.text;
[34862] Fix | Delete
if (!didUserInput) {
[34863] Fix | Delete
return {
[34864] Fix | Delete
ref: mergedRefs
[34865] Fix | Delete
};
[34866] Fix | Delete
}
[34867] Fix | Delete
return {
[34868] Fix | Delete
ref: mergedRefs,
[34869] Fix | Delete
children: popover,
[34870] Fix | Delete
'aria-autocomplete': listBoxId ? 'list' : undefined,
[34871] Fix | Delete
'aria-owns': listBoxId,
[34872] Fix | Delete
'aria-activedescendant': activeId
[34873] Fix | Delete
};
[34874] Fix | Delete
}
[34875] Fix | Delete
function Autocomplete({
[34876] Fix | Delete
children,
[34877] Fix | Delete
isSelected,
[34878] Fix | Delete
...options
[34879] Fix | Delete
}) {
[34880] Fix | Delete
const {
[34881] Fix | Delete
popover,
[34882] Fix | Delete
...props
[34883] Fix | Delete
} = useAutocomplete(options);
[34884] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_ReactJSXRuntime_namespaceObject.Fragment, {
[34885] Fix | Delete
children: [children(props), isSelected && popover]
[34886] Fix | Delete
});
[34887] Fix | Delete
}
[34888] Fix | Delete
[34889] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/base-control/hooks.js
[34890] Fix | Delete
/**
[34891] Fix | Delete
* WordPress dependencies
[34892] Fix | Delete
*/
[34893] Fix | Delete
[34894] Fix | Delete
[34895] Fix | Delete
/**
[34896] Fix | Delete
* Internal dependencies
[34897] Fix | Delete
*/
[34898] Fix | Delete
[34899] Fix | Delete
/**
[34900] Fix | Delete
* Generate props for the `BaseControl` and the inner control itself.
[34901] Fix | Delete
*
[34902] Fix | Delete
* Namely, it takes care of generating a unique `id`, properly associating it with the `label` and `help` elements.
[34903] Fix | Delete
*
[34904] Fix | Delete
* @param props
[34905] Fix | Delete
*/
[34906] Fix | Delete
function useBaseControlProps(props) {
[34907] Fix | Delete
const {
[34908] Fix | Delete
help,
[34909] Fix | Delete
id: preferredId,
[34910] Fix | Delete
...restProps
[34911] Fix | Delete
} = props;
[34912] Fix | Delete
const uniqueId = (0,external_wp_compose_namespaceObject.useInstanceId)(base_control, 'wp-components-base-control', preferredId);
[34913] Fix | Delete
return {
[34914] Fix | Delete
baseControlProps: {
[34915] Fix | Delete
id: uniqueId,
[34916] Fix | Delete
help,
[34917] Fix | Delete
...restProps
[34918] Fix | Delete
},
[34919] Fix | Delete
controlProps: {
[34920] Fix | Delete
id: uniqueId,
[34921] Fix | Delete
...(!!help ? {
[34922] Fix | Delete
'aria-describedby': `${uniqueId}__help`
[34923] Fix | Delete
} : {})
[34924] Fix | Delete
}
[34925] Fix | Delete
};
[34926] Fix | Delete
}
[34927] Fix | Delete
[34928] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/link.js
[34929] Fix | Delete
/**
[34930] Fix | Delete
* WordPress dependencies
[34931] Fix | Delete
*/
[34932] Fix | Delete
[34933] Fix | Delete
[34934] Fix | Delete
const link_link = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.SVG, {
[34935] Fix | Delete
xmlns: "http://www.w3.org/2000/svg",
[34936] Fix | Delete
viewBox: "0 0 24 24",
[34937] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.Path, {
[34938] Fix | Delete
d: "M10 17.389H8.444A5.194 5.194 0 1 1 8.444 7H10v1.5H8.444a3.694 3.694 0 0 0 0 7.389H10v1.5ZM14 7h1.556a5.194 5.194 0 0 1 0 10.39H14v-1.5h1.556a3.694 3.694 0 0 0 0-7.39H14V7Zm-4.5 6h5v-1.5h-5V13Z"
[34939] Fix | Delete
})
[34940] Fix | Delete
});
[34941] Fix | Delete
/* harmony default export */ const library_link = (link_link);
[34942] Fix | Delete
[34943] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/icons/build-module/library/link-off.js
[34944] Fix | Delete
/**
[34945] Fix | Delete
* WordPress dependencies
[34946] Fix | Delete
*/
[34947] Fix | Delete
[34948] Fix | Delete
[34949] Fix | Delete
const linkOff = /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.SVG, {
[34950] Fix | Delete
xmlns: "http://www.w3.org/2000/svg",
[34951] Fix | Delete
viewBox: "0 0 24 24",
[34952] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_primitives_namespaceObject.Path, {
[34953] Fix | Delete
d: "M17.031 4.703 15.576 4l-1.56 3H14v.03l-2.324 4.47H9.5V13h1.396l-1.502 2.889h-.95a3.694 3.694 0 0 1 0-7.389H10V7H8.444a5.194 5.194 0 1 0 0 10.389h.17L7.5 19.53l1.416.719L15.049 8.5h.507a3.694 3.694 0 0 1 0 7.39H14v1.5h1.556a5.194 5.194 0 0 0 .273-10.383l1.202-2.304Z"
[34954] Fix | Delete
})
[34955] Fix | Delete
});
[34956] Fix | Delete
/* harmony default export */ const link_off = (linkOff);
[34957] Fix | Delete
[34958] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/components/build-module/border-box-control/styles.js
[34959] Fix | Delete
function border_box_control_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)."; }
[34960] Fix | Delete
/**
[34961] Fix | Delete
* External dependencies
[34962] Fix | Delete
*/
[34963] Fix | Delete
[34964] Fix | Delete
[34965] Fix | Delete
/**
[34966] Fix | Delete
* Internal dependencies
[34967] Fix | Delete
*/
[34968] Fix | Delete
[34969] Fix | Delete
const borderBoxControl = /*#__PURE__*/emotion_react_browser_esm_css( true ? "" : 0, true ? "" : 0);
[34970] Fix | Delete
const linkedBorderControl = () => /*#__PURE__*/emotion_react_browser_esm_css("flex:1;", rtl({
[34971] Fix | Delete
marginRight: '24px'
[34972] Fix | Delete
})(), ";" + ( true ? "" : 0), true ? "" : 0);
[34973] Fix | Delete
const wrapper = true ? {
[34974] Fix | Delete
name: "bjn8wh",
[34975] Fix | Delete
styles: "position:relative"
[34976] Fix | Delete
} : 0;
[34977] Fix | Delete
const borderBoxControlLinkedButton = size => {
[34978] Fix | Delete
return /*#__PURE__*/emotion_react_browser_esm_css("position:absolute;top:", size === '__unstable-large' ? '8px' : '3px', ";", rtl({
[34979] Fix | Delete
right: 0
[34980] Fix | Delete
})(), " line-height:0;" + ( true ? "" : 0), true ? "" : 0);
[34981] Fix | Delete
};
[34982] Fix | Delete
const borderBoxStyleWithFallback = border => {
[34983] Fix | Delete
const {
[34984] Fix | Delete
color = COLORS.gray[200],
[34985] Fix | Delete
style = 'solid',
[34986] Fix | Delete
width = config_values.borderWidth
[34987] Fix | Delete
} = border || {};
[34988] Fix | Delete
const clampedWidth = width !== config_values.borderWidth ? `clamp(1px, ${width}, 10px)` : width;
[34989] Fix | Delete
const hasVisibleBorder = !!width && width !== '0' || !!color;
[34990] Fix | Delete
const borderStyle = hasVisibleBorder ? style || 'solid' : style;
[34991] Fix | Delete
return `${color} ${borderStyle} ${clampedWidth}`;
[34992] Fix | Delete
};
[34993] Fix | Delete
const borderBoxControlVisualizer = (borders, size) => {
[34994] Fix | Delete
return /*#__PURE__*/emotion_react_browser_esm_css("position:absolute;top:", size === '__unstable-large' ? '20px' : '15px', ";right:", size === '__unstable-large' ? '39px' : '29px', ";bottom:", size === '__unstable-large' ? '20px' : '15px', ";left:", size === '__unstable-large' ? '39px' : '29px', ";border-top:", borderBoxStyleWithFallback(borders?.top), ";border-bottom:", borderBoxStyleWithFallback(borders?.bottom), ";", rtl({
[34995] Fix | Delete
borderLeft: borderBoxStyleWithFallback(borders?.left)
[34996] Fix | Delete
})(), " ", rtl({
[34997] Fix | Delete
borderRight: borderBoxStyleWithFallback(borders?.right)
[34998] Fix | Delete
})(), ";" + ( true ? "" : 0), true ? "" : 0);
[34999] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function