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

Font Library: Add option for (minimal) font stack - at least assignment to the 5 generic font families - to be always W3C compliant #69213

Open
burnuser opened this issue Feb 17, 2025 · 0 comments
Labels

Comments

@burnuser
Copy link

What problem does this address?

W3C font standards are based on 5 generic font families: serif, sans-serif, cursive, fantasy, monospace
https://www.w3.org/TR/css-fonts-3/#generic-font-families
Having 1 of these 5 as last part in the font stack guarantees a working font display on every device in every browser.
If the loading of primary fonts does not work (connection/server/file/... problems), the system has a working fallback.

In WordPress this (minimal) font stack is not guaranteed at the moment.
Not all theme fonts and not all manually uploaded fonts come with this minimal font stack.
For example in "Twenty Twenty-Four" the included font "Inter" has a working font stack with "sans-serif" as base, but the font "Cardo" has no font stack at all. So, even an actual WordPress standard Theme is not W3C compliant.

What is your proposed solution?

If complete font stack editing is not planned in the near future, add at least a minimal interface option in the Font Library at each font to select the font stack base from the list of the five generic font families.

  • Create and use a correct minimal font stack on this base in WordPress.
@burnuser burnuser added the [Type] Enhancement A suggestion for improvement. label Feb 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants