mirror of
https://github.com/penpot/penpot.git
synced 2025-05-20 17:26:11 +02:00
🐛 Fix "move to" menu when duplicated team or project names
This commit is contained in:
parent
f8a46c56e9
commit
d83b362c9f
2 changed files with 4 additions and 2 deletions
|
@ -6,6 +6,7 @@
|
|||
|
||||
(ns app.main.ui.components.context-menu
|
||||
(:require
|
||||
[app.common.data :as d]
|
||||
[app.main.refs :as refs]
|
||||
[app.main.ui.components.dropdown :refer [dropdown']]
|
||||
[app.main.ui.icons :as i]
|
||||
|
@ -100,13 +101,13 @@
|
|||
[:span i/arrow-slide]
|
||||
parent-option]]
|
||||
[:li.separator]])
|
||||
(for [[option-name option-handler sub-options] (:options level)]
|
||||
(for [[index [option-name option-handler sub-options]] (d/enumerate (:options level))]
|
||||
(when option-name
|
||||
(if (= option-name :separator)
|
||||
[:li.separator]
|
||||
[:li.context-menu-item
|
||||
{:class (dom/classnames :is-selected (and selected (= option-name selected)))
|
||||
:key option-name}
|
||||
:key index}
|
||||
(if-not sub-options
|
||||
[:a.context-menu-action {:on-click #(do (dom/stop-propagation %)
|
||||
(on-close)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue