mirror of
https://github.com/penpot/penpot.git
synced 2025-07-19 18:37:23 +02:00
🐛 Fix cannot click on blocked elements in viewer
This commit is contained in:
parent
2500486186
commit
213a8c69fb
3 changed files with 10 additions and 7 deletions
|
@ -20,12 +20,13 @@
|
|||
(mf/defc shape-container
|
||||
{::mf/wrap-props false}
|
||||
[props]
|
||||
(let [shape (obj/get props "shape")
|
||||
children (obj/get props "children")
|
||||
render-id (mf/use-memo #(str (uuid/next)))
|
||||
filter-id (str "filter_" render-id)
|
||||
styles (cond-> (obj/new)
|
||||
(:blocked shape) (obj/set! "pointerEvents" "none"))
|
||||
(let [shape (obj/get props "shape")
|
||||
children (obj/get props "children")
|
||||
pointer-events (obj/get props "pointer-events")
|
||||
render-id (mf/use-memo #(str (uuid/next)))
|
||||
filter-id (str "filter_" render-id)
|
||||
styles (-> (obj/new)
|
||||
(obj/set! "pointerEvents" pointer-events))
|
||||
|
||||
{:keys [x y width height type]} shape
|
||||
frame? (= :frame type)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue