Home / Function/ SelectTrigger() — ui Function Reference

SelectTrigger() — ui Function Reference

Architecture documentation for the SelectTrigger() function in select.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  b0da06c0_7555_6a61_6edf_39f094c758c1["SelectTrigger()"]
  cc5a2b93_5022_c511_3ed0_25dd5a152de0["select.tsx"]
  b0da06c0_7555_6a61_6edf_39f094c758c1 -->|defined in| cc5a2b93_5022_c511_3ed0_25dd5a152de0
  style b0da06c0_7555_6a61_6edf_39f094c758c1 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/registry/bases/radix/ui/select.tsx lines 34–65

function SelectTrigger({
  className,
  size = "default",
  children,
  ...props
}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {
  size?: "sm" | "default"
}) {
  return (
    <SelectPrimitive.Trigger
      data-slot="select-trigger"
      data-size={size}
      className={cn(
        "cn-select-trigger flex w-fit items-center justify-between whitespace-nowrap outline-none disabled:cursor-not-allowed disabled:opacity-50 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center [&_svg]:pointer-events-none [&_svg]:shrink-0",
        className
      )}
      {...props}
    >
      {children}
      <SelectPrimitive.Icon asChild>
        <IconPlaceholder
          lucide="ChevronDownIcon"
          tabler="IconSelector"
          hugeicons="UnfoldMoreIcon"
          phosphor="CaretDownIcon"
          remixicon="RiArrowDownSLine"
          className="cn-select-trigger-icon pointer-events-none"
        />
      </SelectPrimitive.Icon>
    </SelectPrimitive.Trigger>
  )
}

Subdomains

Frequently Asked Questions

What does SelectTrigger() do?
SelectTrigger() is a function in the ui codebase, defined in apps/v4/registry/bases/radix/ui/select.tsx.
Where is SelectTrigger() defined?
SelectTrigger() is defined in apps/v4/registry/bases/radix/ui/select.tsx at line 34.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free