mirror of
https://github.com/penpot/penpot.git
synced 2025-07-24 18:47:25 +02:00
🐛 Fixed problems with resize texts
This commit is contained in:
parent
4a5a5b1081
commit
a71a7d6951
17 changed files with 149 additions and 116 deletions
|
@ -12,7 +12,6 @@
|
|||
[rumext.alpha :as mf]
|
||||
[cuerdas.core :as str]
|
||||
[app.main.ui.shapes.attrs :as attrs]
|
||||
[app.util.debug :refer [debug?]]
|
||||
[app.common.geom.shapes :as geom]))
|
||||
|
||||
(def mask-id-ctx (mf/create-context nil))
|
||||
|
@ -32,7 +31,6 @@
|
|||
childs (if (and (:masked-group? shape) (not expand-mask))
|
||||
(rest childs)
|
||||
childs)
|
||||
is-child-selected? (unchecked-get props "is-child-selected?")
|
||||
{:keys [id x y width height]} shape
|
||||
transform (geom/transform-matrix shape)]
|
||||
[:g
|
||||
|
@ -48,13 +46,6 @@
|
|||
[:& shape-wrapper {:frame frame
|
||||
:shape item
|
||||
:key (:id item)}])]
|
||||
(when (not is-child-selected?)
|
||||
[:rect {:transform transform
|
||||
:x x
|
||||
:y y
|
||||
:fill (if (debug? :group) "red" "transparent")
|
||||
:opacity 0.5
|
||||
:width width
|
||||
:height height}])])))
|
||||
])))
|
||||
|
||||
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
group-props (-> (obj/clone props)
|
||||
(obj/without ["shape" "children"])
|
||||
(obj/set! "id" (str "shape-" (:id shape)))
|
||||
(obj/set! "className" "shape")
|
||||
(obj/set! "className" (str "shape " (:type shape)))
|
||||
(obj/set! "filter" (filters/filter-str filter-id shape)))]
|
||||
[:& (mf/provider muc/render-ctx) {:value render-id}
|
||||
[:> :g group-props
|
||||
|
|
|
@ -100,6 +100,7 @@
|
|||
:width (if (#{:auto-width} grow-type) 10000 width)
|
||||
:height (if (#{:auto-height :auto-width} grow-type) 10000 height)
|
||||
:mask mask-id
|
||||
:ref ref}
|
||||
:ref ref
|
||||
:pointer-events "none"}
|
||||
[:& text-content {:shape shape
|
||||
:content (:content shape)}]]))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue