@elementor/editor-editing-panel 1.18.0 → 1.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/dist/index.js +639 -533
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +490 -384
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
- package/src/components/control-label-with-adornments.tsx +13 -0
- package/src/components/section.tsx +6 -2
- package/src/components/style-sections/layout-section/display-field.tsx +1 -1
- package/src/components/style-sections/layout-section/justify-content-field.tsx +1 -1
- package/src/components/style-sections/position-section/dimensions-field.tsx +1 -1
- package/src/components/style-sections/size-section/size-section.tsx +1 -1
- package/src/contexts/styles-inheritance-context.tsx +18 -3
- package/src/controls-registry/styles-field.tsx +14 -4
- package/src/dynamics/components/dynamic-selection-control.tsx +1 -1
- package/src/hooks/use-styles-fields.ts +3 -4
- package/src/hooks/use-styles-rerender.ts +10 -0
- package/src/styles-inheritance/styles-inheritance-indicator.tsx +70 -0
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// src/index.ts
|
|
2
|
-
import { useBoundProp as
|
|
2
|
+
import { useBoundProp as useBoundProp7 } from "@elementor/editor-controls";
|
|
3
3
|
|
|
4
4
|
// src/control-replacement.tsx
|
|
5
5
|
import { createControlReplacement } from "@elementor/editor-controls";
|
|
@@ -641,14 +641,14 @@ function useHandleApply(appliedIds, setAppliedIds) {
|
|
|
641
641
|
import { __createPanel as createPanel } from "@elementor/editor-panels";
|
|
642
642
|
|
|
643
643
|
// src/components/editing-panel.tsx
|
|
644
|
-
import * as
|
|
644
|
+
import * as React65 from "react";
|
|
645
645
|
import { ControlActionsProvider, ControlReplacementProvider } from "@elementor/editor-controls";
|
|
646
646
|
import { useSelectedElement } from "@elementor/editor-elements";
|
|
647
647
|
import { Panel, PanelBody, PanelHeader, PanelHeaderTitle } from "@elementor/editor-panels";
|
|
648
648
|
import { AtomIcon } from "@elementor/icons";
|
|
649
649
|
import { SessionStorageProvider as SessionStorageProvider3 } from "@elementor/session";
|
|
650
650
|
import { ErrorBoundary } from "@elementor/ui";
|
|
651
|
-
import { __ as
|
|
651
|
+
import { __ as __44 } from "@wordpress/i18n";
|
|
652
652
|
|
|
653
653
|
// src/controls-actions.ts
|
|
654
654
|
import { createMenu } from "@elementor/menus";
|
|
@@ -704,10 +704,10 @@ function EditorPanelErrorFallback() {
|
|
|
704
704
|
}
|
|
705
705
|
|
|
706
706
|
// src/components/editing-panel-tabs.tsx
|
|
707
|
-
import * as
|
|
707
|
+
import * as React64 from "react";
|
|
708
708
|
import { Fragment as Fragment8 } from "react";
|
|
709
709
|
import { Divider as Divider5, Stack as Stack13, Tab, TabPanel, Tabs, useTabs } from "@elementor/ui";
|
|
710
|
-
import { __ as
|
|
710
|
+
import { __ as __43 } from "@wordpress/i18n";
|
|
711
711
|
|
|
712
712
|
// src/components/settings-tab.tsx
|
|
713
713
|
import * as React15 from "react";
|
|
@@ -839,10 +839,17 @@ function Section({ title, children, defaultExpanded = false }) {
|
|
|
839
839
|
{
|
|
840
840
|
id: labelId,
|
|
841
841
|
"aria-controls": contentId,
|
|
842
|
-
onClick: () => setIsOpen((prev) => !prev)
|
|
842
|
+
onClick: () => setIsOpen((prev) => !prev),
|
|
843
|
+
sx: { "&:hover": { backgroundColor: "transparent" } }
|
|
843
844
|
},
|
|
844
|
-
/* @__PURE__ */ React13.createElement(
|
|
845
|
-
|
|
845
|
+
/* @__PURE__ */ React13.createElement(
|
|
846
|
+
ListItemText,
|
|
847
|
+
{
|
|
848
|
+
secondary: title,
|
|
849
|
+
secondaryTypographyProps: { sx: { typography: "caption", fontWeight: "bold" } }
|
|
850
|
+
}
|
|
851
|
+
),
|
|
852
|
+
/* @__PURE__ */ React13.createElement(CollapseIcon, { open: isOpen, color: "secondary", fontSize: "tiny" })
|
|
846
853
|
), /* @__PURE__ */ React13.createElement(Collapse, { id: contentId, "aria-labelledby": labelId, in: isOpen, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React13.createElement(Stack4, { gap: 2.5, p: 2 }, children)), /* @__PURE__ */ React13.createElement(Divider2, null));
|
|
847
854
|
}
|
|
848
855
|
|
|
@@ -879,23 +886,31 @@ var Control2 = ({ control }) => {
|
|
|
879
886
|
};
|
|
880
887
|
|
|
881
888
|
// src/components/style-tab.tsx
|
|
882
|
-
import * as
|
|
889
|
+
import * as React63 from "react";
|
|
883
890
|
import { useState as useState7 } from "react";
|
|
884
891
|
import { getElementStyles, useElementSetting as useElementSetting5 } from "@elementor/editor-elements";
|
|
885
892
|
import { CLASSES_PROP_KEY } from "@elementor/editor-props";
|
|
886
893
|
import { useActiveBreakpoint } from "@elementor/editor-responsive";
|
|
887
894
|
import { SessionStorageProvider as SessionStorageProvider2 } from "@elementor/session";
|
|
888
895
|
import { Divider as Divider4 } from "@elementor/ui";
|
|
889
|
-
import { __ as
|
|
896
|
+
import { __ as __42 } from "@wordpress/i18n";
|
|
890
897
|
|
|
891
898
|
// src/contexts/styles-inheritance-context.tsx
|
|
892
899
|
import * as React16 from "react";
|
|
893
900
|
import { createContext as createContext4, useContext as useContext4 } from "react";
|
|
894
|
-
import { useElementSetting as useElementSetting4 } from "@elementor/editor-elements";
|
|
901
|
+
import { getWidgetsCache, useElementSetting as useElementSetting4 } from "@elementor/editor-elements";
|
|
895
902
|
import { classesPropTypeUtil as classesPropTypeUtil2 } from "@elementor/editor-props";
|
|
896
903
|
import { getBreakpointsTree } from "@elementor/editor-responsive";
|
|
897
904
|
import { stylesRepository as stylesRepository5 } from "@elementor/editor-styles-repository";
|
|
898
905
|
|
|
906
|
+
// src/hooks/use-styles-rerender.ts
|
|
907
|
+
import { useEffect, useReducer } from "react";
|
|
908
|
+
var useStylesRerender = () => {
|
|
909
|
+
const { provider } = useStyle();
|
|
910
|
+
const [, reRender] = useReducer((p) => !p, false);
|
|
911
|
+
useEffect(() => provider?.subscribe(reRender), [provider]);
|
|
912
|
+
};
|
|
913
|
+
|
|
899
914
|
// src/styles-inheritance/utils.ts
|
|
900
915
|
var DEFAULT_STATE = "normal";
|
|
901
916
|
var DEFAULT_BREAKPOINT = "desktop";
|
|
@@ -1052,26 +1067,51 @@ function StyleInheritanceProvider({ children }) {
|
|
|
1052
1067
|
const getSnapshot = createStylesInheritance(styleDefs, breakpointsTree);
|
|
1053
1068
|
return /* @__PURE__ */ React16.createElement(Context4.Provider, { value: { getSnapshot } }, children);
|
|
1054
1069
|
}
|
|
1070
|
+
function useStylesInheritanceFields(fields) {
|
|
1071
|
+
const context = useContext4(Context4);
|
|
1072
|
+
const { meta } = useStyle();
|
|
1073
|
+
if (!context) {
|
|
1074
|
+
throw new Error("useStylesInheritanceFields must be used within a StyleInheritanceProvider");
|
|
1075
|
+
}
|
|
1076
|
+
if (!meta) {
|
|
1077
|
+
return null;
|
|
1078
|
+
}
|
|
1079
|
+
const snapshot = context.getSnapshot(meta);
|
|
1080
|
+
return fields.reduce(
|
|
1081
|
+
(acc, key) => ({ ...acc, [key]: snapshot?.[key] ?? [] }),
|
|
1082
|
+
{}
|
|
1083
|
+
);
|
|
1084
|
+
}
|
|
1085
|
+
function useStylesInheritanceField(field) {
|
|
1086
|
+
return useStylesInheritanceFields([field])?.[field] ?? [];
|
|
1087
|
+
}
|
|
1055
1088
|
var useAppliedStyles = () => {
|
|
1056
1089
|
const { element } = useElement();
|
|
1057
1090
|
const currentClassesProp = useClassesProp();
|
|
1091
|
+
const baseStyles = useBaseStyles();
|
|
1092
|
+
useStylesRerender();
|
|
1058
1093
|
const classesProp = useElementSetting4(element.id, currentClassesProp);
|
|
1059
1094
|
const appliedStyles = classesPropTypeUtil2.extract(classesProp);
|
|
1060
|
-
|
|
1061
|
-
|
|
1095
|
+
return stylesRepository5.all().filter((style) => appliedStyles?.includes(style.id)).concat(baseStyles);
|
|
1096
|
+
};
|
|
1097
|
+
var useBaseStyles = () => {
|
|
1098
|
+
const { elementType } = useElement();
|
|
1099
|
+
const widgetsCache = getWidgetsCache();
|
|
1100
|
+
const widgetCache = widgetsCache?.[elementType.key];
|
|
1101
|
+
return Object.values(widgetCache?.base_styles ?? {});
|
|
1062
1102
|
};
|
|
1063
1103
|
|
|
1064
1104
|
// src/components/style-sections/background-section/background-section.tsx
|
|
1065
|
-
import * as
|
|
1105
|
+
import * as React19 from "react";
|
|
1066
1106
|
import { BackgroundControl } from "@elementor/editor-controls";
|
|
1067
1107
|
|
|
1068
1108
|
// src/controls-registry/styles-field.tsx
|
|
1069
|
-
import * as
|
|
1070
|
-
import { PropKeyProvider as PropKeyProvider2, PropProvider as PropProvider2 } from "@elementor/editor-controls";
|
|
1109
|
+
import * as React18 from "react";
|
|
1110
|
+
import { ControlAdornmentsProvider, PropKeyProvider as PropKeyProvider2, PropProvider as PropProvider2 } from "@elementor/editor-controls";
|
|
1071
1111
|
import { getStylesSchema } from "@elementor/editor-styles";
|
|
1072
1112
|
|
|
1073
1113
|
// src/hooks/use-styles-fields.ts
|
|
1074
|
-
import {
|
|
1114
|
+
import { useMemo } from "react";
|
|
1075
1115
|
import {
|
|
1076
1116
|
createElementStyle,
|
|
1077
1117
|
deleteElementStyle,
|
|
@@ -1087,8 +1127,7 @@ function useStylesFields(propNames) {
|
|
|
1087
1127
|
const classesProp = useClassesProp();
|
|
1088
1128
|
const undoableUpdateStyle = useUndoableUpdateStyle();
|
|
1089
1129
|
const undoableCreateElementStyle = useUndoableCreateElementStyle();
|
|
1090
|
-
|
|
1091
|
-
useEffect(() => provider?.subscribe(reRender), [provider]);
|
|
1130
|
+
useStylesRerender();
|
|
1092
1131
|
const value = getProps({
|
|
1093
1132
|
elementId: element.id,
|
|
1094
1133
|
styleId: id,
|
|
@@ -1211,6 +1250,62 @@ function useStylesField(propName) {
|
|
|
1211
1250
|
return [value, setValue];
|
|
1212
1251
|
}
|
|
1213
1252
|
|
|
1253
|
+
// src/styles-inheritance/styles-inheritance-indicator.tsx
|
|
1254
|
+
import * as React17 from "react";
|
|
1255
|
+
import { useBoundProp } from "@elementor/editor-controls";
|
|
1256
|
+
import { ELEMENTS_STYLES_PROVIDER_KEY as ELEMENTS_STYLES_PROVIDER_KEY2 } from "@elementor/editor-styles-repository";
|
|
1257
|
+
import { styled as styled4 } from "@elementor/ui";
|
|
1258
|
+
import { __ as __5 } from "@wordpress/i18n";
|
|
1259
|
+
var Circle = styled4("div", {
|
|
1260
|
+
shouldForwardProp: (prop) => prop !== "variant"
|
|
1261
|
+
})`
|
|
1262
|
+
width: 5px;
|
|
1263
|
+
height: 5px;
|
|
1264
|
+
border-radius: 50%;
|
|
1265
|
+
background-color: ${({ theme, variant }) => {
|
|
1266
|
+
switch (variant) {
|
|
1267
|
+
case "overridden":
|
|
1268
|
+
return theme.palette.warning.main;
|
|
1269
|
+
case "global-affects":
|
|
1270
|
+
return theme.palette.global.main;
|
|
1271
|
+
case "local-affects":
|
|
1272
|
+
return theme.palette.primary.main;
|
|
1273
|
+
default:
|
|
1274
|
+
return theme.palette.text.secondary;
|
|
1275
|
+
}
|
|
1276
|
+
}};
|
|
1277
|
+
`;
|
|
1278
|
+
var StylesInheritanceIndicator = () => {
|
|
1279
|
+
const { bind } = useBoundProp();
|
|
1280
|
+
const { id: currentStyleId, provider: currentStyleProvider, meta: currentStyleMeta } = useStyle();
|
|
1281
|
+
const [value] = useStylesField(bind);
|
|
1282
|
+
const inheritanceChain = useStylesInheritanceField(bind);
|
|
1283
|
+
if (!inheritanceChain.length) {
|
|
1284
|
+
return null;
|
|
1285
|
+
}
|
|
1286
|
+
const [{ styleId, styleVariant }] = inheritanceChain;
|
|
1287
|
+
const { breakpoint, state } = styleVariant.meta;
|
|
1288
|
+
if (styleId === currentStyleId && breakpoint === currentStyleMeta.breakpoint && state === currentStyleMeta.state) {
|
|
1289
|
+
return /* @__PURE__ */ React17.createElement(
|
|
1290
|
+
Circle,
|
|
1291
|
+
{
|
|
1292
|
+
"aria-label": __5("This is the final value", "elementor"),
|
|
1293
|
+
variant: currentStyleProvider?.key === ELEMENTS_STYLES_PROVIDER_KEY2 ? "local-affects" : "global-affects"
|
|
1294
|
+
}
|
|
1295
|
+
);
|
|
1296
|
+
}
|
|
1297
|
+
if (value !== null && value !== void 0) {
|
|
1298
|
+
return /* @__PURE__ */ React17.createElement(
|
|
1299
|
+
Circle,
|
|
1300
|
+
{
|
|
1301
|
+
"aria-label": __5("This value is overridden by another style", "elementor"),
|
|
1302
|
+
variant: "overridden"
|
|
1303
|
+
}
|
|
1304
|
+
);
|
|
1305
|
+
}
|
|
1306
|
+
return /* @__PURE__ */ React17.createElement(Circle, { "aria-label": __5("This has value from another style", "elementor") });
|
|
1307
|
+
};
|
|
1308
|
+
|
|
1214
1309
|
// src/controls-registry/styles-field.tsx
|
|
1215
1310
|
var StylesField = ({ bind, children }) => {
|
|
1216
1311
|
const [value, setValue] = useStylesField(bind);
|
|
@@ -1220,39 +1315,50 @@ var StylesField = ({ bind, children }) => {
|
|
|
1220
1315
|
const setValues = (newValue) => {
|
|
1221
1316
|
setValue(newValue[bind]);
|
|
1222
1317
|
};
|
|
1223
|
-
return /* @__PURE__ */
|
|
1318
|
+
return /* @__PURE__ */ React18.createElement(
|
|
1319
|
+
ControlAdornmentsProvider,
|
|
1320
|
+
{
|
|
1321
|
+
items: [
|
|
1322
|
+
{
|
|
1323
|
+
id: "styles-inheritance",
|
|
1324
|
+
Adornment: StylesInheritanceIndicator
|
|
1325
|
+
}
|
|
1326
|
+
]
|
|
1327
|
+
},
|
|
1328
|
+
/* @__PURE__ */ React18.createElement(PropProvider2, { propType, value: values, setValue: setValues }, /* @__PURE__ */ React18.createElement(PropKeyProvider2, { bind }, children))
|
|
1329
|
+
);
|
|
1224
1330
|
};
|
|
1225
1331
|
|
|
1226
1332
|
// src/components/style-sections/background-section/background-section.tsx
|
|
1227
1333
|
var BackgroundSection = () => {
|
|
1228
|
-
return /* @__PURE__ */
|
|
1334
|
+
return /* @__PURE__ */ React19.createElement(StylesField, { bind: "background" }, /* @__PURE__ */ React19.createElement(BackgroundControl, null));
|
|
1229
1335
|
};
|
|
1230
1336
|
|
|
1231
1337
|
// src/components/style-sections/border-section/border-section.tsx
|
|
1232
|
-
import * as
|
|
1338
|
+
import * as React29 from "react";
|
|
1233
1339
|
|
|
1234
1340
|
// src/components/panel-divider.tsx
|
|
1235
|
-
import * as
|
|
1341
|
+
import * as React20 from "react";
|
|
1236
1342
|
import { Divider as Divider3 } from "@elementor/ui";
|
|
1237
|
-
var PanelDivider = () => /* @__PURE__ */
|
|
1343
|
+
var PanelDivider = () => /* @__PURE__ */ React20.createElement(Divider3, { sx: { my: 0.5 } });
|
|
1238
1344
|
|
|
1239
1345
|
// src/components/section-content.tsx
|
|
1240
|
-
import * as
|
|
1346
|
+
import * as React21 from "react";
|
|
1241
1347
|
import { Stack as Stack5 } from "@elementor/ui";
|
|
1242
|
-
var SectionContent = ({ gap = 2, sx, children }) => /* @__PURE__ */
|
|
1348
|
+
var SectionContent = ({ gap = 2, sx, children }) => /* @__PURE__ */ React21.createElement(Stack5, { gap, sx: { ...sx } }, children);
|
|
1243
1349
|
|
|
1244
1350
|
// src/components/style-sections/border-section/border-field.tsx
|
|
1245
|
-
import * as
|
|
1246
|
-
import { __ as
|
|
1351
|
+
import * as React27 from "react";
|
|
1352
|
+
import { __ as __9 } from "@wordpress/i18n";
|
|
1247
1353
|
|
|
1248
1354
|
// src/components/add-or-remove-content.tsx
|
|
1249
|
-
import * as
|
|
1355
|
+
import * as React22 from "react";
|
|
1250
1356
|
import { ControlLabel as ControlLabel2 } from "@elementor/editor-controls";
|
|
1251
1357
|
import { MinusIcon, PlusIcon } from "@elementor/icons";
|
|
1252
1358
|
import { Collapse as Collapse2, IconButton as IconButton2, Stack as Stack6 } from "@elementor/ui";
|
|
1253
1359
|
var SIZE2 = "tiny";
|
|
1254
1360
|
var AddOrRemoveContent = ({ isAdded, label, onAdd, onRemove, children }) => {
|
|
1255
|
-
return /* @__PURE__ */
|
|
1361
|
+
return /* @__PURE__ */ React22.createElement(SectionContent, null, /* @__PURE__ */ React22.createElement(
|
|
1256
1362
|
Stack6,
|
|
1257
1363
|
{
|
|
1258
1364
|
direction: "row",
|
|
@@ -1261,47 +1367,47 @@ var AddOrRemoveContent = ({ isAdded, label, onAdd, onRemove, children }) => {
|
|
|
1261
1367
|
alignItems: "center"
|
|
1262
1368
|
}
|
|
1263
1369
|
},
|
|
1264
|
-
/* @__PURE__ */
|
|
1265
|
-
isAdded ? /* @__PURE__ */
|
|
1266
|
-
), /* @__PURE__ */
|
|
1370
|
+
/* @__PURE__ */ React22.createElement(ControlLabel2, null, label),
|
|
1371
|
+
isAdded ? /* @__PURE__ */ React22.createElement(IconButton2, { size: SIZE2, onClick: onRemove, "aria-label": "Remove" }, /* @__PURE__ */ React22.createElement(MinusIcon, { fontSize: SIZE2 })) : /* @__PURE__ */ React22.createElement(IconButton2, { size: SIZE2, onClick: onAdd, "aria-label": "Add" }, /* @__PURE__ */ React22.createElement(PlusIcon, { fontSize: SIZE2 }))
|
|
1372
|
+
), /* @__PURE__ */ React22.createElement(Collapse2, { in: isAdded, unmountOnExit: true }, /* @__PURE__ */ React22.createElement(SectionContent, null, children)));
|
|
1267
1373
|
};
|
|
1268
1374
|
|
|
1269
1375
|
// src/components/style-sections/border-section/border-color-field.tsx
|
|
1270
|
-
import * as
|
|
1376
|
+
import * as React23 from "react";
|
|
1271
1377
|
import { ColorControl, ControlLabel as ControlLabel3 } from "@elementor/editor-controls";
|
|
1272
1378
|
import { Grid } from "@elementor/ui";
|
|
1273
|
-
import { __ as
|
|
1379
|
+
import { __ as __6 } from "@wordpress/i18n";
|
|
1274
1380
|
var BorderColorField = () => {
|
|
1275
|
-
return /* @__PURE__ */
|
|
1381
|
+
return /* @__PURE__ */ React23.createElement(StylesField, { bind: "border-color" }, /* @__PURE__ */ React23.createElement(Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React23.createElement(Grid, { item: true, xs: 6 }, /* @__PURE__ */ React23.createElement(ControlLabel3, null, __6("Border color", "elementor"))), /* @__PURE__ */ React23.createElement(Grid, { item: true, xs: 6 }, /* @__PURE__ */ React23.createElement(ColorControl, null))));
|
|
1276
1382
|
};
|
|
1277
1383
|
|
|
1278
1384
|
// src/components/style-sections/border-section/border-style-field.tsx
|
|
1279
|
-
import * as
|
|
1385
|
+
import * as React24 from "react";
|
|
1280
1386
|
import { ControlLabel as ControlLabel4, SelectControl as SelectControl2 } from "@elementor/editor-controls";
|
|
1281
1387
|
import { Grid as Grid2 } from "@elementor/ui";
|
|
1282
|
-
import { __ as
|
|
1388
|
+
import { __ as __7 } from "@wordpress/i18n";
|
|
1283
1389
|
var borderStyles = [
|
|
1284
|
-
{ value: "none", label:
|
|
1285
|
-
{ value: "solid", label:
|
|
1286
|
-
{ value: "dashed", label:
|
|
1287
|
-
{ value: "dotted", label:
|
|
1288
|
-
{ value: "double", label:
|
|
1289
|
-
{ value: "groove", label:
|
|
1290
|
-
{ value: "ridge", label:
|
|
1291
|
-
{ value: "inset", label:
|
|
1292
|
-
{ value: "outset", label:
|
|
1390
|
+
{ value: "none", label: __7("None", "elementor") },
|
|
1391
|
+
{ value: "solid", label: __7("Solid", "elementor") },
|
|
1392
|
+
{ value: "dashed", label: __7("Dashed", "elementor") },
|
|
1393
|
+
{ value: "dotted", label: __7("Dotted", "elementor") },
|
|
1394
|
+
{ value: "double", label: __7("Double", "elementor") },
|
|
1395
|
+
{ value: "groove", label: __7("Groove", "elementor") },
|
|
1396
|
+
{ value: "ridge", label: __7("Ridge", "elementor") },
|
|
1397
|
+
{ value: "inset", label: __7("Inset", "elementor") },
|
|
1398
|
+
{ value: "outset", label: __7("Outset", "elementor") }
|
|
1293
1399
|
];
|
|
1294
1400
|
var BorderStyleField = () => {
|
|
1295
|
-
return /* @__PURE__ */
|
|
1401
|
+
return /* @__PURE__ */ React24.createElement(StylesField, { bind: "border-style" }, /* @__PURE__ */ React24.createElement(Grid2, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React24.createElement(Grid2, { item: true, xs: 6 }, /* @__PURE__ */ React24.createElement(ControlLabel4, null, __7("Border type", "elementor"))), /* @__PURE__ */ React24.createElement(Grid2, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React24.createElement(SelectControl2, { options: borderStyles }))));
|
|
1296
1402
|
};
|
|
1297
1403
|
|
|
1298
1404
|
// src/components/style-sections/border-section/border-width-field.tsx
|
|
1299
|
-
import * as
|
|
1405
|
+
import * as React26 from "react";
|
|
1300
1406
|
import { EqualUnequalSizesControl } from "@elementor/editor-controls";
|
|
1301
1407
|
import { borderWidthPropTypeUtil } from "@elementor/editor-props";
|
|
1302
1408
|
import { SideAllIcon, SideBottomIcon, SideLeftIcon, SideRightIcon, SideTopIcon } from "@elementor/icons";
|
|
1303
1409
|
import { withDirection } from "@elementor/ui";
|
|
1304
|
-
import { __ as
|
|
1410
|
+
import { __ as __8 } from "@wordpress/i18n";
|
|
1305
1411
|
|
|
1306
1412
|
// src/hooks/use-direction.ts
|
|
1307
1413
|
import { useTheme } from "@elementor/ui";
|
|
@@ -1312,7 +1418,7 @@ function useDirection() {
|
|
|
1312
1418
|
}
|
|
1313
1419
|
|
|
1314
1420
|
// src/components/style-sections/layout-section/utils/rotated-icon.tsx
|
|
1315
|
-
import * as
|
|
1421
|
+
import * as React25 from "react";
|
|
1316
1422
|
import { useRef } from "react";
|
|
1317
1423
|
import { useTheme as useTheme2 } from "@elementor/ui";
|
|
1318
1424
|
var CLOCKWISE_ANGLES = {
|
|
@@ -1330,7 +1436,7 @@ var COUNTER_CLOCKWISE_ANGLES = {
|
|
|
1330
1436
|
var RotatedIcon = ({ icon: Icon, size, isClockwise = true, offset = 0 }) => {
|
|
1331
1437
|
const rotate = useRef(useGetTargetAngle(isClockwise, offset));
|
|
1332
1438
|
rotate.current = useGetTargetAngle(isClockwise, offset, rotate);
|
|
1333
|
-
return /* @__PURE__ */
|
|
1439
|
+
return /* @__PURE__ */ React25.createElement(Icon, { fontSize: size, sx: { transition: ".3s", rotate: `${rotate.current}deg` } });
|
|
1334
1440
|
};
|
|
1335
1441
|
var useGetTargetAngle = (isClockwise, offset, existingRef) => {
|
|
1336
1442
|
const [direction] = useStylesField("flex-direction");
|
|
@@ -1349,35 +1455,35 @@ var InlineStartIcon = withDirection(SideRightIcon);
|
|
|
1349
1455
|
var InlineEndIcon = withDirection(SideLeftIcon);
|
|
1350
1456
|
var getEdges = (isSiteRtl) => [
|
|
1351
1457
|
{
|
|
1352
|
-
label:
|
|
1353
|
-
icon: /* @__PURE__ */
|
|
1458
|
+
label: __8("Top", "elementor"),
|
|
1459
|
+
icon: /* @__PURE__ */ React26.createElement(SideTopIcon, { fontSize: "tiny" }),
|
|
1354
1460
|
bind: "block-start"
|
|
1355
1461
|
},
|
|
1356
1462
|
{
|
|
1357
|
-
label: isSiteRtl ?
|
|
1358
|
-
icon: /* @__PURE__ */
|
|
1463
|
+
label: isSiteRtl ? __8("Left", "elementor") : __8("Right", "elementor"),
|
|
1464
|
+
icon: /* @__PURE__ */ React26.createElement(RotatedIcon, { icon: InlineStartIcon, size: "tiny" }),
|
|
1359
1465
|
bind: "inline-end"
|
|
1360
1466
|
},
|
|
1361
1467
|
{
|
|
1362
|
-
label:
|
|
1363
|
-
icon: /* @__PURE__ */
|
|
1468
|
+
label: __8("Bottom", "elementor"),
|
|
1469
|
+
icon: /* @__PURE__ */ React26.createElement(SideBottomIcon, { fontSize: "tiny" }),
|
|
1364
1470
|
bind: "block-end"
|
|
1365
1471
|
},
|
|
1366
1472
|
{
|
|
1367
|
-
label: isSiteRtl ?
|
|
1368
|
-
icon: /* @__PURE__ */
|
|
1473
|
+
label: isSiteRtl ? __8("Right", "elementor") : __8("Left", "elementor"),
|
|
1474
|
+
icon: /* @__PURE__ */ React26.createElement(RotatedIcon, { icon: InlineEndIcon, size: "tiny" }),
|
|
1369
1475
|
bind: "inline-start"
|
|
1370
1476
|
}
|
|
1371
1477
|
];
|
|
1372
1478
|
var BorderWidthField = () => {
|
|
1373
1479
|
const { isSiteRtl } = useDirection();
|
|
1374
|
-
return /* @__PURE__ */
|
|
1480
|
+
return /* @__PURE__ */ React26.createElement(StylesField, { bind: "border-width" }, /* @__PURE__ */ React26.createElement(
|
|
1375
1481
|
EqualUnequalSizesControl,
|
|
1376
1482
|
{
|
|
1377
1483
|
items: getEdges(isSiteRtl),
|
|
1378
|
-
label:
|
|
1379
|
-
icon: /* @__PURE__ */
|
|
1380
|
-
tooltipLabel:
|
|
1484
|
+
label: __8("Border width", "elementor"),
|
|
1485
|
+
icon: /* @__PURE__ */ React26.createElement(SideAllIcon, { fontSize: "tiny" }),
|
|
1486
|
+
tooltipLabel: __8("Adjust borders", "elementor"),
|
|
1381
1487
|
multiSizePropTypeUtil: borderWidthPropTypeUtil
|
|
1382
1488
|
}
|
|
1383
1489
|
));
|
|
@@ -1402,22 +1508,22 @@ var BorderField = () => {
|
|
|
1402
1508
|
});
|
|
1403
1509
|
};
|
|
1404
1510
|
const hasBorder = Object.values(border ?? {}).some(Boolean);
|
|
1405
|
-
return /* @__PURE__ */
|
|
1511
|
+
return /* @__PURE__ */ React27.createElement(
|
|
1406
1512
|
AddOrRemoveContent,
|
|
1407
1513
|
{
|
|
1408
|
-
label:
|
|
1514
|
+
label: __9("Border", "elementor"),
|
|
1409
1515
|
isAdded: hasBorder,
|
|
1410
1516
|
onAdd: addBorder,
|
|
1411
1517
|
onRemove: removeBorder
|
|
1412
1518
|
},
|
|
1413
|
-
/* @__PURE__ */
|
|
1414
|
-
/* @__PURE__ */
|
|
1415
|
-
/* @__PURE__ */
|
|
1519
|
+
/* @__PURE__ */ React27.createElement(BorderWidthField, null),
|
|
1520
|
+
/* @__PURE__ */ React27.createElement(BorderColorField, null),
|
|
1521
|
+
/* @__PURE__ */ React27.createElement(BorderStyleField, null)
|
|
1416
1522
|
);
|
|
1417
1523
|
};
|
|
1418
1524
|
|
|
1419
1525
|
// src/components/style-sections/border-section/border-radius-field.tsx
|
|
1420
|
-
import * as
|
|
1526
|
+
import * as React28 from "react";
|
|
1421
1527
|
import { EqualUnequalSizesControl as EqualUnequalSizesControl2 } from "@elementor/editor-controls";
|
|
1422
1528
|
import { borderRadiusPropTypeUtil } from "@elementor/editor-props";
|
|
1423
1529
|
import {
|
|
@@ -1428,66 +1534,66 @@ import {
|
|
|
1428
1534
|
RadiusTopRightIcon
|
|
1429
1535
|
} from "@elementor/icons";
|
|
1430
1536
|
import { withDirection as withDirection2 } from "@elementor/ui";
|
|
1431
|
-
import { __ as
|
|
1537
|
+
import { __ as __10 } from "@wordpress/i18n";
|
|
1432
1538
|
var StartStartIcon = withDirection2(RadiusTopLeftIcon);
|
|
1433
1539
|
var StartEndIcon = withDirection2(RadiusTopRightIcon);
|
|
1434
1540
|
var EndStartIcon = withDirection2(RadiusBottomLeftIcon);
|
|
1435
1541
|
var EndEndIcon = withDirection2(RadiusBottomRightIcon);
|
|
1436
|
-
var getStartStartLabel = (isSiteRtl) => isSiteRtl ?
|
|
1437
|
-
var getStartEndLabel = (isSiteRtl) => isSiteRtl ?
|
|
1438
|
-
var getEndStartLabel = (isSiteRtl) => isSiteRtl ?
|
|
1439
|
-
var getEndEndLabel = (isSiteRtl) => isSiteRtl ?
|
|
1542
|
+
var getStartStartLabel = (isSiteRtl) => isSiteRtl ? __10("Top right", "elementor") : __10("Top left", "elementor");
|
|
1543
|
+
var getStartEndLabel = (isSiteRtl) => isSiteRtl ? __10("Top left", "elementor") : __10("Top right", "elementor");
|
|
1544
|
+
var getEndStartLabel = (isSiteRtl) => isSiteRtl ? __10("Bottom right", "elementor") : __10("Bottom left", "elementor");
|
|
1545
|
+
var getEndEndLabel = (isSiteRtl) => isSiteRtl ? __10("Bottom left", "elementor") : __10("Bottom right", "elementor");
|
|
1440
1546
|
var getCorners = (isSiteRtl) => [
|
|
1441
1547
|
{
|
|
1442
1548
|
label: getStartStartLabel(isSiteRtl),
|
|
1443
|
-
icon: /* @__PURE__ */
|
|
1549
|
+
icon: /* @__PURE__ */ React28.createElement(RotatedIcon, { icon: StartStartIcon, size: "tiny" }),
|
|
1444
1550
|
bind: "start-start"
|
|
1445
1551
|
},
|
|
1446
1552
|
{
|
|
1447
1553
|
label: getStartEndLabel(isSiteRtl),
|
|
1448
|
-
icon: /* @__PURE__ */
|
|
1554
|
+
icon: /* @__PURE__ */ React28.createElement(RotatedIcon, { icon: StartEndIcon, size: "tiny" }),
|
|
1449
1555
|
bind: "start-end"
|
|
1450
1556
|
},
|
|
1451
1557
|
{
|
|
1452
1558
|
label: getEndStartLabel(isSiteRtl),
|
|
1453
|
-
icon: /* @__PURE__ */
|
|
1559
|
+
icon: /* @__PURE__ */ React28.createElement(RotatedIcon, { icon: EndStartIcon, size: "tiny" }),
|
|
1454
1560
|
bind: "end-start"
|
|
1455
1561
|
},
|
|
1456
1562
|
{
|
|
1457
1563
|
label: getEndEndLabel(isSiteRtl),
|
|
1458
|
-
icon: /* @__PURE__ */
|
|
1564
|
+
icon: /* @__PURE__ */ React28.createElement(RotatedIcon, { icon: EndEndIcon, size: "tiny" }),
|
|
1459
1565
|
bind: "end-end"
|
|
1460
1566
|
}
|
|
1461
1567
|
];
|
|
1462
1568
|
var BorderRadiusField = () => {
|
|
1463
1569
|
const { isSiteRtl } = useDirection();
|
|
1464
|
-
return /* @__PURE__ */
|
|
1570
|
+
return /* @__PURE__ */ React28.createElement(StylesField, { bind: "border-radius" }, /* @__PURE__ */ React28.createElement(
|
|
1465
1571
|
EqualUnequalSizesControl2,
|
|
1466
1572
|
{
|
|
1467
1573
|
items: getCorners(isSiteRtl),
|
|
1468
|
-
label:
|
|
1469
|
-
icon: /* @__PURE__ */
|
|
1470
|
-
tooltipLabel:
|
|
1574
|
+
label: __10("Border radius", "elementor"),
|
|
1575
|
+
icon: /* @__PURE__ */ React28.createElement(BorderCornersIcon, { fontSize: "tiny" }),
|
|
1576
|
+
tooltipLabel: __10("Adjust corners", "elementor"),
|
|
1471
1577
|
multiSizePropTypeUtil: borderRadiusPropTypeUtil
|
|
1472
1578
|
}
|
|
1473
1579
|
));
|
|
1474
1580
|
};
|
|
1475
1581
|
|
|
1476
1582
|
// src/components/style-sections/border-section/border-section.tsx
|
|
1477
|
-
var BorderSection = () => /* @__PURE__ */
|
|
1583
|
+
var BorderSection = () => /* @__PURE__ */ React29.createElement(SectionContent, null, /* @__PURE__ */ React29.createElement(BorderRadiusField, null), /* @__PURE__ */ React29.createElement(PanelDivider, null), /* @__PURE__ */ React29.createElement(BorderField, null));
|
|
1478
1584
|
|
|
1479
1585
|
// src/components/style-sections/effects-section/effects-section.tsx
|
|
1480
|
-
import * as
|
|
1586
|
+
import * as React30 from "react";
|
|
1481
1587
|
import { BoxShadowRepeaterControl } from "@elementor/editor-controls";
|
|
1482
1588
|
var EffectsSection = () => {
|
|
1483
|
-
return /* @__PURE__ */
|
|
1589
|
+
return /* @__PURE__ */ React30.createElement(SectionContent, null, /* @__PURE__ */ React30.createElement(StylesField, { bind: "box-shadow" }, /* @__PURE__ */ React30.createElement(BoxShadowRepeaterControl, null)));
|
|
1484
1590
|
};
|
|
1485
1591
|
|
|
1486
1592
|
// src/components/style-sections/layout-section/layout-section.tsx
|
|
1487
|
-
import * as
|
|
1593
|
+
import * as React40 from "react";
|
|
1488
1594
|
import { ControlLabel as ControlLabel13 } from "@elementor/editor-controls";
|
|
1489
1595
|
import { useParentElement } from "@elementor/editor-elements";
|
|
1490
|
-
import { __ as
|
|
1596
|
+
import { __ as __20 } from "@wordpress/i18n";
|
|
1491
1597
|
|
|
1492
1598
|
// src/hooks/use-computed-style.ts
|
|
1493
1599
|
import { __privateUseListenTo as useListenTo, commandEndEvent, windowEvent } from "@elementor/editor-v1-adapters";
|
|
@@ -1515,7 +1621,7 @@ function useComputedStyle(elementId) {
|
|
|
1515
1621
|
}
|
|
1516
1622
|
|
|
1517
1623
|
// src/components/style-sections/layout-section/align-items-field.tsx
|
|
1518
|
-
import * as
|
|
1624
|
+
import * as React31 from "react";
|
|
1519
1625
|
import { ControlLabel as ControlLabel5, ToggleControl } from "@elementor/editor-controls";
|
|
1520
1626
|
import {
|
|
1521
1627
|
LayoutAlignCenterIcon as CenterIcon,
|
|
@@ -1524,7 +1630,7 @@ import {
|
|
|
1524
1630
|
LayoutDistributeVerticalIcon as JustifyIcon
|
|
1525
1631
|
} from "@elementor/icons";
|
|
1526
1632
|
import { DirectionProvider, Grid as Grid3, ThemeProvider, withDirection as withDirection3 } from "@elementor/ui";
|
|
1527
|
-
import { __ as
|
|
1633
|
+
import { __ as __11 } from "@wordpress/i18n";
|
|
1528
1634
|
var StartIcon = withDirection3(LayoutAlignLeftIcon);
|
|
1529
1635
|
var EndIcon = withDirection3(LayoutAlignRightIcon);
|
|
1530
1636
|
var iconProps = {
|
|
@@ -1534,36 +1640,36 @@ var iconProps = {
|
|
|
1534
1640
|
var options = [
|
|
1535
1641
|
{
|
|
1536
1642
|
value: "start",
|
|
1537
|
-
label:
|
|
1538
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1643
|
+
label: __11("Start", "elementor"),
|
|
1644
|
+
renderContent: ({ size }) => /* @__PURE__ */ React31.createElement(RotatedIcon, { icon: StartIcon, size, ...iconProps }),
|
|
1539
1645
|
showTooltip: true
|
|
1540
1646
|
},
|
|
1541
1647
|
{
|
|
1542
1648
|
value: "center",
|
|
1543
|
-
label:
|
|
1544
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1649
|
+
label: __11("Center", "elementor"),
|
|
1650
|
+
renderContent: ({ size }) => /* @__PURE__ */ React31.createElement(RotatedIcon, { icon: CenterIcon, size, ...iconProps }),
|
|
1545
1651
|
showTooltip: true
|
|
1546
1652
|
},
|
|
1547
1653
|
{
|
|
1548
1654
|
value: "end",
|
|
1549
|
-
label:
|
|
1550
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1655
|
+
label: __11("End", "elementor"),
|
|
1656
|
+
renderContent: ({ size }) => /* @__PURE__ */ React31.createElement(RotatedIcon, { icon: EndIcon, size, ...iconProps }),
|
|
1551
1657
|
showTooltip: true
|
|
1552
1658
|
},
|
|
1553
1659
|
{
|
|
1554
1660
|
value: "stretch",
|
|
1555
|
-
label:
|
|
1556
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1661
|
+
label: __11("Stretch", "elementor"),
|
|
1662
|
+
renderContent: ({ size }) => /* @__PURE__ */ React31.createElement(RotatedIcon, { icon: JustifyIcon, size, ...iconProps }),
|
|
1557
1663
|
showTooltip: true
|
|
1558
1664
|
}
|
|
1559
1665
|
];
|
|
1560
1666
|
var AlignItemsField = () => {
|
|
1561
1667
|
const { isSiteRtl } = useDirection();
|
|
1562
|
-
return /* @__PURE__ */
|
|
1668
|
+
return /* @__PURE__ */ React31.createElement(DirectionProvider, { rtl: isSiteRtl }, /* @__PURE__ */ React31.createElement(ThemeProvider, null, /* @__PURE__ */ React31.createElement(StylesField, { bind: "align-items" }, /* @__PURE__ */ React31.createElement(Grid3, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React31.createElement(Grid3, { item: true, xs: 6 }, /* @__PURE__ */ React31.createElement(ControlLabel5, null, __11("Align items", "elementor"))), /* @__PURE__ */ React31.createElement(Grid3, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React31.createElement(ToggleControl, { options }))))));
|
|
1563
1669
|
};
|
|
1564
1670
|
|
|
1565
1671
|
// src/components/style-sections/layout-section/align-self-child-field.tsx
|
|
1566
|
-
import * as
|
|
1672
|
+
import * as React32 from "react";
|
|
1567
1673
|
import { ControlLabel as ControlLabel6, ToggleControl as ToggleControl2 } from "@elementor/editor-controls";
|
|
1568
1674
|
import {
|
|
1569
1675
|
LayoutAlignCenterIcon as CenterIcon2,
|
|
@@ -1572,7 +1678,7 @@ import {
|
|
|
1572
1678
|
LayoutDistributeVerticalIcon as JustifyIcon2
|
|
1573
1679
|
} from "@elementor/icons";
|
|
1574
1680
|
import { DirectionProvider as DirectionProvider2, Grid as Grid4, ThemeProvider as ThemeProvider2, withDirection as withDirection4 } from "@elementor/ui";
|
|
1575
|
-
import { __ as
|
|
1681
|
+
import { __ as __12 } from "@wordpress/i18n";
|
|
1576
1682
|
var StartIcon2 = withDirection4(LayoutAlignLeftIcon2);
|
|
1577
1683
|
var EndIcon2 = withDirection4(LayoutAlignRightIcon2);
|
|
1578
1684
|
var iconProps2 = {
|
|
@@ -1582,114 +1688,114 @@ var iconProps2 = {
|
|
|
1582
1688
|
var options2 = [
|
|
1583
1689
|
{
|
|
1584
1690
|
value: "start",
|
|
1585
|
-
label:
|
|
1586
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1691
|
+
label: __12("Start", "elementor"),
|
|
1692
|
+
renderContent: ({ size }) => /* @__PURE__ */ React32.createElement(RotatedIcon, { icon: StartIcon2, size, ...iconProps2 }),
|
|
1587
1693
|
showTooltip: true
|
|
1588
1694
|
},
|
|
1589
1695
|
{
|
|
1590
1696
|
value: "center",
|
|
1591
|
-
label:
|
|
1592
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1697
|
+
label: __12("Center", "elementor"),
|
|
1698
|
+
renderContent: ({ size }) => /* @__PURE__ */ React32.createElement(RotatedIcon, { icon: CenterIcon2, size, ...iconProps2 }),
|
|
1593
1699
|
showTooltip: true
|
|
1594
1700
|
},
|
|
1595
1701
|
{
|
|
1596
1702
|
value: "end",
|
|
1597
|
-
label:
|
|
1598
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1703
|
+
label: __12("End", "elementor"),
|
|
1704
|
+
renderContent: ({ size }) => /* @__PURE__ */ React32.createElement(RotatedIcon, { icon: EndIcon2, size, ...iconProps2 }),
|
|
1599
1705
|
showTooltip: true
|
|
1600
1706
|
},
|
|
1601
1707
|
{
|
|
1602
1708
|
value: "stretch",
|
|
1603
|
-
label:
|
|
1604
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1709
|
+
label: __12("Stretch", "elementor"),
|
|
1710
|
+
renderContent: ({ size }) => /* @__PURE__ */ React32.createElement(RotatedIcon, { icon: JustifyIcon2, size, ...iconProps2 }),
|
|
1605
1711
|
showTooltip: true
|
|
1606
1712
|
}
|
|
1607
1713
|
];
|
|
1608
1714
|
var AlignSelfChild = () => {
|
|
1609
1715
|
const { isSiteRtl } = useDirection();
|
|
1610
|
-
return /* @__PURE__ */
|
|
1716
|
+
return /* @__PURE__ */ React32.createElement(DirectionProvider2, { rtl: isSiteRtl }, /* @__PURE__ */ React32.createElement(ThemeProvider2, null, /* @__PURE__ */ React32.createElement(StylesField, { bind: "align-self" }, /* @__PURE__ */ React32.createElement(Grid4, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React32.createElement(Grid4, { item: true, xs: 6 }, /* @__PURE__ */ React32.createElement(ControlLabel6, null, __12("Align self", "elementor"))), /* @__PURE__ */ React32.createElement(Grid4, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React32.createElement(ToggleControl2, { options: options2 }))))));
|
|
1611
1717
|
};
|
|
1612
1718
|
|
|
1613
1719
|
// src/components/style-sections/layout-section/display-field.tsx
|
|
1614
|
-
import * as
|
|
1720
|
+
import * as React33 from "react";
|
|
1615
1721
|
import { ControlLabel as ControlLabel7, ToggleControl as ToggleControl3 } from "@elementor/editor-controls";
|
|
1616
1722
|
import { Stack as Stack7 } from "@elementor/ui";
|
|
1617
|
-
import { __ as
|
|
1723
|
+
import { __ as __13 } from "@wordpress/i18n";
|
|
1618
1724
|
var DisplayField = () => {
|
|
1619
1725
|
const options12 = [
|
|
1620
1726
|
{
|
|
1621
1727
|
value: "block",
|
|
1622
|
-
renderContent: () =>
|
|
1623
|
-
label:
|
|
1728
|
+
renderContent: () => __13("Block", "elementor"),
|
|
1729
|
+
label: __13("Block", "elementor"),
|
|
1624
1730
|
showTooltip: true
|
|
1625
1731
|
},
|
|
1626
1732
|
{
|
|
1627
1733
|
value: "flex",
|
|
1628
|
-
renderContent: () =>
|
|
1629
|
-
label:
|
|
1734
|
+
renderContent: () => __13("Flex", "elementor"),
|
|
1735
|
+
label: __13("Flex", "elementor"),
|
|
1630
1736
|
showTooltip: true
|
|
1631
1737
|
},
|
|
1632
1738
|
{
|
|
1633
1739
|
value: "inline-block",
|
|
1634
|
-
renderContent: () =>
|
|
1635
|
-
label:
|
|
1740
|
+
renderContent: () => __13("In-blk", "elementor"),
|
|
1741
|
+
label: __13("Inline-block", "elementor"),
|
|
1636
1742
|
showTooltip: true
|
|
1637
1743
|
},
|
|
1638
1744
|
{
|
|
1639
1745
|
value: "inline-flex",
|
|
1640
|
-
renderContent: () =>
|
|
1641
|
-
label:
|
|
1746
|
+
renderContent: () => __13("In-flx", "elementor"),
|
|
1747
|
+
label: __13("Inline-flex", "elementor"),
|
|
1642
1748
|
showTooltip: true
|
|
1643
1749
|
}
|
|
1644
1750
|
];
|
|
1645
|
-
return /* @__PURE__ */
|
|
1751
|
+
return /* @__PURE__ */ React33.createElement(StylesField, { bind: "display" }, /* @__PURE__ */ React33.createElement(Stack7, { gap: 0.75 }, /* @__PURE__ */ React33.createElement(ControlLabel7, null, __13("Display", "elementor")), /* @__PURE__ */ React33.createElement(ToggleControl3, { options: options12, fullWidth: true })));
|
|
1646
1752
|
};
|
|
1647
1753
|
|
|
1648
1754
|
// src/components/style-sections/layout-section/flex-direction-field.tsx
|
|
1649
|
-
import * as
|
|
1755
|
+
import * as React34 from "react";
|
|
1650
1756
|
import { ControlLabel as ControlLabel8, ToggleControl as ToggleControl4 } from "@elementor/editor-controls";
|
|
1651
1757
|
import { ArrowDownSmallIcon, ArrowLeftIcon, ArrowRightIcon, ArrowUpSmallIcon } from "@elementor/icons";
|
|
1652
1758
|
import { DirectionProvider as DirectionProvider3, Grid as Grid5, ThemeProvider as ThemeProvider3, withDirection as withDirection5 } from "@elementor/ui";
|
|
1653
|
-
import { __ as
|
|
1759
|
+
import { __ as __14 } from "@wordpress/i18n";
|
|
1654
1760
|
var options3 = [
|
|
1655
1761
|
{
|
|
1656
1762
|
value: "row",
|
|
1657
|
-
label:
|
|
1763
|
+
label: __14("Row", "elementor"),
|
|
1658
1764
|
renderContent: ({ size }) => {
|
|
1659
1765
|
const StartIcon5 = withDirection5(ArrowRightIcon);
|
|
1660
|
-
return /* @__PURE__ */
|
|
1766
|
+
return /* @__PURE__ */ React34.createElement(StartIcon5, { fontSize: size });
|
|
1661
1767
|
},
|
|
1662
1768
|
showTooltip: true
|
|
1663
1769
|
},
|
|
1664
1770
|
{
|
|
1665
1771
|
value: "column",
|
|
1666
|
-
label:
|
|
1667
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1772
|
+
label: __14("Column", "elementor"),
|
|
1773
|
+
renderContent: ({ size }) => /* @__PURE__ */ React34.createElement(ArrowDownSmallIcon, { fontSize: size }),
|
|
1668
1774
|
showTooltip: true
|
|
1669
1775
|
},
|
|
1670
1776
|
{
|
|
1671
1777
|
value: "row-reverse",
|
|
1672
|
-
label:
|
|
1778
|
+
label: __14("Reversed row", "elementor"),
|
|
1673
1779
|
renderContent: ({ size }) => {
|
|
1674
1780
|
const EndIcon5 = withDirection5(ArrowLeftIcon);
|
|
1675
|
-
return /* @__PURE__ */
|
|
1781
|
+
return /* @__PURE__ */ React34.createElement(EndIcon5, { fontSize: size });
|
|
1676
1782
|
},
|
|
1677
1783
|
showTooltip: true
|
|
1678
1784
|
},
|
|
1679
1785
|
{
|
|
1680
1786
|
value: "column-reverse",
|
|
1681
|
-
label:
|
|
1682
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1787
|
+
label: __14("Reversed column", "elementor"),
|
|
1788
|
+
renderContent: ({ size }) => /* @__PURE__ */ React34.createElement(ArrowUpSmallIcon, { fontSize: size }),
|
|
1683
1789
|
showTooltip: true
|
|
1684
1790
|
}
|
|
1685
1791
|
];
|
|
1686
1792
|
var FlexDirectionField = () => {
|
|
1687
1793
|
const { isSiteRtl } = useDirection();
|
|
1688
|
-
return /* @__PURE__ */
|
|
1794
|
+
return /* @__PURE__ */ React34.createElement(DirectionProvider3, { rtl: isSiteRtl }, /* @__PURE__ */ React34.createElement(ThemeProvider3, null, /* @__PURE__ */ React34.createElement(StylesField, { bind: "flex-direction" }, /* @__PURE__ */ React34.createElement(Grid5, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React34.createElement(Grid5, { item: true, xs: 6 }, /* @__PURE__ */ React34.createElement(ControlLabel8, null, __14("Direction", "elementor"))), /* @__PURE__ */ React34.createElement(Grid5, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React34.createElement(ToggleControl4, { options: options3 }))))));
|
|
1689
1795
|
};
|
|
1690
1796
|
|
|
1691
1797
|
// src/components/style-sections/layout-section/flex-order-field.tsx
|
|
1692
|
-
import * as
|
|
1798
|
+
import * as React35 from "react";
|
|
1693
1799
|
import { useState as useState4 } from "react";
|
|
1694
1800
|
import {
|
|
1695
1801
|
ControlLabel as ControlLabel9,
|
|
@@ -1698,7 +1804,7 @@ import {
|
|
|
1698
1804
|
} from "@elementor/editor-controls";
|
|
1699
1805
|
import { ArrowDownSmallIcon as ArrowDownSmallIcon2, ArrowUpSmallIcon as ArrowUpSmallIcon2, PencilIcon } from "@elementor/icons";
|
|
1700
1806
|
import { DirectionProvider as DirectionProvider4, Grid as Grid6, ThemeProvider as ThemeProvider4 } from "@elementor/ui";
|
|
1701
|
-
import { __ as
|
|
1807
|
+
import { __ as __15 } from "@wordpress/i18n";
|
|
1702
1808
|
var FIRST_DEFAULT_VALUE = -99999;
|
|
1703
1809
|
var LAST_DEFAULT_VALUE = 99999;
|
|
1704
1810
|
var FIRST = "first";
|
|
@@ -1711,20 +1817,20 @@ var orderValueMap = {
|
|
|
1711
1817
|
var items = [
|
|
1712
1818
|
{
|
|
1713
1819
|
value: FIRST,
|
|
1714
|
-
label:
|
|
1715
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1820
|
+
label: __15("First", "elementor"),
|
|
1821
|
+
renderContent: ({ size }) => /* @__PURE__ */ React35.createElement(ArrowUpSmallIcon2, { fontSize: size }),
|
|
1716
1822
|
showTooltip: true
|
|
1717
1823
|
},
|
|
1718
1824
|
{
|
|
1719
1825
|
value: LAST,
|
|
1720
|
-
label:
|
|
1721
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1826
|
+
label: __15("Last", "elementor"),
|
|
1827
|
+
renderContent: ({ size }) => /* @__PURE__ */ React35.createElement(ArrowDownSmallIcon2, { fontSize: size }),
|
|
1722
1828
|
showTooltip: true
|
|
1723
1829
|
},
|
|
1724
1830
|
{
|
|
1725
1831
|
value: CUSTOM,
|
|
1726
|
-
label:
|
|
1727
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1832
|
+
label: __15("Custom", "elementor"),
|
|
1833
|
+
renderContent: ({ size }) => /* @__PURE__ */ React35.createElement(PencilIcon, { fontSize: size }),
|
|
1728
1834
|
showTooltip: true
|
|
1729
1835
|
}
|
|
1730
1836
|
];
|
|
@@ -1739,7 +1845,7 @@ var FlexOrderField = () => {
|
|
|
1739
1845
|
}
|
|
1740
1846
|
setOrder({ $$type: "number", value: orderValueMap[group] });
|
|
1741
1847
|
};
|
|
1742
|
-
return /* @__PURE__ */
|
|
1848
|
+
return /* @__PURE__ */ React35.createElement(DirectionProvider4, { rtl: isSiteRtl }, /* @__PURE__ */ React35.createElement(ThemeProvider4, null, /* @__PURE__ */ React35.createElement(SectionContent, null, /* @__PURE__ */ React35.createElement(Grid6, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React35.createElement(Grid6, { item: true, xs: 6 }, /* @__PURE__ */ React35.createElement(ControlLabel9, null, __15("Order", "elementor"))), /* @__PURE__ */ React35.createElement(Grid6, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React35.createElement(
|
|
1743
1849
|
ControlToggleButtonGroup,
|
|
1744
1850
|
{
|
|
1745
1851
|
items,
|
|
@@ -1747,7 +1853,7 @@ var FlexOrderField = () => {
|
|
|
1747
1853
|
onChange: handleToggleButtonChange,
|
|
1748
1854
|
exclusive: true
|
|
1749
1855
|
}
|
|
1750
|
-
))), CUSTOM === groupControlValue && /* @__PURE__ */
|
|
1856
|
+
))), CUSTOM === groupControlValue && /* @__PURE__ */ React35.createElement(StylesField, { bind: "order" }, /* @__PURE__ */ React35.createElement(Grid6, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React35.createElement(Grid6, { item: true, xs: 6 }, /* @__PURE__ */ React35.createElement(ControlLabel9, null, __15("Custom order", "elementor"))), /* @__PURE__ */ React35.createElement(Grid6, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React35.createElement(
|
|
1751
1857
|
NumberControl,
|
|
1752
1858
|
{
|
|
1753
1859
|
min: FIRST_DEFAULT_VALUE + 1,
|
|
@@ -1767,7 +1873,7 @@ var getGroupControlValue = (order) => {
|
|
|
1767
1873
|
};
|
|
1768
1874
|
|
|
1769
1875
|
// src/components/style-sections/layout-section/flex-size-field.tsx
|
|
1770
|
-
import * as
|
|
1876
|
+
import * as React36 from "react";
|
|
1771
1877
|
import { useMemo as useMemo2, useState as useState5 } from "react";
|
|
1772
1878
|
import {
|
|
1773
1879
|
ControlLabel as ControlLabel10,
|
|
@@ -1777,25 +1883,25 @@ import {
|
|
|
1777
1883
|
} from "@elementor/editor-controls";
|
|
1778
1884
|
import { ExpandIcon, PencilIcon as PencilIcon2, ShrinkIcon } from "@elementor/icons";
|
|
1779
1885
|
import { DirectionProvider as DirectionProvider5, Grid as Grid7, ThemeProvider as ThemeProvider5 } from "@elementor/ui";
|
|
1780
|
-
import { __ as
|
|
1886
|
+
import { __ as __16 } from "@wordpress/i18n";
|
|
1781
1887
|
var DEFAULT = 1;
|
|
1782
1888
|
var items2 = [
|
|
1783
1889
|
{
|
|
1784
1890
|
value: "flex-grow",
|
|
1785
|
-
label:
|
|
1786
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1891
|
+
label: __16("Grow", "elementor"),
|
|
1892
|
+
renderContent: ({ size }) => /* @__PURE__ */ React36.createElement(ExpandIcon, { fontSize: size }),
|
|
1787
1893
|
showTooltip: true
|
|
1788
1894
|
},
|
|
1789
1895
|
{
|
|
1790
1896
|
value: "flex-shrink",
|
|
1791
|
-
label:
|
|
1792
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1897
|
+
label: __16("Shrink", "elementor"),
|
|
1898
|
+
renderContent: ({ size }) => /* @__PURE__ */ React36.createElement(ShrinkIcon, { fontSize: size }),
|
|
1793
1899
|
showTooltip: true
|
|
1794
1900
|
},
|
|
1795
1901
|
{
|
|
1796
1902
|
value: "custom",
|
|
1797
|
-
label:
|
|
1798
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1903
|
+
label: __16("Custom", "elementor"),
|
|
1904
|
+
renderContent: ({ size }) => /* @__PURE__ */ React36.createElement(PencilIcon2, { fontSize: size }),
|
|
1799
1905
|
showTooltip: true
|
|
1800
1906
|
}
|
|
1801
1907
|
];
|
|
@@ -1819,7 +1925,7 @@ var FlexSizeField = () => {
|
|
|
1819
1925
|
setGrowField(null);
|
|
1820
1926
|
setShrinkField({ $$type: "number", value: DEFAULT });
|
|
1821
1927
|
};
|
|
1822
|
-
return /* @__PURE__ */
|
|
1928
|
+
return /* @__PURE__ */ React36.createElement(DirectionProvider5, { rtl: isSiteRtl }, /* @__PURE__ */ React36.createElement(ThemeProvider5, null, /* @__PURE__ */ React36.createElement(SectionContent, null, /* @__PURE__ */ React36.createElement(Grid7, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6 }, /* @__PURE__ */ React36.createElement(ControlLabel10, null, __16("Size", "elementor"))), /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React36.createElement(
|
|
1823
1929
|
ControlToggleButtonGroup2,
|
|
1824
1930
|
{
|
|
1825
1931
|
value: activeGroup,
|
|
@@ -1827,9 +1933,9 @@ var FlexSizeField = () => {
|
|
|
1827
1933
|
items: items2,
|
|
1828
1934
|
exclusive: true
|
|
1829
1935
|
}
|
|
1830
|
-
))), "custom" === activeGroup && /* @__PURE__ */
|
|
1936
|
+
))), "custom" === activeGroup && /* @__PURE__ */ React36.createElement(FlexCustomField, null))));
|
|
1831
1937
|
};
|
|
1832
|
-
var FlexCustomField = () => /* @__PURE__ */
|
|
1938
|
+
var FlexCustomField = () => /* @__PURE__ */ React36.createElement(React36.Fragment, null, /* @__PURE__ */ React36.createElement(StylesField, { bind: "flex-grow" }, /* @__PURE__ */ React36.createElement(Grid7, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6 }, /* @__PURE__ */ React36.createElement(ControlLabel10, null, __16("Grow", "elementor"))), /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React36.createElement(NumberControl2, { min: 0, shouldForceInt: true })))), /* @__PURE__ */ React36.createElement(StylesField, { bind: "flex-shrink" }, /* @__PURE__ */ React36.createElement(Grid7, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6 }, /* @__PURE__ */ React36.createElement(ControlLabel10, null, __16("Shrink", "elementor"))), /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React36.createElement(NumberControl2, { min: 0, shouldForceInt: true })))), /* @__PURE__ */ React36.createElement(StylesField, { bind: "flex-basis" }, /* @__PURE__ */ React36.createElement(Grid7, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6 }, /* @__PURE__ */ React36.createElement(ControlLabel10, null, __16("Basis", "elementor"))), /* @__PURE__ */ React36.createElement(Grid7, { item: true, xs: 6, sx: { display: "flex", justifyContent: "end" } }, /* @__PURE__ */ React36.createElement(SizeControl2, { extendedValues: ["auto"] })))));
|
|
1833
1939
|
var getActiveGroup = ({
|
|
1834
1940
|
grow,
|
|
1835
1941
|
shrink,
|
|
@@ -1851,16 +1957,16 @@ var getActiveGroup = ({
|
|
|
1851
1957
|
};
|
|
1852
1958
|
|
|
1853
1959
|
// src/components/style-sections/layout-section/gap-control-field.tsx
|
|
1854
|
-
import * as
|
|
1960
|
+
import * as React37 from "react";
|
|
1855
1961
|
import { GapControl } from "@elementor/editor-controls";
|
|
1856
1962
|
import { Stack as Stack8 } from "@elementor/ui";
|
|
1857
|
-
import { __ as
|
|
1963
|
+
import { __ as __17 } from "@wordpress/i18n";
|
|
1858
1964
|
var GapControlField = () => {
|
|
1859
|
-
return /* @__PURE__ */
|
|
1965
|
+
return /* @__PURE__ */ React37.createElement(Stack8, { gap: 1 }, /* @__PURE__ */ React37.createElement(StylesField, { bind: "gap" }, /* @__PURE__ */ React37.createElement(GapControl, { label: __17("Gaps", "elementor") })));
|
|
1860
1966
|
};
|
|
1861
1967
|
|
|
1862
1968
|
// src/components/style-sections/layout-section/justify-content-field.tsx
|
|
1863
|
-
import * as
|
|
1969
|
+
import * as React38 from "react";
|
|
1864
1970
|
import { ControlLabel as ControlLabel11, ToggleControl as ToggleControl5 } from "@elementor/editor-controls";
|
|
1865
1971
|
import {
|
|
1866
1972
|
JustifyBottomIcon,
|
|
@@ -1871,7 +1977,7 @@ import {
|
|
|
1871
1977
|
JustifyTopIcon
|
|
1872
1978
|
} from "@elementor/icons";
|
|
1873
1979
|
import { DirectionProvider as DirectionProvider6, Stack as Stack9, ThemeProvider as ThemeProvider6, withDirection as withDirection6 } from "@elementor/ui";
|
|
1874
|
-
import { __ as
|
|
1980
|
+
import { __ as __18 } from "@wordpress/i18n";
|
|
1875
1981
|
var StartIcon3 = withDirection6(JustifyTopIcon);
|
|
1876
1982
|
var EndIcon3 = withDirection6(JustifyBottomIcon);
|
|
1877
1983
|
var iconProps3 = {
|
|
@@ -1881,75 +1987,75 @@ var iconProps3 = {
|
|
|
1881
1987
|
var options4 = [
|
|
1882
1988
|
{
|
|
1883
1989
|
value: "start",
|
|
1884
|
-
label:
|
|
1885
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1990
|
+
label: __18("Start", "elementor"),
|
|
1991
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: StartIcon3, size, ...iconProps3 }),
|
|
1886
1992
|
showTooltip: true
|
|
1887
1993
|
},
|
|
1888
1994
|
{
|
|
1889
1995
|
value: "center",
|
|
1890
|
-
label:
|
|
1891
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
1996
|
+
label: __18("Center", "elementor"),
|
|
1997
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: CenterIcon3, size, ...iconProps3 }),
|
|
1892
1998
|
showTooltip: true
|
|
1893
1999
|
},
|
|
1894
2000
|
{
|
|
1895
2001
|
value: "end",
|
|
1896
|
-
label:
|
|
1897
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2002
|
+
label: __18("End", "elementor"),
|
|
2003
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: EndIcon3, size, ...iconProps3 }),
|
|
1898
2004
|
showTooltip: true
|
|
1899
2005
|
},
|
|
1900
2006
|
{
|
|
1901
2007
|
value: "space-between",
|
|
1902
|
-
label:
|
|
1903
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2008
|
+
label: __18("Space between", "elementor"),
|
|
2009
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: BetweenIcon, size, ...iconProps3 }),
|
|
1904
2010
|
showTooltip: true
|
|
1905
2011
|
},
|
|
1906
2012
|
{
|
|
1907
2013
|
value: "space-around",
|
|
1908
|
-
label:
|
|
1909
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2014
|
+
label: __18("Space around", "elementor"),
|
|
2015
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: AroundIcon, size, ...iconProps3 }),
|
|
1910
2016
|
showTooltip: true
|
|
1911
2017
|
},
|
|
1912
2018
|
{
|
|
1913
2019
|
value: "space-evenly",
|
|
1914
|
-
label:
|
|
1915
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2020
|
+
label: __18("Space evenly", "elementor"),
|
|
2021
|
+
renderContent: ({ size }) => /* @__PURE__ */ React38.createElement(RotatedIcon, { icon: EvenlyIcon, size, ...iconProps3 }),
|
|
1916
2022
|
showTooltip: true
|
|
1917
2023
|
}
|
|
1918
2024
|
];
|
|
1919
2025
|
var JustifyContentField = () => {
|
|
1920
2026
|
const { isSiteRtl } = useDirection();
|
|
1921
|
-
return /* @__PURE__ */
|
|
2027
|
+
return /* @__PURE__ */ React38.createElement(DirectionProvider6, { rtl: isSiteRtl }, /* @__PURE__ */ React38.createElement(ThemeProvider6, null, /* @__PURE__ */ React38.createElement(StylesField, { bind: "justify-content" }, /* @__PURE__ */ React38.createElement(Stack9, { gap: 0.75 }, /* @__PURE__ */ React38.createElement(ControlLabel11, null, __18("Justify content", "elementor")), /* @__PURE__ */ React38.createElement(ToggleControl5, { options: options4, fullWidth: true })))));
|
|
1922
2028
|
};
|
|
1923
2029
|
|
|
1924
2030
|
// src/components/style-sections/layout-section/wrap-field.tsx
|
|
1925
|
-
import * as
|
|
2031
|
+
import * as React39 from "react";
|
|
1926
2032
|
import { ControlLabel as ControlLabel12, ToggleControl as ToggleControl6 } from "@elementor/editor-controls";
|
|
1927
2033
|
import { ArrowBackIcon, ArrowForwardIcon, ArrowRightIcon as ArrowRightIcon2 } from "@elementor/icons";
|
|
1928
2034
|
import { DirectionProvider as DirectionProvider7, Grid as Grid8, ThemeProvider as ThemeProvider7 } from "@elementor/ui";
|
|
1929
|
-
import { __ as
|
|
2035
|
+
import { __ as __19 } from "@wordpress/i18n";
|
|
1930
2036
|
var options5 = [
|
|
1931
2037
|
{
|
|
1932
2038
|
value: "nowrap",
|
|
1933
|
-
label:
|
|
1934
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2039
|
+
label: __19("No wrap", "elementor"),
|
|
2040
|
+
renderContent: ({ size }) => /* @__PURE__ */ React39.createElement(ArrowRightIcon2, { fontSize: size }),
|
|
1935
2041
|
showTooltip: true
|
|
1936
2042
|
},
|
|
1937
2043
|
{
|
|
1938
2044
|
value: "wrap",
|
|
1939
|
-
label:
|
|
1940
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2045
|
+
label: __19("Wrap", "elementor"),
|
|
2046
|
+
renderContent: ({ size }) => /* @__PURE__ */ React39.createElement(ArrowBackIcon, { fontSize: size }),
|
|
1941
2047
|
showTooltip: true
|
|
1942
2048
|
},
|
|
1943
2049
|
{
|
|
1944
2050
|
value: "wrap-reverse",
|
|
1945
|
-
label:
|
|
1946
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2051
|
+
label: __19("Reversed wrap", "elementor"),
|
|
2052
|
+
renderContent: ({ size }) => /* @__PURE__ */ React39.createElement(ArrowForwardIcon, { fontSize: size }),
|
|
1947
2053
|
showTooltip: true
|
|
1948
2054
|
}
|
|
1949
2055
|
];
|
|
1950
2056
|
var WrapField = () => {
|
|
1951
2057
|
const { isSiteRtl } = useDirection();
|
|
1952
|
-
return /* @__PURE__ */
|
|
2058
|
+
return /* @__PURE__ */ React39.createElement(DirectionProvider7, { rtl: isSiteRtl }, /* @__PURE__ */ React39.createElement(ThemeProvider7, null, /* @__PURE__ */ React39.createElement(StylesField, { bind: "flex-wrap" }, /* @__PURE__ */ React39.createElement(Grid8, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 6 }, /* @__PURE__ */ React39.createElement(ControlLabel12, null, __19("Wrap", "elementor"))), /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React39.createElement(ToggleControl6, { options: options5 }))))));
|
|
1953
2059
|
};
|
|
1954
2060
|
|
|
1955
2061
|
// src/components/style-sections/layout-section/layout-section.tsx
|
|
@@ -1958,62 +2064,62 @@ var LayoutSection = () => {
|
|
|
1958
2064
|
const { element } = useElement();
|
|
1959
2065
|
const parent = useParentElement(element.id);
|
|
1960
2066
|
const parentStyle = useComputedStyle(parent?.id || null);
|
|
1961
|
-
return /* @__PURE__ */
|
|
2067
|
+
return /* @__PURE__ */ React40.createElement(SectionContent, null, /* @__PURE__ */ React40.createElement(DisplayField, null), ("flex" === display?.value || "inline-flex" === display?.value) && /* @__PURE__ */ React40.createElement(FlexFields, null), "flex" === parentStyle?.display && /* @__PURE__ */ React40.createElement(FlexChildFields, null));
|
|
1962
2068
|
};
|
|
1963
|
-
var FlexFields = () => /* @__PURE__ */
|
|
1964
|
-
var FlexChildFields = () => /* @__PURE__ */
|
|
2069
|
+
var FlexFields = () => /* @__PURE__ */ React40.createElement(React40.Fragment, null, /* @__PURE__ */ React40.createElement(FlexDirectionField, null), /* @__PURE__ */ React40.createElement(JustifyContentField, null), /* @__PURE__ */ React40.createElement(AlignItemsField, null), /* @__PURE__ */ React40.createElement(PanelDivider, null), /* @__PURE__ */ React40.createElement(GapControlField, null), /* @__PURE__ */ React40.createElement(WrapField, null));
|
|
2070
|
+
var FlexChildFields = () => /* @__PURE__ */ React40.createElement(React40.Fragment, null, /* @__PURE__ */ React40.createElement(PanelDivider, null), /* @__PURE__ */ React40.createElement(ControlLabel13, null, __20("Flex child", "elementor")), /* @__PURE__ */ React40.createElement(AlignSelfChild, null), /* @__PURE__ */ React40.createElement(FlexOrderField, null), /* @__PURE__ */ React40.createElement(FlexSizeField, null));
|
|
1965
2071
|
|
|
1966
2072
|
// src/components/style-sections/position-section/position-section.tsx
|
|
1967
|
-
import * as
|
|
2073
|
+
import * as React44 from "react";
|
|
1968
2074
|
import { useSessionStorage } from "@elementor/session";
|
|
1969
2075
|
|
|
1970
2076
|
// src/components/style-sections/position-section/dimensions-field.tsx
|
|
1971
|
-
import * as
|
|
2077
|
+
import * as React41 from "react";
|
|
1972
2078
|
import { ControlLabel as ControlLabel14, SizeControl as SizeControl3 } from "@elementor/editor-controls";
|
|
1973
2079
|
import { SideBottomIcon as SideBottomIcon2, SideLeftIcon as SideLeftIcon2, SideRightIcon as SideRightIcon2, SideTopIcon as SideTopIcon2 } from "@elementor/icons";
|
|
1974
2080
|
import { Grid as Grid9, Stack as Stack10, withDirection as withDirection7 } from "@elementor/ui";
|
|
1975
|
-
import { __ as
|
|
2081
|
+
import { __ as __21 } from "@wordpress/i18n";
|
|
1976
2082
|
var InlineStartIcon2 = withDirection7(SideLeftIcon2);
|
|
1977
2083
|
var InlineEndIcon2 = withDirection7(SideRightIcon2);
|
|
1978
2084
|
var sideIcons = {
|
|
1979
|
-
"inset-block-start": /* @__PURE__ */
|
|
1980
|
-
"inset-block-end": /* @__PURE__ */
|
|
1981
|
-
"inset-inline-start": /* @__PURE__ */
|
|
1982
|
-
"inset-inline-end": /* @__PURE__ */
|
|
2085
|
+
"inset-block-start": /* @__PURE__ */ React41.createElement(SideTopIcon2, { fontSize: "tiny" }),
|
|
2086
|
+
"inset-block-end": /* @__PURE__ */ React41.createElement(SideBottomIcon2, { fontSize: "tiny" }),
|
|
2087
|
+
"inset-inline-start": /* @__PURE__ */ React41.createElement(RotatedIcon, { icon: InlineStartIcon2, size: "tiny" }),
|
|
2088
|
+
"inset-inline-end": /* @__PURE__ */ React41.createElement(RotatedIcon, { icon: InlineEndIcon2, size: "tiny" })
|
|
1983
2089
|
};
|
|
1984
|
-
var getInlineStartLabel = (isSiteRtl) => isSiteRtl ?
|
|
1985
|
-
var getInlineEndLabel = (isSiteRtl) => isSiteRtl ?
|
|
2090
|
+
var getInlineStartLabel = (isSiteRtl) => isSiteRtl ? __21("Right", "elementor") : __21("Left", "elementor");
|
|
2091
|
+
var getInlineEndLabel = (isSiteRtl) => isSiteRtl ? __21("Left", "elementor") : __21("Right", "elementor");
|
|
1986
2092
|
var DimensionsField = () => {
|
|
1987
2093
|
const { isSiteRtl } = useDirection();
|
|
1988
|
-
return /* @__PURE__ */
|
|
2094
|
+
return /* @__PURE__ */ React41.createElement(React41.Fragment, null, /* @__PURE__ */ React41.createElement(Stack10, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React41.createElement(DimensionField, { side: "inset-block-start", label: __21("Top", "elementor") }), /* @__PURE__ */ React41.createElement(DimensionField, { side: "inset-inline-end", label: getInlineEndLabel(isSiteRtl) })), /* @__PURE__ */ React41.createElement(Stack10, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React41.createElement(DimensionField, { side: "inset-block-end", label: __21("Bottom", "elementor") }), /* @__PURE__ */ React41.createElement(DimensionField, { side: "inset-inline-start", label: getInlineStartLabel(isSiteRtl) })));
|
|
1989
2095
|
};
|
|
1990
2096
|
var DimensionField = ({ side, label }) => {
|
|
1991
|
-
return /* @__PURE__ */
|
|
2097
|
+
return /* @__PURE__ */ React41.createElement(Grid9, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React41.createElement(Grid9, { item: true, xs: 12 }, /* @__PURE__ */ React41.createElement(ControlLabel14, null, label)), /* @__PURE__ */ React41.createElement(Grid9, { item: true, xs: 12 }, /* @__PURE__ */ React41.createElement(StylesField, { bind: side }, /* @__PURE__ */ React41.createElement(SizeControl3, { startIcon: sideIcons[side], extendedValues: ["auto"] }))));
|
|
1992
2098
|
};
|
|
1993
2099
|
|
|
1994
2100
|
// src/components/style-sections/position-section/position-field.tsx
|
|
1995
|
-
import * as
|
|
2101
|
+
import * as React42 from "react";
|
|
1996
2102
|
import { ControlLabel as ControlLabel15, SelectControl as SelectControl3 } from "@elementor/editor-controls";
|
|
1997
2103
|
import { Grid as Grid10 } from "@elementor/ui";
|
|
1998
|
-
import { __ as
|
|
2104
|
+
import { __ as __22 } from "@wordpress/i18n";
|
|
1999
2105
|
var positionOptions = [
|
|
2000
|
-
{ label:
|
|
2001
|
-
{ label:
|
|
2002
|
-
{ label:
|
|
2003
|
-
{ label:
|
|
2004
|
-
{ label:
|
|
2106
|
+
{ label: __22("Static", "elementor"), value: "static" },
|
|
2107
|
+
{ label: __22("Relative", "elementor"), value: "relative" },
|
|
2108
|
+
{ label: __22("Absolute", "elementor"), value: "absolute" },
|
|
2109
|
+
{ label: __22("Fixed", "elementor"), value: "fixed" },
|
|
2110
|
+
{ label: __22("Sticky", "elementor"), value: "sticky" }
|
|
2005
2111
|
];
|
|
2006
2112
|
var PositionField = ({ onChange }) => {
|
|
2007
|
-
return /* @__PURE__ */
|
|
2113
|
+
return /* @__PURE__ */ React42.createElement(StylesField, { bind: "position" }, /* @__PURE__ */ React42.createElement(Grid10, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React42.createElement(Grid10, { item: true, xs: 6 }, /* @__PURE__ */ React42.createElement(ControlLabel15, null, __22("Position", "elementor"))), /* @__PURE__ */ React42.createElement(Grid10, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React42.createElement(SelectControl3, { options: positionOptions, onChange }))));
|
|
2008
2114
|
};
|
|
2009
2115
|
|
|
2010
2116
|
// src/components/style-sections/position-section/z-index-field.tsx
|
|
2011
|
-
import * as
|
|
2117
|
+
import * as React43 from "react";
|
|
2012
2118
|
import { ControlLabel as ControlLabel16, NumberControl as NumberControl3 } from "@elementor/editor-controls";
|
|
2013
2119
|
import { Grid as Grid11 } from "@elementor/ui";
|
|
2014
|
-
import { __ as
|
|
2120
|
+
import { __ as __23 } from "@wordpress/i18n";
|
|
2015
2121
|
var ZIndexField = () => {
|
|
2016
|
-
return /* @__PURE__ */
|
|
2122
|
+
return /* @__PURE__ */ React43.createElement(StylesField, { bind: "z-index" }, /* @__PURE__ */ React43.createElement(Grid11, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React43.createElement(ControlLabel16, null, __23("Z-index", "elementor"))), /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React43.createElement(NumberControl3, null))));
|
|
2017
2123
|
};
|
|
2018
2124
|
|
|
2019
2125
|
// src/components/style-sections/position-section/position-section.tsx
|
|
@@ -2045,7 +2151,7 @@ var PositionSection = () => {
|
|
|
2045
2151
|
}
|
|
2046
2152
|
};
|
|
2047
2153
|
const isNotStatic = positionValue && positionValue?.value !== "static";
|
|
2048
|
-
return /* @__PURE__ */
|
|
2154
|
+
return /* @__PURE__ */ React44.createElement(SectionContent, null, /* @__PURE__ */ React44.createElement(PositionField, { onChange: onPositionChange }), isNotStatic ? /* @__PURE__ */ React44.createElement(React44.Fragment, null, /* @__PURE__ */ React44.createElement(DimensionsField, null), /* @__PURE__ */ React44.createElement(ZIndexField, null)) : null);
|
|
2049
2155
|
};
|
|
2050
2156
|
var usePersistDimensions = () => {
|
|
2051
2157
|
const { id: styleDefID, meta } = useStyle();
|
|
@@ -2055,93 +2161,93 @@ var usePersistDimensions = () => {
|
|
|
2055
2161
|
};
|
|
2056
2162
|
|
|
2057
2163
|
// src/components/style-sections/size-section/size-section.tsx
|
|
2058
|
-
import * as
|
|
2164
|
+
import * as React46 from "react";
|
|
2059
2165
|
import { ControlLabel as ControlLabel18, SizeControl as SizeControl4 } from "@elementor/editor-controls";
|
|
2060
2166
|
import { Grid as Grid13, Stack as Stack11 } from "@elementor/ui";
|
|
2061
|
-
import { __ as
|
|
2167
|
+
import { __ as __25 } from "@wordpress/i18n";
|
|
2062
2168
|
|
|
2063
2169
|
// src/components/style-sections/size-section/overflow-field.tsx
|
|
2064
|
-
import * as
|
|
2170
|
+
import * as React45 from "react";
|
|
2065
2171
|
import { ControlLabel as ControlLabel17, ToggleControl as ToggleControl7 } from "@elementor/editor-controls";
|
|
2066
2172
|
import { EyeIcon, EyeOffIcon, LetterAIcon } from "@elementor/icons";
|
|
2067
2173
|
import { Grid as Grid12 } from "@elementor/ui";
|
|
2068
|
-
import { __ as
|
|
2174
|
+
import { __ as __24 } from "@wordpress/i18n";
|
|
2069
2175
|
var options6 = [
|
|
2070
2176
|
{
|
|
2071
2177
|
value: "visible",
|
|
2072
|
-
label:
|
|
2073
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2178
|
+
label: __24("Visible", "elementor"),
|
|
2179
|
+
renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(EyeIcon, { fontSize: size }),
|
|
2074
2180
|
showTooltip: true
|
|
2075
2181
|
},
|
|
2076
2182
|
{
|
|
2077
2183
|
value: "hidden",
|
|
2078
|
-
label:
|
|
2079
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2184
|
+
label: __24("Hidden", "elementor"),
|
|
2185
|
+
renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(EyeOffIcon, { fontSize: size }),
|
|
2080
2186
|
showTooltip: true
|
|
2081
2187
|
},
|
|
2082
2188
|
{
|
|
2083
2189
|
value: "auto",
|
|
2084
|
-
label:
|
|
2085
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2190
|
+
label: __24("Auto", "elementor"),
|
|
2191
|
+
renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(LetterAIcon, { fontSize: size }),
|
|
2086
2192
|
showTooltip: true
|
|
2087
2193
|
}
|
|
2088
2194
|
];
|
|
2089
2195
|
var OverflowField = () => {
|
|
2090
|
-
return /* @__PURE__ */
|
|
2196
|
+
return /* @__PURE__ */ React45.createElement(StylesField, { bind: "overflow" }, /* @__PURE__ */ React45.createElement(Grid12, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React45.createElement(Grid12, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(ControlLabel17, null, __24("Overflow", "elementor"))), /* @__PURE__ */ React45.createElement(Grid12, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React45.createElement(ToggleControl7, { options: options6 }))));
|
|
2091
2197
|
};
|
|
2092
2198
|
|
|
2093
2199
|
// src/components/style-sections/size-section/size-section.tsx
|
|
2094
2200
|
var SizeSection = () => {
|
|
2095
|
-
return /* @__PURE__ */
|
|
2201
|
+
return /* @__PURE__ */ React46.createElement(SectionContent, null, /* @__PURE__ */ React46.createElement(Grid13, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(SizeField, { bind: "width", label: __25("Width", "elementor"), extendedValues: ["auto"] })), /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(SizeField, { bind: "height", label: __25("Height", "elementor"), extendedValues: ["auto"] }))), /* @__PURE__ */ React46.createElement(Grid13, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(
|
|
2096
2202
|
SizeField,
|
|
2097
2203
|
{
|
|
2098
2204
|
bind: "min-width",
|
|
2099
|
-
label:
|
|
2205
|
+
label: __25("Min width", "elementor"),
|
|
2100
2206
|
extendedValues: ["auto"]
|
|
2101
2207
|
}
|
|
2102
|
-
)), /* @__PURE__ */
|
|
2208
|
+
)), /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(
|
|
2103
2209
|
SizeField,
|
|
2104
2210
|
{
|
|
2105
2211
|
bind: "min-height",
|
|
2106
|
-
label:
|
|
2212
|
+
label: __25("Min height", "elementor"),
|
|
2107
2213
|
extendedValues: ["auto"]
|
|
2108
2214
|
}
|
|
2109
|
-
))), /* @__PURE__ */
|
|
2215
|
+
))), /* @__PURE__ */ React46.createElement(Grid13, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(SizeField, { bind: "max-width", label: __25("Max width", "elementor") })), /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(SizeField, { bind: "max-height", label: __25("Max height", "elementor") }))), /* @__PURE__ */ React46.createElement(PanelDivider, null), /* @__PURE__ */ React46.createElement(Stack11, null, /* @__PURE__ */ React46.createElement(OverflowField, null)));
|
|
2110
2216
|
};
|
|
2111
2217
|
var SizeField = ({ label, bind, extendedValues }) => {
|
|
2112
|
-
return /* @__PURE__ */
|
|
2218
|
+
return /* @__PURE__ */ React46.createElement(StylesField, { bind }, /* @__PURE__ */ React46.createElement(Grid13, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 12 }, /* @__PURE__ */ React46.createElement(ControlLabel18, null, label)), /* @__PURE__ */ React46.createElement(Grid13, { item: true, xs: 12 }, /* @__PURE__ */ React46.createElement(SizeControl4, { extendedValues }))));
|
|
2113
2219
|
};
|
|
2114
2220
|
|
|
2115
2221
|
// src/components/style-sections/spacing-section/spacing-section.tsx
|
|
2116
|
-
import * as
|
|
2222
|
+
import * as React47 from "react";
|
|
2117
2223
|
import { LinkedDimensionsControl } from "@elementor/editor-controls";
|
|
2118
|
-
import { __ as
|
|
2224
|
+
import { __ as __26 } from "@wordpress/i18n";
|
|
2119
2225
|
var SpacingSection = () => {
|
|
2120
2226
|
const { isSiteRtl } = useDirection();
|
|
2121
|
-
return /* @__PURE__ */
|
|
2227
|
+
return /* @__PURE__ */ React47.createElement(SectionContent, null, /* @__PURE__ */ React47.createElement(StylesField, { bind: "margin" }, /* @__PURE__ */ React47.createElement(
|
|
2122
2228
|
LinkedDimensionsControl,
|
|
2123
2229
|
{
|
|
2124
|
-
label:
|
|
2230
|
+
label: __26("Margin", "elementor"),
|
|
2125
2231
|
isSiteRtl,
|
|
2126
2232
|
extendedValues: ["auto"]
|
|
2127
2233
|
}
|
|
2128
|
-
)), /* @__PURE__ */
|
|
2234
|
+
)), /* @__PURE__ */ React47.createElement(PanelDivider, null), /* @__PURE__ */ React47.createElement(StylesField, { bind: "padding" }, /* @__PURE__ */ React47.createElement(LinkedDimensionsControl, { label: __26("Padding", "elementor"), isSiteRtl })));
|
|
2129
2235
|
};
|
|
2130
2236
|
|
|
2131
2237
|
// src/components/style-sections/typography-section/typography-section.tsx
|
|
2132
|
-
import * as
|
|
2238
|
+
import * as React62 from "react";
|
|
2133
2239
|
|
|
2134
2240
|
// src/components/collapsible-content.tsx
|
|
2135
|
-
import * as
|
|
2241
|
+
import * as React48 from "react";
|
|
2136
2242
|
import { useState as useState6 } from "react";
|
|
2137
2243
|
import { Button, Collapse as Collapse3, Stack as Stack12 } from "@elementor/ui";
|
|
2138
|
-
import { __ as
|
|
2244
|
+
import { __ as __27 } from "@wordpress/i18n";
|
|
2139
2245
|
var CollapsibleContent = ({ children, defaultOpen = false }) => {
|
|
2140
2246
|
const [open, setOpen] = useState6(defaultOpen);
|
|
2141
2247
|
const handleToggle = () => {
|
|
2142
2248
|
setOpen((prevOpen) => !prevOpen);
|
|
2143
2249
|
};
|
|
2144
|
-
return /* @__PURE__ */
|
|
2250
|
+
return /* @__PURE__ */ React48.createElement(Stack12, null, /* @__PURE__ */ React48.createElement(
|
|
2145
2251
|
Button,
|
|
2146
2252
|
{
|
|
2147
2253
|
fullWidth: true,
|
|
@@ -2149,22 +2255,22 @@ var CollapsibleContent = ({ children, defaultOpen = false }) => {
|
|
|
2149
2255
|
color: "secondary",
|
|
2150
2256
|
variant: "outlined",
|
|
2151
2257
|
onClick: handleToggle,
|
|
2152
|
-
endIcon: /* @__PURE__ */
|
|
2258
|
+
endIcon: /* @__PURE__ */ React48.createElement(CollapseIcon, { open }),
|
|
2153
2259
|
sx: { my: 0.5 }
|
|
2154
2260
|
},
|
|
2155
|
-
open ?
|
|
2156
|
-
), /* @__PURE__ */
|
|
2261
|
+
open ? __27("Show less", "elementor") : __27("Show more", "elementor")
|
|
2262
|
+
), /* @__PURE__ */ React48.createElement(Collapse3, { in: open, timeout: "auto", unmountOnExit: true }, children));
|
|
2157
2263
|
};
|
|
2158
2264
|
|
|
2159
2265
|
// src/components/style-sections/typography-section/font-family-field.tsx
|
|
2160
|
-
import * as
|
|
2266
|
+
import * as React49 from "react";
|
|
2161
2267
|
import { ControlLabel as ControlLabel19, FontFamilyControl } from "@elementor/editor-controls";
|
|
2162
2268
|
import { Grid as Grid14 } from "@elementor/ui";
|
|
2163
|
-
import { __ as
|
|
2269
|
+
import { __ as __29 } from "@wordpress/i18n";
|
|
2164
2270
|
|
|
2165
2271
|
// src/components/style-sections/typography-section/hooks/use-font-families.ts
|
|
2166
2272
|
import { useMemo as useMemo3 } from "react";
|
|
2167
|
-
import { __ as
|
|
2273
|
+
import { __ as __28 } from "@wordpress/i18n";
|
|
2168
2274
|
|
|
2169
2275
|
// src/sync/get-elementor-config.ts
|
|
2170
2276
|
var getElementorConfig = () => {
|
|
@@ -2174,9 +2280,9 @@ var getElementorConfig = () => {
|
|
|
2174
2280
|
|
|
2175
2281
|
// src/components/style-sections/typography-section/hooks/use-font-families.ts
|
|
2176
2282
|
var supportedCategories = {
|
|
2177
|
-
system:
|
|
2178
|
-
custom:
|
|
2179
|
-
googlefonts:
|
|
2283
|
+
system: __28("System", "elementor"),
|
|
2284
|
+
custom: __28("Custom Fonts", "elementor"),
|
|
2285
|
+
googlefonts: __28("Google Fonts", "elementor")
|
|
2180
2286
|
};
|
|
2181
2287
|
var getFontFamilies = () => {
|
|
2182
2288
|
const { controls } = getElementorConfig();
|
|
@@ -2213,188 +2319,188 @@ var FontFamilyField = () => {
|
|
|
2213
2319
|
if (fontFamilies.length === 0) {
|
|
2214
2320
|
return null;
|
|
2215
2321
|
}
|
|
2216
|
-
return /* @__PURE__ */
|
|
2322
|
+
return /* @__PURE__ */ React49.createElement(StylesField, { bind: "font-family" }, /* @__PURE__ */ React49.createElement(Grid14, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React49.createElement(Grid14, { item: true, xs: 6 }, /* @__PURE__ */ React49.createElement(ControlLabel19, null, __29("Font family", "elementor"))), /* @__PURE__ */ React49.createElement(Grid14, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React49.createElement(FontFamilyControl, { fontFamilies }))));
|
|
2217
2323
|
};
|
|
2218
2324
|
|
|
2219
2325
|
// src/components/style-sections/typography-section/font-size-field.tsx
|
|
2220
|
-
import * as
|
|
2326
|
+
import * as React50 from "react";
|
|
2221
2327
|
import { ControlLabel as ControlLabel20, SizeControl as SizeControl5 } from "@elementor/editor-controls";
|
|
2222
2328
|
import { Grid as Grid15 } from "@elementor/ui";
|
|
2223
|
-
import { __ as
|
|
2329
|
+
import { __ as __30 } from "@wordpress/i18n";
|
|
2224
2330
|
var FontSizeField = () => {
|
|
2225
|
-
return /* @__PURE__ */
|
|
2331
|
+
return /* @__PURE__ */ React50.createElement(StylesField, { bind: "font-size" }, /* @__PURE__ */ React50.createElement(Grid15, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React50.createElement(Grid15, { item: true, xs: 6 }, /* @__PURE__ */ React50.createElement(ControlLabel20, null, __30("Font size", "elementor"))), /* @__PURE__ */ React50.createElement(Grid15, { item: true, xs: 6 }, /* @__PURE__ */ React50.createElement(SizeControl5, null))));
|
|
2226
2332
|
};
|
|
2227
2333
|
|
|
2228
2334
|
// src/components/style-sections/typography-section/font-style-field.tsx
|
|
2229
|
-
import * as
|
|
2335
|
+
import * as React51 from "react";
|
|
2230
2336
|
import { ControlLabel as ControlLabel21, ToggleControl as ToggleControl8 } from "@elementor/editor-controls";
|
|
2231
2337
|
import { ItalicIcon, MinusIcon as MinusIcon2 } from "@elementor/icons";
|
|
2232
2338
|
import { Grid as Grid16 } from "@elementor/ui";
|
|
2233
|
-
import { __ as
|
|
2339
|
+
import { __ as __31 } from "@wordpress/i18n";
|
|
2234
2340
|
var options7 = [
|
|
2235
2341
|
{
|
|
2236
2342
|
value: "normal",
|
|
2237
|
-
label:
|
|
2238
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2343
|
+
label: __31("Normal", "elementor"),
|
|
2344
|
+
renderContent: ({ size }) => /* @__PURE__ */ React51.createElement(MinusIcon2, { fontSize: size }),
|
|
2239
2345
|
showTooltip: true
|
|
2240
2346
|
},
|
|
2241
2347
|
{
|
|
2242
2348
|
value: "italic",
|
|
2243
|
-
label:
|
|
2244
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2349
|
+
label: __31("Italic", "elementor"),
|
|
2350
|
+
renderContent: ({ size }) => /* @__PURE__ */ React51.createElement(ItalicIcon, { fontSize: size }),
|
|
2245
2351
|
showTooltip: true
|
|
2246
2352
|
}
|
|
2247
2353
|
];
|
|
2248
|
-
var FontStyleField = () => /* @__PURE__ */
|
|
2354
|
+
var FontStyleField = () => /* @__PURE__ */ React51.createElement(StylesField, { bind: "font-style" }, /* @__PURE__ */ React51.createElement(Grid16, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React51.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React51.createElement(ControlLabel21, null, __31("Font style", "elementor"))), /* @__PURE__ */ React51.createElement(Grid16, { item: true, xs: 6, display: "flex", justifyContent: "end" }, /* @__PURE__ */ React51.createElement(ToggleControl8, { options: options7 }))));
|
|
2249
2355
|
|
|
2250
2356
|
// src/components/style-sections/typography-section/font-weight-field.tsx
|
|
2251
|
-
import * as
|
|
2357
|
+
import * as React52 from "react";
|
|
2252
2358
|
import { ControlLabel as ControlLabel22, SelectControl as SelectControl4 } from "@elementor/editor-controls";
|
|
2253
2359
|
import { Grid as Grid17 } from "@elementor/ui";
|
|
2254
|
-
import { __ as
|
|
2360
|
+
import { __ as __32 } from "@wordpress/i18n";
|
|
2255
2361
|
var fontWeightOptions = [
|
|
2256
|
-
{ value: "100", label:
|
|
2257
|
-
{ value: "200", label:
|
|
2258
|
-
{ value: "300", label:
|
|
2259
|
-
{ value: "400", label:
|
|
2260
|
-
{ value: "500", label:
|
|
2261
|
-
{ value: "600", label:
|
|
2262
|
-
{ value: "700", label:
|
|
2263
|
-
{ value: "800", label:
|
|
2264
|
-
{ value: "900", label:
|
|
2362
|
+
{ value: "100", label: __32("100 - Thin", "elementor") },
|
|
2363
|
+
{ value: "200", label: __32("200 - Extra light", "elementor") },
|
|
2364
|
+
{ value: "300", label: __32("300 - Light", "elementor") },
|
|
2365
|
+
{ value: "400", label: __32("400 - Normal", "elementor") },
|
|
2366
|
+
{ value: "500", label: __32("500 - Medium", "elementor") },
|
|
2367
|
+
{ value: "600", label: __32("600 - Semi bold", "elementor") },
|
|
2368
|
+
{ value: "700", label: __32("700 - Bold", "elementor") },
|
|
2369
|
+
{ value: "800", label: __32("800 - Extra bold", "elementor") },
|
|
2370
|
+
{ value: "900", label: __32("900 - Black", "elementor") }
|
|
2265
2371
|
];
|
|
2266
2372
|
var FontWeightField = () => {
|
|
2267
|
-
return /* @__PURE__ */
|
|
2373
|
+
return /* @__PURE__ */ React52.createElement(StylesField, { bind: "font-weight" }, /* @__PURE__ */ React52.createElement(Grid17, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React52.createElement(Grid17, { item: true, xs: 6 }, /* @__PURE__ */ React52.createElement(ControlLabel22, null, __32("Font weight", "elementor"))), /* @__PURE__ */ React52.createElement(Grid17, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React52.createElement(SelectControl4, { options: fontWeightOptions }))));
|
|
2268
2374
|
};
|
|
2269
2375
|
|
|
2270
2376
|
// src/components/style-sections/typography-section/letter-spacing-field.tsx
|
|
2271
|
-
import * as
|
|
2377
|
+
import * as React53 from "react";
|
|
2272
2378
|
import { ControlLabel as ControlLabel23, SizeControl as SizeControl6 } from "@elementor/editor-controls";
|
|
2273
2379
|
import { Grid as Grid18 } from "@elementor/ui";
|
|
2274
|
-
import { __ as
|
|
2380
|
+
import { __ as __33 } from "@wordpress/i18n";
|
|
2275
2381
|
var LetterSpacingField = () => {
|
|
2276
|
-
return /* @__PURE__ */
|
|
2382
|
+
return /* @__PURE__ */ React53.createElement(StylesField, { bind: "letter-spacing" }, /* @__PURE__ */ React53.createElement(Grid18, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React53.createElement(Grid18, { item: true, xs: 6 }, /* @__PURE__ */ React53.createElement(ControlLabel23, null, __33("Letter spacing", "elementor"))), /* @__PURE__ */ React53.createElement(Grid18, { item: true, xs: 6 }, /* @__PURE__ */ React53.createElement(SizeControl6, null))));
|
|
2277
2383
|
};
|
|
2278
2384
|
|
|
2279
2385
|
// src/components/style-sections/typography-section/line-height-field.tsx
|
|
2280
|
-
import * as
|
|
2386
|
+
import * as React54 from "react";
|
|
2281
2387
|
import { ControlLabel as ControlLabel24, SizeControl as SizeControl7 } from "@elementor/editor-controls";
|
|
2282
2388
|
import { Grid as Grid19 } from "@elementor/ui";
|
|
2283
|
-
import { __ as
|
|
2389
|
+
import { __ as __34 } from "@wordpress/i18n";
|
|
2284
2390
|
var LineHeightField = () => {
|
|
2285
|
-
return /* @__PURE__ */
|
|
2391
|
+
return /* @__PURE__ */ React54.createElement(StylesField, { bind: "line-height" }, /* @__PURE__ */ React54.createElement(Grid19, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React54.createElement(Grid19, { item: true, xs: 6 }, /* @__PURE__ */ React54.createElement(ControlLabel24, null, __34("Line height", "elementor"))), /* @__PURE__ */ React54.createElement(Grid19, { item: true, xs: 6 }, /* @__PURE__ */ React54.createElement(SizeControl7, null))));
|
|
2286
2392
|
};
|
|
2287
2393
|
|
|
2288
2394
|
// src/components/style-sections/typography-section/text-alignment-field.tsx
|
|
2289
|
-
import * as
|
|
2395
|
+
import * as React55 from "react";
|
|
2290
2396
|
import { ControlLabel as ControlLabel25, ToggleControl as ToggleControl9 } from "@elementor/editor-controls";
|
|
2291
2397
|
import { AlignCenterIcon, AlignJustifiedIcon, AlignLeftIcon, AlignRightIcon } from "@elementor/icons";
|
|
2292
2398
|
import { Grid as Grid20, withDirection as withDirection8 } from "@elementor/ui";
|
|
2293
|
-
import { __ as
|
|
2399
|
+
import { __ as __35 } from "@wordpress/i18n";
|
|
2294
2400
|
var StartIcon4 = withDirection8(AlignLeftIcon);
|
|
2295
2401
|
var EndIcon4 = withDirection8(AlignRightIcon);
|
|
2296
2402
|
var options8 = [
|
|
2297
2403
|
{
|
|
2298
2404
|
value: "start",
|
|
2299
|
-
label:
|
|
2300
|
-
renderContent: () => /* @__PURE__ */
|
|
2405
|
+
label: __35("Start", "elementor"),
|
|
2406
|
+
renderContent: () => /* @__PURE__ */ React55.createElement(RotatedIcon, { icon: StartIcon4, size: "tiny" }),
|
|
2301
2407
|
showTooltip: true
|
|
2302
2408
|
},
|
|
2303
2409
|
{
|
|
2304
2410
|
value: "center",
|
|
2305
|
-
label:
|
|
2306
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2411
|
+
label: __35("Center", "elementor"),
|
|
2412
|
+
renderContent: ({ size }) => /* @__PURE__ */ React55.createElement(AlignCenterIcon, { fontSize: size }),
|
|
2307
2413
|
showTooltip: true
|
|
2308
2414
|
},
|
|
2309
2415
|
{
|
|
2310
2416
|
value: "end",
|
|
2311
|
-
label:
|
|
2312
|
-
renderContent: () => /* @__PURE__ */
|
|
2417
|
+
label: __35("End", "elementor"),
|
|
2418
|
+
renderContent: () => /* @__PURE__ */ React55.createElement(RotatedIcon, { icon: EndIcon4, size: "tiny" }),
|
|
2313
2419
|
showTooltip: true
|
|
2314
2420
|
},
|
|
2315
2421
|
{
|
|
2316
2422
|
value: "justify",
|
|
2317
|
-
label:
|
|
2318
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2423
|
+
label: __35("Justify", "elementor"),
|
|
2424
|
+
renderContent: ({ size }) => /* @__PURE__ */ React55.createElement(AlignJustifiedIcon, { fontSize: size }),
|
|
2319
2425
|
showTooltip: true
|
|
2320
2426
|
}
|
|
2321
2427
|
];
|
|
2322
2428
|
var TextAlignmentField = () => {
|
|
2323
|
-
return /* @__PURE__ */
|
|
2429
|
+
return /* @__PURE__ */ React55.createElement(StylesField, { bind: "text-align" }, /* @__PURE__ */ React55.createElement(Grid20, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React55.createElement(Grid20, { item: true, xs: 6 }, /* @__PURE__ */ React55.createElement(ControlLabel25, null, __35("Alignment", "elementor"))), /* @__PURE__ */ React55.createElement(Grid20, { item: true, xs: 6, display: "flex", justifyContent: "end" }, /* @__PURE__ */ React55.createElement(ToggleControl9, { options: options8 }))));
|
|
2324
2430
|
};
|
|
2325
2431
|
|
|
2326
2432
|
// src/components/style-sections/typography-section/text-color-field.tsx
|
|
2327
|
-
import * as
|
|
2433
|
+
import * as React56 from "react";
|
|
2328
2434
|
import { ColorControl as ColorControl2, ControlLabel as ControlLabel26 } from "@elementor/editor-controls";
|
|
2329
2435
|
import { Grid as Grid21 } from "@elementor/ui";
|
|
2330
|
-
import { __ as
|
|
2436
|
+
import { __ as __36 } from "@wordpress/i18n";
|
|
2331
2437
|
var TextColorField = () => {
|
|
2332
|
-
return /* @__PURE__ */
|
|
2438
|
+
return /* @__PURE__ */ React56.createElement(StylesField, { bind: "color" }, /* @__PURE__ */ React56.createElement(Grid21, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React56.createElement(Grid21, { item: true, xs: 6 }, /* @__PURE__ */ React56.createElement(ControlLabel26, null, __36("Text color", "elementor"))), /* @__PURE__ */ React56.createElement(Grid21, { item: true, xs: 6 }, /* @__PURE__ */ React56.createElement(ColorControl2, null))));
|
|
2333
2439
|
};
|
|
2334
2440
|
|
|
2335
2441
|
// src/components/style-sections/typography-section/text-decoration-field.tsx
|
|
2336
|
-
import * as
|
|
2442
|
+
import * as React57 from "react";
|
|
2337
2443
|
import { ControlLabel as ControlLabel27, ToggleControl as ToggleControl10 } from "@elementor/editor-controls";
|
|
2338
2444
|
import { MinusIcon as MinusIcon3, OverlineIcon, StrikethroughIcon, UnderlineIcon } from "@elementor/icons";
|
|
2339
2445
|
import { Grid as Grid22 } from "@elementor/ui";
|
|
2340
|
-
import { __ as
|
|
2446
|
+
import { __ as __37 } from "@wordpress/i18n";
|
|
2341
2447
|
var options9 = [
|
|
2342
2448
|
{
|
|
2343
2449
|
value: "none",
|
|
2344
|
-
label:
|
|
2345
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2450
|
+
label: __37("None", "elementor"),
|
|
2451
|
+
renderContent: ({ size }) => /* @__PURE__ */ React57.createElement(MinusIcon3, { fontSize: size }),
|
|
2346
2452
|
showTooltip: true,
|
|
2347
2453
|
exclusive: true
|
|
2348
2454
|
},
|
|
2349
2455
|
{
|
|
2350
2456
|
value: "underline",
|
|
2351
|
-
label:
|
|
2352
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2457
|
+
label: __37("Underline", "elementor"),
|
|
2458
|
+
renderContent: ({ size }) => /* @__PURE__ */ React57.createElement(UnderlineIcon, { fontSize: size }),
|
|
2353
2459
|
showTooltip: true
|
|
2354
2460
|
},
|
|
2355
2461
|
{
|
|
2356
2462
|
value: "line-through",
|
|
2357
|
-
label:
|
|
2358
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2463
|
+
label: __37("Line-through", "elementor"),
|
|
2464
|
+
renderContent: ({ size }) => /* @__PURE__ */ React57.createElement(StrikethroughIcon, { fontSize: size }),
|
|
2359
2465
|
showTooltip: true
|
|
2360
2466
|
},
|
|
2361
2467
|
{
|
|
2362
2468
|
value: "overline",
|
|
2363
|
-
label:
|
|
2364
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2469
|
+
label: __37("Overline", "elementor"),
|
|
2470
|
+
renderContent: ({ size }) => /* @__PURE__ */ React57.createElement(OverlineIcon, { fontSize: size }),
|
|
2365
2471
|
showTooltip: true
|
|
2366
2472
|
}
|
|
2367
2473
|
];
|
|
2368
|
-
var TextDecorationField = () => /* @__PURE__ */
|
|
2474
|
+
var TextDecorationField = () => /* @__PURE__ */ React57.createElement(StylesField, { bind: "text-decoration" }, /* @__PURE__ */ React57.createElement(Grid22, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React57.createElement(Grid22, { item: true, xs: 6 }, /* @__PURE__ */ React57.createElement(ControlLabel27, null, __37("Line decoration", "elementor"))), /* @__PURE__ */ React57.createElement(Grid22, { item: true, xs: 6, display: "flex", justifyContent: "end" }, /* @__PURE__ */ React57.createElement(ToggleControl10, { options: options9, exclusive: false }))));
|
|
2369
2475
|
|
|
2370
2476
|
// src/components/style-sections/typography-section/text-direction-field.tsx
|
|
2371
|
-
import * as
|
|
2477
|
+
import * as React58 from "react";
|
|
2372
2478
|
import { ControlLabel as ControlLabel28, ToggleControl as ToggleControl11 } from "@elementor/editor-controls";
|
|
2373
2479
|
import { TextDirectionLtrIcon, TextDirectionRtlIcon } from "@elementor/icons";
|
|
2374
2480
|
import { Grid as Grid23 } from "@elementor/ui";
|
|
2375
|
-
import { __ as
|
|
2481
|
+
import { __ as __38 } from "@wordpress/i18n";
|
|
2376
2482
|
var options10 = [
|
|
2377
2483
|
{
|
|
2378
2484
|
value: "ltr",
|
|
2379
|
-
label:
|
|
2380
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2485
|
+
label: __38("Left to right", "elementor"),
|
|
2486
|
+
renderContent: ({ size }) => /* @__PURE__ */ React58.createElement(TextDirectionLtrIcon, { fontSize: size }),
|
|
2381
2487
|
showTooltip: true
|
|
2382
2488
|
},
|
|
2383
2489
|
{
|
|
2384
2490
|
value: "rtl",
|
|
2385
|
-
label:
|
|
2386
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2491
|
+
label: __38("Right to left", "elementor"),
|
|
2492
|
+
renderContent: ({ size }) => /* @__PURE__ */ React58.createElement(TextDirectionRtlIcon, { fontSize: size }),
|
|
2387
2493
|
showTooltip: true
|
|
2388
2494
|
}
|
|
2389
2495
|
];
|
|
2390
2496
|
var TextDirectionField = () => {
|
|
2391
|
-
return /* @__PURE__ */
|
|
2497
|
+
return /* @__PURE__ */ React58.createElement(StylesField, { bind: "direction" }, /* @__PURE__ */ React58.createElement(Grid23, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React58.createElement(Grid23, { item: true, xs: 6 }, /* @__PURE__ */ React58.createElement(ControlLabel28, null, __38("Direction", "elementor"))), /* @__PURE__ */ React58.createElement(Grid23, { item: true, xs: 6, display: "flex", justifyContent: "end" }, /* @__PURE__ */ React58.createElement(ToggleControl11, { options: options10 }))));
|
|
2392
2498
|
};
|
|
2393
2499
|
|
|
2394
2500
|
// src/components/style-sections/typography-section/text-stroke-field.tsx
|
|
2395
|
-
import * as
|
|
2501
|
+
import * as React59 from "react";
|
|
2396
2502
|
import { StrokeControl } from "@elementor/editor-controls";
|
|
2397
|
-
import { __ as
|
|
2503
|
+
import { __ as __39 } from "@wordpress/i18n";
|
|
2398
2504
|
var initTextStroke = {
|
|
2399
2505
|
$$type: "stroke",
|
|
2400
2506
|
value: {
|
|
@@ -2420,64 +2526,64 @@ var TextStrokeField = () => {
|
|
|
2420
2526
|
setTextStroke(null);
|
|
2421
2527
|
};
|
|
2422
2528
|
const hasTextStroke = Boolean(textStroke);
|
|
2423
|
-
return /* @__PURE__ */
|
|
2529
|
+
return /* @__PURE__ */ React59.createElement(
|
|
2424
2530
|
AddOrRemoveContent,
|
|
2425
2531
|
{
|
|
2426
|
-
label:
|
|
2532
|
+
label: __39("Text stroke", "elementor"),
|
|
2427
2533
|
isAdded: hasTextStroke,
|
|
2428
2534
|
onAdd: addTextStroke,
|
|
2429
2535
|
onRemove: removeTextStroke
|
|
2430
2536
|
},
|
|
2431
|
-
/* @__PURE__ */
|
|
2537
|
+
/* @__PURE__ */ React59.createElement(StylesField, { bind: "stroke" }, /* @__PURE__ */ React59.createElement(StrokeControl, null))
|
|
2432
2538
|
);
|
|
2433
2539
|
};
|
|
2434
2540
|
|
|
2435
2541
|
// src/components/style-sections/typography-section/transform-field.tsx
|
|
2436
|
-
import * as
|
|
2542
|
+
import * as React60 from "react";
|
|
2437
2543
|
import { ControlLabel as ControlLabel29, ToggleControl as ToggleControl12 } from "@elementor/editor-controls";
|
|
2438
2544
|
import { LetterCaseIcon, LetterCaseLowerIcon, LetterCaseUpperIcon, MinusIcon as MinusIcon4 } from "@elementor/icons";
|
|
2439
2545
|
import { Grid as Grid24 } from "@elementor/ui";
|
|
2440
|
-
import { __ as
|
|
2546
|
+
import { __ as __40 } from "@wordpress/i18n";
|
|
2441
2547
|
var options11 = [
|
|
2442
2548
|
{
|
|
2443
2549
|
value: "none",
|
|
2444
|
-
label:
|
|
2445
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2550
|
+
label: __40("None", "elementor"),
|
|
2551
|
+
renderContent: ({ size }) => /* @__PURE__ */ React60.createElement(MinusIcon4, { fontSize: size }),
|
|
2446
2552
|
showTooltip: true
|
|
2447
2553
|
},
|
|
2448
2554
|
{
|
|
2449
2555
|
value: "capitalize",
|
|
2450
|
-
label:
|
|
2451
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2556
|
+
label: __40("Capitalize", "elementor"),
|
|
2557
|
+
renderContent: ({ size }) => /* @__PURE__ */ React60.createElement(LetterCaseIcon, { fontSize: size }),
|
|
2452
2558
|
showTooltip: true
|
|
2453
2559
|
},
|
|
2454
2560
|
{
|
|
2455
2561
|
value: "uppercase",
|
|
2456
|
-
label:
|
|
2457
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2562
|
+
label: __40("Uppercase", "elementor"),
|
|
2563
|
+
renderContent: ({ size }) => /* @__PURE__ */ React60.createElement(LetterCaseUpperIcon, { fontSize: size }),
|
|
2458
2564
|
showTooltip: true
|
|
2459
2565
|
},
|
|
2460
2566
|
{
|
|
2461
2567
|
value: "lowercase",
|
|
2462
|
-
label:
|
|
2463
|
-
renderContent: ({ size }) => /* @__PURE__ */
|
|
2568
|
+
label: __40("Lowercase", "elementor"),
|
|
2569
|
+
renderContent: ({ size }) => /* @__PURE__ */ React60.createElement(LetterCaseLowerIcon, { fontSize: size }),
|
|
2464
2570
|
showTooltip: true
|
|
2465
2571
|
}
|
|
2466
2572
|
];
|
|
2467
|
-
var TransformField = () => /* @__PURE__ */
|
|
2573
|
+
var TransformField = () => /* @__PURE__ */ React60.createElement(StylesField, { bind: "text-transform" }, /* @__PURE__ */ React60.createElement(Grid24, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React60.createElement(Grid24, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(ControlLabel29, null, __40("Text transform", "elementor"))), /* @__PURE__ */ React60.createElement(Grid24, { item: true, xs: 6, display: "flex", justifyContent: "end" }, /* @__PURE__ */ React60.createElement(ToggleControl12, { options: options11 }))));
|
|
2468
2574
|
|
|
2469
2575
|
// src/components/style-sections/typography-section/word-spacing-field.tsx
|
|
2470
|
-
import * as
|
|
2576
|
+
import * as React61 from "react";
|
|
2471
2577
|
import { ControlLabel as ControlLabel30, SizeControl as SizeControl8 } from "@elementor/editor-controls";
|
|
2472
2578
|
import { Grid as Grid25 } from "@elementor/ui";
|
|
2473
|
-
import { __ as
|
|
2579
|
+
import { __ as __41 } from "@wordpress/i18n";
|
|
2474
2580
|
var WordSpacingField = () => {
|
|
2475
|
-
return /* @__PURE__ */
|
|
2581
|
+
return /* @__PURE__ */ React61.createElement(StylesField, { bind: "word-spacing" }, /* @__PURE__ */ React61.createElement(Grid25, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React61.createElement(Grid25, { item: true, xs: 6 }, /* @__PURE__ */ React61.createElement(ControlLabel30, null, __41("Word spacing", "elementor"))), /* @__PURE__ */ React61.createElement(Grid25, { item: true, xs: 6 }, /* @__PURE__ */ React61.createElement(SizeControl8, null))));
|
|
2476
2582
|
};
|
|
2477
2583
|
|
|
2478
2584
|
// src/components/style-sections/typography-section/typography-section.tsx
|
|
2479
2585
|
var TypographySection = () => {
|
|
2480
|
-
return /* @__PURE__ */
|
|
2586
|
+
return /* @__PURE__ */ React62.createElement(SectionContent, null, /* @__PURE__ */ React62.createElement(FontFamilyField, null), /* @__PURE__ */ React62.createElement(FontWeightField, null), /* @__PURE__ */ React62.createElement(FontSizeField, null), /* @__PURE__ */ React62.createElement(PanelDivider, null), /* @__PURE__ */ React62.createElement(TextAlignmentField, null), /* @__PURE__ */ React62.createElement(TextColorField, null), /* @__PURE__ */ React62.createElement(CollapsibleContent, null, /* @__PURE__ */ React62.createElement(SectionContent, { sx: { pt: 2 } }, /* @__PURE__ */ React62.createElement(LineHeightField, null), /* @__PURE__ */ React62.createElement(LetterSpacingField, null), /* @__PURE__ */ React62.createElement(WordSpacingField, null), /* @__PURE__ */ React62.createElement(PanelDivider, null), /* @__PURE__ */ React62.createElement(TextDecorationField, null), /* @__PURE__ */ React62.createElement(TransformField, null), /* @__PURE__ */ React62.createElement(TextDirectionField, null), /* @__PURE__ */ React62.createElement(FontStyleField, null), /* @__PURE__ */ React62.createElement(TextStrokeField, null))));
|
|
2481
2587
|
};
|
|
2482
2588
|
|
|
2483
2589
|
// src/components/style-tab.tsx
|
|
@@ -2486,7 +2592,7 @@ var StyleTab = () => {
|
|
|
2486
2592
|
const [activeStyleDefId, setActiveStyleDefId] = useActiveStyleDefId(currentClassesProp);
|
|
2487
2593
|
const [activeStyleState, setActiveStyleState] = useState7(null);
|
|
2488
2594
|
const breakpoint = useActiveBreakpoint();
|
|
2489
|
-
return /* @__PURE__ */
|
|
2595
|
+
return /* @__PURE__ */ React63.createElement(ClassesPropProvider, { prop: currentClassesProp }, /* @__PURE__ */ React63.createElement(
|
|
2490
2596
|
StyleProvider,
|
|
2491
2597
|
{
|
|
2492
2598
|
meta: { breakpoint, state: activeStyleState },
|
|
@@ -2497,7 +2603,7 @@ var StyleTab = () => {
|
|
|
2497
2603
|
},
|
|
2498
2604
|
setMetaState: setActiveStyleState
|
|
2499
2605
|
},
|
|
2500
|
-
/* @__PURE__ */
|
|
2606
|
+
/* @__PURE__ */ React63.createElement(SessionStorageProvider2, { prefix: activeStyleDefId ?? "" }, /* @__PURE__ */ React63.createElement(StyleInheritanceProvider, null, /* @__PURE__ */ React63.createElement(CssClassSelector, null), /* @__PURE__ */ React63.createElement(Divider4, null), /* @__PURE__ */ React63.createElement(SectionsList, null, /* @__PURE__ */ React63.createElement(Section, { title: __42("Layout", "elementor") }, /* @__PURE__ */ React63.createElement(LayoutSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Spacing", "elementor") }, /* @__PURE__ */ React63.createElement(SpacingSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Size", "elementor") }, /* @__PURE__ */ React63.createElement(SizeSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Position", "elementor") }, /* @__PURE__ */ React63.createElement(PositionSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Typography", "elementor") }, /* @__PURE__ */ React63.createElement(TypographySection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Background", "elementor") }, /* @__PURE__ */ React63.createElement(BackgroundSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Border", "elementor") }, /* @__PURE__ */ React63.createElement(BorderSection, null)), /* @__PURE__ */ React63.createElement(Section, { title: __42("Effects", "elementor") }, /* @__PURE__ */ React63.createElement(EffectsSection, null)))))
|
|
2501
2607
|
));
|
|
2502
2608
|
};
|
|
2503
2609
|
function useActiveStyleDefId(currentClassesProp) {
|
|
@@ -2529,7 +2635,7 @@ var EditingPanelTabs = () => {
|
|
|
2529
2635
|
return (
|
|
2530
2636
|
// When switching between elements, the local states should be reset. We are using key to rerender the tabs.
|
|
2531
2637
|
// Reference: https://react.dev/learn/preserving-and-resetting-state#resetting-a-form-with-a-key
|
|
2532
|
-
/* @__PURE__ */
|
|
2638
|
+
/* @__PURE__ */ React64.createElement(Fragment8, { key: element.id }, /* @__PURE__ */ React64.createElement(Stack13, { direction: "column", sx: { width: "100%" } }, /* @__PURE__ */ React64.createElement(Tabs, { variant: "fullWidth", indicatorColor: "secondary", textColor: "inherit", ...getTabsProps() }, /* @__PURE__ */ React64.createElement(Tab, { label: __43("General", "elementor"), ...getTabProps("settings") }), /* @__PURE__ */ React64.createElement(Tab, { label: __43("Style", "elementor"), ...getTabProps("style") })), /* @__PURE__ */ React64.createElement(Divider5, null), /* @__PURE__ */ React64.createElement(TabPanel, { ...getTabPanelProps("settings"), disablePadding: true }, /* @__PURE__ */ React64.createElement(SettingsTab, null)), /* @__PURE__ */ React64.createElement(TabPanel, { ...getTabPanelProps("style"), disablePadding: true }, /* @__PURE__ */ React64.createElement(StyleTab, null))))
|
|
2533
2639
|
);
|
|
2534
2640
|
};
|
|
2535
2641
|
|
|
@@ -2542,8 +2648,8 @@ var EditingPanel = () => {
|
|
|
2542
2648
|
if (!element || !elementType) {
|
|
2543
2649
|
return null;
|
|
2544
2650
|
}
|
|
2545
|
-
const panelTitle =
|
|
2546
|
-
return /* @__PURE__ */
|
|
2651
|
+
const panelTitle = __44("Edit %s", "elementor").replace("%s", elementType.title);
|
|
2652
|
+
return /* @__PURE__ */ React65.createElement(ErrorBoundary, { fallback: /* @__PURE__ */ React65.createElement(EditorPanelErrorFallback, null) }, /* @__PURE__ */ React65.createElement(SessionStorageProvider3, { prefix: "elementor" }, /* @__PURE__ */ React65.createElement(Panel, null, /* @__PURE__ */ React65.createElement(PanelHeader, null, /* @__PURE__ */ React65.createElement(PanelHeaderTitle, null, panelTitle), /* @__PURE__ */ React65.createElement(AtomIcon, { fontSize: "small", sx: { color: "text.tertiary" } })), /* @__PURE__ */ React65.createElement(PanelBody, null, /* @__PURE__ */ React65.createElement(ControlActionsProvider, { items: menuItems }, /* @__PURE__ */ React65.createElement(ControlReplacementProvider, { ...controlReplacement }, /* @__PURE__ */ React65.createElement(ElementProvider, { element, elementType }, /* @__PURE__ */ React65.createElement(EditingPanelTabs, null))))))));
|
|
2547
2653
|
};
|
|
2548
2654
|
|
|
2549
2655
|
// src/panel.ts
|
|
@@ -2563,10 +2669,10 @@ import { useEffect as useEffect2 } from "react";
|
|
|
2563
2669
|
import { __privateListenTo as listenTo, commandStartEvent } from "@elementor/editor-v1-adapters";
|
|
2564
2670
|
|
|
2565
2671
|
// src/sync/is-atomic-widget-selected.ts
|
|
2566
|
-
import { getSelectedElements, getWidgetsCache } from "@elementor/editor-elements";
|
|
2672
|
+
import { getSelectedElements, getWidgetsCache as getWidgetsCache2 } from "@elementor/editor-elements";
|
|
2567
2673
|
var isAtomicWidgetSelected = () => {
|
|
2568
2674
|
const selectedElements = getSelectedElements();
|
|
2569
|
-
const widgetCache =
|
|
2675
|
+
const widgetCache = getWidgetsCache2();
|
|
2570
2676
|
if (selectedElements.length !== 1) {
|
|
2571
2677
|
return false;
|
|
2572
2678
|
}
|
|
@@ -2592,9 +2698,9 @@ var EditingPanelHooks = () => {
|
|
|
2592
2698
|
};
|
|
2593
2699
|
|
|
2594
2700
|
// src/dynamics/components/dynamic-selection-control.tsx
|
|
2595
|
-
import * as
|
|
2701
|
+
import * as React69 from "react";
|
|
2596
2702
|
import { useId as useId4 } from "react";
|
|
2597
|
-
import { ControlLabel as ControlLabel31, useBoundProp as
|
|
2703
|
+
import { ControlLabel as ControlLabel31, useBoundProp as useBoundProp5 } from "@elementor/editor-controls";
|
|
2598
2704
|
import { DatabaseIcon as DatabaseIcon2, SettingsIcon, XIcon as XIcon2 } from "@elementor/icons";
|
|
2599
2705
|
import {
|
|
2600
2706
|
bindPopover as bindPopover2,
|
|
@@ -2614,12 +2720,12 @@ import {
|
|
|
2614
2720
|
usePopupState as usePopupState3,
|
|
2615
2721
|
useTabs as useTabs2
|
|
2616
2722
|
} from "@elementor/ui";
|
|
2617
|
-
import { __ as
|
|
2723
|
+
import { __ as __46 } from "@wordpress/i18n";
|
|
2618
2724
|
|
|
2619
2725
|
// src/components/popover-content.tsx
|
|
2620
|
-
import * as
|
|
2726
|
+
import * as React66 from "react";
|
|
2621
2727
|
import { Stack as Stack14 } from "@elementor/ui";
|
|
2622
|
-
var PopoverContent = ({ alignItems, gap = 1.5, p, children }) => /* @__PURE__ */
|
|
2728
|
+
var PopoverContent = ({ alignItems, gap = 1.5, p, children }) => /* @__PURE__ */ React66.createElement(Stack14, { alignItems, gap, p }, children);
|
|
2623
2729
|
|
|
2624
2730
|
// src/hooks/use-persist-dynamic-value.ts
|
|
2625
2731
|
import { useSessionStorage as useSessionStorage2 } from "@elementor/session";
|
|
@@ -2630,15 +2736,15 @@ var usePersistDynamicValue = (propKey) => {
|
|
|
2630
2736
|
};
|
|
2631
2737
|
|
|
2632
2738
|
// src/dynamics/dynamic-control.tsx
|
|
2633
|
-
import * as
|
|
2634
|
-
import { PropKeyProvider as PropKeyProvider3, PropProvider as PropProvider3, useBoundProp as
|
|
2739
|
+
import * as React67 from "react";
|
|
2740
|
+
import { PropKeyProvider as PropKeyProvider3, PropProvider as PropProvider3, useBoundProp as useBoundProp3 } from "@elementor/editor-controls";
|
|
2635
2741
|
|
|
2636
2742
|
// src/dynamics/hooks/use-dynamic-tag.ts
|
|
2637
2743
|
import { useMemo as useMemo5 } from "react";
|
|
2638
2744
|
|
|
2639
2745
|
// src/dynamics/hooks/use-prop-dynamic-tags.ts
|
|
2640
2746
|
import { useMemo as useMemo4 } from "react";
|
|
2641
|
-
import { useBoundProp } from "@elementor/editor-controls";
|
|
2747
|
+
import { useBoundProp as useBoundProp2 } from "@elementor/editor-controls";
|
|
2642
2748
|
|
|
2643
2749
|
// src/dynamics/sync/get-elementor-config.ts
|
|
2644
2750
|
var getElementorConfig2 = () => {
|
|
@@ -2687,7 +2793,7 @@ var dynamicPropTypeUtil = createPropUtils(
|
|
|
2687
2793
|
// src/dynamics/hooks/use-prop-dynamic-tags.ts
|
|
2688
2794
|
var usePropDynamicTags = () => {
|
|
2689
2795
|
let categories = [];
|
|
2690
|
-
const { propType } =
|
|
2796
|
+
const { propType } = useBoundProp2();
|
|
2691
2797
|
if (propType) {
|
|
2692
2798
|
const propDynamicType = getDynamicPropType(propType);
|
|
2693
2799
|
categories = propDynamicType?.settings.categories || [];
|
|
@@ -2713,7 +2819,7 @@ var useDynamicTag = (tagName) => {
|
|
|
2713
2819
|
|
|
2714
2820
|
// src/dynamics/dynamic-control.tsx
|
|
2715
2821
|
var DynamicControl = ({ bind, children }) => {
|
|
2716
|
-
const { value, setValue } =
|
|
2822
|
+
const { value, setValue } = useBoundProp3(dynamicPropTypeUtil);
|
|
2717
2823
|
const { name = "", settings } = value ?? {};
|
|
2718
2824
|
const dynamicTag = useDynamicTag(name);
|
|
2719
2825
|
if (!dynamicTag) {
|
|
@@ -2732,13 +2838,13 @@ var DynamicControl = ({ bind, children }) => {
|
|
|
2732
2838
|
});
|
|
2733
2839
|
};
|
|
2734
2840
|
const propType = createTopLevelOjectType({ schema: dynamicTag.props_schema });
|
|
2735
|
-
return /* @__PURE__ */
|
|
2841
|
+
return /* @__PURE__ */ React67.createElement(PropProvider3, { propType, setValue: setDynamicValue, value: { [bind]: dynamicValue } }, /* @__PURE__ */ React67.createElement(PropKeyProvider3, { bind }, children));
|
|
2736
2842
|
};
|
|
2737
2843
|
|
|
2738
2844
|
// src/dynamics/components/dynamic-selection.tsx
|
|
2739
|
-
import * as
|
|
2845
|
+
import * as React68 from "react";
|
|
2740
2846
|
import { Fragment as Fragment9, useState as useState8 } from "react";
|
|
2741
|
-
import { useBoundProp as
|
|
2847
|
+
import { useBoundProp as useBoundProp4 } from "@elementor/editor-controls";
|
|
2742
2848
|
import { DatabaseIcon, SearchIcon } from "@elementor/icons";
|
|
2743
2849
|
import {
|
|
2744
2850
|
Box as Box4,
|
|
@@ -2752,13 +2858,13 @@ import {
|
|
|
2752
2858
|
TextField as TextField2,
|
|
2753
2859
|
Typography as Typography4
|
|
2754
2860
|
} from "@elementor/ui";
|
|
2755
|
-
import { __ as
|
|
2861
|
+
import { __ as __45 } from "@wordpress/i18n";
|
|
2756
2862
|
var SIZE3 = "tiny";
|
|
2757
2863
|
var DynamicSelection = ({ onSelect }) => {
|
|
2758
2864
|
const [searchValue, setSearchValue] = useState8("");
|
|
2759
2865
|
const { groups: dynamicGroups } = getAtomicDynamicTags() || {};
|
|
2760
|
-
const { value: anyValue } =
|
|
2761
|
-
const { bind, value: dynamicValue, setValue } =
|
|
2866
|
+
const { value: anyValue } = useBoundProp4();
|
|
2867
|
+
const { bind, value: dynamicValue, setValue } = useBoundProp4(dynamicPropTypeUtil);
|
|
2762
2868
|
const [, updatePropValueHistory] = usePersistDynamicValue(bind);
|
|
2763
2869
|
const isCurrentValueDynamic = !!dynamicValue;
|
|
2764
2870
|
const options12 = useFilteredOptions(searchValue);
|
|
@@ -2773,19 +2879,19 @@ var DynamicSelection = ({ onSelect }) => {
|
|
|
2773
2879
|
setValue({ name: value, settings: {} });
|
|
2774
2880
|
onSelect?.();
|
|
2775
2881
|
};
|
|
2776
|
-
return /* @__PURE__ */
|
|
2882
|
+
return /* @__PURE__ */ React68.createElement(Stack15, null, hasNoDynamicTags ? /* @__PURE__ */ React68.createElement(NoDynamicTags, null) : /* @__PURE__ */ React68.createElement(Fragment9, null, /* @__PURE__ */ React68.createElement(Box4, { px: 1.5, pb: 1 }, /* @__PURE__ */ React68.createElement(
|
|
2777
2883
|
TextField2,
|
|
2778
2884
|
{
|
|
2779
2885
|
fullWidth: true,
|
|
2780
2886
|
size: SIZE3,
|
|
2781
2887
|
value: searchValue,
|
|
2782
2888
|
onChange: handleSearch,
|
|
2783
|
-
placeholder:
|
|
2889
|
+
placeholder: __45("Search dynamic tags\u2026", "elementor"),
|
|
2784
2890
|
InputProps: {
|
|
2785
|
-
startAdornment: /* @__PURE__ */
|
|
2891
|
+
startAdornment: /* @__PURE__ */ React68.createElement(InputAdornment, { position: "start" }, /* @__PURE__ */ React68.createElement(SearchIcon, { fontSize: SIZE3 }))
|
|
2786
2892
|
}
|
|
2787
2893
|
}
|
|
2788
|
-
)), /* @__PURE__ */
|
|
2894
|
+
)), /* @__PURE__ */ React68.createElement(Divider6, null), /* @__PURE__ */ React68.createElement(Box4, { sx: { overflowY: "auto", height: 260, width: 220 } }, options12.length > 0 ? /* @__PURE__ */ React68.createElement(MenuList, { role: "listbox", tabIndex: 0 }, options12.map(([category, items3], index) => /* @__PURE__ */ React68.createElement(Fragment9, { key: index }, /* @__PURE__ */ React68.createElement(
|
|
2789
2895
|
ListSubheader2,
|
|
2790
2896
|
{
|
|
2791
2897
|
sx: { px: 1.5, typography: "caption", color: "text.tertiary" }
|
|
@@ -2793,7 +2899,7 @@ var DynamicSelection = ({ onSelect }) => {
|
|
|
2793
2899
|
dynamicGroups?.[category]?.title || category
|
|
2794
2900
|
), items3.map(({ value, label: tagLabel }) => {
|
|
2795
2901
|
const isSelected = isCurrentValueDynamic && value === dynamicValue?.name;
|
|
2796
|
-
return /* @__PURE__ */
|
|
2902
|
+
return /* @__PURE__ */ React68.createElement(
|
|
2797
2903
|
MenuItem2,
|
|
2798
2904
|
{
|
|
2799
2905
|
key: value,
|
|
@@ -2804,9 +2910,9 @@ var DynamicSelection = ({ onSelect }) => {
|
|
|
2804
2910
|
},
|
|
2805
2911
|
tagLabel
|
|
2806
2912
|
);
|
|
2807
|
-
})))) : /* @__PURE__ */
|
|
2913
|
+
})))) : /* @__PURE__ */ React68.createElement(NoResults, { searchValue, onClear: () => setSearchValue("") }))));
|
|
2808
2914
|
};
|
|
2809
|
-
var NoResults = ({ searchValue, onClear }) => /* @__PURE__ */
|
|
2915
|
+
var NoResults = ({ searchValue, onClear }) => /* @__PURE__ */ React68.createElement(
|
|
2810
2916
|
Stack15,
|
|
2811
2917
|
{
|
|
2812
2918
|
gap: 1,
|
|
@@ -2817,11 +2923,11 @@ var NoResults = ({ searchValue, onClear }) => /* @__PURE__ */ React67.createElem
|
|
|
2817
2923
|
color: "text.secondary",
|
|
2818
2924
|
sx: { pb: 3.5 }
|
|
2819
2925
|
},
|
|
2820
|
-
/* @__PURE__ */
|
|
2821
|
-
/* @__PURE__ */
|
|
2822
|
-
/* @__PURE__ */
|
|
2926
|
+
/* @__PURE__ */ React68.createElement(DatabaseIcon, { fontSize: "large" }),
|
|
2927
|
+
/* @__PURE__ */ React68.createElement(Typography4, { align: "center", variant: "subtitle2" }, __45("Sorry, nothing matched", "elementor"), /* @__PURE__ */ React68.createElement("br", null), "\u201C", searchValue, "\u201D."),
|
|
2928
|
+
/* @__PURE__ */ React68.createElement(Typography4, { align: "center", variant: "caption" }, __45("Try something else.", "elementor"), "\xA0", /* @__PURE__ */ React68.createElement(Link, { color: "text.secondary", variant: "caption", component: "button", onClick: onClear }, __45("Clear & try again", "elementor")))
|
|
2823
2929
|
);
|
|
2824
|
-
var NoDynamicTags = () => /* @__PURE__ */
|
|
2930
|
+
var NoDynamicTags = () => /* @__PURE__ */ React68.createElement(Box4, { sx: { overflowY: "hidden", height: 297, width: 220 } }, /* @__PURE__ */ React68.createElement(Divider6, null), /* @__PURE__ */ React68.createElement(
|
|
2825
2931
|
Stack15,
|
|
2826
2932
|
{
|
|
2827
2933
|
gap: 1,
|
|
@@ -2832,9 +2938,9 @@ var NoDynamicTags = () => /* @__PURE__ */ React67.createElement(Box4, { sx: { ov
|
|
|
2832
2938
|
color: "text.secondary",
|
|
2833
2939
|
sx: { pb: 3.5 }
|
|
2834
2940
|
},
|
|
2835
|
-
/* @__PURE__ */
|
|
2836
|
-
/* @__PURE__ */
|
|
2837
|
-
/* @__PURE__ */
|
|
2941
|
+
/* @__PURE__ */ React68.createElement(DatabaseIcon, { fontSize: "large" }),
|
|
2942
|
+
/* @__PURE__ */ React68.createElement(Typography4, { align: "center", variant: "subtitle2" }, __45("Streamline your workflow with dynamic tags", "elementor")),
|
|
2943
|
+
/* @__PURE__ */ React68.createElement(Typography4, { align: "center", variant: "caption" }, __45("You\u2019ll need Elementor Pro to use this feature.", "elementor"))
|
|
2838
2944
|
));
|
|
2839
2945
|
var useFilteredOptions = (searchValue) => {
|
|
2840
2946
|
const dynamicTags = usePropDynamicTags();
|
|
@@ -2855,8 +2961,8 @@ var useFilteredOptions = (searchValue) => {
|
|
|
2855
2961
|
// src/dynamics/components/dynamic-selection-control.tsx
|
|
2856
2962
|
var SIZE4 = "tiny";
|
|
2857
2963
|
var DynamicSelectionControl = () => {
|
|
2858
|
-
const { setValue: setAnyValue } =
|
|
2859
|
-
const { bind, value } =
|
|
2964
|
+
const { setValue: setAnyValue } = useBoundProp5();
|
|
2965
|
+
const { bind, value } = useBoundProp5(dynamicPropTypeUtil);
|
|
2860
2966
|
const [propValueFromHistory] = usePersistDynamicValue(bind);
|
|
2861
2967
|
const { name: tagName = "" } = value;
|
|
2862
2968
|
const selectionPopoverId = useId4();
|
|
@@ -2868,25 +2974,25 @@ var DynamicSelectionControl = () => {
|
|
|
2868
2974
|
if (!dynamicTag) {
|
|
2869
2975
|
throw new Error(`Dynamic tag ${tagName} not found`);
|
|
2870
2976
|
}
|
|
2871
|
-
return /* @__PURE__ */
|
|
2977
|
+
return /* @__PURE__ */ React69.createElement(Box5, null, /* @__PURE__ */ React69.createElement(
|
|
2872
2978
|
Tag,
|
|
2873
2979
|
{
|
|
2874
2980
|
fullWidth: true,
|
|
2875
2981
|
showActionsOnHover: true,
|
|
2876
2982
|
label: dynamicTag.label,
|
|
2877
|
-
startIcon: /* @__PURE__ */
|
|
2983
|
+
startIcon: /* @__PURE__ */ React69.createElement(DatabaseIcon2, { fontSize: SIZE4 }),
|
|
2878
2984
|
...bindTrigger2(selectionPopoverState),
|
|
2879
|
-
actions: /* @__PURE__ */
|
|
2985
|
+
actions: /* @__PURE__ */ React69.createElement(React69.Fragment, null, /* @__PURE__ */ React69.createElement(DynamicSettingsPopover, { dynamicTag }), /* @__PURE__ */ React69.createElement(
|
|
2880
2986
|
IconButton3,
|
|
2881
2987
|
{
|
|
2882
2988
|
size: SIZE4,
|
|
2883
2989
|
onClick: removeDynamicTag,
|
|
2884
|
-
"aria-label":
|
|
2990
|
+
"aria-label": __46("Remove dynamic value", "elementor")
|
|
2885
2991
|
},
|
|
2886
|
-
/* @__PURE__ */
|
|
2992
|
+
/* @__PURE__ */ React69.createElement(XIcon2, { fontSize: SIZE4 })
|
|
2887
2993
|
))
|
|
2888
2994
|
}
|
|
2889
|
-
), /* @__PURE__ */
|
|
2995
|
+
), /* @__PURE__ */ React69.createElement(
|
|
2890
2996
|
Popover2,
|
|
2891
2997
|
{
|
|
2892
2998
|
disablePortal: true,
|
|
@@ -2894,7 +3000,7 @@ var DynamicSelectionControl = () => {
|
|
|
2894
3000
|
anchorOrigin: { vertical: "bottom", horizontal: "left" },
|
|
2895
3001
|
...bindPopover2(selectionPopoverState)
|
|
2896
3002
|
},
|
|
2897
|
-
/* @__PURE__ */
|
|
3003
|
+
/* @__PURE__ */ React69.createElement(Stack16, null, /* @__PURE__ */ React69.createElement(Stack16, { direction: "row", alignItems: "center", pl: 1.5, pr: 0.5, py: 1.5 }, /* @__PURE__ */ React69.createElement(DatabaseIcon2, { fontSize: SIZE4, sx: { mr: 0.5 } }), /* @__PURE__ */ React69.createElement(Typography5, { variant: "subtitle2" }, __46("Dynamic tags", "elementor")), /* @__PURE__ */ React69.createElement(IconButton3, { size: SIZE4, sx: { ml: "auto" }, onClick: selectionPopoverState.close }, /* @__PURE__ */ React69.createElement(XIcon2, { fontSize: SIZE4 }))), /* @__PURE__ */ React69.createElement(DynamicSelection, { onSelect: selectionPopoverState.close }))
|
|
2898
3004
|
));
|
|
2899
3005
|
};
|
|
2900
3006
|
var DynamicSettingsPopover = ({ dynamicTag }) => {
|
|
@@ -2904,22 +3010,22 @@ var DynamicSettingsPopover = ({ dynamicTag }) => {
|
|
|
2904
3010
|
if (!hasDynamicSettings) {
|
|
2905
3011
|
return null;
|
|
2906
3012
|
}
|
|
2907
|
-
return /* @__PURE__ */
|
|
3013
|
+
return /* @__PURE__ */ React69.createElement(React69.Fragment, null, /* @__PURE__ */ React69.createElement(
|
|
2908
3014
|
IconButton3,
|
|
2909
3015
|
{
|
|
2910
3016
|
size: SIZE4,
|
|
2911
3017
|
...bindTrigger2(settingsPopupState),
|
|
2912
|
-
"aria-label":
|
|
3018
|
+
"aria-label": __46("Settings", "elementor")
|
|
2913
3019
|
},
|
|
2914
|
-
/* @__PURE__ */
|
|
2915
|
-
), /* @__PURE__ */
|
|
3020
|
+
/* @__PURE__ */ React69.createElement(SettingsIcon, { fontSize: SIZE4 })
|
|
3021
|
+
), /* @__PURE__ */ React69.createElement(
|
|
2916
3022
|
Popover2,
|
|
2917
3023
|
{
|
|
2918
3024
|
disableScrollLock: true,
|
|
2919
3025
|
anchorOrigin: { vertical: "bottom", horizontal: "center" },
|
|
2920
3026
|
...bindPopover2(settingsPopupState)
|
|
2921
3027
|
},
|
|
2922
|
-
/* @__PURE__ */
|
|
3028
|
+
/* @__PURE__ */ React69.createElement(Paper, { component: Stack16, sx: { minHeight: "300px", width: "220px" } }, /* @__PURE__ */ React69.createElement(Stack16, { direction: "row", alignItems: "center", px: 1.5, pt: 2, pb: 1 }, /* @__PURE__ */ React69.createElement(DatabaseIcon2, { fontSize: SIZE4, sx: { mr: 0.5 } }), /* @__PURE__ */ React69.createElement(Typography5, { variant: "subtitle2" }, dynamicTag.label), /* @__PURE__ */ React69.createElement(IconButton3, { sx: { ml: "auto" }, size: SIZE4, onClick: settingsPopupState.close }, /* @__PURE__ */ React69.createElement(XIcon2, { fontSize: SIZE4 }))), /* @__PURE__ */ React69.createElement(DynamicSettings, { controls: dynamicTag.atomic_controls }))
|
|
2923
3029
|
));
|
|
2924
3030
|
};
|
|
2925
3031
|
var DynamicSettings = ({ controls }) => {
|
|
@@ -2928,10 +3034,10 @@ var DynamicSettings = ({ controls }) => {
|
|
|
2928
3034
|
if (!tabs.length) {
|
|
2929
3035
|
return null;
|
|
2930
3036
|
}
|
|
2931
|
-
return /* @__PURE__ */
|
|
2932
|
-
return /* @__PURE__ */
|
|
3037
|
+
return /* @__PURE__ */ React69.createElement(React69.Fragment, null, /* @__PURE__ */ React69.createElement(Tabs2, { indicatorColor: "secondary", textColor: "secondary", ...getTabsProps() }, tabs.map(({ value }, index) => /* @__PURE__ */ React69.createElement(Tab2, { key: index, label: value.label, sx: { px: 1, py: 0.5 }, ...getTabProps(index) }))), /* @__PURE__ */ React69.createElement(Divider7, null), tabs.map(({ value }, index) => {
|
|
3038
|
+
return /* @__PURE__ */ React69.createElement(TabPanel2, { key: index, sx: { flexGrow: 1, py: 0 }, ...getTabPanelProps(index) }, /* @__PURE__ */ React69.createElement(PopoverContent, { p: 1.5 }, value.items.map((item) => {
|
|
2933
3039
|
if (item.type === "control") {
|
|
2934
|
-
return /* @__PURE__ */
|
|
3040
|
+
return /* @__PURE__ */ React69.createElement(Control3, { key: item.value.bind, control: item.value });
|
|
2935
3041
|
}
|
|
2936
3042
|
return null;
|
|
2937
3043
|
})));
|
|
@@ -2941,22 +3047,22 @@ var Control3 = ({ control }) => {
|
|
|
2941
3047
|
if (!getControlByType(control.type)) {
|
|
2942
3048
|
return null;
|
|
2943
3049
|
}
|
|
2944
|
-
return /* @__PURE__ */
|
|
3050
|
+
return /* @__PURE__ */ React69.createElement(DynamicControl, { bind: control.bind }, /* @__PURE__ */ React69.createElement(Grid26, { container: true, gap: 0.75 }, control.label ? /* @__PURE__ */ React69.createElement(Grid26, { item: true, xs: 12 }, /* @__PURE__ */ React69.createElement(ControlLabel31, null, control.label)) : null, /* @__PURE__ */ React69.createElement(Grid26, { item: true, xs: 12 }, /* @__PURE__ */ React69.createElement(Control, { type: control.type, props: control.props }))));
|
|
2945
3051
|
};
|
|
2946
3052
|
|
|
2947
3053
|
// src/dynamics/hooks/use-prop-dynamic-action.tsx
|
|
2948
|
-
import * as
|
|
2949
|
-
import { useBoundProp as
|
|
3054
|
+
import * as React70 from "react";
|
|
3055
|
+
import { useBoundProp as useBoundProp6 } from "@elementor/editor-controls";
|
|
2950
3056
|
import { DatabaseIcon as DatabaseIcon3 } from "@elementor/icons";
|
|
2951
|
-
import { __ as
|
|
3057
|
+
import { __ as __47 } from "@wordpress/i18n";
|
|
2952
3058
|
var usePropDynamicAction = () => {
|
|
2953
|
-
const { propType } =
|
|
3059
|
+
const { propType } = useBoundProp6();
|
|
2954
3060
|
const visible = !!propType && supportsDynamic(propType);
|
|
2955
3061
|
return {
|
|
2956
3062
|
visible,
|
|
2957
3063
|
icon: DatabaseIcon3,
|
|
2958
|
-
title:
|
|
2959
|
-
popoverContent: ({ closePopover }) => /* @__PURE__ */
|
|
3064
|
+
title: __47("Dynamic tags", "elementor"),
|
|
3065
|
+
popoverContent: ({ closePopover }) => /* @__PURE__ */ React70.createElement(DynamicSelection, { onSelect: closePopover })
|
|
2960
3066
|
};
|
|
2961
3067
|
};
|
|
2962
3068
|
|
|
@@ -2999,7 +3105,7 @@ init2();
|
|
|
2999
3105
|
export {
|
|
3000
3106
|
injectIntoClassSelectorActions,
|
|
3001
3107
|
replaceControl,
|
|
3002
|
-
|
|
3108
|
+
useBoundProp7 as useBoundProp,
|
|
3003
3109
|
usePanelActions,
|
|
3004
3110
|
usePanelStatus
|
|
3005
3111
|
};
|