mirror of
https://github.com/penpot/penpot.git
synced 2025-05-11 01:36:37 +02:00
🐛 Fix in dashboard it is possible to update project with empty name on left sidebar
This commit is contained in:
parent
42b68a786e
commit
b2ad78d947
1 changed files with 4 additions and 2 deletions
|
@ -34,6 +34,7 @@
|
||||||
[app.util.timers :as ts]
|
[app.util.timers :as ts]
|
||||||
[beicon.v2.core :as rx]
|
[beicon.v2.core :as rx]
|
||||||
[cljs.spec.alpha :as s]
|
[cljs.spec.alpha :as s]
|
||||||
|
[cuerdas.core :as str]
|
||||||
[goog.functions :as f]
|
[goog.functions :as f]
|
||||||
[potok.v2.core :as ptk]
|
[potok.v2.core :as ptk]
|
||||||
[rumext.v2 :as mf]))
|
[rumext.v2 :as mf]))
|
||||||
|
@ -91,8 +92,9 @@
|
||||||
(mf/use-callback
|
(mf/use-callback
|
||||||
(mf/deps item)
|
(mf/deps item)
|
||||||
(fn [name]
|
(fn [name]
|
||||||
|
(when-not (str/blank? name)
|
||||||
(st/emit! (-> (dd/rename-project (assoc item :name name))
|
(st/emit! (-> (dd/rename-project (assoc item :name name))
|
||||||
(with-meta {::ev/origin "dashboard:sidebar"})))
|
(with-meta {::ev/origin "dashboard:sidebar"}))))
|
||||||
(swap! local* assoc :edition? false)))
|
(swap! local* assoc :edition? false)))
|
||||||
|
|
||||||
on-drag-enter
|
on-drag-enter
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue