yd-admin 0.1.7 → 0.1.8
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.
- package/README.md +372 -327
- package/dist/index.js +3106 -496
- package/dist/style.css +2709 -1032
- package/package.json +81 -81
- package/dist/chunk-pbuEa-1d.js +0 -13
- package/dist/index.d.ts +0 -4588
package/README.md
CHANGED
|
@@ -1,327 +1,372 @@
|
|
|
1
|
-
# yd-admin
|
|
2
|
-
|
|
3
|
-
🎨 基于 Vue 3 的后台管理框架通用组件库
|
|
4
|
-
|
|
5
|
-
[](https://www.npmjs.com/package/yd-admin)
|
|
6
|
-
[](https://opensource.org/licenses/MIT)
|
|
7
|
-
[](https://vuejs.org/)
|
|
8
|
-
[](https://www.typescriptlang.org/)
|
|
9
|
-
|
|
10
|
-
## ✨ 特性
|
|
11
|
-
|
|
12
|
-
- 📦 **轻量高效** - Tree-shaking 支持,按需引入
|
|
13
|
-
- 🎯 **类型安全** - 完整的 TypeScript 类型定义
|
|
14
|
-
- 🎨 **主题定制** - CSS 变量设计,支持暗色模式
|
|
15
|
-
- ⚡ **性能优化** - 虚拟滚动、防抖节流、位置缓存
|
|
16
|
-
- 🔌 **即插即用** - 零配置,简单 API
|
|
17
|
-
|
|
18
|
-
## 📦 安装
|
|
19
|
-
|
|
20
|
-
```bash
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
```
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
|
71
|
-
|
|
|
72
|
-
| `
|
|
73
|
-
| `
|
|
74
|
-
| `
|
|
75
|
-
| `
|
|
76
|
-
| `
|
|
77
|
-
| `
|
|
78
|
-
| `
|
|
79
|
-
| `
|
|
80
|
-
| `
|
|
81
|
-
| `
|
|
82
|
-
| `
|
|
83
|
-
| `
|
|
84
|
-
| `
|
|
85
|
-
| `
|
|
86
|
-
| `
|
|
87
|
-
| `
|
|
88
|
-
| `
|
|
89
|
-
| `
|
|
90
|
-
| `
|
|
91
|
-
| `
|
|
92
|
-
| `
|
|
93
|
-
| `
|
|
94
|
-
| `
|
|
95
|
-
| `
|
|
96
|
-
| `
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
|
104
|
-
|
|
|
105
|
-
| `
|
|
106
|
-
| `
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
|
111
|
-
|
|
|
112
|
-
| `
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
|
119
|
-
|
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
|
139
|
-
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
|
157
|
-
|
|
|
158
|
-
| `
|
|
159
|
-
| `
|
|
160
|
-
| `
|
|
161
|
-
| `
|
|
162
|
-
| `
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
|
167
|
-
|
|
|
168
|
-
| `
|
|
169
|
-
| `
|
|
170
|
-
| `
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
|
175
|
-
|
|
|
176
|
-
| `
|
|
177
|
-
| `
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
|
182
|
-
|
|
|
183
|
-
| `
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
```
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
```
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
#
|
|
291
|
-
vp build
|
|
292
|
-
```
|
|
293
|
-
|
|
294
|
-
###
|
|
295
|
-
|
|
296
|
-
```bash
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
-
|
|
322
|
-
-
|
|
323
|
-
-
|
|
324
|
-
|
|
325
|
-
##
|
|
326
|
-
|
|
327
|
-
|
|
1
|
+
# yd-admin
|
|
2
|
+
|
|
3
|
+
🎨 基于 Vue 3 的后台管理框架通用组件库
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/yd-admin)
|
|
6
|
+
[](https://opensource.org/licenses/MIT)
|
|
7
|
+
[](https://vuejs.org/)
|
|
8
|
+
[](https://www.typescriptlang.org/)
|
|
9
|
+
|
|
10
|
+
## ✨ 特性
|
|
11
|
+
|
|
12
|
+
- 📦 **轻量高效** - Tree-shaking 支持,按需引入
|
|
13
|
+
- 🎯 **类型安全** - 完整的 TypeScript 类型定义
|
|
14
|
+
- 🎨 **主题定制** - CSS 变量设计,支持暗色模式
|
|
15
|
+
- ⚡ **性能优化** - 虚拟滚动、防抖节流、位置缓存
|
|
16
|
+
- 🔌 **即插即用** - 零配置,简单 API
|
|
17
|
+
|
|
18
|
+
## 📦 安装
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
vp add yd-admin
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## 🚀 快速开始
|
|
25
|
+
|
|
26
|
+
### 完整引入
|
|
27
|
+
|
|
28
|
+
```typescript
|
|
29
|
+
import { createApp } from "vue";
|
|
30
|
+
import YdAdmin from "yd-admin";
|
|
31
|
+
import "yd-admin/style.css"; // 引入样式
|
|
32
|
+
import App from "./App.vue";
|
|
33
|
+
|
|
34
|
+
const app = createApp(App);
|
|
35
|
+
app.use(YdAdmin);
|
|
36
|
+
app.mount("#app");
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
### 按需引入
|
|
40
|
+
|
|
41
|
+
```typescript
|
|
42
|
+
import { YdButton, YdInput, YdSelect } from "yd-admin";
|
|
43
|
+
import "yd-admin/style.css";
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
### Vite 配置(自动导入)
|
|
47
|
+
|
|
48
|
+
```typescript
|
|
49
|
+
// vite.config.ts
|
|
50
|
+
import Components from "unplugin-vue-components/vite";
|
|
51
|
+
import { YdAdminResolver } from "yd-admin/resolver";
|
|
52
|
+
|
|
53
|
+
export default {
|
|
54
|
+
plugins: [
|
|
55
|
+
Components({
|
|
56
|
+
resolvers: [YdAdminResolver()],
|
|
57
|
+
}),
|
|
58
|
+
],
|
|
59
|
+
};
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
## 📚 组件列表
|
|
63
|
+
|
|
64
|
+
### 基础组件 (Base)
|
|
65
|
+
|
|
66
|
+
| 组件 | 说明 |
|
|
67
|
+
| ------------------- | ------------ |
|
|
68
|
+
| `YdButton` | 按钮 |
|
|
69
|
+
| `YdInput` | 输入框 |
|
|
70
|
+
| `YdTextarea` | 多行文本 |
|
|
71
|
+
| `YdInputNumber` | 数字输入 |
|
|
72
|
+
| `YdSelect` | 选择器 |
|
|
73
|
+
| `YdColorPicker` | 颜色选择 |
|
|
74
|
+
| `YdTreeSelect` | 树选择 |
|
|
75
|
+
| `YdSwitch` | 开关 |
|
|
76
|
+
| `YdCheckbox` | 复选框 |
|
|
77
|
+
| `YdCheckboxGroup` | 复选框组 |
|
|
78
|
+
| `YdRadio` | 单选框 |
|
|
79
|
+
| `YdRadioGroup` | 单选框组 |
|
|
80
|
+
| `YdTag` | 标签 |
|
|
81
|
+
| `YdAvatar` | 头像 |
|
|
82
|
+
| `YdBadge` | 徽章 |
|
|
83
|
+
| `YdRate` | 评分 |
|
|
84
|
+
| `YdSlider` | 滑块 |
|
|
85
|
+
| `YdDatePicker` | 日期选择 |
|
|
86
|
+
| `YdDateRangePicker` | 日期范围选择 |
|
|
87
|
+
| `YdTimePicker` | 时间选择 |
|
|
88
|
+
| `YdCascader` | 级联选择 |
|
|
89
|
+
| `YdAutoComplete` | 自动完成 |
|
|
90
|
+
| `YdTransfer` | 穿梭框 |
|
|
91
|
+
| `YdUpload` | 上传 |
|
|
92
|
+
| `YdLogin` | 登录框 |
|
|
93
|
+
| `YdLoginCentered` | 居中登录框 |
|
|
94
|
+
| `YdCaptcha` | 验证码 |
|
|
95
|
+
| `YdPinInput` | PIN 输入 |
|
|
96
|
+
| `YdCalendar` | 日历 |
|
|
97
|
+
|
|
98
|
+
### AI 组件 (AI Components)
|
|
99
|
+
|
|
100
|
+
| 组件 | 说明 |
|
|
101
|
+
| ----------------- | ---------------- |
|
|
102
|
+
| `YdChatBubble` | 聊天消息气泡 |
|
|
103
|
+
| `YdConversation` | 会话容器 |
|
|
104
|
+
| `YdPromptInput` | AI提示词输入框 |
|
|
105
|
+
| `YdReasoning` | AI推理过程展示 |
|
|
106
|
+
| `YdCodeBlock` | 代码块(带高亮) |
|
|
107
|
+
| `YdStreamingText` | 流式文本展示 |
|
|
108
|
+
| `YdAiLoader` | AI加载动画 |
|
|
109
|
+
| `YdSuggestion` | AI建议按钮 |
|
|
110
|
+
| `YdSources` | 引用来源展示 |
|
|
111
|
+
| `YdModelSelector` | AI模型选择器 |
|
|
112
|
+
| `YdChatPage` | AI聊天页面 |
|
|
113
|
+
|
|
114
|
+
### 表单组件 (Form)
|
|
115
|
+
|
|
116
|
+
| 组件 | 说明 |
|
|
117
|
+
| ------------ | -------- |
|
|
118
|
+
| `YdForm` | 表单容器 |
|
|
119
|
+
| `YdFormItem` | 表单项 |
|
|
120
|
+
|
|
121
|
+
### 布局组件 (Layout)
|
|
122
|
+
|
|
123
|
+
| 组件 | 说明 |
|
|
124
|
+
| ----------------- | ------------ |
|
|
125
|
+
| `YdLayout` | 后台管理布局 |
|
|
126
|
+
| `YdLayoutSidebar` | 侧边栏 |
|
|
127
|
+
| `YdLayoutHeader` | 顶部 header |
|
|
128
|
+
| `YdLayoutContent` | 内容区域 |
|
|
129
|
+
| `YdCrudPage` | 增删改查页面 |
|
|
130
|
+
| `YdSpace` | 间距 |
|
|
131
|
+
| `YdDivider` | 分割线 |
|
|
132
|
+
| `YdStepper` | 步骤条 |
|
|
133
|
+
|
|
134
|
+
### 数据存储 (Stores)
|
|
135
|
+
|
|
136
|
+
| 导出 | 说明 |
|
|
137
|
+
| --------------------- | ---------------------------- |
|
|
138
|
+
| `secureStoragePlugin` | Pinia 加密存储插件 (AES-GCM) |
|
|
139
|
+
| `initSecureStorage` | 初始化安全存储密钥 |
|
|
140
|
+
|
|
141
|
+
**使用示例**:
|
|
142
|
+
|
|
143
|
+
```typescript
|
|
144
|
+
import { createPinia } from "pinia";
|
|
145
|
+
import { secureStoragePlugin, initSecureStorage } from "yd-admin";
|
|
146
|
+
|
|
147
|
+
const pinia = createPinia();
|
|
148
|
+
pinia.use(secureStoragePlugin);
|
|
149
|
+
|
|
150
|
+
// 应用启动时初始化
|
|
151
|
+
await initSecureStorage();
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
### 数据展示 (Data Display)
|
|
155
|
+
|
|
156
|
+
| 组件 | 说明 |
|
|
157
|
+
| --------------------- | ------------------ |
|
|
158
|
+
| `YdCard` | 卡片 |
|
|
159
|
+
| `YdTable` | 表格(含虚拟滚动) |
|
|
160
|
+
| `YdProgress` | 进度条 |
|
|
161
|
+
| `YdStatistic` | 统计数值 |
|
|
162
|
+
| `YdCollapse` | 折叠面板 |
|
|
163
|
+
| `YdTimeline` | 时间线 |
|
|
164
|
+
| `YdTree` | 树形控件 |
|
|
165
|
+
| `YdList` | 列表 |
|
|
166
|
+
| `YdEmpty` | 空状态 |
|
|
167
|
+
| `YdImage` | 图片 |
|
|
168
|
+
| `YdImagePreviewGroup` | 图片预览组 |
|
|
169
|
+
| `YdFlowChart` | 流程图 |
|
|
170
|
+
| `YdWatermark` | 水印 |
|
|
171
|
+
|
|
172
|
+
### 导航组件 (Navigation)
|
|
173
|
+
|
|
174
|
+
| 组件 | 说明 |
|
|
175
|
+
| -------------- | -------- |
|
|
176
|
+
| `YdMenu` | 菜单 |
|
|
177
|
+
| `YdTabs` | 标签页 |
|
|
178
|
+
| `YdBreadcrumb` | 面包屑 |
|
|
179
|
+
| `YdPagination` | 分页 |
|
|
180
|
+
| `YdDropdown` | 下拉菜单 |
|
|
181
|
+
| `YdSteps` | 步骤条 |
|
|
182
|
+
| `YdStepper` | 步骤器 |
|
|
183
|
+
| `YdAnchor` | 锚点 |
|
|
184
|
+
|
|
185
|
+
### 反馈组件 (Feedback)
|
|
186
|
+
|
|
187
|
+
| 组件 | 说明 |
|
|
188
|
+
| --------------- | ---------- |
|
|
189
|
+
| `YdModal` | 对话框 |
|
|
190
|
+
| `YdDrawer` | 抽屉 |
|
|
191
|
+
| `Message` | 消息提示 |
|
|
192
|
+
| `Notification` | 通知提醒 |
|
|
193
|
+
| `YdTooltip` | 文字提示 |
|
|
194
|
+
| `YdSpin` | 加载中 |
|
|
195
|
+
| `YdSkeleton` | 骨架屏 |
|
|
196
|
+
| `YdPopconfirm` | 气泡确认框 |
|
|
197
|
+
| `YdResult` | 结果页 |
|
|
198
|
+
| `YdContextMenu` | 右键菜单 |
|
|
199
|
+
| `YdLoadingBar` | 加载进度条 |
|
|
200
|
+
|
|
201
|
+
### 配置组件 (Config)
|
|
202
|
+
|
|
203
|
+
| 组件 | 说明 |
|
|
204
|
+
| ------------------ | -------- |
|
|
205
|
+
| `YdConfigProvider` | 全局配置 |
|
|
206
|
+
|
|
207
|
+
### 路由 (Router)
|
|
208
|
+
|
|
209
|
+
| 导出 | 说明 |
|
|
210
|
+
| ----------------------- | ---------------- |
|
|
211
|
+
| `createAppRouter` | 创建路由实例 |
|
|
212
|
+
| `createAuthGuard` | 创建认证守卫 |
|
|
213
|
+
| `createPermissionGuard` | 创建权限守卫 |
|
|
214
|
+
| `YdRouter` | 路由命名空间导出 |
|
|
215
|
+
|
|
216
|
+
## 🎨 主题定制
|
|
217
|
+
|
|
218
|
+
组件库使用 CSS 变量构建,支持全局主题覆盖:
|
|
219
|
+
|
|
220
|
+
```css
|
|
221
|
+
:root {
|
|
222
|
+
--yd-color-primary: #1890ff;
|
|
223
|
+
--yd-border-radius: 4px;
|
|
224
|
+
/* 更多变量见 tokens.css */
|
|
225
|
+
}
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
或使用 `YdConfigProvider`:
|
|
229
|
+
|
|
230
|
+
```vue
|
|
231
|
+
<template>
|
|
232
|
+
<YdConfigProvider :theme="darkTheme">
|
|
233
|
+
<App />
|
|
234
|
+
</YdConfigProvider>
|
|
235
|
+
</template>
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
## 🛠️ 工具函数
|
|
239
|
+
|
|
240
|
+
```typescript
|
|
241
|
+
import { cn, debounce, throttle, generateId, deepClone } from "yd-admin";
|
|
242
|
+
|
|
243
|
+
// 合并 class
|
|
244
|
+
const classes = cn("base-class", condition && "conditional-class");
|
|
245
|
+
|
|
246
|
+
// 防抖
|
|
247
|
+
const debouncedFn = debounce(() => console.log("debounced"), 300);
|
|
248
|
+
|
|
249
|
+
// 节流
|
|
250
|
+
const throttledFn = throttle(() => console.log("throttled"), 100);
|
|
251
|
+
|
|
252
|
+
// 生成唯一 ID
|
|
253
|
+
const id = generateId("prefix");
|
|
254
|
+
|
|
255
|
+
// 深拷贝
|
|
256
|
+
const cloned = deepClone(obj);
|
|
257
|
+
```
|
|
258
|
+
|
|
259
|
+
## 📐 组件尺寸
|
|
260
|
+
|
|
261
|
+
所有组件支持统一尺寸配置:
|
|
262
|
+
|
|
263
|
+
| 尺寸 | 说明 |
|
|
264
|
+
| ---- | ---------- |
|
|
265
|
+
| `xs` | 超小 |
|
|
266
|
+
| `sm` | 小 |
|
|
267
|
+
| `md` | 中(默认) |
|
|
268
|
+
| `lg` | 大 |
|
|
269
|
+
| `xl` | 特大 |
|
|
270
|
+
|
|
271
|
+
## 🌐 开发
|
|
272
|
+
|
|
273
|
+
### 环境要求
|
|
274
|
+
|
|
275
|
+
- Node.js >= 18
|
|
276
|
+
- Vite+ (vp)
|
|
277
|
+
|
|
278
|
+
### 安装依赖
|
|
279
|
+
|
|
280
|
+
```bash
|
|
281
|
+
vp install
|
|
282
|
+
```
|
|
283
|
+
|
|
284
|
+
### 开发预览
|
|
285
|
+
|
|
286
|
+
```bash
|
|
287
|
+
# 启动 Demo
|
|
288
|
+
vp dev
|
|
289
|
+
|
|
290
|
+
# 监视模式构建
|
|
291
|
+
vp build --watch
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
### 代码检查
|
|
295
|
+
|
|
296
|
+
```bash
|
|
297
|
+
# 类型检查和格式化检查
|
|
298
|
+
vp check
|
|
299
|
+
|
|
300
|
+
# 格式化修复
|
|
301
|
+
vp fmt
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
### 构建发布
|
|
305
|
+
|
|
306
|
+
```bash
|
|
307
|
+
vp build
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
### 运行测试
|
|
311
|
+
|
|
312
|
+
```bash
|
|
313
|
+
vp test
|
|
314
|
+
```
|
|
315
|
+
|
|
316
|
+
## ✅ 代码质量状态
|
|
317
|
+
|
|
318
|
+
项目已通过以下检查:
|
|
319
|
+
|
|
320
|
+
- ✅ TypeScript 类型检查
|
|
321
|
+
- ✅ ESLint 代码检查
|
|
322
|
+
- ✅ 格式化检查
|
|
323
|
+
- ✅ 100 个单元测试全部通过
|
|
324
|
+
|
|
325
|
+
## 📊 Bundle 信息
|
|
326
|
+
|
|
327
|
+
| 文件 | 大小 | Gzip |
|
|
328
|
+
| -------------- | ----------- | ----------- |
|
|
329
|
+
| dist/index.js | ~472 KB | ~89 KB |
|
|
330
|
+
| dist/style.css | ~182 KB | ~23 KB |
|
|
331
|
+
| **总计** | **~800 KB** | **~136 KB** |
|
|
332
|
+
|
|
333
|
+
## 📋 更新日志
|
|
334
|
+
|
|
335
|
+
### v0.1.8
|
|
336
|
+
|
|
337
|
+
- **feat(secureStorage)**: 支持 localStorage 和 sessionStorage 分别设置不同密钥
|
|
338
|
+
- **fix**: 修复报错问题
|
|
339
|
+
- **enhancement**: 优化说明文档
|
|
340
|
+
- **feat**: 登录控件优化,增强用户体验
|
|
341
|
+
- **feat**: 增加侧边栏控件,支持更灵活的布局配置
|
|
342
|
+
- **feat**: 增加懒加载和优化轮询机制,提升性能
|
|
343
|
+
- **enhancement**: 优化整体介绍和文档
|
|
344
|
+
- **feat**: 增加整体效果展示组件
|
|
345
|
+
- **feat**: 虚拟滚动等性能优化
|
|
346
|
+
- **enhancement**: 暂存优化,改进数据缓存
|
|
347
|
+
|
|
348
|
+
### v0.1.7
|
|
349
|
+
|
|
350
|
+
- **feat**: 安全存储插件 (AES-GCM) 支持敏感数据加密存储
|
|
351
|
+
|
|
352
|
+
### v0.1.6
|
|
353
|
+
|
|
354
|
+
- **feat**: 多语言支持 (i18n)
|
|
355
|
+
|
|
356
|
+
### v0.1.5
|
|
357
|
+
|
|
358
|
+
- **feat**: 虚拟滚动表格组件
|
|
359
|
+
|
|
360
|
+
### v0.1.4
|
|
361
|
+
|
|
362
|
+
- **feat**: 初始版本发布
|
|
363
|
+
|
|
364
|
+
## 🔗 相关链接
|
|
365
|
+
|
|
366
|
+
- [Vue 3 文档](https://vuejs.org/)
|
|
367
|
+
- [Vite+ 文档](https://vite-plus._voidzero.dev/)
|
|
368
|
+
- [AsyncValidator](https://github.com/yiminghe/async-validator)
|
|
369
|
+
|
|
370
|
+
## 📄 License
|
|
371
|
+
|
|
372
|
+
MIT
|