@app-studio/web 0.9.51 → 0.9.55

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.
@@ -9556,6 +9556,175 @@ var SwitchComponent = props => {
9556
9556
  // Exports the SwitchComponent as 'Switch' for use in other parts of the application.
9557
9557
  var Switch = SwitchComponent;
9558
9558
 
9559
+ // Initializes the custom hook 'useSelectorState' for managing the state of the Selector component
9560
+ var useSelectorState = _ref => {
9561
+ var {
9562
+ placeholder,
9563
+ isMulti,
9564
+ options,
9565
+ id = "selector-" + Math.random().toString(36).substr(2, 9)
9566
+ } = _ref;
9567
+ // Determines the default value based on the 'placeholder' and 'isMulti' props, setting to an empty array for multi-select or an empty string/single default option
9568
+ var defaultValue = placeholder ? isMulti ? [] : '' // If there's a placeholder, set default to empty array for multi-select or empty string for single select
9569
+ : Array.isArray(options) && options.length > 0 ? options[0].value : isMulti ? [] : ''; // If no placeholder, use the first option value if available, otherwise empty array for multi-select or empty string for single select
9570
+ // State hook for tracking mouse hover status over the Selector component
9571
+ var [isHovered, setIsHovered] = React__default.useState(false);
9572
+ // State hook for tracking focus status of the Selector input field
9573
+ var [isFocused, setIsFocused] = React__default.useState(false);
9574
+ // State hook for managing the value(s) selected by the user, initialized with the default value
9575
+ var [value, setValue] = React__default.useState(defaultValue);
9576
+ // State hook for keeping track of the currently highlighted index in the options list
9577
+ var [highlightedIndex, setHighlightedIndex] = React__default.useState(0);
9578
+ // State hook for managing visibility of the Selector dropdown, initially set to hidden
9579
+ var [hide, setHide] = React__default.useState(true);
9580
+ // Returns an object containing all stateful values and their associated setters to manage the Selector component's state
9581
+ return {
9582
+ id,
9583
+ value,
9584
+ setValue,
9585
+ hide,
9586
+ setHide,
9587
+ isHovered,
9588
+ setIsHovered,
9589
+ isFocused,
9590
+ setIsFocused,
9591
+ highlightedIndex,
9592
+ setHighlightedIndex
9593
+ };
9594
+ };
9595
+
9596
+ var _excluded$u = ["id", "name", "label", "value", "views", "options", "onChange", "setValue"];
9597
+ /**
9598
+ * SelectorView Component
9599
+ *
9600
+ * Renders a segmented control style selector.
9601
+ */
9602
+ var SelectorView = _ref => {
9603
+ var {
9604
+ id,
9605
+ name,
9606
+ label,
9607
+ value,
9608
+ views = {},
9609
+ options = [],
9610
+ onChange = () => {},
9611
+ setValue = () => {}
9612
+ } = _ref,
9613
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
9614
+ var {
9615
+ getColor
9616
+ } = appStudio.useTheme();
9617
+ var handleCallback = React.useCallback(option => {
9618
+ setValue(option.value);
9619
+ if (onChange) onChange(option.value);
9620
+ }, [setValue, onChange]);
9621
+ return /*#__PURE__*/React__default.createElement(FieldContainer, {
9622
+ id: id,
9623
+ width: "100%",
9624
+ views: views
9625
+ }, label && (/*#__PURE__*/React__default.createElement(appStudio.Horizontal, {
9626
+ fontSize: "10px",
9627
+ letterSpacing: "wider",
9628
+ color: "color.black.500",
9629
+ fontWeight: "bold",
9630
+ marginBottom: 12,
9631
+ alignItems: "center",
9632
+ gap: 6,
9633
+ //Text transform uppercase
9634
+ style: {
9635
+ textTransform: 'uppercase'
9636
+ }
9637
+ }, /*#__PURE__*/React__default.createElement(InfoIcon, {
9638
+ widthHeight: 14
9639
+ }), " ", /*#__PURE__*/React__default.createElement(appStudio.Text, null, label))), /*#__PURE__*/React__default.createElement(appStudio.Horizontal, {
9640
+ gap: 0
9641
+ }, options.map((option, index, arr) => {
9642
+ var isSelected = value === option.value;
9643
+ var borderColor = getColor('color.gray.200');
9644
+ var textColor = getColor('color.gray.500');
9645
+ var bgColor = 'transparent';
9646
+ if (isSelected) {
9647
+ if (option.color) {
9648
+ // We need a way to get related colors (50, 500, 700 etc) from a base color if we want full fidelity.
9649
+ // But passing full style strings is easier.
9650
+ borderColor = getColor(option.color);
9651
+ textColor = getColor(option.color);
9652
+ // Try to approximate background color if possible, or just use white/transparent.
9653
+ // Simplification: if color provided, use it for border/text.
9654
+ // Background is hard to derive without more specific props.
9655
+ // Let's try to use a very light opacity of the color for background.
9656
+ bgColor = 'rgba(0,0,0,0.05)'; // Generic active background
9657
+ } else {
9658
+ // Default active style
9659
+ var primary = getColor('theme.primary');
9660
+ borderColor = primary;
9661
+ textColor = primary;
9662
+ bgColor = 'color.gray.50';
9663
+ }
9664
+ // Specific overrides based on user request "ComplexitySelector" style
9665
+ // If the values match 'High', 'Medium', 'Low' we can hardcode for *demo* fidelity if generic logic fails.
9666
+ // But let's try to make it generic.
9667
+ // The user simply pasted code.
9668
+ if (option.color) {
9669
+ // Fallback for customized options
9670
+ borderColor = getColor(option.color);
9671
+ textColor = getColor(option.color);
9672
+ bgColor = 'transparent';
9673
+ } else {
9674
+ // Default fallback
9675
+ borderColor = getColor('theme.primary');
9676
+ textColor = getColor('theme.primary');
9677
+ bgColor = getColor('color.blue.50');
9678
+ }
9679
+ }
9680
+ return /*#__PURE__*/React__default.createElement(Button, Object.assign({
9681
+ key: option.value,
9682
+ onClick: () => handleCallback(option),
9683
+ flex: 1,
9684
+ paddingVertical: 6,
9685
+ fontSize: "12px",
9686
+ fontWeight: isSelected ? 'bold' : 'normal',
9687
+ style: {
9688
+ borderTop: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
9689
+ borderBottom: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
9690
+ borderLeft: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
9691
+ borderRight: index === arr.length - 1 || isSelected ? "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')) : 'none',
9692
+ backgroundColor: bgColor,
9693
+ color: textColor,
9694
+ borderRadius: index === 0 ? '6px 0 0 6px' : index === arr.length - 1 ? '0 6px 6px 0' : '0',
9695
+ zIndex: isSelected ? 1 : 0,
9696
+ boxShadow: 'none'
9697
+ }
9698
+ }, views.item), option.label);
9699
+ })), /*#__PURE__*/React__default.createElement("input", {
9700
+ type: "hidden",
9701
+ id: id,
9702
+ name: name,
9703
+ value: Array.isArray(value) ? value.join(',') : value,
9704
+ onChange: () => {}
9705
+ }));
9706
+ };
9707
+
9708
+ // Defines a functional component named 'SelectorComponent', which is expected to receive 'SelectorProps' as properties.
9709
+ var SelectorComponent = props => {
9710
+ // Ensure options is always an array
9711
+ var safeProps = Object.assign({}, props, {
9712
+ options: props.options || []
9713
+ });
9714
+ // Invokes the 'useSelectorState' hook with props to obtain stateful logic for the Selector component.
9715
+ var selectorStates = useSelectorState(safeProps);
9716
+ // Renders the 'SelectorView' component, passing along any states controlled by 'useSelectorState' and all properties passed to 'SelectorComponent'.
9717
+ return /*#__PURE__*/React__default.createElement(SelectorView, Object.assign({}, selectorStates, safeProps, {
9718
+ onClick: e => {
9719
+ // Stop propagation to prevent the global click handler from closing other dropdowns
9720
+ e.stopPropagation();
9721
+ if (props.onClick) props.onClick(e);
9722
+ }
9723
+ }));
9724
+ };
9725
+ // Exports 'SelectorComponent' as 'Selector', making it available for import in other parts of the application.
9726
+ var Selector = SelectorComponent;
9727
+
9559
9728
  // Declaration of the useTextAreaState custom hook for managing the text area component state.
9560
9729
  var useTextAreaState = _ref => {
9561
9730
  var {
@@ -9588,7 +9757,7 @@ var useTextAreaState = _ref => {
9588
9757
  // Export of the useTextAreaState hook for external usage.
9589
9758
  };
9590
9759
 
9591
- var _excluded$u = ["id", "name", "hint", "error", "value", "label", "shadow", "helperText", "placeholder", "size", "shape", "variant", "isHovered", "isFocused", "isEditable", "isReadOnly", "isDisabled", "isAutoFocus", "isMultiline", "maxRows", "maxCols", "onBlur", "onChange", "onFocus", "setHint", "setValue", "setIsFocused", "setIsHovered", "views"];
9760
+ var _excluded$v = ["id", "name", "hint", "error", "value", "label", "shadow", "helperText", "placeholder", "size", "shape", "variant", "isHovered", "isFocused", "isEditable", "isReadOnly", "isDisabled", "isAutoFocus", "isMultiline", "maxRows", "maxCols", "onBlur", "onChange", "onFocus", "setHint", "setValue", "setIsFocused", "setIsHovered", "views"];
9592
9761
  var TextAreaView = _ref => {
9593
9762
  var {
9594
9763
  id,
@@ -9623,7 +9792,7 @@ var TextAreaView = _ref => {
9623
9792
  helperText: {}
9624
9793
  }
9625
9794
  } = _ref,
9626
- props = _objectWithoutPropertiesLoose(_ref, _excluded$u);
9795
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$v);
9627
9796
  var showLabel = !!(isFocused && label);
9628
9797
  /**
9629
9798
  * Styles for the textarea field
@@ -9762,7 +9931,7 @@ var useTextFieldState = _ref => {
9762
9931
  };
9763
9932
  };
9764
9933
 
9765
- var _excluded$v = ["id", "name", "label", "hint", "value", "onChange", "left", "right", "helperText", "placeholder", "onChangeText", "shadow", "views", "size", "shape", "variant", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isClearable", "isAutoFocus", "setHint", "setIsFocused", "setIsHovered", "setValue", "onClick", "onFocus", "onBlur", "themeMode"];
9934
+ var _excluded$w = ["id", "name", "label", "hint", "value", "onChange", "left", "right", "helperText", "placeholder", "onChangeText", "shadow", "views", "size", "shape", "variant", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isClearable", "isAutoFocus", "setHint", "setIsFocused", "setIsHovered", "setValue", "onClick", "onFocus", "onBlur", "themeMode"];
9766
9935
  /**
9767
9936
  * Input component for text fields
9768
9937
  */
@@ -9808,7 +9977,7 @@ var TextFieldView = _ref => {
9808
9977
  onBlur = () => {},
9809
9978
  themeMode: elementMode
9810
9979
  } = _ref,
9811
- props = _objectWithoutPropertiesLoose(_ref, _excluded$v);
9980
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$w);
9812
9981
  var {
9813
9982
  getColor,
9814
9983
  themeMode
@@ -10087,7 +10256,7 @@ var StateStyles = {
10087
10256
  }
10088
10257
  };
10089
10258
 
10090
- var _excluded$w = ["id", "icon", "name", "label", "isChecked", "onChange", "onValueChange", "shadow", "labelPosition", "size", "error", "isSelected", "isHovered", "isDisabled", "isReadOnly", "isIndeterminate", "defaultIsSelected", "setIsSelected", "setIsHovered", "views", "infoText", "helperText"];
10259
+ var _excluded$x = ["id", "icon", "name", "label", "isChecked", "onChange", "onValueChange", "shadow", "labelPosition", "size", "error", "isSelected", "isHovered", "isDisabled", "isReadOnly", "isIndeterminate", "defaultIsSelected", "setIsSelected", "setIsHovered", "views", "infoText", "helperText"];
10091
10260
  var CheckboxView = _ref => {
10092
10261
  var {
10093
10262
  id,
@@ -10114,7 +10283,7 @@ var CheckboxView = _ref => {
10114
10283
  },
10115
10284
  infoText
10116
10285
  } = _ref,
10117
- props = _objectWithoutPropertiesLoose(_ref, _excluded$w);
10286
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$x);
10118
10287
  var handleHover = () => setIsHovered(!isHovered);
10119
10288
  var handleChange = () => {
10120
10289
  if (!isReadOnly && !isDisabled) {
@@ -10572,7 +10741,7 @@ var DefaultColorPalette = [
10572
10741
  value: 'transparent'
10573
10742
  }];
10574
10743
 
10575
- var _excluded$x = ["id", "name", "label", "placeholder", "helperText", "views", "size", "shape", "variant", "shadow", "error", "isDisabled", "isReadOnly", "isFocused", "isHovered", "predefinedColors", "showCustomInput", "showRecentColors", "isOpen", "selectedColor", "recentColors", "customColor", "handleToggle", "handleColorSelect", "handleCustomColorChange", "handleCustomColorSubmit", "setIsFocused", "setIsHovered", "triggerRef", "dropdownRef"];
10744
+ var _excluded$y = ["id", "name", "label", "placeholder", "helperText", "views", "size", "shape", "variant", "shadow", "error", "isDisabled", "isReadOnly", "isFocused", "isHovered", "predefinedColors", "showCustomInput", "showRecentColors", "isOpen", "selectedColor", "recentColors", "customColor", "handleToggle", "handleColorSelect", "handleCustomColorChange", "handleCustomColorSubmit", "setIsFocused", "setIsHovered", "triggerRef", "dropdownRef"];
10576
10745
  var ColorInputView = _ref => {
10577
10746
  var {
10578
10747
  // Basic props
@@ -10613,7 +10782,7 @@ var ColorInputView = _ref => {
10613
10782
  dropdownRef
10614
10783
  // Other props
10615
10784
  } = _ref,
10616
- props = _objectWithoutPropertiesLoose(_ref, _excluded$x);
10785
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$y);
10617
10786
  var {
10618
10787
  getColor
10619
10788
  } = appStudio.useTheme();
@@ -12252,11 +12421,11 @@ var IconSizes$4 = {
12252
12421
  xl: 16
12253
12422
  };
12254
12423
 
12255
- var _excluded$y = ["size"],
12424
+ var _excluded$z = ["size"],
12256
12425
  _excluded2$9 = ["size"],
12257
12426
  _excluded3$8 = ["id", "name", "label", "value", "placeholder", "helperText", "hide", "error", "isHovered", "isFocused", "isAutoFocus", "isDisabled", "isReadOnly", "shadow", "newOptions", "size", "variant", "shape", "onChange", "onBlur", "setHide", "setNewOptions", "setIsHovered", "setIsFocused", "setValue", "views", "themeMode"];
12258
12427
  var CountryList = _ref => {
12259
- var props = _objectWithoutPropertiesLoose(_ref, _excluded$y);
12428
+ var props = _objectWithoutPropertiesLoose(_ref, _excluded$z);
12260
12429
  return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
12261
12430
  as: "ul"
12262
12431
  }, props));
@@ -12494,7 +12663,7 @@ var useDatePickerState = () => {
12494
12663
  };
12495
12664
  };
12496
12665
 
12497
- var _excluded$z = ["id", "icon", "name", "label", "date", "children", "helperText", "shadow", "size", "variant", "shape", "views", "error", "isHovered", "isFocused", "isDisabled", "isReadOnly", "setDate", "setIsFocused", "setIsHovered", "onChange", "onChangeText"];
12666
+ var _excluded$A = ["id", "icon", "name", "label", "date", "children", "helperText", "shadow", "size", "variant", "shape", "views", "error", "isHovered", "isFocused", "isDisabled", "isReadOnly", "setDate", "setIsFocused", "setIsHovered", "onChange", "onChangeText"];
12498
12667
  var DatePickerContent = props => /*#__PURE__*/React__default.createElement(appStudio.Input, Object.assign({
12499
12668
  type: "date"
12500
12669
  }, props));
@@ -12527,7 +12696,7 @@ var DatePickerView = _ref => {
12527
12696
  onChange,
12528
12697
  onChangeText
12529
12698
  } = _ref,
12530
- props = _objectWithoutPropertiesLoose(_ref, _excluded$z);
12699
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$A);
12531
12700
  var showLabel = !!(isFocused && label);
12532
12701
  var handleHover = () => setIsHovered(!isHovered);
12533
12702
  var handleFocus = () => setIsFocused(true);
@@ -12614,7 +12783,7 @@ var usePasswordState = props => {
12614
12783
  }, props, textFieldStates);
12615
12784
  };
12616
12785
 
12617
- var _excluded$A = ["visibleIcon", "hiddenIcon"],
12786
+ var _excluded$B = ["visibleIcon", "hiddenIcon"],
12618
12787
  _excluded2$a = ["isVisible", "setIsVisible"];
12619
12788
  var PasswordComponent = _ref => {
12620
12789
  var {
@@ -12625,7 +12794,7 @@ var PasswordComponent = _ref => {
12625
12794
  widthHeight: 14
12626
12795
  })
12627
12796
  } = _ref,
12628
- props = _objectWithoutPropertiesLoose(_ref, _excluded$A);
12797
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$B);
12629
12798
  var _usePasswordState = usePasswordState(props),
12630
12799
  {
12631
12800
  isVisible,
@@ -12679,7 +12848,7 @@ var useComboBoxState = (items, placeholder, searchPlaceholder) => {
12679
12848
  };
12680
12849
  };
12681
12850
 
12682
- var _excluded$B = ["placeholder", "items", "showTick", "onSelect", "searchEnabled", "left", "right", "label", "filteredItems", "setSelectedItem", "selectedItem", "highlightedIndex", "setHighlightedIndex", "searchQuery", "setSearchQuery", "setFilteredItems", "views", "isDropdownVisible", "setIsDropdownVisible"];
12851
+ var _excluded$C = ["placeholder", "items", "showTick", "onSelect", "searchEnabled", "left", "right", "label", "filteredItems", "setSelectedItem", "selectedItem", "highlightedIndex", "setHighlightedIndex", "searchQuery", "setSearchQuery", "setFilteredItems", "views", "isDropdownVisible", "setIsDropdownVisible"];
12683
12852
  // Defines the functional component 'ComboBoxView' with destructured props.
12684
12853
  var ComboBoxView = _ref => {
12685
12854
  var {
@@ -12704,7 +12873,7 @@ var ComboBoxView = _ref => {
12704
12873
  setIsDropdownVisible
12705
12874
  // Collects all further props not destructured explicitly.
12706
12875
  } = _ref,
12707
- props = _objectWithoutPropertiesLoose(_ref, _excluded$B);
12876
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$C);
12708
12877
  var {
12709
12878
  ref: triggerRef,
12710
12879
  relation
@@ -12883,7 +13052,7 @@ var ComboBoxView = _ref => {
12883
13052
  }, "No items found")))))));
12884
13053
  };
12885
13054
 
12886
- var _excluded$C = ["id", "name", "items", "placeholder", "searchPlaceholder"];
13055
+ var _excluded$D = ["id", "name", "items", "placeholder", "searchPlaceholder"];
12887
13056
  // Defines the ComboBoxComponent functional component with ComboBoxProps
12888
13057
  var ComboBoxComponent = _ref => {
12889
13058
  var {
@@ -12899,7 +13068,7 @@ var ComboBoxComponent = _ref => {
12899
13068
  searchPlaceholder
12900
13069
  // Destructures the rest of the props not explicitly defined
12901
13070
  } = _ref,
12902
- props = _objectWithoutPropertiesLoose(_ref, _excluded$C);
13071
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$D);
12903
13072
  // Initializes ComboBox state using custom hook with items and placeholders
12904
13073
  var state = useComboBoxState(items, placeholder, searchPlaceholder);
12905
13074
  return (
@@ -13108,7 +13277,7 @@ var useTagInputState = props => {
13108
13277
  };
13109
13278
  };
13110
13279
 
13111
- var _excluded$D = ["id", "name", "label", "placeholder", "helperText", "error", "inputValue", "tags", "left", "right", "shadow", "views", "size", "shape", "variant", "isDisabled", "isReadOnly", "isAutoFocus", "isRemovable", "isFocused", "isHovered", "maxTags", "handleInputChange", "handleKeyDown", "handleFocus", "handleBlur", "removeTag", "setIsHovered", "onClick"];
13280
+ var _excluded$E = ["id", "name", "label", "placeholder", "helperText", "error", "inputValue", "tags", "left", "right", "shadow", "views", "size", "shape", "variant", "isDisabled", "isReadOnly", "isAutoFocus", "isRemovable", "isFocused", "isHovered", "maxTags", "handleInputChange", "handleKeyDown", "handleFocus", "handleBlur", "removeTag", "setIsHovered", "onClick"];
13112
13281
  /**
13113
13282
  * Individual tag chip component
13114
13283
  */
@@ -13233,7 +13402,7 @@ var TagInputView = _ref2 => {
13233
13402
  setIsHovered,
13234
13403
  onClick
13235
13404
  } = _ref2,
13236
- props = _objectWithoutPropertiesLoose(_ref2, _excluded$D);
13405
+ props = _objectWithoutPropertiesLoose(_ref2, _excluded$E);
13237
13406
  var {
13238
13407
  getColor,
13239
13408
  themeMode
@@ -13316,7 +13485,7 @@ var TagInputView = _ref2 => {
13316
13485
  }, views == null ? void 0 : views.placeholder), "Maximum ", maxTags, " tags reached")))), right));
13317
13486
  };
13318
13487
 
13319
- var _excluded$E = ["tags"];
13488
+ var _excluded$F = ["tags"];
13320
13489
  /**
13321
13490
  * TagInput Component
13322
13491
  *
@@ -13328,7 +13497,7 @@ var TagInputComponent = props => {
13328
13497
  // Initialize state management with the custom hook
13329
13498
  var tagInputState = useTagInputState(props);
13330
13499
  // Separate the tags prop to avoid type conflicts
13331
- var restProps = _objectWithoutPropertiesLoose(props, _excluded$E);
13500
+ var restProps = _objectWithoutPropertiesLoose(props, _excluded$F);
13332
13501
  // Render the view component with combined props and state
13333
13502
  return /*#__PURE__*/React__default.createElement(TagInputView, Object.assign({}, tagInputState, restProps));
13334
13503
  };
@@ -13641,7 +13810,7 @@ var useOTPInputState = _ref => {
13641
13810
  };
13642
13811
  };
13643
13812
 
13644
- var _excluded$F = ["id", "name", "label", "value", "length", "onChange", "onChangeText", "onComplete", "helperText", "placeholder", "shadow", "views", "size", "shape", "variant", "gap", "type", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isAutoFocus", "setValue", "setIsFocused", "setIsHovered", "inputRef", "containerRef", "mirrorSelectionStart", "mirrorSelectionEnd", "setMirrorSelectionStart", "setMirrorSelectionEnd", "handlePaste", "handleChange", "handleFocus", "handleBlur", "handleKeyDown", "handleKeyPress", "secureTextEntry", "isFirstColumn", "stepValues", "setInputRef", "onBlur", "onClick", "onFocus"];
13813
+ var _excluded$G = ["id", "name", "label", "value", "length", "onChange", "onChangeText", "onComplete", "helperText", "placeholder", "shadow", "views", "size", "shape", "variant", "gap", "type", "error", "isFocused", "isHovered", "isDisabled", "isReadOnly", "isAutoFocus", "setValue", "setIsFocused", "setIsHovered", "inputRef", "containerRef", "mirrorSelectionStart", "mirrorSelectionEnd", "setMirrorSelectionStart", "setMirrorSelectionEnd", "handlePaste", "handleChange", "handleFocus", "handleBlur", "handleKeyDown", "handleKeyPress", "secureTextEntry", "isFirstColumn", "stepValues", "setInputRef", "onBlur", "onClick", "onFocus"];
13645
13814
  // Create a context for OTP input slots
13646
13815
  var OTPInputContext = /*#__PURE__*/React.createContext({
13647
13816
  slots: [],
@@ -13695,7 +13864,7 @@ var OTPInputView = _ref => {
13695
13864
  onFocus = () => {}
13696
13865
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
13697
13866
  } = _ref,
13698
- props = _objectWithoutPropertiesLoose(_ref, _excluded$F);
13867
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$G);
13699
13868
  appStudio.useTheme(); // Initialize theme context
13700
13869
  var showLabel = !!label;
13701
13870
  // Create context value for slots
@@ -13927,7 +14096,7 @@ var OTPInputComponent = props => {
13927
14096
  };
13928
14097
  var OTPInput = OTPInputComponent;
13929
14098
 
13930
- var _excluded$G = ["children", "autoFocus", "initFocus", "onChange"];
14099
+ var _excluded$H = ["children", "autoFocus", "initFocus", "onChange"];
13931
14100
  var FocusContext = /*#__PURE__*/React.createContext({
13932
14101
  active: false,
13933
14102
  focusNextInput: () => {},
@@ -13943,7 +14112,7 @@ var FormikForm = _ref => {
13943
14112
  initFocus,
13944
14113
  onChange = () => {}
13945
14114
  } = _ref,
13946
- props = _objectWithoutPropertiesLoose(_ref, _excluded$G);
14115
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$H);
13947
14116
  var formik$1 = formik.useFormikContext();
13948
14117
  React.useEffect(() => {
13949
14118
  onChange(formik$1.values);
@@ -13991,7 +14160,7 @@ var FormikForm = _ref => {
13991
14160
  }, /*#__PURE__*/React__default.createElement(appStudio.Form, Object.assign({}, props), children));
13992
14161
  };
13993
14162
 
13994
- var _excluded$H = ["name", "type"];
14163
+ var _excluded$I = ["name", "type"];
13995
14164
  var getInputTypeProps = type => {
13996
14165
  switch (type) {
13997
14166
  case 'email':
@@ -14030,7 +14199,7 @@ var useFormikInput = _ref => {
14030
14199
  name,
14031
14200
  type
14032
14201
  } = _ref,
14033
- props = _objectWithoutPropertiesLoose(_ref, _excluded$H);
14202
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$I);
14034
14203
  var focus = useFormFocus();
14035
14204
  var {
14036
14205
  touched,
@@ -14074,13 +14243,13 @@ var useFormikInput = _ref => {
14074
14243
  } : {});
14075
14244
  };
14076
14245
 
14077
- var _excluded$I = ["value"];
14246
+ var _excluded$J = ["value"];
14078
14247
  var CheckboxComponent$1 = props => {
14079
14248
  var _useFormikInput = useFormikInput(props),
14080
14249
  {
14081
14250
  value
14082
14251
  } = _useFormikInput,
14083
- formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$I);
14252
+ formProps = _objectWithoutPropertiesLoose(_useFormikInput, _excluded$J);
14084
14253
  formProps.isChecked = value;
14085
14254
  var checkboxStates = useCheckboxState(props);
14086
14255
  return /*#__PURE__*/React__default.createElement(CheckboxView, Object.assign({}, checkboxStates, formProps));
@@ -14800,7 +14969,7 @@ var useHoverCardState = function useHoverCardState(_temp) {
14800
14969
  };
14801
14970
  };
14802
14971
 
14803
- var _excluded$J = ["children", "views", "asChild"],
14972
+ var _excluded$K = ["children", "views", "asChild"],
14804
14973
  _excluded2$b = ["children", "views", "side", "align", "sideOffset", "style", "backgroundColor", "borderRadius", "boxShadow", "padding", "minWidth", "maxWidth"];
14805
14974
  // Create context for the HoverCard
14806
14975
  var HoverCardContext = /*#__PURE__*/React.createContext({
@@ -14839,7 +15008,7 @@ var HoverCardTrigger = _ref2 => {
14839
15008
  views,
14840
15009
  asChild = false
14841
15010
  } = _ref2,
14842
- props = _objectWithoutPropertiesLoose(_ref2, _excluded$J);
15011
+ props = _objectWithoutPropertiesLoose(_ref2, _excluded$K);
14843
15012
  var {
14844
15013
  openCard,
14845
15014
  closeCard,
@@ -15009,7 +15178,7 @@ var HoverCardContent = _ref3 => {
15009
15178
  }, views == null ? void 0 : views.container, props), children);
15010
15179
  };
15011
15180
 
15012
- var _excluded$K = ["children", "views", "openDelay", "closeDelay"];
15181
+ var _excluded$L = ["children", "views", "openDelay", "closeDelay"];
15013
15182
  /**
15014
15183
  * HoverCard component displays floating content when hovering over a trigger element.
15015
15184
  * Supports configurable open and close delays for a smoother user experience.
@@ -15021,7 +15190,7 @@ var HoverCardComponent = _ref => {
15021
15190
  openDelay,
15022
15191
  closeDelay
15023
15192
  } = _ref,
15024
- props = _objectWithoutPropertiesLoose(_ref, _excluded$K);
15193
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$L);
15025
15194
  var hoverCardState = useHoverCardState({
15026
15195
  openDelay,
15027
15196
  closeDelay
@@ -15633,7 +15802,7 @@ var AudioRecorder = _ref => {
15633
15802
  }))));
15634
15803
  };
15635
15804
 
15636
- var _excluded$L = ["onSubmit", "placeholder", "loading", "disabled", "isAgentRunning", "enableAudioRecording", "leftButtons", "rightButtons", "onStopAgent", "loadingText", "autoFocus", "sandboxId", "hideAttachments", "attachmentText", "promptExamples", "suggestions", "errorMessage", "size", "shape", "variant", "views", "mentionData", "mentionTrigger", "onMentionSelect", "onAudioRecordingStart", "onAudioRecordingStop", "value", "handleChange", "handleSubmit", "editableRef", "fileInputRef", "isUploading", "uploadProgress", "isDraggingOver", "uploadedFiles", "removeUploadedFile", "setPendingFiles", "setUploadedFiles", "setIsUploading", "startUpload", "selectedModel", "handleModelChange", "modelOptions", "subscriptionStatus", "canAccessModel", "isGuideTipShown", "hideGuideTip", "handlePromptExampleSelect", "handleDragOver", "handleDragLeave"];
15805
+ var _excluded$M = ["onSubmit", "placeholder", "loading", "disabled", "isAgentRunning", "enableAudioRecording", "leftButtons", "rightButtons", "onStopAgent", "loadingText", "autoFocus", "sandboxId", "hideAttachments", "attachmentText", "promptExamples", "suggestions", "errorMessage", "size", "shape", "variant", "views", "mentionData", "mentionTrigger", "onMentionSelect", "onAudioRecordingStart", "onAudioRecordingStop", "value", "handleChange", "handleSubmit", "editableRef", "fileInputRef", "isUploading", "uploadProgress", "isDraggingOver", "uploadedFiles", "removeUploadedFile", "setPendingFiles", "setUploadedFiles", "setIsUploading", "startUpload", "selectedModel", "handleModelChange", "modelOptions", "subscriptionStatus", "canAccessModel", "isGuideTipShown", "hideGuideTip", "handlePromptExampleSelect", "handleDragOver", "handleDragLeave"];
15637
15806
  var ChatInputView = _ref => {
15638
15807
  var _value$trim$length;
15639
15808
  var {
@@ -15678,7 +15847,7 @@ var ChatInputView = _ref => {
15678
15847
  handleDragLeave
15679
15848
  // Other props
15680
15849
  } = _ref,
15681
- props = _objectWithoutPropertiesLoose(_ref, _excluded$L);
15850
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$M);
15682
15851
  var {} = appStudio.useTheme();
15683
15852
  // Combine styles
15684
15853
  var containerStyles = Object.assign({}, DefaultChatInputStyles.container, Shapes$2[shape], views == null ? void 0 : views.container);
@@ -15905,13 +16074,13 @@ var ChatInputView = _ref => {
15905
16074
  }, views == null ? void 0 : views.bottomTip), errorMessage)));
15906
16075
  };
15907
16076
 
15908
- var _excluded$M = ["name", "onSubmit"];
16077
+ var _excluded$N = ["name", "onSubmit"];
15909
16078
  var ChatInputComponent = props => {
15910
16079
  var {
15911
16080
  name,
15912
16081
  onSubmit
15913
16082
  } = props,
15914
- chatInputProps = _objectWithoutPropertiesLoose(props, _excluded$M);
16083
+ chatInputProps = _objectWithoutPropertiesLoose(props, _excluded$N);
15915
16084
  // State for managing pending files
15916
16085
  var [pendingFiles, setPendingFiles] = React.useState([]);
15917
16086
  // Get Formik integration props
@@ -16008,7 +16177,7 @@ var SwitchComponent$1 = props => {
16008
16177
  };
16009
16178
  var FormikSwitch = SwitchComponent$1;
16010
16179
 
16011
- var _excluded$N = ["name"],
16180
+ var _excluded$O = ["name"],
16012
16181
  _excluded2$c = ["tags"];
16013
16182
  /**
16014
16183
  * Formik-integrated TagInput component
@@ -16017,7 +16186,7 @@ var TagInputComponent$1 = props => {
16017
16186
  var {
16018
16187
  name
16019
16188
  } = props,
16020
- restProps = _objectWithoutPropertiesLoose(props, _excluded$N);
16189
+ restProps = _objectWithoutPropertiesLoose(props, _excluded$O);
16021
16190
  // Get Formik context directly for better control
16022
16191
  var {
16023
16192
  values,
@@ -16075,11 +16244,11 @@ var TextAreaComponent$1 = props => {
16075
16244
  */
16076
16245
  var FormikTextArea = TextAreaComponent$1;
16077
16246
 
16078
- var _excluded$O = ["value"];
16247
+ var _excluded$P = ["value"];
16079
16248
  var TextFieldComponent$1 = props => {
16080
16249
  var formProps = useFormikInput(props);
16081
16250
  var _useTextFieldState = useTextFieldState(props),
16082
- textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$O);
16251
+ textFieldStates = _objectWithoutPropertiesLoose(_useTextFieldState, _excluded$P);
16083
16252
  return /*#__PURE__*/React__default.createElement(TextFieldView, Object.assign({}, textFieldStates, formProps));
16084
16253
  };
16085
16254
  /**
@@ -16087,7 +16256,7 @@ var TextFieldComponent$1 = props => {
16087
16256
  */
16088
16257
  var FormikTextField = TextFieldComponent$1;
16089
16258
 
16090
- var _excluded$P = ["visibleIcon", "hiddenIcon"],
16259
+ var _excluded$Q = ["visibleIcon", "hiddenIcon"],
16091
16260
  _excluded2$d = ["isVisible", "setIsVisible"];
16092
16261
  var PasswordComponent$1 = _ref => {
16093
16262
  var {
@@ -16098,7 +16267,7 @@ var PasswordComponent$1 = _ref => {
16098
16267
  widthHeight: 14
16099
16268
  })
16100
16269
  } = _ref,
16101
- props = _objectWithoutPropertiesLoose(_ref, _excluded$P);
16270
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$Q);
16102
16271
  var formProps = useFormikInput(props);
16103
16272
  var _usePasswordState = usePasswordState(formProps),
16104
16273
  {
@@ -16123,14 +16292,14 @@ var PasswordComponent$1 = _ref => {
16123
16292
  */
16124
16293
  var FormikPassword = PasswordComponent$1;
16125
16294
 
16126
- var _excluded$Q = ["items", "placeholder", "searchPlaceholder"];
16295
+ var _excluded$R = ["items", "placeholder", "searchPlaceholder"];
16127
16296
  var ComboBoxComponent$1 = _ref => {
16128
16297
  var {
16129
16298
  items,
16130
16299
  placeholder,
16131
16300
  searchPlaceholder
16132
16301
  } = _ref,
16133
- props = _objectWithoutPropertiesLoose(_ref, _excluded$Q);
16302
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$R);
16134
16303
  var formProps = useFormikInput(props);
16135
16304
  var ComboBoxStates = useComboBoxState(items, placeholder, searchPlaceholder);
16136
16305
  // Ensure the onChange function from formProps is being called when an item is selected
@@ -16413,7 +16582,7 @@ var OrientationStyles = {
16413
16582
  }
16414
16583
  };
16415
16584
 
16416
- var _excluded$R = ["min", "max", "step", "currentValue", "stepValues", "shape", "size", "variant", "orientation", "isDisabled", "showValue", "showTooltip", "backgroundColor", "label", "helperText", "themeMode", "shadow", "isDragging", "isHovered", "setIsHovered", "trackRef", "thumbRef", "handleThumbMouseDown", "handleTrackMouseDown", "handleKeyDown", "thumbPositionPercent", "ariaLabel", "views"];
16585
+ var _excluded$S = ["min", "max", "step", "currentValue", "stepValues", "shape", "size", "variant", "orientation", "isDisabled", "showValue", "showTooltip", "backgroundColor", "label", "helperText", "themeMode", "shadow", "isDragging", "isHovered", "setIsHovered", "trackRef", "thumbRef", "handleThumbMouseDown", "handleTrackMouseDown", "handleKeyDown", "thumbPositionPercent", "ariaLabel", "views"];
16417
16586
  var SliderView = _ref => {
16418
16587
  var _views$tooltip, _views$tooltip2;
16419
16588
  var {
@@ -16456,7 +16625,7 @@ var SliderView = _ref => {
16456
16625
  tooltip: {}
16457
16626
  }
16458
16627
  } = _ref,
16459
- props = _objectWithoutPropertiesLoose(_ref, _excluded$R);
16628
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$S);
16460
16629
  var {
16461
16630
  getColor,
16462
16631
  themeMode
@@ -16779,7 +16948,7 @@ var OTPInputComponent$1 = props => {
16779
16948
  */
16780
16949
  var FormikOTPInput = OTPInputComponent$1;
16781
16950
 
16782
- var _excluded$S = ["name", "uploadFile", "onUploadSuccess", "onUploadError", "transformResponse", "onMultipleFileSelect", "onFileSelect", "multiple"];
16951
+ var _excluded$T = ["name", "uploadFile", "onUploadSuccess", "onUploadError", "transformResponse", "onMultipleFileSelect", "onFileSelect", "multiple"];
16783
16952
  var defaultUploadFile = (file, onProgress) => {
16784
16953
  return api.UploadService.uploadControllerFile({
16785
16954
  file
@@ -16805,7 +16974,7 @@ var FormikUploader = _ref => {
16805
16974
  onFileSelect,
16806
16975
  multiple = true
16807
16976
  } = _ref,
16808
- props = _objectWithoutPropertiesLoose(_ref, _excluded$S);
16977
+ props = _objectWithoutPropertiesLoose(_ref, _excluded$T);
16809
16978
  var {
16810
16979
  setFieldValue,
16811
16980
  setFieldTouched,
@@ -16875,156 +17044,7 @@ var FormikUploader = _ref => {
16875
17044
  };
16876
17045
  FormikUploader.displayName = 'FormikUploader';
16877
17046
 
16878
- // Initializes the custom hook 'useSelectorState' for managing the state of the Selector component
16879
- var useSelectorState = _ref => {
16880
- var {
16881
- placeholder,
16882
- isMulti,
16883
- options,
16884
- id = "selector-" + Math.random().toString(36).substr(2, 9)
16885
- } = _ref;
16886
- // Determines the default value based on the 'placeholder' and 'isMulti' props, setting to an empty array for multi-select or an empty string/single default option
16887
- var defaultValue = placeholder ? isMulti ? [] : '' // If there's a placeholder, set default to empty array for multi-select or empty string for single select
16888
- : Array.isArray(options) && options.length > 0 ? options[0].value : isMulti ? [] : ''; // If no placeholder, use the first option value if available, otherwise empty array for multi-select or empty string for single select
16889
- // State hook for tracking mouse hover status over the Selector component
16890
- var [isHovered, setIsHovered] = React__default.useState(false);
16891
- // State hook for tracking focus status of the Selector input field
16892
- var [isFocused, setIsFocused] = React__default.useState(false);
16893
- // State hook for managing the value(s) selected by the user, initialized with the default value
16894
- var [value, setValue] = React__default.useState(defaultValue);
16895
- // State hook for keeping track of the currently highlighted index in the options list
16896
- var [highlightedIndex, setHighlightedIndex] = React__default.useState(0);
16897
- // State hook for managing visibility of the Selector dropdown, initially set to hidden
16898
- var [hide, setHide] = React__default.useState(true);
16899
- // Returns an object containing all stateful values and their associated setters to manage the Selector component's state
16900
- return {
16901
- id,
16902
- value,
16903
- setValue,
16904
- hide,
16905
- setHide,
16906
- isHovered,
16907
- setIsHovered,
16908
- isFocused,
16909
- setIsFocused,
16910
- highlightedIndex,
16911
- setHighlightedIndex
16912
- };
16913
- };
16914
-
16915
- var _excluded$T = ["id", "name", "label", "value", "views", "options", "onChange", "setValue"];
16916
- /**
16917
- * SelectorView Component
16918
- *
16919
- * Renders a segmented control style selector.
16920
- */
16921
- var SelectorView = _ref => {
16922
- var {
16923
- id,
16924
- name,
16925
- label,
16926
- value,
16927
- views = {},
16928
- options = [],
16929
- onChange = () => {},
16930
- setValue = () => {}
16931
- } = _ref,
16932
- props = _objectWithoutPropertiesLoose(_ref, _excluded$T);
16933
- var {
16934
- getColor
16935
- } = appStudio.useTheme();
16936
- var handleCallback = React.useCallback(option => {
16937
- setValue(option.value);
16938
- if (onChange) onChange(option.value);
16939
- }, [setValue, onChange]);
16940
- return /*#__PURE__*/React__default.createElement(FieldContainer, {
16941
- id: id,
16942
- width: "100%",
16943
- views: views
16944
- }, label && (/*#__PURE__*/React__default.createElement(appStudio.Horizontal, {
16945
- fontSize: "10px",
16946
- letterSpacing: "wider",
16947
- color: "color.black.500",
16948
- fontWeight: "bold",
16949
- marginBottom: 12,
16950
- alignItems: "center",
16951
- gap: 6,
16952
- //Text transform uppercase
16953
- style: {
16954
- textTransform: 'uppercase'
16955
- }
16956
- }, /*#__PURE__*/React__default.createElement(InfoIcon, {
16957
- widthHeight: 14
16958
- }), " ", /*#__PURE__*/React__default.createElement(appStudio.Text, null, label))), /*#__PURE__*/React__default.createElement(appStudio.Horizontal, {
16959
- gap: 0
16960
- }, options.map((option, index, arr) => {
16961
- var isSelected = value === option.value;
16962
- var borderColor = getColor('color.gray.200');
16963
- var textColor = getColor('color.gray.500');
16964
- var bgColor = 'transparent';
16965
- if (isSelected) {
16966
- if (option.color) {
16967
- // We need a way to get related colors (50, 500, 700 etc) from a base color if we want full fidelity.
16968
- // But passing full style strings is easier.
16969
- borderColor = getColor(option.color);
16970
- textColor = getColor(option.color);
16971
- // Try to approximate background color if possible, or just use white/transparent.
16972
- // Simplification: if color provided, use it for border/text.
16973
- // Background is hard to derive without more specific props.
16974
- // Let's try to use a very light opacity of the color for background.
16975
- bgColor = 'rgba(0,0,0,0.05)'; // Generic active background
16976
- } else {
16977
- // Default active style
16978
- var primary = getColor('theme.primary');
16979
- borderColor = primary;
16980
- textColor = primary;
16981
- bgColor = 'color.gray.50';
16982
- }
16983
- // Specific overrides based on user request "ComplexitySelector" style
16984
- // If the values match 'High', 'Medium', 'Low' we can hardcode for *demo* fidelity if generic logic fails.
16985
- // But let's try to make it generic.
16986
- // The user simply pasted code.
16987
- if (option.color) {
16988
- // Fallback for customized options
16989
- borderColor = getColor(option.color);
16990
- textColor = getColor(option.color);
16991
- bgColor = 'transparent';
16992
- } else {
16993
- // Default fallback
16994
- borderColor = getColor('theme.primary');
16995
- textColor = getColor('theme.primary');
16996
- bgColor = getColor('color.blue.50');
16997
- }
16998
- }
16999
- return /*#__PURE__*/React__default.createElement(Button, Object.assign({
17000
- key: option.value,
17001
- onClick: () => handleCallback(option),
17002
- flex: 1,
17003
- paddingVertical: 6,
17004
- fontSize: "12px",
17005
- fontWeight: isSelected ? 'bold' : 'normal',
17006
- style: {
17007
- borderTop: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
17008
- borderBottom: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
17009
- borderLeft: "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')),
17010
- borderRight: index === arr.length - 1 || isSelected ? "1px solid " + (isSelected ? borderColor : getColor('color.gray.200')) : 'none',
17011
- backgroundColor: bgColor,
17012
- color: textColor,
17013
- borderRadius: index === 0 ? '6px 0 0 6px' : index === arr.length - 1 ? '0 6px 6px 0' : '0',
17014
- zIndex: isSelected ? 1 : 0,
17015
- boxShadow: 'none'
17016
- }
17017
- }, views.item), option.label);
17018
- })), /*#__PURE__*/React__default.createElement("input", {
17019
- type: "hidden",
17020
- id: id,
17021
- name: name,
17022
- value: Array.isArray(value) ? value.join(',') : value,
17023
- onChange: () => {}
17024
- }));
17025
- };
17026
-
17027
- var SelectorComponent = props => {
17047
+ var SelectorComponent$1 = props => {
17028
17048
  var formProps = useFormikInput(props);
17029
17049
  formProps.selected = formProps.value;
17030
17050
  var selectorStates = useSelectorState(props);
@@ -17033,7 +17053,7 @@ var SelectorComponent = props => {
17033
17053
  /**
17034
17054
  * Selector provides a dropdown list of options for the user to choose from.
17035
17055
  */
17036
- var FormikSelector = SelectorComponent;
17056
+ var FormikSelector = SelectorComponent$1;
17037
17057
 
17038
17058
  var AttachmentPreview = _ref => {
17039
17059
  var {
@@ -19309,16 +19329,6 @@ var TypewriterEffect = _ref => {
19309
19329
 
19310
19330
  var _excluded$_ = ["text", "duration", "direction", "stagger", "sequential", "textStyle", "as", "wordProps"],
19311
19331
  _excluded2$g = ["style"];
19312
- // CSS keyframes injection - done once
19313
- var KEYFRAMES_ID = 'slide-effect-keyframes';
19314
- var injectKeyframes = () => {
19315
- if (typeof document === 'undefined') return;
19316
- if (document.getElementById(KEYFRAMES_ID)) return;
19317
- var style = document.createElement('style');
19318
- style.id = KEYFRAMES_ID;
19319
- style.textContent = "\n @keyframes slideInUp {\n from { transform: translateY(100%); opacity: 0; }\n to { transform: translateY(0); opacity: 1; }\n }\n @keyframes slideOutUp {\n from { transform: translateY(0); opacity: 1; }\n to { transform: translateY(-100%); opacity: 0; }\n }\n @keyframes slideInDown {\n from { transform: translateY(-100%); opacity: 0; }\n to { transform: translateY(0); opacity: 1; }\n }\n @keyframes slideOutDown {\n from { transform: translateY(0); opacity: 1; }\n to { transform: translateY(100%); opacity: 0; }\n }\n ";
19320
- document.head.appendChild(style);
19321
- };
19322
19332
  var SlideEffect = _ref => {
19323
19333
  var {
19324
19334
  text,
@@ -19335,10 +19345,6 @@ var SlideEffect = _ref => {
19335
19345
  var [animKey, setAnimKey] = React.useState(0);
19336
19346
  var pendingTextRef = React.useRef(null);
19337
19347
  var timeoutRef = React.useRef(null);
19338
- // Inject keyframes once on mount
19339
- React.useEffect(() => {
19340
- injectKeyframes();
19341
- }, []);
19342
19348
  // Handle text changes
19343
19349
  React.useEffect(() => {
19344
19350
  if (text === displayedText && phase === 'visible') {
@@ -19404,12 +19410,10 @@ var SlideEffect = _ref => {
19404
19410
  style: customWordStyle
19405
19411
  } = _ref2,
19406
19412
  restWordProps = _objectWithoutPropertiesLoose(_ref2, _excluded2$g);
19407
- // Get animation names based on direction
19413
+ // Get animation functions based on direction
19408
19414
  var isUp = direction === 'up';
19409
- var enterAnim = isUp ? 'slideInUp' : 'slideInDown';
19410
- var exitAnim = isUp ? 'slideOutUp' : 'slideOutDown';
19411
19415
  // Calculate delay for each word
19412
- var getDelay = (index, isExit) => {
19416
+ var getDelay = index => {
19413
19417
  if (sequential) {
19414
19418
  // Sequential: one word at a time
19415
19419
  return index * (duration + stagger);
@@ -19431,9 +19435,6 @@ var SlideEffect = _ref => {
19431
19435
  flexWrap: 'nowrap',
19432
19436
  whiteSpace: 'nowrap'
19433
19437
  }), []);
19434
- // Determine current animation
19435
- var currentAnim = phase === 'exiting' ? exitAnim : enterAnim;
19436
- var isAnimating = phase === 'entering' || phase === 'exiting';
19437
19438
  return /*#__PURE__*/React__default.createElement(appStudio.Element, Object.assign({
19438
19439
  as: "span",
19439
19440
  style: containerStyle
@@ -19442,17 +19443,63 @@ var SlideEffect = _ref => {
19442
19443
  }, words.map((word, index) => {
19443
19444
  var delay = getDelay(index);
19444
19445
  var isLast = index === words.length - 1;
19446
+ // Create animation based on phase and direction
19447
+ var wordAnimation;
19448
+ var durationStr = duration + "ms";
19449
+ var delayStr = delay + "ms";
19450
+ if (phase === 'entering') {
19451
+ // Use app-studio animations for entering
19452
+ wordAnimation = isUp ? appStudio.Animation.slideInUp({
19453
+ duration: durationStr,
19454
+ delay: delayStr,
19455
+ timingFunction: 'ease-out',
19456
+ fillMode: 'both'
19457
+ }) : appStudio.Animation.slideInDown({
19458
+ duration: durationStr,
19459
+ delay: delayStr,
19460
+ timingFunction: 'ease-out',
19461
+ fillMode: 'both'
19462
+ });
19463
+ } else if (phase === 'exiting') {
19464
+ // Custom animation objects for exiting (slideOut not in app-studio yet)
19465
+ wordAnimation = isUp ? {
19466
+ from: {
19467
+ transform: 'translateY(0)',
19468
+ opacity: 1
19469
+ },
19470
+ to: {
19471
+ transform: 'translateY(-100%)',
19472
+ opacity: 0
19473
+ },
19474
+ duration: durationStr,
19475
+ delay: delayStr,
19476
+ timingFunction: 'ease-in',
19477
+ fillMode: 'both'
19478
+ } : {
19479
+ from: {
19480
+ transform: 'translateY(0)',
19481
+ opacity: 1
19482
+ },
19483
+ to: {
19484
+ transform: 'translateY(100%)',
19485
+ opacity: 0
19486
+ },
19487
+ duration: durationStr,
19488
+ delay: delayStr,
19489
+ timingFunction: 'ease-in',
19490
+ fillMode: 'both'
19491
+ };
19492
+ }
19445
19493
  var wordStyle = Object.assign({}, customWordStyle, {
19446
19494
  display: 'inline-block',
19447
19495
  marginRight: isLast ? 0 : '0.25em',
19448
- willChange: isAnimating ? 'transform, opacity' : 'auto',
19449
- animation: isAnimating ? currentAnim + " " + duration + "ms ease-out " + delay + "ms both" : 'none',
19450
19496
  transform: phase === 'visible' ? 'translateY(0)' : undefined,
19451
19497
  opacity: phase === 'visible' ? 1 : undefined
19452
19498
  });
19453
19499
  return /*#__PURE__*/React__default.createElement(appStudio.Text, Object.assign({
19454
19500
  key: animKey + "-" + index,
19455
- as: "span"
19501
+ as: "span",
19502
+ animate: wordAnimation
19456
19503
  }, restWordProps, {
19457
19504
  style: wordStyle
19458
19505
  }), word);
@@ -19461,7 +19508,7 @@ var SlideEffect = _ref => {
19461
19508
 
19462
19509
  var _excluded$$ = ["children", "highlightText", "highlightStyle", "highlightColor", "highlightSecondaryColor", "size", "responsive", "centered", "views", "highlightAnimate", "animate", "animationLoop", "highlightAnimationLoop", "highlightTypewriter", "highlightTypewriterDuration", "highlightSlide", "highlightSlideDuration", "highlightSlideStagger", "highlightSlideSequential"];
19463
19510
  function escapeRegExp(string) {
19464
- return string.replace(/[.*+?^${}()|[\\]\\/g, '\\$&');
19511
+ return string.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
19465
19512
  }
19466
19513
  var TitleView = _ref => {
19467
19514
  var {
@@ -19557,7 +19604,13 @@ var TitleView = _ref => {
19557
19604
  // Get the text to display
19558
19605
  var text = typeof finalDisplayedText === 'string' ? finalDisplayedText : typeof children === 'string' ? children : '';
19559
19606
  if (typeof text === 'string' && activeHighlightTarget) {
19560
- var pattern = new RegExp("(" + escapeRegExp(Array.isArray(activeHighlightTarget) ? activeHighlightTarget.join('|') : activeHighlightTarget) + ")", 'gi');
19607
+ var pattern = (() => {
19608
+ if (Array.isArray(activeHighlightTarget)) {
19609
+ var escaped = activeHighlightTarget.map(t => escapeRegExp(String(t)));
19610
+ return new RegExp("(" + escaped.join('|') + ")", 'gi');
19611
+ }
19612
+ return new RegExp("(" + escapeRegExp(String(activeHighlightTarget)) + ")", 'gi');
19613
+ })();
19561
19614
  var parts = [];
19562
19615
  var lastIndex = 0;
19563
19616
  var match;
@@ -28349,6 +28402,7 @@ exports.RotateIcon = RotateIcon;
28349
28402
  exports.SaveIcon = SaveIcon;
28350
28403
  exports.SearchIcon = SearchIcon;
28351
28404
  exports.Select = Select;
28405
+ exports.Selector = Selector;
28352
28406
  exports.SendIcon = SendIcon;
28353
28407
  exports.Separator = Separator;
28354
28408
  exports.SettingsIcon = SettingsIcon;