@elementor/editor-variables 3.32.0-28 → 3.32.0-29

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.mjs CHANGED
@@ -83,12 +83,12 @@ var usePreventUnload = (isDirty) => {
83
83
  };
84
84
 
85
85
  // src/controls/variable-control.tsx
86
- import * as React24 from "react";
86
+ import * as React25 from "react";
87
87
  import { useBoundProp as useBoundProp10 } from "@elementor/editor-controls";
88
88
 
89
89
  // src/components/ui/variable/assigned-variable.tsx
90
90
  import { useId as useId2, useRef } from "react";
91
- import * as React16 from "react";
91
+ import * as React17 from "react";
92
92
  import { useBoundProp as useBoundProp6 } from "@elementor/editor-controls";
93
93
  import { ColorFilterIcon as ColorFilterIcon2 } from "@elementor/icons";
94
94
  import { bindPopover, bindTrigger, Box as Box5, Popover, usePopupState } from "@elementor/ui";
@@ -496,7 +496,7 @@ function createVariableTypeRegistry() {
496
496
  var { registerVariableType, getVariableType, hasVariableType } = createVariableTypeRegistry();
497
497
 
498
498
  // src/components/variable-selection-popover.tsx
499
- import * as React14 from "react";
499
+ import * as React15 from "react";
500
500
  import { useState as useState7 } from "react";
501
501
  import { isExperimentActive } from "@elementor/editor-v1-adapters";
502
502
 
@@ -544,7 +544,7 @@ var usePermissions = () => {
544
544
  };
545
545
 
546
546
  // src/components/variable-creation.tsx
547
- import * as React6 from "react";
547
+ import * as React7 from "react";
548
548
  import { useState as useState3 } from "react";
549
549
  import { PopoverContent, useBoundProp as useBoundProp3 } from "@elementor/editor-controls";
550
550
  import { PopoverBody } from "@elementor/editor-editing-panel";
@@ -696,10 +696,19 @@ var validateValue = (value) => {
696
696
  };
697
697
 
698
698
  // src/components/fields/label-field.tsx
699
- import * as React5 from "react";
699
+ import * as React6 from "react";
700
700
  import { useId, useState as useState2 } from "react";
701
- import { FormHelperText, FormLabel, Grid, TextField } from "@elementor/ui";
701
+ import { TextField } from "@elementor/ui";
702
702
  import { __ as __5 } from "@wordpress/i18n";
703
+
704
+ // src/components/ui/form-field.tsx
705
+ import * as React5 from "react";
706
+ import { FormHelperText, FormLabel, Grid } from "@elementor/ui";
707
+ var FormField = ({ id: id2, label, errorMsg, noticeMsg, children }) => {
708
+ return /* @__PURE__ */ React5.createElement(Grid, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React5.createElement(Grid, { item: true, xs: 12 }, /* @__PURE__ */ React5.createElement(FormLabel, { htmlFor: id2, size: "tiny" }, label)), /* @__PURE__ */ React5.createElement(Grid, { item: true, xs: 12 }, children, errorMsg && /* @__PURE__ */ React5.createElement(FormHelperText, { error: true }, errorMsg), noticeMsg && /* @__PURE__ */ React5.createElement(FormHelperText, null, noticeMsg)));
709
+ };
710
+
711
+ // src/components/fields/label-field.tsx
703
712
  function isLabelEqual(a, b) {
704
713
  return a.trim().toLowerCase() === b.trim().toLowerCase();
705
714
  }
@@ -728,7 +737,7 @@ var LabelField = ({ value, error, onChange }) => {
728
737
  errorMsg = error.message;
729
738
  }
730
739
  const noticeMsg = errorMsg ? "" : noticeMessage;
731
- return /* @__PURE__ */ React5.createElement(Grid, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React5.createElement(Grid, { item: true, xs: 12 }, /* @__PURE__ */ React5.createElement(FormLabel, { htmlFor: id2, size: "tiny" }, __5("Name", "elementor"))), /* @__PURE__ */ React5.createElement(Grid, { item: true, xs: 12 }, /* @__PURE__ */ React5.createElement(
740
+ return /* @__PURE__ */ React6.createElement(FormField, { id: id2, label: __5("Name", "elementor"), errorMsg, noticeMsg }, /* @__PURE__ */ React6.createElement(
732
741
  TextField,
733
742
  {
734
743
  id: id2,
@@ -739,7 +748,7 @@ var LabelField = ({ value, error, onChange }) => {
739
748
  onChange: (e) => handleChange(e.target.value),
740
749
  inputProps: { maxLength: VARIABLE_LABEL_MAX_LENGTH }
741
750
  }
742
- ), errorMsg && /* @__PURE__ */ React5.createElement(FormHelperText, { error: true }, errorMsg), noticeMsg && /* @__PURE__ */ React5.createElement(FormHelperText, null, noticeMsg)));
751
+ ));
743
752
  };
744
753
 
745
754
  // src/components/variable-creation.tsx
@@ -751,11 +760,13 @@ var VariableCreation = ({ onGoBack, onClose }) => {
751
760
  const [value, setValue] = useState3(initialValue);
752
761
  const [label, setLabel] = useState3("");
753
762
  const [errorMessage, setErrorMessage] = useState3("");
763
+ const [valueFieldError, setValueFieldError] = useState3("");
754
764
  const { labelFieldError, setLabelFieldError } = useLabelError();
755
765
  const resetFields = () => {
756
766
  setValue("");
757
767
  setLabel("");
758
768
  setErrorMessage("");
769
+ setValueFieldError("");
759
770
  };
760
771
  const closePopover = () => {
761
772
  resetFields();
@@ -794,14 +805,14 @@ var VariableCreation = ({ onGoBack, onClose }) => {
794
805
  return !!errorMessage;
795
806
  };
796
807
  const isSubmitDisabled = hasEmptyValue() || hasErrors();
797
- return /* @__PURE__ */ React6.createElement(PopoverBody, { height: "auto" }, /* @__PURE__ */ React6.createElement(
808
+ return /* @__PURE__ */ React7.createElement(PopoverBody, { height: "auto" }, /* @__PURE__ */ React7.createElement(
798
809
  PopoverHeader,
799
810
  {
800
- icon: /* @__PURE__ */ React6.createElement(React6.Fragment, null, onGoBack && /* @__PURE__ */ React6.createElement(IconButton2, { size: SIZE, "aria-label": __6("Go Back", "elementor"), onClick: onGoBack }, /* @__PURE__ */ React6.createElement(ArrowLeftIcon, { fontSize: SIZE })), /* @__PURE__ */ React6.createElement(VariableIcon, { fontSize: SIZE })),
811
+ icon: /* @__PURE__ */ React7.createElement(React7.Fragment, null, onGoBack && /* @__PURE__ */ React7.createElement(IconButton2, { size: SIZE, "aria-label": __6("Go Back", "elementor"), onClick: onGoBack }, /* @__PURE__ */ React7.createElement(ArrowLeftIcon, { fontSize: SIZE })), /* @__PURE__ */ React7.createElement(VariableIcon, { fontSize: SIZE })),
801
812
  title: __6("Create variable", "elementor"),
802
813
  onClose: closePopover
803
814
  }
804
- ), /* @__PURE__ */ React6.createElement(Divider2, null), /* @__PURE__ */ React6.createElement(PopoverContent, { p: 2 }, /* @__PURE__ */ React6.createElement(
815
+ ), /* @__PURE__ */ React7.createElement(Divider2, null), /* @__PURE__ */ React7.createElement(PopoverContent, { p: 2 }, /* @__PURE__ */ React7.createElement(
805
816
  LabelField,
806
817
  {
807
818
  value: label,
@@ -811,20 +822,22 @@ var VariableCreation = ({ onGoBack, onClose }) => {
811
822
  setErrorMessage("");
812
823
  }
813
824
  }
814
- ), /* @__PURE__ */ React6.createElement(
825
+ ), /* @__PURE__ */ React7.createElement(FormField, { errorMsg: valueFieldError, label: __6("Value", "elementor") }, /* @__PURE__ */ React7.createElement(
815
826
  ValueField,
816
827
  {
817
828
  value,
818
829
  onChange: (newValue) => {
819
830
  setValue(newValue);
820
831
  setErrorMessage("");
821
- }
832
+ setValueFieldError("");
833
+ },
834
+ onValidationChange: setValueFieldError
822
835
  }
823
- ), errorMessage && /* @__PURE__ */ React6.createElement(FormHelperText2, { error: true }, errorMessage)), /* @__PURE__ */ React6.createElement(CardActions, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React6.createElement(Button2, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleCreateAndTrack }, __6("Create", "elementor"))));
836
+ )), errorMessage && /* @__PURE__ */ React7.createElement(FormHelperText2, { error: true }, errorMessage)), /* @__PURE__ */ React7.createElement(CardActions, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React7.createElement(Button2, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleCreateAndTrack }, __6("Create", "elementor"))));
824
837
  };
825
838
 
826
839
  // src/components/variable-edit.tsx
827
- import * as React9 from "react";
840
+ import * as React10 from "react";
828
841
  import { useEffect as useEffect2, useState as useState5 } from "react";
829
842
  import { PopoverContent as PopoverContent2, useBoundProp as useBoundProp4 } from "@elementor/editor-controls";
830
843
  import { useSuppressedMessage } from "@elementor/editor-current-user";
@@ -835,7 +848,7 @@ import { Button as Button5, CardActions as CardActions2, Divider as Divider3, Fo
835
848
  import { __ as __9 } from "@wordpress/i18n";
836
849
 
837
850
  // src/components/ui/delete-confirmation-dialog.tsx
838
- import * as React7 from "react";
851
+ import * as React8 from "react";
839
852
  import { AlertOctagonFilledIcon } from "@elementor/icons";
840
853
  import {
841
854
  Button as Button3,
@@ -854,11 +867,11 @@ var DeleteConfirmationDialog = ({
854
867
  closeDialog,
855
868
  onConfirm
856
869
  }) => {
857
- return /* @__PURE__ */ React7.createElement(Dialog, { open, onClose: closeDialog, "aria-labelledby": TITLE_ID, maxWidth: "xs" }, /* @__PURE__ */ React7.createElement(DialogTitle, { id: TITLE_ID, display: "flex", alignItems: "center", gap: 1, sx: { lineHeight: 1 } }, /* @__PURE__ */ React7.createElement(AlertOctagonFilledIcon, { color: "error" }), __7("Delete this variable?", "elementor")), /* @__PURE__ */ React7.createElement(DialogContent, null, /* @__PURE__ */ React7.createElement(DialogContentText, { variant: "body2", color: "textPrimary" }, __7("All elements using", "elementor"), /* @__PURE__ */ React7.createElement(Typography2, { variant: "subtitle2", component: "span" }, "\xA0", label, "\xA0"), __7("will keep their current values, but the variable itself will be removed.", "elementor"))), /* @__PURE__ */ React7.createElement(DialogActions, null, /* @__PURE__ */ React7.createElement(Button3, { color: "secondary", onClick: closeDialog }, __7("Not now", "elementor")), /* @__PURE__ */ React7.createElement(Button3, { variant: "contained", color: "error", onClick: onConfirm }, __7("Delete", "elementor"))));
870
+ return /* @__PURE__ */ React8.createElement(Dialog, { open, onClose: closeDialog, "aria-labelledby": TITLE_ID, maxWidth: "xs" }, /* @__PURE__ */ React8.createElement(DialogTitle, { id: TITLE_ID, display: "flex", alignItems: "center", gap: 1, sx: { lineHeight: 1 } }, /* @__PURE__ */ React8.createElement(AlertOctagonFilledIcon, { color: "error" }), __7("Delete this variable?", "elementor")), /* @__PURE__ */ React8.createElement(DialogContent, null, /* @__PURE__ */ React8.createElement(DialogContentText, { variant: "body2", color: "textPrimary" }, __7("All elements using", "elementor"), /* @__PURE__ */ React8.createElement(Typography2, { variant: "subtitle2", component: "span" }, "\xA0", label, "\xA0"), __7("will keep their current values, but the variable itself will be removed.", "elementor"))), /* @__PURE__ */ React8.createElement(DialogActions, null, /* @__PURE__ */ React8.createElement(Button3, { color: "secondary", onClick: closeDialog }, __7("Not now", "elementor")), /* @__PURE__ */ React8.createElement(Button3, { variant: "contained", color: "error", onClick: onConfirm }, __7("Delete", "elementor"))));
858
871
  };
859
872
 
860
873
  // src/components/ui/edit-confirmation-dialog.tsx
861
- import * as React8 from "react";
874
+ import * as React9 from "react";
862
875
  import { useState as useState4 } from "react";
863
876
  import { AlertTriangleFilledIcon } from "@elementor/icons";
864
877
  import {
@@ -886,13 +899,13 @@ var EditConfirmationDialog = ({
886
899
  }
887
900
  onConfirm?.();
888
901
  };
889
- return /* @__PURE__ */ React8.createElement(Dialog2, { open: true, onClose: closeDialog, maxWidth: "xs" }, /* @__PURE__ */ React8.createElement(DialogTitle2, { display: "flex", alignItems: "center", gap: 1 }, /* @__PURE__ */ React8.createElement(AlertTriangleFilledIcon, { color: "secondary" }), __8("Changes to variables go live right away.", "elementor")), /* @__PURE__ */ React8.createElement(DialogContent2, null, /* @__PURE__ */ React8.createElement(DialogContentText2, { variant: "body2", color: "textPrimary" }, __8(
902
+ return /* @__PURE__ */ React9.createElement(Dialog2, { open: true, onClose: closeDialog, maxWidth: "xs" }, /* @__PURE__ */ React9.createElement(DialogTitle2, { display: "flex", alignItems: "center", gap: 1 }, /* @__PURE__ */ React9.createElement(AlertTriangleFilledIcon, { color: "secondary" }), __8("Changes to variables go live right away.", "elementor")), /* @__PURE__ */ React9.createElement(DialogContent2, null, /* @__PURE__ */ React9.createElement(DialogContentText2, { variant: "body2", color: "textPrimary" }, __8(
890
903
  "Don't worry - all other changes you make will wait until you publish your site.",
891
904
  "elementor"
892
- ))), /* @__PURE__ */ React8.createElement(DialogActions2, { sx: { justifyContent: "space-between", alignItems: "center" } }, /* @__PURE__ */ React8.createElement(
905
+ ))), /* @__PURE__ */ React9.createElement(DialogActions2, { sx: { justifyContent: "space-between", alignItems: "center" } }, /* @__PURE__ */ React9.createElement(
893
906
  FormControlLabel,
894
907
  {
895
- control: /* @__PURE__ */ React8.createElement(
908
+ control: /* @__PURE__ */ React9.createElement(
896
909
  Checkbox,
897
910
  {
898
911
  checked: dontShowAgain,
@@ -900,9 +913,9 @@ var EditConfirmationDialog = ({
900
913
  size: "small"
901
914
  }
902
915
  ),
903
- label: /* @__PURE__ */ React8.createElement(Typography3, { variant: "body2" }, __8("Don't show me again", "elementor"))
916
+ label: /* @__PURE__ */ React9.createElement(Typography3, { variant: "body2" }, __8("Don't show me again", "elementor"))
904
917
  }
905
- ), /* @__PURE__ */ React8.createElement("div", null, /* @__PURE__ */ React8.createElement(Button4, { color: "secondary", onClick: closeDialog }, __8("Keep editing", "elementor")), /* @__PURE__ */ React8.createElement(Button4, { variant: "contained", color: "secondary", onClick: handleSave, sx: { ml: 1 } }, __8("Save", "elementor")))));
918
+ ), /* @__PURE__ */ React9.createElement("div", null, /* @__PURE__ */ React9.createElement(Button4, { color: "secondary", onClick: closeDialog }, __8("Keep editing", "elementor")), /* @__PURE__ */ React9.createElement(Button4, { variant: "contained", color: "secondary", onClick: handleSave, sx: { ml: 1 } }, __8("Save", "elementor")))));
906
919
  };
907
920
 
908
921
  // src/components/variable-edit.tsx
@@ -914,6 +927,7 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
914
927
  const [deleteConfirmation, setDeleteConfirmation] = useState5(false);
915
928
  const [editConfirmation, setEditConfirmation] = useState5(false);
916
929
  const [errorMessage, setErrorMessage] = useState5("");
930
+ const [valueFieldError, setValueFieldError] = useState5("");
917
931
  const { labelFieldError, setLabelFieldError } = useLabelError();
918
932
  const variable = useVariable(editId);
919
933
  if (!variable) {
@@ -985,7 +999,7 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
985
999
  const actions = [];
986
1000
  if (userPermissions.canDelete()) {
987
1001
  actions.push(
988
- /* @__PURE__ */ React9.createElement(
1002
+ /* @__PURE__ */ React10.createElement(
989
1003
  IconButton3,
990
1004
  {
991
1005
  key: "delete",
@@ -993,7 +1007,7 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
993
1007
  "aria-label": __9("Delete", "elementor"),
994
1008
  onClick: handleDeleteConfirmation
995
1009
  },
996
- /* @__PURE__ */ React9.createElement(TrashIcon, { fontSize: SIZE2 })
1010
+ /* @__PURE__ */ React10.createElement(TrashIcon, { fontSize: SIZE2 })
997
1011
  )
998
1012
  );
999
1013
  }
@@ -1007,23 +1021,23 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
1007
1021
  return !!errorMessage;
1008
1022
  };
1009
1023
  const isSubmitDisabled = noValueChanged() || hasEmptyValues() || hasErrors();
1010
- return /* @__PURE__ */ React9.createElement(React9.Fragment, null, /* @__PURE__ */ React9.createElement(PopoverBody2, { height: "auto" }, /* @__PURE__ */ React9.createElement(
1024
+ return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(PopoverBody2, { height: "auto" }, /* @__PURE__ */ React10.createElement(
1011
1025
  PopoverHeader2,
1012
1026
  {
1013
1027
  title: __9("Edit variable", "elementor"),
1014
1028
  onClose,
1015
- icon: /* @__PURE__ */ React9.createElement(React9.Fragment, null, onGoBack && /* @__PURE__ */ React9.createElement(
1029
+ icon: /* @__PURE__ */ React10.createElement(React10.Fragment, null, onGoBack && /* @__PURE__ */ React10.createElement(
1016
1030
  IconButton3,
1017
1031
  {
1018
1032
  size: SIZE2,
1019
1033
  "aria-label": __9("Go Back", "elementor"),
1020
1034
  onClick: onGoBack
1021
1035
  },
1022
- /* @__PURE__ */ React9.createElement(ArrowLeftIcon2, { fontSize: SIZE2 })
1023
- ), /* @__PURE__ */ React9.createElement(VariableIcon, { fontSize: SIZE2 })),
1036
+ /* @__PURE__ */ React10.createElement(ArrowLeftIcon2, { fontSize: SIZE2 })
1037
+ ), /* @__PURE__ */ React10.createElement(VariableIcon, { fontSize: SIZE2 })),
1024
1038
  actions
1025
1039
  }
1026
- ), /* @__PURE__ */ React9.createElement(Divider3, null), /* @__PURE__ */ React9.createElement(PopoverContent2, { p: 2 }, /* @__PURE__ */ React9.createElement(
1040
+ ), /* @__PURE__ */ React10.createElement(Divider3, null), /* @__PURE__ */ React10.createElement(PopoverContent2, { p: 2 }, /* @__PURE__ */ React10.createElement(
1027
1041
  LabelField,
1028
1042
  {
1029
1043
  value: label,
@@ -1033,16 +1047,18 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
1033
1047
  setErrorMessage("");
1034
1048
  }
1035
1049
  }
1036
- ), /* @__PURE__ */ React9.createElement(
1050
+ ), /* @__PURE__ */ React10.createElement(FormField, { errorMsg: valueFieldError, label: __9("Value", "elementor") }, /* @__PURE__ */ React10.createElement(
1037
1051
  ValueField,
1038
1052
  {
1039
1053
  value,
1040
1054
  onChange: (newValue) => {
1041
1055
  setValue(newValue);
1042
1056
  setErrorMessage("");
1043
- }
1057
+ setValueFieldError("");
1058
+ },
1059
+ onValidationChange: setValueFieldError
1044
1060
  }
1045
- ), errorMessage && /* @__PURE__ */ React9.createElement(FormHelperText3, { error: true }, errorMessage)), /* @__PURE__ */ React9.createElement(CardActions2, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React9.createElement(Button5, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleUpdate }, __9("Save", "elementor")))), deleteConfirmation && /* @__PURE__ */ React9.createElement(
1061
+ )), errorMessage && /* @__PURE__ */ React10.createElement(FormHelperText3, { error: true }, errorMessage)), /* @__PURE__ */ React10.createElement(CardActions2, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React10.createElement(Button5, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleUpdate }, __9("Save", "elementor")))), deleteConfirmation && /* @__PURE__ */ React10.createElement(
1046
1062
  DeleteConfirmationDialog,
1047
1063
  {
1048
1064
  open: true,
@@ -1050,7 +1066,7 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
1050
1066
  onConfirm: handleDelete,
1051
1067
  closeDialog: closeDeleteDialog()
1052
1068
  }
1053
- ), editConfirmation && !isMessageSuppressed && /* @__PURE__ */ React9.createElement(
1069
+ ), editConfirmation && !isMessageSuppressed && /* @__PURE__ */ React10.createElement(
1054
1070
  EditConfirmationDialog,
1055
1071
  {
1056
1072
  closeDialog: closeEditDialog(),
@@ -1061,7 +1077,7 @@ var VariableEdit = ({ onClose, onGoBack, onSubmit, editId }) => {
1061
1077
  };
1062
1078
 
1063
1079
  // src/components/variables-selection.tsx
1064
- import * as React13 from "react";
1080
+ import * as React14 from "react";
1065
1081
  import { useState as useState6 } from "react";
1066
1082
  import { useBoundProp as useBoundProp5 } from "@elementor/editor-controls";
1067
1083
  import { PopoverBody as PopoverBody3 } from "@elementor/editor-editing-panel";
@@ -1071,7 +1087,7 @@ import { Divider as Divider4, IconButton as IconButton5 } from "@elementor/ui";
1071
1087
  import { __ as __13, sprintf } from "@wordpress/i18n";
1072
1088
 
1073
1089
  // src/components/ui/menu-item-content.tsx
1074
- import * as React10 from "react";
1090
+ import * as React11 from "react";
1075
1091
  import { EllipsisWithTooltip } from "@elementor/editor-ui";
1076
1092
  import { EditIcon } from "@elementor/icons";
1077
1093
  import { Box as Box3, IconButton as IconButton4, ListItemIcon, Typography as Typography4 } from "@elementor/ui";
@@ -1079,7 +1095,7 @@ import { __ as __10 } from "@wordpress/i18n";
1079
1095
  var SIZE3 = "tiny";
1080
1096
  var MenuItemContent = ({ item }) => {
1081
1097
  const onEdit = item.onEdit;
1082
- return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(ListItemIcon, null, item.icon), /* @__PURE__ */ React10.createElement(
1098
+ return /* @__PURE__ */ React11.createElement(React11.Fragment, null, /* @__PURE__ */ React11.createElement(ListItemIcon, null, item.icon), /* @__PURE__ */ React11.createElement(
1083
1099
  Box3,
1084
1100
  {
1085
1101
  sx: {
@@ -1090,7 +1106,7 @@ var MenuItemContent = ({ item }) => {
1090
1106
  gap: 1
1091
1107
  }
1092
1108
  },
1093
- /* @__PURE__ */ React10.createElement(
1109
+ /* @__PURE__ */ React11.createElement(
1094
1110
  EllipsisWithTooltip,
1095
1111
  {
1096
1112
  title: item.label || item.value,
@@ -1101,7 +1117,7 @@ var MenuItemContent = ({ item }) => {
1101
1117
  maxWidth: "50%"
1102
1118
  }
1103
1119
  ),
1104
- item.secondaryText && /* @__PURE__ */ React10.createElement(
1120
+ item.secondaryText && /* @__PURE__ */ React11.createElement(
1105
1121
  EllipsisWithTooltip,
1106
1122
  {
1107
1123
  title: item.secondaryText,
@@ -1112,7 +1128,7 @@ var MenuItemContent = ({ item }) => {
1112
1128
  maxWidth: "50%"
1113
1129
  }
1114
1130
  )
1115
- ), !!onEdit && /* @__PURE__ */ React10.createElement(
1131
+ ), !!onEdit && /* @__PURE__ */ React11.createElement(
1116
1132
  IconButton4,
1117
1133
  {
1118
1134
  sx: { mx: 1, opacity: "0" },
@@ -1122,16 +1138,16 @@ var MenuItemContent = ({ item }) => {
1122
1138
  },
1123
1139
  "aria-label": __10("Edit", "elementor")
1124
1140
  },
1125
- /* @__PURE__ */ React10.createElement(EditIcon, { color: "action", fontSize: SIZE3 })
1141
+ /* @__PURE__ */ React11.createElement(EditIcon, { color: "action", fontSize: SIZE3 })
1126
1142
  ));
1127
1143
  };
1128
1144
 
1129
1145
  // src/components/ui/no-search-results.tsx
1130
- import * as React11 from "react";
1146
+ import * as React12 from "react";
1131
1147
  import { Link, Stack as Stack3, Typography as Typography5 } from "@elementor/ui";
1132
1148
  import { __ as __11 } from "@wordpress/i18n";
1133
1149
  var NoSearchResults = ({ searchValue, onClear, icon }) => {
1134
- return /* @__PURE__ */ React11.createElement(
1150
+ return /* @__PURE__ */ React12.createElement(
1135
1151
  Stack3,
1136
1152
  {
1137
1153
  gap: 1,
@@ -1143,18 +1159,18 @@ var NoSearchResults = ({ searchValue, onClear, icon }) => {
1143
1159
  sx: { pb: 3.5 }
1144
1160
  },
1145
1161
  icon,
1146
- /* @__PURE__ */ React11.createElement(Typography5, { align: "center", variant: "subtitle2" }, __11("Sorry, nothing matched", "elementor"), /* @__PURE__ */ React11.createElement("br", null), "\u201C", searchValue, "\u201D."),
1147
- /* @__PURE__ */ React11.createElement(Typography5, { align: "center", variant: "caption", sx: { display: "flex", flexDirection: "column" } }, __11("Try something else.", "elementor"), /* @__PURE__ */ React11.createElement(Link, { color: "text.secondary", variant: "caption", component: "button", onClick: onClear }, __11("Clear & try again", "elementor")))
1162
+ /* @__PURE__ */ React12.createElement(Typography5, { align: "center", variant: "subtitle2" }, __11("Sorry, nothing matched", "elementor"), /* @__PURE__ */ React12.createElement("br", null), "\u201C", searchValue, "\u201D."),
1163
+ /* @__PURE__ */ React12.createElement(Typography5, { align: "center", variant: "caption", sx: { display: "flex", flexDirection: "column" } }, __11("Try something else.", "elementor"), /* @__PURE__ */ React12.createElement(Link, { color: "text.secondary", variant: "caption", component: "button", onClick: onClear }, __11("Clear & try again", "elementor")))
1148
1164
  );
1149
1165
  };
1150
1166
 
1151
1167
  // src/components/ui/no-variables.tsx
1152
- import * as React12 from "react";
1168
+ import * as React13 from "react";
1153
1169
  import { Button as Button6, Stack as Stack4, Typography as Typography6 } from "@elementor/ui";
1154
1170
  import { __ as __12 } from "@wordpress/i18n";
1155
1171
  var NoVariables = ({ icon, title, onAdd }) => {
1156
1172
  const canAdd = usePermissions().canAdd();
1157
- return /* @__PURE__ */ React12.createElement(
1173
+ return /* @__PURE__ */ React13.createElement(
1158
1174
  Stack4,
1159
1175
  {
1160
1176
  gap: 1,
@@ -1165,7 +1181,7 @@ var NoVariables = ({ icon, title, onAdd }) => {
1165
1181
  sx: { p: 2.5, pb: 5.5 }
1166
1182
  },
1167
1183
  icon,
1168
- canAdd ? /* @__PURE__ */ React12.createElement(React12.Fragment, null, /* @__PURE__ */ React12.createElement(
1184
+ canAdd ? /* @__PURE__ */ React13.createElement(React13.Fragment, null, /* @__PURE__ */ React13.createElement(
1169
1185
  NoVariablesContent,
1170
1186
  {
1171
1187
  title: title || __12("Create your first variable", "elementor"),
@@ -1174,7 +1190,7 @@ var NoVariables = ({ icon, title, onAdd }) => {
1174
1190
  "elementor"
1175
1191
  )
1176
1192
  }
1177
- ), onAdd && /* @__PURE__ */ React12.createElement(Button6, { variant: "outlined", color: "secondary", size: "small", onClick: onAdd }, __12("Create a variable", "elementor"))) : /* @__PURE__ */ React12.createElement(
1193
+ ), onAdd && /* @__PURE__ */ React13.createElement(Button6, { variant: "outlined", color: "secondary", size: "small", onClick: onAdd }, __12("Create a variable", "elementor"))) : /* @__PURE__ */ React13.createElement(
1178
1194
  NoVariablesContent,
1179
1195
  {
1180
1196
  title: __12("There are no variables", "elementor"),
@@ -1184,7 +1200,7 @@ var NoVariables = ({ icon, title, onAdd }) => {
1184
1200
  );
1185
1201
  };
1186
1202
  function NoVariablesContent({ title, message }) {
1187
- return /* @__PURE__ */ React12.createElement(React12.Fragment, null, /* @__PURE__ */ React12.createElement(Typography6, { align: "center", variant: "subtitle2" }, title), /* @__PURE__ */ React12.createElement(Typography6, { align: "center", variant: "caption", maxWidth: "180px" }, message));
1203
+ return /* @__PURE__ */ React13.createElement(React13.Fragment, null, /* @__PURE__ */ React13.createElement(Typography6, { align: "center", variant: "subtitle2" }, title), /* @__PURE__ */ React13.createElement(Typography6, { align: "center", variant: "caption", maxWidth: "180px" }, message));
1188
1204
  }
1189
1205
 
1190
1206
  // src/components/ui/styled-menu-list.tsx
@@ -1250,20 +1266,20 @@ var VariablesSelection = ({ closePopover, onAdd, onEdit, onSettings }) => {
1250
1266
  const actions = [];
1251
1267
  if (onAdd) {
1252
1268
  actions.push(
1253
- /* @__PURE__ */ React13.createElement(IconButton5, { key: "add", size: SIZE4, onClick: onAddAndTrack }, /* @__PURE__ */ React13.createElement(PlusIcon, { fontSize: SIZE4 }))
1269
+ /* @__PURE__ */ React14.createElement(IconButton5, { key: "add", size: SIZE4, onClick: onAddAndTrack }, /* @__PURE__ */ React14.createElement(PlusIcon, { fontSize: SIZE4 }))
1254
1270
  );
1255
1271
  }
1256
1272
  if (onSettings) {
1257
1273
  actions.push(
1258
- /* @__PURE__ */ React13.createElement(IconButton5, { key: "settings", size: SIZE4, onClick: onSettings }, /* @__PURE__ */ React13.createElement(SettingsIcon, { fontSize: SIZE4 }))
1274
+ /* @__PURE__ */ React14.createElement(IconButton5, { key: "settings", size: SIZE4, onClick: onSettings }, /* @__PURE__ */ React14.createElement(SettingsIcon, { fontSize: SIZE4 }))
1259
1275
  );
1260
1276
  }
1261
- const StartIcon = startIcon || (() => /* @__PURE__ */ React13.createElement(VariableIcon, { fontSize: SIZE4 }));
1277
+ const StartIcon = startIcon || (() => /* @__PURE__ */ React14.createElement(VariableIcon, { fontSize: SIZE4 }));
1262
1278
  const items = variables.map(({ value, label, key }) => ({
1263
1279
  type: "item",
1264
1280
  value: key,
1265
1281
  label,
1266
- icon: /* @__PURE__ */ React13.createElement(StartIcon, { value }),
1282
+ icon: /* @__PURE__ */ React14.createElement(StartIcon, { value }),
1267
1283
  secondaryText: value,
1268
1284
  onEdit: onEdit ? () => onEdit?.(key) : void 0
1269
1285
  }));
@@ -1278,22 +1294,22 @@ var VariablesSelection = ({ closePopover, onAdd, onEdit, onSettings }) => {
1278
1294
  __13("Create your first %s variable", "elementor"),
1279
1295
  variableType
1280
1296
  );
1281
- return /* @__PURE__ */ React13.createElement(PopoverBody3, null, /* @__PURE__ */ React13.createElement(
1297
+ return /* @__PURE__ */ React14.createElement(PopoverBody3, null, /* @__PURE__ */ React14.createElement(
1282
1298
  PopoverHeader3,
1283
1299
  {
1284
1300
  title: __13("Variables", "elementor"),
1285
- icon: /* @__PURE__ */ React13.createElement(ColorFilterIcon, { fontSize: SIZE4 }),
1301
+ icon: /* @__PURE__ */ React14.createElement(ColorFilterIcon, { fontSize: SIZE4 }),
1286
1302
  onClose: closePopover,
1287
1303
  actions
1288
1304
  }
1289
- ), hasVariables && /* @__PURE__ */ React13.createElement(
1305
+ ), hasVariables && /* @__PURE__ */ React14.createElement(
1290
1306
  PopoverSearch,
1291
1307
  {
1292
1308
  value: searchValue,
1293
1309
  onSearch: handleSearch,
1294
1310
  placeholder: __13("Search", "elementor")
1295
1311
  }
1296
- ), /* @__PURE__ */ React13.createElement(Divider4, null), hasVariables && hasSearchResults && /* @__PURE__ */ React13.createElement(
1312
+ ), /* @__PURE__ */ React14.createElement(Divider4, null), hasVariables && hasSearchResults && /* @__PURE__ */ React14.createElement(
1297
1313
  PopoverMenuList,
1298
1314
  {
1299
1315
  items,
@@ -1303,16 +1319,16 @@ var VariablesSelection = ({ closePopover, onAdd, onEdit, onSettings }) => {
1303
1319
  selectedValue: variable,
1304
1320
  "data-testid": `${variableType}-variables-list`,
1305
1321
  menuListTemplate: VariablesStyledMenuList,
1306
- menuItemContentTemplate: (item) => /* @__PURE__ */ React13.createElement(MenuItemContent, { item })
1322
+ menuItemContentTemplate: (item) => /* @__PURE__ */ React14.createElement(MenuItemContent, { item })
1307
1323
  }
1308
- ), !hasSearchResults && hasVariables && /* @__PURE__ */ React13.createElement(
1324
+ ), !hasSearchResults && hasVariables && /* @__PURE__ */ React14.createElement(
1309
1325
  NoSearchResults,
1310
1326
  {
1311
1327
  searchValue,
1312
1328
  onClear: handleClearSearch,
1313
- icon: /* @__PURE__ */ React13.createElement(VariableIcon, { fontSize: "large" })
1329
+ icon: /* @__PURE__ */ React14.createElement(VariableIcon, { fontSize: "large" })
1314
1330
  }
1315
- ), !hasVariables && /* @__PURE__ */ React13.createElement(NoVariables, { title: noVariableTitle, icon: /* @__PURE__ */ React13.createElement(VariableIcon, { fontSize: "large" }), onAdd }));
1331
+ ), !hasVariables && /* @__PURE__ */ React14.createElement(NoVariables, { title: noVariableTitle, icon: /* @__PURE__ */ React14.createElement(VariableIcon, { fontSize: "large" }), onAdd }));
1316
1332
  };
1317
1333
 
1318
1334
  // src/components/variable-selection-popover.tsx
@@ -1326,7 +1342,7 @@ var VariableSelectionPopover = ({ closePopover, propTypeKey, selectedVariable })
1326
1342
  const onSettingsAvailable = isExperimentActive("e_variables_settings") ? () => {
1327
1343
  open();
1328
1344
  } : void 0;
1329
- return /* @__PURE__ */ React14.createElement(VariableTypeProvider, { propTypeKey }, /* @__PURE__ */ React14.createElement(PopoverContentRefContextProvider, null, RenderView({
1345
+ return /* @__PURE__ */ React15.createElement(VariableTypeProvider, { propTypeKey }, /* @__PURE__ */ React15.createElement(PopoverContentRefContextProvider, null, RenderView({
1330
1346
  propTypeKey,
1331
1347
  currentView,
1332
1348
  selectedVariable,
@@ -1372,7 +1388,7 @@ function RenderView(props) {
1372
1388
  }
1373
1389
  };
1374
1390
  if (VIEW_LIST === props.currentView) {
1375
- return /* @__PURE__ */ React14.createElement(
1391
+ return /* @__PURE__ */ React15.createElement(
1376
1392
  VariablesSelection,
1377
1393
  {
1378
1394
  closePopover: handlers.onClose,
@@ -1383,10 +1399,10 @@ function RenderView(props) {
1383
1399
  );
1384
1400
  }
1385
1401
  if (VIEW_ADD === props.currentView) {
1386
- return /* @__PURE__ */ React14.createElement(VariableCreation, { onGoBack: handlers.onGoBack, onClose: handlers.onClose });
1402
+ return /* @__PURE__ */ React15.createElement(VariableCreation, { onGoBack: handlers.onGoBack, onClose: handlers.onClose });
1387
1403
  }
1388
1404
  if (VIEW_EDIT === props.currentView) {
1389
- return /* @__PURE__ */ React14.createElement(
1405
+ return /* @__PURE__ */ React15.createElement(
1390
1406
  VariableEdit,
1391
1407
  {
1392
1408
  editId: props.editId,
@@ -1400,7 +1416,7 @@ function RenderView(props) {
1400
1416
  }
1401
1417
 
1402
1418
  // src/components/ui/tags/assigned-tag.tsx
1403
- import * as React15 from "react";
1419
+ import * as React16 from "react";
1404
1420
  import { DetachIcon } from "@elementor/icons";
1405
1421
  import { Box as Box4, IconButton as IconButton6, Stack as Stack5, Tooltip, Typography as Typography7, UnstableTag as Tag } from "@elementor/ui";
1406
1422
  import { __ as __14 } from "@wordpress/i18n";
@@ -1409,16 +1425,16 @@ var AssignedTag = ({ startIcon, label, onUnlink, ...props }) => {
1409
1425
  const actions = [];
1410
1426
  if (onUnlink) {
1411
1427
  actions.push(
1412
- /* @__PURE__ */ React15.createElement(IconButton6, { key: "unlink", size: SIZE5, onClick: onUnlink, "aria-label": __14("Unlink", "elementor") }, /* @__PURE__ */ React15.createElement(DetachIcon, { fontSize: SIZE5 }))
1428
+ /* @__PURE__ */ React16.createElement(IconButton6, { key: "unlink", size: SIZE5, onClick: onUnlink, "aria-label": __14("Unlink", "elementor") }, /* @__PURE__ */ React16.createElement(DetachIcon, { fontSize: SIZE5 }))
1413
1429
  );
1414
1430
  }
1415
- return /* @__PURE__ */ React15.createElement(Tooltip, { title: label, placement: "top" }, /* @__PURE__ */ React15.createElement(
1431
+ return /* @__PURE__ */ React16.createElement(Tooltip, { title: label, placement: "top" }, /* @__PURE__ */ React16.createElement(
1416
1432
  Tag,
1417
1433
  {
1418
1434
  fullWidth: true,
1419
1435
  showActionsOnHover: true,
1420
- startIcon: /* @__PURE__ */ React15.createElement(Stack5, { gap: 0.5, direction: "row", alignItems: "center" }, startIcon),
1421
- label: /* @__PURE__ */ React15.createElement(Box4, { sx: { display: "inline-grid", minWidth: 0 } }, /* @__PURE__ */ React15.createElement(Typography7, { sx: { lineHeight: 1.34 }, variant: "caption", noWrap: true }, label)),
1436
+ startIcon: /* @__PURE__ */ React16.createElement(Stack5, { gap: 0.5, direction: "row", alignItems: "center" }, startIcon),
1437
+ label: /* @__PURE__ */ React16.createElement(Box4, { sx: { display: "inline-grid", minWidth: 0 } }, /* @__PURE__ */ React16.createElement(Typography7, { sx: { lineHeight: 1.34 }, variant: "caption", noWrap: true }, label)),
1422
1438
  actions,
1423
1439
  ...props
1424
1440
  }
@@ -1440,15 +1456,15 @@ var AssignedVariable = ({ variable, propTypeKey }) => {
1440
1456
  setValue(fallbackValue);
1441
1457
  };
1442
1458
  const StartIcon = startIcon || (() => null);
1443
- return /* @__PURE__ */ React16.createElement(Box5, { ref: anchorRef }, /* @__PURE__ */ React16.createElement(
1459
+ return /* @__PURE__ */ React17.createElement(Box5, { ref: anchorRef }, /* @__PURE__ */ React17.createElement(
1444
1460
  AssignedTag,
1445
1461
  {
1446
1462
  label: variable.label,
1447
- startIcon: /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(ColorFilterIcon2, { fontSize: SIZE5 }), /* @__PURE__ */ React16.createElement(StartIcon, { value: variable.value })),
1463
+ startIcon: /* @__PURE__ */ React17.createElement(React17.Fragment, null, /* @__PURE__ */ React17.createElement(ColorFilterIcon2, { fontSize: SIZE5 }), /* @__PURE__ */ React17.createElement(StartIcon, { value: variable.value })),
1448
1464
  onUnlink: unlinkVariable,
1449
1465
  ...bindTrigger(popupState)
1450
1466
  }
1451
- ), /* @__PURE__ */ React16.createElement(
1467
+ ), /* @__PURE__ */ React17.createElement(
1452
1468
  Popover,
1453
1469
  {
1454
1470
  disableScrollLock: true,
@@ -1460,7 +1476,7 @@ var AssignedVariable = ({ variable, propTypeKey }) => {
1460
1476
  },
1461
1477
  ...bindPopover(popupState)
1462
1478
  },
1463
- /* @__PURE__ */ React16.createElement(
1479
+ /* @__PURE__ */ React17.createElement(
1464
1480
  VariableSelectionPopover,
1465
1481
  {
1466
1482
  selectedVariable: variable,
@@ -1472,13 +1488,13 @@ var AssignedVariable = ({ variable, propTypeKey }) => {
1472
1488
  };
1473
1489
 
1474
1490
  // src/components/ui/variable/deleted-variable.tsx
1475
- import * as React20 from "react";
1491
+ import * as React21 from "react";
1476
1492
  import { useId as useId3, useRef as useRef2, useState as useState9 } from "react";
1477
1493
  import { useBoundProp as useBoundProp8 } from "@elementor/editor-controls";
1478
1494
  import { Backdrop, bindPopover as bindPopover2, Box as Box7, Infotip, Popover as Popover2, usePopupState as usePopupState2 } from "@elementor/ui";
1479
1495
 
1480
1496
  // src/components/variable-restore.tsx
1481
- import * as React17 from "react";
1497
+ import * as React18 from "react";
1482
1498
  import { useState as useState8 } from "react";
1483
1499
  import { PopoverContent as PopoverContent3, useBoundProp as useBoundProp7 } from "@elementor/editor-controls";
1484
1500
  import { PopoverBody as PopoverBody4 } from "@elementor/editor-editing-panel";
@@ -1494,6 +1510,7 @@ var VariableRestore = ({ variableId, onClose, onSubmit }) => {
1494
1510
  throw new Error(`Global ${variableType} variable not found`);
1495
1511
  }
1496
1512
  const [errorMessage, setErrorMessage] = useState8("");
1513
+ const [valueFieldError, setValueFieldError] = useState8("");
1497
1514
  const [label, setLabel] = useState8(variable.label);
1498
1515
  const [value, setValue] = useState8(variable.value);
1499
1516
  const { labelFieldError, setLabelFieldError } = useLabelError({
@@ -1527,14 +1544,14 @@ var VariableRestore = ({ variableId, onClose, onSubmit }) => {
1527
1544
  return !!errorMessage;
1528
1545
  };
1529
1546
  const isSubmitDisabled = noValueChanged() || hasEmptyValues() || hasErrors();
1530
- return /* @__PURE__ */ React17.createElement(PopoverContentRefContextProvider, null, /* @__PURE__ */ React17.createElement(PopoverBody4, { height: "auto" }, /* @__PURE__ */ React17.createElement(
1547
+ return /* @__PURE__ */ React18.createElement(PopoverContentRefContextProvider, null, /* @__PURE__ */ React18.createElement(PopoverBody4, { height: "auto" }, /* @__PURE__ */ React18.createElement(
1531
1548
  PopoverHeader4,
1532
1549
  {
1533
- icon: /* @__PURE__ */ React17.createElement(VariableIcon, { fontSize: SIZE6 }),
1550
+ icon: /* @__PURE__ */ React18.createElement(VariableIcon, { fontSize: SIZE6 }),
1534
1551
  title: __15("Restore variable", "elementor"),
1535
1552
  onClose
1536
1553
  }
1537
- ), /* @__PURE__ */ React17.createElement(Divider5, null), /* @__PURE__ */ React17.createElement(PopoverContent3, { p: 2 }, /* @__PURE__ */ React17.createElement(
1554
+ ), /* @__PURE__ */ React18.createElement(Divider5, null), /* @__PURE__ */ React18.createElement(PopoverContent3, { p: 2 }, /* @__PURE__ */ React18.createElement(
1538
1555
  LabelField,
1539
1556
  {
1540
1557
  value: label,
@@ -1544,35 +1561,37 @@ var VariableRestore = ({ variableId, onClose, onSubmit }) => {
1544
1561
  setErrorMessage("");
1545
1562
  }
1546
1563
  }
1547
- ), /* @__PURE__ */ React17.createElement(
1564
+ ), /* @__PURE__ */ React18.createElement(FormField, { errorMsg: valueFieldError, label: __15("Value", "elementor") }, /* @__PURE__ */ React18.createElement(
1548
1565
  ValueField,
1549
1566
  {
1550
1567
  value,
1551
1568
  onChange: (newValue) => {
1552
1569
  setValue(newValue);
1553
1570
  setErrorMessage("");
1554
- }
1571
+ setValueFieldError("");
1572
+ },
1573
+ onValidationChange: setValueFieldError
1555
1574
  }
1556
- ), errorMessage && /* @__PURE__ */ React17.createElement(FormHelperText4, { error: true }, errorMessage)), /* @__PURE__ */ React17.createElement(CardActions3, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React17.createElement(Button7, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleRestore }, __15("Restore", "elementor")))));
1575
+ )), errorMessage && /* @__PURE__ */ React18.createElement(FormHelperText4, { error: true }, errorMessage)), /* @__PURE__ */ React18.createElement(CardActions3, { sx: { pt: 0.5, pb: 1 } }, /* @__PURE__ */ React18.createElement(Button7, { size: "small", variant: "contained", disabled: isSubmitDisabled, onClick: handleRestore }, __15("Restore", "elementor")))));
1557
1576
  };
1558
1577
 
1559
1578
  // src/components/ui/deleted-variable-alert.tsx
1560
- import * as React18 from "react";
1579
+ import * as React19 from "react";
1561
1580
  import { useSectionWidth } from "@elementor/editor-editing-panel";
1562
1581
  import { Alert as Alert2, AlertAction, AlertTitle, ClickAwayListener } from "@elementor/ui";
1563
1582
  import { __ as __16 } from "@wordpress/i18n";
1564
1583
  var DeletedVariableAlert = ({ onClose, onUnlink, onRestore, label }) => {
1565
1584
  const sectionWidth = useSectionWidth();
1566
- return /* @__PURE__ */ React18.createElement(ClickAwayListener, { onClickAway: onClose }, /* @__PURE__ */ React18.createElement(
1585
+ return /* @__PURE__ */ React19.createElement(ClickAwayListener, { onClickAway: onClose }, /* @__PURE__ */ React19.createElement(
1567
1586
  Alert2,
1568
1587
  {
1569
1588
  variant: "standard",
1570
1589
  severity: "warning",
1571
1590
  onClose,
1572
- action: /* @__PURE__ */ React18.createElement(React18.Fragment, null, onUnlink && /* @__PURE__ */ React18.createElement(AlertAction, { variant: "contained", onClick: onUnlink }, __16("Unlink", "elementor")), onRestore && /* @__PURE__ */ React18.createElement(AlertAction, { variant: "outlined", onClick: onRestore }, __16("Restore", "elementor"))),
1591
+ action: /* @__PURE__ */ React19.createElement(React19.Fragment, null, onUnlink && /* @__PURE__ */ React19.createElement(AlertAction, { variant: "contained", onClick: onUnlink }, __16("Unlink", "elementor")), onRestore && /* @__PURE__ */ React19.createElement(AlertAction, { variant: "outlined", onClick: onRestore }, __16("Restore", "elementor"))),
1573
1592
  sx: { width: sectionWidth }
1574
1593
  },
1575
- /* @__PURE__ */ React18.createElement(AlertTitle, null, __16("Deleted variable", "elementor")),
1594
+ /* @__PURE__ */ React19.createElement(AlertTitle, null, __16("Deleted variable", "elementor")),
1576
1595
  __16("The variable", "elementor"),
1577
1596
  " '",
1578
1597
  label,
@@ -1586,12 +1605,12 @@ var DeletedVariableAlert = ({ onClose, onUnlink, onRestore, label }) => {
1586
1605
  };
1587
1606
 
1588
1607
  // src/components/ui/tags/deleted-tag.tsx
1589
- import * as React19 from "react";
1608
+ import * as React20 from "react";
1590
1609
  import { AlertTriangleFilledIcon as AlertTriangleFilledIcon2 } from "@elementor/icons";
1591
1610
  import { Box as Box6, Chip, Tooltip as Tooltip2, Typography as Typography8 } from "@elementor/ui";
1592
1611
  import { __ as __17 } from "@wordpress/i18n";
1593
- var DeletedTag = React19.forwardRef(({ label, onClick, ...props }, ref) => {
1594
- return /* @__PURE__ */ React19.createElement(
1612
+ var DeletedTag = React20.forwardRef(({ label, onClick, ...props }, ref) => {
1613
+ return /* @__PURE__ */ React20.createElement(
1595
1614
  Chip,
1596
1615
  {
1597
1616
  ref,
@@ -1600,8 +1619,8 @@ var DeletedTag = React19.forwardRef(({ label, onClick, ...props }, ref) => {
1600
1619
  shape: "rounded",
1601
1620
  variant: "standard",
1602
1621
  onClick,
1603
- icon: /* @__PURE__ */ React19.createElement(AlertTriangleFilledIcon2, null),
1604
- label: /* @__PURE__ */ React19.createElement(Tooltip2, { title: label, placement: "top" }, /* @__PURE__ */ React19.createElement(Box6, { sx: { display: "flex", gap: 0.5, alignItems: "center" } }, /* @__PURE__ */ React19.createElement(Typography8, { variant: "caption", noWrap: true }, label), /* @__PURE__ */ React19.createElement(Typography8, { variant: "caption", noWrap: true, sx: { textOverflow: "initial", overflow: "visible" } }, "(", __17("deleted", "elementor"), ")"))),
1622
+ icon: /* @__PURE__ */ React20.createElement(AlertTriangleFilledIcon2, null),
1623
+ label: /* @__PURE__ */ React20.createElement(Tooltip2, { title: label, placement: "top" }, /* @__PURE__ */ React20.createElement(Box6, { sx: { display: "flex", gap: 0.5, alignItems: "center" } }, /* @__PURE__ */ React20.createElement(Typography8, { variant: "caption", noWrap: true }, label), /* @__PURE__ */ React20.createElement(Typography8, { variant: "caption", noWrap: true, sx: { textOverflow: "initial", overflow: "visible" } }, "(", __17("deleted", "elementor"), ")"))),
1605
1624
  sx: {
1606
1625
  height: (theme) => theme.spacing(3.5),
1607
1626
  borderRadius: (theme) => theme.spacing(1),
@@ -1651,7 +1670,7 @@ var DeletedVariable = ({ variable, propTypeKey }) => {
1651
1670
  const handleRestoreWithOverrides = () => {
1652
1671
  popupState.close();
1653
1672
  };
1654
- return /* @__PURE__ */ React20.createElement(React20.Fragment, null, /* @__PURE__ */ React20.createElement(Box7, { ref: deletedChipAnchorRef }, showInfotip && /* @__PURE__ */ React20.createElement(Backdrop, { open: true, onClick: closeInfotip, invisible: true }), /* @__PURE__ */ React20.createElement(
1673
+ return /* @__PURE__ */ React21.createElement(React21.Fragment, null, /* @__PURE__ */ React21.createElement(Box7, { ref: deletedChipAnchorRef }, showInfotip && /* @__PURE__ */ React21.createElement(Backdrop, { open: true, onClick: closeInfotip, invisible: true }), /* @__PURE__ */ React21.createElement(
1655
1674
  Infotip,
1656
1675
  {
1657
1676
  color: "warning",
@@ -1659,7 +1678,7 @@ var DeletedVariable = ({ variable, propTypeKey }) => {
1659
1678
  open: showInfotip,
1660
1679
  disableHoverListener: true,
1661
1680
  onClose: closeInfotip,
1662
- content: /* @__PURE__ */ React20.createElement(
1681
+ content: /* @__PURE__ */ React21.createElement(
1663
1682
  DeletedVariableAlert,
1664
1683
  {
1665
1684
  onClose: closeInfotip,
@@ -1679,8 +1698,8 @@ var DeletedVariable = ({ variable, propTypeKey }) => {
1679
1698
  }
1680
1699
  }
1681
1700
  },
1682
- /* @__PURE__ */ React20.createElement(DeletedTag, { label: variable.label, onClick: toggleInfotip })
1683
- ), /* @__PURE__ */ React20.createElement(
1701
+ /* @__PURE__ */ React21.createElement(DeletedTag, { label: variable.label, onClick: toggleInfotip })
1702
+ ), /* @__PURE__ */ React21.createElement(
1684
1703
  Popover2,
1685
1704
  {
1686
1705
  disableScrollLock: true,
@@ -1691,7 +1710,7 @@ var DeletedVariable = ({ variable, propTypeKey }) => {
1691
1710
  },
1692
1711
  ...bindPopover2(popupState)
1693
1712
  },
1694
- /* @__PURE__ */ React20.createElement(VariableTypeProvider, { propTypeKey }, /* @__PURE__ */ React20.createElement(
1713
+ /* @__PURE__ */ React21.createElement(VariableTypeProvider, { propTypeKey }, /* @__PURE__ */ React21.createElement(
1695
1714
  VariableRestore,
1696
1715
  {
1697
1716
  variableId: variable.key ?? "",
@@ -1703,29 +1722,29 @@ var DeletedVariable = ({ variable, propTypeKey }) => {
1703
1722
  };
1704
1723
 
1705
1724
  // src/components/ui/variable/missing-variable.tsx
1706
- import * as React23 from "react";
1725
+ import * as React24 from "react";
1707
1726
  import { useState as useState10 } from "react";
1708
1727
  import { useBoundProp as useBoundProp9 } from "@elementor/editor-controls";
1709
1728
  import { Backdrop as Backdrop2, Infotip as Infotip2 } from "@elementor/ui";
1710
1729
  import { __ as __19 } from "@wordpress/i18n";
1711
1730
 
1712
1731
  // src/components/ui/missing-variable-alert.tsx
1713
- import * as React21 from "react";
1732
+ import * as React22 from "react";
1714
1733
  import { useSectionWidth as useSectionWidth2 } from "@elementor/editor-editing-panel";
1715
1734
  import { Alert as Alert3, AlertAction as AlertAction2, AlertTitle as AlertTitle2, ClickAwayListener as ClickAwayListener2 } from "@elementor/ui";
1716
1735
  import { __ as __18 } from "@wordpress/i18n";
1717
1736
  var MissingVariableAlert = ({ onClose, onClear }) => {
1718
1737
  const sectionWidth = useSectionWidth2();
1719
- return /* @__PURE__ */ React21.createElement(ClickAwayListener2, { onClickAway: onClose }, /* @__PURE__ */ React21.createElement(
1738
+ return /* @__PURE__ */ React22.createElement(ClickAwayListener2, { onClickAway: onClose }, /* @__PURE__ */ React22.createElement(
1720
1739
  Alert3,
1721
1740
  {
1722
1741
  variant: "standard",
1723
1742
  severity: "warning",
1724
1743
  onClose,
1725
- action: /* @__PURE__ */ React21.createElement(React21.Fragment, null, onClear && /* @__PURE__ */ React21.createElement(AlertAction2, { variant: "contained", onClick: onClear }, __18("Clear", "elementor"))),
1744
+ action: /* @__PURE__ */ React22.createElement(React22.Fragment, null, onClear && /* @__PURE__ */ React22.createElement(AlertAction2, { variant: "contained", onClick: onClear }, __18("Clear", "elementor"))),
1726
1745
  sx: { width: sectionWidth }
1727
1746
  },
1728
- /* @__PURE__ */ React21.createElement(AlertTitle2, null, __18("This variable is missing", "elementor")),
1747
+ /* @__PURE__ */ React22.createElement(AlertTitle2, null, __18("This variable is missing", "elementor")),
1729
1748
  __18(
1730
1749
  "It may have been deleted. Try clearing this field and select a different value or variable.",
1731
1750
  "elementor"
@@ -1734,11 +1753,11 @@ var MissingVariableAlert = ({ onClose, onClear }) => {
1734
1753
  };
1735
1754
 
1736
1755
  // src/components/ui/tags/missing-tag.tsx
1737
- import * as React22 from "react";
1756
+ import * as React23 from "react";
1738
1757
  import { AlertTriangleFilledIcon as AlertTriangleFilledIcon3 } from "@elementor/icons";
1739
1758
  import { Chip as Chip2 } from "@elementor/ui";
1740
- var MissingTag = React22.forwardRef(({ label, onClick, ...props }, ref) => {
1741
- return /* @__PURE__ */ React22.createElement(
1759
+ var MissingTag = React23.forwardRef(({ label, onClick, ...props }, ref) => {
1760
+ return /* @__PURE__ */ React23.createElement(
1742
1761
  Chip2,
1743
1762
  {
1744
1763
  ref,
@@ -1747,7 +1766,7 @@ var MissingTag = React22.forwardRef(({ label, onClick, ...props }, ref) => {
1747
1766
  shape: "rounded",
1748
1767
  variant: "standard",
1749
1768
  onClick,
1750
- icon: /* @__PURE__ */ React22.createElement(AlertTriangleFilledIcon3, null),
1769
+ icon: /* @__PURE__ */ React23.createElement(AlertTriangleFilledIcon3, null),
1751
1770
  label,
1752
1771
  sx: {
1753
1772
  height: (theme) => theme.spacing(3.5),
@@ -1767,7 +1786,7 @@ var MissingVariable = () => {
1767
1786
  const toggleInfotip = () => setInfotipVisible((prev) => !prev);
1768
1787
  const closeInfotip = () => setInfotipVisible(false);
1769
1788
  const clearValue = () => setValue(null);
1770
- return /* @__PURE__ */ React23.createElement(React23.Fragment, null, infotipVisible && /* @__PURE__ */ React23.createElement(Backdrop2, { open: true, onClick: closeInfotip, invisible: true }), /* @__PURE__ */ React23.createElement(
1789
+ return /* @__PURE__ */ React24.createElement(React24.Fragment, null, infotipVisible && /* @__PURE__ */ React24.createElement(Backdrop2, { open: true, onClick: closeInfotip, invisible: true }), /* @__PURE__ */ React24.createElement(
1771
1790
  Infotip2,
1772
1791
  {
1773
1792
  color: "warning",
@@ -1775,7 +1794,7 @@ var MissingVariable = () => {
1775
1794
  open: infotipVisible,
1776
1795
  disableHoverListener: true,
1777
1796
  onClose: closeInfotip,
1778
- content: /* @__PURE__ */ React23.createElement(MissingVariableAlert, { onClose: closeInfotip, onClear: clearValue }),
1797
+ content: /* @__PURE__ */ React24.createElement(MissingVariableAlert, { onClose: closeInfotip, onClear: clearValue }),
1779
1798
  slotProps: {
1780
1799
  popper: {
1781
1800
  modifiers: [
@@ -1787,7 +1806,7 @@ var MissingVariable = () => {
1787
1806
  }
1788
1807
  }
1789
1808
  },
1790
- /* @__PURE__ */ React23.createElement(MissingTag, { label: __19("Missing variable", "elementor"), onClick: toggleInfotip })
1809
+ /* @__PURE__ */ React24.createElement(MissingTag, { label: __19("Missing variable", "elementor"), onClick: toggleInfotip })
1791
1810
  ));
1792
1811
  };
1793
1812
 
@@ -1796,17 +1815,17 @@ var VariableControl = () => {
1796
1815
  const boundProp = useBoundProp10().value;
1797
1816
  const assignedVariable = useVariable(boundProp?.value);
1798
1817
  if (!assignedVariable) {
1799
- return /* @__PURE__ */ React24.createElement(MissingVariable, null);
1818
+ return /* @__PURE__ */ React25.createElement(MissingVariable, null);
1800
1819
  }
1801
1820
  const { $$type: propTypeKey } = boundProp;
1802
1821
  if (assignedVariable?.deleted) {
1803
- return /* @__PURE__ */ React24.createElement(DeletedVariable, { variable: assignedVariable, propTypeKey });
1822
+ return /* @__PURE__ */ React25.createElement(DeletedVariable, { variable: assignedVariable, propTypeKey });
1804
1823
  }
1805
- return /* @__PURE__ */ React24.createElement(AssignedVariable, { variable: assignedVariable, propTypeKey });
1824
+ return /* @__PURE__ */ React25.createElement(AssignedVariable, { variable: assignedVariable, propTypeKey });
1806
1825
  };
1807
1826
 
1808
1827
  // src/hooks/use-prop-variable-action.tsx
1809
- import * as React25 from "react";
1828
+ import * as React26 from "react";
1810
1829
  import { useBoundProp as useBoundProp11 } from "@elementor/editor-editing-panel";
1811
1830
  import { ColorFilterIcon as ColorFilterIcon3 } from "@elementor/icons";
1812
1831
  import { __ as __20 } from "@wordpress/i18n";
@@ -1822,7 +1841,7 @@ var usePropVariableAction = () => {
1822
1841
  return null;
1823
1842
  }
1824
1843
  trackOpenVariablePopover(path, variable.variableType);
1825
- return /* @__PURE__ */ React25.createElement(VariableSelectionPopover, { closePopover, propTypeKey: variable.propTypeUtil.key });
1844
+ return /* @__PURE__ */ React26.createElement(VariableSelectionPopover, { closePopover, propTypeKey: variable.propTypeUtil.key });
1826
1845
  }
1827
1846
  };
1828
1847
  };
@@ -1847,16 +1866,15 @@ var trackOpenVariablePopover = (path, variableType) => {
1847
1866
  };
1848
1867
 
1849
1868
  // src/register-variable-types.tsx
1850
- import * as React28 from "react";
1869
+ import * as React29 from "react";
1851
1870
  import { colorPropTypeUtil, stringPropTypeUtil } from "@elementor/editor-props";
1852
1871
  import { BrushIcon, TextIcon as TextIcon2 } from "@elementor/icons";
1853
1872
 
1854
1873
  // src/components/fields/color-field.tsx
1855
- import * as React26 from "react";
1874
+ import * as React27 from "react";
1856
1875
  import { useRef as useRef3, useState as useState11 } from "react";
1857
- import { FormHelperText as FormHelperText5, FormLabel as FormLabel2, Grid as Grid2, UnstableColorField } from "@elementor/ui";
1858
- import { __ as __21 } from "@wordpress/i18n";
1859
- var ColorField = ({ value, onChange }) => {
1876
+ import { UnstableColorField } from "@elementor/ui";
1877
+ var ColorField = ({ value, onChange, onValidationChange }) => {
1860
1878
  const [color, setColor] = useState11(value);
1861
1879
  const [errorMessage, setErrorMessage] = useState11("");
1862
1880
  const defaultRef = useRef3(null);
@@ -1865,16 +1883,17 @@ var ColorField = ({ value, onChange }) => {
1865
1883
  setColor(newValue);
1866
1884
  const errorMsg = validateValue(newValue);
1867
1885
  setErrorMessage(errorMsg);
1886
+ onValidationChange?.(errorMsg);
1868
1887
  onChange(errorMsg ? "" : newValue);
1869
1888
  };
1870
- return /* @__PURE__ */ React26.createElement(Grid2, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React26.createElement(Grid2, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(FormLabel2, { size: "tiny" }, __21("Value", "elementor"))), /* @__PURE__ */ React26.createElement(Grid2, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(
1889
+ return /* @__PURE__ */ React27.createElement(
1871
1890
  UnstableColorField,
1872
1891
  {
1873
1892
  size: "tiny",
1874
1893
  fullWidth: true,
1875
1894
  value: color,
1876
1895
  onChange: handleChange,
1877
- error: errorMessage ?? void 0,
1896
+ error: errorMessage || void 0,
1878
1897
  slotProps: {
1879
1898
  colorPicker: {
1880
1899
  anchorEl: anchorRef,
@@ -1883,35 +1902,25 @@ var ColorField = ({ value, onChange }) => {
1883
1902
  }
1884
1903
  }
1885
1904
  }
1886
- ), errorMessage && /* @__PURE__ */ React26.createElement(FormHelperText5, { error: true }, errorMessage)));
1905
+ );
1887
1906
  };
1888
1907
 
1889
1908
  // src/components/fields/font-field.tsx
1890
- import * as React27 from "react";
1891
- import { useRef as useRef4, useState as useState12 } from "react";
1909
+ import * as React28 from "react";
1910
+ import { useId as useId4, useRef as useRef4, useState as useState12 } from "react";
1892
1911
  import { enqueueFont as enqueueFont2, ItemSelector } from "@elementor/editor-controls";
1893
1912
  import { useFontFamilies, useSectionWidth as useSectionWidth3 } from "@elementor/editor-editing-panel";
1894
1913
  import { ChevronDownIcon, TextIcon } from "@elementor/icons";
1895
- import {
1896
- bindPopover as bindPopover3,
1897
- bindTrigger as bindTrigger2,
1898
- FormHelperText as FormHelperText6,
1899
- FormLabel as FormLabel3,
1900
- Grid as Grid3,
1901
- Popover as Popover3,
1902
- UnstableTag,
1903
- usePopupState as usePopupState3
1904
- } from "@elementor/ui";
1905
- import { __ as __22 } from "@wordpress/i18n";
1906
- var FontField = ({ value, onChange }) => {
1914
+ import { bindPopover as bindPopover3, bindTrigger as bindTrigger2, Popover as Popover3, UnstableTag, usePopupState as usePopupState3 } from "@elementor/ui";
1915
+ import { __ as __21 } from "@wordpress/i18n";
1916
+ var FontField = ({ value, onChange, onValidationChange }) => {
1907
1917
  const [fontFamily, setFontFamily] = useState12(value);
1908
- const [errorMessage, setErrorMessage] = useState12("");
1909
1918
  const defaultRef = useRef4(null);
1910
1919
  const anchorRef = usePopoverContentRef() ?? defaultRef.current;
1911
1920
  const fontPopoverState = usePopupState3({ variant: "popover" });
1912
1921
  const fontFamilies = useFontFamilies();
1913
1922
  const sectionWidth = useSectionWidth3();
1914
- const mapFontSubs = React27.useMemo(() => {
1923
+ const mapFontSubs = React28.useMemo(() => {
1915
1924
  return fontFamilies.map(({ label, fonts }) => ({
1916
1925
  label,
1917
1926
  items: fonts
@@ -1920,23 +1929,25 @@ var FontField = ({ value, onChange }) => {
1920
1929
  const handleChange = (newValue) => {
1921
1930
  setFontFamily(newValue);
1922
1931
  const errorMsg = validateValue(newValue);
1923
- setErrorMessage(errorMsg);
1932
+ onValidationChange?.(errorMsg);
1924
1933
  onChange(errorMsg ? "" : newValue);
1925
1934
  };
1926
1935
  const handleFontFamilyChange = (newFontFamily) => {
1927
1936
  handleChange(newFontFamily);
1928
1937
  fontPopoverState.close();
1929
1938
  };
1930
- return /* @__PURE__ */ React27.createElement(Grid3, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React27.createElement(Grid3, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(FormLabel3, { size: "tiny" }, __22("Value", "elementor"))), /* @__PURE__ */ React27.createElement(Grid3, { item: true, xs: 12 }, /* @__PURE__ */ React27.createElement(
1939
+ const id2 = useId4();
1940
+ return /* @__PURE__ */ React28.createElement(React28.Fragment, null, /* @__PURE__ */ React28.createElement(
1931
1941
  UnstableTag,
1932
1942
  {
1943
+ id: id2,
1933
1944
  variant: "outlined",
1934
1945
  label: fontFamily,
1935
- endIcon: /* @__PURE__ */ React27.createElement(ChevronDownIcon, { fontSize: "tiny" }),
1946
+ endIcon: /* @__PURE__ */ React28.createElement(ChevronDownIcon, { fontSize: "tiny" }),
1936
1947
  ...bindTrigger2(fontPopoverState),
1937
1948
  fullWidth: true
1938
1949
  }
1939
- ), /* @__PURE__ */ React27.createElement(
1950
+ ), /* @__PURE__ */ React28.createElement(
1940
1951
  Popover3,
1941
1952
  {
1942
1953
  disablePortal: true,
@@ -1946,7 +1957,7 @@ var FontField = ({ value, onChange }) => {
1946
1957
  transformOrigin: { vertical: "top", horizontal: -28 },
1947
1958
  ...bindPopover3(fontPopoverState)
1948
1959
  },
1949
- /* @__PURE__ */ React27.createElement(
1960
+ /* @__PURE__ */ React28.createElement(
1950
1961
  ItemSelector,
1951
1962
  {
1952
1963
  itemsList: mapFontSubs,
@@ -1954,13 +1965,13 @@ var FontField = ({ value, onChange }) => {
1954
1965
  onItemChange: handleFontFamilyChange,
1955
1966
  onClose: fontPopoverState.close,
1956
1967
  sectionWidth,
1957
- title: __22("Font Family", "elementor"),
1968
+ title: __21("Font Family", "elementor"),
1958
1969
  itemStyle: (item) => ({ fontFamily: item.value }),
1959
1970
  onDebounce: enqueueFont2,
1960
1971
  icon: TextIcon
1961
1972
  }
1962
1973
  )
1963
- ), errorMessage && /* @__PURE__ */ React27.createElement(FormHelperText6, { error: true }, errorMessage)));
1974
+ ));
1964
1975
  };
1965
1976
 
1966
1977
  // src/register-variable-types.tsx
@@ -1971,7 +1982,7 @@ function registerVariableTypes() {
1971
1982
  propTypeUtil: colorVariablePropTypeUtil,
1972
1983
  fallbackPropTypeUtil: colorPropTypeUtil,
1973
1984
  variableType: "color",
1974
- startIcon: ({ value }) => /* @__PURE__ */ React28.createElement(ColorIndicator, { size: "inherit", component: "span", value })
1985
+ startIcon: ({ value }) => /* @__PURE__ */ React29.createElement(ColorIndicator, { size: "inherit", component: "span", value })
1975
1986
  });
1976
1987
  registerVariableType({
1977
1988
  valueField: FontField,
@@ -1983,7 +1994,7 @@ function registerVariableTypes() {
1983
1994
  }
1984
1995
 
1985
1996
  // src/renderers/style-variables-renderer.tsx
1986
- import * as React29 from "react";
1997
+ import * as React30 from "react";
1987
1998
  import { useEffect as useEffect3, useState as useState13 } from "react";
1988
1999
  import { __privateUseListenTo as useListenTo, commandEndEvent } from "@elementor/editor-v1-adapters";
1989
2000
  import { Portal } from "@elementor/ui";
@@ -2005,7 +2016,7 @@ function StyleVariablesRenderer() {
2005
2016
  }
2006
2017
  const cssVariables = convertToCssVariables(styleVariables);
2007
2018
  const wrappedCss = `${VARIABLES_WRAPPER}{${cssVariables}}`;
2008
- return /* @__PURE__ */ React29.createElement(Portal, { container }, /* @__PURE__ */ React29.createElement("style", { "data-e-style-id": "e-variables", key: wrappedCss }, wrappedCss));
2019
+ return /* @__PURE__ */ React30.createElement(Portal, { container }, /* @__PURE__ */ React30.createElement("style", { "data-e-style-id": "e-variables", key: wrappedCss }, wrappedCss));
2009
2020
  }
2010
2021
  function usePortalContainer() {
2011
2022
  return useListenTo(commandEndEvent("editor/documents/attach-preview"), () => getCanvasIframeDocument()?.head);
@@ -2035,22 +2046,22 @@ import { injectIntoRepeaterItemIcon, injectIntoRepeaterItemLabel } from "@elemen
2035
2046
  import { backgroundColorOverlayPropTypeUtil, shadowPropTypeUtil } from "@elementor/editor-props";
2036
2047
 
2037
2048
  // src/components/variables-repeater-item-slot.tsx
2038
- import * as React30 from "react";
2049
+ import * as React31 from "react";
2039
2050
  var useColorVariable = (value) => {
2040
2051
  const variableId = value?.value?.color?.value;
2041
2052
  return useVariable(variableId || "");
2042
2053
  };
2043
2054
  var BackgroundRepeaterColorIndicator = ({ value }) => {
2044
2055
  const colorVariable = useColorVariable(value);
2045
- return /* @__PURE__ */ React30.createElement(ColorIndicator, { component: "span", size: "inherit", value: colorVariable?.value });
2056
+ return /* @__PURE__ */ React31.createElement(ColorIndicator, { component: "span", size: "inherit", value: colorVariable?.value });
2046
2057
  };
2047
2058
  var BackgroundRepeaterLabel = ({ value }) => {
2048
2059
  const colorVariable = useColorVariable(value);
2049
- return /* @__PURE__ */ React30.createElement("span", null, colorVariable?.label);
2060
+ return /* @__PURE__ */ React31.createElement("span", null, colorVariable?.label);
2050
2061
  };
2051
2062
  var BoxShadowRepeaterColorIndicator = ({ value }) => {
2052
2063
  const colorVariable = useColorVariable(value);
2053
- return /* @__PURE__ */ React30.createElement(ColorIndicator, { component: "span", size: "inherit", value: colorVariable?.value });
2064
+ return /* @__PURE__ */ React31.createElement(ColorIndicator, { component: "span", size: "inherit", value: colorVariable?.value });
2054
2065
  };
2055
2066
 
2056
2067
  // src/repeater-injections.ts