Files
webstudio/packages/css-engine
Oleg Isonen 525e6e384d Support for variable fonts (#1007)
Closes https://github.com/webstudio-is/webstudio-designer/issues/994

## Description

Variable fonts were treated like normal fonts, so we were only showing
one default font weight as available.
Now we not only detect variable fonts, but we also save all the meta
data we get from them, so we can add a variable font settings UI in the
future, which is a huge deal for designers, because variable fonts offer
very interesting styling options and animations

## Steps for reproduction

1. select instance
2. font family, upload variable versions fonts like Monrope, Inter or
Roboto Flex
3. see you can choose any font weight
4. use any styles on the font e.g. italic etc 

## Code Review

- [ ] hi @TrySound , I need you to do
  - conceptual review (architecture, feature-correctness)
  - detailed review (read every line)
  - test it on preview

## Before requesting a review

- [ ] made a self-review
- [ ] added inline comments where things may be not obvious (the "why",
not "what")

## Before merging

- [ ] tested locally and on preview environment (preview dev login:
5de6)
- [ ] updated [test
cases](https://github.com/webstudio-is/webstudio-designer/blob/main/apps/designer/docs/test-cases.md)
document
- [ ] added tests
- [ ] if any new env variables are added, added them to `.env.example`
and the `designer/env-check.js` if mandatory
2023-02-12 21:34:38 +01:00
..
2022-12-17 21:50:59 +01:00
2023-02-12 21:34:38 +01:00
2022-11-10 19:55:38 +01:00
2023-02-10 13:39:35 +03:00
2022-11-10 19:55:38 +01:00
2022-12-16 13:09:33 +03:00

CSS Engine

This package is designed to render effectively CSS in the format produced by Webstudio Designer. It is using CSS variables for all dynamic parts and can render at runtime as for usage on Live Canvas in the Designer as well as for extracting a fully static style sheet for production.