DimensionDev / Maskbook-Talks

Where talks of Maskbook happen.
7 stars 1 forks source link

[Talk] Do we need to use typography? #51

Open zhouhanseng opened 4 years ago

zhouhanseng commented 4 years ago

Inroduction and Background

Here DashboardRouters/Setup.tsx#L133, if I tried to replace the <Typography> with just a <p>, it renders the same ui result.

https://material-ui.com/components/typography/:

Too many type sizes and styles at once can spoil any layout. A typographic scale has a limited set of type sizes that work well together along with the layout grid.

So as we define our own font-size, font-weight and so on, I think we don't need to use typography.

Jack-Works commented 4 years ago

Did you try the dark mode? IIRC <Typography> automatically fits that but <p> won't. (still in black color)

zhouhanseng commented 4 years ago

Dark mode works well. <p> inherits the color from <body>, and even there's no inheritation, it's fine to define a color for <p>, like we do for <Typography> as well.

image