block editor – Define fonts in theme.json what slug name

Question

Is there a naming convention for slugs for fontFamilies in themes.json. I see they end up being using for the vss var --wp--preset--font-family--<slug>. So it would make sense to name the slug something generic like body-text instead of for instance open-sans, where a child theme might use a different font family but with the same, generic slug.

Example

Rationale

The slug is only used by the theme developer, not by the web designer. The web designer selects the font from a list of fonts made available by the theme developer.

0
th00ht 4 months 2023-05-31T03:37:33-05:00 0 Answers 0 views 0

Leave an answer

Browse
Browse