/** * @usevyre/react — Select / Dropdown * * AI CONTEXT: * ┌─────────────────────────────────────────────────────────┐ * │ Component: Select │ * │ Import: import { Select } from "@usevyre/react" │ * │ │ * │ Props: │ * │ options = { value: string; label: string; │ * │ disabled?: boolean }[] │ * │ value = string (controlled) │ * │ defaultValue = string (uncontrolled) │ * │ onChange = (value: string) => void │ * │ placeholder = string │ * │ disabled = boolean │ * │ size = "sm"|"md"(default)|"lg" │ * │ disablePortal = boolean (default: false) — render the │ * │ dropdown inline instead of portaling │ * │ it to . Portaling (default) keeps │ * │ the dropdown visible inside Modal / │ * │ overflow:hidden containers. │ * │ + all native
props │ * └─────────────────────────────────────────────────────────┘ * * @example * // Controlled * * */ import React from "react"; import type { BaseProps } from "../../types"; export interface SelectOption { value: string; label: string; disabled?: boolean; } export type SelectSize = "sm" | "md" | "lg"; export interface SelectProps extends Omit, "onChange">, BaseProps { options: SelectOption[]; value?: string; defaultValue?: string; onChange?: (value: string) => void; placeholder?: string; disabled?: boolean; size?: SelectSize; /** * Render the dropdown inline inside the component instead of teleporting it * to . Default false: the dropdown portals to body so it stays visible * inside Modal / overflow:hidden containers. */ disablePortal?: boolean; } export declare const Select: React.ForwardRefExoticComponent>;