zartui 3.0.1 → 3.0.2

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/es/index.d.ts CHANGED
@@ -32,4 +32,4 @@ declare namespace _default {
32
32
  }
33
33
  export default _default;
34
34
  export function install(app: any): void;
35
- export const version: "3.0.1";
35
+ export const version: "3.0.2";
package/es/index.mjs CHANGED
@@ -26,7 +26,7 @@ import { Switch } from "./switch/index.mjs";
26
26
  import { Tab } from "./tab/index.mjs";
27
27
  import { Tabs } from "./tabs/index.mjs";
28
28
  import { Toast } from "./toast/index.mjs";
29
- const version = "3.0.1";
29
+ const version = "3.0.2";
30
30
  function install(app) {
31
31
  const components = [
32
32
  Badge,
@@ -1,6 +1,6 @@
1
1
  import { withDirectives as _withDirectives, mergeProps as _mergeProps, vShow as _vShow, createVNode as _createVNode } from "vue";
2
2
  import { ref, watch, computed, nextTick, defineComponent } from "vue";
3
- import { isDef, addUnit, addNumber, truthProp, resetScroll, numericProp, formatNumber, getSizeStyle, preventDefault, createNamespace, callInterceptor, makeNumericProp } from "../utils";
3
+ import { isDef, addUnit, addNumber, truthProp, resetScroll, numericProp, formatNumber, getSizeStyle, preventDefault, createNamespace, callInterceptor, makeNumericProp } from "../utils/index.mjs";
4
4
  import { useCustomFieldValue } from "@zartui/use";
5
5
  import ZtIcon from "../icon/index.mjs";
6
6
  const [name, bem] = createNamespace("stepper");
package/lib/index.d.ts CHANGED
@@ -32,4 +32,4 @@ declare namespace _default {
32
32
  }
33
33
  export default _default;
34
34
  export function install(app: any): void;
35
- export const version: "3.0.1";
35
+ export const version: "3.0.2";
package/lib/index.js CHANGED
@@ -79,7 +79,7 @@ __reExport(stdin_exports, require("./switch"), module.exports);
79
79
  __reExport(stdin_exports, require("./tab"), module.exports);
80
80
  __reExport(stdin_exports, require("./tabs"), module.exports);
81
81
  __reExport(stdin_exports, require("./toast"), module.exports);
82
- const version = "3.0.1";
82
+ const version = "3.0.2";
83
83
  function install(app) {
84
84
  const components = [
85
85
  import_badge.Badge,
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "framework": "vue",
4
4
  "name": "zartui",
5
- "version": "3.0.1",
5
+ "version": "3.0.2",
6
6
  "contributions": {
7
7
  "html": {
8
8
  "tags": [
@@ -93,68 +93,70 @@
93
93
  ]
94
94
  },
95
95
  {
96
- "name": "button",
96
+ "name": "cell",
97
97
  "slots": [
98
98
  {
99
- "name": "default",
100
- "description": "按钮内容"
99
+ "name": "title",
100
+ "description": "自定义左侧标题"
101
+ },
102
+ {
103
+ "name": "value",
104
+ "description": "自定义右侧内容"
105
+ },
106
+ {
107
+ "name": "label",
108
+ "description": "自定义标题下方的描述信息"
101
109
  },
102
110
  {
103
111
  "name": "icon",
104
- "description": "自定义图标"
112
+ "description": "自定义左侧图标"
105
113
  },
106
114
  {
107
- "name": "loading",
108
- "description": "自定义加载图标"
115
+ "name": "right-icon",
116
+ "description": "自定义右侧图标"
117
+ },
118
+ {
119
+ "name": "extra",
120
+ "description": "自定义单元格最右侧的额外内容"
109
121
  }
110
122
  ],
111
123
  "events": [
112
124
  {
113
125
  "name": "click",
114
- "description": "点击按钮,且按钮状态不为加载或禁用时触发",
126
+ "description": "点击单元格时触发",
115
127
  "arguments": [
116
128
  {
117
129
  "name": "event",
118
130
  "type": "MouseEvent"
119
131
  }
120
132
  ]
121
- },
122
- {
123
- "name": "touchstart",
124
- "description": "开始触摸按钮时触发",
125
- "arguments": [
126
- {
127
- "name": "event",
128
- "type": "TouchEvent"
129
- }
130
- ]
131
133
  }
132
134
  ],
133
135
  "attributes": [
134
136
  {
135
- "name": "type",
136
- "default": "`default`",
137
- "description": "类型,可选值为 `primary` `success` `warning` `danger`",
137
+ "name": "title",
138
+ "default": "-",
139
+ "description": "左侧标题",
138
140
  "options": [],
139
141
  "value": {
140
- "type": "string",
142
+ "type": "number | string",
141
143
  "kind": "expression"
142
144
  }
143
145
  },
144
146
  {
145
- "name": "size",
146
- "default": "`normal`",
147
- "description": "尺寸,可选值为 `normal` `medium` `small` `mini`",
147
+ "name": "value",
148
+ "default": "-",
149
+ "description": "右侧内容",
148
150
  "options": [],
149
151
  "value": {
150
- "type": "string",
152
+ "type": "number | string",
151
153
  "kind": "expression"
152
154
  }
153
155
  },
154
156
  {
155
- "name": "text",
157
+ "name": "label",
156
158
  "default": "-",
157
- "description": "按钮文字",
159
+ "description": "标题下方的描述信息",
158
160
  "options": [],
159
161
  "value": {
160
162
  "type": "string",
@@ -162,9 +164,9 @@
162
164
  }
163
165
  },
164
166
  {
165
- "name": "color",
167
+ "name": "size",
166
168
  "default": "-",
167
- "description": "按钮文字颜色",
169
+ "description": "单元格大小,可选值为 `large`",
168
170
  "options": [],
169
171
  "value": {
170
172
  "type": "string",
@@ -172,9 +174,9 @@
172
174
  }
173
175
  },
174
176
  {
175
- "name": "background-color",
176
- "default": "-",
177
- "description": "按钮背景颜色",
177
+ "name": "direction",
178
+ "default": "column",
179
+ "description": "标题与内容的排列方向,默认为竖直排列,可选值为 `row`或 `column`",
178
180
  "options": [],
179
181
  "value": {
180
182
  "type": "string",
@@ -202,9 +204,29 @@
202
204
  }
203
205
  },
204
206
  {
205
- "name": "block",
206
- "default": "`false`",
207
- "description": "是否为块级元素",
207
+ "name": "url",
208
+ "default": "-",
209
+ "description": "点击后跳转的链接地址",
210
+ "options": [],
211
+ "value": {
212
+ "type": "string",
213
+ "kind": "expression"
214
+ }
215
+ },
216
+ {
217
+ "name": "to",
218
+ "default": "-",
219
+ "description": "点击后跳转的目标路由对象,等同于 vue-router 的 [to 属性](https://router.vuejs.org/zh/api/#to)",
220
+ "options": [],
221
+ "value": {
222
+ "type": "string | object",
223
+ "kind": "expression"
224
+ }
225
+ },
226
+ {
227
+ "name": "border",
228
+ "default": "`true`",
229
+ "description": "是否显示内边框",
208
230
  "options": [],
209
231
  "value": {
210
232
  "type": "boolean",
@@ -212,9 +234,9 @@
212
234
  }
213
235
  },
214
236
  {
215
- "name": "plain",
237
+ "name": "replace",
216
238
  "default": "`false`",
217
- "description": "是否为朴素按钮",
239
+ "description": "是否在跳转时替换当前页面历史",
218
240
  "options": [],
219
241
  "value": {
220
242
  "type": "boolean",
@@ -222,9 +244,19 @@
222
244
  }
223
245
  },
224
246
  {
225
- "name": "square",
247
+ "name": "clickable",
248
+ "default": "`null`",
249
+ "description": "是否开启点击反馈",
250
+ "options": [],
251
+ "value": {
252
+ "type": "boolean",
253
+ "kind": "expression"
254
+ }
255
+ },
256
+ {
257
+ "name": "is-link",
226
258
  "default": "`false`",
227
- "description": "是否为方形按钮",
259
+ "description": "是否展示右侧箭头并开启点击反馈",
228
260
  "options": [],
229
261
  "value": {
230
262
  "type": "boolean",
@@ -232,9 +264,9 @@
232
264
  }
233
265
  },
234
266
  {
235
- "name": "round",
267
+ "name": "required",
236
268
  "default": "`false`",
237
- "description": "是否为圆形按钮,只支持显示 Icon",
269
+ "description": "是否显示表单必填星号",
238
270
  "options": [],
239
271
  "value": {
240
272
  "type": "boolean",
@@ -242,129 +274,130 @@
242
274
  }
243
275
  },
244
276
  {
245
- "name": "disabled",
277
+ "name": "center",
246
278
  "default": "`false`",
247
- "description": "是否禁用按钮",
279
+ "description": "是否使内容垂直居中",
248
280
  "options": [],
249
281
  "value": {
250
282
  "type": "boolean",
251
283
  "kind": "expression"
252
284
  }
253
- }
254
- ]
255
- },
256
- {
257
- "name": "config-provider",
258
- "slots": [],
259
- "events": [],
260
- "attributes": [
285
+ },
261
286
  {
262
- "name": "theme",
263
- "default": "`light`",
264
- "description": "主题风格,设置为 `dark` 来开启深色模式,全局生效",
287
+ "name": "arrow-direction",
288
+ "default": "`right`",
289
+ "description": "箭头方向,可选值为 `left` `up` `down`",
265
290
  "options": [],
266
291
  "value": {
267
- "type": "ConfigProviderTheme",
292
+ "type": "string",
268
293
  "kind": "expression"
269
294
  }
270
295
  },
271
296
  {
272
- "name": "theme-vars",
297
+ "name": "title-style",
273
298
  "default": "-",
274
- "description": "自定义主题变量,局部生效",
299
+ "description": "左侧标题额外样式",
275
300
  "options": [],
276
301
  "value": {
277
- "type": "object",
302
+ "type": "string | Array | object",
278
303
  "kind": "expression"
279
304
  }
280
305
  },
281
306
  {
282
- "name": "tag",
283
- "default": "`div`",
284
- "description": "根节点对应的 HTML 标签名",
307
+ "name": "title-class",
308
+ "default": "-",
309
+ "description": "左侧标题额外类名",
285
310
  "options": [],
286
311
  "value": {
287
- "type": "string",
312
+ "type": "string | Array | object",
288
313
  "kind": "expression"
289
314
  }
290
315
  },
291
316
  {
292
- "name": "icon-prefix",
293
- "default": "`zt-icon`",
294
- "description": "所有图标的类名前缀,等同于 Icon 组件的 [class-prefix 属性](#/zh-CN/icon#props)",
317
+ "name": "value-class",
318
+ "default": "-",
319
+ "description": "右侧内容额外类名",
295
320
  "options": [],
296
321
  "value": {
297
- "type": "string",
322
+ "type": "string | Array | object",
323
+ "kind": "expression"
324
+ }
325
+ },
326
+ {
327
+ "name": "label-class",
328
+ "default": "-",
329
+ "description": "描述信息额外类名",
330
+ "options": [],
331
+ "value": {
332
+ "type": "string | Array | object",
298
333
  "kind": "expression"
299
334
  }
300
335
  }
301
336
  ]
302
337
  },
303
338
  {
304
- "name": "cell",
339
+ "name": "button",
305
340
  "slots": [
306
341
  {
307
- "name": "title",
308
- "description": "自定义左侧标题"
309
- },
310
- {
311
- "name": "value",
312
- "description": "自定义右侧内容"
313
- },
314
- {
315
- "name": "label",
316
- "description": "自定义标题下方的描述信息"
342
+ "name": "default",
343
+ "description": "按钮内容"
317
344
  },
318
345
  {
319
346
  "name": "icon",
320
- "description": "自定义左侧图标"
321
- },
322
- {
323
- "name": "right-icon",
324
- "description": "自定义右侧图标"
347
+ "description": "自定义图标"
325
348
  },
326
349
  {
327
- "name": "extra",
328
- "description": "自定义单元格最右侧的额外内容"
350
+ "name": "loading",
351
+ "description": "自定义加载图标"
329
352
  }
330
353
  ],
331
354
  "events": [
332
355
  {
333
356
  "name": "click",
334
- "description": "点击单元格时触发",
357
+ "description": "点击按钮,且按钮状态不为加载或禁用时触发",
335
358
  "arguments": [
336
359
  {
337
360
  "name": "event",
338
361
  "type": "MouseEvent"
339
362
  }
340
363
  ]
364
+ },
365
+ {
366
+ "name": "touchstart",
367
+ "description": "开始触摸按钮时触发",
368
+ "arguments": [
369
+ {
370
+ "name": "event",
371
+ "type": "TouchEvent"
372
+ }
373
+ ]
341
374
  }
342
375
  ],
343
376
  "attributes": [
344
377
  {
345
- "name": "title",
346
- "default": "-",
347
- "description": "左侧标题",
378
+ "name": "type",
379
+ "default": "`default`",
380
+ "description": "类型,可选值为 `primary` `success` `warning` `danger`",
348
381
  "options": [],
349
382
  "value": {
350
- "type": "number | string",
383
+ "type": "string",
351
384
  "kind": "expression"
352
385
  }
353
386
  },
354
387
  {
355
- "name": "value",
356
- "default": "-",
357
- "description": "右侧内容",
388
+ "name": "size",
389
+ "default": "`normal`",
390
+ "description": "尺寸,可选值为 `normal` `medium` `small` `mini`",
358
391
  "options": [],
359
392
  "value": {
360
- "type": "number | string",
393
+ "type": "string",
361
394
  "kind": "expression"
362
395
  }
363
396
  },
364
397
  {
365
- "name": "label",
398
+ "name": "text",
366
399
  "default": "-",
367
- "description": "标题下方的描述信息",
400
+ "description": "按钮文字",
368
401
  "options": [],
369
402
  "value": {
370
403
  "type": "string",
@@ -372,9 +405,9 @@
372
405
  }
373
406
  },
374
407
  {
375
- "name": "size",
408
+ "name": "color",
376
409
  "default": "-",
377
- "description": "单元格大小,可选值为 `large`",
410
+ "description": "按钮文字颜色",
378
411
  "options": [],
379
412
  "value": {
380
413
  "type": "string",
@@ -382,9 +415,9 @@
382
415
  }
383
416
  },
384
417
  {
385
- "name": "direction",
386
- "default": "column",
387
- "description": "标题与内容的排列方向,默认为竖直排列,可选值为 `row`或 `column`",
418
+ "name": "background-color",
419
+ "default": "-",
420
+ "description": "按钮背景颜色",
388
421
  "options": [],
389
422
  "value": {
390
423
  "type": "string",
@@ -412,39 +445,9 @@
412
445
  }
413
446
  },
414
447
  {
415
- "name": "url",
416
- "default": "-",
417
- "description": "点击后跳转的链接地址",
418
- "options": [],
419
- "value": {
420
- "type": "string",
421
- "kind": "expression"
422
- }
423
- },
424
- {
425
- "name": "to",
426
- "default": "-",
427
- "description": "点击后跳转的目标路由对象,等同于 vue-router 的 [to 属性](https://router.vuejs.org/zh/api/#to)",
428
- "options": [],
429
- "value": {
430
- "type": "string | object",
431
- "kind": "expression"
432
- }
433
- },
434
- {
435
- "name": "border",
436
- "default": "`true`",
437
- "description": "是否显示内边框",
438
- "options": [],
439
- "value": {
440
- "type": "boolean",
441
- "kind": "expression"
442
- }
443
- },
444
- {
445
- "name": "replace",
448
+ "name": "block",
446
449
  "default": "`false`",
447
- "description": "是否在跳转时替换当前页面历史",
450
+ "description": "是否为块级元素",
448
451
  "options": [],
449
452
  "value": {
450
453
  "type": "boolean",
@@ -452,9 +455,9 @@
452
455
  }
453
456
  },
454
457
  {
455
- "name": "clickable",
456
- "default": "`null`",
457
- "description": "是否开启点击反馈",
458
+ "name": "plain",
459
+ "default": "`false`",
460
+ "description": "是否为朴素按钮",
458
461
  "options": [],
459
462
  "value": {
460
463
  "type": "boolean",
@@ -462,9 +465,9 @@
462
465
  }
463
466
  },
464
467
  {
465
- "name": "is-link",
468
+ "name": "square",
466
469
  "default": "`false`",
467
- "description": "是否展示右侧箭头并开启点击反馈",
470
+ "description": "是否为方形按钮",
468
471
  "options": [],
469
472
  "value": {
470
473
  "type": "boolean",
@@ -472,9 +475,9 @@
472
475
  }
473
476
  },
474
477
  {
475
- "name": "required",
478
+ "name": "round",
476
479
  "default": "`false`",
477
- "description": "是否显示表单必填星号",
480
+ "description": "是否为圆形按钮,只支持显示 Icon",
478
481
  "options": [],
479
482
  "value": {
480
483
  "type": "boolean",
@@ -482,64 +485,14 @@
482
485
  }
483
486
  },
484
487
  {
485
- "name": "center",
488
+ "name": "disabled",
486
489
  "default": "`false`",
487
- "description": "是否使内容垂直居中",
490
+ "description": "是否禁用按钮",
488
491
  "options": [],
489
492
  "value": {
490
493
  "type": "boolean",
491
494
  "kind": "expression"
492
495
  }
493
- },
494
- {
495
- "name": "arrow-direction",
496
- "default": "`right`",
497
- "description": "箭头方向,可选值为 `left` `up` `down`",
498
- "options": [],
499
- "value": {
500
- "type": "string",
501
- "kind": "expression"
502
- }
503
- },
504
- {
505
- "name": "title-style",
506
- "default": "-",
507
- "description": "左侧标题额外样式",
508
- "options": [],
509
- "value": {
510
- "type": "string | Array | object",
511
- "kind": "expression"
512
- }
513
- },
514
- {
515
- "name": "title-class",
516
- "default": "-",
517
- "description": "左侧标题额外类名",
518
- "options": [],
519
- "value": {
520
- "type": "string | Array | object",
521
- "kind": "expression"
522
- }
523
- },
524
- {
525
- "name": "value-class",
526
- "default": "-",
527
- "description": "右侧内容额外类名",
528
- "options": [],
529
- "value": {
530
- "type": "string | Array | object",
531
- "kind": "expression"
532
- }
533
- },
534
- {
535
- "name": "label-class",
536
- "default": "-",
537
- "description": "描述信息额外类名",
538
- "options": [],
539
- "value": {
540
- "type": "string | Array | object",
541
- "kind": "expression"
542
- }
543
496
  }
544
497
  ]
545
498
  },
@@ -659,6 +612,53 @@
659
612
  }
660
613
  ]
661
614
  },
615
+ {
616
+ "name": "config-provider",
617
+ "slots": [],
618
+ "events": [],
619
+ "attributes": [
620
+ {
621
+ "name": "theme",
622
+ "default": "`light`",
623
+ "description": "主题风格,设置为 `dark` 来开启深色模式,全局生效",
624
+ "options": [],
625
+ "value": {
626
+ "type": "ConfigProviderTheme",
627
+ "kind": "expression"
628
+ }
629
+ },
630
+ {
631
+ "name": "theme-vars",
632
+ "default": "-",
633
+ "description": "自定义主题变量,局部生效",
634
+ "options": [],
635
+ "value": {
636
+ "type": "object",
637
+ "kind": "expression"
638
+ }
639
+ },
640
+ {
641
+ "name": "tag",
642
+ "default": "`div`",
643
+ "description": "根节点对应的 HTML 标签名",
644
+ "options": [],
645
+ "value": {
646
+ "type": "string",
647
+ "kind": "expression"
648
+ }
649
+ },
650
+ {
651
+ "name": "icon-prefix",
652
+ "default": "`zt-icon`",
653
+ "description": "所有图标的类名前缀,等同于 Icon 组件的 [class-prefix 属性](#/zh-CN/icon#props)",
654
+ "options": [],
655
+ "value": {
656
+ "type": "string",
657
+ "kind": "expression"
658
+ }
659
+ }
660
+ ]
661
+ },
662
662
  {
663
663
  "name": "divider",
664
664
  "slots": [
package/lib/zartui.cjs.js CHANGED
@@ -6651,7 +6651,7 @@ var stdin_default$1 = vue.defineComponent({
6651
6651
  });
6652
6652
  const Tab = withInstall(stdin_default$1);
6653
6653
  const Tabs = withInstall(stdin_default$2);
6654
- const version = "3.0.1";
6654
+ const version = "3.0.2";
6655
6655
  function install(app) {
6656
6656
  const components = [
6657
6657
  Badge,