({filteredItems, listBoxClassName}: IconSearchViewProps)
| 161 | } |
| 162 | |
| 163 | export function IconSearchView({filteredItems, listBoxClassName}: IconSearchViewProps) { |
| 164 | let {copiedId, handleCopyImport} = useCopyImport(); |
| 165 | |
| 166 | return ( |
| 167 | <> |
| 168 | <InfoMessage> |
| 169 | Press an item to copy its import statement. See <Link href="icons">Icons</Link> for more |
| 170 | information. |
| 171 | </InfoMessage> |
| 172 | <IconListBox |
| 173 | items={filteredItems} |
| 174 | copiedId={copiedId} |
| 175 | onAction={handleCopyImport} |
| 176 | listBoxClassName={listBoxClassName} |
| 177 | /> |
| 178 | </> |
| 179 | ); |
| 180 | } |
| 181 | |
| 182 | function IconItem({item, isCopied = false}: {item: (typeof iconList)[number]; isCopied?: boolean}) { |
| 183 | let Icon = item.icon; |
nothing calls this directly
no test coverage detected