mirror of
https://github.com/penpot/penpot.git
synced 2025-01-31 19:39:07 -05:00
🐛 Fix problem with strokes not refreshing in Safari
This commit is contained in:
parent
e0281b553c
commit
52e5978ed5
2 changed files with 10 additions and 2 deletions
|
@ -19,6 +19,7 @@
|
|||
|
||||
- Fix problem with alt key measures being stuck [Taiga #9348](https://tree.taiga.io/project/penpot/issue/9348)
|
||||
- Fix error when reseting stroke cap
|
||||
- Fix problem with strokes not refreshing in Safari [Taiga #9040](https://tree.taiga.io/project/penpot/issue/9040)
|
||||
|
||||
## 2.4.2
|
||||
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
[app.common.geom.shapes :as gsh]
|
||||
[app.common.geom.shapes.bounds :as gsb]
|
||||
[app.common.geom.shapes.text :as gst]
|
||||
[app.common.uuid :as uuid]
|
||||
[app.config :as cf]
|
||||
[app.main.ui.context :as muc]
|
||||
[app.main.ui.shapes.attrs :as attrs]
|
||||
|
@ -470,12 +471,18 @@
|
|||
render-id (mf/use-ctx muc/render-id)
|
||||
render-id (d/nilv (unchecked-get props "render-id") render-id)
|
||||
|
||||
stroke-id (dm/fmt "strokes-%" shape-id)
|
||||
strokes (get shape :strokes)
|
||||
|
||||
;; Generate a unique id when the strokes change. This way we can solve some
|
||||
;; render issues in Safari https://tree.taiga.io/project/penpot/issue/9040
|
||||
prefix (mf/use-memo (mf/deps strokes) #(dm/str (uuid/next)))
|
||||
|
||||
stroke-id (dm/str (dm/fmt "strokes-%-%" prefix shape-id))
|
||||
|
||||
shape-blur (get shape :blur)
|
||||
shape-fills (get shape :fills)
|
||||
shape-shadow (get shape :shadow)
|
||||
shape-strokes (not-empty (get shape :strokes))
|
||||
shape-strokes (not-empty strokes)
|
||||
|
||||
svg-attrs (attrs/get-svg-props shape render-id)
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue