Skip to content

Commit

Permalink
[material-ui][material-icons] Add option to search for all icon styles
Browse files Browse the repository at this point in the history
  • Loading branch information
cipherlogs committed Mar 9, 2024
1 parent 655eff4 commit fabe664
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/data/material/components/material-icons/SearchIcons.js
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ function useLatest(value) {

export default function SearchIcons() {
const [keys, setKeys] = React.useState(null);
const [theme, setTheme] = useQueryParameterState('theme', 'Filled');
const [theme, setTheme] = useQueryParameterState('theme', 'All');
const [selectedIcon, setSelectedIcon] = useQueryParameterState('selected', '');
const [query, setQuery] = useQueryParameterState('query', '');

Expand Down Expand Up @@ -527,7 +527,7 @@ export default function SearchIcons() {
const icons = React.useMemo(
() =>
(keys === null ? allIcons : keys.map((key) => allIconsMap[key])).filter(
(icon) => theme === icon.theme,
(icon) => theme === "All" || theme === icon.theme,
),
[theme, keys],
);
Expand All @@ -544,7 +544,7 @@ export default function SearchIcons() {
Filter the style
</Typography>
<RadioGroup>
{['Filled', 'Outlined', 'Rounded', 'Two tone', 'Sharp'].map(
{['All', 'Filled', 'Outlined', 'Rounded', 'Two tone', 'Sharp'].map(
(currentTheme) => {
return (
<FormControlLabel
Expand Down

0 comments on commit fabe664

Please sign in to comment.