mirror of
https://github.com/penpot/penpot.git
synced 2025-03-20 19:51:23 -05:00
🐛 Fix broken text shapes without position-data on comp-v2 migration
This commit is contained in:
parent
6d35cb2eb4
commit
ec2eb3d406
1 changed files with 13 additions and 0 deletions
|
@ -376,6 +376,19 @@
|
|||
:selrect selrect
|
||||
:points points))
|
||||
|
||||
(and (cfh/text-shape? shape)
|
||||
(valid-text-content? (:content shape))
|
||||
(not (valid-shape-points? (:points shape)))
|
||||
(grc/valid-rect? (:selrect shape)))
|
||||
(let [selrect (:selrect shape)
|
||||
points (grc/rect->points selrect)]
|
||||
(assoc shape
|
||||
:x (:x selrect)
|
||||
:y (:y selrect)
|
||||
:width (:width selrect)
|
||||
:height (:height selrect)
|
||||
:points points))
|
||||
|
||||
(and (or (cfh/rect-shape? shape)
|
||||
(cfh/svg-raw-shape? shape)
|
||||
(cfh/circle-shape? shape))
|
||||
|
|
Loading…
Add table
Reference in a new issue