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AAK,GAAS,EAAK,YAAW,KAAK,KAAK,GAClE,CAAC,EAAM,cAAe,EAAa,IAChC,GAAkB,EAAI,cAAc,UAAS,IAC7C,GACqB,EAAI,oBAAoB,KAAK,eAAe,QAAS,IAAK,MAE5E,GACN,CAAC,EAAW,EAAY,IACrB,GAAiB,EAAI,cAAc,UACvC,IAAM,EAAM,QAAyB,EAAI,oBAAoB,KAAK,eAAe,gBAAiB,IAAK,IAAmB,UAA0B,EAAI,oBAAoB,KAAK,qBAAqB,aAAc,IAAK,IAA0B,UAA0B,EAAI,oBAAoB,KAAK,eAAe,QAAS,IAAK,UAA6B,MACpW,CAAC,EAAM,OAAQ,EAAiB,EAAO,EAAY,EAAwB,IAE7E,OAAuB,EAAI,oBAAoB,MAAM,MAAO,IAAK,IAAgB,SAAU,EACzE,EAAI,oBAAoB,KAAK,aAAc,IAAK,MAChE,EAAuB,EAAe,MACtB,EAAI,oBAAoB,MAAM,MAAO,IAAK,IAAuB,SAAU,EACzE,EAAI,oBAAoB,MAAM,EAAW,IAAK,IAAmB,SAAU,CACxF,EAAsC,KAAf,GACR,EAAI,oBAAoB,MAAM,MAAO,IAAK,IAAwB,SAAU,CAC1F,GACgB,EAAI,oBAAoB,KAAK,OAAQ,IAAK,IAAiB,SAAU,IACrF,GAAc,EAAM,gBAAiC,EAAI,oBAAoB,KAAK,wBAAwB,eAAgB,CAAE,YAAa,OAAQ,SAAU,MAC3J,KAEF,KAEF,KAEF,EAAmB,GAAiC,EAAI,oBAAoB,KAAK,qBAAqB,gBAAiB,CAAE,SAAU,MAEvI,IACI,eAAiB","file":"/npm/@nextui-org/select@2.4.9/dist/index.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.39.0.\n * Original file: /npm/@nextui-org/select@2.4.9/dist/index.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","\"use client\";\n\"use strict\";\nvar __defProp = Object.defineProperty;\nvar __getOwnPropDesc = Object.getOwnPropertyDescriptor;\nvar __getOwnPropNames = Object.getOwnPropertyNames;\nvar __hasOwnProp = Object.prototype.hasOwnProperty;\nvar __export = (target, all) => {\n  for (var name in all)\n    __defProp(target, name, { get: all[name], enumerable: true });\n};\nvar __copyProps = (to, from, except, desc) => {\n  if (from && typeof from === \"object\" || typeof from === \"function\") {\n    for (let key of __getOwnPropNames(from))\n      if (!__hasOwnProp.call(to, key) && key !== except)\n        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });\n  }\n  return to;\n};\nvar __toCommonJS = (mod) => __copyProps(__defProp({}, \"__esModule\", { value: true }), mod);\n\n// src/index.ts\nvar src_exports = {};\n__export(src_exports, {\n  HiddenSelect: () => HiddenSelect,\n  Select: () => select_default,\n  SelectItem: () => import_listbox2.ListboxItem,\n  SelectSection: () => import_listbox2.ListboxSection,\n  useSelect: () => useSelect\n});\nmodule.exports = __toCommonJS(src_exports);\nvar import_listbox2 = require(\"@nextui-org/listbox\");\n\n// src/select.tsx\nvar import_listbox = require(\"@nextui-org/listbox\");\nvar import_popover = require(\"@nextui-org/popover\");\nvar import_shared_icons = require(\"@nextui-org/shared-icons\");\nvar import_spinner = require(\"@nextui-org/spinner\");\nvar import_react2 = require(\"react\");\nvar import_system2 = require(\"@nextui-org/system\");\nvar import_scroll_shadow = require(\"@nextui-org/scroll-shadow\");\nvar import_react3 = require(\"react\");\nvar import_visually_hidden2 = require(\"@react-aria/visually-hidden\");\nvar import_framer_motion = require(\"framer-motion\");\n\n// src/hidden-select.tsx\nvar import_utils2 = require(\"@react-aria/utils\");\nvar import_visually_hidden = require(\"@react-aria/visually-hidden\");\nvar import_form2 = require(\"@react-aria/form\");\n\n// src/use-select.ts\nvar import_system = require(\"@nextui-org/system\");\nvar import_theme = require(\"@nextui-org/theme\");\nvar import_react_utils = require(\"@nextui-org/react-utils\");\nvar import_react = require(\"react\");\nvar import_use_aria_button = require(\"@nextui-org/use-aria-button\");\nvar import_focus = require(\"@react-aria/focus\");\nvar import_shared_utils = require(\"@nextui-org/shared-utils\");\nvar import_utils = require(\"@react-aria/utils\");\nvar import_interactions = require(\"@react-aria/interactions\");\nvar import_use_aria_multiselect = require(\"@nextui-org/use-aria-multiselect\");\nvar import_use_safe_layout_effect = require(\"@nextui-org/use-safe-layout-effect\");\nvar import_aria_utils = require(\"@nextui-org/aria-utils\");\nvar import_form = require(\"@nextui-org/form\");\nvar selectData = /* @__PURE__ */ new WeakMap();\nfunction useSelect(originalProps) {\n  var _a, _b, _c, _d, _e, _f;\n  const globalContext = (0, import_system.useProviderContext)();\n  const { validationBehavior: formValidationBehavior } = (0, import_form.useSlottedContext)(import_form.FormContext) || {};\n  const [props, variantProps] = (0, import_system.mapPropsVariants)(originalProps, import_theme.select.variantKeys);\n  const disableAnimation = (_b = (_a = originalProps.disableAnimation) != null ? _a : globalContext == null ? void 0 : globalContext.disableAnimation) != null ? _b : false;\n  const {\n    ref,\n    as,\n    label,\n    name,\n    isLoading,\n    selectorIcon,\n    isOpen,\n    defaultOpen,\n    onOpenChange,\n    startContent,\n    endContent,\n    description,\n    renderValue,\n    onSelectionChange,\n    placeholder,\n    isVirtualized,\n    itemHeight = 36,\n    maxListboxHeight = 256,\n    children,\n    disallowEmptySelection = false,\n    selectionMode = \"single\",\n    spinnerRef,\n    scrollRef: scrollRefProp,\n    popoverProps = {},\n    scrollShadowProps = {},\n    listboxProps = {},\n    spinnerProps = {},\n    validationState,\n    onChange,\n    onClose,\n    className,\n    classNames,\n    validationBehavior = (_c = formValidationBehavior != null ? formValidationBehavior : globalContext == null ? void 0 : globalContext.validationBehavior) != null ? _c : \"native\",\n    hideEmptyContent = false,\n    ...otherProps\n  } = props;\n  const scrollShadowRef = (0, import_react_utils.useDOMRef)(scrollRefProp);\n  const slotsProps = {\n    popoverProps: (0, import_utils.mergeProps)(\n      {\n        placement: \"bottom\",\n        triggerScaleOnOpen: false,\n        offset: 5,\n        disableAnimation\n      },\n      popoverProps\n    ),\n    scrollShadowProps: (0, import_utils.mergeProps)(\n      {\n        ref: scrollShadowRef,\n        isEnabled: (_d = originalProps.showScrollIndicators) != null ? _d : true,\n        hideScrollBar: true,\n        offset: 15\n      },\n      scrollShadowProps\n    ),\n    listboxProps: (0, import_utils.mergeProps)(\n      {\n        disableAnimation\n      },\n      listboxProps\n    )\n  };\n  const Component = as || \"button\";\n  const shouldFilterDOMProps = typeof Component === \"string\";\n  const domRef = (0, import_react_utils.useDOMRef)(ref);\n  const triggerRef = (0, import_react.useRef)(null);\n  const listBoxRef = (0, import_react.useRef)(null);\n  const popoverRef = (0, import_react.useRef)(null);\n  let state = (0, import_use_aria_multiselect.useMultiSelectState)({\n    ...props,\n    isOpen,\n    selectionMode,\n    disallowEmptySelection,\n    validationBehavior,\n    children,\n    isRequired: originalProps.isRequired,\n    isDisabled: originalProps.isDisabled,\n    isInvalid: originalProps.isInvalid,\n    defaultOpen,\n    hideEmptyContent,\n    onOpenChange: (open) => {\n      onOpenChange == null ? void 0 : onOpenChange(open);\n      if (!open) {\n        onClose == null ? void 0 : onClose();\n      }\n    },\n    onSelectionChange: (keys) => {\n      onSelectionChange == null ? void 0 : onSelectionChange(keys);\n      if (onChange && typeof onChange === \"function\") {\n        onChange({\n          target: {\n            ...domRef.current && {\n              ...domRef.current,\n              name: domRef.current.name\n            },\n            value: Array.from(keys).join(\",\")\n          }\n        });\n      }\n      state.commitValidation();\n    }\n  });\n  state = {\n    ...state,\n    ...originalProps.isDisabled && {\n      disabledKeys: /* @__PURE__ */ new Set([...state.collection.getKeys()])\n    }\n  };\n  (0, import_use_safe_layout_effect.useSafeLayoutEffect)(() => {\n    var _a2;\n    if (!((_a2 = domRef.current) == null ? void 0 : _a2.value))\n      return;\n    state.setSelectedKeys(/* @__PURE__ */ new Set([...state.selectedKeys, domRef.current.value]));\n  }, [domRef.current]);\n  const {\n    labelProps,\n    triggerProps,\n    valueProps,\n    menuProps,\n    descriptionProps,\n    errorMessageProps,\n    isInvalid: isAriaInvalid,\n    validationErrors,\n    validationDetails\n  } = (0, import_use_aria_multiselect.useMultiSelect)(\n    { ...props, disallowEmptySelection, isDisabled: originalProps.isDisabled },\n    state,\n    triggerRef\n  );\n  const isInvalid = originalProps.isInvalid || validationState === \"invalid\" || isAriaInvalid;\n  const { isPressed, buttonProps } = (0, import_use_aria_button.useAriaButton)(triggerProps, triggerRef);\n  const { focusProps, isFocused, isFocusVisible } = (0, import_focus.useFocusRing)();\n  const { isHovered, hoverProps } = (0, import_interactions.useHover)({ isDisabled: originalProps.isDisabled });\n  const labelPlacement = (0, import_react.useMemo)(() => {\n    var _a2;\n    if ((!originalProps.labelPlacement || originalProps.labelPlacement === \"inside\") && !label) {\n      return \"outside\";\n    }\n    return (_a2 = originalProps.labelPlacement) != null ? _a2 : \"inside\";\n  }, [originalProps.labelPlacement, label]);\n  const hasPlaceholder = !!placeholder;\n  const shouldLabelBeOutside = labelPlacement === \"outside-left\" || labelPlacement === \"outside\" && (!(hasPlaceholder || !!description) || !!originalProps.isMultiline);\n  const shouldLabelBeInside = labelPlacement === \"inside\";\n  const isOutsideLeft = labelPlacement === \"outside-left\";\n  const isFilled = state.isOpen || hasPlaceholder || !!((_e = state.selectedItems) == null ? void 0 : _e.length) || !!startContent || !!endContent || !!originalProps.isMultiline;\n  const hasValue = !!((_f = state.selectedItems) == null ? void 0 : _f.length);\n  const hasLabel = !!label;\n  const baseStyles = (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.base, className);\n  const slots = (0, import_react.useMemo)(\n    () => (0, import_theme.select)({\n      ...variantProps,\n      isInvalid,\n      labelPlacement,\n      disableAnimation,\n      className\n    }),\n    [(0, import_shared_utils.objectToDeps)(variantProps), isInvalid, labelPlacement, disableAnimation, className]\n  );\n  (0, import_react.useEffect)(() => {\n    if (state.isOpen && popoverRef.current && listBoxRef.current) {\n      let selectedItem = listBoxRef.current.querySelector(\"[aria-selected=true] [data-label=true]\");\n      let scrollShadow = scrollShadowRef.current;\n      if (selectedItem && scrollShadow && selectedItem.parentElement) {\n        let scrollShadowRect = scrollShadow == null ? void 0 : scrollShadow.getBoundingClientRect();\n        let scrollShadowHeight = scrollShadowRect.height;\n        scrollShadow.scrollTop = selectedItem.parentElement.offsetTop - scrollShadowHeight / 2 + selectedItem.parentElement.clientHeight / 2;\n      }\n    }\n  }, [state.isOpen, disableAnimation]);\n  const errorMessage = typeof props.errorMessage === \"function\" ? props.errorMessage({ isInvalid, validationErrors, validationDetails }) : props.errorMessage || (validationErrors == null ? void 0 : validationErrors.join(\" \"));\n  const hasHelper = !!description || !!errorMessage;\n  (0, import_react.useEffect)(() => {\n    if (state.isOpen && popoverRef.current && triggerRef.current) {\n      let selectRect = triggerRef.current.getBoundingClientRect();\n      let popover = popoverRef.current;\n      popover.style.width = selectRect.width + \"px\";\n    }\n  }, [state.isOpen]);\n  const getBaseProps = (0, import_react.useCallback)(\n    (props2 = {}) => ({\n      \"data-slot\": \"base\",\n      \"data-filled\": (0, import_shared_utils.dataAttr)(isFilled),\n      \"data-has-value\": (0, import_shared_utils.dataAttr)(hasValue),\n      \"data-has-label\": (0, import_shared_utils.dataAttr)(hasLabel),\n      \"data-has-helper\": (0, import_shared_utils.dataAttr)(hasHelper),\n      \"data-invalid\": (0, import_shared_utils.dataAttr)(isInvalid),\n      className: slots.base({\n        class: (0, import_shared_utils.clsx)(baseStyles, props2.className)\n      }),\n      ...props2\n    }),\n    [slots, hasHelper, hasValue, hasLabel, isFilled, baseStyles]\n  );\n  const getTriggerProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ref: triggerRef,\n        \"data-slot\": \"trigger\",\n        \"data-open\": (0, import_shared_utils.dataAttr)(state.isOpen),\n        \"data-disabled\": (0, import_shared_utils.dataAttr)(originalProps == null ? void 0 : originalProps.isDisabled),\n        \"data-focus\": (0, import_shared_utils.dataAttr)(isFocused),\n        \"data-pressed\": (0, import_shared_utils.dataAttr)(isPressed),\n        \"data-focus-visible\": (0, import_shared_utils.dataAttr)(isFocusVisible),\n        \"data-hover\": (0, import_shared_utils.dataAttr)(isHovered),\n        className: slots.trigger({ class: classNames == null ? void 0 : classNames.trigger }),\n        ...(0, import_utils.mergeProps)(\n          buttonProps,\n          focusProps,\n          hoverProps,\n          (0, import_react_utils.filterDOMProps)(otherProps, {\n            enabled: shouldFilterDOMProps\n          }),\n          (0, import_react_utils.filterDOMProps)(props2)\n        )\n      };\n    },\n    [\n      slots,\n      triggerRef,\n      state.isOpen,\n      classNames == null ? void 0 : classNames.trigger,\n      originalProps == null ? void 0 : originalProps.isDisabled,\n      isFocused,\n      isPressed,\n      isFocusVisible,\n      isHovered,\n      buttonProps,\n      focusProps,\n      hoverProps,\n      otherProps,\n      shouldFilterDOMProps\n    ]\n  );\n  const getHiddenSelectProps = (0, import_react.useCallback)(\n    (props2 = {}) => ({\n      state,\n      triggerRef,\n      selectRef: domRef,\n      selectionMode,\n      label: originalProps == null ? void 0 : originalProps.label,\n      name: originalProps == null ? void 0 : originalProps.name,\n      isRequired: originalProps == null ? void 0 : originalProps.isRequired,\n      autoComplete: originalProps == null ? void 0 : originalProps.autoComplete,\n      isDisabled: originalProps == null ? void 0 : originalProps.isDisabled,\n      onChange,\n      ...props2\n    }),\n    [\n      state,\n      selectionMode,\n      originalProps == null ? void 0 : originalProps.label,\n      originalProps == null ? void 0 : originalProps.autoComplete,\n      originalProps == null ? void 0 : originalProps.name,\n      originalProps == null ? void 0 : originalProps.isDisabled,\n      triggerRef\n    ]\n  );\n  const getLabelProps = (0, import_react.useCallback)(\n    (props2 = {}) => ({\n      \"data-slot\": \"label\",\n      className: slots.label({\n        class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.label, props2.className)\n      }),\n      ...labelProps,\n      ...props2\n    }),\n    [slots, classNames == null ? void 0 : classNames.label, labelProps]\n  );\n  const getValueProps = (0, import_react.useCallback)(\n    (props2 = {}) => ({\n      \"data-slot\": \"value\",\n      className: slots.value({\n        class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.value, props2.className)\n      }),\n      ...valueProps,\n      ...props2\n    }),\n    [slots, classNames == null ? void 0 : classNames.value, valueProps]\n  );\n  const getListboxWrapperProps = (0, import_react.useCallback)(\n    (props2 = {}) => ({\n      \"data-slot\": \"listboxWrapper\",\n      className: slots.listboxWrapper({\n        class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.listboxWrapper, props2 == null ? void 0 : props2.className)\n      }),\n      style: {\n        maxHeight: maxListboxHeight != null ? maxListboxHeight : 256,\n        ...props2.style\n      },\n      ...(0, import_utils.mergeProps)(slotsProps.scrollShadowProps, props2)\n    }),\n    [\n      slots.listboxWrapper,\n      classNames == null ? void 0 : classNames.listboxWrapper,\n      slotsProps.scrollShadowProps,\n      maxListboxHeight\n    ]\n  );\n  const getListboxProps = (props2 = {}) => {\n    const shouldVirtualize = isVirtualized != null ? isVirtualized : state.collection.size > 50;\n    return {\n      state,\n      ref: listBoxRef,\n      isVirtualized: shouldVirtualize,\n      virtualization: shouldVirtualize ? {\n        maxListboxHeight,\n        itemHeight\n      } : void 0,\n      \"data-slot\": \"listbox\",\n      className: slots.listbox({\n        class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.listbox, props2 == null ? void 0 : props2.className)\n      }),\n      scrollShadowProps: slotsProps.scrollShadowProps,\n      ...(0, import_utils.mergeProps)(slotsProps.listboxProps, props2, menuProps)\n    };\n  };\n  const getPopoverProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      var _a2, _b2;\n      const popoverProps2 = (0, import_utils.mergeProps)(slotsProps.popoverProps, props2);\n      return {\n        state,\n        triggerRef,\n        ref: popoverRef,\n        \"data-slot\": \"popover\",\n        scrollRef: listBoxRef,\n        triggerType: \"listbox\",\n        classNames: {\n          content: slots.popoverContent({\n            class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.popoverContent, props2.className)\n          })\n        },\n        ...popoverProps2,\n        offset: state.selectedItems && state.selectedItems.length > 0 ? state.selectedItems.length * 1e-8 + (((_a2 = slotsProps.popoverProps) == null ? void 0 : _a2.offset) || 0) : (_b2 = slotsProps.popoverProps) == null ? void 0 : _b2.offset,\n        shouldCloseOnInteractOutside: (popoverProps2 == null ? void 0 : popoverProps2.shouldCloseOnInteractOutside) ? popoverProps2.shouldCloseOnInteractOutside : (element) => (0, import_aria_utils.ariaShouldCloseOnInteractOutside)(element, domRef, state)\n      };\n    },\n    [\n      slots,\n      classNames == null ? void 0 : classNames.popoverContent,\n      slotsProps.popoverProps,\n      triggerRef,\n      state,\n      state.selectedItems\n    ]\n  );\n  const getSelectorIconProps = (0, import_react.useCallback)(\n    () => ({\n      \"data-slot\": \"selectorIcon\",\n      \"aria-hidden\": (0, import_shared_utils.dataAttr)(true),\n      \"data-open\": (0, import_shared_utils.dataAttr)(state.isOpen),\n      className: slots.selectorIcon({ class: classNames == null ? void 0 : classNames.selectorIcon })\n    }),\n    [slots, classNames == null ? void 0 : classNames.selectorIcon, state.isOpen]\n  );\n  const getInnerWrapperProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ...props2,\n        \"data-slot\": \"innerWrapper\",\n        className: slots.innerWrapper({\n          class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.innerWrapper, props2 == null ? void 0 : props2.className)\n        })\n      };\n    },\n    [slots, classNames == null ? void 0 : classNames.innerWrapper]\n  );\n  const getHelperWrapperProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ...props2,\n        \"data-slot\": \"helperWrapper\",\n        className: slots.helperWrapper({\n          class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.helperWrapper, props2 == null ? void 0 : props2.className)\n        })\n      };\n    },\n    [slots, classNames == null ? void 0 : classNames.helperWrapper]\n  );\n  const getDescriptionProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ...props2,\n        ...descriptionProps,\n        \"data-slot\": \"description\",\n        className: slots.description({ class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.description, props2 == null ? void 0 : props2.className) })\n      };\n    },\n    [slots, classNames == null ? void 0 : classNames.description]\n  );\n  const getMainWrapperProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ...props2,\n        \"data-slot\": \"mainWrapper\",\n        className: slots.mainWrapper({\n          class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.mainWrapper, props2 == null ? void 0 : props2.className)\n        })\n      };\n    },\n    [slots, classNames == null ? void 0 : classNames.mainWrapper]\n  );\n  const getErrorMessageProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        ...props2,\n        ...errorMessageProps,\n        \"data-slot\": \"error-message\",\n        className: slots.errorMessage({ class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.errorMessage, props2 == null ? void 0 : props2.className) })\n      };\n    },\n    [slots, errorMessageProps, classNames == null ? void 0 : classNames.errorMessage]\n  );\n  const getSpinnerProps = (0, import_react.useCallback)(\n    (props2 = {}) => {\n      return {\n        \"aria-hidden\": (0, import_shared_utils.dataAttr)(true),\n        \"data-slot\": \"spinner\",\n        color: \"current\",\n        size: \"sm\",\n        ...spinnerProps,\n        ...props2,\n        ref: spinnerRef,\n        className: slots.spinner({ class: (0, import_shared_utils.clsx)(classNames == null ? void 0 : classNames.spinner, props2 == null ? void 0 : props2.className) })\n      };\n    },\n    [slots, spinnerRef, spinnerProps, classNames == null ? void 0 : classNames.spinner]\n  );\n  selectData.set(state, {\n    isDisabled: originalProps == null ? void 0 : originalProps.isDisabled,\n    isRequired: originalProps == null ? void 0 : originalProps.isRequired,\n    name: originalProps == null ? void 0 : originalProps.name,\n    isInvalid,\n    validationBehavior\n  });\n  return {\n    Component,\n    domRef,\n    state,\n    label,\n    name,\n    triggerRef,\n    isLoading,\n    placeholder,\n    startContent,\n    endContent,\n    description,\n    selectorIcon,\n    hasHelper,\n    labelPlacement,\n    hasPlaceholder,\n    renderValue,\n    selectionMode,\n    disableAnimation,\n    isOutsideLeft,\n    shouldLabelBeOutside,\n    shouldLabelBeInside,\n    isInvalid,\n    errorMessage,\n    getBaseProps,\n    getTriggerProps,\n    getLabelProps,\n    getValueProps,\n    getListboxProps,\n    getPopoverProps,\n    getSpinnerProps,\n    getMainWrapperProps,\n    getListboxWrapperProps,\n    getHiddenSelectProps,\n    getInnerWrapperProps,\n    getHelperWrapperProps,\n    getDescriptionProps,\n    getErrorMessageProps,\n    getSelectorIconProps\n  };\n}\n\n// src/hidden-select.tsx\nvar import_jsx_runtime = require(\"react/jsx-runtime\");\nfunction useHiddenSelect(props, state, triggerRef) {\n  var _a;\n  let data = selectData.get(state) || {};\n  let {\n    autoComplete,\n    name = data.name,\n    isDisabled = data.isDisabled,\n    selectionMode,\n    onChange\n  } = props;\n  let { validationBehavior, isRequired, isInvalid } = data;\n  let { visuallyHiddenProps } = (0, import_visually_hidden.useVisuallyHidden)();\n  (0, import_utils2.useFormReset)(props.selectRef, state.selectedKeys, state.setSelectedKeys);\n  (0, import_form2.useFormValidation)(\n    {\n      validationBehavior,\n      focus: () => {\n        var _a2;\n        return (_a2 = triggerRef.current) == null ? void 0 : _a2.focus();\n      }\n    },\n    state,\n    props.selectRef\n  );\n  return {\n    containerProps: {\n      ...visuallyHiddenProps,\n      \"aria-hidden\": true,\n      [\"data-a11y-ignore\"]: \"aria-hidden-focus\"\n    },\n    inputProps: {\n      style: { display: \"none\" }\n    },\n    selectProps: {\n      autoComplete,\n      disabled: isDisabled,\n      \"aria-invalid\": isInvalid || void 0,\n      \"aria-required\": isRequired && validationBehavior === \"aria\" || void 0,\n      required: isRequired && validationBehavior === \"native\",\n      name,\n      tabIndex: -1,\n      value: selectionMode === \"multiple\" ? [...state.selectedKeys].map((k) => String(k)) : (_a = [...state.selectedKeys][0]) != null ? _a : \"\",\n      multiple: selectionMode === \"multiple\",\n      onChange: (e) => {\n        state.setSelectedKeys(e.target.value);\n        onChange == null ? void 0 : onChange(e);\n      }\n    }\n  };\n}\nfunction HiddenSelect(props) {\n  var _a;\n  let { state, triggerRef, selectRef, label, name, isDisabled } = props;\n  let { containerProps, selectProps } = useHiddenSelect({ ...props, selectRef }, state, triggerRef);\n  if (state.collection.size <= 300) {\n    return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\"div\", { ...containerProps, \"data-testid\": \"hidden-select-container\", children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(\"label\", { children: [\n      label,\n      /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(\"select\", { ...selectProps, ref: selectRef, children: [\n        /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\"option\", {}),\n        [...state.collection.getKeys()].map((key) => {\n          let item = state.collection.getItem(key);\n          if ((item == null ? void 0 : item.type) === \"item\") {\n            return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\"option\", { value: item.key, children: item.textValue }, item.key);\n          }\n        })\n      ] })\n    ] }) });\n  } else if (name) {\n    return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(\n      \"input\",\n      {\n        autoComplete: selectProps.autoComplete,\n        disabled: isDisabled,\n        name,\n        type: \"hidden\",\n        value: (_a = [...state.selectedKeys].join(\",\")) != null ? _a : \"\"\n      }\n    );\n  }\n  return null;\n}\n\n// src/select.tsx\nvar import_jsx_runtime2 = require(\"react/jsx-runtime\");\nvar Select = (0, import_system2.forwardRef)(function Select2(props, ref) {\n  const {\n    Component,\n    state,\n    label,\n    hasHelper,\n    isLoading,\n    triggerRef,\n    selectorIcon = /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_shared_icons.ChevronDownIcon, {}),\n    description,\n    errorMessage,\n    isInvalid,\n    startContent,\n    endContent,\n    placeholder,\n    renderValue,\n    shouldLabelBeOutside,\n    disableAnimation,\n    getBaseProps,\n    getLabelProps,\n    getTriggerProps,\n    getValueProps,\n    getListboxProps,\n    getPopoverProps,\n    getSpinnerProps,\n    getMainWrapperProps,\n    getInnerWrapperProps,\n    getHiddenSelectProps,\n    getHelperWrapperProps,\n    getListboxWrapperProps,\n    getDescriptionProps,\n    getErrorMessageProps,\n    getSelectorIconProps\n  } = useSelect({ ...props, ref });\n  const labelContent = label ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(\"label\", { ...getLabelProps(), children: label }) : null;\n  const clonedIcon = (0, import_react3.cloneElement)(selectorIcon, getSelectorIconProps());\n  const helperWrapper = (0, import_react2.useMemo)(() => {\n    const shouldShowError = isInvalid && errorMessage;\n    const hasContent = shouldShowError || description;\n    if (!hasHelper || !hasContent)\n      return null;\n    return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(\"div\", { ...getHelperWrapperProps(), children: shouldShowError ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(\"div\", { ...getErrorMessageProps(), children: errorMessage }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(\"div\", { ...getDescriptionProps(), children: description }) });\n  }, [\n    hasHelper,\n    isInvalid,\n    errorMessage,\n    description,\n    getHelperWrapperProps,\n    getErrorMessageProps,\n    getDescriptionProps\n  ]);\n  const renderSelectedItem = (0, import_react2.useMemo)(() => {\n    var _a;\n    if (!((_a = state.selectedItems) == null ? void 0 : _a.length))\n      return placeholder;\n    if (renderValue && typeof renderValue === \"function\") {\n      const mappedItems = [...state.selectedItems].map((item) => ({\n        key: item.key,\n        data: item.value,\n        type: item.type,\n        props: item.props,\n        textValue: item.textValue,\n        rendered: item.rendered,\n        \"aria-label\": item[\"aria-label\"]\n      }));\n      return renderValue(mappedItems);\n    }\n    return state.selectedItems.map((item) => item.textValue).join(\", \");\n  }, [state.selectedItems, renderValue, placeholder]);\n  const renderIndicator = (0, import_react2.useMemo)(() => {\n    if (isLoading) {\n      return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_spinner.Spinner, { ...getSpinnerProps() });\n    }\n    return clonedIcon;\n  }, [isLoading, clonedIcon, getSpinnerProps]);\n  const popoverContent = (0, import_react2.useMemo)(\n    () => state.isOpen ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_popover.FreeSoloPopover, { ...getPopoverProps(), children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_scroll_shadow.ScrollShadow, { ...getListboxWrapperProps(), children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_listbox.Listbox, { ...getListboxProps() }) }) }) : null,\n    [state.isOpen, getPopoverProps, state, triggerRef, getListboxWrapperProps, getListboxProps]\n  );\n  return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(\"div\", { ...getBaseProps(), children: [\n    /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(HiddenSelect, { ...getHiddenSelectProps() }),\n    shouldLabelBeOutside ? labelContent : null,\n    /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(\"div\", { ...getMainWrapperProps(), children: [\n      /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(Component, { ...getTriggerProps(), children: [\n        !shouldLabelBeOutside ? labelContent : null,\n        /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(\"div\", { ...getInnerWrapperProps(), children: [\n          startContent,\n          /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(\"span\", { ...getValueProps(), children: renderSelectedItem }),\n          endContent && state.selectedItems && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_visually_hidden2.VisuallyHidden, { elementType: \"span\", children: \",\" }),\n          endContent\n        ] }),\n        renderIndicator\n      ] }),\n      helperWrapper\n    ] }),\n    disableAnimation ? popoverContent : /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_framer_motion.AnimatePresence, { children: popoverContent })\n  ] });\n});\nvar select_default = Select;\n// Annotate the CommonJS export names for ESM import in node:\n0 && (module.exports = {\n  HiddenSelect,\n  Select,\n  SelectItem,\n  SelectSection,\n  useSelect\n});\n"]}