@elementor/editor-controls 0.3.0 → 0.4.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/dist/index.js CHANGED
@@ -30,7 +30,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
30
30
  // src/index.ts
31
31
  var index_exports = {};
32
32
  __export(index_exports, {
33
- BackgroundOverlayRepeaterControl: () => BackgroundOverlayRepeaterControl,
33
+ BackgroundControl: () => BackgroundControl,
34
34
  BoundPropProvider: () => BoundPropProvider,
35
35
  BoxShadowRepeaterControl: () => BoxShadowRepeaterControl,
36
36
  ColorControl: () => ColorControl,
@@ -237,9 +237,10 @@ var ImageMediaControl = createControl(() => {
237
237
  var React8 = __toESM(require("react"));
238
238
  var import_editor_props2 = require("@elementor/editor-props");
239
239
  var import_ui5 = require("@elementor/ui");
240
- var SelectControl = createControl(({ options }) => {
240
+ var SelectControl = createControl(({ options, onChange }) => {
241
241
  const { value, setValue } = useBoundProp(import_editor_props2.stringPropTypeUtil);
242
242
  const handleChange = (event) => {
243
+ onChange?.(event.target.value, value);
243
244
  setValue(event.target.value);
244
245
  };
245
246
  return /* @__PURE__ */ React8.createElement(ControlActions, null, /* @__PURE__ */ React8.createElement(import_ui5.Select, { displayEmpty: true, size: "tiny", value: value ?? "", onChange: handleChange, fullWidth: true }, options.map(({ label, ...props }) => /* @__PURE__ */ React8.createElement(import_ui5.MenuItem, { key: props.value, ...props }, label))));
@@ -271,7 +272,16 @@ var import_ui7 = require("@elementor/ui");
271
272
  var TextControl = createControl(({ placeholder }) => {
272
273
  const { value, setValue } = useBoundProp(import_editor_props4.stringPropTypeUtil);
273
274
  const handleChange = (event) => setValue(event.target.value);
274
- return /* @__PURE__ */ React10.createElement(ControlActions, null, /* @__PURE__ */ React10.createElement(import_ui7.TextField, { size: "tiny", fullWidth: true, value, onChange: handleChange, placeholder }));
275
+ return /* @__PURE__ */ React10.createElement(ControlActions, null, /* @__PURE__ */ React10.createElement(
276
+ import_ui7.TextField,
277
+ {
278
+ size: "tiny",
279
+ fullWidth: true,
280
+ value: value ?? "",
281
+ onChange: handleChange,
282
+ placeholder
283
+ }
284
+ ));
275
285
  });
276
286
 
277
287
  // src/controls/text-area-control.tsx
@@ -290,7 +300,7 @@ var TextAreaControl = createControl(({ placeholder }) => {
290
300
  multiline: true,
291
301
  fullWidth: true,
292
302
  rows: 5,
293
- value,
303
+ value: value ?? "",
294
304
  onChange: handleChange,
295
305
  placeholder
296
306
  }
@@ -445,7 +455,16 @@ var ColorControl = createControl(
445
455
  const handleChange = (selectedColor) => {
446
456
  setValue(selectedColor);
447
457
  };
448
- return /* @__PURE__ */ React14.createElement(ControlActions, null, /* @__PURE__ */ React14.createElement(import_ui11.UnstableColorField, { size: "tiny", ...props, value, onChange: handleChange, fullWidth: true }));
458
+ return /* @__PURE__ */ React14.createElement(ControlActions, null, /* @__PURE__ */ React14.createElement(
459
+ import_ui11.UnstableColorField,
460
+ {
461
+ size: "tiny",
462
+ ...props,
463
+ value: value ?? "",
464
+ onChange: handleChange,
465
+ fullWidth: true
466
+ }
467
+ ));
449
468
  }
450
469
  );
451
470
 
@@ -785,82 +804,14 @@ var initialShadow = {
785
804
  }
786
805
  };
787
806
 
788
- // src/controls/background-overlay-repeater-control.tsx
789
- var React18 = __toESM(require("react"));
790
- var import_editor_props10 = require("@elementor/editor-props");
791
- var import_ui15 = require("@elementor/ui");
792
- var import_i18n6 = require("@wordpress/i18n");
793
- var BackgroundOverlayRepeaterControl = createControl(() => {
794
- const { value: colorOverlayValues, setValue } = useBoundProp(import_editor_props10.backgroundImagePropTypeUtil);
795
- const setColorOverlay = (newValue) => {
796
- setValue(newValue);
797
- };
798
- return /* @__PURE__ */ React18.createElement(
799
- Repeater,
800
- {
801
- values: colorOverlayValues,
802
- setValues: setColorOverlay,
803
- label: (0, import_i18n6.__)("Overlay", "elementor"),
804
- itemSettings: {
805
- Icon: ItemIcon2,
806
- Label: ItemLabel2,
807
- Content: ItemContent2,
808
- initialValues: initialGradient
809
- }
810
- }
811
- );
812
- });
813
- var ItemIcon2 = ({ value }) => /* @__PURE__ */ React18.createElement(import_ui15.UnstableColorIndicator, { size: "inherit", component: "span", value: value.value.color.value });
814
- var ItemContent2 = ({
815
- value,
816
- setValue
817
- }) => {
818
- const setColor = (newValue) => {
819
- setValue({
820
- $$type: "background-overlay",
821
- value: newValue
822
- });
823
- };
824
- return /* @__PURE__ */ React18.createElement(import_ui15.Stack, { gap: 1.5 }, /* @__PURE__ */ React18.createElement(
825
- Control3,
826
- {
827
- bind: "color",
828
- value: value.value.color,
829
- label: (0, import_i18n6.__)("Color", "elementor"),
830
- setValue: (v) => setColor({ ...value.value, color: v })
831
- },
832
- /* @__PURE__ */ React18.createElement(ColorControl, null)
833
- ));
834
- };
835
- var Control3 = ({
836
- value,
837
- setValue,
838
- label,
839
- bind,
840
- children
841
- }) => /* @__PURE__ */ React18.createElement(BoundPropProvider, { value, setValue, bind }, /* @__PURE__ */ React18.createElement(import_ui15.Grid, { container: true, spacing: 1, alignItems: "center" }, /* @__PURE__ */ React18.createElement(import_ui15.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React18.createElement(import_ui15.Typography, { component: "label", variant: "caption", color: "text.secondary" }, label)), /* @__PURE__ */ React18.createElement(import_ui15.Grid, { item: true, xs: 12 }, children)));
842
- var ItemLabel2 = ({ value }) => {
843
- const color = value.value.color.value;
844
- return /* @__PURE__ */ React18.createElement("span", null, color);
845
- };
846
- var initialGradient = {
847
- $$type: "background-overlay",
848
- value: {
849
- color: {
850
- $$type: "color",
851
- value: "rgba(0, 0, 0, 0.2)"
852
- }
853
- }
854
- };
855
-
856
807
  // src/controls/toggle-control.tsx
857
- var React20 = __toESM(require("react"));
858
- var import_editor_props11 = require("@elementor/editor-props");
808
+ var React19 = __toESM(require("react"));
809
+ var import_editor_props10 = require("@elementor/editor-props");
859
810
 
860
811
  // src/components/control-toggle-button-group.tsx
861
- var React19 = __toESM(require("react"));
862
- var import_ui16 = require("@elementor/ui");
863
- var StyledToggleButtonGroup = (0, import_ui16.styled)(import_ui16.ToggleButtonGroup)`
812
+ var React18 = __toESM(require("react"));
813
+ var import_ui15 = require("@elementor/ui");
814
+ var StyledToggleButtonGroup = (0, import_ui15.styled)(import_ui15.ToggleButtonGroup)`
864
815
  ${({ justify }) => `justify-content: ${justify};`}
865
816
  `;
866
817
  var ControlToggleButtonGroup = ({
@@ -872,11 +823,11 @@ var ControlToggleButtonGroup = ({
872
823
  exclusive = false,
873
824
  fullWidth = false
874
825
  }) => {
875
- const isRtl = "rtl" === (0, import_ui16.useTheme)().direction;
826
+ const isRtl = "rtl" === (0, import_ui15.useTheme)().direction;
876
827
  const handleChange = (_, newValue) => {
877
828
  onChange(newValue);
878
829
  };
879
- return /* @__PURE__ */ React19.createElement(
830
+ return /* @__PURE__ */ React18.createElement(
880
831
  StyledToggleButtonGroup,
881
832
  {
882
833
  justify,
@@ -888,8 +839,8 @@ var ControlToggleButtonGroup = ({
888
839
  }
889
840
  },
890
841
  items.map(
891
- ({ label, value: buttonValue, renderContent: Content, showTooltip }) => showTooltip ? /* @__PURE__ */ React19.createElement(import_ui16.Tooltip, { key: buttonValue, title: label, disableFocusListener: true, placement: "top" }, /* @__PURE__ */ React19.createElement(import_ui16.ToggleButton, { value: buttonValue, "aria-label": label, size, fullWidth }, /* @__PURE__ */ React19.createElement(Content, { size }))) : /* @__PURE__ */ React19.createElement(
892
- import_ui16.ToggleButton,
842
+ ({ label, value: buttonValue, renderContent: Content, showTooltip }) => showTooltip ? /* @__PURE__ */ React18.createElement(import_ui15.Tooltip, { key: buttonValue, title: label, disableFocusListener: true, placement: "top" }, /* @__PURE__ */ React18.createElement(import_ui15.ToggleButton, { value: buttonValue, "aria-label": label, size, fullWidth }, /* @__PURE__ */ React18.createElement(Content, { size }))) : /* @__PURE__ */ React18.createElement(
843
+ import_ui15.ToggleButton,
893
844
  {
894
845
  key: buttonValue,
895
846
  value: buttonValue,
@@ -897,7 +848,7 @@ var ControlToggleButtonGroup = ({
897
848
  size,
898
849
  fullWidth
899
850
  },
900
- /* @__PURE__ */ React19.createElement(Content, { size })
851
+ /* @__PURE__ */ React18.createElement(Content, { size })
901
852
  )
902
853
  )
903
854
  );
@@ -906,11 +857,11 @@ var ControlToggleButtonGroup = ({
906
857
  // src/controls/toggle-control.tsx
907
858
  var ToggleControl = createControl(
908
859
  ({ options, fullWidth = false, size = "tiny" }) => {
909
- const { value, setValue } = useBoundProp(import_editor_props11.stringPropTypeUtil);
860
+ const { value, setValue } = useBoundProp(import_editor_props10.stringPropTypeUtil);
910
861
  const handleToggle = (option) => {
911
862
  setValue(option);
912
863
  };
913
- return /* @__PURE__ */ React20.createElement(
864
+ return /* @__PURE__ */ React19.createElement(
914
865
  ControlToggleButtonGroup,
915
866
  {
916
867
  items: options,
@@ -925,9 +876,9 @@ var ToggleControl = createControl(
925
876
  );
926
877
 
927
878
  // src/controls/number-control.tsx
928
- var React21 = __toESM(require("react"));
929
- var import_editor_props12 = require("@elementor/editor-props");
930
- var import_ui17 = require("@elementor/ui");
879
+ var React20 = __toESM(require("react"));
880
+ var import_editor_props11 = require("@elementor/editor-props");
881
+ var import_ui16 = require("@elementor/ui");
931
882
  var isEmptyOrNaN = (value) => value === null || value === void 0 || value === "" || Number.isNaN(Number(value));
932
883
  var NumberControl = createControl(
933
884
  ({
@@ -937,7 +888,7 @@ var NumberControl = createControl(
937
888
  step = 1,
938
889
  shouldForceInt = false
939
890
  }) => {
940
- const { value, setValue } = useBoundProp(import_editor_props12.numberPropTypeUtil);
891
+ const { value, setValue } = useBoundProp(import_editor_props11.numberPropTypeUtil);
941
892
  const handleChange = (event) => {
942
893
  const eventValue = event.target.value;
943
894
  if (isEmptyOrNaN(eventValue)) {
@@ -947,8 +898,8 @@ var NumberControl = createControl(
947
898
  const formattedValue = shouldForceInt ? +parseInt(eventValue) : Number(eventValue);
948
899
  setValue(Math.min(Math.max(formattedValue, min), max));
949
900
  };
950
- return /* @__PURE__ */ React21.createElement(ControlActions, null, /* @__PURE__ */ React21.createElement(
951
- import_ui17.TextField,
901
+ return /* @__PURE__ */ React20.createElement(ControlActions, null, /* @__PURE__ */ React20.createElement(
902
+ import_ui16.TextField,
952
903
  {
953
904
  size: "tiny",
954
905
  type: "number",
@@ -963,11 +914,11 @@ var NumberControl = createControl(
963
914
  );
964
915
 
965
916
  // src/controls/equal-unequal-sizes-control.tsx
966
- var React22 = __toESM(require("react"));
917
+ var React21 = __toESM(require("react"));
967
918
  var import_react7 = require("react");
968
- var import_editor_props13 = require("@elementor/editor-props");
969
- var import_ui18 = require("@elementor/ui");
970
- var import_i18n7 = require("@wordpress/i18n");
919
+ var import_editor_props12 = require("@elementor/editor-props");
920
+ var import_ui17 = require("@elementor/ui");
921
+ var import_i18n6 = require("@wordpress/i18n");
971
922
  var isEqualSizes = (values, items) => {
972
923
  if (values.length !== items.length) {
973
924
  return false;
@@ -985,11 +936,14 @@ function EqualUnequalSizesControl({
985
936
  }) {
986
937
  const popupId = (0, import_react7.useId)();
987
938
  const controlRef = (0, import_react7.useRef)(null);
988
- const popupState = (0, import_ui18.usePopupState)({ variant: "popover", popupId });
989
- const { value: sizeValue, setValue: setSizeValue } = useBoundProp(import_editor_props13.sizePropTypeUtil);
939
+ const popupState = (0, import_ui17.usePopupState)({ variant: "popover", popupId });
940
+ const { value: sizeValue, setValue: setSizeValue } = useBoundProp(import_editor_props12.sizePropTypeUtil);
990
941
  const { value: multiSizeValue, setValue: setMultiSizeValue } = useBoundProp(multiSizePropTypeUtil);
991
942
  const splitEqualValue = () => {
992
- return items.reduce((acc, item) => ({ ...acc, [item.bind]: import_editor_props13.sizePropTypeUtil.create(sizeValue) }), {});
943
+ if (!sizeValue) {
944
+ return {};
945
+ }
946
+ return items.reduce((acc, { bind }) => ({ ...acc, [bind]: import_editor_props12.sizePropTypeUtil.create(sizeValue) }), {});
993
947
  };
994
948
  const setNestedProp = (item, newValue) => {
995
949
  const newMappedValues = {
@@ -1002,27 +956,27 @@ function EqualUnequalSizesControl({
1002
956
  }
1003
957
  setMultiSizeValue(newMappedValues);
1004
958
  };
1005
- return /* @__PURE__ */ React22.createElement(React22.Fragment, null, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref: controlRef }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, label)), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React22.createElement(
959
+ return /* @__PURE__ */ React21.createElement(React21.Fragment, null, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref: controlRef }, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React21.createElement(ControlLabel, null, label)), /* @__PURE__ */ React21.createElement(import_ui17.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React21.createElement(
1006
960
  EqualSizeControl,
1007
961
  {
1008
962
  items,
1009
963
  value: sizeValue,
1010
964
  multiSizeValue,
1011
965
  setValue: setSizeValue,
1012
- iconButton: /* @__PURE__ */ React22.createElement(
1013
- import_ui18.ToggleButton,
966
+ iconButton: /* @__PURE__ */ React21.createElement(
967
+ import_ui17.ToggleButton,
1014
968
  {
1015
969
  size: "tiny",
1016
970
  value: "check",
1017
971
  sx: { marginLeft: "auto" },
1018
- ...(0, import_ui18.bindToggle)(popupState),
972
+ ...(0, import_ui17.bindToggle)(popupState),
1019
973
  selected: popupState.isOpen
1020
974
  },
1021
975
  icon
1022
976
  )
1023
977
  }
1024
- ))), /* @__PURE__ */ React22.createElement(
1025
- import_ui18.Popover,
978
+ ))), /* @__PURE__ */ React21.createElement(
979
+ import_ui17.Popover,
1026
980
  {
1027
981
  disablePortal: true,
1028
982
  disableScrollLock: true,
@@ -1034,12 +988,12 @@ function EqualUnequalSizesControl({
1034
988
  vertical: "top",
1035
989
  horizontal: "right"
1036
990
  },
1037
- ...(0, import_ui18.bindPopover)(popupState),
991
+ ...(0, import_ui17.bindPopover)(popupState),
1038
992
  slotProps: {
1039
993
  paper: { sx: { mt: 0.5, p: 2, pt: 1, width: controlRef.current?.getBoundingClientRect().width } }
1040
994
  }
1041
995
  },
1042
- /* @__PURE__ */ React22.createElement(import_ui18.Stack, { gap: 1.5 }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React22.createElement(
996
+ /* @__PURE__ */ React21.createElement(import_ui17.Stack, { gap: 1.5 }, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React21.createElement(
1043
997
  MultiSizeValueControl,
1044
998
  {
1045
999
  item: items[0],
@@ -1047,7 +1001,7 @@ function EqualUnequalSizesControl({
1047
1001
  setNestedProp,
1048
1002
  splitEqualValue
1049
1003
  }
1050
- ), /* @__PURE__ */ React22.createElement(
1004
+ ), /* @__PURE__ */ React21.createElement(
1051
1005
  MultiSizeValueControl,
1052
1006
  {
1053
1007
  item: items[1],
@@ -1055,7 +1009,7 @@ function EqualUnequalSizesControl({
1055
1009
  setNestedProp,
1056
1010
  splitEqualValue
1057
1011
  }
1058
- )), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React22.createElement(
1012
+ )), /* @__PURE__ */ React21.createElement(import_ui17.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React21.createElement(
1059
1013
  MultiSizeValueControl,
1060
1014
  {
1061
1015
  item: items[3],
@@ -1063,7 +1017,7 @@ function EqualUnequalSizesControl({
1063
1017
  setNestedProp,
1064
1018
  splitEqualValue
1065
1019
  }
1066
- ), /* @__PURE__ */ React22.createElement(
1020
+ ), /* @__PURE__ */ React21.createElement(
1067
1021
  MultiSizeValueControl,
1068
1022
  {
1069
1023
  item: items[2],
@@ -1087,7 +1041,7 @@ var MultiSizeValueControl = ({
1087
1041
  }
1088
1042
  return splitEqualValue()?.[item.bind] ?? null;
1089
1043
  };
1090
- return /* @__PURE__ */ React22.createElement(BoundPropProvider, { bind: "", setValue: handleChange, value: getMultiSizeValues() }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, item.label)), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(SizeControl, { startIcon: item.icon })))));
1044
+ return /* @__PURE__ */ React21.createElement(BoundPropProvider, { bind: "", setValue: handleChange, value: getMultiSizeValues() }, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React21.createElement(import_ui17.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React21.createElement(ControlLabel, null, item.label)), /* @__PURE__ */ React21.createElement(import_ui17.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React21.createElement(SizeControl, { startIcon: item.icon })))));
1091
1045
  };
1092
1046
  var EqualSizeControl = ({
1093
1047
  value,
@@ -1101,24 +1055,24 @@ var EqualSizeControl = ({
1101
1055
  };
1102
1056
  const getDisplayValue = () => {
1103
1057
  if (value) {
1104
- return import_editor_props13.sizePropTypeUtil.create(value);
1058
+ return import_editor_props12.sizePropTypeUtil.create(value);
1105
1059
  }
1106
1060
  const multiValues = Object.values(multiSizeValue ?? {});
1107
1061
  if (isEqualSizes(multiValues, items)) {
1108
- return import_editor_props13.sizePropTypeUtil.create(multiValues[0].value);
1062
+ return import_editor_props12.sizePropTypeUtil.create(multiValues[0].value);
1109
1063
  }
1110
1064
  };
1111
- return /* @__PURE__ */ React22.createElement(BoundPropProvider, { bind: "", setValue: handleChange, value: getDisplayValue() ?? null }, /* @__PURE__ */ React22.createElement(import_ui18.Stack, { direction: "row", alignItems: "center", gap: 1 }, /* @__PURE__ */ React22.createElement(SizeControl, { placeholder: (0, import_i18n7.__)("MIXED", "elementor") }), iconButton));
1065
+ return /* @__PURE__ */ React21.createElement(BoundPropProvider, { bind: "", setValue: handleChange, value: getDisplayValue() ?? null }, /* @__PURE__ */ React21.createElement(import_ui17.Stack, { direction: "row", alignItems: "center", gap: 1 }, /* @__PURE__ */ React21.createElement(SizeControl, { placeholder: (0, import_i18n6.__)("MIXED", "elementor") }), iconButton));
1112
1066
  };
1113
1067
 
1114
1068
  // src/controls/linked-dimensions-control.tsx
1115
- var React23 = __toESM(require("react"));
1116
- var import_editor_props14 = require("@elementor/editor-props");
1069
+ var React22 = __toESM(require("react"));
1070
+ var import_editor_props13 = require("@elementor/editor-props");
1117
1071
  var import_icons3 = require("@elementor/icons");
1118
- var import_ui19 = require("@elementor/ui");
1119
- var import_i18n8 = require("@wordpress/i18n");
1072
+ var import_ui18 = require("@elementor/ui");
1073
+ var import_i18n7 = require("@wordpress/i18n");
1120
1074
  var LinkedDimensionsControl = createControl(({ label }) => {
1121
- const { value, setValue } = useBoundProp(import_editor_props14.linkedDimensionsPropTypeUtil);
1075
+ const { value, setValue } = useBoundProp(import_editor_props13.linkedDimensionsPropTypeUtil);
1122
1076
  const { top, right, bottom, left, isLinked = true } = value || {};
1123
1077
  const setLinkedValue = (position, newValue) => {
1124
1078
  const updatedValue = {
@@ -1142,72 +1096,72 @@ var LinkedDimensionsControl = createControl(({ label }) => {
1142
1096
  setValue(updatedValue);
1143
1097
  };
1144
1098
  const LinkedIcon = isLinked ? import_icons3.LinkIcon : import_icons3.DetachIcon;
1145
- return /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(import_ui19.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React23.createElement(ControlLabel, null, label), /* @__PURE__ */ React23.createElement(
1146
- import_ui19.ToggleButton,
1099
+ return /* @__PURE__ */ React22.createElement(React22.Fragment, null, /* @__PURE__ */ React22.createElement(import_ui18.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React22.createElement(ControlLabel, null, label), /* @__PURE__ */ React22.createElement(
1100
+ import_ui18.ToggleButton,
1147
1101
  {
1148
- "aria-label": (0, import_i18n8.__)("Link Inputs", "elementor"),
1102
+ "aria-label": (0, import_i18n7.__)("Link Inputs", "elementor"),
1149
1103
  size: "tiny",
1150
1104
  value: "check",
1151
1105
  selected: isLinked,
1152
1106
  sx: { marginLeft: "auto" },
1153
1107
  onChange: toggleLinked
1154
1108
  },
1155
- /* @__PURE__ */ React23.createElement(LinkedIcon, { fontSize: "tiny" })
1156
- )), /* @__PURE__ */ React23.createElement(import_ui19.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(ControlLabel, null, (0, import_i18n8.__)("Top", "elementor"))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(
1157
- Control4,
1109
+ /* @__PURE__ */ React22.createElement(LinkedIcon, { fontSize: "tiny" })
1110
+ )), /* @__PURE__ */ React22.createElement(import_ui18.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, (0, import_i18n7.__)("Top", "elementor"))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(
1111
+ Control3,
1158
1112
  {
1159
1113
  bind: "top",
1160
1114
  value: top,
1161
1115
  setValue: setLinkedValue,
1162
- startIcon: /* @__PURE__ */ React23.createElement(import_icons3.SideTopIcon, { fontSize: "tiny" })
1116
+ startIcon: /* @__PURE__ */ React22.createElement(import_icons3.SideTopIcon, { fontSize: "tiny" })
1163
1117
  }
1164
- ))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(ControlLabel, null, (0, import_i18n8.__)("Right", "elementor"))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(
1165
- Control4,
1118
+ ))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, (0, import_i18n7.__)("Right", "elementor"))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(
1119
+ Control3,
1166
1120
  {
1167
1121
  bind: "right",
1168
1122
  value: right,
1169
1123
  setValue: setLinkedValue,
1170
- startIcon: /* @__PURE__ */ React23.createElement(import_icons3.SideRightIcon, { fontSize: "tiny" })
1124
+ startIcon: /* @__PURE__ */ React22.createElement(import_icons3.SideRightIcon, { fontSize: "tiny" })
1171
1125
  }
1172
- )))), /* @__PURE__ */ React23.createElement(import_ui19.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(ControlLabel, null, (0, import_i18n8.__)("Bottom", "elementor"))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(
1173
- Control4,
1126
+ )))), /* @__PURE__ */ React22.createElement(import_ui18.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, (0, import_i18n7.__)("Bottom", "elementor"))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(
1127
+ Control3,
1174
1128
  {
1175
1129
  bind: "bottom",
1176
1130
  value: bottom,
1177
1131
  setValue: setLinkedValue,
1178
- startIcon: /* @__PURE__ */ React23.createElement(import_icons3.SideBottomIcon, { fontSize: "tiny" })
1132
+ startIcon: /* @__PURE__ */ React22.createElement(import_icons3.SideBottomIcon, { fontSize: "tiny" })
1179
1133
  }
1180
- ))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(ControlLabel, null, (0, import_i18n8.__)("Left", "elementor"))), /* @__PURE__ */ React23.createElement(import_ui19.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React23.createElement(
1181
- Control4,
1134
+ ))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(ControlLabel, null, (0, import_i18n7.__)("Left", "elementor"))), /* @__PURE__ */ React22.createElement(import_ui18.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React22.createElement(
1135
+ Control3,
1182
1136
  {
1183
1137
  bind: "left",
1184
1138
  value: left,
1185
1139
  setValue: setLinkedValue,
1186
- startIcon: /* @__PURE__ */ React23.createElement(import_icons3.SideLeftIcon, { fontSize: "tiny" })
1140
+ startIcon: /* @__PURE__ */ React22.createElement(import_icons3.SideLeftIcon, { fontSize: "tiny" })
1187
1141
  }
1188
1142
  )))));
1189
1143
  });
1190
- var Control4 = ({
1144
+ var Control3 = ({
1191
1145
  bind,
1192
1146
  startIcon,
1193
1147
  value,
1194
1148
  setValue
1195
- }) => /* @__PURE__ */ React23.createElement(BoundPropProvider, { setValue: (newValue) => setValue(bind, newValue), value, bind }, /* @__PURE__ */ React23.createElement(SizeControl, { startIcon }));
1149
+ }) => /* @__PURE__ */ React22.createElement(BoundPropProvider, { setValue: (newValue) => setValue(bind, newValue), value, bind }, /* @__PURE__ */ React22.createElement(SizeControl, { startIcon }));
1196
1150
 
1197
1151
  // src/controls/font-family-control.tsx
1198
1152
  var import_react8 = require("react");
1199
- var React24 = __toESM(require("react"));
1200
- var import_editor_props15 = require("@elementor/editor-props");
1153
+ var React23 = __toESM(require("react"));
1154
+ var import_editor_props14 = require("@elementor/editor-props");
1201
1155
  var import_icons4 = require("@elementor/icons");
1202
- var import_ui20 = require("@elementor/ui");
1203
- var import_i18n10 = require("@wordpress/i18n");
1156
+ var import_ui19 = require("@elementor/ui");
1157
+ var import_i18n9 = require("@wordpress/i18n");
1204
1158
 
1205
1159
  // src/hooks/use-filtered-font-families.ts
1206
- var import_i18n9 = require("@wordpress/i18n");
1160
+ var import_i18n8 = require("@wordpress/i18n");
1207
1161
  var supportedCategories = {
1208
- system: (0, import_i18n9.__)("System", "elementor"),
1209
- googlefonts: (0, import_i18n9.__)("Google Fonts", "elementor"),
1210
- customfonts: (0, import_i18n9.__)("Custom Fonts", "elementor")
1162
+ system: (0, import_i18n8.__)("System", "elementor"),
1163
+ googlefonts: (0, import_i18n8.__)("Google Fonts", "elementor"),
1164
+ customfonts: (0, import_i18n8.__)("Custom Fonts", "elementor")
1211
1165
  };
1212
1166
  var useFilteredFontFamilies = (fontFamilies, searchValue) => {
1213
1167
  const filteredFontFamilies = Object.entries(fontFamilies).reduce(
@@ -1236,9 +1190,9 @@ var useFilteredFontFamilies = (fontFamilies, searchValue) => {
1236
1190
  var SIZE2 = "tiny";
1237
1191
  var FontFamilyControl = createControl(({ fontFamilies }) => {
1238
1192
  const [searchValue, setSearchValue] = (0, import_react8.useState)("");
1239
- const { value: fontFamily, setValue: setFontFamily } = useBoundProp(import_editor_props15.stringPropTypeUtil);
1193
+ const { value: fontFamily, setValue: setFontFamily } = useBoundProp(import_editor_props14.stringPropTypeUtil);
1240
1194
  const popupId = (0, import_react8.useId)();
1241
- const popoverState = (0, import_ui20.usePopupState)({ variant: "popover", popupId });
1195
+ const popoverState = (0, import_ui19.usePopupState)({ variant: "popover", popupId });
1242
1196
  const filteredFontFamilies = useFilteredFontFamilies(fontFamilies, searchValue);
1243
1197
  if (!filteredFontFamilies) {
1244
1198
  return null;
@@ -1250,40 +1204,40 @@ var FontFamilyControl = createControl(({ fontFamilies }) => {
1250
1204
  setSearchValue("");
1251
1205
  popoverState.close();
1252
1206
  };
1253
- return /* @__PURE__ */ React24.createElement(React24.Fragment, null, /* @__PURE__ */ React24.createElement(
1254
- import_ui20.UnstableTag,
1207
+ return /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(
1208
+ import_ui19.UnstableTag,
1255
1209
  {
1256
1210
  variant: "outlined",
1257
1211
  label: fontFamily,
1258
- endIcon: /* @__PURE__ */ React24.createElement(import_icons4.ChevronDownIcon, { fontSize: "tiny" }),
1259
- ...(0, import_ui20.bindTrigger)(popoverState),
1212
+ endIcon: /* @__PURE__ */ React23.createElement(import_icons4.ChevronDownIcon, { fontSize: "tiny" }),
1213
+ ...(0, import_ui19.bindTrigger)(popoverState),
1260
1214
  fullWidth: true
1261
1215
  }
1262
- ), /* @__PURE__ */ React24.createElement(
1263
- import_ui20.Popover,
1216
+ ), /* @__PURE__ */ React23.createElement(
1217
+ import_ui19.Popover,
1264
1218
  {
1265
1219
  disablePortal: true,
1266
1220
  disableScrollLock: true,
1267
1221
  anchorOrigin: { vertical: "bottom", horizontal: "left" },
1268
- ...(0, import_ui20.bindPopover)(popoverState),
1222
+ ...(0, import_ui19.bindPopover)(popoverState),
1269
1223
  onClose: handleClose
1270
1224
  },
1271
- /* @__PURE__ */ React24.createElement(import_ui20.Stack, null, /* @__PURE__ */ React24.createElement(import_ui20.Stack, { direction: "row", alignItems: "center", pl: 1.5, pr: 0.5, py: 1.5 }, /* @__PURE__ */ React24.createElement(import_icons4.EditIcon, { fontSize: SIZE2, sx: { mr: 0.5 } }), /* @__PURE__ */ React24.createElement(import_ui20.Typography, { variant: "subtitle2" }, (0, import_i18n10.__)("Font Family", "elementor")), /* @__PURE__ */ React24.createElement(import_ui20.IconButton, { size: SIZE2, sx: { ml: "auto" }, onClick: handleClose }, /* @__PURE__ */ React24.createElement(import_icons4.XIcon, { fontSize: SIZE2 }))), /* @__PURE__ */ React24.createElement(import_ui20.Box, { px: 1.5, pb: 1 }, /* @__PURE__ */ React24.createElement(
1272
- import_ui20.TextField,
1225
+ /* @__PURE__ */ React23.createElement(import_ui19.Stack, null, /* @__PURE__ */ React23.createElement(import_ui19.Stack, { direction: "row", alignItems: "center", pl: 1.5, pr: 0.5, py: 1.5 }, /* @__PURE__ */ React23.createElement(import_icons4.EditIcon, { fontSize: SIZE2, sx: { mr: 0.5 } }), /* @__PURE__ */ React23.createElement(import_ui19.Typography, { variant: "subtitle2" }, (0, import_i18n9.__)("Font Family", "elementor")), /* @__PURE__ */ React23.createElement(import_ui19.IconButton, { size: SIZE2, sx: { ml: "auto" }, onClick: handleClose }, /* @__PURE__ */ React23.createElement(import_icons4.XIcon, { fontSize: SIZE2 }))), /* @__PURE__ */ React23.createElement(import_ui19.Box, { px: 1.5, pb: 1 }, /* @__PURE__ */ React23.createElement(
1226
+ import_ui19.TextField,
1273
1227
  {
1274
1228
  fullWidth: true,
1275
1229
  size: SIZE2,
1276
1230
  value: searchValue,
1277
- placeholder: (0, import_i18n10.__)("Search", "elementor"),
1231
+ placeholder: (0, import_i18n9.__)("Search", "elementor"),
1278
1232
  onChange: handleSearch,
1279
1233
  InputProps: {
1280
- startAdornment: /* @__PURE__ */ React24.createElement(import_ui20.InputAdornment, { position: "start" }, /* @__PURE__ */ React24.createElement(import_icons4.SearchIcon, { fontSize: SIZE2 }))
1234
+ startAdornment: /* @__PURE__ */ React23.createElement(import_ui19.InputAdornment, { position: "start" }, /* @__PURE__ */ React23.createElement(import_icons4.SearchIcon, { fontSize: SIZE2 }))
1281
1235
  }
1282
1236
  }
1283
- )), /* @__PURE__ */ React24.createElement(import_ui20.Divider, null), /* @__PURE__ */ React24.createElement(import_ui20.Box, { sx: { overflowY: "auto", height: 260, width: 220 } }, filteredFontFamilies.length > 0 ? /* @__PURE__ */ React24.createElement(import_ui20.MenuList, { role: "listbox", tabIndex: 0 }, filteredFontFamilies.map(([category, items], index) => /* @__PURE__ */ React24.createElement(import_react8.Fragment, { key: index }, /* @__PURE__ */ React24.createElement(import_ui20.ListSubheader, { sx: { typography: "caption", color: "text.tertiary" } }, category), items.map((item) => {
1237
+ )), /* @__PURE__ */ React23.createElement(import_ui19.Divider, null), /* @__PURE__ */ React23.createElement(import_ui19.Box, { sx: { overflowY: "auto", height: 260, width: 220 } }, filteredFontFamilies.length > 0 ? /* @__PURE__ */ React23.createElement(import_ui19.MenuList, { role: "listbox", tabIndex: 0 }, filteredFontFamilies.map(([category, items], index) => /* @__PURE__ */ React23.createElement(import_react8.Fragment, { key: index }, /* @__PURE__ */ React23.createElement(import_ui19.ListSubheader, { sx: { typography: "caption", color: "text.tertiary" } }, category), items.map((item) => {
1284
1238
  const isSelected = item === fontFamily;
1285
- return /* @__PURE__ */ React24.createElement(
1286
- import_ui20.MenuItem,
1239
+ return /* @__PURE__ */ React23.createElement(
1240
+ import_ui19.MenuItem,
1287
1241
  {
1288
1242
  key: item,
1289
1243
  selected: isSelected,
@@ -1297,30 +1251,30 @@ var FontFamilyControl = createControl(({ fontFamilies }) => {
1297
1251
  },
1298
1252
  item
1299
1253
  );
1300
- })))) : /* @__PURE__ */ React24.createElement(import_ui20.Stack, { alignItems: "center", p: 2.5, gap: 1.5 }, /* @__PURE__ */ React24.createElement(import_icons4.PhotoIcon, { fontSize: "large" }), /* @__PURE__ */ React24.createElement(import_ui20.Typography, { align: "center", variant: "caption", color: "text.secondary" }, (0, import_i18n10.__)("Sorry, nothing matched", "elementor"), /* @__PURE__ */ React24.createElement("br", null), "\u201C", searchValue, "\u201D."), /* @__PURE__ */ React24.createElement(import_ui20.Typography, { align: "center", variant: "caption", color: "text.secondary" }, /* @__PURE__ */ React24.createElement(
1301
- import_ui20.Link,
1254
+ })))) : /* @__PURE__ */ React23.createElement(import_ui19.Stack, { alignItems: "center", p: 2.5, gap: 1.5 }, /* @__PURE__ */ React23.createElement(import_icons4.PhotoIcon, { fontSize: "large" }), /* @__PURE__ */ React23.createElement(import_ui19.Typography, { align: "center", variant: "caption", color: "text.secondary" }, (0, import_i18n9.__)("Sorry, nothing matched", "elementor"), /* @__PURE__ */ React23.createElement("br", null), "\u201C", searchValue, "\u201D."), /* @__PURE__ */ React23.createElement(import_ui19.Typography, { align: "center", variant: "caption", color: "text.secondary" }, /* @__PURE__ */ React23.createElement(
1255
+ import_ui19.Link,
1302
1256
  {
1303
1257
  color: "secondary",
1304
1258
  variant: "caption",
1305
1259
  component: "button",
1306
1260
  onClick: () => setSearchValue("")
1307
1261
  },
1308
- (0, import_i18n10.__)("Clear the filters", "elementor")
1309
- ), "\xA0", (0, import_i18n10.__)("and try again.", "elementor")))))
1262
+ (0, import_i18n9.__)("Clear the filters", "elementor")
1263
+ ), "\xA0", (0, import_i18n9.__)("and try again.", "elementor")))))
1310
1264
  ));
1311
1265
  });
1312
1266
 
1313
1267
  // src/controls/url-control.tsx
1314
- var React25 = __toESM(require("react"));
1315
- var import_ui21 = require("@elementor/ui");
1268
+ var React24 = __toESM(require("react"));
1269
+ var import_ui20 = require("@elementor/ui");
1316
1270
  var UrlControl = createControl(({ placeholder }) => {
1317
1271
  const { value, setValue } = useBoundProp();
1318
1272
  const handleChange = (event) => setValue({
1319
1273
  $$type: "url",
1320
1274
  value: event.target.value
1321
1275
  });
1322
- return /* @__PURE__ */ React25.createElement(ControlActions, null, /* @__PURE__ */ React25.createElement(
1323
- import_ui21.TextField,
1276
+ return /* @__PURE__ */ React24.createElement(ControlActions, null, /* @__PURE__ */ React24.createElement(
1277
+ import_ui20.TextField,
1324
1278
  {
1325
1279
  size: "tiny",
1326
1280
  fullWidth: true,
@@ -1332,10 +1286,10 @@ var UrlControl = createControl(({ placeholder }) => {
1332
1286
  });
1333
1287
 
1334
1288
  // src/controls/link-control.tsx
1335
- var React26 = __toESM(require("react"));
1289
+ var React25 = __toESM(require("react"));
1336
1290
  var import_icons5 = require("@elementor/icons");
1337
- var import_ui22 = require("@elementor/ui");
1338
- var import_i18n11 = require("@wordpress/i18n");
1291
+ var import_ui21 = require("@elementor/ui");
1292
+ var import_i18n10 = require("@wordpress/i18n");
1339
1293
  var SIZE3 = "tiny";
1340
1294
  var DEFAULT_LINK_CONTROL_VALUE = {
1341
1295
  $$type: "link",
@@ -1360,8 +1314,8 @@ var LinkControl = createControl(() => {
1360
1314
  }
1361
1315
  });
1362
1316
  };
1363
- return /* @__PURE__ */ React26.createElement(import_ui22.Stack, { gap: 1.5 }, /* @__PURE__ */ React26.createElement(import_ui22.Divider, null), /* @__PURE__ */ React26.createElement(
1364
- import_ui22.Stack,
1317
+ return /* @__PURE__ */ React25.createElement(import_ui21.Stack, { gap: 1.5 }, /* @__PURE__ */ React25.createElement(import_ui21.Divider, null), /* @__PURE__ */ React25.createElement(
1318
+ import_ui21.Stack,
1365
1319
  {
1366
1320
  direction: "row",
1367
1321
  sx: {
@@ -1369,17 +1323,17 @@ var LinkControl = createControl(() => {
1369
1323
  alignItems: "center"
1370
1324
  }
1371
1325
  },
1372
- /* @__PURE__ */ React26.createElement(ControlLabel, null, (0, import_i18n11.__)("Link", "elementor")),
1373
- /* @__PURE__ */ React26.createElement(import_ui22.IconButton, { size: SIZE3, onClick: () => handleOnChange("enabled", !enabled) }, enabled ? /* @__PURE__ */ React26.createElement(import_icons5.MinusIcon, { fontSize: SIZE3 }) : /* @__PURE__ */ React26.createElement(import_icons5.PlusIcon, { fontSize: SIZE3 }))
1374
- ), /* @__PURE__ */ React26.createElement(import_ui22.Collapse, { in: enabled, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React26.createElement(import_ui22.Stack, { gap: 1.5 }, /* @__PURE__ */ React26.createElement(
1326
+ /* @__PURE__ */ React25.createElement(ControlLabel, null, (0, import_i18n10.__)("Link", "elementor")),
1327
+ /* @__PURE__ */ React25.createElement(import_ui21.IconButton, { size: SIZE3, onClick: () => handleOnChange("enabled", !enabled) }, enabled ? /* @__PURE__ */ React25.createElement(import_icons5.MinusIcon, { fontSize: SIZE3 }) : /* @__PURE__ */ React25.createElement(import_icons5.PlusIcon, { fontSize: SIZE3 }))
1328
+ ), /* @__PURE__ */ React25.createElement(import_ui21.Collapse, { in: enabled, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React25.createElement(import_ui21.Stack, { gap: 1.5 }, /* @__PURE__ */ React25.createElement(
1375
1329
  BoundPropProvider,
1376
1330
  {
1377
1331
  value: href,
1378
1332
  setValue: (newHref) => handleOnChange("href", newHref),
1379
1333
  bind: "href"
1380
1334
  },
1381
- /* @__PURE__ */ React26.createElement(UrlControl, { placeholder: (0, import_i18n11.__)("Paste URL or type", "elementor") })
1382
- ), /* @__PURE__ */ React26.createElement(
1335
+ /* @__PURE__ */ React25.createElement(UrlControl, { placeholder: (0, import_i18n10.__)("Paste URL or type", "elementor") })
1336
+ ), /* @__PURE__ */ React25.createElement(
1383
1337
  SwitchControl,
1384
1338
  {
1385
1339
  value: isTargetBlank,
@@ -1388,17 +1342,17 @@ var LinkControl = createControl(() => {
1388
1342
  ))));
1389
1343
  });
1390
1344
  var SwitchControl = ({ value, onSwitch }) => {
1391
- return /* @__PURE__ */ React26.createElement(import_ui22.Grid, { container: true, alignItems: "center", flexWrap: "nowrap", justifyContent: "space-between" }, /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true }, /* @__PURE__ */ React26.createElement(ControlLabel, null, (0, import_i18n11.__)("Open in new tab", "elementor"))), /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true }, /* @__PURE__ */ React26.createElement(import_ui22.Switch, { checked: value, onChange: onSwitch })));
1345
+ return /* @__PURE__ */ React25.createElement(import_ui21.Grid, { container: true, alignItems: "center", flexWrap: "nowrap", justifyContent: "space-between" }, /* @__PURE__ */ React25.createElement(import_ui21.Grid, { item: true }, /* @__PURE__ */ React25.createElement(ControlLabel, null, (0, import_i18n10.__)("Open in new tab", "elementor"))), /* @__PURE__ */ React25.createElement(import_ui21.Grid, { item: true }, /* @__PURE__ */ React25.createElement(import_ui21.Switch, { checked: value, onChange: onSwitch })));
1392
1346
  };
1393
1347
 
1394
1348
  // src/controls/gap-control.tsx
1395
- var React27 = __toESM(require("react"));
1396
- var import_editor_props16 = require("@elementor/editor-props");
1349
+ var React26 = __toESM(require("react"));
1350
+ var import_editor_props15 = require("@elementor/editor-props");
1397
1351
  var import_icons6 = require("@elementor/icons");
1398
- var import_ui23 = require("@elementor/ui");
1399
- var import_i18n12 = require("@wordpress/i18n");
1352
+ var import_ui22 = require("@elementor/ui");
1353
+ var import_i18n11 = require("@wordpress/i18n");
1400
1354
  var GapControl = createControl(({ label }) => {
1401
- const { value, setValue } = useBoundProp(import_editor_props16.gapPropTypeUtil);
1355
+ const { value, setValue } = useBoundProp(import_editor_props15.gapPropTypeUtil);
1402
1356
  const { column, row, isLinked = true } = value || {};
1403
1357
  const setLinkedValue = (gap, newValue) => {
1404
1358
  const updatedValue = {
@@ -1418,38 +1372,125 @@ var GapControl = createControl(({ label }) => {
1418
1372
  setValue(updatedValue);
1419
1373
  };
1420
1374
  const LinkedIcon = isLinked ? import_icons6.LinkIcon : import_icons6.DetachIcon;
1421
- return /* @__PURE__ */ React27.createElement(React27.Fragment, null, /* @__PURE__ */ React27.createElement(import_ui23.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React27.createElement(ControlLabel, null, label), /* @__PURE__ */ React27.createElement(
1422
- import_ui23.ToggleButton,
1375
+ return /* @__PURE__ */ React26.createElement(React26.Fragment, null, /* @__PURE__ */ React26.createElement(import_ui22.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React26.createElement(ControlLabel, null, label), /* @__PURE__ */ React26.createElement(
1376
+ import_ui22.ToggleButton,
1423
1377
  {
1424
- "aria-label": (0, import_i18n12.__)("Link Inputs", "elementor"),
1378
+ "aria-label": (0, import_i18n11.__)("Link Inputs", "elementor"),
1425
1379
  size: "tiny",
1426
1380
  value: "check",
1427
1381
  selected: isLinked,
1428
1382
  sx: { marginLeft: "auto" },
1429
1383
  onChange: toggleLinked
1430
1384
  },
1431
- /* @__PURE__ */ React27.createElement(LinkedIcon, { fontSize: "tiny" })
1432
- )), /* @__PURE__ */ React27.createElement(import_ui23.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React27.createElement(import_ui23.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(ControlLabel, null, (0, import_i18n12.__)("Column", "elementor"))), /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(
1385
+ /* @__PURE__ */ React26.createElement(LinkedIcon, { fontSize: "tiny" })
1386
+ )), /* @__PURE__ */ React26.createElement(import_ui22.Stack, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React26.createElement(import_ui22.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(ControlLabel, null, (0, import_i18n11.__)("Column", "elementor"))), /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(
1433
1387
  BoundPropProvider,
1434
1388
  {
1435
1389
  setValue: (newValue) => setLinkedValue("column", newValue),
1436
1390
  value: column,
1437
1391
  bind: "column"
1438
1392
  },
1439
- /* @__PURE__ */ React27.createElement(SizeControl, null)
1440
- ))), /* @__PURE__ */ React27.createElement(import_ui23.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(ControlLabel, null, (0, import_i18n12.__)("Row", "elementor"))), /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(
1393
+ /* @__PURE__ */ React26.createElement(SizeControl, null)
1394
+ ))), /* @__PURE__ */ React26.createElement(import_ui22.Grid, { container: true, gap: 1, alignItems: "center" }, /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(ControlLabel, null, (0, import_i18n11.__)("Row", "elementor"))), /* @__PURE__ */ React26.createElement(import_ui22.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(
1441
1395
  BoundPropProvider,
1442
1396
  {
1443
1397
  setValue: (newValue) => setLinkedValue("row", newValue),
1444
1398
  value: row,
1445
1399
  bind: "row"
1446
1400
  },
1447
- /* @__PURE__ */ React27.createElement(SizeControl, null)
1401
+ /* @__PURE__ */ React26.createElement(SizeControl, null)
1448
1402
  )))));
1449
1403
  });
1404
+
1405
+ // src/controls/background-control/background-control.tsx
1406
+ var React28 = __toESM(require("react"));
1407
+ var import_editor_props17 = require("@elementor/editor-props");
1408
+ var import_ui24 = require("@elementor/ui");
1409
+ var import_i18n13 = require("@wordpress/i18n");
1410
+
1411
+ // src/controls/background-control/background-overlay/background-overlay-repeater-control.tsx
1412
+ var React27 = __toESM(require("react"));
1413
+ var import_editor_props16 = require("@elementor/editor-props");
1414
+ var import_ui23 = require("@elementor/ui");
1415
+ var import_i18n12 = require("@wordpress/i18n");
1416
+ var initialBackgroundOverlay = {
1417
+ $$type: "background-color-overlay",
1418
+ value: "rgba(0, 0, 0, 0.2)"
1419
+ };
1420
+ var BackgroundOverlayRepeaterControl = createControl(() => {
1421
+ const { value: overlayValues, setValue } = useBoundProp(import_editor_props16.backgroundOverlayPropTypeUtil);
1422
+ const setColorOverlay = (newValue) => {
1423
+ setValue(newValue);
1424
+ };
1425
+ return /* @__PURE__ */ React27.createElement(
1426
+ Repeater,
1427
+ {
1428
+ values: overlayValues ?? [],
1429
+ setValues: setColorOverlay,
1430
+ label: (0, import_i18n12.__)("Overlay", "elementor"),
1431
+ itemSettings: {
1432
+ Icon: ItemIcon2,
1433
+ Label: ItemLabel2,
1434
+ Content: ItemContent2,
1435
+ initialValues: initialBackgroundOverlay
1436
+ }
1437
+ }
1438
+ );
1439
+ });
1440
+ var ItemIcon2 = ({ value }) => /* @__PURE__ */ React27.createElement(import_ui23.UnstableColorIndicator, { size: "inherit", component: "span", value: value.value });
1441
+ var ItemContent2 = ({
1442
+ value,
1443
+ setValue
1444
+ }) => {
1445
+ const setBackgroundColorOverlay = (newValue) => {
1446
+ setValue({
1447
+ $$type: "background-color-overlay",
1448
+ value: newValue.value
1449
+ });
1450
+ };
1451
+ return /* @__PURE__ */ React27.createElement(import_ui23.Stack, { gap: 1.5 }, /* @__PURE__ */ React27.createElement(
1452
+ BoundPropProvider,
1453
+ {
1454
+ bind: "background-color-overlay",
1455
+ value,
1456
+ setValue: setBackgroundColorOverlay
1457
+ },
1458
+ /* @__PURE__ */ React27.createElement(import_ui23.Grid, { container: true, spacing: 1, alignItems: "center" }, /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(ControlLabel, null, (0, import_i18n12.__)("Color", "elementor"))), /* @__PURE__ */ React27.createElement(import_ui23.Grid, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(ColorControl, null)))
1459
+ ));
1460
+ };
1461
+ var ItemLabel2 = ({ value }) => {
1462
+ const color = value.value;
1463
+ return /* @__PURE__ */ React27.createElement("span", null, color);
1464
+ };
1465
+
1466
+ // src/controls/background-control/background-control.tsx
1467
+ var BackgroundControl = createControl(() => {
1468
+ const { value, setValue } = useBoundProp(import_editor_props17.backgroundPropTypeUtil);
1469
+ const setColor = (newValue) => {
1470
+ setValue({
1471
+ ...value,
1472
+ color: newValue
1473
+ });
1474
+ };
1475
+ const setBackgroundColorOverlay = (newValue) => {
1476
+ setValue({
1477
+ ...value,
1478
+ "background-overlay": newValue
1479
+ });
1480
+ };
1481
+ return /* @__PURE__ */ React28.createElement(import_ui24.Stack, { gap: 1.5 }, /* @__PURE__ */ React28.createElement(
1482
+ BoundPropProvider,
1483
+ {
1484
+ bind: "background-overlay",
1485
+ value: value?.["background-overlay"],
1486
+ setValue: setBackgroundColorOverlay
1487
+ },
1488
+ /* @__PURE__ */ React28.createElement(BackgroundOverlayRepeaterControl, null)
1489
+ ), /* @__PURE__ */ React28.createElement(BoundPropProvider, { bind: "color", value: value?.color, setValue: setColor }, /* @__PURE__ */ React28.createElement(import_ui24.Grid, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React28.createElement(import_ui24.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React28.createElement(ControlLabel, null, (0, import_i18n13.__)("Color", "elementor"))), /* @__PURE__ */ React28.createElement(import_ui24.Grid, { item: true, xs: 6 }, /* @__PURE__ */ React28.createElement(ColorControl, null)))));
1490
+ });
1450
1491
  // Annotate the CommonJS export names for ESM import in node:
1451
1492
  0 && (module.exports = {
1452
- BackgroundOverlayRepeaterControl,
1493
+ BackgroundControl,
1453
1494
  BoundPropProvider,
1454
1495
  BoxShadowRepeaterControl,
1455
1496
  ColorControl,