mirror of
https://github.com/penpot/penpot.git
synced 2025-01-10 00:40:30 -05:00
🐛 Fix code generation for areas
This commit is contained in:
parent
a45bc0177b
commit
950fd60917
1 changed files with 6 additions and 1 deletions
|
@ -280,9 +280,14 @@
|
||||||
[_ shape _]
|
[_ shape _]
|
||||||
(:layout-grid-columns shape))
|
(:layout-grid-columns shape))
|
||||||
|
|
||||||
|
(defn area-cell?
|
||||||
|
[{:keys [position area-name]}]
|
||||||
|
(and (= position :area) (d/not-empty? area-name)))
|
||||||
|
|
||||||
(defmethod get-value :grid-template-areas
|
(defmethod get-value :grid-template-areas
|
||||||
[_ shape _]
|
[_ shape _]
|
||||||
(when (ctl/grid-layout? shape)
|
(when (and (ctl/grid-layout? shape)
|
||||||
|
(some area-cell? (vals (:layout-grid-cells shape))))
|
||||||
(let [result
|
(let [result
|
||||||
(->> (d/enumerate (:layout-grid-rows shape))
|
(->> (d/enumerate (:layout-grid-rows shape))
|
||||||
(map
|
(map
|
||||||
|
|
Loading…
Reference in a new issue