@7shifts/sous-chef 3.44.16 → 3.44.17

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.
@@ -30,5 +30,5 @@ type Props<T> = {
30
30
  onCreate?: (option: string) => void;
31
31
  };
32
32
  /** Component to make possible choose from a predefined options. */
33
- declare const MultiSelectField: <T extends unknown>({ name, id: inputId, value, options, onChange, onBlur, CustomOption: UserCustomOption, label, caption, error, placeholder, prefix, noOptionsMessage, disabled, closeOnSelect, menuShouldScrollIntoView: menuShouldScrollIntoViewProp, testId, isSearchable, creatableButton, onCreate }: Props<T>) => React.JSX.Element;
33
+ declare const MultiSelectField: <T extends unknown>({ name, id: inputId, value, options, onChange, onBlur, CustomOption: UserCustomOption, label, caption, error, placeholder, prefix, noOptionsMessage, disabled, closeOnSelect, menuShouldScrollIntoView, testId, isSearchable, creatableButton, onCreate }: Props<T>) => React.JSX.Element;
34
34
  export default MultiSelectField;
package/dist/index.js CHANGED
@@ -10595,18 +10595,6 @@ var PasswordField = function PasswordField(_ref) {
10595
10595
  }))));
10596
10596
  };
10597
10597
 
10598
- var useShouldScrollMenuIntoView = function useShouldScrollMenuIntoView(menuShouldScrollIntoView) {
10599
- var _useModalContext = useModalContext(),
10600
- isModalMounted = _useModalContext.isModalMounted;
10601
- if (menuShouldScrollIntoView !== undefined) {
10602
- return menuShouldScrollIntoView;
10603
- }
10604
- if (isModalMounted) {
10605
- return false;
10606
- }
10607
- return true;
10608
- };
10609
-
10610
10598
  var MultiSelectField = function MultiSelectField(_ref) {
10611
10599
  var name = _ref.name,
10612
10600
  inputId = _ref.id,
@@ -10624,13 +10612,13 @@ var MultiSelectField = function MultiSelectField(_ref) {
10624
10612
  disabled = _ref.disabled,
10625
10613
  _ref$closeOnSelect = _ref.closeOnSelect,
10626
10614
  closeOnSelect = _ref$closeOnSelect === void 0 ? false : _ref$closeOnSelect,
10627
- menuShouldScrollIntoViewProp = _ref.menuShouldScrollIntoView,
10615
+ _ref$menuShouldScroll = _ref.menuShouldScrollIntoView,
10616
+ menuShouldScrollIntoView = _ref$menuShouldScroll === void 0 ? false : _ref$menuShouldScroll,
10628
10617
  testId = _ref.testId,
10629
10618
  _ref$isSearchable = _ref.isSearchable,
10630
10619
  isSearchable = _ref$isSearchable === void 0 ? true : _ref$isSearchable,
10631
10620
  creatableButton = _ref.creatableButton,
10632
10621
  onCreate = _ref.onCreate;
10633
- var menuShouldScrollIntoView = useShouldScrollMenuIntoView(menuShouldScrollIntoViewProp);
10634
10622
  var _useState = React.useState(false),
10635
10623
  isMenuInputFocus = _useState[0],
10636
10624
  setIsMenuInputFocus = _useState[1];