mirror of
https://github.com/penpot/penpot.git
synced 2025-01-08 07:50:43 -05:00
🐛 Fix contextual menu in dashboard shared libraries section
This commit is contained in:
parent
3295685938
commit
150427cd39
2 changed files with 12 additions and 2 deletions
|
@ -20,6 +20,7 @@
|
|||
- Fix dashboard navigation on moving file to other team [Taiga #1817](https://tree.taiga.io/project/penpot/issue/1817).
|
||||
- Fix workspace header presence styles and invalid link [Taiga #1813](https://tree.taiga.io/project/penpot/issue/1813).
|
||||
- Fix color-input wrong behavior (on workspace page color) [Taiga #1795](https://tree.taiga.io/project/penpot/issue/1795).
|
||||
- Fix file contextual menu in shared libraries at dashboard [Taiga #1865](https://tree.taiga.io/project/penpot/issue/1865).
|
||||
|
||||
### :arrow_up: Deps updates
|
||||
### :boom: Breaking changes
|
||||
|
|
|
@ -73,6 +73,7 @@
|
|||
(-> (assoc :current-team-id id)
|
||||
(dissoc :dashboard-files)
|
||||
(dissoc :dashboard-projects)
|
||||
(dissoc :dashboard-shared-files)
|
||||
(dissoc :dashboard-recent-files)
|
||||
(dissoc :dashboard-team-members)
|
||||
(dissoc :dashboard-team-stats)))))
|
||||
|
@ -206,7 +207,10 @@
|
|||
(ptk/reify ::shared-files-fetched
|
||||
ptk/UpdateEvent
|
||||
(update [_ state]
|
||||
(assoc state :dashboard-shared-files (d/index-by :id files)))))
|
||||
(let [files (d/index-by :id files)]
|
||||
(-> state
|
||||
(assoc :dashboard-shared-files files)
|
||||
(update :dashboard-files d/merge files))))))
|
||||
|
||||
(defn fetch-shared-files
|
||||
[]
|
||||
|
@ -548,6 +552,7 @@
|
|||
(update [_ state]
|
||||
(-> state
|
||||
(d/update-when :dashboard-files dissoc id)
|
||||
(d/update-when :dashboard-shared-files dissoc id)
|
||||
(d/update-when :dashboard-recent-files dissoc id)))
|
||||
|
||||
ptk/WatchEvent
|
||||
|
@ -566,6 +571,7 @@
|
|||
(update [_ state]
|
||||
(-> state
|
||||
(d/update-in-when [:dashboard-files id :name] (constantly name))
|
||||
(d/update-in-when [:dashboard-shared-files id :name] (constantly name))
|
||||
(d/update-in-when [:dashboard-recent-files id :name] (constantly name))))
|
||||
|
||||
ptk/WatchEvent
|
||||
|
@ -584,7 +590,10 @@
|
|||
(update [_ state]
|
||||
(-> state
|
||||
(d/update-in-when [:dashboard-files id :is-shared] (constantly is-shared))
|
||||
(d/update-in-when [:dashboard-recent-files id :is-shared] (constantly is-shared))))
|
||||
(d/update-in-when [:dashboard-recent-files id :is-shared] (constantly is-shared))
|
||||
(cond->
|
||||
(not is-shared)
|
||||
(d/update-when :dashboard-shared-files dissoc id))))
|
||||
|
||||
ptk/WatchEvent
|
||||
(watch [_ _ _]
|
||||
|
|
Loading…
Reference in a new issue