From 17db2a6b382619569782e11bda6451d63a66c77e Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Mon, 15 Dec 2025 07:46:36 +0200 Subject: [PATCH] Revert "fix(context_menu): clicking submenu dismisses the menu" This reverts commit 34bc444b186df01461d7547e140116a49425d554. --- apps/client/src/widgets/react/FormList.tsx | 52 +++++++++++----------- 1 file changed, 25 insertions(+), 27 deletions(-) diff --git a/apps/client/src/widgets/react/FormList.tsx b/apps/client/src/widgets/react/FormList.tsx index 87a047821..42f43a044 100644 --- a/apps/client/src/widgets/react/FormList.tsx +++ b/apps/client/src/widgets/react/FormList.tsx @@ -1,15 +1,13 @@ -import "./FormList.css"; - import { Dropdown as BootstrapDropdown, Tooltip } from "bootstrap"; -import clsx from "clsx"; import { ComponentChildren } from "preact"; -import { type CSSProperties,useEffect, useMemo, useRef, useState } from "preact/compat"; - -import { CommandNames } from "../../components/app_context"; -import { handleRightToLeftPlacement, isMobile, openInAppHelpFromUrl } from "../../services/utils"; -import FormToggle from "./FormToggle"; -import { useStaticTooltip } from "./hooks"; import Icon from "./Icon"; +import { useEffect, useMemo, useRef, useState, type CSSProperties } from "preact/compat"; +import "./FormList.css"; +import { CommandNames } from "../../components/app_context"; +import { useStaticTooltip } from "./hooks"; +import { handleRightToLeftPlacement, isMobile, openInAppHelpFromUrl } from "../../services/utils"; +import clsx from "clsx"; +import FormToggle from "./FormToggle"; interface FormListOpts { children: ComponentChildren; @@ -35,7 +33,7 @@ export default function FormList({ children, onSelect, style, fullHeight, wrappe return () => { $wrapperRef.off("hide.bs.dropdown"); dropdown.dispose(); - }; + } }, [ triggerRef, wrapperRef ]); const builtinStyles = useMemo(() => { @@ -53,7 +51,8 @@ export default function FormList({ children, onSelect, style, fullHeight, wrappe