0
Fork 0
mirror of https://github.com/penpot/penpot.git synced 2025-01-22 22:49:01 -05:00

🐛 Fix unpublish more than one library at the same time

This commit is contained in:
Eva 2023-07-03 10:46:38 +02:00 committed by Alejandro Alonso
parent e461745479
commit a737c125d5
2 changed files with 23 additions and 18 deletions

View file

@ -24,6 +24,7 @@
- Fix files can be opened from multiple urls [Taiga #5310](https://tree.taiga.io/project/penpot/issue/5310) - Fix files can be opened from multiple urls [Taiga #5310](https://tree.taiga.io/project/penpot/issue/5310)
- Fix asset color item was created from the selected layer [Taiga #5180](https://tree.taiga.io/project/penpot/issue/5180) - Fix asset color item was created from the selected layer [Taiga #5180](https://tree.taiga.io/project/penpot/issue/5180)
- Fix unpublish more than one library at the same time [Taiga #5532](https://tree.taiga.io/project/penpot/issue/5532)
### :arrow_up: Deps updates ### :arrow_up: Deps updates

View file

@ -142,7 +142,11 @@
#(st/emit! (dd/set-file-shared (assoc file :is-shared true))) #(st/emit! (dd/set-file-shared (assoc file :is-shared true)))
del-shared del-shared
#(st/emit! (dd/set-file-shared (assoc file :is-shared false))) (mf/use-fn
(mf/deps files)
(fn [_]
(run! #(st/emit! (dd/set-file-shared (assoc % :is-shared false))) files)))
on-add-shared on-add-shared
(fn [event] (fn [event]
@ -216,23 +220,23 @@
(when current-team (when current-team
(let [sub-options (concat (vec (for [project current-projects] (let [sub-options (concat (vec (for [project current-projects]
{:option-name (get-project-name project) {:option-name (get-project-name project)
:id (get-project-id project) :id (get-project-id project)
:option-handler (on-move (:id current-team) :option-handler (on-move (:id current-team)
(:id project))})) (:id project))}))
(when (seq other-teams) (when (seq other-teams)
[{:option-name (tr "dashboard.move-to-other-team") [{:option-name (tr "dashboard.move-to-other-team")
:id "move-to-other-team" :id "move-to-other-team"
:sub-options :sub-options
(for [team other-teams] (for [team other-teams]
{:option-name (get-team-name team) {:option-name (get-team-name team)
:id (get-project-id team) :id (get-project-id team)
:sub-options :sub-options
(for [sub-project (:projects team)] (for [sub-project (:projects team)]
{:option-name (get-project-name sub-project) {:option-name (get-project-name sub-project)
:id (get-project-id sub-project) :id (get-project-id sub-project)
:option-handler (on-move (:id team) :option-handler (on-move (:id team)
(:id sub-project))})})}])) (:id sub-project))})})}]))
options (if multi? options (if multi?
[{:option-name (tr "dashboard.duplicate-multi" file-count) [{:option-name (tr "dashboard.duplicate-multi" file-count)