@vibeflui/react-select
v1.1.1
Published
React Select field adapter plugin for VibeFlui / FluiKit.
Downloads
433
Maintainers
Readme
@vibeflui/react-select
React Select field adapter plugin contract for VibeFlui / FluiKit.
This package keeps React Select outside core. The built-in ReactSelectField adapter includes light/dark runtime styles for the control, menu, placeholder, selected values, and multi-value chips. It follows schema.theme.colorMode first, then the nearest .fluikit-light or .dark class, so a light FluiKit screen stays light even when the operating system prefers dark mode. Register adapter components from your app or adapter wrapper:
import { FluiKitProvider } from "@vibeflui/core"
import { createReactSelectPlugin } from "@vibeflui/react-select"
import { ReactSelectAsyncAdapter } from "./ReactSelectAsyncAdapter"
const reactSelectPlugin = createReactSelectPlugin({
adapters: {
"react-select-async": ReactSelectAsyncAdapter
}
})
<FluiKitProvider plugins={[reactSelectPlugin]}>
{children}
</FluiKitProvider>Schema stays portable:
{
name: "roleId",
type: "select",
adapter: "react-select-async",
optionLoader: "loadRoles",
optionLabelKey: "name",
optionValueKey: "id"
}