From 696ae451d3ef33f2455ef1e0410bc2a736efd663 Mon Sep 17 00:00:00 2001 From: orangecoding Date: Tue, 2 Jun 2026 12:57:12 +0200 Subject: [PATCH] fixing tooltip issues --- ui/src/components/listings/StatusControl.jsx | 32 ++++++++++++++++--- ui/src/components/listings/StatusControl.less | 8 +++++ 2 files changed, 36 insertions(+), 4 deletions(-) diff --git a/ui/src/components/listings/StatusControl.jsx b/ui/src/components/listings/StatusControl.jsx index d9d7dbb..d45ea1b 100644 --- a/ui/src/components/listings/StatusControl.jsx +++ b/ui/src/components/listings/StatusControl.jsx @@ -3,6 +3,7 @@ * Licensed under Apache-2.0 with Commons Clause and Attribution/Naming Clause */ +import { useState } from 'react'; import { Dropdown, Button, Tooltip } from '@douyinfe/semi-ui-19'; import { IconChevronDown } from '@douyinfe/semi-icons'; @@ -43,9 +44,12 @@ const optionFor = (status) => STATUS_OPTIONS.find((o) => o.value === status) ?? * @param {(e: React.MouseEvent) => void} [props.onTriggerClick] - Optional click handler to stop propagation on the trigger. */ export default function StatusControl({ status = null, onChange, compact = false, onTriggerClick }) { + const [open, setOpen] = useState(false); + const [tooltipOpen, setTooltipOpen] = useState(false); const current = optionFor(status); const handlePick = (next) => { + setOpen(false); if (next === status) return; onChange?.(next); }; @@ -69,13 +73,25 @@ export default function StatusControl({ status = null, onChange, compact = false .join(' '); const trigger = ( - +