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: edit-widgets.js
__unstableExplicitMenuItem: __unstableExplicitMenuItem,
[1000] Fix | Delete
__unstableTarget: `${scope}/${target}`,
[1001] Fix | Delete
as: PluginsMenuItem,
[1002] Fix | Delete
name: `${scope}/plugin-more-menu`,
[1003] Fix | Delete
...toggleProps
[1004] Fix | Delete
});
[1005] Fix | Delete
},
[1006] Fix | Delete
role: "menuitemcheckbox",
[1007] Fix | Delete
selectedIcon: library_check,
[1008] Fix | Delete
name: target,
[1009] Fix | Delete
scope: scope,
[1010] Fix | Delete
...props
[1011] Fix | Delete
});
[1012] Fix | Delete
}
[1013] Fix | Delete
[1014] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/interface/build-module/components/pinned-items/index.js
[1015] Fix | Delete
/**
[1016] Fix | Delete
* External dependencies
[1017] Fix | Delete
*/
[1018] Fix | Delete
[1019] Fix | Delete
[1020] Fix | Delete
/**
[1021] Fix | Delete
* WordPress dependencies
[1022] Fix | Delete
*/
[1023] Fix | Delete
[1024] Fix | Delete
[1025] Fix | Delete
function PinnedItems({
[1026] Fix | Delete
scope,
[1027] Fix | Delete
...props
[1028] Fix | Delete
}) {
[1029] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Fill, {
[1030] Fix | Delete
name: `PinnedItems/${scope}`,
[1031] Fix | Delete
...props
[1032] Fix | Delete
});
[1033] Fix | Delete
}
[1034] Fix | Delete
function PinnedItemsSlot({
[1035] Fix | Delete
scope,
[1036] Fix | Delete
className,
[1037] Fix | Delete
...props
[1038] Fix | Delete
}) {
[1039] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Slot, {
[1040] Fix | Delete
name: `PinnedItems/${scope}`,
[1041] Fix | Delete
...props,
[1042] Fix | Delete
children: fills => fills?.length > 0 && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("div", {
[1043] Fix | Delete
className: dist_clsx(className, 'interface-pinned-items'),
[1044] Fix | Delete
children: fills
[1045] Fix | Delete
})
[1046] Fix | Delete
});
[1047] Fix | Delete
}
[1048] Fix | Delete
PinnedItems.Slot = PinnedItemsSlot;
[1049] Fix | Delete
/* harmony default export */ const pinned_items = (PinnedItems);
[1050] Fix | Delete
[1051] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/interface/build-module/components/complementary-area/index.js
[1052] Fix | Delete
/**
[1053] Fix | Delete
* External dependencies
[1054] Fix | Delete
*/
[1055] Fix | Delete
[1056] Fix | Delete
[1057] Fix | Delete
/**
[1058] Fix | Delete
* WordPress dependencies
[1059] Fix | Delete
*/
[1060] Fix | Delete
[1061] Fix | Delete
[1062] Fix | Delete
[1063] Fix | Delete
[1064] Fix | Delete
[1065] Fix | Delete
[1066] Fix | Delete
[1067] Fix | Delete
[1068] Fix | Delete
[1069] Fix | Delete
/**
[1070] Fix | Delete
* Internal dependencies
[1071] Fix | Delete
*/
[1072] Fix | Delete
[1073] Fix | Delete
[1074] Fix | Delete
[1075] Fix | Delete
[1076] Fix | Delete
[1077] Fix | Delete
[1078] Fix | Delete
[1079] Fix | Delete
[1080] Fix | Delete
[1081] Fix | Delete
const ANIMATION_DURATION = 0.3;
[1082] Fix | Delete
function ComplementaryAreaSlot({
[1083] Fix | Delete
scope,
[1084] Fix | Delete
...props
[1085] Fix | Delete
}) {
[1086] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Slot, {
[1087] Fix | Delete
name: `ComplementaryArea/${scope}`,
[1088] Fix | Delete
...props
[1089] Fix | Delete
});
[1090] Fix | Delete
}
[1091] Fix | Delete
const SIDEBAR_WIDTH = 280;
[1092] Fix | Delete
const variants = {
[1093] Fix | Delete
open: {
[1094] Fix | Delete
width: SIDEBAR_WIDTH
[1095] Fix | Delete
},
[1096] Fix | Delete
closed: {
[1097] Fix | Delete
width: 0
[1098] Fix | Delete
},
[1099] Fix | Delete
mobileOpen: {
[1100] Fix | Delete
width: '100vw'
[1101] Fix | Delete
}
[1102] Fix | Delete
};
[1103] Fix | Delete
function ComplementaryAreaFill({
[1104] Fix | Delete
activeArea,
[1105] Fix | Delete
isActive,
[1106] Fix | Delete
scope,
[1107] Fix | Delete
children,
[1108] Fix | Delete
className,
[1109] Fix | Delete
id
[1110] Fix | Delete
}) {
[1111] Fix | Delete
const disableMotion = (0,external_wp_compose_namespaceObject.useReducedMotion)();
[1112] Fix | Delete
const isMobileViewport = (0,external_wp_compose_namespaceObject.useViewportMatch)('medium', '<');
[1113] Fix | Delete
// This is used to delay the exit animation to the next tick.
[1114] Fix | Delete
// The reason this is done is to allow us to apply the right transition properties
[1115] Fix | Delete
// When we switch from an open sidebar to another open sidebar.
[1116] Fix | Delete
// we don't want to animate in this case.
[1117] Fix | Delete
const previousActiveArea = (0,external_wp_compose_namespaceObject.usePrevious)(activeArea);
[1118] Fix | Delete
const previousIsActive = (0,external_wp_compose_namespaceObject.usePrevious)(isActive);
[1119] Fix | Delete
const [, setState] = (0,external_wp_element_namespaceObject.useState)({});
[1120] Fix | Delete
(0,external_wp_element_namespaceObject.useEffect)(() => {
[1121] Fix | Delete
setState({});
[1122] Fix | Delete
}, [isActive]);
[1123] Fix | Delete
const transition = {
[1124] Fix | Delete
type: 'tween',
[1125] Fix | Delete
duration: disableMotion || isMobileViewport || !!previousActiveArea && !!activeArea && activeArea !== previousActiveArea ? 0 : ANIMATION_DURATION,
[1126] Fix | Delete
ease: [0.6, 0, 0.4, 1]
[1127] Fix | Delete
};
[1128] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Fill, {
[1129] Fix | Delete
name: `ComplementaryArea/${scope}`,
[1130] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.__unstableAnimatePresence, {
[1131] Fix | Delete
initial: false,
[1132] Fix | Delete
children: (previousIsActive || isActive) && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.__unstableMotion.div, {
[1133] Fix | Delete
variants: variants,
[1134] Fix | Delete
initial: "closed",
[1135] Fix | Delete
animate: isMobileViewport ? 'mobileOpen' : 'open',
[1136] Fix | Delete
exit: "closed",
[1137] Fix | Delete
transition: transition,
[1138] Fix | Delete
className: "interface-complementary-area__fill",
[1139] Fix | Delete
children: /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("div", {
[1140] Fix | Delete
id: id,
[1141] Fix | Delete
className: className,
[1142] Fix | Delete
style: {
[1143] Fix | Delete
width: isMobileViewport ? '100vw' : SIDEBAR_WIDTH
[1144] Fix | Delete
},
[1145] Fix | Delete
children: children
[1146] Fix | Delete
})
[1147] Fix | Delete
})
[1148] Fix | Delete
})
[1149] Fix | Delete
});
[1150] Fix | Delete
}
[1151] Fix | Delete
function useAdjustComplementaryListener(scope, identifier, activeArea, isActive, isSmall) {
[1152] Fix | Delete
const previousIsSmall = (0,external_wp_element_namespaceObject.useRef)(false);
[1153] Fix | Delete
const shouldOpenWhenNotSmall = (0,external_wp_element_namespaceObject.useRef)(false);
[1154] Fix | Delete
const {
[1155] Fix | Delete
enableComplementaryArea,
[1156] Fix | Delete
disableComplementaryArea
[1157] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[1158] Fix | Delete
(0,external_wp_element_namespaceObject.useEffect)(() => {
[1159] Fix | Delete
// If the complementary area is active and the editor is switching from
[1160] Fix | Delete
// a big to a small window size.
[1161] Fix | Delete
if (isActive && isSmall && !previousIsSmall.current) {
[1162] Fix | Delete
disableComplementaryArea(scope);
[1163] Fix | Delete
// Flag the complementary area to be reopened when the window size
[1164] Fix | Delete
// goes from small to big.
[1165] Fix | Delete
shouldOpenWhenNotSmall.current = true;
[1166] Fix | Delete
} else if (
[1167] Fix | Delete
// If there is a flag indicating the complementary area should be
[1168] Fix | Delete
// enabled when we go from small to big window size and we are going
[1169] Fix | Delete
// from a small to big window size.
[1170] Fix | Delete
shouldOpenWhenNotSmall.current && !isSmall && previousIsSmall.current) {
[1171] Fix | Delete
// Remove the flag indicating the complementary area should be
[1172] Fix | Delete
// enabled.
[1173] Fix | Delete
shouldOpenWhenNotSmall.current = false;
[1174] Fix | Delete
enableComplementaryArea(scope, identifier);
[1175] Fix | Delete
} else if (
[1176] Fix | Delete
// If the flag is indicating the current complementary should be
[1177] Fix | Delete
// reopened but another complementary area becomes active, remove
[1178] Fix | Delete
// the flag.
[1179] Fix | Delete
shouldOpenWhenNotSmall.current && activeArea && activeArea !== identifier) {
[1180] Fix | Delete
shouldOpenWhenNotSmall.current = false;
[1181] Fix | Delete
}
[1182] Fix | Delete
if (isSmall !== previousIsSmall.current) {
[1183] Fix | Delete
previousIsSmall.current = isSmall;
[1184] Fix | Delete
}
[1185] Fix | Delete
}, [isActive, isSmall, scope, identifier, activeArea, disableComplementaryArea, enableComplementaryArea]);
[1186] Fix | Delete
}
[1187] Fix | Delete
function ComplementaryArea({
[1188] Fix | Delete
children,
[1189] Fix | Delete
className,
[1190] Fix | Delete
closeLabel = (0,external_wp_i18n_namespaceObject.__)('Close plugin'),
[1191] Fix | Delete
identifier,
[1192] Fix | Delete
header,
[1193] Fix | Delete
headerClassName,
[1194] Fix | Delete
icon,
[1195] Fix | Delete
isPinnable = true,
[1196] Fix | Delete
panelClassName,
[1197] Fix | Delete
scope,
[1198] Fix | Delete
name,
[1199] Fix | Delete
smallScreenTitle,
[1200] Fix | Delete
title,
[1201] Fix | Delete
toggleShortcut,
[1202] Fix | Delete
isActiveByDefault
[1203] Fix | Delete
}) {
[1204] Fix | Delete
// This state is used to delay the rendering of the Fill
[1205] Fix | Delete
// until the initial effect runs.
[1206] Fix | Delete
// This prevents the animation from running on mount if
[1207] Fix | Delete
// the complementary area is active by default.
[1208] Fix | Delete
const [isReady, setIsReady] = (0,external_wp_element_namespaceObject.useState)(false);
[1209] Fix | Delete
const {
[1210] Fix | Delete
isLoading,
[1211] Fix | Delete
isActive,
[1212] Fix | Delete
isPinned,
[1213] Fix | Delete
activeArea,
[1214] Fix | Delete
isSmall,
[1215] Fix | Delete
isLarge,
[1216] Fix | Delete
showIconLabels
[1217] Fix | Delete
} = (0,external_wp_data_namespaceObject.useSelect)(select => {
[1218] Fix | Delete
const {
[1219] Fix | Delete
getActiveComplementaryArea,
[1220] Fix | Delete
isComplementaryAreaLoading,
[1221] Fix | Delete
isItemPinned
[1222] Fix | Delete
} = select(store);
[1223] Fix | Delete
const {
[1224] Fix | Delete
get
[1225] Fix | Delete
} = select(external_wp_preferences_namespaceObject.store);
[1226] Fix | Delete
const _activeArea = getActiveComplementaryArea(scope);
[1227] Fix | Delete
return {
[1228] Fix | Delete
isLoading: isComplementaryAreaLoading(scope),
[1229] Fix | Delete
isActive: _activeArea === identifier,
[1230] Fix | Delete
isPinned: isItemPinned(scope, identifier),
[1231] Fix | Delete
activeArea: _activeArea,
[1232] Fix | Delete
isSmall: select(external_wp_viewport_namespaceObject.store).isViewportMatch('< medium'),
[1233] Fix | Delete
isLarge: select(external_wp_viewport_namespaceObject.store).isViewportMatch('large'),
[1234] Fix | Delete
showIconLabels: get('core', 'showIconLabels')
[1235] Fix | Delete
};
[1236] Fix | Delete
}, [identifier, scope]);
[1237] Fix | Delete
useAdjustComplementaryListener(scope, identifier, activeArea, isActive, isSmall);
[1238] Fix | Delete
const {
[1239] Fix | Delete
enableComplementaryArea,
[1240] Fix | Delete
disableComplementaryArea,
[1241] Fix | Delete
pinItem,
[1242] Fix | Delete
unpinItem
[1243] Fix | Delete
} = (0,external_wp_data_namespaceObject.useDispatch)(store);
[1244] Fix | Delete
(0,external_wp_element_namespaceObject.useEffect)(() => {
[1245] Fix | Delete
// Set initial visibility: For large screens, enable if it's active by
[1246] Fix | Delete
// default. For small screens, always initially disable.
[1247] Fix | Delete
if (isActiveByDefault && activeArea === undefined && !isSmall) {
[1248] Fix | Delete
enableComplementaryArea(scope, identifier);
[1249] Fix | Delete
} else if (activeArea === undefined && isSmall) {
[1250] Fix | Delete
disableComplementaryArea(scope, identifier);
[1251] Fix | Delete
}
[1252] Fix | Delete
setIsReady(true);
[1253] Fix | Delete
}, [activeArea, isActiveByDefault, scope, identifier, isSmall, enableComplementaryArea, disableComplementaryArea]);
[1254] Fix | Delete
if (!isReady) {
[1255] Fix | Delete
return;
[1256] Fix | Delete
}
[1257] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_ReactJSXRuntime_namespaceObject.Fragment, {
[1258] Fix | Delete
children: [isPinnable && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(pinned_items, {
[1259] Fix | Delete
scope: scope,
[1260] Fix | Delete
children: isPinned && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(complementary_area_toggle, {
[1261] Fix | Delete
scope: scope,
[1262] Fix | Delete
identifier: identifier,
[1263] Fix | Delete
isPressed: isActive && (!showIconLabels || isLarge),
[1264] Fix | Delete
"aria-expanded": isActive,
[1265] Fix | Delete
"aria-disabled": isLoading,
[1266] Fix | Delete
label: title,
[1267] Fix | Delete
icon: showIconLabels ? library_check : icon,
[1268] Fix | Delete
showTooltip: !showIconLabels,
[1269] Fix | Delete
variant: showIconLabels ? 'tertiary' : undefined,
[1270] Fix | Delete
size: "compact"
[1271] Fix | Delete
})
[1272] Fix | Delete
}), name && isPinnable && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(ComplementaryAreaMoreMenuItem, {
[1273] Fix | Delete
target: name,
[1274] Fix | Delete
scope: scope,
[1275] Fix | Delete
icon: icon,
[1276] Fix | Delete
children: title
[1277] Fix | Delete
}), /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(ComplementaryAreaFill, {
[1278] Fix | Delete
activeArea: activeArea,
[1279] Fix | Delete
isActive: isActive,
[1280] Fix | Delete
className: dist_clsx('interface-complementary-area', className),
[1281] Fix | Delete
scope: scope,
[1282] Fix | Delete
id: identifier.replace('/', ':'),
[1283] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(complementary_area_header, {
[1284] Fix | Delete
className: headerClassName,
[1285] Fix | Delete
closeLabel: closeLabel,
[1286] Fix | Delete
onClose: () => disableComplementaryArea(scope),
[1287] Fix | Delete
smallScreenTitle: smallScreenTitle,
[1288] Fix | Delete
toggleButtonProps: {
[1289] Fix | Delete
label: closeLabel,
[1290] Fix | Delete
size: 'small',
[1291] Fix | Delete
shortcut: toggleShortcut,
[1292] Fix | Delete
scope,
[1293] Fix | Delete
identifier
[1294] Fix | Delete
},
[1295] Fix | Delete
children: header || /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)(external_ReactJSXRuntime_namespaceObject.Fragment, {
[1296] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("h2", {
[1297] Fix | Delete
className: "interface-complementary-area-header__title",
[1298] Fix | Delete
children: title
[1299] Fix | Delete
}), isPinnable && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Button, {
[1300] Fix | Delete
className: "interface-complementary-area__pin-unpin-item",
[1301] Fix | Delete
icon: isPinned ? star_filled : star_empty,
[1302] Fix | Delete
label: isPinned ? (0,external_wp_i18n_namespaceObject.__)('Unpin from toolbar') : (0,external_wp_i18n_namespaceObject.__)('Pin to toolbar'),
[1303] Fix | Delete
onClick: () => (isPinned ? unpinItem : pinItem)(scope, identifier),
[1304] Fix | Delete
isPressed: isPinned,
[1305] Fix | Delete
"aria-expanded": isPinned,
[1306] Fix | Delete
size: "compact"
[1307] Fix | Delete
})]
[1308] Fix | Delete
})
[1309] Fix | Delete
}), /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.Panel, {
[1310] Fix | Delete
className: panelClassName,
[1311] Fix | Delete
children: children
[1312] Fix | Delete
})]
[1313] Fix | Delete
})]
[1314] Fix | Delete
});
[1315] Fix | Delete
}
[1316] Fix | Delete
const ComplementaryAreaWrapped = complementary_area_context(ComplementaryArea);
[1317] Fix | Delete
ComplementaryAreaWrapped.Slot = ComplementaryAreaSlot;
[1318] Fix | Delete
/* harmony default export */ const complementary_area = (ComplementaryAreaWrapped);
[1319] Fix | Delete
[1320] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/interface/build-module/components/navigable-region/index.js
[1321] Fix | Delete
/**
[1322] Fix | Delete
* External dependencies
[1323] Fix | Delete
*/
[1324] Fix | Delete
[1325] Fix | Delete
[1326] Fix | Delete
function NavigableRegion({
[1327] Fix | Delete
children,
[1328] Fix | Delete
className,
[1329] Fix | Delete
ariaLabel,
[1330] Fix | Delete
as: Tag = 'div',
[1331] Fix | Delete
...props
[1332] Fix | Delete
}) {
[1333] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(Tag, {
[1334] Fix | Delete
className: dist_clsx('interface-navigable-region', className),
[1335] Fix | Delete
"aria-label": ariaLabel,
[1336] Fix | Delete
role: "region",
[1337] Fix | Delete
tabIndex: "-1",
[1338] Fix | Delete
...props,
[1339] Fix | Delete
children: children
[1340] Fix | Delete
});
[1341] Fix | Delete
}
[1342] Fix | Delete
[1343] Fix | Delete
;// CONCATENATED MODULE: ./node_modules/@wordpress/interface/build-module/components/interface-skeleton/index.js
[1344] Fix | Delete
/**
[1345] Fix | Delete
* External dependencies
[1346] Fix | Delete
*/
[1347] Fix | Delete
[1348] Fix | Delete
[1349] Fix | Delete
/**
[1350] Fix | Delete
* WordPress dependencies
[1351] Fix | Delete
*/
[1352] Fix | Delete
[1353] Fix | Delete
[1354] Fix | Delete
[1355] Fix | Delete
[1356] Fix | Delete
[1357] Fix | Delete
/**
[1358] Fix | Delete
* Internal dependencies
[1359] Fix | Delete
*/
[1360] Fix | Delete
[1361] Fix | Delete
[1362] Fix | Delete
[1363] Fix | Delete
const interface_skeleton_ANIMATION_DURATION = 0.25;
[1364] Fix | Delete
const commonTransition = {
[1365] Fix | Delete
type: 'tween',
[1366] Fix | Delete
duration: interface_skeleton_ANIMATION_DURATION,
[1367] Fix | Delete
ease: [0.6, 0, 0.4, 1]
[1368] Fix | Delete
};
[1369] Fix | Delete
function useHTMLClass(className) {
[1370] Fix | Delete
(0,external_wp_element_namespaceObject.useEffect)(() => {
[1371] Fix | Delete
const element = document && document.querySelector(`html:not(.${className})`);
[1372] Fix | Delete
if (!element) {
[1373] Fix | Delete
return;
[1374] Fix | Delete
}
[1375] Fix | Delete
element.classList.toggle(className);
[1376] Fix | Delete
return () => {
[1377] Fix | Delete
element.classList.toggle(className);
[1378] Fix | Delete
};
[1379] Fix | Delete
}, [className]);
[1380] Fix | Delete
}
[1381] Fix | Delete
const headerVariants = {
[1382] Fix | Delete
hidden: {
[1383] Fix | Delete
opacity: 1,
[1384] Fix | Delete
marginTop: -60
[1385] Fix | Delete
},
[1386] Fix | Delete
visible: {
[1387] Fix | Delete
opacity: 1,
[1388] Fix | Delete
marginTop: 0
[1389] Fix | Delete
},
[1390] Fix | Delete
distractionFreeHover: {
[1391] Fix | Delete
opacity: 1,
[1392] Fix | Delete
marginTop: 0,
[1393] Fix | Delete
transition: {
[1394] Fix | Delete
...commonTransition,
[1395] Fix | Delete
delay: 0.2,
[1396] Fix | Delete
delayChildren: 0.2
[1397] Fix | Delete
}
[1398] Fix | Delete
},
[1399] Fix | Delete
distractionFreeHidden: {
[1400] Fix | Delete
opacity: 0,
[1401] Fix | Delete
marginTop: -60
[1402] Fix | Delete
},
[1403] Fix | Delete
distractionFreeDisabled: {
[1404] Fix | Delete
opacity: 0,
[1405] Fix | Delete
marginTop: 0,
[1406] Fix | Delete
transition: {
[1407] Fix | Delete
...commonTransition,
[1408] Fix | Delete
delay: 0.8,
[1409] Fix | Delete
delayChildren: 0.8
[1410] Fix | Delete
}
[1411] Fix | Delete
}
[1412] Fix | Delete
};
[1413] Fix | Delete
function InterfaceSkeleton({
[1414] Fix | Delete
isDistractionFree,
[1415] Fix | Delete
footer,
[1416] Fix | Delete
header,
[1417] Fix | Delete
editorNotices,
[1418] Fix | Delete
sidebar,
[1419] Fix | Delete
secondarySidebar,
[1420] Fix | Delete
content,
[1421] Fix | Delete
actions,
[1422] Fix | Delete
labels,
[1423] Fix | Delete
className,
[1424] Fix | Delete
enableRegionNavigation = true,
[1425] Fix | Delete
// Todo: does this need to be a prop.
[1426] Fix | Delete
// Can we use a dependency to keyboard-shortcuts directly?
[1427] Fix | Delete
shortcuts
[1428] Fix | Delete
}, ref) {
[1429] Fix | Delete
const [secondarySidebarResizeListener, secondarySidebarSize] = (0,external_wp_compose_namespaceObject.useResizeObserver)();
[1430] Fix | Delete
const isMobileViewport = (0,external_wp_compose_namespaceObject.useViewportMatch)('medium', '<');
[1431] Fix | Delete
const disableMotion = (0,external_wp_compose_namespaceObject.useReducedMotion)();
[1432] Fix | Delete
const defaultTransition = {
[1433] Fix | Delete
type: 'tween',
[1434] Fix | Delete
duration: disableMotion ? 0 : interface_skeleton_ANIMATION_DURATION,
[1435] Fix | Delete
ease: [0.6, 0, 0.4, 1]
[1436] Fix | Delete
};
[1437] Fix | Delete
const navigateRegionsProps = (0,external_wp_components_namespaceObject.__unstableUseNavigateRegions)(shortcuts);
[1438] Fix | Delete
useHTMLClass('interface-interface-skeleton__html-container');
[1439] Fix | Delete
const defaultLabels = {
[1440] Fix | Delete
/* translators: accessibility text for the top bar landmark region. */
[1441] Fix | Delete
header: (0,external_wp_i18n_namespaceObject._x)('Header', 'header landmark area'),
[1442] Fix | Delete
/* translators: accessibility text for the content landmark region. */
[1443] Fix | Delete
body: (0,external_wp_i18n_namespaceObject.__)('Content'),
[1444] Fix | Delete
/* translators: accessibility text for the secondary sidebar landmark region. */
[1445] Fix | Delete
secondarySidebar: (0,external_wp_i18n_namespaceObject.__)('Block Library'),
[1446] Fix | Delete
/* translators: accessibility text for the settings landmark region. */
[1447] Fix | Delete
sidebar: (0,external_wp_i18n_namespaceObject.__)('Settings'),
[1448] Fix | Delete
/* translators: accessibility text for the publish landmark region. */
[1449] Fix | Delete
actions: (0,external_wp_i18n_namespaceObject.__)('Publish'),
[1450] Fix | Delete
/* translators: accessibility text for the footer landmark region. */
[1451] Fix | Delete
footer: (0,external_wp_i18n_namespaceObject.__)('Footer')
[1452] Fix | Delete
};
[1453] Fix | Delete
const mergedLabels = {
[1454] Fix | Delete
...defaultLabels,
[1455] Fix | Delete
...labels
[1456] Fix | Delete
};
[1457] Fix | Delete
return /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)("div", {
[1458] Fix | Delete
...(enableRegionNavigation ? navigateRegionsProps : {}),
[1459] Fix | Delete
ref: (0,external_wp_compose_namespaceObject.useMergeRefs)([ref, enableRegionNavigation ? navigateRegionsProps.ref : undefined]),
[1460] Fix | Delete
className: dist_clsx(className, 'interface-interface-skeleton', navigateRegionsProps.className, !!footer && 'has-footer'),
[1461] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)("div", {
[1462] Fix | Delete
className: "interface-interface-skeleton__editor",
[1463] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.__unstableAnimatePresence, {
[1464] Fix | Delete
initial: false,
[1465] Fix | Delete
children: !!header && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(NavigableRegion, {
[1466] Fix | Delete
as: external_wp_components_namespaceObject.__unstableMotion.div,
[1467] Fix | Delete
className: "interface-interface-skeleton__header",
[1468] Fix | Delete
"aria-label": mergedLabels.header,
[1469] Fix | Delete
initial: isDistractionFree ? 'distractionFreeHidden' : 'hidden',
[1470] Fix | Delete
whileHover: isDistractionFree ? 'distractionFreeHover' : 'visible',
[1471] Fix | Delete
animate: isDistractionFree ? 'distractionFreeDisabled' : 'visible',
[1472] Fix | Delete
exit: isDistractionFree ? 'distractionFreeHidden' : 'hidden',
[1473] Fix | Delete
variants: headerVariants,
[1474] Fix | Delete
transition: defaultTransition,
[1475] Fix | Delete
children: header
[1476] Fix | Delete
})
[1477] Fix | Delete
}), isDistractionFree && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)("div", {
[1478] Fix | Delete
className: "interface-interface-skeleton__header",
[1479] Fix | Delete
children: editorNotices
[1480] Fix | Delete
}), /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsxs)("div", {
[1481] Fix | Delete
className: "interface-interface-skeleton__body",
[1482] Fix | Delete
children: [/*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(external_wp_components_namespaceObject.__unstableAnimatePresence, {
[1483] Fix | Delete
initial: false,
[1484] Fix | Delete
children: !!secondarySidebar && /*#__PURE__*/(0,external_ReactJSXRuntime_namespaceObject.jsx)(NavigableRegion, {
[1485] Fix | Delete
className: "interface-interface-skeleton__secondary-sidebar",
[1486] Fix | Delete
ariaLabel: mergedLabels.secondarySidebar,
[1487] Fix | Delete
as: external_wp_components_namespaceObject.__unstableMotion.div,
[1488] Fix | Delete
initial: "closed",
[1489] Fix | Delete
animate: isMobileViewport ? 'mobileOpen' : 'open',
[1490] Fix | Delete
exit: "closed",
[1491] Fix | Delete
variants: {
[1492] Fix | Delete
open: {
[1493] Fix | Delete
width: secondarySidebarSize.width
[1494] Fix | Delete
},
[1495] Fix | Delete
closed: {
[1496] Fix | Delete
width: 0
[1497] Fix | Delete
},
[1498] Fix | Delete
mobileOpen: {
[1499] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function