mirror of
https://github.com/penpot/penpot.git
synced 2025-06-03 19:41:38 +02:00
💄 Minor cosmetic changes on shapes related namespaces.
This commit is contained in:
parent
247273631c
commit
7b1f84f509
3 changed files with 43 additions and 45 deletions
|
@ -9,25 +9,23 @@
|
|||
|
||||
(ns app.main.ui.shapes.shape
|
||||
(:require
|
||||
[rumext.alpha :as mf]
|
||||
[cuerdas.core :as str]
|
||||
[app.util.object :as obj]
|
||||
[app.common.uuid :as uuid]
|
||||
[app.common.geom.shapes :as geom]
|
||||
[app.common.uuid :as uuid]
|
||||
[app.main.ui.context :as muc]
|
||||
[app.main.ui.shapes.filters :as filters]
|
||||
[app.main.ui.shapes.gradients :as grad]
|
||||
[app.main.ui.context :as muc]))
|
||||
[app.util.object :as obj]
|
||||
[cuerdas.core :as str]
|
||||
[rumext.alpha :as mf]))
|
||||
|
||||
(mf/defc shape-container
|
||||
{::mf/wrap-props false}
|
||||
[props]
|
||||
|
||||
(let [shape (unchecked-get props "shape")
|
||||
children (unchecked-get props "children")
|
||||
(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)
|
||||
group-props (-> props
|
||||
(obj/clone)
|
||||
group-props (-> (obj/clone props)
|
||||
(obj/without ["shape" "children"])
|
||||
(obj/set! "id" (str "shape-" (:id shape)))
|
||||
(obj/set! "className" "shape")
|
||||
|
@ -38,5 +36,4 @@
|
|||
[:& filters/filters {:shape shape :filter-id filter-id}]
|
||||
[:& grad/gradient {:shape shape :attr :fill-color-gradient}]
|
||||
[:& grad/gradient {:shape shape :attr :stroke-color-gradient}]]
|
||||
|
||||
children]]))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue