@elementor/editor-controls 0.36.0 → 1.1.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.
Files changed (30) hide show
  1. package/CHANGELOG.md +46 -0
  2. package/dist/index.d.mts +78 -45
  3. package/dist/index.d.ts +78 -45
  4. package/dist/index.js +951 -651
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.mjs +890 -596
  7. package/dist/index.mjs.map +1 -1
  8. package/package.json +8 -7
  9. package/src/bound-prop-context/use-bound-prop.ts +4 -1
  10. package/src/components/font-family-selector.tsx +23 -164
  11. package/src/components/popover-grid-container.tsx +7 -10
  12. package/src/components/repeater.tsx +24 -10
  13. package/src/components/size-control/size-input.tsx +125 -0
  14. package/src/components/{text-field-inner-selection.tsx → size-control/text-field-inner-selection.tsx} +33 -16
  15. package/src/components/text-field-popover.tsx +47 -0
  16. package/src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-position.tsx +11 -3
  17. package/src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-size.tsx +7 -3
  18. package/src/controls/box-shadow-repeater-control.tsx +8 -6
  19. package/src/controls/equal-unequal-sizes-control.tsx +24 -14
  20. package/src/controls/gap-control.tsx +17 -6
  21. package/src/controls/key-value-control.tsx +99 -0
  22. package/src/controls/linked-dimensions-control.tsx +62 -81
  23. package/src/controls/position-control.tsx +109 -0
  24. package/src/controls/repeatable-control.tsx +89 -0
  25. package/src/controls/size-control.tsx +181 -149
  26. package/src/controls/stroke-control.tsx +9 -6
  27. package/src/hooks/use-repeatable-control-context.ts +24 -0
  28. package/src/hooks/use-size-extended-options.ts +21 -0
  29. package/src/index.ts +4 -1
  30. package/src/utils/size-control.ts +10 -0
package/dist/index.mjs CHANGED
@@ -442,16 +442,38 @@ var TextAreaControl = createControl(({ placeholder }) => {
442
442
  });
443
443
 
444
444
  // src/controls/size-control.tsx
445
+ import * as React16 from "react";
446
+ import { useEffect as useEffect2, useState as useState3 } from "react";
447
+ import { sizePropTypeUtil } from "@elementor/editor-props";
448
+ import { useActiveBreakpoint } from "@elementor/editor-responsive";
449
+ import { usePopupState as usePopupState2 } from "@elementor/ui";
450
+
451
+ // src/components/size-control/size-input.tsx
445
452
  import * as React14 from "react";
446
453
  import { useRef } from "react";
447
- import { sizePropTypeUtil, stringPropTypeUtil as stringPropTypeUtil4 } from "@elementor/editor-props";
454
+ import { PencilIcon } from "@elementor/icons";
448
455
  import { Box, InputAdornment as InputAdornment2 } from "@elementor/ui";
449
456
 
450
- // src/components/text-field-inner-selection.tsx
457
+ // src/utils/size-control.ts
458
+ var defaultUnits = ["px", "%", "em", "rem", "vw", "vh"];
459
+ var defaultExtendedOptions = ["auto", "custom"];
460
+ function isUnitExtendedOption(unit) {
461
+ return defaultExtendedOptions.includes(unit);
462
+ }
463
+
464
+ // src/components/size-control/text-field-inner-selection.tsx
451
465
  import * as React13 from "react";
452
466
  import { forwardRef, useId } from "react";
453
467
  import { MenuListItem as MenuListItem2 } from "@elementor/editor-ui";
454
- import { bindMenu, bindTrigger, Button as Button2, InputAdornment, Menu, TextField as TextField3, usePopupState } from "@elementor/ui";
468
+ import {
469
+ bindMenu,
470
+ bindTrigger,
471
+ Button as Button2,
472
+ InputAdornment,
473
+ Menu,
474
+ TextField as TextField3,
475
+ usePopupState
476
+ } from "@elementor/ui";
455
477
  var TextFieldInnerSelection = forwardRef(
456
478
  ({
457
479
  placeholder,
@@ -461,36 +483,36 @@ var TextFieldInnerSelection = forwardRef(
461
483
  onBlur,
462
484
  onKeyDown,
463
485
  onKeyUp,
464
- endAdornment,
465
- startAdornment,
486
+ shouldBlockInput = false,
487
+ inputProps,
466
488
  disabled
467
489
  }, ref) => {
468
490
  return /* @__PURE__ */ React13.createElement(
469
491
  TextField3,
470
492
  {
471
493
  ref,
494
+ sx: { input: { cursor: shouldBlockInput ? "default !important" : void 0 } },
472
495
  size: "tiny",
473
496
  fullWidth: true,
474
- type,
497
+ type: shouldBlockInput ? void 0 : type,
475
498
  value,
499
+ onChange: shouldBlockInput ? void 0 : onChange,
500
+ onKeyDown: shouldBlockInput ? void 0 : onKeyDown,
501
+ onKeyUp: shouldBlockInput ? void 0 : onKeyUp,
476
502
  disabled,
477
- onChange,
478
- onKeyDown,
479
- onKeyUp,
480
503
  onBlur,
481
504
  placeholder,
482
- InputProps: {
483
- endAdornment,
484
- startAdornment
485
- }
505
+ InputProps: inputProps
486
506
  }
487
507
  );
488
508
  }
489
509
  );
490
510
  var SelectionEndAdornment = ({
491
511
  options,
512
+ alternativeOptionLabels = {},
492
513
  onClick,
493
514
  value,
515
+ menuItemsAttributes = {},
494
516
  disabled
495
517
  }) => {
496
518
  const popupState = usePopupState({
@@ -510,10 +532,159 @@ var SelectionEndAdornment = ({
510
532
  sx: { font: "inherit", minWidth: "initial", textTransform: "uppercase" },
511
533
  ...bindTrigger(popupState)
512
534
  },
513
- value
514
- ), /* @__PURE__ */ React13.createElement(Menu, { MenuListProps: { dense: true }, ...bindMenu(popupState) }, options.map((option, index) => /* @__PURE__ */ React13.createElement(MenuListItem2, { key: option, onClick: () => handleMenuItemClick(index) }, option.toUpperCase()))));
535
+ alternativeOptionLabels[value] ?? value
536
+ ), /* @__PURE__ */ React13.createElement(Menu, { MenuListProps: { dense: true }, ...bindMenu(popupState) }, options.map((option, index) => /* @__PURE__ */ React13.createElement(
537
+ MenuListItem2,
538
+ {
539
+ key: option,
540
+ onClick: () => handleMenuItemClick(index),
541
+ ...menuItemsAttributes?.[option]
542
+ },
543
+ alternativeOptionLabels[option] ?? option.toUpperCase()
544
+ ))));
545
+ };
546
+
547
+ // src/components/size-control/size-input.tsx
548
+ var RESTRICTED_INPUT_KEYS = ["e", "E", "+", "-"];
549
+ var SizeInput = ({
550
+ units: units2,
551
+ handleUnitChange,
552
+ handleSizeChange,
553
+ placeholder,
554
+ startIcon,
555
+ onBlur,
556
+ onFocus,
557
+ onClick,
558
+ size,
559
+ unit,
560
+ popupState,
561
+ disabled
562
+ }) => {
563
+ const unitInputBufferRef = useRef("");
564
+ const inputType = isUnitExtendedOption(unit) ? "text" : "number";
565
+ const inputValue = !isUnitExtendedOption(unit) && Number.isNaN(size) ? "" : size ?? "";
566
+ const handleKeyUp = (event) => {
567
+ const { key } = event;
568
+ if (!/^[a-zA-Z%]$/.test(key)) {
569
+ return;
570
+ }
571
+ event.preventDefault();
572
+ const newChar = key.toLowerCase();
573
+ const updatedBuffer = (unitInputBufferRef.current + newChar).slice(-3);
574
+ unitInputBufferRef.current = updatedBuffer;
575
+ const matchedUnit = units2.find((u) => u.includes(updatedBuffer)) || units2.find((u) => u.startsWith(newChar)) || units2.find((u) => u.includes(newChar));
576
+ if (matchedUnit) {
577
+ handleUnitChange(matchedUnit);
578
+ }
579
+ };
580
+ const popupAttributes = {
581
+ "aria-controls": popupState.isOpen ? popupState.popupId : void 0,
582
+ "aria-haspopup": true
583
+ };
584
+ const inputProps = {
585
+ ...popupAttributes,
586
+ autoComplete: "off",
587
+ onClick,
588
+ onFocus,
589
+ startAdornment: startIcon ? /* @__PURE__ */ React14.createElement(InputAdornment2, { position: "start", disabled }, startIcon) : void 0,
590
+ endAdornment: /* @__PURE__ */ React14.createElement(
591
+ SelectionEndAdornment,
592
+ {
593
+ disabled,
594
+ options: units2,
595
+ onClick: handleUnitChange,
596
+ value: unit,
597
+ alternativeOptionLabels: {
598
+ custom: /* @__PURE__ */ React14.createElement(PencilIcon, { fontSize: "small" })
599
+ },
600
+ menuItemsAttributes: units2.includes("custom") ? {
601
+ custom: popupAttributes
602
+ } : void 0
603
+ }
604
+ )
605
+ };
606
+ return /* @__PURE__ */ React14.createElement(ControlActions, null, /* @__PURE__ */ React14.createElement(Box, null, /* @__PURE__ */ React14.createElement(
607
+ TextFieldInnerSelection,
608
+ {
609
+ disabled,
610
+ placeholder,
611
+ type: inputType,
612
+ value: inputValue,
613
+ onChange: handleSizeChange,
614
+ onKeyDown: (event) => {
615
+ if (RESTRICTED_INPUT_KEYS.includes(event.key)) {
616
+ event.preventDefault();
617
+ }
618
+ },
619
+ onKeyUp: handleKeyUp,
620
+ onBlur,
621
+ shouldBlockInput: isUnitExtendedOption(unit),
622
+ inputProps
623
+ }
624
+ )));
625
+ };
626
+
627
+ // src/components/text-field-popover.tsx
628
+ import * as React15 from "react";
629
+ import { bindPopover, Paper, Popover, TextField as TextField4 } from "@elementor/ui";
630
+ var TextFieldPopover = (props) => {
631
+ const { popupState, restoreValue, anchorRef, value, onChange } = props;
632
+ return /* @__PURE__ */ React15.createElement(
633
+ Popover,
634
+ {
635
+ disablePortal: true,
636
+ ...bindPopover(popupState),
637
+ anchorOrigin: { vertical: "bottom", horizontal: "center" },
638
+ transformOrigin: { vertical: "top", horizontal: "center" },
639
+ onClose: () => {
640
+ restoreValue();
641
+ popupState.close();
642
+ }
643
+ },
644
+ /* @__PURE__ */ React15.createElement(
645
+ Paper,
646
+ {
647
+ sx: {
648
+ width: anchorRef.current.offsetWidth + "px",
649
+ borderRadius: 2,
650
+ p: 1.5
651
+ }
652
+ },
653
+ /* @__PURE__ */ React15.createElement(
654
+ TextField4,
655
+ {
656
+ value,
657
+ onChange,
658
+ size: "tiny",
659
+ type: "text",
660
+ fullWidth: true,
661
+ inputProps: {
662
+ autoFocus: true
663
+ }
664
+ }
665
+ )
666
+ )
667
+ );
515
668
  };
516
669
 
670
+ // src/hooks/use-size-extended-options.ts
671
+ import { useMemo } from "react";
672
+ import { isExperimentActive } from "@elementor/editor-v1-adapters";
673
+ var EXPERIMENT_ID = "e_v_3_30";
674
+ function useSizeExtendedOptions(options, disableCustom) {
675
+ return useMemo(() => {
676
+ const isVersion330Active = isExperimentActive(EXPERIMENT_ID);
677
+ const shouldDisableCustom = !isVersion330Active || disableCustom;
678
+ const extendedOptions = [...options];
679
+ if (!shouldDisableCustom && !extendedOptions.includes("custom")) {
680
+ extendedOptions.push("custom");
681
+ } else if (options.includes("custom")) {
682
+ extendedOptions.splice(extendedOptions.indexOf("custom"), 1);
683
+ }
684
+ return extendedOptions;
685
+ }, [options, disableCustom]);
686
+ }
687
+
517
688
  // src/hooks/use-sync-external-state.tsx
518
689
  import { useEffect, useState as useState2 } from "react";
519
690
  var useSyncExternalState = ({
@@ -548,139 +719,164 @@ var useSyncExternalState = ({
548
719
  };
549
720
 
550
721
  // src/controls/size-control.tsx
551
- var defaultUnits = ["px", "%", "em", "rem", "vw", "vh"];
552
- var defaultUnit = "px";
553
- var defaultSize = NaN;
554
- var SizeControl = createControl(
555
- ({ units: units2 = defaultUnits, extendedValues = [], placeholder, startIcon }) => {
556
- const { value: sizeValue, setValue: setSizeValue, restoreValue, disabled } = useBoundProp(sizePropTypeUtil);
557
- const [state, setState] = useSyncExternalState({
558
- external: sizeValue,
559
- setExternal: setSizeValue,
560
- persistWhen: (controlValue) => !!controlValue?.size || controlValue?.size === 0,
561
- fallback: (controlValue) => ({ unit: controlValue?.unit || defaultUnit, size: defaultSize })
562
- });
563
- const handleUnitChange = (unit) => {
564
- setState((prev) => ({
565
- size: prev?.size ?? defaultSize,
566
- unit
567
- }));
568
- };
569
- const handleSizeChange = (event) => {
570
- const { value: size } = event.target;
571
- setState((prev) => ({
572
- ...prev,
573
- size: size || size === "0" ? parseFloat(size) : defaultSize
574
- }));
575
- };
576
- const Input = extendedValues?.length ? ExtendedSizeInput : SizeInput;
577
- return /* @__PURE__ */ React14.createElement(
578
- Input,
579
- {
580
- disabled,
581
- size: state.size,
582
- unit: state.unit,
583
- placeholder,
584
- startIcon,
585
- units: units2,
586
- extendedValues,
587
- handleSizeChange,
588
- handleUnitChange,
589
- onBlur: restoreValue
722
+ var DEFAULT_UNIT = "px";
723
+ var DEFAULT_SIZE = NaN;
724
+ var SizeControl = createControl((props) => {
725
+ const defaultUnit = props.defaultUnit ?? DEFAULT_UNIT;
726
+ const { units: units2 = [...defaultUnits], placeholder, startIcon, anchorRef } = props;
727
+ const { value: sizeValue, setValue: setSizeValue, disabled, restoreValue } = useBoundProp(sizePropTypeUtil);
728
+ const [internalState, setInternalState] = useState3(createStateFromSizeProp(sizeValue, defaultUnit));
729
+ const activeBreakpoint = useActiveBreakpoint();
730
+ const extendedOptions = useSizeExtendedOptions(props.extendedOptions || [], props.disableCustom ?? false);
731
+ const popupState = usePopupState2({ variant: "popover" });
732
+ const [state, setState] = useSyncExternalState({
733
+ external: internalState,
734
+ setExternal: (newState) => setSizeValue(extractValueFromState(newState)),
735
+ persistWhen: (newState) => {
736
+ if (!newState?.unit) {
737
+ return false;
590
738
  }
591
- );
592
- }
593
- );
594
- var ExtendedSizeInput = (props) => {
595
- const { value: stringValue, setValue: setStringValue } = useBoundProp(stringPropTypeUtil4);
596
- const { extendedValues = [] } = props;
597
- const unit = stringValue ?? props.unit;
739
+ if (isUnitExtendedOption(newState.unit)) {
740
+ return newState.unit === "auto" ? true : !!newState.custom;
741
+ }
742
+ return !!newState?.numeric || newState?.numeric === 0;
743
+ },
744
+ fallback: (newState) => ({
745
+ unit: newState?.unit ?? props.defaultUnit ?? DEFAULT_UNIT,
746
+ numeric: newState?.numeric ?? DEFAULT_SIZE,
747
+ custom: newState?.custom ?? ""
748
+ })
749
+ });
750
+ const { size: controlSize = DEFAULT_SIZE, unit: controlUnit = DEFAULT_UNIT } = extractValueFromState(state) || {};
598
751
  const handleUnitChange = (newUnit) => {
599
- if (extendedValues.includes(newUnit)) {
600
- setStringValue(newUnit);
601
- } else {
602
- props.handleUnitChange(newUnit);
752
+ if (newUnit === "custom") {
753
+ popupState.open(anchorRef?.current);
603
754
  }
755
+ setState((prev) => ({ ...prev, unit: newUnit }));
604
756
  };
605
- return /* @__PURE__ */ React14.createElement(
606
- SizeInput,
607
- {
608
- ...props,
609
- units: [...props.units, ...extendedValues],
610
- handleUnitChange,
611
- unit
612
- }
613
- );
614
- };
615
- var RESTRICTED_INPUT_KEYS = ["e", "E", "+", "-"];
616
- var SizeInput = ({
617
- units: units2,
618
- handleUnitChange,
619
- handleSizeChange,
620
- placeholder,
621
- startIcon,
622
- onBlur,
623
- size,
624
- unit,
625
- disabled
626
- }) => {
627
- const unitInputBufferRef = useRef("");
628
- const handleKeyUp = (event) => {
629
- const { key } = event;
630
- if (!/^[a-zA-Z%]$/.test(key)) {
757
+ const handleSizeChange = (event) => {
758
+ const { value: size } = event.target;
759
+ if (controlUnit === "auto") {
760
+ setState((prev) => ({ ...prev, unit: controlUnit }));
631
761
  return;
632
762
  }
633
- event.preventDefault();
634
- const newChar = key.toLowerCase();
635
- const updatedBuffer = (unitInputBufferRef.current + newChar).slice(-3);
636
- unitInputBufferRef.current = updatedBuffer;
637
- const matchedUnit = units2.find((u) => u.includes(updatedBuffer)) || units2.find((u) => u.startsWith(newChar)) || units2.find((u) => u.includes(newChar));
638
- if (matchedUnit) {
639
- handleUnitChange(matchedUnit);
763
+ setState((prev) => ({
764
+ ...prev,
765
+ [controlUnit === "custom" ? "custom" : "numeric"]: formatSize(size, controlUnit),
766
+ unit: controlUnit
767
+ }));
768
+ };
769
+ const onInputFocus = (event) => {
770
+ if (isUnitExtendedOption(state.unit)) {
771
+ event.target?.blur();
640
772
  }
641
773
  };
642
- return /* @__PURE__ */ React14.createElement(ControlActions, null, /* @__PURE__ */ React14.createElement(Box, null, /* @__PURE__ */ React14.createElement(
643
- TextFieldInnerSelection,
774
+ const onInputClick = (event) => {
775
+ if (event.target.closest("input") && "custom" === state.unit) {
776
+ popupState.open(anchorRef?.current);
777
+ }
778
+ };
779
+ useEffect2(() => {
780
+ const newState = createStateFromSizeProp(sizeValue, defaultUnit);
781
+ const currentUnit = isUnitExtendedOption(state.unit) ? "custom" : "numeric";
782
+ const mergedStates = { ...state, [currentUnit]: newState[currentUnit] };
783
+ if (mergedStates.unit !== "auto" && areStatesEqual(state, mergedStates)) {
784
+ return;
785
+ }
786
+ if (state.unit === newState.unit) {
787
+ setInternalState(mergedStates);
788
+ return;
789
+ }
790
+ setState(newState);
791
+ }, [sizeValue]);
792
+ useEffect2(() => {
793
+ const newState = createStateFromSizeProp(sizeValue, defaultUnit);
794
+ if (activeBreakpoint && !areStatesEqual(newState, state)) {
795
+ setState(newState);
796
+ }
797
+ }, [activeBreakpoint]);
798
+ return /* @__PURE__ */ React16.createElement(React16.Fragment, null, /* @__PURE__ */ React16.createElement(
799
+ SizeInput,
644
800
  {
645
801
  disabled,
646
- endAdornment: /* @__PURE__ */ React14.createElement(
647
- SelectionEndAdornment,
648
- {
649
- disabled,
650
- options: units2,
651
- onClick: handleUnitChange,
652
- value: unit ?? defaultUnit
653
- }
654
- ),
802
+ size: controlSize,
803
+ unit: controlUnit,
804
+ units: [...units2, ...extendedOptions || []],
655
805
  placeholder,
656
- startAdornment: startIcon ? /* @__PURE__ */ React14.createElement(InputAdornment2, { position: "start", disabled }, startIcon) : void 0,
657
- type: "number",
658
- value: Number.isNaN(size) ? "" : size,
659
- onChange: handleSizeChange,
660
- onBlur,
661
- onKeyDown: (event) => {
662
- if (RESTRICTED_INPUT_KEYS.includes(event.key)) {
663
- event.preventDefault();
664
- }
665
- },
666
- onKeyUp: handleKeyUp
806
+ startIcon,
807
+ handleSizeChange,
808
+ handleUnitChange,
809
+ onBlur: restoreValue,
810
+ onFocus: onInputFocus,
811
+ onClick: onInputClick,
812
+ popupState
667
813
  }
668
- )));
669
- };
814
+ ), anchorRef?.current && /* @__PURE__ */ React16.createElement(
815
+ TextFieldPopover,
816
+ {
817
+ popupState,
818
+ anchorRef,
819
+ restoreValue,
820
+ value: controlSize,
821
+ onChange: handleSizeChange
822
+ }
823
+ ));
824
+ });
825
+ function formatSize(size, unit) {
826
+ if (isUnitExtendedOption(unit)) {
827
+ return unit === "auto" ? "" : String(size ?? "");
828
+ }
829
+ return size || size === 0 ? Number(size) : NaN;
830
+ }
831
+ function createStateFromSizeProp(sizeValue, defaultUnit) {
832
+ const unit = sizeValue?.unit ?? defaultUnit;
833
+ const size = sizeValue?.size ?? "";
834
+ return {
835
+ numeric: !isUnitExtendedOption(unit) && !isNaN(Number(size)) && (size || size === 0) ? Number(size) : DEFAULT_SIZE,
836
+ custom: unit === "custom" ? String(size) : "",
837
+ unit
838
+ };
839
+ }
840
+ function extractValueFromState(state) {
841
+ if (!state) {
842
+ return null;
843
+ }
844
+ if (!state?.unit) {
845
+ return { size: DEFAULT_SIZE, unit: DEFAULT_UNIT };
846
+ }
847
+ const { unit } = state;
848
+ if (unit === "auto") {
849
+ return { size: "", unit };
850
+ }
851
+ return {
852
+ size: state[unit === "custom" ? "custom" : "numeric"],
853
+ unit
854
+ };
855
+ }
856
+ function areStatesEqual(state1, state2) {
857
+ if (state1.unit !== state2.unit || state1.custom !== state2.custom) {
858
+ return false;
859
+ }
860
+ if (isUnitExtendedOption(state1.unit)) {
861
+ return state1.custom === state2.custom;
862
+ }
863
+ return state1.numeric === state2.numeric || isNaN(state1.numeric) && isNaN(state2.numeric);
864
+ }
670
865
 
671
866
  // src/controls/stroke-control.tsx
672
- import * as React17 from "react";
867
+ import * as React19 from "react";
868
+ import { forwardRef as forwardRef2, useRef as useRef2 } from "react";
673
869
  import { strokePropTypeUtil } from "@elementor/editor-props";
674
870
  import { Grid as Grid2 } from "@elementor/ui";
675
871
  import { __ as __3 } from "@wordpress/i18n";
676
872
 
677
873
  // src/components/section-content.tsx
678
- import * as React15 from "react";
874
+ import * as React17 from "react";
679
875
  import { Stack as Stack3 } from "@elementor/ui";
680
- var SectionContent = ({ gap = 2, sx, children }) => /* @__PURE__ */ React15.createElement(Stack3, { gap, sx: { ...sx } }, children);
876
+ var SectionContent = ({ gap = 2, sx, children }) => /* @__PURE__ */ React17.createElement(Stack3, { gap, sx: { ...sx } }, children);
681
877
 
682
878
  // src/controls/color-control.tsx
683
- import * as React16 from "react";
879
+ import * as React18 from "react";
684
880
  import { colorPropTypeUtil } from "@elementor/editor-props";
685
881
  import { UnstableColorField } from "@elementor/ui";
686
882
  var ColorControl = createControl(
@@ -689,7 +885,7 @@ var ColorControl = createControl(
689
885
  const handleChange = (selectedColor) => {
690
886
  setValue(selectedColor || null);
691
887
  };
692
- return /* @__PURE__ */ React16.createElement(ControlActions, null, /* @__PURE__ */ React16.createElement(
888
+ return /* @__PURE__ */ React18.createElement(ControlActions, null, /* @__PURE__ */ React18.createElement(
693
889
  UnstableColorField,
694
890
  {
695
891
  size: "tiny",
@@ -721,57 +917,57 @@ var ColorControl = createControl(
721
917
  var units = ["px", "em", "rem"];
722
918
  var StrokeControl = createControl(() => {
723
919
  const propContext = useBoundProp(strokePropTypeUtil);
724
- return /* @__PURE__ */ React17.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React17.createElement(SectionContent, null, /* @__PURE__ */ React17.createElement(Control, { bind: "width", label: __3("Stroke width", "elementor") }, /* @__PURE__ */ React17.createElement(SizeControl, { units })), /* @__PURE__ */ React17.createElement(Control, { bind: "color", label: __3("Stroke color", "elementor") }, /* @__PURE__ */ React17.createElement(ColorControl, null))));
920
+ const rowRef = useRef2();
921
+ return /* @__PURE__ */ React19.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React19.createElement(SectionContent, null, /* @__PURE__ */ React19.createElement(Control, { bind: "width", label: __3("Stroke width", "elementor"), ref: rowRef }, /* @__PURE__ */ React19.createElement(SizeControl, { units, anchorRef: rowRef })), /* @__PURE__ */ React19.createElement(Control, { bind: "color", label: __3("Stroke color", "elementor") }, /* @__PURE__ */ React19.createElement(ColorControl, null))));
725
922
  });
726
- var Control = ({ bind, label, children }) => /* @__PURE__ */ React17.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React17.createElement(Grid2, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React17.createElement(Grid2, { item: true, xs: 6 }, /* @__PURE__ */ React17.createElement(ControlFormLabel, null, label)), /* @__PURE__ */ React17.createElement(Grid2, { item: true, xs: 6 }, children)));
923
+ var Control = forwardRef2(({ bind, label, children }, ref) => /* @__PURE__ */ React19.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React19.createElement(Grid2, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref }, /* @__PURE__ */ React19.createElement(Grid2, { item: true, xs: 6 }, /* @__PURE__ */ React19.createElement(ControlFormLabel, null, label)), /* @__PURE__ */ React19.createElement(Grid2, { item: true, xs: 6 }, children))));
727
924
 
728
925
  // src/controls/box-shadow-repeater-control.tsx
729
- import * as React24 from "react";
926
+ import * as React26 from "react";
927
+ import { useRef as useRef3 } from "react";
730
928
  import { boxShadowPropTypeUtil, shadowPropTypeUtil } from "@elementor/editor-props";
731
929
  import { FormLabel as FormLabel2, Grid as Grid4, UnstableColorIndicator } from "@elementor/ui";
732
930
  import { __ as __5 } from "@wordpress/i18n";
733
931
 
734
932
  // src/components/popover-content.tsx
735
- import * as React18 from "react";
933
+ import * as React20 from "react";
736
934
  import { Stack as Stack4 } from "@elementor/ui";
737
- var PopoverContent = ({ alignItems, gap = 1.5, p, pt, pb, children }) => /* @__PURE__ */ React18.createElement(Stack4, { alignItems, gap, p, pt, pb }, children);
935
+ var PopoverContent = ({ alignItems, gap = 1.5, p, pt, pb, children }) => /* @__PURE__ */ React20.createElement(Stack4, { alignItems, gap, p, pt, pb }, children);
738
936
 
739
937
  // src/components/popover-grid-container.tsx
740
- import * as React19 from "react";
938
+ import { forwardRef as forwardRef3 } from "react";
939
+ import * as React21 from "react";
741
940
  import { Grid as Grid3 } from "@elementor/ui";
742
- var PopoverGridContainer = ({
743
- gap = 1.5,
744
- alignItems = "center",
745
- flexWrap = "nowrap",
746
- children
747
- }) => /* @__PURE__ */ React19.createElement(Grid3, { container: true, gap, alignItems, flexWrap }, children);
941
+ var PopoverGridContainer = forwardRef3(
942
+ ({ gap = 1.5, alignItems = "center", flexWrap = "nowrap", children }, ref) => /* @__PURE__ */ React21.createElement(Grid3, { container: true, gap, alignItems, flexWrap, ref }, children)
943
+ );
748
944
 
749
945
  // src/components/repeater.tsx
750
- import * as React23 from "react";
751
- import { useEffect as useEffect2, useState as useState3 } from "react";
946
+ import * as React25 from "react";
947
+ import { useEffect as useEffect3, useState as useState4 } from "react";
752
948
  import { CopyIcon, EyeIcon, EyeOffIcon, PlusIcon, XIcon } from "@elementor/icons";
753
949
  import {
754
- bindPopover,
950
+ bindPopover as bindPopover2,
755
951
  bindTrigger as bindTrigger2,
756
952
  Box as Box2,
757
953
  IconButton,
758
- Popover,
954
+ Popover as Popover2,
759
955
  Stack as Stack5,
760
956
  Tooltip,
761
957
  Typography,
762
958
  UnstableTag,
763
- usePopupState as usePopupState2
959
+ usePopupState as usePopupState3
764
960
  } from "@elementor/ui";
765
961
  import { __ as __4 } from "@wordpress/i18n";
766
962
 
767
963
  // src/control-adornments/control-adornments.tsx
768
- import * as React21 from "react";
964
+ import * as React23 from "react";
769
965
 
770
966
  // src/control-adornments/control-adornments-context.tsx
771
- import * as React20 from "react";
967
+ import * as React22 from "react";
772
968
  import { createContext as createContext5, useContext as useContext5 } from "react";
773
969
  var Context2 = createContext5(null);
774
- var ControlAdornmentsProvider = ({ children, items }) => /* @__PURE__ */ React20.createElement(Context2.Provider, { value: { items } }, children);
970
+ var ControlAdornmentsProvider = ({ children, items }) => /* @__PURE__ */ React22.createElement(Context2.Provider, { value: { items } }, children);
775
971
  var useControlAdornments = () => {
776
972
  const context = useContext5(Context2);
777
973
  return context?.items ?? [];
@@ -783,7 +979,7 @@ function ControlAdornments() {
783
979
  if (items?.length === 0) {
784
980
  return null;
785
981
  }
786
- return /* @__PURE__ */ React21.createElement(React21.Fragment, null, items.map(({ Adornment, id }) => /* @__PURE__ */ React21.createElement(Adornment, { key: id })));
982
+ return /* @__PURE__ */ React23.createElement(React23.Fragment, null, items.map(({ Adornment, id }) => /* @__PURE__ */ React23.createElement(Adornment, { key: id })));
787
983
  }
788
984
 
789
985
  // src/locations.ts
@@ -792,7 +988,7 @@ var { Slot: RepeaterItemIconSlot, inject: injectIntoRepeaterItemIcon } = createR
792
988
  var { Slot: RepeaterItemLabelSlot, inject: injectIntoRepeaterItemLabel } = createReplaceableLocation();
793
989
 
794
990
  // src/components/sortable.tsx
795
- import * as React22 from "react";
991
+ import * as React24 from "react";
796
992
  import { GripVerticalIcon } from "@elementor/icons";
797
993
  import {
798
994
  Divider,
@@ -803,10 +999,10 @@ import {
803
999
  UnstableSortableProvider
804
1000
  } from "@elementor/ui";
805
1001
  var SortableProvider = (props) => {
806
- return /* @__PURE__ */ React22.createElement(List, { sx: { p: 0, my: -0.5, mx: 0 } }, /* @__PURE__ */ React22.createElement(UnstableSortableProvider, { restrictAxis: true, disableDragOverlay: false, variant: "static", ...props }));
1002
+ return /* @__PURE__ */ React24.createElement(List, { sx: { p: 0, my: -0.5, mx: 0 } }, /* @__PURE__ */ React24.createElement(UnstableSortableProvider, { restrictAxis: true, disableDragOverlay: false, variant: "static", ...props }));
807
1003
  };
808
1004
  var SortableItem = ({ id, children, disabled }) => {
809
- return /* @__PURE__ */ React22.createElement(
1005
+ return /* @__PURE__ */ React24.createElement(
810
1006
  UnstableSortableItem,
811
1007
  {
812
1008
  id,
@@ -819,7 +1015,7 @@ var SortableItem = ({ id, children, disabled }) => {
819
1015
  showDropIndication,
820
1016
  dropIndicationStyle
821
1017
  }) => {
822
- return /* @__PURE__ */ React22.createElement(StyledListItem, { ...itemProps, style: itemStyle }, !disabled && /* @__PURE__ */ React22.createElement(SortableTrigger, { ...triggerProps, style: triggerStyle }), children, showDropIndication && /* @__PURE__ */ React22.createElement(StyledDivider, { style: dropIndicationStyle }));
1018
+ return /* @__PURE__ */ React24.createElement(StyledListItem, { ...itemProps, style: itemStyle }, !disabled && /* @__PURE__ */ React24.createElement(SortableTrigger, { ...triggerProps, style: triggerStyle }), children, showDropIndication && /* @__PURE__ */ React24.createElement(StyledDivider, { style: dropIndicationStyle }));
823
1019
  }
824
1020
  }
825
1021
  );
@@ -853,7 +1049,7 @@ var StyledListItem = styled2(ListItem)`
853
1049
  }
854
1050
  }
855
1051
  `;
856
- var SortableTrigger = (props) => /* @__PURE__ */ React22.createElement("div", { ...props, role: "button", className: "class-item-sortable-trigger" }, /* @__PURE__ */ React22.createElement(GripVerticalIcon, { fontSize: "tiny" }));
1052
+ var SortableTrigger = (props) => /* @__PURE__ */ React24.createElement("div", { ...props, role: "button", className: "class-item-sortable-trigger" }, /* @__PURE__ */ React24.createElement(GripVerticalIcon, { fontSize: "tiny" }));
857
1053
  var StyledDivider = styled2(Divider)`
858
1054
  height: 0px;
859
1055
  border: none;
@@ -881,16 +1077,18 @@ var Repeater = ({
881
1077
  openOnAdd = false,
882
1078
  addToBottom = false,
883
1079
  values: repeaterValues = [],
884
- setValues: setRepeaterValues
1080
+ setValues: setRepeaterValues,
1081
+ showDuplicate = true,
1082
+ showToggle = true
885
1083
  }) => {
886
- const [openItem, setOpenItem] = useState3(EMPTY_OPEN_ITEM);
1084
+ const [openItem, setOpenItem] = useState4(EMPTY_OPEN_ITEM);
887
1085
  const [items, setItems] = useSyncExternalState({
888
1086
  external: repeaterValues,
889
1087
  // @ts-expect-error - as long as persistWhen => true, value will never be null
890
1088
  setExternal: setRepeaterValues,
891
1089
  persistWhen: () => true
892
1090
  });
893
- const [uniqueKeys, setUniqueKeys] = useState3(items.map((_, index) => index));
1091
+ const [uniqueKeys, setUniqueKeys] = useState4(items.map((_, index) => index));
894
1092
  const generateNextKey = (source) => {
895
1093
  return 1 + Math.max(0, ...source);
896
1094
  };
@@ -947,7 +1145,7 @@ var Repeater = ({
947
1145
  });
948
1146
  });
949
1147
  };
950
- return /* @__PURE__ */ React23.createElement(SectionContent, null, /* @__PURE__ */ React23.createElement(
1148
+ return /* @__PURE__ */ React25.createElement(SectionContent, null, /* @__PURE__ */ React25.createElement(
951
1149
  Stack5,
952
1150
  {
953
1151
  direction: "row",
@@ -956,9 +1154,9 @@ var Repeater = ({
956
1154
  gap: 1,
957
1155
  sx: { marginInlineEnd: -0.75 }
958
1156
  },
959
- /* @__PURE__ */ React23.createElement(Typography, { component: "label", variant: "caption", color: "text.secondary" }, label),
960
- /* @__PURE__ */ React23.createElement(ControlAdornments, null),
961
- /* @__PURE__ */ React23.createElement(
1157
+ /* @__PURE__ */ React25.createElement(Typography, { component: "label", variant: "caption", color: "text.secondary" }, label),
1158
+ /* @__PURE__ */ React25.createElement(ControlAdornments, null),
1159
+ /* @__PURE__ */ React25.createElement(
962
1160
  IconButton,
963
1161
  {
964
1162
  size: SIZE,
@@ -967,27 +1165,29 @@ var Repeater = ({
967
1165
  onClick: addRepeaterItem,
968
1166
  "aria-label": __4("Add item", "elementor")
969
1167
  },
970
- /* @__PURE__ */ React23.createElement(PlusIcon, { fontSize: SIZE })
1168
+ /* @__PURE__ */ React25.createElement(PlusIcon, { fontSize: SIZE })
971
1169
  )
972
- ), 0 < uniqueKeys.length && /* @__PURE__ */ React23.createElement(SortableProvider, { value: uniqueKeys, onChange: onChangeOrder }, uniqueKeys.map((key, index) => {
1170
+ ), 0 < uniqueKeys.length && /* @__PURE__ */ React25.createElement(SortableProvider, { value: uniqueKeys, onChange: onChangeOrder }, uniqueKeys.map((key, index) => {
973
1171
  const value = items[index];
974
1172
  if (!value) {
975
1173
  return null;
976
1174
  }
977
- return /* @__PURE__ */ React23.createElement(SortableItem, { id: key, key: `sortable-${key}`, disabled }, /* @__PURE__ */ React23.createElement(
1175
+ return /* @__PURE__ */ React25.createElement(SortableItem, { id: key, key: `sortable-${key}`, disabled }, /* @__PURE__ */ React25.createElement(
978
1176
  RepeaterItem,
979
1177
  {
980
1178
  disabled,
981
1179
  propDisabled: value?.disabled,
982
- label: /* @__PURE__ */ React23.createElement(RepeaterItemLabelSlot, { value }, /* @__PURE__ */ React23.createElement(itemSettings.Label, { value })),
983
- startIcon: /* @__PURE__ */ React23.createElement(RepeaterItemIconSlot, { value }, /* @__PURE__ */ React23.createElement(itemSettings.Icon, { value })),
1180
+ label: /* @__PURE__ */ React25.createElement(RepeaterItemLabelSlot, { value }, /* @__PURE__ */ React25.createElement(itemSettings.Label, { value })),
1181
+ startIcon: /* @__PURE__ */ React25.createElement(RepeaterItemIconSlot, { value }, /* @__PURE__ */ React25.createElement(itemSettings.Icon, { value })),
984
1182
  removeItem: () => removeRepeaterItem(index),
985
1183
  duplicateItem: () => duplicateRepeaterItem(index),
986
1184
  toggleDisableItem: () => toggleDisableRepeaterItem(index),
987
1185
  openOnMount: openOnAdd && openItem === key,
988
- onOpen: () => setOpenItem(EMPTY_OPEN_ITEM)
1186
+ onOpen: () => setOpenItem(EMPTY_OPEN_ITEM),
1187
+ showDuplicate,
1188
+ showToggle
989
1189
  },
990
- (props) => /* @__PURE__ */ React23.createElement(itemSettings.Content, { ...props, value, bind: String(index) })
1190
+ (props) => /* @__PURE__ */ React25.createElement(itemSettings.Content, { ...props, value, bind: String(index) })
991
1191
  ));
992
1192
  })));
993
1193
  };
@@ -1001,14 +1201,16 @@ var RepeaterItem = ({
1001
1201
  toggleDisableItem,
1002
1202
  openOnMount,
1003
1203
  onOpen,
1204
+ showDuplicate,
1205
+ showToggle,
1004
1206
  disabled
1005
1207
  }) => {
1006
- const [anchorEl, setAnchorEl] = useState3(null);
1208
+ const [anchorEl, setAnchorEl] = useState4(null);
1007
1209
  const { popoverState, popoverProps, ref, setRef } = usePopover(openOnMount, onOpen);
1008
1210
  const duplicateLabel = __4("Duplicate", "elementor");
1009
1211
  const toggleLabel = propDisabled ? __4("Show", "elementor") : __4("Hide", "elementor");
1010
1212
  const removeLabel = __4("Remove", "elementor");
1011
- return /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(
1213
+ return /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(
1012
1214
  UnstableTag,
1013
1215
  {
1014
1216
  disabled,
@@ -1020,10 +1222,10 @@ var RepeaterItem = ({
1020
1222
  "aria-label": __4("Open item", "elementor"),
1021
1223
  ...bindTrigger2(popoverState),
1022
1224
  startIcon,
1023
- actions: /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(Tooltip, { title: duplicateLabel, placement: "top" }, /* @__PURE__ */ React23.createElement(IconButton, { size: SIZE, onClick: duplicateItem, "aria-label": duplicateLabel }, /* @__PURE__ */ React23.createElement(CopyIcon, { fontSize: SIZE }))), /* @__PURE__ */ React23.createElement(Tooltip, { title: toggleLabel, placement: "top" }, /* @__PURE__ */ React23.createElement(IconButton, { size: SIZE, onClick: toggleDisableItem, "aria-label": toggleLabel }, propDisabled ? /* @__PURE__ */ React23.createElement(EyeOffIcon, { fontSize: SIZE }) : /* @__PURE__ */ React23.createElement(EyeIcon, { fontSize: SIZE }))), /* @__PURE__ */ React23.createElement(Tooltip, { title: removeLabel, placement: "top" }, /* @__PURE__ */ React23.createElement(IconButton, { size: SIZE, onClick: removeItem, "aria-label": removeLabel }, /* @__PURE__ */ React23.createElement(XIcon, { fontSize: SIZE }))))
1225
+ actions: /* @__PURE__ */ React25.createElement(React25.Fragment, null, showDuplicate && /* @__PURE__ */ React25.createElement(Tooltip, { title: duplicateLabel, placement: "top" }, /* @__PURE__ */ React25.createElement(IconButton, { size: SIZE, onClick: duplicateItem, "aria-label": duplicateLabel }, /* @__PURE__ */ React25.createElement(CopyIcon, { fontSize: SIZE }))), showToggle && /* @__PURE__ */ React25.createElement(Tooltip, { title: toggleLabel, placement: "top" }, /* @__PURE__ */ React25.createElement(IconButton, { size: SIZE, onClick: toggleDisableItem, "aria-label": toggleLabel }, propDisabled ? /* @__PURE__ */ React25.createElement(EyeOffIcon, { fontSize: SIZE }) : /* @__PURE__ */ React25.createElement(EyeIcon, { fontSize: SIZE }))), /* @__PURE__ */ React25.createElement(Tooltip, { title: removeLabel, placement: "top" }, /* @__PURE__ */ React25.createElement(IconButton, { size: SIZE, onClick: removeItem, "aria-label": removeLabel }, /* @__PURE__ */ React25.createElement(XIcon, { fontSize: SIZE }))))
1024
1226
  }
1025
- ), /* @__PURE__ */ React23.createElement(
1026
- Popover,
1227
+ ), /* @__PURE__ */ React25.createElement(
1228
+ Popover2,
1027
1229
  {
1028
1230
  disablePortal: true,
1029
1231
  slotProps: {
@@ -1036,14 +1238,14 @@ var RepeaterItem = ({
1036
1238
  ...popoverProps,
1037
1239
  anchorEl: ref
1038
1240
  },
1039
- /* @__PURE__ */ React23.createElement(Box2, null, children({ anchorEl }))
1241
+ /* @__PURE__ */ React25.createElement(Box2, null, children({ anchorEl }))
1040
1242
  ));
1041
1243
  };
1042
1244
  var usePopover = (openOnMount, onOpen) => {
1043
- const [ref, setRef] = useState3(null);
1044
- const popoverState = usePopupState2({ variant: "popover" });
1045
- const popoverProps = bindPopover(popoverState);
1046
- useEffect2(() => {
1245
+ const [ref, setRef] = useState4(null);
1246
+ const popoverState = usePopupState3({ variant: "popover" });
1247
+ const popoverProps = bindPopover2(popoverState);
1248
+ useEffect3(() => {
1047
1249
  if (openOnMount && ref) {
1048
1250
  popoverState.open(ref);
1049
1251
  onOpen?.();
@@ -1060,7 +1262,7 @@ var usePopover = (openOnMount, onOpen) => {
1060
1262
  // src/controls/box-shadow-repeater-control.tsx
1061
1263
  var BoxShadowRepeaterControl = createControl(() => {
1062
1264
  const { propType, value, setValue, disabled } = useBoundProp(boxShadowPropTypeUtil);
1063
- return /* @__PURE__ */ React24.createElement(PropProvider, { propType, value, setValue, disabled }, /* @__PURE__ */ React24.createElement(
1265
+ return /* @__PURE__ */ React26.createElement(PropProvider, { propType, value, setValue, disabled }, /* @__PURE__ */ React26.createElement(
1064
1266
  Repeater,
1065
1267
  {
1066
1268
  openOnAdd: true,
@@ -1077,13 +1279,14 @@ var BoxShadowRepeaterControl = createControl(() => {
1077
1279
  }
1078
1280
  ));
1079
1281
  });
1080
- var ItemIcon = ({ value }) => /* @__PURE__ */ React24.createElement(UnstableColorIndicator, { size: "inherit", component: "span", value: value.value.color?.value });
1282
+ var ItemIcon = ({ value }) => /* @__PURE__ */ React26.createElement(UnstableColorIndicator, { size: "inherit", component: "span", value: value.value.color?.value });
1081
1283
  var ItemContent = ({ anchorEl, bind }) => {
1082
- return /* @__PURE__ */ React24.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React24.createElement(Content, { anchorEl }));
1284
+ return /* @__PURE__ */ React26.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React26.createElement(Content, { anchorEl }));
1083
1285
  };
1084
1286
  var Content = ({ anchorEl }) => {
1085
1287
  const context = useBoundProp(shadowPropTypeUtil);
1086
- return /* @__PURE__ */ React24.createElement(PropProvider, { ...context }, /* @__PURE__ */ React24.createElement(PopoverContent, { p: 1.5 }, /* @__PURE__ */ React24.createElement(PopoverGridContainer, null, /* @__PURE__ */ React24.createElement(Control2, { bind: "color", label: __5("Color", "elementor") }, /* @__PURE__ */ React24.createElement(ColorControl, { anchorEl })), /* @__PURE__ */ React24.createElement(Control2, { bind: "position", label: __5("Position", "elementor"), sx: { overflow: "hidden" } }, /* @__PURE__ */ React24.createElement(
1288
+ const rowRef = [useRef3(), useRef3()];
1289
+ return /* @__PURE__ */ React26.createElement(PropProvider, { ...context }, /* @__PURE__ */ React26.createElement(PopoverContent, { p: 1.5 }, /* @__PURE__ */ React26.createElement(PopoverGridContainer, null, /* @__PURE__ */ React26.createElement(Control2, { bind: "color", label: __5("Color", "elementor") }, /* @__PURE__ */ React26.createElement(ColorControl, { anchorEl })), /* @__PURE__ */ React26.createElement(Control2, { bind: "position", label: __5("Position", "elementor"), sx: { overflow: "hidden" } }, /* @__PURE__ */ React26.createElement(
1087
1290
  SelectControl,
1088
1291
  {
1089
1292
  options: [
@@ -1091,14 +1294,14 @@ var Content = ({ anchorEl }) => {
1091
1294
  { label: __5("Outset", "elementor"), value: null }
1092
1295
  ]
1093
1296
  }
1094
- ))), /* @__PURE__ */ React24.createElement(PopoverGridContainer, null, /* @__PURE__ */ React24.createElement(Control2, { bind: "hOffset", label: __5("Horizontal", "elementor") }, /* @__PURE__ */ React24.createElement(SizeControl, null)), /* @__PURE__ */ React24.createElement(Control2, { bind: "vOffset", label: __5("Vertical", "elementor") }, /* @__PURE__ */ React24.createElement(SizeControl, null))), /* @__PURE__ */ React24.createElement(PopoverGridContainer, null, /* @__PURE__ */ React24.createElement(Control2, { bind: "blur", label: __5("Blur", "elementor") }, /* @__PURE__ */ React24.createElement(SizeControl, null)), /* @__PURE__ */ React24.createElement(Control2, { bind: "spread", label: __5("Spread", "elementor") }, /* @__PURE__ */ React24.createElement(SizeControl, null)))));
1297
+ ))), /* @__PURE__ */ React26.createElement(PopoverGridContainer, { ref: rowRef[0] }, /* @__PURE__ */ React26.createElement(Control2, { bind: "hOffset", label: __5("Horizontal", "elementor") }, /* @__PURE__ */ React26.createElement(SizeControl, { anchorRef: rowRef[0] })), /* @__PURE__ */ React26.createElement(Control2, { bind: "vOffset", label: __5("Vertical", "elementor") }, /* @__PURE__ */ React26.createElement(SizeControl, { anchorRef: rowRef[0] }))), /* @__PURE__ */ React26.createElement(PopoverGridContainer, { ref: rowRef[1] }, /* @__PURE__ */ React26.createElement(Control2, { bind: "blur", label: __5("Blur", "elementor") }, /* @__PURE__ */ React26.createElement(SizeControl, { anchorRef: rowRef[1] })), /* @__PURE__ */ React26.createElement(Control2, { bind: "spread", label: __5("Spread", "elementor") }, /* @__PURE__ */ React26.createElement(SizeControl, { anchorRef: rowRef[1] })))));
1095
1298
  };
1096
1299
  var Control2 = ({
1097
1300
  label,
1098
1301
  bind,
1099
1302
  children,
1100
1303
  sx
1101
- }) => /* @__PURE__ */ React24.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React24.createElement(Grid4, { item: true, xs: 6, sx }, /* @__PURE__ */ React24.createElement(Grid4, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React24.createElement(Grid4, { item: true, xs: 12 }, /* @__PURE__ */ React24.createElement(FormLabel2, { size: "tiny" }, label)), /* @__PURE__ */ React24.createElement(Grid4, { item: true, xs: 12 }, children))));
1304
+ }) => /* @__PURE__ */ React26.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React26.createElement(Grid4, { item: true, xs: 6, sx }, /* @__PURE__ */ React26.createElement(Grid4, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React26.createElement(Grid4, { item: true, xs: 12 }, /* @__PURE__ */ React26.createElement(FormLabel2, { size: "tiny" }, label)), /* @__PURE__ */ React26.createElement(Grid4, { item: true, xs: 12 }, children))));
1102
1305
  var ItemLabel = ({ value }) => {
1103
1306
  const { position, hOffset, vOffset, blur, spread } = value.value;
1104
1307
  const { size: blurSize = "", unit: blurUnit = "" } = blur?.value || {};
@@ -1112,7 +1315,7 @@ var ItemLabel = ({ value }) => {
1112
1315
  blurSize + blurUnit,
1113
1316
  spreadSize + spreadUnit
1114
1317
  ].join(" ");
1115
- return /* @__PURE__ */ React24.createElement("span", { style: { textTransform: "capitalize" } }, positionLabel, ": ", sizes);
1318
+ return /* @__PURE__ */ React26.createElement("span", { style: { textTransform: "capitalize" } }, positionLabel, ": ", sizes);
1116
1319
  };
1117
1320
  var initialShadow = {
1118
1321
  $$type: "shadow",
@@ -1142,12 +1345,12 @@ var initialShadow = {
1142
1345
  };
1143
1346
 
1144
1347
  // src/controls/toggle-control.tsx
1145
- import * as React27 from "react";
1146
- import { stringPropTypeUtil as stringPropTypeUtil5 } from "@elementor/editor-props";
1348
+ import * as React29 from "react";
1349
+ import { stringPropTypeUtil as stringPropTypeUtil4 } from "@elementor/editor-props";
1147
1350
 
1148
1351
  // src/components/control-toggle-button-group.tsx
1149
- import * as React26 from "react";
1150
- import { useEffect as useEffect3, useMemo, useRef as useRef2, useState as useState4 } from "react";
1352
+ import * as React28 from "react";
1353
+ import { useEffect as useEffect4, useMemo as useMemo2, useRef as useRef4, useState as useState5 } from "react";
1151
1354
  import { ChevronDownIcon } from "@elementor/icons";
1152
1355
  import {
1153
1356
  ListItemText,
@@ -1161,14 +1364,14 @@ import {
1161
1364
  } from "@elementor/ui";
1162
1365
 
1163
1366
  // src/components/conditional-tooltip.tsx
1164
- import * as React25 from "react";
1367
+ import * as React27 from "react";
1165
1368
  import { Tooltip as Tooltip2 } from "@elementor/ui";
1166
1369
  var ConditionalTooltip = ({
1167
1370
  showTooltip,
1168
1371
  children,
1169
1372
  label
1170
1373
  }) => {
1171
- return showTooltip && label ? /* @__PURE__ */ React25.createElement(Tooltip2, { title: label, disableFocusListener: true, placement: "top" }, children) : children;
1374
+ return showTooltip && label ? /* @__PURE__ */ React27.createElement(Tooltip2, { title: label, disableFocusListener: true, placement: "top" }, children) : children;
1172
1375
  };
1173
1376
 
1174
1377
  // src/components/control-toggle-button-group.tsx
@@ -1205,13 +1408,13 @@ var ControlToggleButtonGroup = ({
1205
1408
  const handleChange = (_, newValue) => {
1206
1409
  onChange(newValue);
1207
1410
  };
1208
- const getGridTemplateColumns = useMemo(() => {
1411
+ const getGridTemplateColumns = useMemo2(() => {
1209
1412
  const isOffLimits = menuItems?.length;
1210
1413
  const itemsCount = isOffLimits ? fixedItems.length + 1 : fixedItems.length;
1211
1414
  const templateColumnsSuffix = isOffLimits ? "auto" : "";
1212
1415
  return `repeat(${itemsCount}, minmax(0, 25%)) ${templateColumnsSuffix}`;
1213
1416
  }, [menuItems?.length, fixedItems.length]);
1214
- return /* @__PURE__ */ React26.createElement(ControlActions, null, /* @__PURE__ */ React26.createElement(
1417
+ return /* @__PURE__ */ React28.createElement(ControlActions, null, /* @__PURE__ */ React28.createElement(
1215
1418
  StyledToggleButtonGroup,
1216
1419
  {
1217
1420
  justify,
@@ -1226,16 +1429,16 @@ var ControlToggleButtonGroup = ({
1226
1429
  width: `100%`
1227
1430
  }
1228
1431
  },
1229
- fixedItems.map(({ label, value: buttonValue, renderContent: Content3, showTooltip }) => /* @__PURE__ */ React26.createElement(
1432
+ fixedItems.map(({ label, value: buttonValue, renderContent: Content4, showTooltip }) => /* @__PURE__ */ React28.createElement(
1230
1433
  ConditionalTooltip,
1231
1434
  {
1232
1435
  key: buttonValue,
1233
1436
  label,
1234
1437
  showTooltip: showTooltip || false
1235
1438
  },
1236
- /* @__PURE__ */ React26.createElement(ToggleButton, { value: buttonValue, "aria-label": label, size, fullWidth }, /* @__PURE__ */ React26.createElement(Content3, { size }))
1439
+ /* @__PURE__ */ React28.createElement(ToggleButton, { value: buttonValue, "aria-label": label, size, fullWidth }, /* @__PURE__ */ React28.createElement(Content4, { size }))
1237
1440
  )),
1238
- menuItems.length && exclusive && /* @__PURE__ */ React26.createElement(
1441
+ menuItems.length && exclusive && /* @__PURE__ */ React28.createElement(
1239
1442
  SplitButtonGroup,
1240
1443
  {
1241
1444
  size,
@@ -1255,8 +1458,8 @@ var SplitButtonGroup = ({
1255
1458
  value
1256
1459
  }) => {
1257
1460
  const previewButton = usePreviewButton(items, value);
1258
- const [isMenuOpen, setIsMenuOpen] = useState4(false);
1259
- const menuButtonRef = useRef2(null);
1461
+ const [isMenuOpen, setIsMenuOpen] = useState5(false);
1462
+ const menuButtonRef = useRef4(null);
1260
1463
  const onMenuToggle = (ev) => {
1261
1464
  setIsMenuOpen((prev) => !prev);
1262
1465
  ev.preventDefault();
@@ -1269,7 +1472,7 @@ var SplitButtonGroup = ({
1269
1472
  const shouldRemove = newValue === value;
1270
1473
  onChange(shouldRemove ? null : newValue);
1271
1474
  };
1272
- return /* @__PURE__ */ React26.createElement(React26.Fragment, null, /* @__PURE__ */ React26.createElement(
1475
+ return /* @__PURE__ */ React28.createElement(React28.Fragment, null, /* @__PURE__ */ React28.createElement(
1273
1476
  ToggleButton,
1274
1477
  {
1275
1478
  value: previewButton.value,
@@ -1283,7 +1486,7 @@ var SplitButtonGroup = ({
1283
1486
  ref: menuButtonRef
1284
1487
  },
1285
1488
  previewButton.renderContent({ size })
1286
- ), /* @__PURE__ */ React26.createElement(
1489
+ ), /* @__PURE__ */ React28.createElement(
1287
1490
  ToggleButton,
1288
1491
  {
1289
1492
  size,
@@ -1294,8 +1497,8 @@ var SplitButtonGroup = ({
1294
1497
  ref: menuButtonRef,
1295
1498
  value: "__chevron-icon-button__"
1296
1499
  },
1297
- /* @__PURE__ */ React26.createElement(ChevronDownIcon, { fontSize: size })
1298
- ), /* @__PURE__ */ React26.createElement(
1500
+ /* @__PURE__ */ React28.createElement(ChevronDownIcon, { fontSize: size })
1501
+ ), /* @__PURE__ */ React28.createElement(
1299
1502
  Menu2,
1300
1503
  {
1301
1504
  open: isMenuOpen,
@@ -1313,22 +1516,22 @@ var SplitButtonGroup = ({
1313
1516
  mt: 0.5
1314
1517
  }
1315
1518
  },
1316
- items.map(({ label, value: buttonValue }) => /* @__PURE__ */ React26.createElement(
1519
+ items.map(({ label, value: buttonValue }) => /* @__PURE__ */ React28.createElement(
1317
1520
  MenuItem,
1318
1521
  {
1319
1522
  key: buttonValue,
1320
1523
  selected: buttonValue === value,
1321
1524
  onClick: () => onMenuItemClick(buttonValue)
1322
1525
  },
1323
- /* @__PURE__ */ React26.createElement(ListItemText, null, /* @__PURE__ */ React26.createElement(Typography2, { sx: { fontSize: "14px" } }, label))
1526
+ /* @__PURE__ */ React28.createElement(ListItemText, null, /* @__PURE__ */ React28.createElement(Typography2, { sx: { fontSize: "14px" } }, label))
1324
1527
  ))
1325
1528
  ));
1326
1529
  };
1327
1530
  var usePreviewButton = (items, value) => {
1328
- const [previewButton, setPreviewButton] = useState4(
1531
+ const [previewButton, setPreviewButton] = useState5(
1329
1532
  items.find((item) => item.value === value) ?? items[0]
1330
1533
  );
1331
- useEffect3(() => {
1534
+ useEffect4(() => {
1332
1535
  const selectedButton = items.find((item) => item.value === value);
1333
1536
  if (selectedButton) {
1334
1537
  setPreviewButton(selectedButton);
@@ -1346,7 +1549,7 @@ var ToggleControl = createControl(
1346
1549
  exclusive = true,
1347
1550
  maxItems
1348
1551
  }) => {
1349
- const { value, setValue, placeholder, disabled } = useBoundProp(stringPropTypeUtil5);
1552
+ const { value, setValue, placeholder, disabled } = useBoundProp(stringPropTypeUtil4);
1350
1553
  const exclusiveValues = options.filter((option) => option.exclusive).map((option) => option.value);
1351
1554
  const handleNonExclusiveToggle = (selectedValues) => {
1352
1555
  const newSelectedValue = selectedValues[selectedValues.length - 1];
@@ -1360,7 +1563,7 @@ var ToggleControl = createControl(
1360
1563
  fullWidth,
1361
1564
  size
1362
1565
  };
1363
- return exclusive ? /* @__PURE__ */ React27.createElement(
1566
+ return exclusive ? /* @__PURE__ */ React29.createElement(
1364
1567
  ControlToggleButtonGroup,
1365
1568
  {
1366
1569
  ...toggleButtonGroupProps,
@@ -1369,7 +1572,7 @@ var ToggleControl = createControl(
1369
1572
  disabled,
1370
1573
  exclusive: true
1371
1574
  }
1372
- ) : /* @__PURE__ */ React27.createElement(
1575
+ ) : /* @__PURE__ */ React29.createElement(
1373
1576
  ControlToggleButtonGroup,
1374
1577
  {
1375
1578
  ...toggleButtonGroupProps,
@@ -1383,9 +1586,9 @@ var ToggleControl = createControl(
1383
1586
  );
1384
1587
 
1385
1588
  // src/controls/number-control.tsx
1386
- import * as React28 from "react";
1589
+ import * as React30 from "react";
1387
1590
  import { numberPropTypeUtil } from "@elementor/editor-props";
1388
- import { TextField as TextField4 } from "@elementor/ui";
1591
+ import { TextField as TextField5 } from "@elementor/ui";
1389
1592
  var isEmptyOrNaN = (value) => value === null || value === void 0 || value === "" || Number.isNaN(Number(value));
1390
1593
  var RESTRICTED_INPUT_KEYS2 = ["e", "E", "+", "-"];
1391
1594
  var NumberControl = createControl(
@@ -1406,8 +1609,8 @@ var NumberControl = createControl(
1406
1609
  const formattedValue = shouldForceInt ? +parseInt(eventValue) : Number(eventValue);
1407
1610
  setValue(Math.min(Math.max(formattedValue, min), max));
1408
1611
  };
1409
- return /* @__PURE__ */ React28.createElement(ControlActions, null, /* @__PURE__ */ React28.createElement(
1410
- TextField4,
1612
+ return /* @__PURE__ */ React30.createElement(ControlActions, null, /* @__PURE__ */ React30.createElement(
1613
+ TextField5,
1411
1614
  {
1412
1615
  size: "tiny",
1413
1616
  type: "number",
@@ -1428,18 +1631,18 @@ var NumberControl = createControl(
1428
1631
  );
1429
1632
 
1430
1633
  // src/controls/equal-unequal-sizes-control.tsx
1431
- import * as React30 from "react";
1432
- import { useId as useId2, useRef as useRef3 } from "react";
1634
+ import * as React32 from "react";
1635
+ import { useId as useId2, useRef as useRef5 } from "react";
1433
1636
  import { sizePropTypeUtil as sizePropTypeUtil2 } from "@elementor/editor-props";
1434
- import { isExperimentActive } from "@elementor/editor-v1-adapters";
1435
- import { bindPopover as bindPopover2, bindToggle, Grid as Grid5, Popover as Popover2, Stack as Stack7, ToggleButton as ToggleButton2, Tooltip as Tooltip3, usePopupState as usePopupState3 } from "@elementor/ui";
1637
+ import { isExperimentActive as isExperimentActive2 } from "@elementor/editor-v1-adapters";
1638
+ import { bindPopover as bindPopover3, bindToggle, Grid as Grid5, Popover as Popover3, Stack as Stack7, ToggleButton as ToggleButton2, Tooltip as Tooltip3, usePopupState as usePopupState4 } from "@elementor/ui";
1436
1639
  import { __ as __6 } from "@wordpress/i18n";
1437
1640
 
1438
1641
  // src/components/control-label.tsx
1439
- import * as React29 from "react";
1642
+ import * as React31 from "react";
1440
1643
  import { Stack as Stack6 } from "@elementor/ui";
1441
1644
  var ControlLabel = ({ children }) => {
1442
- return /* @__PURE__ */ React29.createElement(Stack6, { direction: "row", alignItems: "center", justifyItems: "start", gap: 0.25 }, /* @__PURE__ */ React29.createElement(ControlFormLabel, null, children), /* @__PURE__ */ React29.createElement(ControlAdornments, null));
1645
+ return /* @__PURE__ */ React31.createElement(Stack6, { direction: "row", alignItems: "center", justifyItems: "start", gap: 0.25 }, /* @__PURE__ */ React31.createElement(ControlFormLabel, null, children), /* @__PURE__ */ React31.createElement(ControlAdornments, null));
1443
1646
  };
1444
1647
 
1445
1648
  // src/controls/equal-unequal-sizes-control.tsx
@@ -1461,8 +1664,7 @@ function EqualUnequalSizesControl({
1461
1664
  multiSizePropTypeUtil
1462
1665
  }) {
1463
1666
  const popupId = useId2();
1464
- const controlRef = useRef3(null);
1465
- const popupState = usePopupState3({ variant: "popover", popupId });
1667
+ const popupState = usePopupState4({ variant: "popover", popupId });
1466
1668
  const {
1467
1669
  propType: multiSizePropType,
1468
1670
  value: multiSizeValue,
@@ -1470,6 +1672,7 @@ function EqualUnequalSizesControl({
1470
1672
  disabled: multiSizeDisabled
1471
1673
  } = useBoundProp(multiSizePropTypeUtil);
1472
1674
  const { value: sizeValue, setValue: setSizeValue } = useBoundProp(sizePropTypeUtil2);
1675
+ const rowRefs = [useRef5(), useRef5()];
1473
1676
  const splitEqualValue = () => {
1474
1677
  if (!sizeValue) {
1475
1678
  return null;
@@ -1496,9 +1699,15 @@ function EqualUnequalSizesControl({
1496
1699
  }
1497
1700
  return splitEqualValue() ?? null;
1498
1701
  };
1499
- const isShowingGeneralIndicator = !isExperimentActive("e_v_3_30") || !popupState.isOpen;
1702
+ const isShowingGeneralIndicator = !isExperimentActive2("e_v_3_30") || !popupState.isOpen;
1500
1703
  const isMixed = !!multiSizeValue;
1501
- return /* @__PURE__ */ React30.createElement(React30.Fragment, null, /* @__PURE__ */ React30.createElement(Grid5, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref: controlRef }, /* @__PURE__ */ React30.createElement(Grid5, { item: true, xs: 6 }, !isShowingGeneralIndicator ? /* @__PURE__ */ React30.createElement(ControlFormLabel, null, label) : /* @__PURE__ */ React30.createElement(ControlLabel, null, label)), /* @__PURE__ */ React30.createElement(Grid5, { item: true, xs: 6 }, /* @__PURE__ */ React30.createElement(Stack7, { direction: "row", alignItems: "center", gap: 1 }, /* @__PURE__ */ React30.createElement(SizeControl, { placeholder: isMixed ? __6("Mixed", "elementor") : void 0 }), /* @__PURE__ */ React30.createElement(Tooltip3, { title: tooltipLabel, placement: "top" }, /* @__PURE__ */ React30.createElement(
1704
+ return /* @__PURE__ */ React32.createElement(React32.Fragment, null, /* @__PURE__ */ React32.createElement(Grid5, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap", ref: rowRefs[0] }, /* @__PURE__ */ React32.createElement(Grid5, { item: true, xs: 6 }, !isShowingGeneralIndicator ? /* @__PURE__ */ React32.createElement(ControlFormLabel, null, label) : /* @__PURE__ */ React32.createElement(ControlLabel, null, label)), /* @__PURE__ */ React32.createElement(Grid5, { item: true, xs: 6 }, /* @__PURE__ */ React32.createElement(Stack7, { direction: "row", alignItems: "center", gap: 1 }, /* @__PURE__ */ React32.createElement(
1705
+ SizeControl,
1706
+ {
1707
+ placeholder: isMixed ? __6("Mixed", "elementor") : void 0,
1708
+ anchorRef: rowRefs[0]
1709
+ }
1710
+ ), /* @__PURE__ */ React32.createElement(Tooltip3, { title: tooltipLabel, placement: "top" }, /* @__PURE__ */ React32.createElement(
1502
1711
  ToggleButton2,
1503
1712
  {
1504
1713
  size: "tiny",
@@ -1509,8 +1718,8 @@ function EqualUnequalSizesControl({
1509
1718
  "aria-label": tooltipLabel
1510
1719
  },
1511
1720
  icon
1512
- ))))), /* @__PURE__ */ React30.createElement(
1513
- Popover2,
1721
+ ))))), /* @__PURE__ */ React32.createElement(
1722
+ Popover3,
1514
1723
  {
1515
1724
  disablePortal: true,
1516
1725
  disableScrollLock: true,
@@ -1522,12 +1731,12 @@ function EqualUnequalSizesControl({
1522
1731
  vertical: "top",
1523
1732
  horizontal: "right"
1524
1733
  },
1525
- ...bindPopover2(popupState),
1734
+ ...bindPopover3(popupState),
1526
1735
  slotProps: {
1527
- paper: { sx: { mt: 0.5, width: controlRef.current?.getBoundingClientRect().width } }
1736
+ paper: { sx: { mt: 0.5, width: rowRefs[0].current?.getBoundingClientRect().width } }
1528
1737
  }
1529
1738
  },
1530
- /* @__PURE__ */ React30.createElement(
1739
+ /* @__PURE__ */ React32.createElement(
1531
1740
  PropProvider,
1532
1741
  {
1533
1742
  propType: multiSizePropType,
@@ -1535,19 +1744,23 @@ function EqualUnequalSizesControl({
1535
1744
  setValue: setNestedProp,
1536
1745
  disabled: multiSizeDisabled
1537
1746
  },
1538
- /* @__PURE__ */ React30.createElement(PopoverContent, { p: 1.5, pt: 2.5, pb: 3 }, /* @__PURE__ */ React30.createElement(PopoverGridContainer, null, /* @__PURE__ */ React30.createElement(MultiSizeValueControl, { item: items[0] }), /* @__PURE__ */ React30.createElement(MultiSizeValueControl, { item: items[1] })), /* @__PURE__ */ React30.createElement(PopoverGridContainer, null, /* @__PURE__ */ React30.createElement(MultiSizeValueControl, { item: items[2] }), /* @__PURE__ */ React30.createElement(MultiSizeValueControl, { item: items[3] })))
1747
+ /* @__PURE__ */ React32.createElement(PopoverContent, { p: 1.5 }, /* @__PURE__ */ React32.createElement(PopoverGridContainer, { ref: rowRefs[1] }, /* @__PURE__ */ React32.createElement(MultiSizeValueControl, { item: items[0], rowRef: rowRefs[1] }), /* @__PURE__ */ React32.createElement(MultiSizeValueControl, { item: items[1], rowRef: rowRefs[1] })), /* @__PURE__ */ React32.createElement(PopoverGridContainer, { ref: rowRefs[2] }, /* @__PURE__ */ React32.createElement(MultiSizeValueControl, { item: items[2], rowRef: rowRefs[2] }), /* @__PURE__ */ React32.createElement(MultiSizeValueControl, { item: items[3], rowRef: rowRefs[2] })))
1539
1748
  )
1540
1749
  ));
1541
1750
  }
1542
- var MultiSizeValueControl = ({ item }) => {
1543
- const isUsingNestedProps = isExperimentActive("e_v_3_30");
1544
- return /* @__PURE__ */ React30.createElement(PropKeyProvider, { bind: item.bind }, /* @__PURE__ */ React30.createElement(Grid5, { item: true, xs: 6 }, /* @__PURE__ */ React30.createElement(Grid5, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React30.createElement(Grid5, { item: true, xs: 12 }, isUsingNestedProps ? /* @__PURE__ */ React30.createElement(ControlLabel, null, item.label) : /* @__PURE__ */ React30.createElement(ControlFormLabel, null, item.label)), /* @__PURE__ */ React30.createElement(Grid5, { item: true, xs: 12 }, /* @__PURE__ */ React30.createElement(SizeControl, { startIcon: item.icon })))));
1751
+ var MultiSizeValueControl = ({
1752
+ item,
1753
+ rowRef
1754
+ }) => {
1755
+ const isUsingNestedProps = isExperimentActive2("e_v_3_30");
1756
+ return /* @__PURE__ */ React32.createElement(PropKeyProvider, { bind: item.bind }, /* @__PURE__ */ React32.createElement(Grid5, { item: true, xs: 6 }, /* @__PURE__ */ React32.createElement(Grid5, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React32.createElement(Grid5, { item: true, xs: 12 }, isUsingNestedProps ? /* @__PURE__ */ React32.createElement(ControlLabel, null, item.label) : /* @__PURE__ */ React32.createElement(ControlFormLabel, null, item.label)), /* @__PURE__ */ React32.createElement(Grid5, { item: true, xs: 12 }, /* @__PURE__ */ React32.createElement(SizeControl, { startIcon: item.icon, anchorRef: rowRef })))));
1545
1757
  };
1546
1758
 
1547
1759
  // src/controls/linked-dimensions-control.tsx
1548
- import * as React31 from "react";
1760
+ import * as React33 from "react";
1761
+ import { useRef as useRef6 } from "react";
1549
1762
  import { dimensionsPropTypeUtil, sizePropTypeUtil as sizePropTypeUtil3 } from "@elementor/editor-props";
1550
- import { isExperimentActive as isExperimentActive2 } from "@elementor/editor-v1-adapters";
1763
+ import { isExperimentActive as isExperimentActive3 } from "@elementor/editor-v1-adapters";
1551
1764
  import { DetachIcon, LinkIcon, SideBottomIcon, SideLeftIcon, SideRightIcon, SideTopIcon } from "@elementor/icons";
1552
1765
  import { Grid as Grid6, Stack as Stack8, ToggleButton as ToggleButton3, Tooltip as Tooltip4 } from "@elementor/ui";
1553
1766
  import { __ as __7 } from "@wordpress/i18n";
@@ -1555,9 +1768,10 @@ var LinkedDimensionsControl = createControl(
1555
1768
  ({
1556
1769
  label,
1557
1770
  isSiteRtl = false,
1558
- extendedValues
1771
+ extendedOptions
1559
1772
  }) => {
1560
1773
  const { value: sizeValue, setValue: setSizeValue, disabled: sizeDisabled } = useBoundProp(sizePropTypeUtil3);
1774
+ const gridRowRefs = [useRef6(), useRef6()];
1561
1775
  const {
1562
1776
  value: dimensionsValue,
1563
1777
  setValue: setDimensionsValue,
@@ -1565,7 +1779,7 @@ var LinkedDimensionsControl = createControl(
1565
1779
  disabled: dimensionsDisabled
1566
1780
  } = useBoundProp(dimensionsPropTypeUtil);
1567
1781
  const isLinked = !dimensionsValue && !sizeValue ? true : !!sizeValue;
1568
- const isUsingNestedProps = isExperimentActive2("e_v_3_30");
1782
+ const isUsingNestedProps = isExperimentActive3("e_v_3_30");
1569
1783
  const onLinkToggle = () => {
1570
1784
  if (!isLinked) {
1571
1785
  setSizeValue(dimensionsValue["block-start"]?.value ?? null);
@@ -1584,7 +1798,7 @@ var LinkedDimensionsControl = createControl(
1584
1798
  const linkedLabel = __7("Link %s", "elementor").replace("%s", tooltipLabel);
1585
1799
  const unlinkedLabel = __7("Unlink %s", "elementor").replace("%s", tooltipLabel);
1586
1800
  const disabled = sizeDisabled || dimensionsDisabled;
1587
- return /* @__PURE__ */ React31.createElement(
1801
+ return /* @__PURE__ */ React33.createElement(
1588
1802
  PropProvider,
1589
1803
  {
1590
1804
  propType,
@@ -1592,7 +1806,7 @@ var LinkedDimensionsControl = createControl(
1592
1806
  setValue: setDimensionsValue,
1593
1807
  disabled
1594
1808
  },
1595
- /* @__PURE__ */ React31.createElement(Stack8, { direction: "row", gap: 2, flexWrap: "nowrap" }, isUsingNestedProps ? /* @__PURE__ */ React31.createElement(ControlFormLabel, null, label) : /* @__PURE__ */ React31.createElement(ControlLabel, null, label), /* @__PURE__ */ React31.createElement(Tooltip4, { title: isLinked ? unlinkedLabel : linkedLabel, placement: "top" }, /* @__PURE__ */ React31.createElement(
1809
+ /* @__PURE__ */ React33.createElement(Stack8, { direction: "row", gap: 2, flexWrap: "nowrap" }, isUsingNestedProps ? /* @__PURE__ */ React33.createElement(ControlFormLabel, null, label) : /* @__PURE__ */ React33.createElement(ControlLabel, null, label), /* @__PURE__ */ React33.createElement(Tooltip4, { title: isLinked ? unlinkedLabel : linkedLabel, placement: "top" }, /* @__PURE__ */ React33.createElement(
1596
1810
  ToggleButton3,
1597
1811
  {
1598
1812
  "aria-label": isLinked ? unlinkedLabel : linkedLabel,
@@ -1603,54 +1817,18 @@ var LinkedDimensionsControl = createControl(
1603
1817
  onChange: onLinkToggle,
1604
1818
  disabled
1605
1819
  },
1606
- /* @__PURE__ */ React31.createElement(LinkedIcon, { fontSize: "tiny" })
1820
+ /* @__PURE__ */ React33.createElement(LinkedIcon, { fontSize: "tiny" })
1607
1821
  ))),
1608
- /* @__PURE__ */ React31.createElement(Stack8, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React31.createElement(Grid6, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(Label, { bind: "block-start", label: __7("Top", "elementor") })), /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1609
- Control3,
1610
- {
1611
- bind: "block-start",
1612
- startIcon: /* @__PURE__ */ React31.createElement(SideTopIcon, { fontSize: "tiny" }),
1613
- isLinked,
1614
- extendedValues
1615
- }
1616
- ))), /* @__PURE__ */ React31.createElement(Grid6, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1617
- Label,
1618
- {
1619
- bind: "inline-end",
1620
- label: isSiteRtl ? __7("Left", "elementor") : __7("Right", "elementor")
1621
- }
1622
- )), /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1623
- Control3,
1624
- {
1625
- bind: "inline-end",
1626
- startIcon: isSiteRtl ? /* @__PURE__ */ React31.createElement(SideLeftIcon, { fontSize: "tiny" }) : /* @__PURE__ */ React31.createElement(SideRightIcon, { fontSize: "tiny" }),
1627
- isLinked,
1628
- extendedValues
1629
- }
1630
- )))),
1631
- /* @__PURE__ */ React31.createElement(Stack8, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React31.createElement(Grid6, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(Label, { bind: "block-end", label: __7("Bottom", "elementor") })), /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1632
- Control3,
1633
- {
1634
- bind: "block-end",
1635
- startIcon: /* @__PURE__ */ React31.createElement(SideBottomIcon, { fontSize: "tiny" }),
1636
- isLinked,
1637
- extendedValues
1638
- }
1639
- ))), /* @__PURE__ */ React31.createElement(Grid6, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1640
- Label,
1641
- {
1642
- bind: "inline-start",
1643
- label: isSiteRtl ? __7("Right", "elementor") : __7("Left", "elementor")
1644
- }
1645
- )), /* @__PURE__ */ React31.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React31.createElement(
1822
+ getCssMarginProps(isSiteRtl).map((row, index) => /* @__PURE__ */ React33.createElement(Stack8, { direction: "row", gap: 2, flexWrap: "nowrap", key: index, ref: gridRowRefs[index] }, row.map(({ icon, ...props }) => /* @__PURE__ */ React33.createElement(Grid6, { container: true, gap: 0.75, alignItems: "center", key: props.bind }, /* @__PURE__ */ React33.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React33.createElement(Label, { ...props })), /* @__PURE__ */ React33.createElement(Grid6, { item: true, xs: 12 }, /* @__PURE__ */ React33.createElement(
1646
1823
  Control3,
1647
1824
  {
1648
- bind: "inline-start",
1825
+ bind: props.bind,
1826
+ startIcon: icon,
1649
1827
  isLinked,
1650
- extendedValues,
1651
- startIcon: isSiteRtl ? /* @__PURE__ */ React31.createElement(SideRightIcon, { fontSize: "tiny" }) : /* @__PURE__ */ React31.createElement(SideLeftIcon, { fontSize: "tiny" })
1828
+ extendedOptions,
1829
+ anchorRef: gridRowRefs[index]
1652
1830
  }
1653
- ))))
1831
+ ))))))
1654
1832
  );
1655
1833
  }
1656
1834
  );
@@ -1658,46 +1836,63 @@ var Control3 = ({
1658
1836
  bind,
1659
1837
  startIcon,
1660
1838
  isLinked,
1661
- extendedValues
1839
+ extendedOptions,
1840
+ anchorRef
1662
1841
  }) => {
1663
1842
  if (isLinked) {
1664
- return /* @__PURE__ */ React31.createElement(SizeControl, { startIcon, extendedValues });
1843
+ return /* @__PURE__ */ React33.createElement(SizeControl, { startIcon, extendedOptions, anchorRef });
1665
1844
  }
1666
- return /* @__PURE__ */ React31.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React31.createElement(SizeControl, { startIcon, extendedValues }));
1845
+ return /* @__PURE__ */ React33.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React33.createElement(SizeControl, { startIcon, extendedOptions, anchorRef }));
1667
1846
  };
1668
1847
  var Label = ({ label, bind }) => {
1669
- const isUsingNestedProps = isExperimentActive2("e_v_3_30");
1848
+ const isUsingNestedProps = isExperimentActive3("e_v_3_30");
1670
1849
  if (!isUsingNestedProps) {
1671
- return /* @__PURE__ */ React31.createElement(ControlFormLabel, null, label);
1850
+ return /* @__PURE__ */ React33.createElement(ControlFormLabel, null, label);
1672
1851
  }
1673
- return /* @__PURE__ */ React31.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React31.createElement(ControlLabel, null, label));
1852
+ return /* @__PURE__ */ React33.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React33.createElement(ControlLabel, null, label));
1674
1853
  };
1854
+ function getCssMarginProps(isSiteRtl) {
1855
+ return [
1856
+ [
1857
+ {
1858
+ bind: "block-start",
1859
+ label: __7("Top", "elementor"),
1860
+ icon: /* @__PURE__ */ React33.createElement(SideTopIcon, { fontSize: "tiny" })
1861
+ },
1862
+ {
1863
+ bind: "inline-end",
1864
+ label: isSiteRtl ? __7("Left", "elementor") : __7("Right", "elementor"),
1865
+ icon: isSiteRtl ? /* @__PURE__ */ React33.createElement(SideLeftIcon, { fontSize: "tiny" }) : /* @__PURE__ */ React33.createElement(SideRightIcon, { fontSize: "tiny" })
1866
+ }
1867
+ ],
1868
+ [
1869
+ {
1870
+ bind: "block-end",
1871
+ label: __7("Bottom", "elementor"),
1872
+ icon: /* @__PURE__ */ React33.createElement(SideBottomIcon, { fontSize: "tiny" })
1873
+ },
1874
+ {
1875
+ bind: "inline-start",
1876
+ label: isSiteRtl ? __7("Right", "elementor") : __7("Left", "elementor"),
1877
+ icon: isSiteRtl ? /* @__PURE__ */ React33.createElement(SideRightIcon, { fontSize: "tiny" }) : /* @__PURE__ */ React33.createElement(SideLeftIcon, { fontSize: "tiny" })
1878
+ }
1879
+ ]
1880
+ ];
1881
+ }
1675
1882
 
1676
1883
  // src/controls/font-family-control/font-family-control.tsx
1677
- import * as React33 from "react";
1678
- import { stringPropTypeUtil as stringPropTypeUtil6 } from "@elementor/editor-props";
1884
+ import * as React35 from "react";
1885
+ import { stringPropTypeUtil as stringPropTypeUtil5 } from "@elementor/editor-props";
1679
1886
  import { ChevronDownIcon as ChevronDownIcon2 } from "@elementor/icons";
1680
- import { bindPopover as bindPopover3, bindTrigger as bindTrigger3, Popover as Popover3, UnstableTag as UnstableTag2, usePopupState as usePopupState4 } from "@elementor/ui";
1887
+ import { bindPopover as bindPopover4, bindTrigger as bindTrigger3, Popover as Popover4, UnstableTag as UnstableTag2, usePopupState as usePopupState5 } from "@elementor/ui";
1681
1888
 
1682
1889
  // src/components/font-family-selector.tsx
1683
- import { useEffect as useEffect4, useRef as useRef4, useState as useState5 } from "react";
1684
- import * as React32 from "react";
1685
- import { PopoverHeader } from "@elementor/editor-ui";
1686
- import { SearchIcon, TextIcon } from "@elementor/icons";
1687
- import {
1688
- Box as Box3,
1689
- Divider as Divider2,
1690
- InputAdornment as InputAdornment3,
1691
- Link,
1692
- MenuList,
1693
- MenuSubheader,
1694
- Stack as Stack9,
1695
- styled as styled4,
1696
- TextField as TextField5,
1697
- Typography as Typography3
1698
- } from "@elementor/ui";
1890
+ import * as React34 from "react";
1891
+ import { useEffect as useEffect5, useState as useState6 } from "react";
1892
+ import { PopoverHeader, PopoverMenuList, PopoverScrollableContent, PopoverSearch } from "@elementor/editor-ui";
1893
+ import { TextIcon } from "@elementor/icons";
1894
+ import { Box as Box3, Divider as Divider2, Link, Stack as Stack9, Typography as Typography3 } from "@elementor/ui";
1699
1895
  import { debounce } from "@elementor/utils";
1700
- import { useVirtualizer } from "@tanstack/react-virtual";
1701
1896
  import { __ as __8 } from "@wordpress/i18n";
1702
1897
 
1703
1898
  // src/controls/font-family-control/enqueue-font.tsx
@@ -1730,36 +1925,30 @@ var FontFamilySelector = ({
1730
1925
  onFontFamilyChange,
1731
1926
  onClose
1732
1927
  }) => {
1733
- const [searchValue, setSearchValue] = useState5("");
1928
+ const [searchValue, setSearchValue] = useState6("");
1734
1929
  const filteredFontFamilies = useFilteredFontFamilies(fontFamilies, searchValue);
1735
- const handleSearch = (event) => {
1736
- setSearchValue(event.target.value);
1930
+ const handleSearch = (value) => {
1931
+ setSearchValue(value);
1737
1932
  };
1738
1933
  const handleClose = () => {
1739
1934
  setSearchValue("");
1740
1935
  onClose();
1741
1936
  };
1742
- return /* @__PURE__ */ React32.createElement(Stack9, null, /* @__PURE__ */ React32.createElement(
1937
+ return /* @__PURE__ */ React34.createElement(Stack9, null, /* @__PURE__ */ React34.createElement(
1743
1938
  PopoverHeader,
1744
1939
  {
1745
1940
  title: __8("Font Family", "elementor"),
1746
1941
  onClose: handleClose,
1747
- icon: /* @__PURE__ */ React32.createElement(TextIcon, { fontSize: SIZE2 })
1942
+ icon: /* @__PURE__ */ React34.createElement(TextIcon, { fontSize: SIZE2 })
1748
1943
  }
1749
- ), /* @__PURE__ */ React32.createElement(Box3, { px: 1.5, pb: 1 }, /* @__PURE__ */ React32.createElement(
1750
- TextField5,
1944
+ ), /* @__PURE__ */ React34.createElement(
1945
+ PopoverSearch,
1751
1946
  {
1752
- autoFocus: true,
1753
- fullWidth: true,
1754
- size: SIZE2,
1755
1947
  value: searchValue,
1756
- placeholder: __8("Search", "elementor"),
1757
- onChange: handleSearch,
1758
- InputProps: {
1759
- startAdornment: /* @__PURE__ */ React32.createElement(InputAdornment3, { position: "start" }, /* @__PURE__ */ React32.createElement(SearchIcon, { fontSize: SIZE2 }))
1760
- }
1948
+ onSearch: handleSearch,
1949
+ placeholder: __8("Search", "elementor")
1761
1950
  }
1762
- )), /* @__PURE__ */ React32.createElement(Divider2, null), filteredFontFamilies.length > 0 ? /* @__PURE__ */ React32.createElement(
1951
+ ), /* @__PURE__ */ React34.createElement(Divider2, null), filteredFontFamilies.length > 0 ? /* @__PURE__ */ React34.createElement(
1763
1952
  FontList,
1764
1953
  {
1765
1954
  fontListItems: filteredFontFamilies,
@@ -1767,7 +1956,7 @@ var FontFamilySelector = ({
1767
1956
  handleClose,
1768
1957
  fontFamily
1769
1958
  }
1770
- ) : /* @__PURE__ */ React32.createElement(Box3, { sx: { overflowY: "auto", height: 260, width: 220 } }, /* @__PURE__ */ React32.createElement(Stack9, { alignItems: "center", p: 2.5, gap: 1.5, overflow: "hidden" }, /* @__PURE__ */ React32.createElement(TextIcon, { fontSize: "large" }), /* @__PURE__ */ React32.createElement(Box3, { sx: { maxWidth: 160, overflow: "hidden" } }, /* @__PURE__ */ React32.createElement(Typography3, { align: "center", variant: "subtitle2", color: "text.secondary" }, __8("Sorry, nothing matched", "elementor")), /* @__PURE__ */ React32.createElement(
1959
+ ) : /* @__PURE__ */ React34.createElement(PopoverScrollableContent, null, /* @__PURE__ */ React34.createElement(Stack9, { alignItems: "center", p: 2.5, gap: 1.5, overflow: "hidden" }, /* @__PURE__ */ React34.createElement(TextIcon, { fontSize: "large" }), /* @__PURE__ */ React34.createElement(Box3, { sx: { maxWidth: 160, overflow: "hidden" } }, /* @__PURE__ */ React34.createElement(Typography3, { align: "center", variant: "subtitle2", color: "text.secondary" }, __8("Sorry, nothing matched", "elementor")), /* @__PURE__ */ React34.createElement(
1771
1960
  Typography3,
1772
1961
  {
1773
1962
  variant: "subtitle2",
@@ -1778,10 +1967,10 @@ var FontFamilySelector = ({
1778
1967
  justifyContent: "center"
1779
1968
  }
1780
1969
  },
1781
- /* @__PURE__ */ React32.createElement("span", null, "\u201C"),
1782
- /* @__PURE__ */ React32.createElement("span", { style: { maxWidth: "80%", overflow: "hidden", textOverflow: "ellipsis" } }, searchValue),
1783
- /* @__PURE__ */ React32.createElement("span", null, "\u201D.")
1784
- )), /* @__PURE__ */ React32.createElement(Typography3, { align: "center", variant: "caption", color: "text.secondary" }, __8("Try something else.", "elementor"), /* @__PURE__ */ React32.createElement(
1970
+ /* @__PURE__ */ React34.createElement("span", null, "\u201C"),
1971
+ /* @__PURE__ */ React34.createElement("span", { style: { maxWidth: "80%", overflow: "hidden", textOverflow: "ellipsis" } }, searchValue),
1972
+ /* @__PURE__ */ React34.createElement("span", null, "\u201D.")
1973
+ )), /* @__PURE__ */ React34.createElement(Typography3, { align: "center", variant: "caption", color: "text.secondary" }, __8("Try something else.", "elementor"), /* @__PURE__ */ React34.createElement(
1785
1974
  Link,
1786
1975
  {
1787
1976
  color: "secondary",
@@ -1792,10 +1981,7 @@ var FontFamilySelector = ({
1792
1981
  __8("Clear & try again", "elementor")
1793
1982
  )))));
1794
1983
  };
1795
- var LIST_ITEM_HEIGHT = 36;
1796
- var LIST_ITEMS_BUFFER = 6;
1797
1984
  var FontList = ({ fontListItems, setFontFamily, handleClose, fontFamily }) => {
1798
- const containerRef = useRef4(null);
1799
1985
  const selectedItem = fontListItems.find((item) => item.value === fontFamily);
1800
1986
  const debouncedVirtualizeChange = useDebounce(({ getVirtualIndexes }) => {
1801
1987
  getVirtualIndexes().forEach((index) => {
@@ -1805,150 +1991,49 @@ var FontList = ({ fontListItems, setFontFamily, handleClose, fontFamily }) => {
1805
1991
  }
1806
1992
  });
1807
1993
  }, 100);
1808
- const virtualizer = useVirtualizer({
1809
- count: fontListItems.length,
1810
- getScrollElement: () => containerRef.current,
1811
- estimateSize: () => LIST_ITEM_HEIGHT,
1812
- overscan: LIST_ITEMS_BUFFER,
1813
- onChange: debouncedVirtualizeChange
1814
- });
1815
- useEffect4(
1816
- () => {
1817
- virtualizer.scrollToIndex(fontListItems.findIndex((item) => item.value === fontFamily));
1818
- },
1819
- // eslint-disable-next-line react-compiler/react-compiler
1820
- // eslint-disable-next-line react-hooks/exhaustive-deps
1821
- [fontFamily]
1822
- );
1823
- return /* @__PURE__ */ React32.createElement(
1824
- Box3,
1994
+ return /* @__PURE__ */ React34.createElement(
1995
+ PopoverMenuList,
1825
1996
  {
1826
- ref: containerRef,
1827
- sx: {
1828
- overflowY: "auto",
1829
- height: 260,
1830
- width: 220
1831
- }
1832
- },
1833
- /* @__PURE__ */ React32.createElement(
1834
- StyledMenuList,
1835
- {
1836
- role: "listbox",
1837
- style: {
1838
- height: `${virtualizer.getTotalSize()}px`
1839
- },
1840
- "data-testid": "font-list"
1841
- },
1842
- virtualizer.getVirtualItems().map((virtualRow) => {
1843
- const item = fontListItems[virtualRow.index];
1844
- const isLast = virtualRow.index === fontListItems.length - 1;
1845
- const isFirst = virtualRow.index === 1;
1846
- const isSelected = selectedItem?.value === item.value;
1847
- const tabIndexFallback = !selectedItem ? 0 : -1;
1848
- if (item.type === "category") {
1849
- return /* @__PURE__ */ React32.createElement(
1850
- MenuSubheader,
1851
- {
1852
- key: virtualRow.key,
1853
- style: {
1854
- transform: `translateY(${virtualRow.start}px)`
1855
- }
1856
- },
1857
- item.value
1858
- );
1859
- }
1860
- return /* @__PURE__ */ React32.createElement(
1861
- "li",
1862
- {
1863
- key: virtualRow.key,
1864
- role: "option",
1865
- "aria-selected": isSelected,
1866
- onClick: () => {
1867
- setFontFamily(item.value);
1868
- handleClose();
1869
- },
1870
- onKeyDown: (event) => {
1871
- if (event.key === "Enter") {
1872
- setFontFamily(item.value);
1873
- handleClose();
1874
- }
1875
- if (event.key === "ArrowDown" && isLast) {
1876
- event.preventDefault();
1877
- event.stopPropagation();
1878
- }
1879
- if (event.key === "ArrowUp" && isFirst) {
1880
- event.preventDefault();
1881
- event.stopPropagation();
1882
- }
1883
- },
1884
- tabIndex: isSelected ? 0 : tabIndexFallback,
1885
- style: {
1886
- transform: `translateY(${virtualRow.start}px)`,
1887
- fontFamily: item.value
1888
- }
1889
- },
1890
- item.value
1891
- );
1892
- })
1893
- )
1997
+ items: fontListItems,
1998
+ selectedValue: selectedItem?.value,
1999
+ onChange: debouncedVirtualizeChange,
2000
+ onSelect: setFontFamily,
2001
+ onClose: handleClose,
2002
+ itemStyle: (item) => ({ fontFamily: item.value }),
2003
+ "data-testid": "font-list"
2004
+ }
1894
2005
  );
1895
2006
  };
1896
- var StyledMenuList = styled4(MenuList)(({ theme }) => ({
1897
- "& > li": {
1898
- height: LIST_ITEM_HEIGHT,
1899
- position: "absolute",
1900
- top: 0,
1901
- left: 0,
1902
- width: "100%",
1903
- display: "flex",
1904
- alignItems: "center"
1905
- },
1906
- '& > [role="option"]': {
1907
- ...theme.typography.caption,
1908
- lineHeight: "inherit",
1909
- padding: theme.spacing(0.75, 2, 0.75, 4),
1910
- "&:hover, &:focus": {
1911
- backgroundColor: theme.palette.action.hover
1912
- },
1913
- '&[aria-selected="true"]': {
1914
- backgroundColor: theme.palette.action.selected
1915
- },
1916
- cursor: "pointer",
1917
- textOverflow: "ellipsis"
1918
- },
1919
- width: "100%",
1920
- position: "relative"
1921
- }));
1922
2007
  var useDebounce = (fn, delay) => {
1923
- const [debouncedFn] = useState5(() => debounce(fn, delay));
1924
- useEffect4(() => () => debouncedFn.cancel(), [debouncedFn]);
2008
+ const [debouncedFn] = useState6(() => debounce(fn, delay));
2009
+ useEffect5(() => () => debouncedFn.cancel(), [debouncedFn]);
1925
2010
  return debouncedFn;
1926
2011
  };
1927
2012
 
1928
2013
  // src/controls/font-family-control/font-family-control.tsx
1929
2014
  var SIZE3 = "tiny";
1930
2015
  var FontFamilyControl = createControl(({ fontFamilies }) => {
1931
- const { value: fontFamily, setValue: setFontFamily, disabled } = useBoundProp(stringPropTypeUtil6);
1932
- const popoverState = usePopupState4({ variant: "popover" });
1933
- return /* @__PURE__ */ React33.createElement(React33.Fragment, null, /* @__PURE__ */ React33.createElement(ControlActions, null, /* @__PURE__ */ React33.createElement(
2016
+ const { value: fontFamily, setValue: setFontFamily, disabled } = useBoundProp(stringPropTypeUtil5);
2017
+ const popoverState = usePopupState5({ variant: "popover" });
2018
+ return /* @__PURE__ */ React35.createElement(React35.Fragment, null, /* @__PURE__ */ React35.createElement(ControlActions, null, /* @__PURE__ */ React35.createElement(
1934
2019
  UnstableTag2,
1935
2020
  {
1936
2021
  variant: "outlined",
1937
2022
  label: fontFamily,
1938
- endIcon: /* @__PURE__ */ React33.createElement(ChevronDownIcon2, { fontSize: SIZE3 }),
2023
+ endIcon: /* @__PURE__ */ React35.createElement(ChevronDownIcon2, { fontSize: SIZE3 }),
1939
2024
  ...bindTrigger3(popoverState),
1940
2025
  fullWidth: true,
1941
2026
  disabled
1942
2027
  }
1943
- )), /* @__PURE__ */ React33.createElement(
1944
- Popover3,
2028
+ )), /* @__PURE__ */ React35.createElement(
2029
+ Popover4,
1945
2030
  {
1946
2031
  disablePortal: true,
1947
2032
  disableScrollLock: true,
1948
2033
  anchorOrigin: { vertical: "bottom", horizontal: "left" },
1949
- ...bindPopover3(popoverState)
2034
+ ...bindPopover4(popoverState)
1950
2035
  },
1951
- /* @__PURE__ */ React33.createElement(
2036
+ /* @__PURE__ */ React35.createElement(
1952
2037
  FontFamilySelector,
1953
2038
  {
1954
2039
  fontFamilies,
@@ -1961,13 +2046,13 @@ var FontFamilyControl = createControl(({ fontFamilies }) => {
1961
2046
  });
1962
2047
 
1963
2048
  // src/controls/url-control.tsx
1964
- import * as React34 from "react";
2049
+ import * as React36 from "react";
1965
2050
  import { urlPropTypeUtil } from "@elementor/editor-props";
1966
2051
  import { TextField as TextField6 } from "@elementor/ui";
1967
2052
  var UrlControl = createControl(({ placeholder }) => {
1968
2053
  const { value, setValue, disabled } = useBoundProp(urlPropTypeUtil);
1969
2054
  const handleChange = (event) => setValue(event.target.value);
1970
- return /* @__PURE__ */ React34.createElement(ControlActions, null, /* @__PURE__ */ React34.createElement(
2055
+ return /* @__PURE__ */ React36.createElement(ControlActions, null, /* @__PURE__ */ React36.createElement(
1971
2056
  TextField6,
1972
2057
  {
1973
2058
  size: "tiny",
@@ -1981,14 +2066,14 @@ var UrlControl = createControl(({ placeholder }) => {
1981
2066
  });
1982
2067
 
1983
2068
  // src/controls/link-control.tsx
1984
- import * as React36 from "react";
1985
- import { useMemo as useMemo2, useState as useState6 } from "react";
2069
+ import * as React38 from "react";
2070
+ import { useMemo as useMemo3, useState as useState7 } from "react";
1986
2071
  import { getLinkInLinkRestriction, selectElement } from "@elementor/editor-elements";
1987
2072
  import {
1988
2073
  booleanPropTypeUtil,
1989
2074
  linkPropTypeUtil,
1990
2075
  numberPropTypeUtil as numberPropTypeUtil2,
1991
- stringPropTypeUtil as stringPropTypeUtil7,
2076
+ stringPropTypeUtil as stringPropTypeUtil6,
1992
2077
  urlPropTypeUtil as urlPropTypeUtil2
1993
2078
  } from "@elementor/editor-props";
1994
2079
  import { InfoTipCard } from "@elementor/editor-ui";
@@ -2000,17 +2085,17 @@ import { debounce as debounce2 } from "@elementor/utils";
2000
2085
  import { __ as __9 } from "@wordpress/i18n";
2001
2086
 
2002
2087
  // src/components/autocomplete.tsx
2003
- import * as React35 from "react";
2004
- import { forwardRef as forwardRef2 } from "react";
2088
+ import * as React37 from "react";
2089
+ import { forwardRef as forwardRef4 } from "react";
2005
2090
  import { XIcon as XIcon2 } from "@elementor/icons";
2006
2091
  import {
2007
2092
  Autocomplete as AutocompleteBase,
2008
2093
  Box as Box4,
2009
2094
  IconButton as IconButton2,
2010
- InputAdornment as InputAdornment4,
2095
+ InputAdornment as InputAdornment3,
2011
2096
  TextField as TextField7
2012
2097
  } from "@elementor/ui";
2013
- var Autocomplete = forwardRef2((props, ref) => {
2098
+ var Autocomplete = forwardRef4((props, ref) => {
2014
2099
  const {
2015
2100
  options,
2016
2101
  onOptionChange,
@@ -2026,7 +2111,7 @@ var Autocomplete = forwardRef2((props, ref) => {
2026
2111
  const muiWarningPreventer = allowCustomValues || !!value?.toString()?.length;
2027
2112
  const isOptionEqualToValue = muiWarningPreventer ? void 0 : () => true;
2028
2113
  const isValueFromOptions = typeof value === "number" && !!findMatchingOption(options, value);
2029
- return /* @__PURE__ */ React35.createElement(
2114
+ return /* @__PURE__ */ React37.createElement(
2030
2115
  AutocompleteBase,
2031
2116
  {
2032
2117
  ...restProps,
@@ -2044,8 +2129,8 @@ var Autocomplete = forwardRef2((props, ref) => {
2044
2129
  groupBy: isCategorizedOptionPool(options) ? (optionId) => findMatchingOption(options, optionId)?.groupLabel || optionId : void 0,
2045
2130
  isOptionEqualToValue,
2046
2131
  filterOptions: () => optionKeys,
2047
- renderOption: (optionProps, optionId) => /* @__PURE__ */ React35.createElement(Box4, { component: "li", ...optionProps, key: optionProps.id }, findMatchingOption(options, optionId)?.label ?? optionId),
2048
- renderInput: (params) => /* @__PURE__ */ React35.createElement(
2132
+ renderOption: (optionProps, optionId) => /* @__PURE__ */ React37.createElement(Box4, { component: "li", ...optionProps, key: optionProps.id }, findMatchingOption(options, optionId)?.label ?? optionId),
2133
+ renderInput: (params) => /* @__PURE__ */ React37.createElement(
2049
2134
  TextInput,
2050
2135
  {
2051
2136
  params,
@@ -2068,7 +2153,7 @@ var TextInput = ({
2068
2153
  const onChange = (event) => {
2069
2154
  handleChange(event.target.value);
2070
2155
  };
2071
- return /* @__PURE__ */ React35.createElement(
2156
+ return /* @__PURE__ */ React37.createElement(
2072
2157
  TextField7,
2073
2158
  {
2074
2159
  ...params,
@@ -2081,7 +2166,7 @@ var TextInput = ({
2081
2166
  },
2082
2167
  InputProps: {
2083
2168
  ...params.InputProps,
2084
- endAdornment: /* @__PURE__ */ React35.createElement(ClearButton, { params, allowClear, handleChange })
2169
+ endAdornment: /* @__PURE__ */ React37.createElement(ClearButton, { params, allowClear, handleChange })
2085
2170
  }
2086
2171
  }
2087
2172
  );
@@ -2090,7 +2175,7 @@ var ClearButton = ({
2090
2175
  allowClear,
2091
2176
  handleChange,
2092
2177
  params
2093
- }) => /* @__PURE__ */ React35.createElement(InputAdornment4, { position: "end" }, allowClear && /* @__PURE__ */ React35.createElement(IconButton2, { size: params.size, onClick: () => handleChange(null), sx: { cursor: "pointer" } }, /* @__PURE__ */ React35.createElement(XIcon2, { fontSize: params.size })));
2178
+ }) => /* @__PURE__ */ React37.createElement(InputAdornment3, { position: "end" }, allowClear && /* @__PURE__ */ React37.createElement(IconButton2, { size: params.size, onClick: () => handleChange(null), sx: { cursor: "pointer" } }, /* @__PURE__ */ React37.createElement(XIcon2, { fontSize: params.size })));
2094
2179
  function findMatchingOption(options, optionId = null) {
2095
2180
  const formattedOption = (optionId || "").toString();
2096
2181
  return options.find(({ id }) => formattedOption === id.toString());
@@ -2120,7 +2205,7 @@ var learnMoreButton = {
2120
2205
  var LinkControl = createControl((props) => {
2121
2206
  const { value, path, setValue, ...propContext } = useBoundProp(linkPropTypeUtil);
2122
2207
  const [linkSessionValue, setLinkSessionValue] = useSessionStorage(path.join("/"));
2123
- const [isActive, setIsActive] = useState6(!!value);
2208
+ const [isActive, setIsActive] = useState7(!!value);
2124
2209
  const {
2125
2210
  allowCustomValues,
2126
2211
  queryOptions: { endpoint = "", requestParams = {} },
@@ -2128,8 +2213,8 @@ var LinkControl = createControl((props) => {
2128
2213
  minInputLength = 2,
2129
2214
  context: { elementId }
2130
2215
  } = props || {};
2131
- const [linkInLinkRestriction, setLinkInLinkRestriction] = useState6(getLinkInLinkRestriction(elementId));
2132
- const [options, setOptions] = useState6(
2216
+ const [linkInLinkRestriction, setLinkInLinkRestriction] = useState7(getLinkInLinkRestriction(elementId));
2217
+ const [options, setOptions] = useState7(
2133
2218
  generateFirstLoadedOption(value)
2134
2219
  );
2135
2220
  const shouldDisableAddingLink = !isActive && linkInLinkRestriction.shouldRestrict;
@@ -2155,7 +2240,7 @@ var LinkControl = createControl((props) => {
2155
2240
  const valueToSave = newValue ? {
2156
2241
  ...value,
2157
2242
  destination: numberPropTypeUtil2.create(newValue),
2158
- label: stringPropTypeUtil7.create(findMatchingOption(options, newValue)?.label || null)
2243
+ label: stringPropTypeUtil6.create(findMatchingOption(options, newValue)?.label || null)
2159
2244
  } : null;
2160
2245
  onSaveNewValue(valueToSave);
2161
2246
  };
@@ -2164,7 +2249,7 @@ var LinkControl = createControl((props) => {
2164
2249
  const valueToSave = newValue ? {
2165
2250
  ...value,
2166
2251
  destination: urlPropTypeUtil2.create(newValue),
2167
- label: stringPropTypeUtil7.create("")
2252
+ label: stringPropTypeUtil6.create("")
2168
2253
  } : null;
2169
2254
  onSaveNewValue(valueToSave);
2170
2255
  updateOptions(newValue);
@@ -2180,7 +2265,7 @@ var LinkControl = createControl((props) => {
2180
2265
  }
2181
2266
  debounceFetch({ ...requestParams, term: newValue });
2182
2267
  };
2183
- const debounceFetch = useMemo2(
2268
+ const debounceFetch = useMemo3(
2184
2269
  () => debounce2(
2185
2270
  (params) => fetchOptions(endpoint, params).then((newOptions) => {
2186
2271
  setOptions(formatOptions(newOptions));
@@ -2189,7 +2274,7 @@ var LinkControl = createControl((props) => {
2189
2274
  ),
2190
2275
  [endpoint]
2191
2276
  );
2192
- return /* @__PURE__ */ React36.createElement(PropProvider, { ...propContext, value, setValue }, /* @__PURE__ */ React36.createElement(Stack10, { gap: 1.5 }, /* @__PURE__ */ React36.createElement(
2277
+ return /* @__PURE__ */ React38.createElement(PropProvider, { ...propContext, value, setValue }, /* @__PURE__ */ React38.createElement(Stack10, { gap: 1.5 }, /* @__PURE__ */ React38.createElement(
2193
2278
  Stack10,
2194
2279
  {
2195
2280
  direction: "row",
@@ -2199,8 +2284,8 @@ var LinkControl = createControl((props) => {
2199
2284
  marginInlineEnd: -0.75
2200
2285
  }
2201
2286
  },
2202
- /* @__PURE__ */ React36.createElement(ControlFormLabel, null, __9("Link", "elementor")),
2203
- /* @__PURE__ */ React36.createElement(ConditionalInfoTip, { isVisible: !isActive, linkInLinkRestriction }, /* @__PURE__ */ React36.createElement(
2287
+ /* @__PURE__ */ React38.createElement(ControlFormLabel, null, __9("Link", "elementor")),
2288
+ /* @__PURE__ */ React38.createElement(ConditionalInfoTip, { isVisible: !isActive, linkInLinkRestriction }, /* @__PURE__ */ React38.createElement(
2204
2289
  ToggleIconControl,
2205
2290
  {
2206
2291
  disabled: shouldDisableAddingLink,
@@ -2209,7 +2294,7 @@ var LinkControl = createControl((props) => {
2209
2294
  label: __9("Toggle link", "elementor")
2210
2295
  }
2211
2296
  ))
2212
- ), /* @__PURE__ */ React36.createElement(Collapse, { in: isActive, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React36.createElement(Stack10, { gap: 1.5 }, /* @__PURE__ */ React36.createElement(PropKeyProvider, { bind: "destination" }, /* @__PURE__ */ React36.createElement(ControlActions, null, /* @__PURE__ */ React36.createElement(
2297
+ ), /* @__PURE__ */ React38.createElement(Collapse, { in: isActive, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React38.createElement(Stack10, { gap: 1.5 }, /* @__PURE__ */ React38.createElement(PropKeyProvider, { bind: "destination" }, /* @__PURE__ */ React38.createElement(ControlActions, null, /* @__PURE__ */ React38.createElement(
2213
2298
  Autocomplete,
2214
2299
  {
2215
2300
  options,
@@ -2220,10 +2305,10 @@ var LinkControl = createControl((props) => {
2220
2305
  onTextChange,
2221
2306
  minInputLength
2222
2307
  }
2223
- ))), /* @__PURE__ */ React36.createElement(PropKeyProvider, { bind: "isTargetBlank" }, /* @__PURE__ */ React36.createElement(SwitchControl, { disabled: propContext.disabled || !value }))))));
2308
+ ))), /* @__PURE__ */ React38.createElement(PropKeyProvider, { bind: "isTargetBlank" }, /* @__PURE__ */ React38.createElement(SwitchControl, { disabled: propContext.disabled || !value }))))));
2224
2309
  });
2225
2310
  var ToggleIconControl = ({ disabled, active, onIconClick, label }) => {
2226
- return /* @__PURE__ */ React36.createElement(IconButton3, { size: SIZE4, onClick: onIconClick, "aria-label": label, disabled }, active ? /* @__PURE__ */ React36.createElement(MinusIcon, { fontSize: SIZE4 }) : /* @__PURE__ */ React36.createElement(PlusIcon2, { fontSize: SIZE4 }));
2311
+ return /* @__PURE__ */ React38.createElement(IconButton3, { size: SIZE4, onClick: onIconClick, "aria-label": label, disabled }, active ? /* @__PURE__ */ React38.createElement(MinusIcon, { fontSize: SIZE4 }) : /* @__PURE__ */ React38.createElement(PlusIcon2, { fontSize: SIZE4 }));
2227
2312
  };
2228
2313
  var SwitchControl = ({ disabled }) => {
2229
2314
  const { value = false, setValue } = useBoundProp(booleanPropTypeUtil);
@@ -2235,7 +2320,7 @@ var SwitchControl = ({ disabled }) => {
2235
2320
  opacity: 0
2236
2321
  }
2237
2322
  } : {};
2238
- return /* @__PURE__ */ React36.createElement(Grid7, { container: true, alignItems: "center", flexWrap: "nowrap", justifyContent: "space-between" }, /* @__PURE__ */ React36.createElement(Grid7, { item: true }, /* @__PURE__ */ React36.createElement(ControlFormLabel, null, __9("Open in a new tab", "elementor"))), /* @__PURE__ */ React36.createElement(Grid7, { item: true, sx: { marginInlineEnd: -1 } }, /* @__PURE__ */ React36.createElement(Switch, { checked: value, onClick, disabled, inputProps })));
2323
+ return /* @__PURE__ */ React38.createElement(Grid7, { container: true, alignItems: "center", flexWrap: "nowrap", justifyContent: "space-between" }, /* @__PURE__ */ React38.createElement(Grid7, { item: true }, /* @__PURE__ */ React38.createElement(ControlFormLabel, null, __9("Open in a new tab", "elementor"))), /* @__PURE__ */ React38.createElement(Grid7, { item: true, sx: { marginInlineEnd: -1 } }, /* @__PURE__ */ React38.createElement(Switch, { checked: value, onClick, disabled, inputProps })));
2239
2324
  };
2240
2325
  async function fetchOptions(ajaxUrl, params) {
2241
2326
  if (!params || !ajaxUrl) {
@@ -2272,15 +2357,15 @@ var ConditionalInfoTip = ({ linkInLinkRestriction, isVisible, children }) => {
2272
2357
  selectElement(elementId);
2273
2358
  }
2274
2359
  };
2275
- return shouldRestrict && isVisible ? /* @__PURE__ */ React36.createElement(
2360
+ return shouldRestrict && isVisible ? /* @__PURE__ */ React38.createElement(
2276
2361
  Infotip,
2277
2362
  {
2278
2363
  placement: "right",
2279
- content: /* @__PURE__ */ React36.createElement(
2364
+ content: /* @__PURE__ */ React38.createElement(
2280
2365
  InfoTipCard,
2281
2366
  {
2282
2367
  content: INFOTIP_CONTENT[reason],
2283
- svgIcon: /* @__PURE__ */ React36.createElement(AlertTriangleIcon, null),
2368
+ svgIcon: /* @__PURE__ */ React38.createElement(AlertTriangleIcon, null),
2284
2369
  learnMoreButton,
2285
2370
  ctaButton: {
2286
2371
  label: __9("Take me there", "elementor"),
@@ -2289,16 +2374,17 @@ var ConditionalInfoTip = ({ linkInLinkRestriction, isVisible, children }) => {
2289
2374
  }
2290
2375
  )
2291
2376
  },
2292
- /* @__PURE__ */ React36.createElement(Box5, null, children)
2293
- ) : /* @__PURE__ */ React36.createElement(React36.Fragment, null, children);
2377
+ /* @__PURE__ */ React38.createElement(Box5, null, children)
2378
+ ) : /* @__PURE__ */ React38.createElement(React38.Fragment, null, children);
2294
2379
  };
2295
2380
  var INFOTIP_CONTENT = {
2296
- descendant: /* @__PURE__ */ React36.createElement(React36.Fragment, null, __9("To add a link to this container,", "elementor"), /* @__PURE__ */ React36.createElement("br", null), __9("first remove the link from the elements inside of it.", "elementor")),
2297
- ancestor: /* @__PURE__ */ React36.createElement(React36.Fragment, null, __9("To add a link to this element,", "elementor"), /* @__PURE__ */ React36.createElement("br", null), __9("first remove the link from its parent container.", "elementor"))
2381
+ descendant: /* @__PURE__ */ React38.createElement(React38.Fragment, null, __9("To add a link to this container,", "elementor"), /* @__PURE__ */ React38.createElement("br", null), __9("first remove the link from the elements inside of it.", "elementor")),
2382
+ ancestor: /* @__PURE__ */ React38.createElement(React38.Fragment, null, __9("To add a link to this element,", "elementor"), /* @__PURE__ */ React38.createElement("br", null), __9("first remove the link from its parent container.", "elementor"))
2298
2383
  };
2299
2384
 
2300
2385
  // src/controls/gap-control.tsx
2301
- import * as React37 from "react";
2386
+ import * as React39 from "react";
2387
+ import { useRef as useRef7 } from "react";
2302
2388
  import { layoutDirectionPropTypeUtil, sizePropTypeUtil as sizePropTypeUtil4 } from "@elementor/editor-props";
2303
2389
  import { DetachIcon as DetachIcon2, LinkIcon as LinkIcon2 } from "@elementor/icons";
2304
2390
  import { Grid as Grid8, Stack as Stack11, ToggleButton as ToggleButton4, Tooltip as Tooltip5 } from "@elementor/ui";
@@ -2310,6 +2396,7 @@ var GapControl = createControl(({ label }) => {
2310
2396
  propType,
2311
2397
  disabled: directionDisabled
2312
2398
  } = useBoundProp(layoutDirectionPropTypeUtil);
2399
+ const stackRef = useRef7();
2313
2400
  const { value: sizeValue, setValue: setSizeValue, disabled: sizeDisabled } = useBoundProp(sizePropTypeUtil4);
2314
2401
  const isLinked = !directionValue && !sizeValue ? true : !!sizeValue;
2315
2402
  const onLinkToggle = () => {
@@ -2328,7 +2415,7 @@ var GapControl = createControl(({ label }) => {
2328
2415
  const linkedLabel = __10("Link %s", "elementor").replace("%s", tooltipLabel);
2329
2416
  const unlinkedLabel = __10("Unlink %s", "elementor").replace("%s", tooltipLabel);
2330
2417
  const disabled = sizeDisabled || directionDisabled;
2331
- return /* @__PURE__ */ React37.createElement(PropProvider, { propType, value: directionValue, setValue: setDirectionValue }, /* @__PURE__ */ React37.createElement(Stack11, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React37.createElement(ControlLabel, null, label), /* @__PURE__ */ React37.createElement(Tooltip5, { title: isLinked ? unlinkedLabel : linkedLabel, placement: "top" }, /* @__PURE__ */ React37.createElement(
2418
+ return /* @__PURE__ */ React39.createElement(PropProvider, { propType, value: directionValue, setValue: setDirectionValue }, /* @__PURE__ */ React39.createElement(Stack11, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React39.createElement(ControlLabel, null, label), /* @__PURE__ */ React39.createElement(Tooltip5, { title: isLinked ? unlinkedLabel : linkedLabel, placement: "top" }, /* @__PURE__ */ React39.createElement(
2332
2419
  ToggleButton4,
2333
2420
  {
2334
2421
  "aria-label": isLinked ? unlinkedLabel : linkedLabel,
@@ -2339,20 +2426,24 @@ var GapControl = createControl(({ label }) => {
2339
2426
  onChange: onLinkToggle,
2340
2427
  disabled
2341
2428
  },
2342
- /* @__PURE__ */ React37.createElement(LinkedIcon, { fontSize: "tiny" })
2343
- ))), /* @__PURE__ */ React37.createElement(Stack11, { direction: "row", gap: 2, flexWrap: "nowrap" }, /* @__PURE__ */ React37.createElement(Grid8, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React37.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React37.createElement(ControlFormLabel, null, __10("Column", "elementor"))), /* @__PURE__ */ React37.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React37.createElement(Control4, { bind: "column", isLinked }))), /* @__PURE__ */ React37.createElement(Grid8, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React37.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React37.createElement(ControlFormLabel, null, __10("Row", "elementor"))), /* @__PURE__ */ React37.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React37.createElement(Control4, { bind: "row", isLinked })))));
2429
+ /* @__PURE__ */ React39.createElement(LinkedIcon, { fontSize: "tiny" })
2430
+ ))), /* @__PURE__ */ React39.createElement(Stack11, { direction: "row", gap: 2, flexWrap: "nowrap", ref: stackRef }, /* @__PURE__ */ React39.createElement(Grid8, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React39.createElement(ControlFormLabel, null, __10("Column", "elementor"))), /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React39.createElement(Control4, { bind: "column", isLinked, anchorRef: stackRef }))), /* @__PURE__ */ React39.createElement(Grid8, { container: true, gap: 0.75, alignItems: "center" }, /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React39.createElement(ControlFormLabel, null, __10("Row", "elementor"))), /* @__PURE__ */ React39.createElement(Grid8, { item: true, xs: 12 }, /* @__PURE__ */ React39.createElement(Control4, { bind: "row", isLinked, anchorRef: stackRef })))));
2344
2431
  });
2345
- var Control4 = ({ bind, isLinked }) => {
2432
+ var Control4 = ({
2433
+ bind,
2434
+ isLinked,
2435
+ anchorRef
2436
+ }) => {
2346
2437
  if (isLinked) {
2347
- return /* @__PURE__ */ React37.createElement(SizeControl, null);
2438
+ return /* @__PURE__ */ React39.createElement(SizeControl, { anchorRef });
2348
2439
  }
2349
- return /* @__PURE__ */ React37.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React37.createElement(SizeControl, null));
2440
+ return /* @__PURE__ */ React39.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React39.createElement(SizeControl, { anchorRef }));
2350
2441
  };
2351
2442
 
2352
2443
  // src/controls/aspect-ratio-control.tsx
2353
- import * as React38 from "react";
2354
- import { useState as useState7 } from "react";
2355
- import { stringPropTypeUtil as stringPropTypeUtil8 } from "@elementor/editor-props";
2444
+ import * as React40 from "react";
2445
+ import { useState as useState8 } from "react";
2446
+ import { stringPropTypeUtil as stringPropTypeUtil7 } from "@elementor/editor-props";
2356
2447
  import { MenuListItem as MenuListItem3 } from "@elementor/editor-ui";
2357
2448
  import { ArrowsMoveHorizontalIcon, ArrowsMoveVerticalIcon } from "@elementor/icons";
2358
2449
  import { Grid as Grid9, Select as Select2, Stack as Stack12, TextField as TextField8 } from "@elementor/ui";
@@ -2369,13 +2460,13 @@ var RATIO_OPTIONS = [
2369
2460
  ];
2370
2461
  var CUSTOM_RATIO = "custom";
2371
2462
  var AspectRatioControl = createControl(({ label }) => {
2372
- const { value: aspectRatioValue, setValue: setAspectRatioValue, disabled } = useBoundProp(stringPropTypeUtil8);
2463
+ const { value: aspectRatioValue, setValue: setAspectRatioValue, disabled } = useBoundProp(stringPropTypeUtil7);
2373
2464
  const isCustomSelected = aspectRatioValue && !RATIO_OPTIONS.some((option) => option.value === aspectRatioValue);
2374
2465
  const [initialWidth, initialHeight] = isCustomSelected ? aspectRatioValue.split("/") : ["", ""];
2375
- const [isCustom, setIsCustom] = useState7(isCustomSelected);
2376
- const [customWidth, setCustomWidth] = useState7(initialWidth);
2377
- const [customHeight, setCustomHeight] = useState7(initialHeight);
2378
- const [selectedValue, setSelectedValue] = useState7(
2466
+ const [isCustom, setIsCustom] = useState8(isCustomSelected);
2467
+ const [customWidth, setCustomWidth] = useState8(initialWidth);
2468
+ const [customHeight, setCustomHeight] = useState8(initialHeight);
2469
+ const [selectedValue, setSelectedValue] = useState8(
2379
2470
  isCustomSelected ? CUSTOM_RATIO : aspectRatioValue || ""
2380
2471
  );
2381
2472
  const handleSelectChange = (event) => {
@@ -2402,7 +2493,7 @@ var AspectRatioControl = createControl(({ label }) => {
2402
2493
  setAspectRatioValue(`${customWidth}/${newHeight}`);
2403
2494
  }
2404
2495
  };
2405
- return /* @__PURE__ */ React38.createElement(ControlActions, null, /* @__PURE__ */ React38.createElement(Stack12, { direction: "column", pt: 2, gap: 2 }, /* @__PURE__ */ React38.createElement(Grid9, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React38.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React38.createElement(ControlLabel, null, label)), /* @__PURE__ */ React38.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React38.createElement(
2496
+ return /* @__PURE__ */ React40.createElement(ControlActions, null, /* @__PURE__ */ React40.createElement(Stack12, { direction: "column", pt: 2, gap: 2 }, /* @__PURE__ */ React40.createElement(Grid9, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React40.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React40.createElement(ControlLabel, null, label)), /* @__PURE__ */ React40.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React40.createElement(
2406
2497
  Select2,
2407
2498
  {
2408
2499
  size: "tiny",
@@ -2414,9 +2505,9 @@ var AspectRatioControl = createControl(({ label }) => {
2414
2505
  fullWidth: true
2415
2506
  },
2416
2507
  [...RATIO_OPTIONS, { label: __11("Custom", "elementor"), value: CUSTOM_RATIO }].map(
2417
- ({ label: optionLabel, ...props }) => /* @__PURE__ */ React38.createElement(MenuListItem3, { key: props.value, ...props, value: props.value ?? "" }, optionLabel)
2508
+ ({ label: optionLabel, ...props }) => /* @__PURE__ */ React40.createElement(MenuListItem3, { key: props.value, ...props, value: props.value ?? "" }, optionLabel)
2418
2509
  )
2419
- ))), isCustom && /* @__PURE__ */ React38.createElement(Grid9, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React38.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React38.createElement(
2510
+ ))), isCustom && /* @__PURE__ */ React40.createElement(Grid9, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React40.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React40.createElement(
2420
2511
  TextField8,
2421
2512
  {
2422
2513
  size: "tiny",
@@ -2426,10 +2517,10 @@ var AspectRatioControl = createControl(({ label }) => {
2426
2517
  value: customWidth,
2427
2518
  onChange: handleCustomWidthChange,
2428
2519
  InputProps: {
2429
- startAdornment: /* @__PURE__ */ React38.createElement(ArrowsMoveHorizontalIcon, { fontSize: "tiny" })
2520
+ startAdornment: /* @__PURE__ */ React40.createElement(ArrowsMoveHorizontalIcon, { fontSize: "tiny" })
2430
2521
  }
2431
2522
  }
2432
- )), /* @__PURE__ */ React38.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React38.createElement(
2523
+ )), /* @__PURE__ */ React40.createElement(Grid9, { item: true, xs: 6 }, /* @__PURE__ */ React40.createElement(
2433
2524
  TextField8,
2434
2525
  {
2435
2526
  size: "tiny",
@@ -2439,24 +2530,24 @@ var AspectRatioControl = createControl(({ label }) => {
2439
2530
  value: customHeight,
2440
2531
  onChange: handleCustomHeightChange,
2441
2532
  InputProps: {
2442
- startAdornment: /* @__PURE__ */ React38.createElement(ArrowsMoveVerticalIcon, { fontSize: "tiny" })
2533
+ startAdornment: /* @__PURE__ */ React40.createElement(ArrowsMoveVerticalIcon, { fontSize: "tiny" })
2443
2534
  }
2444
2535
  }
2445
2536
  )))));
2446
2537
  });
2447
2538
 
2448
2539
  // src/controls/svg-media-control.tsx
2449
- import * as React40 from "react";
2450
- import { useState as useState9 } from "react";
2540
+ import * as React42 from "react";
2541
+ import { useState as useState10 } from "react";
2451
2542
  import { imageSrcPropTypeUtil as imageSrcPropTypeUtil2 } from "@elementor/editor-props";
2452
2543
  import { UploadIcon as UploadIcon2 } from "@elementor/icons";
2453
- import { Button as Button4, Card as Card2, CardMedia as CardMedia2, CardOverlay as CardOverlay2, CircularProgress as CircularProgress3, Stack as Stack13, styled as styled5 } from "@elementor/ui";
2544
+ import { Button as Button4, Card as Card2, CardMedia as CardMedia2, CardOverlay as CardOverlay2, CircularProgress as CircularProgress3, Stack as Stack13, styled as styled4 } from "@elementor/ui";
2454
2545
  import { useWpMediaAttachment as useWpMediaAttachment2, useWpMediaFrame as useWpMediaFrame2 } from "@elementor/wp-media";
2455
2546
  import { __ as __13 } from "@wordpress/i18n";
2456
2547
 
2457
2548
  // src/components/enable-unfiltered-modal.tsx
2458
- import * as React39 from "react";
2459
- import { useState as useState8 } from "react";
2549
+ import * as React41 from "react";
2550
+ import { useState as useState9 } from "react";
2460
2551
  import { useCurrentUserCapabilities } from "@elementor/editor-current-user";
2461
2552
  import {
2462
2553
  Button as Button3,
@@ -2489,7 +2580,7 @@ var WAIT_FOR_CLOSE_TIMEOUT_MS = 300;
2489
2580
  var EnableUnfilteredModal = (props) => {
2490
2581
  const { mutateAsync, isPending } = useUpdateUnfilteredFilesUpload();
2491
2582
  const { canUser } = useCurrentUserCapabilities();
2492
- const [isError, setIsError] = useState8(false);
2583
+ const [isError, setIsError] = useState9(false);
2493
2584
  const canManageOptions = canUser("manage_options");
2494
2585
  const onClose = (enabled) => {
2495
2586
  props.onClose(enabled);
@@ -2508,9 +2599,9 @@ var EnableUnfilteredModal = (props) => {
2508
2599
  }
2509
2600
  };
2510
2601
  const dialogProps = { ...props, isPending, handleEnable, isError, onClose };
2511
- return canManageOptions ? /* @__PURE__ */ React39.createElement(AdminDialog, { ...dialogProps }) : /* @__PURE__ */ React39.createElement(NonAdminDialog, { ...dialogProps });
2602
+ return canManageOptions ? /* @__PURE__ */ React41.createElement(AdminDialog, { ...dialogProps }) : /* @__PURE__ */ React41.createElement(NonAdminDialog, { ...dialogProps });
2512
2603
  };
2513
- var AdminDialog = ({ open, onClose, handleEnable, isPending, isError }) => /* @__PURE__ */ React39.createElement(Dialog, { open, maxWidth: "sm", onClose: () => onClose(false) }, /* @__PURE__ */ React39.createElement(DialogHeader, { logo: false }, /* @__PURE__ */ React39.createElement(DialogTitle, null, ADMIN_TITLE_TEXT)), /* @__PURE__ */ React39.createElement(Divider3, null), /* @__PURE__ */ React39.createElement(DialogContent, null, /* @__PURE__ */ React39.createElement(DialogContentText, null, isError ? /* @__PURE__ */ React39.createElement(React39.Fragment, null, ADMIN_FAILED_CONTENT_TEXT_PT1, " ", /* @__PURE__ */ React39.createElement("br", null), " ", ADMIN_FAILED_CONTENT_TEXT_PT2) : ADMIN_CONTENT_TEXT)), /* @__PURE__ */ React39.createElement(DialogActions, null, /* @__PURE__ */ React39.createElement(Button3, { size: "medium", color: "secondary", onClick: () => onClose(false) }, __12("Cancel", "elementor")), /* @__PURE__ */ React39.createElement(
2604
+ var AdminDialog = ({ open, onClose, handleEnable, isPending, isError }) => /* @__PURE__ */ React41.createElement(Dialog, { open, maxWidth: "sm", onClose: () => onClose(false) }, /* @__PURE__ */ React41.createElement(DialogHeader, { logo: false }, /* @__PURE__ */ React41.createElement(DialogTitle, null, ADMIN_TITLE_TEXT)), /* @__PURE__ */ React41.createElement(Divider3, null), /* @__PURE__ */ React41.createElement(DialogContent, null, /* @__PURE__ */ React41.createElement(DialogContentText, null, isError ? /* @__PURE__ */ React41.createElement(React41.Fragment, null, ADMIN_FAILED_CONTENT_TEXT_PT1, " ", /* @__PURE__ */ React41.createElement("br", null), " ", ADMIN_FAILED_CONTENT_TEXT_PT2) : ADMIN_CONTENT_TEXT)), /* @__PURE__ */ React41.createElement(DialogActions, null, /* @__PURE__ */ React41.createElement(Button3, { size: "medium", color: "secondary", onClick: () => onClose(false) }, __12("Cancel", "elementor")), /* @__PURE__ */ React41.createElement(
2514
2605
  Button3,
2515
2606
  {
2516
2607
  size: "medium",
@@ -2519,16 +2610,16 @@ var AdminDialog = ({ open, onClose, handleEnable, isPending, isError }) => /* @_
2519
2610
  color: "primary",
2520
2611
  disabled: isPending
2521
2612
  },
2522
- isPending ? /* @__PURE__ */ React39.createElement(CircularProgress2, { size: 24 }) : __12("Enable", "elementor")
2613
+ isPending ? /* @__PURE__ */ React41.createElement(CircularProgress2, { size: 24 }) : __12("Enable", "elementor")
2523
2614
  )));
2524
- var NonAdminDialog = ({ open, onClose }) => /* @__PURE__ */ React39.createElement(Dialog, { open, maxWidth: "sm", onClose: () => onClose(false) }, /* @__PURE__ */ React39.createElement(DialogHeader, { logo: false }, /* @__PURE__ */ React39.createElement(DialogTitle, null, NON_ADMIN_TITLE_TEXT)), /* @__PURE__ */ React39.createElement(Divider3, null), /* @__PURE__ */ React39.createElement(DialogContent, null, /* @__PURE__ */ React39.createElement(DialogContentText, null, NON_ADMIN_CONTENT_TEXT)), /* @__PURE__ */ React39.createElement(DialogActions, null, /* @__PURE__ */ React39.createElement(Button3, { size: "medium", onClick: () => onClose(false), variant: "contained", color: "primary" }, __12("Got it", "elementor"))));
2615
+ var NonAdminDialog = ({ open, onClose }) => /* @__PURE__ */ React41.createElement(Dialog, { open, maxWidth: "sm", onClose: () => onClose(false) }, /* @__PURE__ */ React41.createElement(DialogHeader, { logo: false }, /* @__PURE__ */ React41.createElement(DialogTitle, null, NON_ADMIN_TITLE_TEXT)), /* @__PURE__ */ React41.createElement(Divider3, null), /* @__PURE__ */ React41.createElement(DialogContent, null, /* @__PURE__ */ React41.createElement(DialogContentText, null, NON_ADMIN_CONTENT_TEXT)), /* @__PURE__ */ React41.createElement(DialogActions, null, /* @__PURE__ */ React41.createElement(Button3, { size: "medium", onClick: () => onClose(false), variant: "contained", color: "primary" }, __12("Got it", "elementor"))));
2525
2616
 
2526
2617
  // src/controls/svg-media-control.tsx
2527
2618
  var TILE_SIZE = 8;
2528
2619
  var TILE_WHITE = "transparent";
2529
2620
  var TILE_BLACK = "#c1c1c1";
2530
2621
  var TILES_GRADIENT_FORMULA = `linear-gradient(45deg, ${TILE_BLACK} 25%, ${TILE_WHITE} 0, ${TILE_WHITE} 75%, ${TILE_BLACK} 0, ${TILE_BLACK})`;
2531
- var StyledCard = styled5(Card2)`
2622
+ var StyledCard = styled4(Card2)`
2532
2623
  background-color: white;
2533
2624
  background-image: ${TILES_GRADIENT_FORMULA}, ${TILES_GRADIENT_FORMULA};
2534
2625
  background-size: ${TILE_SIZE}px ${TILE_SIZE}px;
@@ -2537,7 +2628,7 @@ var StyledCard = styled5(Card2)`
2537
2628
  ${TILE_SIZE / 2}px ${TILE_SIZE / 2}px;
2538
2629
  border: none;
2539
2630
  `;
2540
- var StyledCardMediaContainer = styled5(Stack13)`
2631
+ var StyledCardMediaContainer = styled4(Stack13)`
2541
2632
  position: relative;
2542
2633
  height: 140px;
2543
2634
  object-fit: contain;
@@ -2554,7 +2645,7 @@ var SvgMediaControl = createControl(() => {
2554
2645
  const { data: attachment, isFetching } = useWpMediaAttachment2(id?.value || null);
2555
2646
  const src = attachment?.url ?? url?.value ?? null;
2556
2647
  const { data: allowSvgUpload } = useUnfilteredFilesUpload();
2557
- const [unfilteredModalOpenState, setUnfilteredModalOpenState] = useState9(false);
2648
+ const [unfilteredModalOpenState, setUnfilteredModalOpenState] = useState10(false);
2558
2649
  const { open } = useWpMediaFrame2({
2559
2650
  mediaTypes: ["svg"],
2560
2651
  multiple: false,
@@ -2582,7 +2673,7 @@ var SvgMediaControl = createControl(() => {
2582
2673
  open(openOptions);
2583
2674
  }
2584
2675
  };
2585
- return /* @__PURE__ */ React40.createElement(Stack13, { gap: 1 }, /* @__PURE__ */ React40.createElement(EnableUnfilteredModal, { open: unfilteredModalOpenState, onClose: onCloseUnfilteredModal }), /* @__PURE__ */ React40.createElement(ControlFormLabel, null, " ", __13("SVG", "elementor"), " "), /* @__PURE__ */ React40.createElement(ControlActions, null, /* @__PURE__ */ React40.createElement(StyledCard, { variant: "outlined" }, /* @__PURE__ */ React40.createElement(StyledCardMediaContainer, null, isFetching ? /* @__PURE__ */ React40.createElement(CircularProgress3, { role: "progressbar" }) : /* @__PURE__ */ React40.createElement(
2676
+ return /* @__PURE__ */ React42.createElement(Stack13, { gap: 1 }, /* @__PURE__ */ React42.createElement(EnableUnfilteredModal, { open: unfilteredModalOpenState, onClose: onCloseUnfilteredModal }), /* @__PURE__ */ React42.createElement(ControlFormLabel, null, " ", __13("SVG", "elementor"), " "), /* @__PURE__ */ React42.createElement(ControlActions, null, /* @__PURE__ */ React42.createElement(StyledCard, { variant: "outlined" }, /* @__PURE__ */ React42.createElement(StyledCardMediaContainer, null, isFetching ? /* @__PURE__ */ React42.createElement(CircularProgress3, { role: "progressbar" }) : /* @__PURE__ */ React42.createElement(
2586
2677
  CardMedia2,
2587
2678
  {
2588
2679
  component: "img",
@@ -2590,7 +2681,7 @@ var SvgMediaControl = createControl(() => {
2590
2681
  alt: __13("Preview SVG", "elementor"),
2591
2682
  sx: { maxHeight: "140px", width: "50px" }
2592
2683
  }
2593
- )), /* @__PURE__ */ React40.createElement(
2684
+ )), /* @__PURE__ */ React42.createElement(
2594
2685
  CardOverlay2,
2595
2686
  {
2596
2687
  sx: {
@@ -2599,7 +2690,7 @@ var SvgMediaControl = createControl(() => {
2599
2690
  }
2600
2691
  }
2601
2692
  },
2602
- /* @__PURE__ */ React40.createElement(Stack13, { gap: 1 }, /* @__PURE__ */ React40.createElement(
2693
+ /* @__PURE__ */ React42.createElement(Stack13, { gap: 1 }, /* @__PURE__ */ React42.createElement(
2603
2694
  Button4,
2604
2695
  {
2605
2696
  size: "tiny",
@@ -2608,13 +2699,13 @@ var SvgMediaControl = createControl(() => {
2608
2699
  onClick: () => handleClick(MODE_BROWSE)
2609
2700
  },
2610
2701
  __13("Select SVG", "elementor")
2611
- ), /* @__PURE__ */ React40.createElement(
2702
+ ), /* @__PURE__ */ React42.createElement(
2612
2703
  Button4,
2613
2704
  {
2614
2705
  size: "tiny",
2615
2706
  variant: "text",
2616
2707
  color: "inherit",
2617
- startIcon: /* @__PURE__ */ React40.createElement(UploadIcon2, null),
2708
+ startIcon: /* @__PURE__ */ React42.createElement(UploadIcon2, null),
2618
2709
  onClick: () => handleClick(MODE_UPLOAD)
2619
2710
  },
2620
2711
  __13("Upload", "elementor")
@@ -2623,21 +2714,21 @@ var SvgMediaControl = createControl(() => {
2623
2714
  });
2624
2715
 
2625
2716
  // src/controls/background-control/background-control.tsx
2626
- import * as React47 from "react";
2717
+ import * as React49 from "react";
2627
2718
  import { backgroundPropTypeUtil } from "@elementor/editor-props";
2628
- import { isExperimentActive as isExperimentActive3 } from "@elementor/editor-v1-adapters";
2719
+ import { isExperimentActive as isExperimentActive4 } from "@elementor/editor-v1-adapters";
2629
2720
  import { Grid as Grid15 } from "@elementor/ui";
2630
2721
  import { __ as __19 } from "@wordpress/i18n";
2631
2722
 
2632
2723
  // src/controls/background-control/background-overlay/background-overlay-repeater-control.tsx
2633
- import * as React46 from "react";
2724
+ import * as React48 from "react";
2634
2725
  import {
2635
2726
  backgroundColorOverlayPropTypeUtil as backgroundColorOverlayPropTypeUtil2,
2636
2727
  backgroundImageOverlayPropTypeUtil as backgroundImageOverlayPropTypeUtil2,
2637
2728
  backgroundOverlayPropTypeUtil,
2638
2729
  colorPropTypeUtil as colorPropTypeUtil3
2639
2730
  } from "@elementor/editor-props";
2640
- import { Box as Box6, CardMedia as CardMedia3, Grid as Grid14, styled as styled6, Tab, TabPanel, Tabs, UnstableColorIndicator as UnstableColorIndicator2 } from "@elementor/ui";
2731
+ import { Box as Box6, CardMedia as CardMedia3, Grid as Grid14, styled as styled5, Tab, TabPanel, Tabs, UnstableColorIndicator as UnstableColorIndicator2 } from "@elementor/ui";
2641
2732
  import { useWpMediaAttachment as useWpMediaAttachment3 } from "@elementor/wp-media";
2642
2733
  import { __ as __18 } from "@wordpress/i18n";
2643
2734
 
@@ -2646,14 +2737,14 @@ import { parseEnv } from "@elementor/env";
2646
2737
  var { env } = parseEnv("@elementor/editor-controls");
2647
2738
 
2648
2739
  // src/controls/background-control/background-gradient-color-control.tsx
2649
- import * as React41 from "react";
2740
+ import * as React43 from "react";
2650
2741
  import {
2651
2742
  backgroundGradientOverlayPropTypeUtil,
2652
2743
  colorPropTypeUtil as colorPropTypeUtil2,
2653
2744
  colorStopPropTypeUtil,
2654
2745
  gradientColorStopPropTypeUtil,
2655
2746
  numberPropTypeUtil as numberPropTypeUtil3,
2656
- stringPropTypeUtil as stringPropTypeUtil9
2747
+ stringPropTypeUtil as stringPropTypeUtil8
2657
2748
  } from "@elementor/editor-props";
2658
2749
  import { UnstableGradientBox } from "@elementor/ui";
2659
2750
  var BackgroundGradientColorControl = createControl(() => {
@@ -2661,13 +2752,13 @@ var BackgroundGradientColorControl = createControl(() => {
2661
2752
  const handleChange = (newValue) => {
2662
2753
  const transformedValue = createTransformableValue(newValue);
2663
2754
  if (transformedValue.positions) {
2664
- transformedValue.positions = stringPropTypeUtil9.create(newValue.positions.join(" "));
2755
+ transformedValue.positions = stringPropTypeUtil8.create(newValue.positions.join(" "));
2665
2756
  }
2666
2757
  setValue(transformedValue);
2667
2758
  };
2668
2759
  const createTransformableValue = (newValue) => ({
2669
2760
  ...newValue,
2670
- type: stringPropTypeUtil9.create(newValue.type),
2761
+ type: stringPropTypeUtil8.create(newValue.type),
2671
2762
  angle: numberPropTypeUtil3.create(newValue.angle),
2672
2763
  stops: gradientColorStopPropTypeUtil.create(
2673
2764
  newValue.stops.map(
@@ -2693,7 +2784,7 @@ var BackgroundGradientColorControl = createControl(() => {
2693
2784
  positions: positions?.value.split(" ")
2694
2785
  };
2695
2786
  };
2696
- return /* @__PURE__ */ React41.createElement(ControlActions, null, /* @__PURE__ */ React41.createElement(
2787
+ return /* @__PURE__ */ React43.createElement(ControlActions, null, /* @__PURE__ */ React43.createElement(
2697
2788
  UnstableGradientBox,
2698
2789
  {
2699
2790
  sx: { width: "auto", padding: 1.5 },
@@ -2703,7 +2794,7 @@ var BackgroundGradientColorControl = createControl(() => {
2703
2794
  ));
2704
2795
  });
2705
2796
  var initialBackgroundGradientOverlay = backgroundGradientOverlayPropTypeUtil.create({
2706
- type: stringPropTypeUtil9.create("linear"),
2797
+ type: stringPropTypeUtil8.create("linear"),
2707
2798
  angle: numberPropTypeUtil3.create(180),
2708
2799
  stops: gradientColorStopPropTypeUtil.create([
2709
2800
  colorStopPropTypeUtil.create({
@@ -2718,7 +2809,7 @@ var initialBackgroundGradientOverlay = backgroundGradientOverlayPropTypeUtil.cre
2718
2809
  });
2719
2810
 
2720
2811
  // src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-attachment.tsx
2721
- import * as React42 from "react";
2812
+ import * as React44 from "react";
2722
2813
  import { PinIcon, PinnedOffIcon } from "@elementor/icons";
2723
2814
  import { Grid as Grid10 } from "@elementor/ui";
2724
2815
  import { __ as __14 } from "@wordpress/i18n";
@@ -2726,23 +2817,24 @@ var attachmentControlOptions = [
2726
2817
  {
2727
2818
  value: "fixed",
2728
2819
  label: __14("Fixed", "elementor"),
2729
- renderContent: ({ size }) => /* @__PURE__ */ React42.createElement(PinIcon, { fontSize: size }),
2820
+ renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(PinIcon, { fontSize: size }),
2730
2821
  showTooltip: true
2731
2822
  },
2732
2823
  {
2733
2824
  value: "scroll",
2734
2825
  label: __14("Scroll", "elementor"),
2735
- renderContent: ({ size }) => /* @__PURE__ */ React42.createElement(PinnedOffIcon, { fontSize: size }),
2826
+ renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(PinnedOffIcon, { fontSize: size }),
2736
2827
  showTooltip: true
2737
2828
  }
2738
2829
  ];
2739
2830
  var BackgroundImageOverlayAttachment = () => {
2740
- return /* @__PURE__ */ React42.createElement(PopoverGridContainer, null, /* @__PURE__ */ React42.createElement(Grid10, { item: true, xs: 6 }, /* @__PURE__ */ React42.createElement(ControlFormLabel, null, __14("Attachment", "elementor"))), /* @__PURE__ */ React42.createElement(Grid10, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end", overflow: "hidden" } }, /* @__PURE__ */ React42.createElement(ToggleControl, { options: attachmentControlOptions })));
2831
+ return /* @__PURE__ */ React44.createElement(PopoverGridContainer, null, /* @__PURE__ */ React44.createElement(Grid10, { item: true, xs: 6 }, /* @__PURE__ */ React44.createElement(ControlFormLabel, null, __14("Attachment", "elementor"))), /* @__PURE__ */ React44.createElement(Grid10, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end", overflow: "hidden" } }, /* @__PURE__ */ React44.createElement(ToggleControl, { options: attachmentControlOptions })));
2741
2832
  };
2742
2833
 
2743
2834
  // src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-position.tsx
2744
- import * as React43 from "react";
2745
- import { backgroundImagePositionOffsetPropTypeUtil, stringPropTypeUtil as stringPropTypeUtil10 } from "@elementor/editor-props";
2835
+ import * as React45 from "react";
2836
+ import { useRef as useRef8 } from "react";
2837
+ import { backgroundImagePositionOffsetPropTypeUtil, stringPropTypeUtil as stringPropTypeUtil9 } from "@elementor/editor-props";
2746
2838
  import { MenuListItem as MenuListItem4 } from "@elementor/editor-ui";
2747
2839
  import { LetterXIcon, LetterYIcon } from "@elementor/icons";
2748
2840
  import { Grid as Grid11, Select as Select3 } from "@elementor/ui";
@@ -2761,8 +2853,9 @@ var backgroundPositionOptions = [
2761
2853
  ];
2762
2854
  var BackgroundImageOverlayPosition = () => {
2763
2855
  const backgroundImageOffsetContext = useBoundProp(backgroundImagePositionOffsetPropTypeUtil);
2764
- const stringPropContext = useBoundProp(stringPropTypeUtil10);
2856
+ const stringPropContext = useBoundProp(stringPropTypeUtil9);
2765
2857
  const isCustom = !!backgroundImageOffsetContext.value;
2858
+ const rowRef = useRef8();
2766
2859
  const handlePositionChange = (event) => {
2767
2860
  const value = event.target.value || null;
2768
2861
  if (value === "custom") {
@@ -2771,7 +2864,7 @@ var BackgroundImageOverlayPosition = () => {
2771
2864
  stringPropContext.setValue(value);
2772
2865
  }
2773
2866
  };
2774
- return /* @__PURE__ */ React43.createElement(Grid11, { container: true, spacing: 1.5 }, /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 12 }, /* @__PURE__ */ React43.createElement(PopoverGridContainer, null, /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React43.createElement(ControlFormLabel, null, __15("Position", "elementor"))), /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end", overflow: "hidden" } }, /* @__PURE__ */ React43.createElement(
2867
+ return /* @__PURE__ */ React45.createElement(Grid11, { container: true, spacing: 1.5 }, /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 12 }, /* @__PURE__ */ React45.createElement(PopoverGridContainer, null, /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(ControlFormLabel, null, __15("Position", "elementor"))), /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end", overflow: "hidden" } }, /* @__PURE__ */ React45.createElement(
2775
2868
  Select3,
2776
2869
  {
2777
2870
  fullWidth: true,
@@ -2780,12 +2873,24 @@ var BackgroundImageOverlayPosition = () => {
2780
2873
  disabled: stringPropContext.disabled,
2781
2874
  value: (backgroundImageOffsetContext.value ? "custom" : stringPropContext.value) ?? ""
2782
2875
  },
2783
- backgroundPositionOptions.map(({ label, value }) => /* @__PURE__ */ React43.createElement(MenuListItem4, { key: value, value: value ?? "" }, label))
2784
- )))), isCustom ? /* @__PURE__ */ React43.createElement(PropProvider, { ...backgroundImageOffsetContext }, /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 12 }, /* @__PURE__ */ React43.createElement(Grid11, { container: true, spacing: 1.5 }, /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React43.createElement(PropKeyProvider, { bind: "x" }, /* @__PURE__ */ React43.createElement(SizeControl, { startIcon: /* @__PURE__ */ React43.createElement(LetterXIcon, { fontSize: "tiny" }) }))), /* @__PURE__ */ React43.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React43.createElement(PropKeyProvider, { bind: "y" }, /* @__PURE__ */ React43.createElement(SizeControl, { startIcon: /* @__PURE__ */ React43.createElement(LetterYIcon, { fontSize: "tiny" }) })))))) : null);
2876
+ backgroundPositionOptions.map(({ label, value }) => /* @__PURE__ */ React45.createElement(MenuListItem4, { key: value, value: value ?? "" }, label))
2877
+ )))), isCustom ? /* @__PURE__ */ React45.createElement(PropProvider, { ...backgroundImageOffsetContext }, /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 12 }, /* @__PURE__ */ React45.createElement(Grid11, { container: true, spacing: 1.5, ref: rowRef }, /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(PropKeyProvider, { bind: "x" }, /* @__PURE__ */ React45.createElement(
2878
+ SizeControl,
2879
+ {
2880
+ startIcon: /* @__PURE__ */ React45.createElement(LetterXIcon, { fontSize: "tiny" }),
2881
+ anchorRef: rowRef
2882
+ }
2883
+ ))), /* @__PURE__ */ React45.createElement(Grid11, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(PropKeyProvider, { bind: "y" }, /* @__PURE__ */ React45.createElement(
2884
+ SizeControl,
2885
+ {
2886
+ startIcon: /* @__PURE__ */ React45.createElement(LetterYIcon, { fontSize: "tiny" }),
2887
+ anchorRef: rowRef
2888
+ }
2889
+ )))))) : null);
2785
2890
  };
2786
2891
 
2787
2892
  // src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-repeat.tsx
2788
- import * as React44 from "react";
2893
+ import * as React46 from "react";
2789
2894
  import { DotsHorizontalIcon, DotsVerticalIcon, GridDotsIcon, XIcon as XIcon3 } from "@elementor/icons";
2790
2895
  import { Grid as Grid12 } from "@elementor/ui";
2791
2896
  import { __ as __16 } from "@wordpress/i18n";
@@ -2793,42 +2898,43 @@ var repeatControlOptions = [
2793
2898
  {
2794
2899
  value: "repeat",
2795
2900
  label: __16("Repeat", "elementor"),
2796
- renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(GridDotsIcon, { fontSize: size }),
2901
+ renderContent: ({ size }) => /* @__PURE__ */ React46.createElement(GridDotsIcon, { fontSize: size }),
2797
2902
  showTooltip: true
2798
2903
  },
2799
2904
  {
2800
2905
  value: "repeat-x",
2801
2906
  label: __16("Repeat-x", "elementor"),
2802
- renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(DotsHorizontalIcon, { fontSize: size }),
2907
+ renderContent: ({ size }) => /* @__PURE__ */ React46.createElement(DotsHorizontalIcon, { fontSize: size }),
2803
2908
  showTooltip: true
2804
2909
  },
2805
2910
  {
2806
2911
  value: "repeat-y",
2807
2912
  label: __16("Repeat-y", "elementor"),
2808
- renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(DotsVerticalIcon, { fontSize: size }),
2913
+ renderContent: ({ size }) => /* @__PURE__ */ React46.createElement(DotsVerticalIcon, { fontSize: size }),
2809
2914
  showTooltip: true
2810
2915
  },
2811
2916
  {
2812
2917
  value: "no-repeat",
2813
2918
  label: __16("No-repeat", "elementor"),
2814
- renderContent: ({ size }) => /* @__PURE__ */ React44.createElement(XIcon3, { fontSize: size }),
2919
+ renderContent: ({ size }) => /* @__PURE__ */ React46.createElement(XIcon3, { fontSize: size }),
2815
2920
  showTooltip: true
2816
2921
  }
2817
2922
  ];
2818
2923
  var BackgroundImageOverlayRepeat = () => {
2819
- return /* @__PURE__ */ React44.createElement(PopoverGridContainer, null, /* @__PURE__ */ React44.createElement(Grid12, { item: true, xs: 6 }, /* @__PURE__ */ React44.createElement(ControlFormLabel, null, __16("Repeat", "elementor"))), /* @__PURE__ */ React44.createElement(Grid12, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React44.createElement(ToggleControl, { options: repeatControlOptions })));
2924
+ return /* @__PURE__ */ React46.createElement(PopoverGridContainer, null, /* @__PURE__ */ React46.createElement(Grid12, { item: true, xs: 6 }, /* @__PURE__ */ React46.createElement(ControlFormLabel, null, __16("Repeat", "elementor"))), /* @__PURE__ */ React46.createElement(Grid12, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React46.createElement(ToggleControl, { options: repeatControlOptions })));
2820
2925
  };
2821
2926
 
2822
2927
  // src/controls/background-control/background-overlay/background-image-overlay/background-image-overlay-size.tsx
2823
- import * as React45 from "react";
2824
- import { backgroundImageSizeScalePropTypeUtil, stringPropTypeUtil as stringPropTypeUtil11 } from "@elementor/editor-props";
2928
+ import * as React47 from "react";
2929
+ import { useRef as useRef9 } from "react";
2930
+ import { backgroundImageSizeScalePropTypeUtil, stringPropTypeUtil as stringPropTypeUtil10 } from "@elementor/editor-props";
2825
2931
  import {
2826
2932
  ArrowBarBothIcon,
2827
2933
  ArrowsMaximizeIcon,
2828
2934
  ArrowsMoveHorizontalIcon as ArrowsMoveHorizontalIcon2,
2829
2935
  ArrowsMoveVerticalIcon as ArrowsMoveVerticalIcon2,
2830
2936
  LetterAIcon,
2831
- PencilIcon
2937
+ PencilIcon as PencilIcon2
2832
2938
  } from "@elementor/icons";
2833
2939
  import { Grid as Grid13 } from "@elementor/ui";
2834
2940
  import { __ as __17 } from "@wordpress/i18n";
@@ -2836,32 +2942,33 @@ var sizeControlOptions = [
2836
2942
  {
2837
2943
  value: "auto",
2838
2944
  label: __17("Auto", "elementor"),
2839
- renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(LetterAIcon, { fontSize: size }),
2945
+ renderContent: ({ size }) => /* @__PURE__ */ React47.createElement(LetterAIcon, { fontSize: size }),
2840
2946
  showTooltip: true
2841
2947
  },
2842
2948
  {
2843
2949
  value: "cover",
2844
2950
  label: __17("Cover", "elementor"),
2845
- renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(ArrowsMaximizeIcon, { fontSize: size }),
2951
+ renderContent: ({ size }) => /* @__PURE__ */ React47.createElement(ArrowsMaximizeIcon, { fontSize: size }),
2846
2952
  showTooltip: true
2847
2953
  },
2848
2954
  {
2849
2955
  value: "contain",
2850
2956
  label: __17("Contain", "elementor"),
2851
- renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(ArrowBarBothIcon, { fontSize: size }),
2957
+ renderContent: ({ size }) => /* @__PURE__ */ React47.createElement(ArrowBarBothIcon, { fontSize: size }),
2852
2958
  showTooltip: true
2853
2959
  },
2854
2960
  {
2855
2961
  value: "custom",
2856
2962
  label: __17("Custom", "elementor"),
2857
- renderContent: ({ size }) => /* @__PURE__ */ React45.createElement(PencilIcon, { fontSize: size }),
2963
+ renderContent: ({ size }) => /* @__PURE__ */ React47.createElement(PencilIcon2, { fontSize: size }),
2858
2964
  showTooltip: true
2859
2965
  }
2860
2966
  ];
2861
2967
  var BackgroundImageOverlaySize = () => {
2862
2968
  const backgroundImageScaleContext = useBoundProp(backgroundImageSizeScalePropTypeUtil);
2863
- const stringPropContext = useBoundProp(stringPropTypeUtil11);
2969
+ const stringPropContext = useBoundProp(stringPropTypeUtil10);
2864
2970
  const isCustom = !!backgroundImageScaleContext.value;
2971
+ const rowRef = useRef9();
2865
2972
  const handleSizeChange = (size) => {
2866
2973
  if (size === "custom") {
2867
2974
  backgroundImageScaleContext.setValue({ width: null, height: null });
@@ -2869,7 +2976,7 @@ var BackgroundImageOverlaySize = () => {
2869
2976
  stringPropContext.setValue(size);
2870
2977
  }
2871
2978
  };
2872
- return /* @__PURE__ */ React45.createElement(Grid13, { container: true, spacing: 1.5 }, /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 12 }, /* @__PURE__ */ React45.createElement(PopoverGridContainer, null, /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(ControlFormLabel, null, __17("Size", "elementor"))), /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React45.createElement(
2979
+ return /* @__PURE__ */ React47.createElement(Grid13, { container: true, spacing: 1.5 }, /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 12 }, /* @__PURE__ */ React47.createElement(PopoverGridContainer, null, /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React47.createElement(ControlFormLabel, null, __17("Size", "elementor"))), /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 6, sx: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React47.createElement(
2873
2980
  ControlToggleButtonGroup,
2874
2981
  {
2875
2982
  exclusive: true,
@@ -2878,23 +2985,25 @@ var BackgroundImageOverlaySize = () => {
2878
2985
  disabled: stringPropContext.disabled,
2879
2986
  value: backgroundImageScaleContext.value ? "custom" : stringPropContext.value
2880
2987
  }
2881
- )))), isCustom ? /* @__PURE__ */ React45.createElement(PropProvider, { ...backgroundImageScaleContext }, /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 12 }, /* @__PURE__ */ React45.createElement(PopoverGridContainer, null, /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(PropKeyProvider, { bind: "width" }, /* @__PURE__ */ React45.createElement(
2988
+ )))), isCustom ? /* @__PURE__ */ React47.createElement(PropProvider, { ...backgroundImageScaleContext }, /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 12, ref: rowRef }, /* @__PURE__ */ React47.createElement(PopoverGridContainer, null, /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React47.createElement(PropKeyProvider, { bind: "width" }, /* @__PURE__ */ React47.createElement(
2882
2989
  SizeControl,
2883
2990
  {
2884
- startIcon: /* @__PURE__ */ React45.createElement(ArrowsMoveHorizontalIcon2, { fontSize: "tiny" }),
2885
- extendedValues: ["auto"]
2991
+ startIcon: /* @__PURE__ */ React47.createElement(ArrowsMoveHorizontalIcon2, { fontSize: "tiny" }),
2992
+ extendedOptions: ["auto"],
2993
+ anchorRef: rowRef
2886
2994
  }
2887
- ))), /* @__PURE__ */ React45.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React45.createElement(PropKeyProvider, { bind: "height" }, /* @__PURE__ */ React45.createElement(
2995
+ ))), /* @__PURE__ */ React47.createElement(Grid13, { item: true, xs: 6 }, /* @__PURE__ */ React47.createElement(PropKeyProvider, { bind: "height" }, /* @__PURE__ */ React47.createElement(
2888
2996
  SizeControl,
2889
2997
  {
2890
- startIcon: /* @__PURE__ */ React45.createElement(ArrowsMoveVerticalIcon2, { fontSize: "tiny" }),
2891
- extendedValues: ["auto"]
2998
+ startIcon: /* @__PURE__ */ React47.createElement(ArrowsMoveVerticalIcon2, { fontSize: "tiny" }),
2999
+ extendedOptions: ["auto"],
3000
+ anchorRef: rowRef
2892
3001
  }
2893
3002
  )))))) : null);
2894
3003
  };
2895
3004
 
2896
3005
  // src/controls/background-control/background-overlay/use-background-tabs-history.ts
2897
- import { useRef as useRef5 } from "react";
3006
+ import { useRef as useRef10 } from "react";
2898
3007
  import {
2899
3008
  backgroundColorOverlayPropTypeUtil,
2900
3009
  backgroundGradientOverlayPropTypeUtil as backgroundGradientOverlayPropTypeUtil2,
@@ -2919,7 +3028,7 @@ var useBackgroundTabsHistory = ({
2919
3028
  return "image";
2920
3029
  };
2921
3030
  const { getTabsProps, getTabProps, getTabPanelProps } = useTabs(getCurrentOverlayType());
2922
- const valuesHistory = useRef5({
3031
+ const valuesHistory = useRef10({
2923
3032
  image: initialBackgroundImageOverlay,
2924
3033
  color: initialBackgroundColorOverlay2,
2925
3034
  gradient: initialBackgroundGradientOverlay2
@@ -2994,7 +3103,7 @@ var backgroundResolutionOptions = [
2994
3103
  ];
2995
3104
  var BackgroundOverlayRepeaterControl = createControl(() => {
2996
3105
  const { propType, value: overlayValues, setValue, disabled } = useBoundProp(backgroundOverlayPropTypeUtil);
2997
- return /* @__PURE__ */ React46.createElement(PropProvider, { propType, value: overlayValues, setValue, disabled }, /* @__PURE__ */ React46.createElement(
3106
+ return /* @__PURE__ */ React48.createElement(PropProvider, { propType, value: overlayValues, setValue, disabled }, /* @__PURE__ */ React48.createElement(
2998
3107
  Repeater,
2999
3108
  {
3000
3109
  openOnAdd: true,
@@ -3012,7 +3121,7 @@ var BackgroundOverlayRepeaterControl = createControl(() => {
3012
3121
  ));
3013
3122
  });
3014
3123
  var ItemContent2 = ({ anchorEl = null, bind }) => {
3015
- return /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React46.createElement(Content2, { anchorEl }));
3124
+ return /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React48.createElement(Content2, { anchorEl }));
3016
3125
  };
3017
3126
  var Content2 = ({ anchorEl }) => {
3018
3127
  const { getTabsProps, getTabProps, getTabPanelProps } = useBackgroundTabsHistory({
@@ -3020,7 +3129,7 @@ var Content2 = ({ anchorEl }) => {
3020
3129
  color: initialBackgroundColorOverlay.value,
3021
3130
  gradient: initialBackgroundGradientOverlay.value
3022
3131
  });
3023
- return /* @__PURE__ */ React46.createElement(Box6, { sx: { width: "100%" } }, /* @__PURE__ */ React46.createElement(Box6, { sx: { borderBottom: 1, borderColor: "divider" } }, /* @__PURE__ */ React46.createElement(
3132
+ return /* @__PURE__ */ React48.createElement(Box6, { sx: { width: "100%" } }, /* @__PURE__ */ React48.createElement(Box6, { sx: { borderBottom: 1, borderColor: "divider" } }, /* @__PURE__ */ React48.createElement(
3024
3133
  Tabs,
3025
3134
  {
3026
3135
  size: "small",
@@ -3028,19 +3137,19 @@ var Content2 = ({ anchorEl }) => {
3028
3137
  ...getTabsProps(),
3029
3138
  "aria-label": __18("Background Overlay", "elementor")
3030
3139
  },
3031
- /* @__PURE__ */ React46.createElement(Tab, { label: __18("Image", "elementor"), ...getTabProps("image") }),
3032
- /* @__PURE__ */ React46.createElement(Tab, { label: __18("Gradient", "elementor"), ...getTabProps("gradient") }),
3033
- /* @__PURE__ */ React46.createElement(Tab, { label: __18("Color", "elementor"), ...getTabProps("color") })
3034
- )), /* @__PURE__ */ React46.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("image") }, /* @__PURE__ */ React46.createElement(PopoverContent, null, /* @__PURE__ */ React46.createElement(ImageOverlayContent, null))), /* @__PURE__ */ React46.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("gradient") }, /* @__PURE__ */ React46.createElement(BackgroundGradientColorControl, null)), /* @__PURE__ */ React46.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("color") }, /* @__PURE__ */ React46.createElement(PopoverContent, null, /* @__PURE__ */ React46.createElement(ColorOverlayContent, { anchorEl }))));
3140
+ /* @__PURE__ */ React48.createElement(Tab, { label: __18("Image", "elementor"), ...getTabProps("image") }),
3141
+ /* @__PURE__ */ React48.createElement(Tab, { label: __18("Gradient", "elementor"), ...getTabProps("gradient") }),
3142
+ /* @__PURE__ */ React48.createElement(Tab, { label: __18("Color", "elementor"), ...getTabProps("color") })
3143
+ )), /* @__PURE__ */ React48.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("image") }, /* @__PURE__ */ React48.createElement(PopoverContent, null, /* @__PURE__ */ React48.createElement(ImageOverlayContent, null))), /* @__PURE__ */ React48.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("gradient") }, /* @__PURE__ */ React48.createElement(BackgroundGradientColorControl, null)), /* @__PURE__ */ React48.createElement(TabPanel, { sx: { p: 1.5 }, ...getTabPanelProps("color") }, /* @__PURE__ */ React48.createElement(PopoverContent, null, /* @__PURE__ */ React48.createElement(ColorOverlayContent, { anchorEl }))));
3035
3144
  };
3036
3145
  var ItemIcon2 = ({ value }) => {
3037
3146
  switch (value.$$type) {
3038
3147
  case "background-image-overlay":
3039
- return /* @__PURE__ */ React46.createElement(ItemIconImage, { value });
3148
+ return /* @__PURE__ */ React48.createElement(ItemIconImage, { value });
3040
3149
  case "background-color-overlay":
3041
- return /* @__PURE__ */ React46.createElement(ItemIconColor, { value });
3150
+ return /* @__PURE__ */ React48.createElement(ItemIconColor, { value });
3042
3151
  case "background-gradient-overlay":
3043
- return /* @__PURE__ */ React46.createElement(ItemIconGradient, { value });
3152
+ return /* @__PURE__ */ React48.createElement(ItemIconGradient, { value });
3044
3153
  default:
3045
3154
  return null;
3046
3155
  }
@@ -3053,11 +3162,11 @@ var extractColorFrom = (prop) => {
3053
3162
  };
3054
3163
  var ItemIconColor = ({ value: prop }) => {
3055
3164
  const color = extractColorFrom(prop);
3056
- return /* @__PURE__ */ React46.createElement(StyledUnstableColorIndicator, { size: "inherit", component: "span", value: color });
3165
+ return /* @__PURE__ */ React48.createElement(StyledUnstableColorIndicator, { size: "inherit", component: "span", value: color });
3057
3166
  };
3058
3167
  var ItemIconImage = ({ value }) => {
3059
3168
  const { imageUrl } = useImage(value);
3060
- return /* @__PURE__ */ React46.createElement(
3169
+ return /* @__PURE__ */ React48.createElement(
3061
3170
  CardMedia3,
3062
3171
  {
3063
3172
  image: imageUrl,
@@ -3072,49 +3181,49 @@ var ItemIconImage = ({ value }) => {
3072
3181
  };
3073
3182
  var ItemIconGradient = ({ value }) => {
3074
3183
  const gradient = getGradientValue(value);
3075
- return /* @__PURE__ */ React46.createElement(StyledUnstableColorIndicator, { size: "inherit", component: "span", value: gradient });
3184
+ return /* @__PURE__ */ React48.createElement(StyledUnstableColorIndicator, { size: "inherit", component: "span", value: gradient });
3076
3185
  };
3077
3186
  var ItemLabel2 = ({ value }) => {
3078
3187
  switch (value.$$type) {
3079
3188
  case "background-image-overlay":
3080
- return /* @__PURE__ */ React46.createElement(ItemLabelImage, { value });
3189
+ return /* @__PURE__ */ React48.createElement(ItemLabelImage, { value });
3081
3190
  case "background-color-overlay":
3082
- return /* @__PURE__ */ React46.createElement(ItemLabelColor, { value });
3191
+ return /* @__PURE__ */ React48.createElement(ItemLabelColor, { value });
3083
3192
  case "background-gradient-overlay":
3084
- return /* @__PURE__ */ React46.createElement(ItemLabelGradient, { value });
3193
+ return /* @__PURE__ */ React48.createElement(ItemLabelGradient, { value });
3085
3194
  default:
3086
3195
  return null;
3087
3196
  }
3088
3197
  };
3089
3198
  var ItemLabelColor = ({ value: prop }) => {
3090
3199
  const color = extractColorFrom(prop);
3091
- return /* @__PURE__ */ React46.createElement("span", null, color);
3200
+ return /* @__PURE__ */ React48.createElement("span", null, color);
3092
3201
  };
3093
3202
  var ItemLabelImage = ({ value }) => {
3094
3203
  const { imageTitle } = useImage(value);
3095
- return /* @__PURE__ */ React46.createElement("span", null, imageTitle);
3204
+ return /* @__PURE__ */ React48.createElement("span", null, imageTitle);
3096
3205
  };
3097
3206
  var ItemLabelGradient = ({ value }) => {
3098
3207
  if (value.value.type.value === "linear") {
3099
- return /* @__PURE__ */ React46.createElement("span", null, __18("Linear Gradient", "elementor"));
3208
+ return /* @__PURE__ */ React48.createElement("span", null, __18("Linear Gradient", "elementor"));
3100
3209
  }
3101
- return /* @__PURE__ */ React46.createElement("span", null, __18("Radial Gradient", "elementor"));
3210
+ return /* @__PURE__ */ React48.createElement("span", null, __18("Radial Gradient", "elementor"));
3102
3211
  };
3103
3212
  var ColorOverlayContent = ({ anchorEl }) => {
3104
3213
  const propContext = useBoundProp(backgroundColorOverlayPropTypeUtil2);
3105
- return /* @__PURE__ */ React46.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "color" }, /* @__PURE__ */ React46.createElement(ColorControl, { anchorEl })));
3214
+ return /* @__PURE__ */ React48.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "color" }, /* @__PURE__ */ React48.createElement(ColorControl, { anchorEl })));
3106
3215
  };
3107
3216
  var ImageOverlayContent = () => {
3108
3217
  const propContext = useBoundProp(backgroundImageOverlayPropTypeUtil2);
3109
- return /* @__PURE__ */ React46.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "image" }, /* @__PURE__ */ React46.createElement(Grid14, { container: true, spacing: 1, alignItems: "center" }, /* @__PURE__ */ React46.createElement(Grid14, { item: true, xs: 12 }, /* @__PURE__ */ React46.createElement(
3218
+ return /* @__PURE__ */ React48.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "image" }, /* @__PURE__ */ React48.createElement(Grid14, { container: true, spacing: 1, alignItems: "center" }, /* @__PURE__ */ React48.createElement(Grid14, { item: true, xs: 12 }, /* @__PURE__ */ React48.createElement(
3110
3219
  ImageControl,
3111
3220
  {
3112
3221
  resolutionLabel: __18("Resolution", "elementor"),
3113
3222
  sizes: backgroundResolutionOptions
3114
3223
  }
3115
- )))), /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "position" }, /* @__PURE__ */ React46.createElement(BackgroundImageOverlayPosition, null)), /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "repeat" }, /* @__PURE__ */ React46.createElement(BackgroundImageOverlayRepeat, null)), /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "size" }, /* @__PURE__ */ React46.createElement(BackgroundImageOverlaySize, null)), /* @__PURE__ */ React46.createElement(PropKeyProvider, { bind: "attachment" }, /* @__PURE__ */ React46.createElement(BackgroundImageOverlayAttachment, null)));
3224
+ )))), /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "position" }, /* @__PURE__ */ React48.createElement(BackgroundImageOverlayPosition, null)), /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "repeat" }, /* @__PURE__ */ React48.createElement(BackgroundImageOverlayRepeat, null)), /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "size" }, /* @__PURE__ */ React48.createElement(BackgroundImageOverlaySize, null)), /* @__PURE__ */ React48.createElement(PropKeyProvider, { bind: "attachment" }, /* @__PURE__ */ React48.createElement(BackgroundImageOverlayAttachment, null)));
3116
3225
  };
3117
- var StyledUnstableColorIndicator = styled6(UnstableColorIndicator2)(({ theme }) => ({
3226
+ var StyledUnstableColorIndicator = styled5(UnstableColorIndicator2)(({ theme }) => ({
3118
3227
  borderRadius: `${theme.shape.borderRadius / 2}px`
3119
3228
  }));
3120
3229
  var useImage = (image) => {
@@ -3150,13 +3259,13 @@ var getGradientValue = (value) => {
3150
3259
  // src/controls/background-control/background-control.tsx
3151
3260
  var BackgroundControl = createControl(() => {
3152
3261
  const propContext = useBoundProp(backgroundPropTypeUtil);
3153
- const isUsingNestedProps = isExperimentActive3("e_v_3_30");
3262
+ const isUsingNestedProps = isExperimentActive4("e_v_3_30");
3154
3263
  const colorLabel = __19("Color", "elementor");
3155
- return /* @__PURE__ */ React47.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React47.createElement(PropKeyProvider, { bind: "background-overlay" }, /* @__PURE__ */ React47.createElement(BackgroundOverlayRepeaterControl, null)), /* @__PURE__ */ React47.createElement(PropKeyProvider, { bind: "color" }, /* @__PURE__ */ React47.createElement(Grid15, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React47.createElement(Grid15, { item: true, xs: 6 }, isUsingNestedProps ? /* @__PURE__ */ React47.createElement(ControlLabel, null, colorLabel) : /* @__PURE__ */ React47.createElement(ControlFormLabel, null, colorLabel)), /* @__PURE__ */ React47.createElement(Grid15, { item: true, xs: 6 }, /* @__PURE__ */ React47.createElement(ColorControl, null)))));
3264
+ return /* @__PURE__ */ React49.createElement(PropProvider, { ...propContext }, /* @__PURE__ */ React49.createElement(PropKeyProvider, { bind: "background-overlay" }, /* @__PURE__ */ React49.createElement(BackgroundOverlayRepeaterControl, null)), /* @__PURE__ */ React49.createElement(PropKeyProvider, { bind: "color" }, /* @__PURE__ */ React49.createElement(Grid15, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React49.createElement(Grid15, { item: true, xs: 6 }, isUsingNestedProps ? /* @__PURE__ */ React49.createElement(ControlLabel, null, colorLabel) : /* @__PURE__ */ React49.createElement(ControlFormLabel, null, colorLabel)), /* @__PURE__ */ React49.createElement(Grid15, { item: true, xs: 6 }, /* @__PURE__ */ React49.createElement(ColorControl, null)))));
3156
3265
  });
3157
3266
 
3158
3267
  // src/controls/switch-control.tsx
3159
- import * as React48 from "react";
3268
+ import * as React50 from "react";
3160
3269
  import { booleanPropTypeUtil as booleanPropTypeUtil2 } from "@elementor/editor-props";
3161
3270
  import { Switch as Switch2 } from "@elementor/ui";
3162
3271
  var SwitchControl2 = createControl(() => {
@@ -3164,8 +3273,190 @@ var SwitchControl2 = createControl(() => {
3164
3273
  const handleChange = (event) => {
3165
3274
  setValue(event.target.checked);
3166
3275
  };
3167
- return /* @__PURE__ */ React48.createElement("div", { style: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React48.createElement(Switch2, { checked: !!value, onChange: handleChange, size: "small", disabled }));
3276
+ return /* @__PURE__ */ React50.createElement("div", { style: { display: "flex", justifyContent: "flex-end" } }, /* @__PURE__ */ React50.createElement(Switch2, { checked: !!value, onChange: handleChange, size: "small", disabled }));
3168
3277
  });
3278
+
3279
+ // src/controls/repeatable-control.tsx
3280
+ import * as React51 from "react";
3281
+ import { useMemo as useMemo4 } from "react";
3282
+ import { createArrayPropUtils } from "@elementor/editor-props";
3283
+ import { __ as __20 } from "@wordpress/i18n";
3284
+
3285
+ // src/hooks/use-repeatable-control-context.ts
3286
+ import { createContext as createContext6, useContext as useContext6 } from "react";
3287
+ var RepeatableControlContext = createContext6(void 0);
3288
+ var useRepeatableControlContext = () => {
3289
+ const context = useContext6(RepeatableControlContext);
3290
+ if (!context) {
3291
+ throw new Error("useRepeatableControlContext must be used within RepeatableControl");
3292
+ }
3293
+ return context;
3294
+ };
3295
+
3296
+ // src/controls/repeatable-control.tsx
3297
+ var RepeatableControl = createControl(
3298
+ ({ label, childControlConfig, showDuplicate, showToggle }) => {
3299
+ const { propTypeUtil: childPropTypeUtil } = childControlConfig;
3300
+ if (!childPropTypeUtil) {
3301
+ return null;
3302
+ }
3303
+ const childArrayPropTypeUtil = useMemo4(
3304
+ () => createArrayPropUtils(childPropTypeUtil.key, childPropTypeUtil.schema),
3305
+ [childPropTypeUtil.key, childPropTypeUtil.schema]
3306
+ );
3307
+ const { propType, value, setValue } = useBoundProp(childArrayPropTypeUtil);
3308
+ return /* @__PURE__ */ React51.createElement(PropProvider, { propType, value, setValue }, /* @__PURE__ */ React51.createElement(RepeatableControlContext.Provider, { value: childControlConfig }, /* @__PURE__ */ React51.createElement(
3309
+ Repeater,
3310
+ {
3311
+ openOnAdd: true,
3312
+ values: value ?? [],
3313
+ setValues: setValue,
3314
+ label,
3315
+ itemSettings: {
3316
+ Icon: ItemIcon3,
3317
+ Label: ItemLabel3,
3318
+ Content: ItemContent3,
3319
+ initialValues: childPropTypeUtil.create(null)
3320
+ },
3321
+ showDuplicate,
3322
+ showToggle
3323
+ }
3324
+ )));
3325
+ }
3326
+ );
3327
+ var ItemContent3 = ({ bind }) => {
3328
+ return /* @__PURE__ */ React51.createElement(PropKeyProvider, { bind }, /* @__PURE__ */ React51.createElement(Content3, null));
3329
+ };
3330
+ var ItemIcon3 = () => /* @__PURE__ */ React51.createElement(React51.Fragment, null);
3331
+ var Content3 = () => {
3332
+ const { component: ChildControl, props = {} } = useRepeatableControlContext();
3333
+ return /* @__PURE__ */ React51.createElement(PopoverContent, { p: 1.5 }, /* @__PURE__ */ React51.createElement(PopoverGridContainer, null, /* @__PURE__ */ React51.createElement(ChildControl, { ...props })));
3334
+ };
3335
+ var ItemLabel3 = () => {
3336
+ const { label = __20("Empty", "elementor") } = useRepeatableControlContext();
3337
+ return /* @__PURE__ */ React51.createElement("span", null, label);
3338
+ };
3339
+
3340
+ // src/controls/key-value-control.tsx
3341
+ import * as React52 from "react";
3342
+ import { useMemo as useMemo5, useState as useState11 } from "react";
3343
+ import { keyValuePropTypeUtil } from "@elementor/editor-props";
3344
+ import { FormHelperText, FormLabel as FormLabel3, Grid as Grid16, TextField as TextField9 } from "@elementor/ui";
3345
+ import { __ as __21 } from "@wordpress/i18n";
3346
+ var KeyValueControl = createControl((props = {}) => {
3347
+ const { value, setValue } = useBoundProp(keyValuePropTypeUtil);
3348
+ const [keyError, setKeyError] = useState11(null);
3349
+ const [valueError, setValueError] = useState11(null);
3350
+ const keyLabel = props.keyName || __21("Key", "elementor");
3351
+ const valueLabel = props.valueName || __21("Value", "elementor");
3352
+ const keyValue = value?.key?.value || "";
3353
+ const valueValue = value?.value?.value || "";
3354
+ const [keyRegex, valueRegex, errMsg] = useMemo5(
3355
+ () => [
3356
+ props.regexKey ? new RegExp(props.regexKey) : void 0,
3357
+ props.regexValue ? new RegExp(props.regexValue) : void 0,
3358
+ props.validationErrorMessage || __21("Invalid Format", "elementor")
3359
+ ],
3360
+ [props.regexKey, props.regexValue, props.validationErrorMessage]
3361
+ );
3362
+ const validate = (newValue, FieldType) => {
3363
+ if (FieldType === "key" && keyRegex) {
3364
+ const isValid = keyRegex.test(newValue);
3365
+ setKeyError(isValid ? null : errMsg);
3366
+ } else if (FieldType === "value" && valueRegex) {
3367
+ const isValid = valueRegex.test(newValue);
3368
+ setValueError(isValid ? null : errMsg);
3369
+ }
3370
+ };
3371
+ const handleChange = (event, fieldType) => {
3372
+ const newValue = event.target.value;
3373
+ validate(newValue, fieldType);
3374
+ setValue({
3375
+ ...value,
3376
+ [fieldType]: {
3377
+ value: newValue,
3378
+ $$type: "string"
3379
+ }
3380
+ });
3381
+ };
3382
+ const isKeyInvalid = keyError !== null;
3383
+ const isValueInvalid = valueError !== null;
3384
+ return /* @__PURE__ */ React52.createElement(ControlActions, null, /* @__PURE__ */ React52.createElement(Grid16, { container: true, gap: 1.5, p: 1.5, sx: props.sx }, /* @__PURE__ */ React52.createElement(Grid16, { item: true, xs: 12 }, /* @__PURE__ */ React52.createElement(FormLabel3, { size: "tiny" }, keyLabel), /* @__PURE__ */ React52.createElement(
3385
+ TextField9,
3386
+ {
3387
+ sx: { pt: 1 },
3388
+ size: "tiny",
3389
+ fullWidth: true,
3390
+ value: keyValue,
3391
+ onChange: (e) => handleChange(e, "key"),
3392
+ error: isKeyInvalid
3393
+ }
3394
+ ), isKeyInvalid && /* @__PURE__ */ React52.createElement(FormHelperText, { error: true }, keyError)), /* @__PURE__ */ React52.createElement(Grid16, { item: true, xs: 12 }, /* @__PURE__ */ React52.createElement(FormLabel3, { size: "tiny" }, valueLabel), /* @__PURE__ */ React52.createElement(
3395
+ TextField9,
3396
+ {
3397
+ sx: { pt: 1 },
3398
+ size: "tiny",
3399
+ fullWidth: true,
3400
+ value: valueValue,
3401
+ onChange: (e) => handleChange(e, "value"),
3402
+ disabled: isKeyInvalid,
3403
+ error: isValueInvalid
3404
+ }
3405
+ ), isValueInvalid && /* @__PURE__ */ React52.createElement(FormHelperText, { error: true }, valueError))));
3406
+ });
3407
+
3408
+ // src/controls/position-control.tsx
3409
+ import * as React53 from "react";
3410
+ import { useMemo as useMemo6 } from "react";
3411
+ import { positionPropTypeUtil, stringPropTypeUtil as stringPropTypeUtil11 } from "@elementor/editor-props";
3412
+ import { MenuListItem as MenuListItem5 } from "@elementor/editor-ui";
3413
+ import { isExperimentActive as isExperimentActive5 } from "@elementor/editor-v1-adapters";
3414
+ import { LetterXIcon as LetterXIcon2, LetterYIcon as LetterYIcon2 } from "@elementor/icons";
3415
+ import { Grid as Grid17, Select as Select4 } from "@elementor/ui";
3416
+ import { __ as __22 } from "@wordpress/i18n";
3417
+ var positionOptions = [
3418
+ { label: __22("Center center", "elementor"), value: "center center" },
3419
+ { label: __22("Center left", "elementor"), value: "center left" },
3420
+ { label: __22("Center right", "elementor"), value: "center right" },
3421
+ { label: __22("Top center", "elementor"), value: "top center" },
3422
+ { label: __22("Top left", "elementor"), value: "top left" },
3423
+ { label: __22("Top right", "elementor"), value: "top right" },
3424
+ { label: __22("Bottom center", "elementor"), value: "bottom center" },
3425
+ { label: __22("Bottom left", "elementor"), value: "bottom left" },
3426
+ { label: __22("Bottom right", "elementor"), value: "bottom right" }
3427
+ ];
3428
+ var PositionControl = () => {
3429
+ const positionContext = useBoundProp(positionPropTypeUtil);
3430
+ const stringPropContext = useBoundProp(stringPropTypeUtil11);
3431
+ const isVersion331Active = isExperimentActive5("e_v_3_31");
3432
+ const isCustom = !!positionContext.value && isVersion331Active;
3433
+ const availablePositionOptions = useMemo6(() => {
3434
+ const options = [...positionOptions];
3435
+ if (isVersion331Active) {
3436
+ options.push({ label: __22("Custom", "elementor"), value: "custom" });
3437
+ }
3438
+ return options;
3439
+ }, [isVersion331Active]);
3440
+ const handlePositionChange = (event) => {
3441
+ const value = event.target.value || null;
3442
+ if (value === "custom" && isVersion331Active) {
3443
+ positionContext.setValue({ x: null, y: null });
3444
+ } else {
3445
+ stringPropContext.setValue(value);
3446
+ }
3447
+ };
3448
+ return /* @__PURE__ */ React53.createElement(Grid17, { container: true, spacing: 1.5 }, /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 12 }, /* @__PURE__ */ React53.createElement(Grid17, { container: true, gap: 2, alignItems: "center", flexWrap: "nowrap" }, /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 6 }, /* @__PURE__ */ React53.createElement(ControlFormLabel, null, __22("Object position", "elementor"))), /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 6, sx: { overflow: "hidden" } }, /* @__PURE__ */ React53.createElement(
3449
+ Select4,
3450
+ {
3451
+ size: "tiny",
3452
+ disabled: stringPropContext.disabled,
3453
+ value: (positionContext.value ? "custom" : stringPropContext.value) ?? "",
3454
+ onChange: handlePositionChange,
3455
+ fullWidth: true
3456
+ },
3457
+ availablePositionOptions.map(({ label, value }) => /* @__PURE__ */ React53.createElement(MenuListItem5, { key: value, value: value ?? "" }, label))
3458
+ )))), isCustom && /* @__PURE__ */ React53.createElement(PropProvider, { ...positionContext }, /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 12 }, /* @__PURE__ */ React53.createElement(Grid17, { container: true, spacing: 1.5 }, /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 6 }, /* @__PURE__ */ React53.createElement(PropKeyProvider, { bind: "x" }, /* @__PURE__ */ React53.createElement(SizeControl, { startIcon: /* @__PURE__ */ React53.createElement(LetterXIcon2, { fontSize: "tiny" }) }))), /* @__PURE__ */ React53.createElement(Grid17, { item: true, xs: 6 }, /* @__PURE__ */ React53.createElement(PropKeyProvider, { bind: "y" }, /* @__PURE__ */ React53.createElement(SizeControl, { startIcon: /* @__PURE__ */ React53.createElement(LetterYIcon2, { fontSize: "tiny" }) })))))));
3459
+ };
3169
3460
  export {
3170
3461
  AspectRatioControl,
3171
3462
  BackgroundControl,
@@ -3182,11 +3473,14 @@ export {
3182
3473
  FontFamilySelector,
3183
3474
  GapControl,
3184
3475
  ImageControl,
3476
+ KeyValueControl,
3185
3477
  LinkControl,
3186
3478
  LinkedDimensionsControl,
3187
3479
  NumberControl,
3480
+ PositionControl,
3188
3481
  PropKeyProvider,
3189
3482
  PropProvider,
3483
+ RepeatableControl,
3190
3484
  SelectControl,
3191
3485
  SizeControl,
3192
3486
  StrokeControl,