From 44c0db5774bb55b76ce28b13ddd7e44cc3938e52 Mon Sep 17 00:00:00 2001 From: chaishi <974383157@qq.com> Date: Mon, 25 Sep 2023 16:57:04 +0800 Subject: [PATCH 1/4] feat(tag): support check-tag-group --- src/_common | 2 +- .../__snapshots__/index.test.jsx.snap | 309 +- src/table/enhanced-table.tsx | 2 +- .../__snapshots__/index.test.jsx.snap | 141 +- src/tag/_example/base.vue | 5 +- src/tag/_example/check-tag-group.vue | 91 + src/tag/_example/delete.vue | 2 +- src/tag/_example/icon.vue | 4 +- src/tag/_example/selectable.vue | 85 +- src/tag/check-tag-group-props.ts | 37 + src/tag/check-tag-group.tsx | 82 + src/tag/check-tag-props.ts | 17 +- src/tag/check-tag.tsx | 122 +- src/tag/index.ts | 9 +- src/tag/tag.en-US.md | 35 +- src/tag/tag.md | 43 +- src/tag/tag.tsx | 4 +- src/tag/type.ts | 66 +- .../__snapshots__/index.test.jsx.snap | 12 +- test/snap/__snapshots__/csr.test.js.snap | 2767 +++++++++++------ test/snap/__snapshots__/ssr.test.js.snap | 178 +- 21 files changed, 2601 insertions(+), 1412 deletions(-) create mode 100644 src/tag/_example/check-tag-group.vue create mode 100644 src/tag/check-tag-group-props.ts create mode 100644 src/tag/check-tag-group.tsx diff --git a/src/_common b/src/_common index a78db5d83..057249bdd 160000 --- a/src/_common +++ b/src/_common @@ -1 +1 @@ -Subproject commit a78db5d8382c3c96cacedc2a9cb669584d0d3d9d +Subproject commit 057249bdd09cebf59f1590f88ff0580870c2e10d diff --git a/src/calendar/__tests__/__snapshots__/index.test.jsx.snap b/src/calendar/__tests__/__snapshots__/index.test.jsx.snap index 5c1ffd02d..5df843360 100644 --- a/src/calendar/__tests__/__snapshots__/index.test.jsx.snap +++ b/src/calendar/__tests__/__snapshots__/index.test.jsx.snap @@ -180,11 +180,14 @@ exports[`Calendar > :props > :cell 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :cell 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :cellAppend 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :cellAppend 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :controllerConfig 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :fillWithZero 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :fillWithZero 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :firstDayOfWeek 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :format 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :head 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :head 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :isShowWeekendDefault 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :isShowWeekendDefault 1`] = `
- - 显示周末 - + + 显示周末 + +
:props > :mode 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :multiple 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :preventCellContextmenu 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :preventCellContextmenu 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :range 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :theme 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :value 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :week 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :week 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :year:month 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:props > :year:month 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
> 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
> 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
> 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
> 1`] = `
- - 隐藏周末 - + + 隐藏周末 + +
:Tag:props > :checked 1`] = ` - - +
`; exports[`Tag or CheckTag > :Tag:props > :closable 1`] = ` - @@ -26,58 +26,58 @@ exports[`Tag or CheckTag > :Tag:props > :closable 1`] = ` fill="currentColor" /> - + `; exports[`Tag or CheckTag > :Tag:props > :disabled 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :maxWidth 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :shape:mark 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :shape:round 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :shape:square 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :size:large 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :size:medium 1`] = ``; @@ -85,175 +85,175 @@ exports[`Tag or CheckTag > :Tag:props > :size:medium 1`] = ``; exports[`Tag or CheckTag > :Tag:props > :size:small 1`] = ``; exports[`Tag or CheckTag > :Tag:props > :theme: 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :theme:danger 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :theme:default 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :theme:primary 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :theme:success 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :theme:warning 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:dark;theme:danger 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:dark;theme:default 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:dark;theme:primary 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:dark;theme:success 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:dark;theme:warning 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:danger 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:danger 2`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:default 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:default 2`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:primary 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:primary 2`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:success 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:success 2`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:warning 1`] = ` - - + `; exports[`Tag or CheckTag > :Tag:props > :variant:light;theme:warning 2`] = ` - - + `; exports[`Tag or CheckTag > @event: Tag > Event passthrough: close 1`] = ` - @@ -269,26 +269,31 @@ exports[`Tag or CheckTag > @event: Tag > Event passthrough: close 1`] = ` fill="currentColor" /> - + `; exports[`Tag or CheckTag > CheckTag:props > :checked 1`] = ` - +
+ +
`; exports[`Tag or CheckTag > CheckTag:props > :disabled 1`] = ` - +
+ +
`; exports[`Tag or CheckTag > Tag:slot > 1`] = ` -
- +
`; diff --git a/src/tag/_example/base.vue b/src/tag/_example/base.vue index 705c049d3..2c0ec00a2 100644 --- a/src/tag/_example/base.vue +++ b/src/tag/_example/base.vue @@ -1,30 +1,33 @@