()
| 278 | ]; |
| 279 | |
| 280 | export function ObjectExample() { |
| 281 | return ( |
| 282 | <Combobox |
| 283 | options={ALL_OBJECT_OPTIONS} |
| 284 | optionValue="value" |
| 285 | optionTextValue="label" |
| 286 | optionLabel="label" |
| 287 | optionDisabled="disabled" |
| 288 | placeholder="Search a fruit…" |
| 289 | itemComponent={(props) => ( |
| 290 | <Combobox.Item item={props.item} class={style.combobox__item}> |
| 291 | <Combobox.ItemLabel>{props.item.rawValue.label}</Combobox.ItemLabel> |
| 292 | <Combobox.ItemIndicator class={style["combobox__item-indicator"]}> |
| 293 | <CheckIcon /> |
| 294 | </Combobox.ItemIndicator> |
| 295 | </Combobox.Item> |
| 296 | )} |
| 297 | > |
| 298 | <Combobox.Control class={style.combobox__control} aria-label="Fruit"> |
| 299 | <Combobox.Input class={style.combobox__input} /> |
| 300 | <Combobox.Trigger class={style.combobox__trigger}> |
| 301 | <Combobox.Icon class={style.combobox__icon}> |
| 302 | <CaretSortIcon /> |
| 303 | </Combobox.Icon> |
| 304 | </Combobox.Trigger> |
| 305 | </Combobox.Control> |
| 306 | <Combobox.Portal> |
| 307 | <Combobox.Content class={style.combobox__content}> |
| 308 | <Combobox.Listbox class={style.combobox__listbox} /> |
| 309 | </Combobox.Content> |
| 310 | </Combobox.Portal> |
| 311 | </Combobox> |
| 312 | ); |
| 313 | } |
| 314 | |
| 315 | interface Category { |
| 316 | label: string; |
nothing calls this directly
no outgoing calls
no test coverage detected