Select

Forms

A borderless select trigger and a floating option list.

Live preview

Installation

Import the component from the kit. The package ships source and is transpiled by Next.js.

Import
import { Field, Select } from "@nphuonha/ui-kit";

Usage

Compose the component with your own content. All controls share the same focus, disabled and invalid states.

Usage
import { Field, Select } from "@nphuonha/ui-kit";
<Field label="Framework">
<Select options={frameworks} placeholder="Choose one" />
</Field>

Examples

Inside a field

Compose Select with Field for labels, help text and validation.

Inside a field

API Reference

Props are additive to the underlying Base UI or native element.

PropTypeDefaultDescription
optionsSelectOption[]—Value/label entries.
valuestring | null—Controlled value.
defaultValuestring | null—Uncontrolled initial value.
onValueChange(value: string | null) => void—Called when the selection changes.
placeholderstring"Select…"Text shown without a value.
disabledboolean—Disables the trigger.
errorboolean—Applies the invalid visual state.