{"version":3,"file":"NativeSelectInput.mjs","sources":["../../../../../../../../node_modules/@mui/material/NativeSelect/NativeSelectInput.js"],"sourcesContent":["'use client';\n\nimport * as React from 'react';\nimport PropTypes from 'prop-types';\nimport clsx from 'clsx';\nimport refType from '@mui/utils/refType';\nimport composeClasses from '@mui/utils/composeClasses';\nimport capitalize from \"../utils/capitalize.js\";\nimport nativeSelectClasses, { getNativeSelectUtilityClasses } from \"./nativeSelectClasses.js\";\nimport { styled } from \"../zero-styled/index.js\";\nimport rootShouldForwardProp from \"../styles/rootShouldForwardProp.js\";\nimport { jsx as _jsx, jsxs as _jsxs } from \"react/jsx-runtime\";\nconst useUtilityClasses = ownerState => {\n  const {\n    classes,\n    variant,\n    disabled,\n    multiple,\n    open,\n    error\n  } = ownerState;\n  const slots = {\n    select: ['select', variant, disabled && 'disabled', multiple && 'multiple', error && 'error'],\n    icon: ['icon', `icon${capitalize(variant)}`, open && 'iconOpen', disabled && 'disabled']\n  };\n  return composeClasses(slots, getNativeSelectUtilityClasses, classes);\n};\nexport const StyledSelectSelect = styled('select')(({\n  theme\n}) => ({\n  // Reset\n  MozAppearance: 'none',\n  // Reset\n  WebkitAppearance: 'none',\n  // When interacting quickly, the text can end up selected.\n  // Native select can't be selected either.\n  userSelect: 'none',\n  // Reset\n  borderRadius: 0,\n  cursor: 'pointer',\n  '&:focus': {\n    // Reset Chrome style\n    borderRadius: 0\n  },\n  [`&.${nativeSelectClasses.disabled}`]: {\n    cursor: 'default'\n  },\n  '&[multiple]': {\n    height: 'auto'\n  },\n  '&:not([multiple]) option, &:not([multiple]) optgroup': {\n    backgroundColor: (theme.vars || theme).palette.background.paper\n  },\n  variants: [{\n    props: ({\n      ownerState\n    }) => ownerState.variant !== 'filled' && ownerState.variant !== 'outlined',\n    style: {\n      // Bump specificity to allow extending custom inputs\n      '&&&': {\n        paddingRight: 24,\n        minWidth: 16 // So it doesn't collapse.\n      }\n    }\n  }, {\n    props: {\n      variant: 'filled'\n    },\n    style: {\n      '&&&': {\n        paddingRight: 32\n      }\n    }\n  }, {\n    props: {\n      variant: 'outlined'\n    },\n    style: {\n      borderRadius: (theme.vars || theme).shape.borderRadius,\n      '&:focus': {\n        borderRadius: (theme.vars || theme).shape.borderRadius // Reset the reset for Chrome style\n      },\n      '&&&': {\n        paddingRight: 32\n      }\n    }\n  }]\n}));\nconst NativeSelectSelect = styled(StyledSelectSelect, {\n  name: 'MuiNativeSelect',\n  slot: 'Select',\n  shouldForwardProp: rootShouldForwardProp,\n  overridesResolver: (props, styles) => {\n    const {\n      ownerState\n    } = props;\n    return [styles.select, styles[ownerState.variant], ownerState.error && styles.error, {\n      [`&.${nativeSelectClasses.multiple}`]: styles.multiple\n    }];\n  }\n})({});\nexport const StyledSelectIcon = styled('svg')(({\n  theme\n}) => ({\n  // We use a position absolute over a flexbox in order to forward the pointer events\n  // to the input and to support wrapping tags..\n  position: 'absolute',\n  right: 0,\n  // Center vertically, height is 1em\n  top: 'calc(50% - .5em)',\n  // Don't block pointer events on the select under the icon.\n  pointerEvents: 'none',\n  color: (theme.vars || theme).palette.action.active,\n  [`&.${nativeSelectClasses.disabled}`]: {\n    color: (theme.vars || theme).palette.action.disabled\n  },\n  variants: [{\n    props: ({\n      ownerState\n    }) => ownerState.open,\n    style: {\n      transform: 'rotate(180deg)'\n    }\n  }, {\n    props: {\n      variant: 'filled'\n    },\n    style: {\n      right: 7\n    }\n  }, {\n    props: {\n      variant: 'outlined'\n    },\n    style: {\n      right: 7\n    }\n  }]\n}));\nconst NativeSelectIcon = styled(StyledSelectIcon, {\n  name: 'MuiNativeSelect',\n  slot: 'Icon',\n  overridesResolver: (props, styles) => {\n    const {\n      ownerState\n    } = props;\n    return [styles.icon, ownerState.variant && styles[`icon${capitalize(ownerState.variant)}`], ownerState.open && styles.iconOpen];\n  }\n})({});\n\n/**\n * @ignore - internal component.\n */\nconst NativeSelectInput = /*#__PURE__*/React.forwardRef(function NativeSelectInput(props, ref) {\n  const {\n    className,\n    disabled,\n    error,\n    IconComponent,\n    inputRef,\n    variant = 'standard',\n    ...other\n  } = props;\n  const ownerState = {\n    ...props,\n    disabled,\n    variant,\n    error\n  };\n  const classes = useUtilityClasses(ownerState);\n  return /*#__PURE__*/_jsxs(React.Fragment, {\n    children: [/*#__PURE__*/_jsx(NativeSelectSelect, {\n      ownerState: ownerState,\n      className: clsx(classes.select, className),\n      disabled: disabled,\n      ref: inputRef || ref,\n      ...other\n    }), props.multiple ? null : /*#__PURE__*/_jsx(NativeSelectIcon, {\n      as: IconComponent,\n      ownerState: ownerState,\n      className: classes.icon\n    })]\n  });\n});\nprocess.env.NODE_ENV !== \"production\" ? NativeSelectInput.propTypes = {\n  /**\n   * The option elements to populate the select with.\n   * Can be some `<option>` elements.\n   */\n  children: PropTypes.node,\n  /**\n   * Override or extend the styles applied to the component.\n   */\n  classes: PropTypes.object,\n  /**\n   * The CSS class name of the select element.\n   */\n  className: PropTypes.string,\n  /**\n   * If `true`, the select is disabled.\n   */\n  disabled: PropTypes.bool,\n  /**\n   * If `true`, the `select input` will indicate an error.\n   */\n  error: PropTypes.bool,\n  /**\n   * The icon that displays the arrow.\n   */\n  IconComponent: PropTypes.elementType.isRequired,\n  /**\n   * Use that prop to pass a ref to the native select element.\n   * @deprecated\n   */\n  inputRef: refType,\n  /**\n   * @ignore\n   */\n  multiple: PropTypes.bool,\n  /**\n   * Name attribute of the `select` or hidden `input` element.\n   */\n  name: PropTypes.string,\n  /**\n   * Callback fired when a menu item is selected.\n   *\n   * @param {object} event The event source of the callback.\n   * You can pull out the new value by accessing `event.target.value` (string).\n   */\n  onChange: PropTypes.func,\n  /**\n   * The input value.\n   */\n  value: PropTypes.any,\n  /**\n   * The variant to use.\n   */\n  variant: PropTypes.oneOf(['standard', 'outlined', 'filled'])\n} : void 0;\nexport default NativeSelectInput;"],"names":["useUtilityClasses","React.forwardRef","_jsxs","React.Fragment","_jsx"],"mappings":";;;;;;;;;;AAYA,MAAMA,mBAAiB,GAAG,UAAU,IAAI;AACx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