From e2b5f9a4020e433abd2175707e225b867c7aca59 Mon Sep 17 00:00:00 2001 From: "xinxin.wu" Date: Mon, 16 Dec 2024 18:38:22 +0800 Subject: [PATCH] =?UTF-8?q?style(=E5=B7=A5=E4=BD=9C=E5=8F=B0):=20=E8=B0=83?= =?UTF-8?q?=E6=95=B4tooltip=E5=86=85=E5=AE=B9=E5=A4=AA=E9=95=BF=E5=92=8C?= =?UTF-8?q?=E5=B1=95=E7=A4=BA=E4=BD=8D=E7=BD=AE=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/assets/style/arco-reset.less | 6 ++++-- frontend/src/components/business/ms-select/index.tsx | 4 +++- .../src/views/workbench/homePage/components/overview.vue | 1 + .../views/workbench/homePage/components/overviewMember.vue | 1 + 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/frontend/src/assets/style/arco-reset.less b/frontend/src/assets/style/arco-reset.less index 6bea3b89bb..fe143e8e31 100644 --- a/frontend/src/assets/style/arco-reset.less +++ b/frontend/src/assets/style/arco-reset.less @@ -897,9 +897,11 @@ input::placeholder { /** tooltip **/ .arco-tooltip-content { - @apply break-all; - + max-height: 400px; color: var(--color-text-fff); + @apply overflow-y-auto break-all; + + .ms-scroll-bar(); } .arco-trigger-arrow { border-bottom-right-radius: var(--border-radius-mini) !important; diff --git a/frontend/src/components/business/ms-select/index.tsx b/frontend/src/components/business/ms-select/index.tsx index 709a34dccf..5e4a1ebf5e 100644 --- a/frontend/src/components/business/ms-select/index.tsx +++ b/frontend/src/components/business/ms-select/index.tsx @@ -45,6 +45,7 @@ export interface MsSearchSelectProps { optionTooltipContent?: (item: SelectOptionData) => string; // 自定义 option 的 tooltip 内容,返回一个字符串,默认使用 item.label remoteFilterFunc?: (options: SelectOptionData[]) => SelectOptionData[]; // 自定义过滤函数,会在远程请求返回数据后执行 optionTooltipPosition?: 'top' | 'tl' | 'tr' | 'bottom' | 'bl' | 'br' | 'left' | 'lt' | 'lb' | 'right' | 'rt' | 'rb'; // // label tooltip 的位置 + fullTooltipPosition?: 'top' | 'tl' | 'tr' | 'bottom' | 'bl' | 'br' | 'left' | 'lt' | 'lb' | 'right' | 'rt' | 'rb'; // // 全选 tooltip 的位置 } export interface RadioProps { options: SelectOptionData[]; @@ -479,7 +480,7 @@ export default defineComponent( @@ -588,6 +589,7 @@ export default defineComponent( 'disabled', 'size', 'optionTooltipPosition', + 'fullTooltipPosition', ], emits: [ 'update:modelValue', diff --git a/frontend/src/views/workbench/homePage/components/overview.vue b/frontend/src/views/workbench/homePage/components/overview.vue index be910a5014..be4af0c5b9 100644 --- a/frontend/src/views/workbench/homePage/components/overview.vue +++ b/frontend/src/views/workbench/homePage/components/overview.vue @@ -22,6 +22,7 @@ :prefix="t('workbench.homePage.project')" :multiple="true" :has-all-select="true" + full-tooltip-position="tr" :default-all-select="props.item.selectAll" :at-least-one="true" @popup-visible-change="popupVisibleChange" diff --git a/frontend/src/views/workbench/homePage/components/overviewMember.vue b/frontend/src/views/workbench/homePage/components/overviewMember.vue index d60fb2f9de..5915eaf649 100644 --- a/frontend/src/views/workbench/homePage/components/overviewMember.vue +++ b/frontend/src/views/workbench/homePage/components/overviewMember.vue @@ -29,6 +29,7 @@ class="!w-[220px]" :prefix="t('workbench.homePage.staff')" :multiple="true" + full-tooltip-position="tr" :has-all-select="true" @popup-visible-change="popupVisibleChange" >