Home / Function/ ComboboxWithCustomItems() — ui Function Reference

ComboboxWithCustomItems() — ui Function Reference

Architecture documentation for the ComboboxWithCustomItems() function in combobox-example.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  f954408a_5920_5b1d_e59d_8749eea8e795["ComboboxWithCustomItems()"]
  3abbb5d0_a426_2d0f_1c5d_dd3e5ea603b4["combobox-example.tsx"]
  f954408a_5920_5b1d_e59d_8749eea8e795 -->|defined in| 3abbb5d0_a426_2d0f_1c5d_dd3e5ea603b4
  style f954408a_5920_5b1d_e59d_8749eea8e795 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/registry/bases/radix/examples/combobox-example.tsx lines 1096–1128

function ComboboxWithCustomItems() {
  return (
    <Example title="With Custom Item Rendering">
      <Combobox
        items={countries.filter((country) => country.code !== "")}
        itemToStringValue={(country: (typeof countries)[number]) =>
          country.label
        }
      >
        <ComboboxInput placeholder="Search countries..." />
        <ComboboxContent>
          <ComboboxEmpty>No countries found.</ComboboxEmpty>
          <ComboboxList>
            {(country) => (
              <ComboboxItem key={country.code} value={country}>
                <Item size="xs" className="p-0">
                  <ItemContent>
                    <ItemTitle className="whitespace-nowrap">
                      {country.label}
                    </ItemTitle>
                    <ItemDescription>
                      {country.continent} ({country.code})
                    </ItemDescription>
                  </ItemContent>
                </Item>
              </ComboboxItem>
            )}
          </ComboboxList>
        </ComboboxContent>
      </Combobox>
    </Example>
  )
}

Subdomains

Frequently Asked Questions

What does ComboboxWithCustomItems() do?
ComboboxWithCustomItems() is a function in the ui codebase, defined in apps/v4/registry/bases/radix/examples/combobox-example.tsx.
Where is ComboboxWithCustomItems() defined?
ComboboxWithCustomItems() is defined in apps/v4/registry/bases/radix/examples/combobox-example.tsx at line 1096.

Analyze Your Own Codebase

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

Try Supermodel Free