ai-front-base 0.1.11 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (75) hide show
  1. package/dist/components/AiAside/index.mjs +4 -0
  2. package/dist/components/AiAside/index.vue.mjs +20 -0
  3. package/dist/components/AiAside/types.ts +6 -0
  4. package/dist/components/AiBadge/index.mjs +4 -0
  5. package/dist/components/AiBadge/index.vue.mjs +20 -0
  6. package/dist/components/AiBadge/types.ts +10 -0
  7. package/dist/components/AiBreadcrumb/index.mjs +4 -0
  8. package/dist/components/AiBreadcrumb/index.vue.mjs +20 -0
  9. package/dist/components/AiBreadcrumb/types.ts +7 -0
  10. package/dist/components/AiCheckbox/index.mjs +4 -0
  11. package/dist/components/AiCheckbox/index.vue.mjs +20 -0
  12. package/dist/components/AiCheckbox/types.ts +14 -0
  13. package/dist/components/AiContainer/index.mjs +4 -0
  14. package/dist/components/AiContainer/index.vue.mjs +20 -0
  15. package/dist/components/AiContainer/types.ts +6 -0
  16. package/dist/components/AiDatePicker/index.mjs +4 -0
  17. package/dist/components/AiDatePicker/index.vue.mjs +15 -0
  18. package/dist/components/AiDatePicker/types.ts +17 -0
  19. package/dist/components/AiDialog/index.mjs +4 -0
  20. package/dist/components/AiDialog/index.vue.mjs +20 -0
  21. package/dist/components/AiDialog/types.ts +11 -0
  22. package/dist/components/AiFooter/index.mjs +4 -0
  23. package/dist/components/AiFooter/index.vue.mjs +20 -0
  24. package/dist/components/AiFooter/types.ts +6 -0
  25. package/dist/components/AiHeader/index.mjs +4 -0
  26. package/dist/components/AiHeader/index.vue.mjs +20 -0
  27. package/dist/components/AiHeader/types.ts +6 -0
  28. package/dist/components/AiLoading/index.mjs +5 -0
  29. package/dist/components/AiLoading/types.ts +7 -0
  30. package/dist/components/AiMain/index.mjs +4 -0
  31. package/dist/components/AiMain/index.vue.mjs +20 -0
  32. package/dist/components/AiMain/types.ts +4 -0
  33. package/dist/components/AiMenu/index.mjs +4 -0
  34. package/dist/components/AiMenu/index.vue.mjs +20 -0
  35. package/dist/components/AiMenu/types.ts +9 -0
  36. package/dist/components/AiMessage/index.mjs +5 -0
  37. package/dist/components/AiMessage/types.ts +9 -0
  38. package/dist/components/AiNotification/index.mjs +5 -0
  39. package/dist/components/AiNotification/types.ts +10 -0
  40. package/dist/components/AiPagination/index.mjs +4 -0
  41. package/dist/components/AiPagination/index.vue.mjs +15 -0
  42. package/dist/components/AiPagination/types.ts +9 -0
  43. package/dist/components/AiProgress/index.mjs +4 -0
  44. package/dist/components/AiProgress/index.vue.mjs +15 -0
  45. package/dist/components/AiProgress/types.ts +10 -0
  46. package/dist/components/AiRadio/index.mjs +4 -0
  47. package/dist/components/AiRadio/index.vue.mjs +20 -0
  48. package/dist/components/AiRadio/types.ts +8 -0
  49. package/dist/components/AiSwitch/index.mjs +4 -0
  50. package/dist/components/AiSwitch/index.vue.mjs +15 -0
  51. package/dist/components/AiSwitch/types.ts +9 -0
  52. package/dist/components/AiTabs/index.mjs +4 -0
  53. package/dist/components/AiTabs/index.vue.mjs +20 -0
  54. package/dist/components/AiTabs/types.ts +9 -0
  55. package/dist/components/AiTag/index.mjs +4 -0
  56. package/dist/components/AiTag/index.vue.mjs +20 -0
  57. package/dist/components/AiTag/types.ts +9 -0
  58. package/dist/components/AiTimePicker/index.mjs +4 -0
  59. package/dist/components/AiTimePicker/index.vue.mjs +15 -0
  60. package/dist/components/AiTimePicker/types.ts +16 -0
  61. package/dist/components/AiUpload/index.mjs +4 -0
  62. package/dist/components/AiUpload/index.vue.mjs +20 -0
  63. package/dist/components/AiUpload/types.ts +11 -0
  64. package/dist/components/README.md +36 -28
  65. package/dist/index.mjs +52 -8
  66. package/dist/layouts/government.md +203 -58
  67. package/dist/layouts/union.md +208 -57
  68. package/dist/standards/README.md +45 -0
  69. package/dist/styles/README.md +155 -17
  70. package/dist/styles/blue.scss +68 -4
  71. package/dist/styles/dark.scss +69 -5
  72. package/dist/styles/element-plus-theme.css +52 -0
  73. package/dist/styles/index.css +70 -0
  74. package/dist/styles/light-blue.scss +68 -4
  75. package/package.json +1 -1
@@ -13,66 +13,217 @@
13
13
  **推荐主题**:
14
14
  - `light-blue` - 浅蓝温馨主题
15
15
  - `blue` - 蓝色专业主题
16
- - `minimal` - 极简清爽主题
17
16
 
18
- ## 页面类型布局指导
19
-
20
- ### 1. 列表检索页
17
+ ## 整体布局结构
18
+
19
+ ### 标准后台布局
20
+ ```
21
+ ┌─────────────────────────────────────┐
22
+ │ Header (64px) │
23
+ ├──────┬──────────────────────────────┤
24
+ │ │ │
25
+ │ Aside│ Main │
26
+ │(220px│ Content │
27
+ │ │ │
28
+ ├──────┴──────────────────────────────┤
29
+ │ Footer (64px) │
30
+ └─────────────────────────────────────┘
31
+ ```
32
+
33
+ **布局规范**:
34
+ - Header高度:64px,固定定位
35
+ - Aside宽度:220px(收起时80px)
36
+ - Main内边距:24px
37
+ - Footer高度:64px
38
+ - 圆角:使用较大圆角(8px-12px)
39
+
40
+ ### 页面内容区布局
41
+ ```
42
+ ┌─────────────────────────────────────┐
43
+ │ 面包屑导航 (margin-bottom: 20px) │
44
+ ├─────────────────────────────────────┤
45
+ │ 页面标题 + 操作按钮 │
46
+ │ (margin-bottom: 24px) │
47
+ ├─────────────────────────────────────┤
48
+ │ │
49
+ │ 主内容区 │
50
+ │ (padding: 24px) │
51
+ │ │
52
+ └─────────────────────────────────────┘
53
+ ```
21
54
 
22
- **布局准则**:
23
- - 搜索框使用凹陷效果(inset shadow)
24
- - 列表项使用轻微凸起效果
25
- - 筛选按钮组使用分段控制器样式
26
- - 避免使用传统边框,用阴影区分区域
55
+ ## 页面类型布局指导
27
56
 
28
- **推荐组件**:
29
- - 组件库: `AiSearchBar`, `AiListItem`, `AiFilterGroup`
30
- - 备选: `ElInput`, `ElCard`, `ElSegmented`
57
+ ### 1. 列表页
58
+
59
+ **结构**:
60
+ - 搜索区:padding 24px,背景色 bg-base,圆角 8px
61
+ - 表格区:margin-top 20px
62
+ - 分页器:margin-top 20px,居中对齐
63
+
64
+ **间距规范**:
65
+ - 搜索表单项间距:20px
66
+ - 表格行高:52px
67
+ - 操作按钮间距:12px
68
+
69
+ **组件使用**:
70
+ ```vue
71
+ <AiContainer>
72
+ <AiMain>
73
+ <!-- 搜索区 -->
74
+ <div style="padding: var(--ai-padding-lg); background: var(--ai-bg-base); border-radius: var(--ai-radius-lg)">
75
+ <AiForm :inline="true">
76
+ <AiInput placeholder="搜索" />
77
+ <AiSelect placeholder="状态" />
78
+ </AiForm>
79
+ </div>
80
+
81
+ <!-- 表格区 -->
82
+ <AiTable :data="list" style="margin-top: var(--ai-margin-lg)" />
83
+
84
+ <!-- 分页 -->
85
+ <div style="margin-top: var(--ai-margin-lg); text-align: center">
86
+ <AiPagination />
87
+ </div>
88
+ </AiMain>
89
+ </AiContainer>
90
+ ```
31
91
 
32
92
  ### 2. 详情页
33
93
 
34
- **布局准则**:
35
- - 主内容卡片使用大圆角(20-24px)
36
- - 信息分组使用轻微凸起的卡片
37
- - 操作按钮使用凸起效果,点击时切换为凹陷
38
- - 头像/图片使用圆形+双层阴影
39
-
40
- **推荐组件**:
41
- - 组件库: `AiCard`, `AiAvatar`, `AiDescriptions`
42
- - 备选: `ElCard`, `ElDescriptions`, `ElButton`
43
-
44
- ### 3. 编辑页/表单页
45
-
46
- **布局准则**:
47
- - 输入框使用凹陷效果
48
- - 表单容器使用轻微凸起
49
- - 提交按钮使用明显凸起,取消按钮使用平面
50
- - 表单项间距加大(20-24px)
51
-
52
- **推荐组件**:
53
- - 组件库: `AiForm`, `AiInput`, `AiButton`
54
- - 备选: `ElForm`, `ElInput`, `ElButton`
55
-
56
- ### 4. 看板页/仪表盘
57
-
58
- **布局准则**:
59
- - 统计卡片使用中等凸起效果
60
- - 图表容器使用轻微凹陷(内嵌感)
61
- - 卡片间距统一(16-20px)
62
- - 避免过多层级,最多2层阴影
63
-
64
- **推荐组件**:
65
- - 组件库: `AiStatistic`, `AiChart`, `AiGrid`
66
- - 备选: `ElCard`, `ElStatistic`, `ElRow`/`ElCol`
67
-
68
- ### 5. 弹窗/对话框
69
-
70
- **布局准则**:
71
- - 弹窗背景使用主色调
72
- - 弹窗本身使用强凸起效果
73
- - 关闭按钮使用圆形凸起
74
- - 避免使用传统边框和分割线
75
-
76
- **推荐组件**:
77
- - 组件库: `AiDialog`, `AiDrawer`, `AiModal`
78
- - 备选: `ElDialog`, `ElDrawer`
94
+ **结构**:
95
+ - 基本信息卡片:margin-bottom 20px,圆角 12px
96
+ - 详细信息卡片:margin-bottom 20px,圆角 12px
97
+ - 操作历史:margin-bottom 20px
98
+
99
+ **间距规范**:
100
+ - 卡片内边距:24px
101
+ - 信息项间距:20px
102
+ - 标签与值间距:12px
103
+
104
+ **组件使用**:
105
+ ```vue
106
+ <AiContainer>
107
+ <AiMain>
108
+ <!-- 基本信息 -->
109
+ <div style="padding: var(--ai-padding-lg); background: var(--ai-bg-base); border-radius: var(--ai-radius-xl); margin-bottom: var(--ai-margin-lg)">
110
+ <h3>基本信息</h3>
111
+ <div style="margin-top: var(--ai-margin-lg)">
112
+ <div style="margin-bottom: var(--ai-margin-lg)">
113
+ <span>姓名:</span><span>张三</span>
114
+ </div>
115
+ </div>
116
+ </div>
117
+ </AiMain>
118
+ </AiContainer>
119
+ ```
120
+
121
+ ### 3. 表单页
122
+
123
+ **结构**:
124
+ - 表单容器:padding 24px,圆角 12px
125
+ - 表单项:margin-bottom 24px
126
+ - 按钮组:margin-top 32px,居中对齐
127
+
128
+ **间距规范**:
129
+ - 表单项间距:24px
130
+ - 标签宽度:100px
131
+ - 按钮间距:16px
132
+
133
+ **组件使用**:
134
+ ```vue
135
+ <AiContainer>
136
+ <AiMain>
137
+ <div style="padding: var(--ai-padding-xl); background: var(--ai-bg-base); border-radius: var(--ai-radius-xl)">
138
+ <AiForm :label-width="100">
139
+ <AiInput label="姓名" />
140
+ <AiSelect label="部门" />
141
+ <div style="margin-top: var(--ai-margin-xl); text-align: center">
142
+ <el-button type="primary" size="large">提交</el-button>
143
+ <el-button size="large">取消</el-button>
144
+ </div>
145
+ </AiForm>
146
+ </div>
147
+ </AiMain>
148
+ </AiContainer>
149
+ ```
150
+
151
+ ### 4. 看板页
152
+
153
+ **结构**:
154
+ - 统计卡片行:margin-bottom 20px
155
+ - 图表区:2列布局
156
+ - 卡片间距:20px
157
+
158
+ **间距规范**:
159
+ - 卡片内边距:24px
160
+ - 卡片间距:20px
161
+ - 标题与内容间距:20px
162
+
163
+ **组件使用**:
164
+ ```vue
165
+ <AiContainer>
166
+ <AiMain>
167
+ <!-- 统计卡片 -->
168
+ <div style="display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--ai-spacing-lg); margin-bottom: var(--ai-margin-lg)">
169
+ <div style="padding: var(--ai-padding-lg); background: var(--ai-bg-base); border-radius: var(--ai-radius-lg)">
170
+ <AiStatistic title="总数" :value="1000" />
171
+ </div>
172
+ </div>
173
+
174
+ <!-- 图表区 -->
175
+ <div style="display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--ai-spacing-lg)">
176
+ <div style="padding: var(--ai-padding-lg); background: var(--ai-bg-base); border-radius: var(--ai-radius-lg)">
177
+ 图表内容
178
+ </div>
179
+ </div>
180
+ </AiMain>
181
+ </AiContainer>
182
+ ```
183
+
184
+ ### 5. 弹窗
185
+
186
+ **间距规范**:
187
+ - 弹窗内边距:24px
188
+ - 标题与内容间距:20px
189
+ - 按钮组间距:16px
190
+ - 圆角:12px
191
+
192
+ **组件使用**:
193
+ ```vue
194
+ <AiDialog title="标题" width="600px">
195
+ <div style="padding: var(--ai-padding-lg)">
196
+ 内容区
197
+ </div>
198
+ <template #footer>
199
+ <div style="text-align: center">
200
+ <el-button type="primary" size="large">确定</el-button>
201
+ <el-button size="large">取消</el-button>
202
+ </div>
203
+ </template>
204
+ </AiDialog>
205
+ ```
206
+
207
+ ## 间距规范总结
208
+
209
+ | 场景 | 间距值 | CSS变量 |
210
+ |------|--------|---------|
211
+ | 页面内边距 | 24px | --ai-padding-lg |
212
+ | 卡片间距 | 20px | --ai-margin-lg |
213
+ | 表单项间距 | 24px | --ai-margin-lg |
214
+ | 按钮间距 | 12px | --ai-margin-md |
215
+ | 小元素间距 | 8px | --ai-margin-sm |
216
+
217
+ ## 响应式规则
218
+
219
+ **断点**:
220
+ - 大屏:>1920px
221
+ - 标准:1440px-1920px
222
+ - 小屏:1280px-1440px
223
+ - 最小:<1280px
224
+
225
+ **适配规则**:
226
+ - 大屏:Main内边距增加到32px,卡片间距增加到24px
227
+ - 标准:使用默认24px
228
+ - 小屏:Aside收起,Main内边距减少到16px
229
+ - 最小:不支持,提示使用更大屏幕
@@ -27,6 +27,51 @@
27
27
  - 警告any类型
28
28
  - 要求组件名多单词
29
29
 
30
+ ## CSS样式规范
31
+
32
+ ### ⚠️ 强制规则
33
+
34
+ **所有CSS样式必须使用主题变量,禁止硬编码**
35
+
36
+ 1. **禁止硬编码色值** - 所有颜色必须使用CSS变量
37
+ 2. **禁止硬编码间距** - 所有padding/margin必须使用间距变量
38
+ 3. **禁止硬编码尺寸** - 圆角、字号、行高必须使用对应变量
39
+
40
+ ### 可用变量
41
+
42
+ 查看 [样式主题文档](../styles/README.md) 了解完整变量列表
43
+
44
+ ### ✅ 正确示例
45
+ ```css
46
+ .card {
47
+ color: var(--ai-text-primary);
48
+ background: var(--ai-bg-base);
49
+ padding: var(--ai-padding-md);
50
+ margin-bottom: var(--ai-margin-lg);
51
+ border: 1px solid var(--ai-border-base);
52
+ border-radius: var(--ai-radius-base);
53
+ font-size: var(--ai-font-base);
54
+ box-shadow: var(--ai-shadow-sm);
55
+ transition: all var(--ai-transition-base);
56
+ }
57
+
58
+ .card:hover {
59
+ background: var(--ai-hover);
60
+ }
61
+ ```
62
+
63
+ ### ❌ 错误示例
64
+ ```css
65
+ .card {
66
+ color: #333; /* ❌ 硬编码色值 */
67
+ background: #fff; /* ❌ 硬编码色值 */
68
+ padding: 16px; /* ❌ 硬编码间距 */
69
+ margin-bottom: 24px; /* ❌ 硬编码间距 */
70
+ border: 1px solid #ddd; /* ❌ 硬编码色值 */
71
+ border-radius: 4px; /* ❌ 硬编码圆角 */
72
+ }
73
+ ```
74
+
30
75
  ## Vue开发规范
31
76
 
32
77
  ### 组件结构
@@ -19,33 +19,171 @@ AI组件库样式主题库
19
19
  import 'ai-front-base/styles'
20
20
  ```
21
21
 
22
- **默认主题:** `blue`(蓝色专业主题,每个业务系统MUST设置)
22
+ **步骤2:设置主题(必须)**
23
23
 
24
- **步骤2:切换主题(可选)**
24
+ ⚠️ **重要:必须在HTML的body标签上设置data-theme属性**
25
+
26
+ **方法1:在index.html中直接设置(推荐)**
27
+ ```html
28
+ <!DOCTYPE html>
29
+ <html>
30
+ <head>...</head>
31
+ <body data-theme="blue">
32
+ <div id="app"></div>
33
+ </body>
34
+ </html>
35
+ ```
36
+
37
+ **方法2:在App.vue中动态设置**
25
38
  ```vue
26
- <template>
27
- <body :data-theme="theme">
28
- <div>内容</div>
29
- </body>
30
- </template>
39
+ <script setup>
40
+ import { onMounted } from 'vue'
31
41
 
42
+ onMounted(() => {
43
+ document.body.setAttribute('data-theme', 'blue')
44
+ })
45
+ </script>
46
+ ```
47
+
48
+ **方法3:支持主题切换**
49
+ ```vue
32
50
  <script setup>
33
- import { ref } from 'vue'
34
- const theme = ref('light-blue')
51
+ import { ref, watch } from 'vue'
52
+
53
+ const theme = ref('blue')
54
+
55
+ watch(theme, (newTheme) => {
56
+ document.body.setAttribute('data-theme', newTheme)
57
+ }, { immediate: true })
58
+
59
+ const changeTheme = (newTheme) => {
60
+ theme.value = newTheme
61
+ }
35
62
  </script>
63
+
64
+ <template>
65
+ <div>
66
+ <button @click="changeTheme('blue')">蓝色主题</button>
67
+ <button @click="changeTheme('light-blue')">浅蓝主题</button>
68
+ <button @click="changeTheme('dark')">深色主题</button>
69
+ </div>
70
+ </template>
36
71
  ```
37
72
 
38
73
  **可选主题值:**
39
- - `blue` - 蓝色专业主题
74
+ - `blue` - 蓝色专业主题(默认)
40
75
  - `light-blue` - 浅蓝温馨主题
41
76
  - `dark` - 深色主题
42
77
 
43
78
 
44
- ## 主题变量
79
+ ## CSS变量体系
80
+
81
+ ### 色值变量
82
+ ```css
83
+ /* 主色系 */
84
+ --ai-primary /* 主色 */
85
+ --ai-success /* 成功色 */
86
+ --ai-warning /* 警告色 */
87
+ --ai-danger /* 危险色 */
88
+ --ai-info /* 信息色 */
89
+
90
+ /* 背景色 */
91
+ --ai-bg-base /* 基础背景 */
92
+ --ai-bg-light /* 浅色背景 */
93
+ --ai-bg-dark /* 深色背景 */
94
+ --ai-bg-overlay /* 遮罩背景 */
95
+
96
+ /* 文字色 */
97
+ --ai-text-primary /* 主要文字 */
98
+ --ai-text-regular /* 常规文字 */
99
+ --ai-text-secondary /* 次要文字 */
100
+ --ai-text-placeholder /* 占位文字 */
101
+ --ai-text-disabled /* 禁用文字 */
102
+
103
+ /* 边框色 */
104
+ --ai-border-base /* 基础边框 */
105
+ --ai-border-light /* 浅色边框 */
106
+ --ai-border-dark /* 深色边框 */
107
+
108
+ /* 功能色 */
109
+ --ai-link /* 链接色 */
110
+ --ai-hover /* 悬停色 */
111
+ --ai-active /* 激活色 */
112
+ --ai-disabled /* 禁用色 */
113
+ ```
114
+
115
+ ### 间距变量
116
+ ```css
117
+ /* 基础间距 */
118
+ --ai-spacing-xs /* 4px */
119
+ --ai-spacing-sm /* 8px */
120
+ --ai-spacing-md /* 16px */
121
+ --ai-spacing-lg /* 24px */
122
+ --ai-spacing-xl /* 32px */
123
+
124
+ /* 内边距 */
125
+ --ai-padding-xs/sm/md/lg/xl
126
+
127
+ /* 外边距 */
128
+ --ai-margin-xs/sm/md/lg/xl
129
+ ```
130
+
131
+ ### 尺寸变量
132
+ ```css
133
+ /* 圆角 */
134
+ --ai-radius-sm /* 2px */
135
+ --ai-radius-base /* 4px */
136
+ --ai-radius-lg /* 8px */
137
+ --ai-radius-xl /* 12px */
138
+
139
+ /* 字号 */
140
+ --ai-font-xs /* 12px */
141
+ --ai-font-sm /* 14px */
142
+ --ai-font-base /* 16px */
143
+ --ai-font-lg /* 18px */
144
+ --ai-font-xl /* 20px */
145
+
146
+ /* 行高 */
147
+ --ai-line-height-sm/base/lg
148
+
149
+ /* 阴影 */
150
+ --ai-shadow-sm/base/lg
151
+ ```
152
+
153
+ ### 动画变量
154
+ ```css
155
+ --ai-transition-fast /* 0.1s */
156
+ --ai-transition-base /* 0.3s */
157
+ --ai-transition-slow /* 0.5s */
158
+ ```
159
+
160
+ ## CSS样式规范
161
+
162
+ ### ⚠️ 强制规则
163
+
164
+ 1. **禁止硬编码色值** - 所有颜色必须使用CSS变量
165
+ 2. **禁止硬编码间距** - 所有padding/margin必须使用间距变量
166
+ 3. **禁止硬编码尺寸** - 圆角、字号、行高必须使用对应变量
167
+
168
+ ### ✅ 正确示例
169
+ ```css
170
+ .button {
171
+ color: var(--ai-text-primary);
172
+ background: var(--ai-primary);
173
+ padding: var(--ai-padding-sm) var(--ai-padding-md);
174
+ border-radius: var(--ai-radius-base);
175
+ font-size: var(--ai-font-base);
176
+ transition: all var(--ai-transition-base);
177
+ }
178
+ ```
179
+
180
+ ### ❌ 错误示例
181
+ ```css
182
+ .button {
183
+ color: #333; /* ❌ 硬编码色值 */
184
+ background: #1890ff; /* ❌ 硬编码色值 */
185
+ padding: 8px 16px; /* ❌ 硬编码间距 */
186
+ border-radius: 4px; /* ❌ 硬编码圆角 */
187
+ }
188
+ ```
45
189
 
46
- 所有主题提供统一的CSS变量:
47
- - `--ai-primary` - 主色调
48
- - `--ai-bg` - 背景色
49
- - `--ai-text` - 文字色
50
- - `--ai-border` - 边框色
51
- - `--ai-radius` - 圆角
@@ -1,7 +1,71 @@
1
1
  body[data-theme="blue"] {
2
+ // 主色系
2
3
  --ai-primary: #1890ff;
3
- --ai-bg: #ffffff;
4
- --ai-text: #333333;
5
- --ai-border: #d9d9d9;
6
- --ai-radius: 4px;
4
+ --ai-success: #52c41a;
5
+ --ai-warning: #faad14;
6
+ --ai-danger: #ff4d4f;
7
+ --ai-info: #1890ff;
8
+
9
+ // 背景色
10
+ --ai-bg-base: #ffffff;
11
+ --ai-bg-light: #fafafa;
12
+ --ai-bg-dark: #f5f5f5;
13
+ --ai-bg-overlay: rgba(0, 0, 0, 0.45);
14
+
15
+ // 文字色
16
+ --ai-text-primary: #262626;
17
+ --ai-text-regular: #595959;
18
+ --ai-text-secondary: #8c8c8c;
19
+ --ai-text-placeholder: #bfbfbf;
20
+ --ai-text-disabled: #d9d9d9;
21
+
22
+ // 边框色
23
+ --ai-border-base: #d9d9d9;
24
+ --ai-border-light: #e8e8e8;
25
+ --ai-border-dark: #bfbfbf;
26
+
27
+ // 功能色
28
+ --ai-link: #1890ff;
29
+ --ai-hover: #40a9ff;
30
+ --ai-active: #096dd9;
31
+ --ai-disabled: #f5f5f5;
32
+
33
+ // 间距
34
+ --ai-spacing-xs: 4px;
35
+ --ai-spacing-sm: 8px;
36
+ --ai-spacing-md: 16px;
37
+ --ai-spacing-lg: 24px;
38
+ --ai-spacing-xl: 32px;
39
+ --ai-padding-xs: 4px;
40
+ --ai-padding-sm: 8px;
41
+ --ai-padding-md: 16px;
42
+ --ai-padding-lg: 24px;
43
+ --ai-padding-xl: 32px;
44
+ --ai-margin-xs: 4px;
45
+ --ai-margin-sm: 8px;
46
+ --ai-margin-md: 16px;
47
+ --ai-margin-lg: 24px;
48
+ --ai-margin-xl: 32px;
49
+
50
+ // 尺寸
51
+ --ai-radius-sm: 2px;
52
+ --ai-radius-base: 4px;
53
+ --ai-radius-lg: 8px;
54
+ --ai-radius-xl: 12px;
55
+ --ai-font-xs: 12px;
56
+ --ai-font-sm: 14px;
57
+ --ai-font-base: 16px;
58
+ --ai-font-lg: 18px;
59
+ --ai-font-xl: 20px;
60
+ --ai-line-height-sm: 1.2;
61
+ --ai-line-height-base: 1.5;
62
+ --ai-line-height-lg: 1.8;
63
+ --ai-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.08);
64
+ --ai-shadow-base: 0 4px 8px rgba(0, 0, 0, 0.12);
65
+ --ai-shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.16);
66
+
67
+ // 动画
68
+ --ai-transition-fast: 0.1s;
69
+ --ai-transition-base: 0.3s;
70
+ --ai-transition-slow: 0.5s;
7
71
  }
@@ -1,7 +1,71 @@
1
1
  body[data-theme="dark"] {
2
- --ai-primary: #177ddc;
3
- --ai-bg: #141414;
4
- --ai-text: #ffffff;
5
- --ai-border: #434343;
6
- --ai-radius: 4px;
2
+ // 主色系 - 深蓝暗黑主题
3
+ --ai-primary: #1668dc;
4
+ --ai-success: #49aa19;
5
+ --ai-warning: #d89614;
6
+ --ai-danger: #d32029;
7
+ --ai-info: #1668dc;
8
+
9
+ // 背景色
10
+ --ai-bg-base: #141414;
11
+ --ai-bg-light: #1f1f1f;
12
+ --ai-bg-dark: #0a0a0a;
13
+ --ai-bg-overlay: rgba(0, 0, 0, 0.65);
14
+
15
+ // 文字色
16
+ --ai-text-primary: #ffffff;
17
+ --ai-text-regular: #d9d9d9;
18
+ --ai-text-secondary: #8c8c8c;
19
+ --ai-text-placeholder: #595959;
20
+ --ai-text-disabled: #434343;
21
+
22
+ // 边框色
23
+ --ai-border-base: #434343;
24
+ --ai-border-light: #303030;
25
+ --ai-border-dark: #595959;
26
+
27
+ // 功能色
28
+ --ai-link: #1668dc;
29
+ --ai-hover: #3c9ae8;
30
+ --ai-active: #0958d9;
31
+ --ai-disabled: #262626;
32
+
33
+ // 间距
34
+ --ai-spacing-xs: 4px;
35
+ --ai-spacing-sm: 8px;
36
+ --ai-spacing-md: 16px;
37
+ --ai-spacing-lg: 24px;
38
+ --ai-spacing-xl: 32px;
39
+ --ai-padding-xs: 4px;
40
+ --ai-padding-sm: 8px;
41
+ --ai-padding-md: 16px;
42
+ --ai-padding-lg: 24px;
43
+ --ai-padding-xl: 32px;
44
+ --ai-margin-xs: 4px;
45
+ --ai-margin-sm: 8px;
46
+ --ai-margin-md: 16px;
47
+ --ai-margin-lg: 24px;
48
+ --ai-margin-xl: 32px;
49
+
50
+ // 尺寸
51
+ --ai-radius-sm: 2px;
52
+ --ai-radius-base: 4px;
53
+ --ai-radius-lg: 8px;
54
+ --ai-radius-xl: 12px;
55
+ --ai-font-xs: 12px;
56
+ --ai-font-sm: 14px;
57
+ --ai-font-base: 16px;
58
+ --ai-font-lg: 18px;
59
+ --ai-font-xl: 20px;
60
+ --ai-line-height-sm: 1.2;
61
+ --ai-line-height-base: 1.5;
62
+ --ai-line-height-lg: 1.8;
63
+ --ai-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.24);
64
+ --ai-shadow-base: 0 4px 8px rgba(0, 0, 0, 0.32);
65
+ --ai-shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.48);
66
+
67
+ // 动画
68
+ --ai-transition-fast: 0.1s;
69
+ --ai-transition-base: 0.3s;
70
+ --ai-transition-slow: 0.5s;
7
71
  }