From fe5cdcbdc76c0cf9be2e133958c8cc96fd00e7a5 Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Fri, 29 Aug 2025 13:53:55 +0200 Subject: [PATCH] :bug: Do not render assets sidebar context menu if it is not open (#7222) This commit is a workaround to an issue that happens when you performing multiple selection of several shapes (including components) and an exception is raised of max depth of updates. The issue is still not solved, we justo do not render the context menu when user performs the selection on the workspace. That issue/exception happens only we have context-menu* component rendered independently of its visibility and dev-tools open --- .../app/main/ui/workspace/sidebar/assets.cljs | 23 ++++++++++--------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/frontend/src/app/main/ui/workspace/sidebar/assets.cljs b/frontend/src/app/main/ui/workspace/sidebar/assets.cljs index 01f60c4fbd..b04f5f4bf1 100644 --- a/frontend/src/app/main/ui/workspace/sidebar/assets.cljs +++ b/frontend/src/app/main/ui/workspace/sidebar/assets.cljs @@ -178,17 +178,18 @@ :class (stl/css-case :section-button true :opened menu-open?)} i/filter-icon]] - [:> context-menu* - {:on-close on-menu-close - :selectable true - :selected section - :show menu-open? - :fixed true - :min-width true - :width size - :top 158 - :left 18 - :options options}] + (when menu-open? + [:> context-menu* + {:on-close on-menu-close + :selectable true + :selected section + :show true + :fixed true + :min-width true + :width size + :top 158 + :left 18 + :options options}]) [:> icon-button* {:variant "ghost" :aria-label (tr "workspace.assets.sort") :on-click toggle-ordering