mirror of
https://github.com/vector-im/element-web.git
synced 2026-03-06 14:02:24 +01:00
doc: add recommendation to use compound typography component (#31715)
* doc: add recommendation to use compound typograpghy component * Update code_style.md Co-authored-by: R Midhun Suresh <hi@midhun.dev> --------- Co-authored-by: R Midhun Suresh <hi@midhun.dev>
This commit is contained in:
parent
9640c330e5
commit
bdee36ca7c
@ -272,6 +272,8 @@ Inheriting all the rules of TypeScript, the following additionally apply:
|
||||
18. Components should serve a single, or near-single, purpose.
|
||||
19. Prefer to derive information from component properties rather than establish state.
|
||||
20. Do not use `React.Component::forceUpdate`.
|
||||
21. Prefer to use [compound typography components](https://compound.element.io/?path=/docs/compound-web_typography--docs) instead of raw HTML elements for text. This ensures consistent font usage and letter spacing across the app.
|
||||
22. If you can't use 21, don't forget to apply the correct CSS classes for font and letter spacing.
|
||||
|
||||
## Stylesheets (\*.pcss = PostCSS + Plugins)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user