(props: ListBoxItemProps)
| 49 | } |
| 50 | |
| 51 | export function DropdownItem(props: ListBoxItemProps) { |
| 52 | let textValue = |
| 53 | props.textValue || (typeof props.children === 'string' ? props.children : undefined); |
| 54 | return ( |
| 55 | <ListBoxItem {...props} textValue={textValue} className="dropdown-item"> |
| 56 | {composeRenderProps(props.children, (children, {isSelected}) => ( |
| 57 | <> |
| 58 | {isSelected && <Check />} |
| 59 | {typeof children === 'string' ? <Text slot="label">{children}</Text> : children} |
| 60 | </> |
| 61 | ))} |
| 62 | </ListBoxItem> |
| 63 | ); |
| 64 | } |
| 65 | |
| 66 | export {Text, Header}; |
nothing calls this directly
no test coverage detected