@xqmsg/ui-core 0.24.8 → 0.24.10

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.
@@ -1034,7 +1034,7 @@ var Dropdown$1 = function Dropdown(_ref) {
1034
1034
  });
1035
1035
  };
1036
1036
 
1037
- var _excluded$1 = ["isRequired", "options", "name", "setValue", "handleOnChange", "disabled", "value", "fullOptions", "loadingOptions"];
1037
+ var _excluded$1 = ["isRequired", "options", "name", "setValue", "handleOnChange", "disabled", "value", "fullOptions", "loadingOptions", "searchable"];
1038
1038
  /**
1039
1039
  * A functional React component utilized to render the `StackedSelect` component.
1040
1040
  */
@@ -1049,6 +1049,8 @@ var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
1049
1049
  value = _ref2.value,
1050
1050
  fullOptions = _ref2.fullOptions,
1051
1051
  loadingOptions = _ref2.loadingOptions,
1052
+ _ref2$searchable = _ref2.searchable,
1053
+ searchable = _ref2$searchable === void 0 ? true : _ref2$searchable,
1052
1054
  props = _objectWithoutPropertiesLoose(_ref2, _excluded$1);
1053
1055
  var dropdownRef = useRef(null);
1054
1056
  var dropdownMenuRef = useRef(null);
@@ -1167,11 +1169,13 @@ var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
1167
1169
  }));
1168
1170
  }, [options, searchValue]);
1169
1171
  var handleInput = function handleInput(e) {
1170
- var _filteredOptions$;
1171
- var initialOptionIndex = filteredOptions.length && ((_filteredOptions$ = filteredOptions[0]) == null ? void 0 : _filteredOptions$.value) === 'section_header' ? 1 : 0;
1172
- setOptionIndex(initialOptionIndex);
1173
- var value = e.target.value;
1174
- setSearchValue(value);
1172
+ if (searchable) {
1173
+ var _filteredOptions$;
1174
+ var initialOptionIndex = filteredOptions.length && ((_filteredOptions$ = filteredOptions[0]) == null ? void 0 : _filteredOptions$.value) === 'section_header' ? 1 : 0;
1175
+ setOptionIndex(initialOptionIndex);
1176
+ var _value = e.target.value;
1177
+ setSearchValue(_value);
1178
+ }
1175
1179
  };
1176
1180
  return /*#__PURE__*/React__default.createElement(Box, {
1177
1181
  ref: dropdownRef,
@@ -1184,7 +1188,6 @@ var StackedSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2, _ref
1184
1188
  return setIsFocussed(!isFocussed);
1185
1189
  },
1186
1190
  cursor: isFocussed ? 'default' : 'pointer',
1187
- color: loadingOptions ? 'transparent' : 'inital',
1188
1191
  fontSize: "13px",
1189
1192
  value: isFocussed ? searchValue : selectedOption,
1190
1193
  autoComplete: "off",
@@ -1568,6 +1571,7 @@ var StackedMultiSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2,
1568
1571
  width: "0",
1569
1572
  autoComplete: "off",
1570
1573
  type: "text",
1574
+ ref: inputRef,
1571
1575
  tabIndex: -1,
1572
1576
  _focus: {
1573
1577
  boxShadow: 'none !important'
@@ -1589,7 +1593,7 @@ var StackedMultiSelect = /*#__PURE__*/React__default.forwardRef(function (_ref2,
1589
1593
  optionIndex: optionIndex,
1590
1594
  loading: loadingOptions
1591
1595
  }, /*#__PURE__*/React__default.createElement(Input$2, {
1592
- ref: inputRef,
1596
+ autoFocus: true,
1593
1597
  value: searchValue,
1594
1598
  onChange: handleInput,
1595
1599
  disabled: loadingOptions
@@ -1939,12 +1943,9 @@ function Input(_ref) {
1939
1943
  separators = _ref.separators,
1940
1944
  _ref$loadingOptions = _ref.loadingOptions,
1941
1945
  loadingOptions = _ref$loadingOptions === void 0 ? false : _ref$loadingOptions,
1942
- truncatePillLength = _ref.truncatePillLength;
1946
+ truncatePillLength = _ref.truncatePillLength,
1947
+ searchable = _ref.searchable;
1943
1948
  function selectedInputField(onChange, onBlur, ref, value) {
1944
- if (inputType === 'text') {
1945
- console.log(errorText);
1946
- console.log(isInvalid);
1947
- }
1948
1949
  switch (inputType) {
1949
1950
  case 'text':
1950
1951
  return /*#__PURE__*/React__default.createElement(StackedInput, {
@@ -1965,9 +1966,7 @@ function Input(_ref) {
1965
1966
  defaultValue: defaultValue,
1966
1967
  value: value,
1967
1968
  variant: variant,
1968
- label: label,
1969
- setError: setError,
1970
- clearErrors: clearErrors
1969
+ label: label
1971
1970
  });
1972
1971
  case 'radio':
1973
1972
  return /*#__PURE__*/React__default.createElement(StackedRadioGroup, {
@@ -1994,15 +1993,14 @@ function Input(_ref) {
1994
1993
  onBlur: onBlur,
1995
1994
  setValue: setValue,
1996
1995
  control: control,
1997
- setError: setError,
1998
- clearErrors: clearErrors,
1999
1996
  ref: ref,
2000
1997
  disabled: disabled,
2001
1998
  value: value,
2002
1999
  defaultValue: defaultValue,
2003
2000
  placeholder: placeholder,
2004
2001
  fullOptions: fullOptions,
2005
- loadingOptions: loadingOptions
2002
+ loadingOptions: loadingOptions,
2003
+ searchable: searchable
2006
2004
  });
2007
2005
  case 'textarea':
2008
2006
  return /*#__PURE__*/React__default.createElement(StackedTextarea, {
@@ -2119,7 +2117,7 @@ function Input(_ref) {
2119
2117
  tooltipText: tooltipText,
2120
2118
  label: label,
2121
2119
  isRequired: isRequired
2122
- }), selectedInputField(onChange ? onChange : fieldOnChange, onBlur, ref, value), isInvalid && /*#__PURE__*/React__default.createElement(FormErrorMessage, null, errorText), helperText && /*#__PURE__*/React__default.createElement(FormHelperText, null, helperText), errorText, " ", isInvalid == null ? void 0 : isInvalid.toString());
2120
+ }), selectedInputField(onChange ? onChange : fieldOnChange, onBlur, ref, value), isInvalid && /*#__PURE__*/React__default.createElement(FormErrorMessage, null, errorText), helperText && /*#__PURE__*/React__default.createElement(FormHelperText, null, helperText));
2123
2121
  }
2124
2122
  });
2125
2123
  }
@@ -3035,7 +3033,8 @@ var Workspace = function Workspace(_ref) {
3035
3033
  filled = _ref$filled === void 0 ? false : _ref$filled;
3036
3034
  if (filled) {
3037
3035
  return /*#__PURE__*/React__default.createElement(Memo$w, {
3038
- boxSize: boxSize
3036
+ width: boxSize,
3037
+ height: boxSize
3039
3038
  });
3040
3039
  }
3041
3040
  return /*#__PURE__*/React__default.createElement(Image$1, {