Wensity Labs

Select

Forms

About

A custom select dropdown with grouped options, descriptions, leading icons and animated open states. Built on Base UI for keyboard and screen reader support in forms, filters and settings.

Built with React and Tailwind. Copy the prompt and paste it into Claude Code, Cursor or Lovable: your agent adds Select to your project and fits it to your theme.

Code

How Select is used: the demo's code. The component's own source comes with a free account.

Usage.tsx

"use client";

import * as React from "react";
import { IconCloud, IconGlobe, IconMapPin } from "@tabler/icons-react";
import { Select } from "@/components/ui/select";

function PreviewColumn({
  children,
  className,
}: {
  children: React.ReactNode;
  className?: string;
}) {
  return (
    <div className={["w-full max-w-[20rem] px-4", className].filter(Boolean).join(" ")}>
      {children}
    </div>
  );
}

const regionOptions = [
  {
    value: "iad",
    label: "US East",
    description: "Virginia, low latency for North America.",
    leading: <IconMapPin stroke={1.75} />,
    trailing: "IAD",
  },
  {
    value: "fra",
    label: "Europe",
    description: "Frankfurt, balanced coverage for EU users.",
    leading: <IconGlobe stroke={1.75} />,
    trailing: "FRA",
  },
  {
    value: "sin",
    label: "Asia Pacific",
    description: "Singapore, close to APAC traffic.",
    leading: <IconCloud stroke={1.75} />,
    trailing: "SIN",
  },
];

export function SelectPreview() {
  return (
    <PreviewColumn>
      <Select
        label="Region"
        placeholder="Choose region"
        defaultValue="fra"
        options={regionOptions}
      />
    </PreviewColumn>
  );
}

export default function Demo() {
  return <SelectPreview />;
}

Dependencies

More by Wensity Labs

View all
  • Sidebar

    Sidebar

    392
  • Calendar

    Calendar

    287
  • Button

    Button

    131
  • Color Picker

    Color Picker

    97
  • Image Comparison Slider

    Image Comparison Slider

    82
  • AI Prompt Input

    AI Prompt Input

    80
  • Text Morphing

    Text Morphing

    60
  • Carousel

    Carousel

    57

More in Forms

View all
  • Login 1

    Login 1

    64
  • Premium Auth

    Premium Auth

    571
  • Contact Card

    Contact Card

    1.1K
  • Form

    Form

    18
  • Book A Demo 1

    Book A Demo 1

    91
  • Authentication Card

    Authentication Card

    52
  • Card Studio

    Card Studio

    47
  • Login Card

    Login Card

    35