From 63a915ca4f4ca8eb5a3807a9f254909914588b9d Mon Sep 17 00:00:00 2001 From: ComfyFluffy <24245520+ComfyFluffy@users.noreply.github.com> Date: Thu, 13 Jun 2024 16:48:50 +0800 Subject: [PATCH 1/3] feat: UIDropdownWithTooltip --- .../components/editor/common/EditorList.vue | 34 ++++++--------- spx-gui/src/components/ui/UIDropdown.vue | 5 +++ .../components/ui/UIDropdownWithTooltip.vue | 41 +++++++++++++++++++ spx-gui/src/components/ui/UITooltip.vue | 17 +++++++- spx-gui/src/components/ui/index.ts | 1 + 5 files changed, 75 insertions(+), 23 deletions(-) create mode 100644 spx-gui/src/components/ui/UIDropdownWithTooltip.vue diff --git a/spx-gui/src/components/editor/common/EditorList.vue b/spx-gui/src/components/editor/common/EditorList.vue index 6ab8d41ef..10a764f79 100644 --- a/spx-gui/src/components/editor/common/EditorList.vue +++ b/spx-gui/src/components/editor/common/EditorList.vue @@ -4,26 +4,19 @@ - + + + - - + @@ -33,11 +26,10 @@ import { computed } from 'vue' import { UIIcon, - UIDropdown, - UITooltip, type Color, useUIVariables, - getCssVars + getCssVars, + UIDropdownWithTooltip } from '@/components/ui' const props = defineProps<{ diff --git a/spx-gui/src/components/ui/UIDropdown.vue b/spx-gui/src/components/ui/UIDropdown.vue index 59cbf9250..31cb668c5 100644 --- a/spx-gui/src/components/ui/UIDropdown.vue +++ b/spx-gui/src/components/ui/UIDropdown.vue @@ -11,6 +11,7 @@ :show-arrow="false" :style="{ marginTop: offset.y + 'px', marginLeft: offset.x + 'px' }" raw + @update:show="(v) => emit('update:visible', v)" >