mirror of
https://github.com/penpot/penpot.git
synced 2025-04-01 01:21:21 -05:00
🐛 Fix blur
This commit is contained in:
parent
a8eb5328a0
commit
a19f5fd305
1 changed files with 5 additions and 5 deletions
|
@ -20,11 +20,11 @@
|
||||||
(- (mth/sqrt (* 2 stroke-width stroke-width)) stroke-width)))
|
(- (mth/sqrt (* 2 stroke-width stroke-width)) stroke-width)))
|
||||||
|
|
||||||
(defn- apply-filters
|
(defn- apply-filters
|
||||||
[type filters]
|
[attr type filters]
|
||||||
(sequence
|
(sequence
|
||||||
(comp
|
(comp
|
||||||
(remove :hidden)
|
(remove :hidden)
|
||||||
(filter #(= (:style %) type))
|
(filter #(= (attr %) type))
|
||||||
(map (fn [item]
|
(map (fn [item]
|
||||||
{:id (dm/str "filter_" (:id item))
|
{:id (dm/str "filter_" (:id item))
|
||||||
:type type
|
:type type
|
||||||
|
@ -40,10 +40,10 @@
|
||||||
;; We can revisit this in the future
|
;; We can revisit this in the future
|
||||||
#_(->> shape :blur (into []) (blur-filters :background-blur))
|
#_(->> shape :blur (into []) (blur-filters :background-blur))
|
||||||
|
|
||||||
(->> shape :shadow (apply-filters :drop-shadow))
|
(->> shape :shadow (apply-filters :style :drop-shadow))
|
||||||
[{:id "shape" :type :blend-filters}]
|
[{:id "shape" :type :blend-filters}]
|
||||||
(->> shape :shadow (apply-filters :inner-shadow))
|
(->> shape :shadow (apply-filters :style :inner-shadow))
|
||||||
(->> shape :blur (into []) (apply-filters :layer-blur))))
|
(->> shape :blur list (apply-filters :type :layer-blur))))
|
||||||
|
|
||||||
(defn- calculate-filter-bounds
|
(defn- calculate-filter-bounds
|
||||||
[selrect filter-entry]
|
[selrect filter-entry]
|
||||||
|
|
Loading…
Add table
Reference in a new issue