Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[docs] Prefer SVG over font icons in the demos #17056

Merged
merged 2 commits into from
Aug 21, 2019

Conversation

troussos
Copy link
Contributor

@mui-pr-bot
Copy link

mui-pr-bot commented Aug 19, 2019

No bundle size changes comparing c20b046...6464087

Generated by 🚫 dangerJS against 6464087

@mbrookes mbrookes added the docs Improvements or additions to the documentation label Aug 19, 2019
@mbrookes mbrookes changed the title Floating Action Button Documentation Updates [docs] Use @material-ui/icons icon for Floating Action Button demos Aug 19, 2019
@mbrookes mbrookes added the component: Fab The React component. label Aug 19, 2019
@oliviertassinari
Copy link
Member

oliviertassinari commented Aug 19, 2019

@troussos We use the same approach with the docs/src/pages/components/buttons/IconButtons.js file. I think that we should have the two files use the same tradeoff. The current strategy was picked, in order to:

  1. Show people that both can be used. Now, considering that the SVG approach should be, likely, be prioritized over the font one, the changes are probably OK.
  2. To prevent rendering regression between the SVG and font icon components. Maybe a regression test would be better?

@mbrookes
Copy link
Member

Maybe a regression test would be better?

Yes, since with font icons, copying the example code doesn't work out of the box, as you have to have the font loaded.

@oliviertassinari
Copy link
Member

oliviertassinari commented Aug 20, 2019

Well, we could always load the font icons in codesandbox, but it's not ideal. I'm adding a regression test, WIP:

@oliviertassinari oliviertassinari changed the title [docs] Use @material-ui/icons icon for Floating Action Button demos [docs] Prefer SVG over font icons in the demos Aug 20, 2019
@troussos
Copy link
Contributor Author

Thanks for the quick review and adding the regression tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: Fab The React component. docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants