[csswg-drafts] [css-fonts] General function of system font families for parity with corresponding generic (#10852)

rthrejheytjyrtj545 has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-fonts] General function of system font families for parity with corresponding generic ==
System font families as they exist are not required to be mapped to anything. This has the advantage that implementations do not have to make any effort to conform to the specification, but the disadvantage that they have neither the incentive to change things nor the benefit of supporting null mapping

This impacts authors by requiring duplication for a straightforward use case, while fragmenting the platform further, leaving more inconsistency between browser vendors, increasing cognitive costs in terms of learning and documentation

A solution may be a function that takes the name of a generic font family, outputting the corresponding system font, otherwise the generic one. At this time, the current system font families could be aliases for the output of such a function, and non-overlapping areas before their elimination should be compensated at this level of abstraction, leaving more room for future expansion of system font support or introduction of new types of generic families

For example, such function could be called `ui()` and for the input `ui(rounded)` it would exist as the equivalent of `ui-rounded, ui-sans-serif, system-ui, rounded, sans-serif`

Ultimately, the pain point will be solved by having the feature necessarily match some fonts, leaving the exact behavior to the vendor's choice

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10852 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Sunday, 8 September 2024 16:42:31 UTC