File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 1+ import * as MaterialIcons from '@material-ui/icons'
2+
3+ const icons = Object . keys ( MaterialIcons ) . filter ( key => key . endsWith ( 'Sharp' ) )
4+
5+ export const Icons = icons . reduce ( ( obj , key ) => {
6+ obj [ key . slice ( 0 , - 5 ) ] = MaterialIcons [ key ]
7+ return obj
8+ } , { } )
Original file line number Diff line number Diff line change @@ -17,8 +17,8 @@ export { Form } from './form/Form'
1717export { FormControl } from './form/FormControl'
1818export { Heading } from './typography/Heading'
1919export { Hidden } from './hidden/Hidden'
20- export { Icon } from './icon/Icon'
2120export { IconButton } from './iconbutton/IconButton'
21+ export { Icons } from './icons/Icons'
2222export { Link } from './link/Link'
2323export { Loader } from './loader/Loader'
2424export { Logo } from './logo/Logo'
@@ -90,5 +90,3 @@ export {
9090 TableRow ,
9191 TableSortLabel
9292}
93-
94- export { Icons } from './icon'
You can’t perform that action at this time.
0 commit comments