question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Typography with Fonts output is invalid when auto-prefixing is off

See original GitHub issue

The README suggests (using standard format) that it can export both Fonts and Typography tokens, however the tree structure doesn’t seem to be valid (by that I mean, using only style-dictionary transforms alone would not be enough, for web css)

It exports something like this:

{
  "myTheme": {
      "font": {
          "myFontA": {
              "type": "custom-fontStyle",
              "value": {
                  "fontSize": 42,
                  "textDecoration: ...  etc.
               },
               "fontSize": {
                  "type": "dimension",
                  "value": 42
               },
               ... the others
          }
      }
   }

Since myFontA has a type and a value key, the other siblings are not picked up as separate tokens and get ignored.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
lukasoppermanncommented, Aug 30, 2022

So what is outputted in the Original (outdated) mode, should be supported by style dictionary.

What is output in standard mode is not. It is by now also not according the standard anymore, as they updated. I will hopefully in the next days/weeks have time to refactor standard to align with the specs.

0reactions
derekwsgraycommented, Sep 1, 2022

I’ve updated the title to reflect the special case. Should be re-opened.

Read more comments on GitHub >

github_iconTop Results From Across the Web

autoprefixer/README.md at main - GitHub
Autoprefixer can be used to translate modern CSS Grid syntax into IE 10 and IE 11 syntax, but this polyfill will not work...
Read more >
Next.js postcss font-variant overwriting - Stack Overflow
I tried adding "font-variant-property": false , but it is still compiled as normal even though I set it to initial . Btw, is...
Read more >
Advanced Features: Customizing PostCSS Config - Next.js
Out of the box, with no configuration, Next.js compiles CSS with the following transformations: Autoprefixer automatically adds vendor prefixes to CSS rules ( ......
Read more >
Using with Preprocessors - Tailwind CSS
A guide to using Tailwind with common CSS preprocessors like Sass, Less, and Stylus.
Read more >
CSS Fonts Module Level 4 - W3C
Synthesis of the font-variant-position property; The font-language-override ... To illustrate this, the following declarations are invalid:
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found