Pārlūkot izejas kodu

下载管理图标智能/自主两模式统一 20px,用户下拉箭头颜色对齐自主模式

cc 1 dienu atpakaļ
vecāks
revīzija
7f52c72774

+ 2 - 8
ai-electron/frontend/src/ai/views/aiWorkbench/index.vue

@@ -328,7 +328,8 @@
    * 下载管理入口的图标按钮观感:传统壳那套 `.jeesite-layout-header-action > div`
    * 规则只存在于传统布局样式表(layouts/default/header/index.less),工作台路由下
    * 不加载,这里自带一份(取值与 `jeesite-header-action-button` 一致:顶栏缩排后 30×28),
-   * 只作用于本页,不影响传统壳原有外观。
+   * 只作用于本页,不影响传统壳原有外观。图标尺寸(20px)由组件自身样式统一,
+   * 两个模式不再各写一份。
    */
   .awb-page .jeesite-app-download-manager-trigger {
     display: inline-flex;
@@ -343,13 +344,6 @@
     cursor: pointer;
     transition: background-color 0.2s ease;
 
-    .dl-trigger__icon {
-      display: inline-flex;
-      align-items: center;
-      font-size: 14px;
-      line-height: 1;
-    }
-
     &:hover {
       background-color: @header-light-bg-hover-color;
     }

+ 9 - 1
ai-electron/frontend/src/core/components/Application/src/AppDownloadManager.vue

@@ -4,7 +4,7 @@
     :title="activeCount > 0 ? `正在下载 ${activeCount} 个文件` : '下载管理'"
     @click="openModal(true)"
   >
-    <span class="dl-trigger__icon"><Icon icon="i-mdi:download-outline" /></span>
+    <span class="dl-trigger__icon"><Icon icon="i-mdi:download-outline" :size="20" /></span>
     <span v-if="activeCount > 0" class="dl-trigger__badge">{{ activeCount }}</span>
     <span v-else-if="items.length" class="dl-trigger__dot"></span>
   </div>
@@ -346,6 +346,14 @@
   .@{prefix-cls}-trigger {
     position: relative;
 
+    /* 图标盒自带字号与行高(不继承外层),保证传统壳与智能壳下大小、垂直居中一致 */
+    .dl-trigger__icon {
+      display: inline-flex;
+      align-items: center;
+      font-size: 20px;
+      line-height: 1;
+    }
+
     /* 下载中:箭头上下轻跳,提示还有任务在跑 */
     &.is-busy .dl-trigger__icon {
       animation: dl-trigger-bob 1.1s ease-in-out infinite;

+ 3 - 1
ai-electron/frontend/src/core/layouts/default/header/components/user-dropdown/index.vue

@@ -187,7 +187,9 @@
 
     &__caret {
       font-size: 10px;
-      color: @cb-text-secondary;
+      /* 取 @text-color-base 与自主(传统)壳一致:那边主题把 action 区
+         role=img 图标定成该色,若这里用次要灰,智能壳下颜色就和自主模式不一样 */
+      color: @text-color-base;
     }
   }