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