mirror of
https://github.com/penpot/penpot.git
synced 2025-01-08 16:00:19 -05:00
🐛 Fix clipped elements affect artboards centering
This commit is contained in:
parent
b926409fa2
commit
9ffd00d821
2 changed files with 17 additions and 15 deletions
|
@ -34,6 +34,7 @@
|
||||||
|
|
||||||
### :bug: Bugs fixed
|
### :bug: Bugs fixed
|
||||||
|
|
||||||
|
- Fix clipped elements affect boards and centering [Taiga #3666](https://tree.taiga.io/project/penpot/issue/3666)
|
||||||
- Fix intro action in multi input [Taiga #3541](https://tree.taiga.io/project/penpot/issue/3541)
|
- Fix intro action in multi input [Taiga #3541](https://tree.taiga.io/project/penpot/issue/3541)
|
||||||
- Fix team default image [Taiga #3919](https://tree.taiga.io/project/penpot/issue/3919)
|
- Fix team default image [Taiga #3919](https://tree.taiga.io/project/penpot/issue/3919)
|
||||||
- Fix problem with group coordinates [#2008](https://github.com/penpot/penpot/issues/2008)
|
- Fix problem with group coordinates [#2008](https://github.com/penpot/penpot/issues/2008)
|
||||||
|
|
|
@ -129,26 +129,27 @@
|
||||||
(-> (get-shape-filter-bounds shape)
|
(-> (get-shape-filter-bounds shape)
|
||||||
(add-padding (calculate-padding shape true))))
|
(add-padding (calculate-padding shape true))))
|
||||||
|
|
||||||
bounds
|
bounds (if (cph/frame-shape? shape)
|
||||||
(cph/reduce-objects
|
[(calculate-base-bounds shape)]
|
||||||
objects
|
(cph/reduce-objects
|
||||||
(fn [shape]
|
objects
|
||||||
(and (d/not-empty? (:shapes shape))
|
(fn [shape]
|
||||||
(or (not (cph/frame-shape? shape))
|
(and (d/not-empty? (:shapes shape))
|
||||||
(:show-content shape))
|
(or (not (cph/frame-shape? shape))
|
||||||
|
(:show-content shape))
|
||||||
|
|
||||||
(or (not (cph/group-shape? shape))
|
(or (not (cph/group-shape? shape))
|
||||||
(not (:masked-group? shape)))))
|
(not (:masked-group? shape)))))
|
||||||
|
|
||||||
(:id shape)
|
(:id shape)
|
||||||
|
|
||||||
(fn [result shape]
|
(fn [result shape]
|
||||||
(conj result (get-object-bounds objects shape)))
|
(conj result (get-object-bounds objects shape)))
|
||||||
|
|
||||||
[(calculate-base-bounds shape)])
|
[(calculate-base-bounds shape)]))
|
||||||
|
|
||||||
|
children-bounds (cond->> (gsr/join-selrects bounds)
|
||||||
children-bounds (or (:children-bounds shape) (gsr/join-selrects bounds))
|
(not (cph/frame-shape? shape)) (or (:children-bounds shape)))
|
||||||
|
|
||||||
filters (shape->filters shape)
|
filters (shape->filters shape)
|
||||||
blur-value (or (-> shape :blur :value) 0)]
|
blur-value (or (-> shape :blur :value) 0)]
|
||||||
|
|
Loading…
Reference in a new issue