@elementor/editor-controls 3.35.0-392 → 3.35.0-394
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/dist/index.js +7 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -7
- package/dist/index.mjs.map +1 -1
- package/package.json +15 -15
- package/src/controls/equal-unequal-sizes-control.tsx +9 -9
package/dist/index.mjs
CHANGED
|
@@ -2612,22 +2612,22 @@ function EqualUnequalSizesControl({
|
|
|
2612
2612
|
if (!values) {
|
|
2613
2613
|
return true;
|
|
2614
2614
|
}
|
|
2615
|
+
const multiSizeValue = multiSizePropTypeUtil.create(values);
|
|
2615
2616
|
const propValue = {};
|
|
2616
2617
|
items2.forEach((item) => {
|
|
2617
|
-
propValue[item.bind] =
|
|
2618
|
+
propValue[item.bind] = multiSizeValue?.value?.[item.bind] ?? null;
|
|
2618
2619
|
});
|
|
2619
2620
|
const allValues = Object.values(propValue).map((value) => JSON.stringify(value));
|
|
2620
2621
|
return allValues.every((value) => value === allValues[0]);
|
|
2621
2622
|
};
|
|
2622
|
-
const isMixedPlaceholder = !masterValue && !isEqualValues(
|
|
2623
|
-
const isMixed = isMixedPlaceholder || !isEqualValues(
|
|
2623
|
+
const isMixedPlaceholder = !masterValue && !isEqualValues(derivedPlaceholder);
|
|
2624
|
+
const isMixed = isMixedPlaceholder || !isEqualValues(derivedValue);
|
|
2624
2625
|
const applyMultiSizeValue = (newValue) => {
|
|
2625
|
-
|
|
2626
|
-
|
|
2627
|
-
setMasterValue(Object.values(newValue)?.pop() ?? null);
|
|
2626
|
+
if (!isEqualValues(newValue)) {
|
|
2627
|
+
setMasterValue(multiSizePropTypeUtil.create(newValue));
|
|
2628
2628
|
return;
|
|
2629
2629
|
}
|
|
2630
|
-
setMasterValue(
|
|
2630
|
+
setMasterValue(Object.values(newValue)?.pop() ?? null);
|
|
2631
2631
|
};
|
|
2632
2632
|
return /* @__PURE__ */ React56.createElement(React56.Fragment, null, /* @__PURE__ */ React56.createElement(Grid8, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref: rowRefs[0] }, /* @__PURE__ */ React56.createElement(Grid8, { item: true, xs: 6 }, !isShowingGeneralIndicator ? /* @__PURE__ */ React56.createElement(ControlFormLabel, null, label) : /* @__PURE__ */ React56.createElement(ControlLabel, null, label)), /* @__PURE__ */ React56.createElement(Grid8, { item: true, xs: 6 }, /* @__PURE__ */ React56.createElement(Stack7, { direction: "row", alignItems: "center", gap: 1 }, /* @__PURE__ */ React56.createElement(Box7, { flexGrow: 1 }, /* @__PURE__ */ React56.createElement(
|
|
2633
2633
|
SizeControl,
|