mirror of
https://github.com/penpot/penpot.git
synced 2025-01-08 07:50:43 -05:00
🐛 Fix issues related to font family names with spaces.
This commit is contained in:
parent
2ea200be78
commit
9c99ec3410
2 changed files with 9 additions and 9 deletions
|
@ -27,7 +27,8 @@
|
|||
|
||||
### :bug: Bugs fixed
|
||||
|
||||
- Remove interactions when the destination artboard is deleted [Taiga #1656](https://tree.taiga.io/project/penpot/issue/1656)
|
||||
- Remove interactions when the destination artboard is deleted [Taiga #1656](https://tree.taiga.io/project/penpot/issue/1656).
|
||||
- Fix problem with fonts that ends with numbers [#940](https://github.com/penpot/penpot/issues/940).
|
||||
|
||||
|
||||
### :arrow_up: Deps updates
|
||||
|
|
|
@ -65,9 +65,7 @@
|
|||
font-id (:font-id data (:font-id txt/default-text-attrs))
|
||||
font-variant-id (:font-variant-id data)
|
||||
|
||||
font-family (:font-family data)
|
||||
font-size (:font-size data)
|
||||
|
||||
fill-color (:fill-color data)
|
||||
fill-opacity (:fill-opacity data)
|
||||
|
||||
|
@ -106,14 +104,15 @@
|
|||
(pos? (alength font-id)))
|
||||
(fonts/ensure-loaded! font-id)
|
||||
(let [font (get fontsdb font-id)]
|
||||
(let [font-family (or (:family font)
|
||||
(obj/get data "fontFamily"))
|
||||
(let [font-family (str/quote
|
||||
(or (:family font)
|
||||
(:font-family data)))
|
||||
font-variant (d/seek #(= font-variant-id (:id %))
|
||||
(:variants font))
|
||||
font-style (or (:style font-variant)
|
||||
(obj/get data "fontStyle"))
|
||||
font-weight (or (:weight font-variant)
|
||||
(obj/get data "fontWeight"))]
|
||||
font-style (or (:style font-variant)
|
||||
(:font-style data))
|
||||
font-weight (or (:weight font-variant)
|
||||
(:font-weight data))]
|
||||
(obj/set! base "fontFamily" font-family)
|
||||
(obj/set! base "fontStyle" font-style)
|
||||
(obj/set! base "fontWeight" font-weight))))
|
||||
|
|
Loading…
Reference in a new issue