Skip to Content
Liquid Glass UI
Components

Select

Responsive Apple Liquid Glass selector presenting a floating macOS 27 Liquid Glass dropdown on desktop, and automatically switching to a swipe-to-dismiss iOS 27 bottom Liquid Glass Drawer list on mobile.

Standard shadcn/ui JSX API (<Select> / <SelectTrigger> / <SelectValue> / <SelectContent> / <SelectGroup> / <SelectItem>) that adapts automatically via useIsMobile() (768px):

  • Desktop (>= 768px · macOS 27): Powered by @base-ui/react/select, opening a floating Liquid Glass menu with #0069F9 hover highlights, trailing checkmarks, and keyboard navigation.
  • Mobile (< 768px · iOS 27): Automatically switches to a floating bottom Liquid Glass Drawer (@base-ui/react/drawer) with swipe-to-dismiss, top grabber handle, 50px+ Inset Grouped rows, and trailing Apple Blue checkmarks.

Responsive Live Preview

Displays the macOS 27 dropdown by default; click the Mobile icon top-right to experience the iOS 27 bottom Drawer, or toggle Code to inspect the full snippet:

apple-liquid-ui/preview/select-liquid-hero
MacBook · 16:10

Installation (Shadcn Registry)

# Install via the configured @apple-liquid namespace (includes drawer, use-mobile, and liquid-glass)
npx shadcn@latest add @apple-liquid/select

# Or install directly via URL
npx shadcn@latest add https://your-domain.com/r/select.json

Trigger Styles & Sizes

Triggers default to Liquid Glass (Regular - Small capsule matching Button); pass glass={false} for opaque Bordered triggers, or nest inside Dialog/Popover/glass Card for automatic Over-Glass flat fills. Supports default, sm, and disabled states:

apple-liquid-ui/preview/select-variants
MacBook · 16:10

Groups & Separators

Renders compact section headers and hairline dividers on desktop, and automatically transforms into iOS 27 Inset Grouped cards on mobile:

apple-liquid-ui/preview/select-grouped
MacBook · 16:10

Controlled State

Fully supports controlled value / onValueChange and native form submission via name / required (automatically syncs a hidden <input> in mobile Drawer mode):

apple-liquid-ui/preview/select-controlled
MacBook · 16:10

Usage

import {
  Select,
  SelectContent,
  SelectGroup,
  SelectItem,
  SelectLabel,
  SelectTrigger,
  SelectValue,
} from '@/components/ui/select';

export function Example() {
  return (
    <Select defaultValue="macbook">
      <SelectTrigger className="w-56">
        <SelectValue placeholder="Choose a device..." />
      </SelectTrigger>
      <SelectContent title="Select Apple Device">
        <SelectGroup>
          <SelectLabel>Desktop & Mobile</SelectLabel>
          <SelectItem value="macbook">MacBook Pro</SelectItem>
          <SelectItem value="iphone">iPhone 18 Pro</SelectItem>
        </SelectGroup>
      </SelectContent>
    </Select>
  );
}

Props API

SelectTrigger

PropTypeDefaultDescription
glassbooleantrueLiquid Glass control material; false renders 100% opaque Bordered equivalent; auto-switches to Over-Glass on glass surfaces
surface'default' | 'over-glass'Auto-detectedOverride surface context
size'default' | 'sm''default'Desktop 32px / 28px, automatically switches to 46px / 38px on mobile
disableMotionbooleanfalseDisable trigger press spring animation

SelectContent

PropTypeDefaultDescription
glassbooleantrueLiquid Glass material reacting to glass tint; false renders a 100% opaque surface
titleReact.ReactNode'Select'Header title shown in the mobile bottom Drawer
side / align / sideOffsetBase UI Positioner'bottom' / 'start' / 6Desktop dropdown positioning only

Language & Text

Select accepts locale and messages, which apply to all of its parts and the overlays it opens and win over the global <LiquidGlassProvider locale messages>. To override the text globally, put it under messages.select on the provider. See Liquid Glass → Global settings.

PropTypeDescription
localeLiquidGlassLocaleInputUI language of this component (any BCP 47 tag; unsupported ones fall back to English)
messagesPartial<SelectMessages>Text overrides, merged over the built-in text and the global messages.select
KeyBuilt-in text (English)
titleSelect

On this page