@elementor/editor-editing-panel 1.41.0 → 1.42.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 +108 -71
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +128 -79
- package/dist/index.mjs.map +1 -1
- package/package.json +2 -2
- package/src/components/style-sections/size-section/object-fit-field.tsx +2 -6
- package/src/components/style-sections/size-section/object-position-field.tsx +2 -6
- package/src/components/style-sections/size-section/size-section.tsx +4 -10
- package/src/styles-inheritance/components/label-chip.tsx +14 -9
- package/src/styles-inheritance/consts.ts +1 -1
- package/src/styles-inheritance/hooks/use-normalized-inheritance-chain-items.tsx +17 -1
- package/src/styles-inheritance/styles-inheritance-infotip.tsx +142 -87
- package/src/styles-inheritance/types.ts +2 -0
package/dist/index.mjs
CHANGED
|
@@ -1179,7 +1179,7 @@ function EditorPanelErrorFallback() {
|
|
|
1179
1179
|
|
|
1180
1180
|
// src/components/editing-panel-tabs.tsx
|
|
1181
1181
|
import * as React79 from "react";
|
|
1182
|
-
import { Fragment as
|
|
1182
|
+
import { Fragment as Fragment10 } from "react";
|
|
1183
1183
|
import { isExperimentActive as isExperimentActive11 } from "@elementor/editor-v1-adapters";
|
|
1184
1184
|
import { Divider as Divider6, Stack as Stack18, Tab, TabPanel, Tabs, useTabs } from "@elementor/ui";
|
|
1185
1185
|
import { __ as __53 } from "@wordpress/i18n";
|
|
@@ -1932,7 +1932,7 @@ import { useBoundProp } from "@elementor/editor-controls";
|
|
|
1932
1932
|
import { isEmpty as isEmpty2 } from "@elementor/editor-props";
|
|
1933
1933
|
import { ELEMENTS_BASE_STYLES_PROVIDER_KEY as ELEMENTS_BASE_STYLES_PROVIDER_KEY3, isElementsStylesProvider as isElementsStylesProvider3 } from "@elementor/editor-styles-repository";
|
|
1934
1934
|
import { isExperimentActive as isExperimentActive5 } from "@elementor/editor-v1-adapters";
|
|
1935
|
-
import { Tooltip as
|
|
1935
|
+
import { Tooltip as Tooltip6 } from "@elementor/ui";
|
|
1936
1936
|
import { __ as __9 } from "@wordpress/i18n";
|
|
1937
1937
|
|
|
1938
1938
|
// src/styles-inheritance/consts.ts
|
|
@@ -1949,13 +1949,25 @@ var excludePropTypeTransformers = /* @__PURE__ */ new Set([
|
|
|
1949
1949
|
"image",
|
|
1950
1950
|
"background-overlay"
|
|
1951
1951
|
]);
|
|
1952
|
-
var isUsingIndicatorPopover = () => isExperimentActive4("
|
|
1952
|
+
var isUsingIndicatorPopover = () => isExperimentActive4("e_v_3_30");
|
|
1953
1953
|
|
|
1954
1954
|
// src/styles-inheritance/styles-inheritance-infotip.tsx
|
|
1955
1955
|
import * as React25 from "react";
|
|
1956
1956
|
import { useMemo as useMemo4, useState as useState8 } from "react";
|
|
1957
1957
|
import { createPropsResolver } from "@elementor/editor-canvas";
|
|
1958
|
-
import {
|
|
1958
|
+
import {
|
|
1959
|
+
Backdrop,
|
|
1960
|
+
Box as Box6,
|
|
1961
|
+
Card,
|
|
1962
|
+
CardContent,
|
|
1963
|
+
ClickAwayListener,
|
|
1964
|
+
CloseButton,
|
|
1965
|
+
IconButton as IconButton3,
|
|
1966
|
+
Infotip,
|
|
1967
|
+
Stack as Stack7,
|
|
1968
|
+
Tooltip as Tooltip5,
|
|
1969
|
+
Typography as Typography6
|
|
1970
|
+
} from "@elementor/ui";
|
|
1959
1971
|
import { __ as __8 } from "@wordpress/i18n";
|
|
1960
1972
|
|
|
1961
1973
|
// src/components/section-content.tsx
|
|
@@ -2031,16 +2043,18 @@ import { InfoCircleIcon } from "@elementor/icons";
|
|
|
2031
2043
|
import { Chip as Chip4, Tooltip as Tooltip4 } from "@elementor/ui";
|
|
2032
2044
|
import { __ as __6 } from "@wordpress/i18n";
|
|
2033
2045
|
var SIZE4 = "tiny";
|
|
2034
|
-
var LabelChip = ({ displayLabel, provider }) => {
|
|
2046
|
+
var LabelChip = ({ displayLabel, provider, chipColor }) => {
|
|
2047
|
+
const isBaseStyle = provider === ELEMENTS_BASE_STYLES_PROVIDER_KEY;
|
|
2048
|
+
const chipIcon = isBaseStyle ? /* @__PURE__ */ React22.createElement(Tooltip4, { title: __6("Inherited from base styles", "elementor"), placement: "top" }, /* @__PURE__ */ React22.createElement(InfoCircleIcon, { fontSize: SIZE4 })) : void 0;
|
|
2035
2049
|
return /* @__PURE__ */ React22.createElement(
|
|
2036
2050
|
Chip4,
|
|
2037
2051
|
{
|
|
2038
2052
|
label: displayLabel,
|
|
2039
2053
|
size: SIZE4,
|
|
2040
|
-
color:
|
|
2054
|
+
color: chipColor,
|
|
2041
2055
|
variant: "standard",
|
|
2042
2056
|
state: "enabled",
|
|
2043
|
-
icon:
|
|
2057
|
+
icon: chipIcon,
|
|
2044
2058
|
sx: (theme) => ({
|
|
2045
2059
|
lineHeight: 1,
|
|
2046
2060
|
flexWrap: "nowrap",
|
|
@@ -2118,7 +2132,8 @@ var normalizeInheritanceItem = async (item, index, bind, resolve) => {
|
|
|
2118
2132
|
provider: item.provider || "",
|
|
2119
2133
|
breakpoint: breakpoint ?? DEFAULT_BREAKPOINT3,
|
|
2120
2134
|
displayLabel,
|
|
2121
|
-
value: await getTransformedValue(item, bind, resolve)
|
|
2135
|
+
value: await getTransformedValue(item, bind, resolve),
|
|
2136
|
+
chipColor: getChipColor(item)
|
|
2122
2137
|
};
|
|
2123
2138
|
};
|
|
2124
2139
|
var getTransformedValue = async (item, bind, resolve) => {
|
|
@@ -2140,6 +2155,16 @@ var getTransformedValue = async (item, bind, resolve) => {
|
|
|
2140
2155
|
return "";
|
|
2141
2156
|
}
|
|
2142
2157
|
};
|
|
2158
|
+
var getChipColor = (item) => {
|
|
2159
|
+
const { provider = "", style } = item;
|
|
2160
|
+
if (provider === ELEMENTS_BASE_STYLES_PROVIDER_KEY2) {
|
|
2161
|
+
return "default";
|
|
2162
|
+
}
|
|
2163
|
+
if (style?.label === "local") {
|
|
2164
|
+
return "accent";
|
|
2165
|
+
}
|
|
2166
|
+
return "global";
|
|
2167
|
+
};
|
|
2143
2168
|
|
|
2144
2169
|
// src/styles-inheritance/styles-inheritance-transformers-registry.tsx
|
|
2145
2170
|
import { createTransformersRegistry } from "@elementor/editor-canvas";
|
|
@@ -2148,8 +2173,9 @@ var stylesInheritanceTransformersRegistry = createTransformersRegistry();
|
|
|
2148
2173
|
// src/styles-inheritance/styles-inheritance-infotip.tsx
|
|
2149
2174
|
var SIZE5 = "tiny";
|
|
2150
2175
|
var StyleIndicatorInfotip = ({ inheritanceChain, propType, path, label, children }) => {
|
|
2151
|
-
const [
|
|
2152
|
-
const
|
|
2176
|
+
const [showInfotip, setShowInfotip] = useState8(false);
|
|
2177
|
+
const toggleInfotip = () => setShowInfotip((prev) => !prev);
|
|
2178
|
+
const closeInfotip = () => setShowInfotip(false);
|
|
2153
2179
|
const key = path.join(".");
|
|
2154
2180
|
const sectionContentRef = useSectionContentRef();
|
|
2155
2181
|
const sectionContentWidth = sectionContentRef?.current?.offsetWidth ?? 320;
|
|
@@ -2160,12 +2186,7 @@ var StyleIndicatorInfotip = ({ inheritanceChain, propType, path, label, children
|
|
|
2160
2186
|
});
|
|
2161
2187
|
}, [key, propType]);
|
|
2162
2188
|
const items3 = useNormalizedInheritanceChainItems(inheritanceChain, key, resolve);
|
|
2163
|
-
const
|
|
2164
|
-
const closeInfotip = () => {
|
|
2165
|
-
setOpen(false);
|
|
2166
|
-
};
|
|
2167
|
-
const forceInfotipAlignLeft = isSiteRtl ? 9999999 : -9999999;
|
|
2168
|
-
const infotipContent = /* @__PURE__ */ React25.createElement(
|
|
2189
|
+
const infotipContent = /* @__PURE__ */ React25.createElement(ClickAwayListener, { onClickAway: closeInfotip }, /* @__PURE__ */ React25.createElement(
|
|
2169
2190
|
Card,
|
|
2170
2191
|
{
|
|
2171
2192
|
elevation: 0,
|
|
@@ -2196,54 +2217,90 @@ var StyleIndicatorInfotip = ({ inheritanceChain, propType, path, label, children
|
|
|
2196
2217
|
onClick: closeInfotip
|
|
2197
2218
|
}
|
|
2198
2219
|
)),
|
|
2199
|
-
/* @__PURE__ */ React25.createElement(
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2220
|
+
/* @__PURE__ */ React25.createElement(
|
|
2221
|
+
Stack7,
|
|
2222
|
+
{
|
|
2223
|
+
gap: 1.5,
|
|
2224
|
+
sx: { pl: 2, pr: 1, pb: 2, overflowX: "hidden", overflowY: "auto" },
|
|
2225
|
+
role: "list"
|
|
2226
|
+
},
|
|
2227
|
+
items3.map((item, index) => {
|
|
2228
|
+
return /* @__PURE__ */ React25.createElement(
|
|
2229
|
+
Box6,
|
|
2230
|
+
{
|
|
2231
|
+
key: item.id,
|
|
2232
|
+
display: "flex",
|
|
2233
|
+
gap: 0.5,
|
|
2234
|
+
role: "listitem",
|
|
2235
|
+
"aria-label": __8("Inheritance item: %s", "elementor").replace(
|
|
2236
|
+
"%s",
|
|
2237
|
+
item.displayLabel
|
|
2238
|
+
)
|
|
2239
|
+
},
|
|
2240
|
+
/* @__PURE__ */ React25.createElement(Box6, { display: "flex", gap: 0.5, sx: { flexWrap: "wrap", width: "100%" } }, /* @__PURE__ */ React25.createElement(BreakpointIcon, { breakpoint: item.breakpoint }), /* @__PURE__ */ React25.createElement(
|
|
2241
|
+
LabelChip,
|
|
2242
|
+
{
|
|
2243
|
+
displayLabel: item.displayLabel,
|
|
2244
|
+
provider: item.provider,
|
|
2245
|
+
chipColor: item.chipColor
|
|
2246
|
+
}
|
|
2247
|
+
), /* @__PURE__ */ React25.createElement(ValueComponent, { index, value: item.value })),
|
|
2248
|
+
/* @__PURE__ */ React25.createElement(ActionIcons, null)
|
|
2249
|
+
);
|
|
2250
|
+
})
|
|
2251
|
+
)
|
|
2216
2252
|
)
|
|
2217
|
-
);
|
|
2218
|
-
return /* @__PURE__ */ React25.createElement(
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2253
|
+
));
|
|
2254
|
+
return /* @__PURE__ */ React25.createElement(TooltipOrInfotip, { showInfotip, onClose: closeInfotip, infotipContent }, /* @__PURE__ */ React25.createElement(IconButton3, { onClick: toggleInfotip, "aria-label": label, sx: { my: "-1px" } }, children));
|
|
2255
|
+
};
|
|
2256
|
+
function TooltipOrInfotip({
|
|
2257
|
+
children,
|
|
2258
|
+
showInfotip,
|
|
2259
|
+
onClose,
|
|
2260
|
+
infotipContent
|
|
2261
|
+
}) {
|
|
2262
|
+
const { isSiteRtl } = useDirection();
|
|
2263
|
+
const forceInfotipAlignLeft = isSiteRtl ? 9999999 : -9999999;
|
|
2264
|
+
if (showInfotip) {
|
|
2265
|
+
return /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(
|
|
2266
|
+
Backdrop,
|
|
2267
|
+
{
|
|
2268
|
+
open: showInfotip,
|
|
2269
|
+
onClick: onClose,
|
|
2270
|
+
sx: {
|
|
2271
|
+
backgroundColor: "transparent",
|
|
2272
|
+
zIndex: (theme) => theme.zIndex.modal - 1
|
|
2273
|
+
}
|
|
2274
|
+
}
|
|
2275
|
+
), /* @__PURE__ */ React25.createElement(
|
|
2276
|
+
Infotip,
|
|
2277
|
+
{
|
|
2278
|
+
placement: "top",
|
|
2279
|
+
content: infotipContent,
|
|
2280
|
+
open: showInfotip,
|
|
2281
|
+
onClose,
|
|
2282
|
+
disableHoverListener: true,
|
|
2283
|
+
componentsProps: {
|
|
2284
|
+
tooltip: {
|
|
2285
|
+
sx: { mx: 2 }
|
|
2286
|
+
}
|
|
2287
|
+
},
|
|
2288
|
+
slotProps: {
|
|
2289
|
+
popper: {
|
|
2290
|
+
modifiers: [
|
|
2291
|
+
{
|
|
2292
|
+
name: "offset",
|
|
2293
|
+
options: { offset: [forceInfotipAlignLeft, 0] }
|
|
2294
|
+
}
|
|
2295
|
+
]
|
|
2230
2296
|
}
|
|
2231
2297
|
}
|
|
2232
2298
|
},
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
options: { offset: [forceInfotipAlignLeft, 0] }
|
|
2239
|
-
}
|
|
2240
|
-
]
|
|
2241
|
-
}
|
|
2242
|
-
}
|
|
2243
|
-
},
|
|
2244
|
-
/* @__PURE__ */ React25.createElement(IconButton3, { onClick: toggleOpen, "aria-label": label, sx: { my: "-1px" } }, children)
|
|
2245
|
-
);
|
|
2246
|
-
};
|
|
2299
|
+
children
|
|
2300
|
+
));
|
|
2301
|
+
}
|
|
2302
|
+
return /* @__PURE__ */ React25.createElement(Tooltip5, { title: __8("Style origin", "elementor"), placement: "top" }, children);
|
|
2303
|
+
}
|
|
2247
2304
|
|
|
2248
2305
|
// src/styles-inheritance/styles-inheritance-indicator.tsx
|
|
2249
2306
|
var StylesInheritanceIndicator = () => {
|
|
@@ -2272,7 +2329,7 @@ var StylesInheritanceIndicator = () => {
|
|
|
2272
2329
|
const label = getLabel({ isFinalValue, hasValue });
|
|
2273
2330
|
const variantType = getVariant({ isFinalValue, hasValue, currentStyleProvider });
|
|
2274
2331
|
if (!isUsingIndicatorPopover()) {
|
|
2275
|
-
return /* @__PURE__ */ React26.createElement(
|
|
2332
|
+
return /* @__PURE__ */ React26.createElement(Tooltip6, { title: __9("Style origin", "elementor"), placement: "top" }, /* @__PURE__ */ React26.createElement(StyleIndicator, { variant: variantType, "aria-label": label }));
|
|
2276
2333
|
}
|
|
2277
2334
|
return /* @__PURE__ */ React26.createElement(
|
|
2278
2335
|
StyleIndicatorInfotip,
|
|
@@ -3383,8 +3440,8 @@ var positionOptions2 = [
|
|
|
3383
3440
|
{ label: __31("None", "elementor"), value: "none" },
|
|
3384
3441
|
{ label: __31("Scale down", "elementor"), value: "scale-down" }
|
|
3385
3442
|
];
|
|
3386
|
-
var ObjectFitField = (
|
|
3387
|
-
return /* @__PURE__ */ React57.createElement(StylesField, { bind: "object-fit" }, /* @__PURE__ */ React57.createElement(Grid13, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React57.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React57.createElement(ControlLabel, null, __31("Object fit", "elementor"))), /* @__PURE__ */ React57.createElement(Grid13, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React57.createElement(SelectControl4, { options: positionOptions2
|
|
3443
|
+
var ObjectFitField = () => {
|
|
3444
|
+
return /* @__PURE__ */ React57.createElement(StylesField, { bind: "object-fit" }, /* @__PURE__ */ React57.createElement(Grid13, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React57.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React57.createElement(ControlLabel, null, __31("Object fit", "elementor"))), /* @__PURE__ */ React57.createElement(Grid13, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React57.createElement(SelectControl4, { options: positionOptions2 }))));
|
|
3388
3445
|
};
|
|
3389
3446
|
|
|
3390
3447
|
// src/components/style-sections/size-section/object-position-field.tsx
|
|
@@ -3403,8 +3460,8 @@ var positionOptions3 = [
|
|
|
3403
3460
|
{ label: __32("Bottom left", "elementor"), value: "bottom left" },
|
|
3404
3461
|
{ label: __32("Bottom right", "elementor"), value: "bottom right" }
|
|
3405
3462
|
];
|
|
3406
|
-
var ObjectPositionField = (
|
|
3407
|
-
return /* @__PURE__ */ React58.createElement(StylesField, { bind: "object-position" }, /* @__PURE__ */ React58.createElement(Grid14, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React58.createElement(Grid14, { item: true, xs: 6 }, /* @__PURE__ */ React58.createElement(ControlLabel, null, __32("Object position", "elementor"))), /* @__PURE__ */ React58.createElement(Grid14, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React58.createElement(SelectControl5, { options: positionOptions3
|
|
3463
|
+
var ObjectPositionField = () => {
|
|
3464
|
+
return /* @__PURE__ */ React58.createElement(StylesField, { bind: "object-position" }, /* @__PURE__ */ React58.createElement(Grid14, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React58.createElement(Grid14, { item: true, xs: 6 }, /* @__PURE__ */ React58.createElement(ControlLabel, null, __32("Object position", "elementor"))), /* @__PURE__ */ React58.createElement(Grid14, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React58.createElement(SelectControl5, { options: positionOptions3 }))));
|
|
3408
3465
|
};
|
|
3409
3466
|
|
|
3410
3467
|
// src/components/style-sections/size-section/overflow-field.tsx
|
|
@@ -3439,16 +3496,8 @@ var OverflowField = () => {
|
|
|
3439
3496
|
|
|
3440
3497
|
// src/components/style-sections/size-section/size-section.tsx
|
|
3441
3498
|
var SizeSection = () => {
|
|
3442
|
-
const [fitValue
|
|
3499
|
+
const [fitValue] = useStylesField("object-fit");
|
|
3443
3500
|
const isNotFill = fitValue && fitValue?.value !== "fill";
|
|
3444
|
-
const onFitChange = (newFit, previousValue) => {
|
|
3445
|
-
if (newFit && newFit !== previousValue) {
|
|
3446
|
-
setFitValue({
|
|
3447
|
-
value: newFit,
|
|
3448
|
-
$$type: "string"
|
|
3449
|
-
});
|
|
3450
|
-
}
|
|
3451
|
-
};
|
|
3452
3501
|
const isVersion330Active = isExperimentActive8("e_v_3_30");
|
|
3453
3502
|
return /* @__PURE__ */ React60.createElement(SectionContent, null, /* @__PURE__ */ React60.createElement(Grid16, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "width", label: __34("Width", "elementor"), extendedValues: ["auto"] })), /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "height", label: __34("Height", "elementor"), extendedValues: ["auto"] }))), /* @__PURE__ */ React60.createElement(Grid16, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(
|
|
3454
3503
|
SizeField,
|
|
@@ -3464,7 +3513,7 @@ var SizeSection = () => {
|
|
|
3464
3513
|
label: __34("Min height", "elementor"),
|
|
3465
3514
|
extendedValues: ["auto"]
|
|
3466
3515
|
}
|
|
3467
|
-
))), /* @__PURE__ */ React60.createElement(Grid16, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "max-width", label: __34("Max width", "elementor") })), /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "max-height", label: __34("Max height", "elementor") }))), /* @__PURE__ */ React60.createElement(PanelDivider, null), /* @__PURE__ */ React60.createElement(Stack16, null, /* @__PURE__ */ React60.createElement(OverflowField, null)), isVersion330Active && /* @__PURE__ */ React60.createElement(CollapsibleContent, null, /* @__PURE__ */ React60.createElement(Stack16, { gap: 2 }, /* @__PURE__ */ React60.createElement(StylesField, { bind: "aspect-ratio" }, /* @__PURE__ */ React60.createElement(AspectRatioControl, { label: __34("Aspect Ratio", "elementor") })), /* @__PURE__ */ React60.createElement(PanelDivider, null), /* @__PURE__ */ React60.createElement(ObjectFitField,
|
|
3516
|
+
))), /* @__PURE__ */ React60.createElement(Grid16, { container: true, gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "max-width", label: __34("Max width", "elementor") })), /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(SizeField, { bind: "max-height", label: __34("Max height", "elementor") }))), /* @__PURE__ */ React60.createElement(PanelDivider, null), /* @__PURE__ */ React60.createElement(Stack16, null, /* @__PURE__ */ React60.createElement(OverflowField, null)), isVersion330Active && /* @__PURE__ */ React60.createElement(CollapsibleContent, null, /* @__PURE__ */ React60.createElement(Stack16, { gap: 2 }, /* @__PURE__ */ React60.createElement(StylesField, { bind: "aspect-ratio" }, /* @__PURE__ */ React60.createElement(AspectRatioControl, { label: __34("Aspect Ratio", "elementor") })), /* @__PURE__ */ React60.createElement(PanelDivider, null), /* @__PURE__ */ React60.createElement(ObjectFitField, null), isNotFill && /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 6 }, /* @__PURE__ */ React60.createElement(ObjectPositionField, null)))));
|
|
3468
3517
|
};
|
|
3469
3518
|
var SizeField = ({ label, bind, extendedValues }) => {
|
|
3470
3519
|
return /* @__PURE__ */ React60.createElement(StylesField, { bind }, /* @__PURE__ */ React60.createElement(Grid16, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 12 }, /* @__PURE__ */ React60.createElement(ControlLabel, null, label)), /* @__PURE__ */ React60.createElement(Grid16, { item: true, xs: 12 }, /* @__PURE__ */ React60.createElement(SizeControl5, { extendedValues }))));
|
|
@@ -3957,7 +4006,7 @@ var EditingPanelTabs = () => {
|
|
|
3957
4006
|
return (
|
|
3958
4007
|
// When switching between elements, the local states should be reset. We are using key to rerender the tabs.
|
|
3959
4008
|
// Reference: https://react.dev/learn/preserving-and-resetting-state#resetting-a-form-with-a-key
|
|
3960
|
-
/* @__PURE__ */ React79.createElement(
|
|
4009
|
+
/* @__PURE__ */ React79.createElement(Fragment10, { key: element.id }, /* @__PURE__ */ React79.createElement(PanelTabContent, null))
|
|
3961
4010
|
);
|
|
3962
4011
|
};
|
|
3963
4012
|
var PanelTabContent = () => {
|
|
@@ -4188,7 +4237,7 @@ var DynamicControl = ({ bind, children }) => {
|
|
|
4188
4237
|
|
|
4189
4238
|
// src/dynamics/components/dynamic-selection.tsx
|
|
4190
4239
|
import * as React83 from "react";
|
|
4191
|
-
import { Fragment as
|
|
4240
|
+
import { Fragment as Fragment11, useState as useState13 } from "react";
|
|
4192
4241
|
import { useBoundProp as useBoundProp4 } from "@elementor/editor-controls";
|
|
4193
4242
|
import { DatabaseIcon, SearchIcon } from "@elementor/icons";
|
|
4194
4243
|
import {
|
|
@@ -4224,7 +4273,7 @@ var DynamicSelection = ({ onSelect }) => {
|
|
|
4224
4273
|
setValue({ name: value, settings: { label } });
|
|
4225
4274
|
onSelect?.();
|
|
4226
4275
|
};
|
|
4227
|
-
return /* @__PURE__ */ React83.createElement(Stack20, null, hasNoDynamicTags ? /* @__PURE__ */ React83.createElement(NoDynamicTags, null) : /* @__PURE__ */ React83.createElement(
|
|
4276
|
+
return /* @__PURE__ */ React83.createElement(Stack20, null, hasNoDynamicTags ? /* @__PURE__ */ React83.createElement(NoDynamicTags, null) : /* @__PURE__ */ React83.createElement(Fragment11, null, /* @__PURE__ */ React83.createElement(Box7, { px: 1.5, pb: 1 }, /* @__PURE__ */ React83.createElement(
|
|
4228
4277
|
TextField2,
|
|
4229
4278
|
{
|
|
4230
4279
|
fullWidth: true,
|
|
@@ -4236,7 +4285,7 @@ var DynamicSelection = ({ onSelect }) => {
|
|
|
4236
4285
|
startAdornment: /* @__PURE__ */ React83.createElement(InputAdornment, { position: "start" }, /* @__PURE__ */ React83.createElement(SearchIcon, { fontSize: SIZE7 }))
|
|
4237
4286
|
}
|
|
4238
4287
|
}
|
|
4239
|
-
)), /* @__PURE__ */ React83.createElement(Divider7, null), /* @__PURE__ */ React83.createElement(Box7, { sx: { overflowY: "auto", height: 260, width: 220 } }, options12.length > 0 ? /* @__PURE__ */ React83.createElement(MenuList, { role: "listbox", tabIndex: 0 }, options12.map(([category, items3], index) => /* @__PURE__ */ React83.createElement(
|
|
4288
|
+
)), /* @__PURE__ */ React83.createElement(Divider7, null), /* @__PURE__ */ React83.createElement(Box7, { sx: { overflowY: "auto", height: 260, width: 220 } }, options12.length > 0 ? /* @__PURE__ */ React83.createElement(MenuList, { role: "listbox", tabIndex: 0 }, options12.map(([category, items3], index) => /* @__PURE__ */ React83.createElement(Fragment11, { key: index }, /* @__PURE__ */ React83.createElement(
|
|
4240
4289
|
MenuSubheader2,
|
|
4241
4290
|
{
|
|
4242
4291
|
sx: { px: 1.5, typography: "caption", color: "text.tertiary" }
|