vxe-pc-ui 3.0.0 → 3.0.1
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/button/src/button.js +3 -0
- package/es/carousel/index.js +12 -0
- package/es/carousel/src/carousel-item.js +100 -0
- package/es/carousel/src/carousel.js +418 -0
- package/es/carousel/src/util.js +17 -0
- package/es/carousel/style.css +185 -0
- package/es/carousel/style.min.css +1 -0
- package/es/carousel-item/index.js +12 -0
- package/es/carousel-item/style.css +0 -0
- package/es/carousel-item/style.min.css +0 -0
- package/es/checkbox/index.js +12 -0
- package/es/checkbox/src/checkbox.js +159 -0
- package/es/checkbox/src/group.js +154 -0
- package/es/checkbox/style.css +117 -0
- package/es/checkbox/style.min.css +1 -0
- package/es/checkbox-group/index.js +12 -0
- package/es/checkbox-group/style.css +0 -0
- package/es/checkbox-group/style.min.css +0 -0
- package/es/components.js +39 -39
- package/es/date-picker/src/date-picker.js +3 -0
- package/es/icon/style.css +1 -1
- package/es/icon-picker/index.js +12 -0
- package/es/icon-picker/src/icon-picker.js +668 -0
- package/es/icon-picker/style.css +207 -0
- package/es/icon-picker/style.min.css +1 -0
- package/es/input/index.js +12 -0
- package/es/input/src/input.js +2892 -0
- package/es/input/style.css +941 -0
- package/es/input/style.min.css +1 -0
- package/es/layout-footer/src/layout-footer.js +2 -1
- package/es/layout-header/src/layout-header.js +2 -1
- package/es/optgroup/index.js +12 -0
- package/es/optgroup/style.css +0 -0
- package/es/optgroup/style.min.css +0 -0
- package/es/option/index.js +12 -0
- package/es/option/style.css +0 -0
- package/es/option/style.min.css +0 -0
- package/es/pager/index.js +12 -0
- package/es/pager/src/pager.js +687 -0
- package/es/password-input/index.js +12 -0
- package/es/password-input/src/password-input.js +388 -0
- package/es/password-input/style.css +604 -0
- package/es/password-input/style.min.css +1 -0
- package/es/pulldown/src/pulldown.js +5 -1
- package/es/select/index.js +12 -0
- package/es/select/src/optgroup.js +90 -0
- package/es/select/src/option-info.js +16 -0
- package/es/select/src/option.js +86 -0
- package/es/select/src/select.js +1269 -0
- package/es/select/src/util.js +35 -0
- package/es/select/style.css +207 -0
- package/es/select/style.min.css +1 -0
- package/es/style.css +1 -1
- package/es/style.min.css +1 -1
- package/es/tab-pane/index.js +12 -0
- package/es/tab-pane/style.css +0 -0
- package/es/tab-pane/style.min.css +0 -0
- package/es/tabs/index.js +12 -0
- package/es/tabs/src/tab-pane.js +119 -0
- package/es/tabs/src/tabs.js +593 -0
- package/es/tabs/src/util.js +17 -0
- package/es/tabs/style.css +342 -0
- package/es/tabs/style.min.css +1 -0
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/es/vxe-carousel/index.js +3 -0
- package/es/vxe-carousel/style.css +185 -0
- package/es/vxe-carousel/style.min.css +1 -0
- package/es/vxe-carousel-item/index.js +3 -0
- package/es/vxe-carousel-item/style.css +0 -0
- package/es/vxe-carousel-item/style.min.css +0 -0
- package/es/vxe-checkbox/index.js +3 -0
- package/es/vxe-checkbox/style.css +117 -0
- package/es/vxe-checkbox/style.min.css +1 -0
- package/es/vxe-checkbox-group/index.js +3 -0
- package/es/vxe-checkbox-group/style.css +0 -0
- package/es/vxe-checkbox-group/style.min.css +0 -0
- package/es/vxe-icon-picker/index.js +3 -0
- package/es/vxe-icon-picker/style.css +207 -0
- package/es/vxe-icon-picker/style.min.css +1 -0
- package/es/vxe-input/index.js +3 -0
- package/es/vxe-input/style.css +941 -0
- package/es/vxe-input/style.min.css +1 -0
- package/es/vxe-optgroup/index.js +3 -0
- package/es/vxe-optgroup/style.css +0 -0
- package/es/vxe-optgroup/style.min.css +0 -0
- package/es/vxe-option/index.js +3 -0
- package/es/vxe-option/style.css +0 -0
- package/es/vxe-option/style.min.css +0 -0
- package/es/vxe-password-input/index.js +3 -0
- package/es/vxe-password-input/style.css +604 -0
- package/es/vxe-password-input/style.min.css +1 -0
- package/es/vxe-select/index.js +3 -0
- package/es/vxe-select/style.css +207 -0
- package/es/vxe-select/style.min.css +1 -0
- package/es/vxe-tab-pane/index.js +3 -0
- package/es/vxe-tab-pane/style.css +0 -0
- package/es/vxe-tab-pane/style.min.css +0 -0
- package/es/vxe-tabs/index.js +3 -0
- package/es/vxe-tabs/style.css +342 -0
- package/es/vxe-tabs/style.min.css +1 -0
- package/lib/button/src/button.js +3 -0
- package/lib/button/src/button.min.js +1 -1
- package/lib/carousel/index.js +19 -0
- package/lib/carousel/index.min.js +1 -0
- package/lib/carousel/src/carousel-item.js +107 -0
- package/lib/carousel/src/carousel-item.min.js +1 -0
- package/lib/carousel/src/carousel.js +437 -0
- package/lib/carousel/src/carousel.min.js +1 -0
- package/lib/carousel/src/util.js +27 -0
- package/lib/carousel/src/util.min.js +1 -0
- package/lib/carousel/style/index.js +1 -0
- package/lib/carousel/style/style.css +185 -0
- package/lib/carousel/style/style.min.css +1 -0
- package/lib/carousel-item/index.js +19 -0
- package/lib/carousel-item/index.min.js +1 -0
- package/lib/carousel-item/style/index.js +1 -0
- package/lib/carousel-item/style/style.css +0 -0
- package/lib/carousel-item/style/style.min.css +0 -0
- package/lib/checkbox/index.js +19 -0
- package/lib/checkbox/index.min.js +1 -0
- package/lib/checkbox/src/checkbox.js +169 -0
- package/lib/checkbox/src/checkbox.min.js +1 -0
- package/lib/checkbox/src/group.js +164 -0
- package/lib/checkbox/src/group.min.js +1 -0
- package/lib/checkbox/style/index.js +1 -0
- package/lib/checkbox/style/style.css +117 -0
- package/lib/checkbox/style/style.min.css +1 -0
- package/lib/checkbox-group/index.js +19 -0
- package/lib/checkbox-group/index.min.js +1 -0
- package/lib/checkbox-group/style/index.js +1 -0
- package/lib/checkbox-group/style/style.css +0 -0
- package/lib/checkbox-group/style/style.min.css +0 -0
- package/lib/components.js +159 -60
- package/lib/components.min.js +1 -1
- package/lib/date-picker/src/date-picker.js +3 -0
- package/lib/date-picker/src/date-picker.min.js +1 -1
- package/lib/icon/style/style.css +1 -1
- package/lib/icon/style/style.min.css +1 -1
- package/lib/icon-picker/index.js +19 -0
- package/lib/icon-picker/index.min.js +1 -0
- package/lib/icon-picker/src/icon-picker.js +646 -0
- package/lib/icon-picker/src/icon-picker.min.js +1 -0
- package/lib/icon-picker/style/index.js +1 -0
- package/lib/icon-picker/style/style.css +207 -0
- package/lib/icon-picker/style/style.min.css +1 -0
- package/lib/index.umd.js +15870 -7738
- package/lib/index.umd.min.js +1 -1
- package/lib/input/index.js +19 -0
- package/lib/input/index.min.js +1 -0
- package/lib/input/src/input.js +2897 -0
- package/lib/input/src/input.min.js +1 -0
- package/lib/input/style/index.js +1 -0
- package/lib/input/style/style.css +941 -0
- package/lib/input/style/style.min.css +1 -0
- package/lib/layout-footer/src/layout-footer.js +2 -1
- package/lib/layout-header/src/layout-header.js +2 -1
- package/lib/optgroup/index.js +19 -0
- package/lib/optgroup/index.min.js +1 -0
- package/lib/optgroup/style/index.js +1 -0
- package/lib/optgroup/style/style.css +0 -0
- package/lib/optgroup/style/style.min.css +0 -0
- package/lib/option/index.js +19 -0
- package/lib/option/index.min.js +1 -0
- package/lib/option/style/index.js +1 -0
- package/lib/option/style/style.css +0 -0
- package/lib/option/style/style.min.css +0 -0
- package/lib/pager/index.js +19 -0
- package/lib/pager/index.min.js +1 -0
- package/lib/pager/src/pager.js +714 -0
- package/lib/pager/src/pager.min.js +1 -0
- package/lib/password-input/index.js +19 -0
- package/lib/password-input/index.min.js +1 -0
- package/lib/password-input/src/password-input.js +398 -0
- package/lib/password-input/src/password-input.min.js +1 -0
- package/lib/password-input/style/index.js +1 -0
- package/lib/password-input/style/style.css +604 -0
- package/lib/password-input/style/style.min.css +1 -0
- package/lib/pulldown/src/pulldown.js +5 -1
- package/lib/pulldown/src/pulldown.min.js +1 -1
- package/lib/select/index.js +19 -0
- package/lib/select/index.min.js +1 -0
- package/lib/select/src/optgroup.js +97 -0
- package/lib/select/src/optgroup.min.js +1 -0
- package/lib/select/src/option-info.js +33 -0
- package/lib/select/src/option-info.min.js +1 -0
- package/lib/select/src/option.js +93 -0
- package/lib/select/src/option.min.js +1 -0
- package/lib/select/src/select.js +1315 -0
- package/lib/select/src/select.min.js +1 -0
- package/lib/select/src/util.js +50 -0
- package/lib/select/src/util.min.js +1 -0
- package/lib/select/style/index.js +1 -0
- package/lib/select/style/style.css +207 -0
- package/lib/select/style/style.min.css +1 -0
- package/lib/style.css +1 -1
- package/lib/style.min.css +1 -1
- package/lib/tab-pane/index.js +19 -0
- package/lib/tab-pane/index.min.js +1 -0
- package/lib/tab-pane/style/index.js +1 -0
- package/lib/tab-pane/style/style.css +0 -0
- package/lib/tab-pane/style/style.min.css +0 -0
- package/lib/tabs/index.js +19 -0
- package/lib/tabs/index.min.js +1 -0
- package/lib/tabs/src/tab-pane.js +128 -0
- package/lib/tabs/src/tab-pane.min.js +1 -0
- package/lib/tabs/src/tabs.js +630 -0
- package/lib/tabs/src/tabs.min.js +1 -0
- package/lib/tabs/src/util.js +29 -0
- package/lib/tabs/src/util.min.js +1 -0
- package/lib/tabs/style/index.js +1 -0
- package/lib/tabs/style/style.css +342 -0
- package/lib/tabs/style/style.min.css +1 -0
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/lib/vxe-carousel/index.js +23 -0
- package/lib/vxe-carousel/index.min.js +1 -0
- package/lib/vxe-carousel/style/index.js +1 -0
- package/lib/vxe-carousel/style/style.css +185 -0
- package/lib/vxe-carousel/style/style.min.css +1 -0
- package/lib/vxe-carousel-item/index.js +23 -0
- package/lib/vxe-carousel-item/index.min.js +1 -0
- package/lib/vxe-carousel-item/style/index.js +1 -0
- package/lib/vxe-carousel-item/style/style.css +0 -0
- package/lib/vxe-carousel-item/style/style.min.css +0 -0
- package/lib/vxe-checkbox/index.js +23 -0
- package/lib/vxe-checkbox/index.min.js +1 -0
- package/lib/vxe-checkbox/style/index.js +1 -0
- package/lib/vxe-checkbox/style/style.css +117 -0
- package/lib/vxe-checkbox/style/style.min.css +1 -0
- package/lib/vxe-checkbox-group/index.js +23 -0
- package/lib/vxe-checkbox-group/index.min.js +1 -0
- package/lib/vxe-checkbox-group/style/index.js +1 -0
- package/lib/vxe-checkbox-group/style/style.css +0 -0
- package/lib/vxe-checkbox-group/style/style.min.css +0 -0
- package/lib/vxe-icon-picker/index.js +23 -0
- package/lib/vxe-icon-picker/index.min.js +1 -0
- package/lib/vxe-icon-picker/style/index.js +1 -0
- package/lib/vxe-icon-picker/style/style.css +207 -0
- package/lib/vxe-icon-picker/style/style.min.css +1 -0
- package/lib/vxe-input/index.js +23 -0
- package/lib/vxe-input/index.min.js +1 -0
- package/lib/vxe-input/style/index.js +1 -0
- package/lib/vxe-input/style/style.css +941 -0
- package/lib/vxe-input/style/style.min.css +1 -0
- package/lib/vxe-optgroup/index.js +23 -0
- package/lib/vxe-optgroup/index.min.js +1 -0
- package/lib/vxe-optgroup/style/index.js +1 -0
- package/lib/vxe-optgroup/style/style.css +0 -0
- package/lib/vxe-optgroup/style/style.min.css +0 -0
- package/lib/vxe-option/index.js +23 -0
- package/lib/vxe-option/index.min.js +1 -0
- package/lib/vxe-option/style/index.js +1 -0
- package/lib/vxe-option/style/style.css +0 -0
- package/lib/vxe-option/style/style.min.css +0 -0
- package/lib/vxe-password-input/index.js +23 -0
- package/lib/vxe-password-input/index.min.js +1 -0
- package/lib/vxe-password-input/style/index.js +1 -0
- package/lib/vxe-password-input/style/style.css +604 -0
- package/lib/vxe-password-input/style/style.min.css +1 -0
- package/lib/vxe-select/index.js +23 -0
- package/lib/vxe-select/index.min.js +1 -0
- package/lib/vxe-select/style/index.js +1 -0
- package/lib/vxe-select/style/style.css +207 -0
- package/lib/vxe-select/style/style.min.css +1 -0
- package/lib/vxe-tab-pane/index.js +23 -0
- package/lib/vxe-tab-pane/index.min.js +1 -0
- package/lib/vxe-tab-pane/style/index.js +1 -0
- package/lib/vxe-tab-pane/style/style.css +0 -0
- package/lib/vxe-tab-pane/style/style.min.css +0 -0
- package/lib/vxe-tabs/index.js +23 -0
- package/lib/vxe-tabs/index.min.js +1 -0
- package/lib/vxe-tabs/style/index.js +1 -0
- package/lib/vxe-tabs/style/style.css +342 -0
- package/lib/vxe-tabs/style/style.min.css +1 -0
- package/package.json +1 -1
- package/packages/button/src/button.ts +3 -0
- package/packages/carousel/index.ts +16 -0
- package/packages/carousel/src/carousel-item.ts +114 -0
- package/packages/carousel/src/carousel.ts +449 -0
- package/packages/carousel/src/util.ts +21 -0
- package/packages/carousel-item/index.ts +16 -0
- package/packages/checkbox/index.ts +16 -0
- package/packages/checkbox/src/checkbox.ts +176 -0
- package/packages/checkbox/src/group.ts +178 -0
- package/packages/checkbox-group/index.ts +16 -0
- package/packages/components.ts +39 -39
- package/packages/date-picker/src/date-picker.ts +3 -0
- package/packages/icon-picker/index.ts +16 -0
- package/packages/icon-picker/src/icon-picker.ts +711 -0
- package/packages/input/index.ts +16 -0
- package/packages/input/src/input.ts +2995 -0
- package/packages/layout-footer/src/layout-footer.ts +4 -3
- package/packages/layout-header/src/layout-header.ts +2 -1
- package/packages/optgroup/index.ts +16 -0
- package/packages/option/index.ts +16 -0
- package/packages/pager/index.ts +16 -0
- package/packages/pager/src/pager.ts +743 -0
- package/packages/password-input/index.ts +16 -0
- package/packages/password-input/src/password-input.ts +427 -0
- package/packages/pulldown/src/pulldown.ts +5 -1
- package/packages/select/index.ts +16 -0
- package/packages/select/src/optgroup.ts +107 -0
- package/packages/select/src/option-info.ts +20 -0
- package/packages/select/src/option.ts +103 -0
- package/packages/select/src/select.ts +1325 -0
- package/packages/select/src/util.ts +46 -0
- package/packages/tab-pane/index.ts +16 -0
- package/packages/tabs/index.ts +16 -0
- package/packages/tabs/src/tab-pane.ts +136 -0
- package/packages/tabs/src/tabs.ts +630 -0
- package/packages/tabs/src/util.ts +21 -0
- package/types/components/carousel.d.ts +5 -0
- package/types/components/icon-picker.d.ts +4 -0
- package/types/components/input.d.ts +9 -1
- package/types/components/optgroup.d.ts +10 -4
- package/types/components/tabs.d.ts +4 -0
- /package/es/icon/style/{iconfont.1725630285930.ttf → iconfont.1725723159302.ttf} +0 -0
- /package/es/icon/style/{iconfont.1725630285930.woff → iconfont.1725723159302.woff} +0 -0
- /package/es/icon/style/{iconfont.1725630285930.woff2 → iconfont.1725723159302.woff2} +0 -0
- /package/es/{iconfont.1725630285930.ttf → iconfont.1725723159302.ttf} +0 -0
- /package/es/{iconfont.1725630285930.woff → iconfont.1725723159302.woff} +0 -0
- /package/es/{iconfont.1725630285930.woff2 → iconfont.1725723159302.woff2} +0 -0
- /package/lib/icon/style/{iconfont.1725630285930.ttf → iconfont.1725723159302.ttf} +0 -0
- /package/lib/icon/style/{iconfont.1725630285930.woff → iconfont.1725723159302.woff} +0 -0
- /package/lib/icon/style/{iconfont.1725630285930.woff2 → iconfont.1725723159302.woff2} +0 -0
- /package/lib/{iconfont.1725630285930.ttf → iconfont.1725723159302.ttf} +0 -0
- /package/lib/{iconfont.1725630285930.woff → iconfont.1725723159302.woff} +0 -0
- /package/lib/{iconfont.1725630285930.woff2 → iconfont.1725723159302.woff2} +0 -0
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
.vxe-carousel {
|
|
2
|
+
position: relative;
|
|
3
|
+
font-size: var(--vxe-ui-font-size-default);
|
|
4
|
+
color: var(--vxe-ui-font-color);
|
|
5
|
+
font-family: var(--vxe-ui-font-family);
|
|
6
|
+
background-color: var(--vxe-ui-layout-background-color);
|
|
7
|
+
overflow: hidden;
|
|
8
|
+
}
|
|
9
|
+
.vxe-carousel:hover .vxe-carousel--indicators {
|
|
10
|
+
opacity: 1;
|
|
11
|
+
}
|
|
12
|
+
.vxe-carousel:hover .vxe-carousel--previous-btn,
|
|
13
|
+
.vxe-carousel:hover .vxe-carousel--next-btn {
|
|
14
|
+
opacity: 1;
|
|
15
|
+
}
|
|
16
|
+
.vxe-carousel:hover.is--horizontal .vxe-carousel--previous-btn,
|
|
17
|
+
.vxe-carousel:hover.is--horizontal .vxe-carousel--next-btn {
|
|
18
|
+
transform: translate(0, -50%);
|
|
19
|
+
}
|
|
20
|
+
.vxe-carousel:hover.is--vertical .vxe-carousel--previous-btn,
|
|
21
|
+
.vxe-carousel:hover.is--vertical .vxe-carousel--next-btn {
|
|
22
|
+
transform: translate(-50%, 0);
|
|
23
|
+
}
|
|
24
|
+
.vxe-carousel.is--horizontal .vxe-carousel--list {
|
|
25
|
+
height: 100%;
|
|
26
|
+
flex-direction: row;
|
|
27
|
+
}
|
|
28
|
+
.vxe-carousel.is--horizontal .vxe-carousel--indicators {
|
|
29
|
+
flex-direction: row;
|
|
30
|
+
bottom: 0.3em;
|
|
31
|
+
left: 50%;
|
|
32
|
+
padding: 0.15em 0.3em;
|
|
33
|
+
transform: translateX(-50%);
|
|
34
|
+
}
|
|
35
|
+
.vxe-carousel.is--horizontal .vxe-carousel--indicators:hover {
|
|
36
|
+
transform: translateX(-50%) scale(1.1);
|
|
37
|
+
}
|
|
38
|
+
.vxe-carousel.is--horizontal .vxe-carousel--indicators-item {
|
|
39
|
+
margin: 0.2em 0.25em;
|
|
40
|
+
}
|
|
41
|
+
.vxe-carousel.is--horizontal .vxe-carousel--previous-btn,
|
|
42
|
+
.vxe-carousel.is--horizontal .vxe-carousel--next-btn {
|
|
43
|
+
top: 50%;
|
|
44
|
+
transform: translate(0, -50%);
|
|
45
|
+
}
|
|
46
|
+
.vxe-carousel.is--horizontal .vxe-carousel--previous-btn:hover,
|
|
47
|
+
.vxe-carousel.is--horizontal .vxe-carousel--next-btn:hover {
|
|
48
|
+
transform: translate(0, -50%) scale(1.1);
|
|
49
|
+
}
|
|
50
|
+
.vxe-carousel.is--horizontal .vxe-carousel--previous-btn:active,
|
|
51
|
+
.vxe-carousel.is--horizontal .vxe-carousel--next-btn:active {
|
|
52
|
+
transform: translate(0, -50%) scale(0.8);
|
|
53
|
+
}
|
|
54
|
+
.vxe-carousel.is--horizontal .vxe-carousel--previous-btn {
|
|
55
|
+
left: 0.3em;
|
|
56
|
+
transform: translate(-0.8em, -50%);
|
|
57
|
+
}
|
|
58
|
+
.vxe-carousel.is--horizontal .vxe-carousel--next-btn {
|
|
59
|
+
right: 0.3em;
|
|
60
|
+
transform: translate(0.8em, -50%);
|
|
61
|
+
}
|
|
62
|
+
.vxe-carousel.is--vertical .vxe-carousel--list {
|
|
63
|
+
width: 100%;
|
|
64
|
+
flex-direction: column;
|
|
65
|
+
}
|
|
66
|
+
.vxe-carousel.is--vertical .vxe-carousel--indicators {
|
|
67
|
+
display: flex;
|
|
68
|
+
flex-direction: column;
|
|
69
|
+
padding: 0.3em 0.15em;
|
|
70
|
+
top: 50%;
|
|
71
|
+
right: 0.3em;
|
|
72
|
+
transform: translateY(-50%);
|
|
73
|
+
}
|
|
74
|
+
.vxe-carousel.is--vertical .vxe-carousel--indicators:hover {
|
|
75
|
+
transform: translateY(-50%) scale(1.1);
|
|
76
|
+
}
|
|
77
|
+
.vxe-carousel.is--vertical .vxe-carousel--indicators-item {
|
|
78
|
+
margin: 0.25em 0.2em;
|
|
79
|
+
}
|
|
80
|
+
.vxe-carousel.is--vertical .vxe-carousel--previous-btn,
|
|
81
|
+
.vxe-carousel.is--vertical .vxe-carousel--next-btn {
|
|
82
|
+
left: 50%;
|
|
83
|
+
}
|
|
84
|
+
.vxe-carousel.is--vertical .vxe-carousel--previous-btn:hover,
|
|
85
|
+
.vxe-carousel.is--vertical .vxe-carousel--next-btn:hover {
|
|
86
|
+
transform: translate(-50%, 0) scale(1.1);
|
|
87
|
+
}
|
|
88
|
+
.vxe-carousel.is--vertical .vxe-carousel--previous-btn:active,
|
|
89
|
+
.vxe-carousel.is--vertical .vxe-carousel--next-btn:active {
|
|
90
|
+
transform: translate(-50%, 0) scale(0.8);
|
|
91
|
+
}
|
|
92
|
+
.vxe-carousel.is--vertical .vxe-carousel--previous-btn {
|
|
93
|
+
top: 0.3em;
|
|
94
|
+
transform: translate(-50%, -0.8em);
|
|
95
|
+
}
|
|
96
|
+
.vxe-carousel.is--vertical .vxe-carousel--next-btn {
|
|
97
|
+
bottom: 0.3em;
|
|
98
|
+
transform: translate(-50%, 0.8em);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.vxe-carousel--slots {
|
|
102
|
+
display: none;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.vxe-carousel--item-wrapper {
|
|
106
|
+
position: relative;
|
|
107
|
+
width: 100%;
|
|
108
|
+
overflow: hidden;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.vxe-carousel--list {
|
|
112
|
+
position: absolute;
|
|
113
|
+
left: 0;
|
|
114
|
+
top: 0;
|
|
115
|
+
display: flex;
|
|
116
|
+
outline: 0;
|
|
117
|
+
transition: transform 0.2s ease-in-out;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.vxe-carousel--item-inner {
|
|
121
|
+
width: 100%;
|
|
122
|
+
height: 100%;
|
|
123
|
+
text-align: center;
|
|
124
|
+
flex-grow: 1;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.vxe-carousel--item-img {
|
|
128
|
+
max-width: 100%;
|
|
129
|
+
max-height: 100%;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.vxe-carousel--indicators {
|
|
133
|
+
position: absolute;
|
|
134
|
+
display: inline-flex;
|
|
135
|
+
background-color: rgba(0, 0, 0, 0.6);
|
|
136
|
+
border-radius: 0.6em;
|
|
137
|
+
opacity: 0;
|
|
138
|
+
transition: all 0.3s ease-in-out;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.vxe-carousel--indicators-item {
|
|
142
|
+
width: 0.8em;
|
|
143
|
+
height: 0.8em;
|
|
144
|
+
border-radius: 50%;
|
|
145
|
+
background-color: rgba(255, 255, 255, 0.8);
|
|
146
|
+
cursor: pointer;
|
|
147
|
+
transition: all 0.2s ease-in-out;
|
|
148
|
+
}
|
|
149
|
+
.vxe-carousel--indicators-item.is--active {
|
|
150
|
+
background-color: rgb(255, 255, 255);
|
|
151
|
+
}
|
|
152
|
+
.vxe-carousel--indicators-item:hover {
|
|
153
|
+
background-color: rgba(255, 255, 255, 0.9);
|
|
154
|
+
}
|
|
155
|
+
.vxe-carousel--indicators-item:active {
|
|
156
|
+
background-color: var(--vxe-ui-font-primary-color);
|
|
157
|
+
transform: scale(0.8);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.vxe-carousel--previous-btn,
|
|
161
|
+
.vxe-carousel--next-btn {
|
|
162
|
+
display: flex;
|
|
163
|
+
flex-direction: row;
|
|
164
|
+
align-items: center;
|
|
165
|
+
justify-content: center;
|
|
166
|
+
position: absolute;
|
|
167
|
+
width: 1.8em;
|
|
168
|
+
height: 1.8em;
|
|
169
|
+
border-radius: 50%;
|
|
170
|
+
font-size: 1.4em;
|
|
171
|
+
background-color: rgba(0, 0, 0, 0.8);
|
|
172
|
+
opacity: 0;
|
|
173
|
+
color: rgba(255, 255, 255, 0.6);
|
|
174
|
+
cursor: pointer;
|
|
175
|
+
transition: all 0.2s ease-in-out;
|
|
176
|
+
}
|
|
177
|
+
.vxe-carousel--previous-btn:hover,
|
|
178
|
+
.vxe-carousel--next-btn:hover {
|
|
179
|
+
color: rgb(255, 255, 255);
|
|
180
|
+
}
|
|
181
|
+
.vxe-carousel--previous-btn:active,
|
|
182
|
+
.vxe-carousel--next-btn:active {
|
|
183
|
+
color: var(--vxe-ui-font-primary-color);
|
|
184
|
+
background-color: rgba(0, 0, 0, 0.6);
|
|
185
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.vxe-carousel{position:relative;font-size:var(--vxe-ui-font-size-default);color:var(--vxe-ui-font-color);font-family:var(--vxe-ui-font-family);background-color:var(--vxe-ui-layout-background-color);overflow:hidden}.vxe-carousel:hover .vxe-carousel--indicators{opacity:1}.vxe-carousel:hover .vxe-carousel--next-btn,.vxe-carousel:hover .vxe-carousel--previous-btn{opacity:1}.vxe-carousel:hover.is--horizontal .vxe-carousel--next-btn,.vxe-carousel:hover.is--horizontal .vxe-carousel--previous-btn{transform:translate(0,-50%)}.vxe-carousel:hover.is--vertical .vxe-carousel--next-btn,.vxe-carousel:hover.is--vertical .vxe-carousel--previous-btn{transform:translate(-50%,0)}.vxe-carousel.is--horizontal .vxe-carousel--list{height:100%;flex-direction:row}.vxe-carousel.is--horizontal .vxe-carousel--indicators{flex-direction:row;bottom:.3em;left:50%;padding:.15em .3em;transform:translateX(-50%)}.vxe-carousel.is--horizontal .vxe-carousel--indicators:hover{transform:translateX(-50%) scale(1.1)}.vxe-carousel.is--horizontal .vxe-carousel--indicators-item{margin:.2em .25em}.vxe-carousel.is--horizontal .vxe-carousel--next-btn,.vxe-carousel.is--horizontal .vxe-carousel--previous-btn{top:50%;transform:translate(0,-50%)}.vxe-carousel.is--horizontal .vxe-carousel--next-btn:hover,.vxe-carousel.is--horizontal .vxe-carousel--previous-btn:hover{transform:translate(0,-50%) scale(1.1)}.vxe-carousel.is--horizontal .vxe-carousel--next-btn:active,.vxe-carousel.is--horizontal .vxe-carousel--previous-btn:active{transform:translate(0,-50%) scale(.8)}.vxe-carousel.is--horizontal .vxe-carousel--previous-btn{left:.3em;transform:translate(-.8em,-50%)}.vxe-carousel.is--horizontal .vxe-carousel--next-btn{right:.3em;transform:translate(.8em,-50%)}.vxe-carousel.is--vertical .vxe-carousel--list{width:100%;flex-direction:column}.vxe-carousel.is--vertical .vxe-carousel--indicators{display:flex;flex-direction:column;padding:.3em .15em;top:50%;right:.3em;transform:translateY(-50%)}.vxe-carousel.is--vertical .vxe-carousel--indicators:hover{transform:translateY(-50%) scale(1.1)}.vxe-carousel.is--vertical .vxe-carousel--indicators-item{margin:.25em .2em}.vxe-carousel.is--vertical .vxe-carousel--next-btn,.vxe-carousel.is--vertical .vxe-carousel--previous-btn{left:50%}.vxe-carousel.is--vertical .vxe-carousel--next-btn:hover,.vxe-carousel.is--vertical .vxe-carousel--previous-btn:hover{transform:translate(-50%,0) scale(1.1)}.vxe-carousel.is--vertical .vxe-carousel--next-btn:active,.vxe-carousel.is--vertical .vxe-carousel--previous-btn:active{transform:translate(-50%,0) scale(.8)}.vxe-carousel.is--vertical .vxe-carousel--previous-btn{top:.3em;transform:translate(-50%,-.8em)}.vxe-carousel.is--vertical .vxe-carousel--next-btn{bottom:.3em;transform:translate(-50%,.8em)}.vxe-carousel--slots{display:none}.vxe-carousel--item-wrapper{position:relative;width:100%;overflow:hidden}.vxe-carousel--list{position:absolute;left:0;top:0;display:flex;outline:0;transition:transform .2s ease-in-out}.vxe-carousel--item-inner{width:100%;height:100%;text-align:center;flex-grow:1}.vxe-carousel--item-img{max-width:100%;max-height:100%}.vxe-carousel--indicators{position:absolute;display:inline-flex;background-color:rgba(0,0,0,.6);border-radius:.6em;opacity:0;transition:all .3s ease-in-out}.vxe-carousel--indicators-item{width:.8em;height:.8em;border-radius:50%;background-color:rgba(255,255,255,.8);cursor:pointer;transition:all .2s ease-in-out}.vxe-carousel--indicators-item.is--active{background-color:#fff}.vxe-carousel--indicators-item:hover{background-color:rgba(255,255,255,.9)}.vxe-carousel--indicators-item:active{background-color:var(--vxe-ui-font-primary-color);transform:scale(.8)}.vxe-carousel--next-btn,.vxe-carousel--previous-btn{display:flex;flex-direction:row;align-items:center;justify-content:center;position:absolute;width:1.8em;height:1.8em;border-radius:50%;font-size:1.4em;background-color:rgba(0,0,0,.8);opacity:0;color:rgba(255,255,255,.6);cursor:pointer;transition:all .2s ease-in-out}.vxe-carousel--next-btn:hover,.vxe-carousel--previous-btn:hover{color:#fff}.vxe-carousel--next-btn:active,.vxe-carousel--previous-btn:active{color:var(--vxe-ui-font-primary-color);background-color:rgba(0,0,0,.6)}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.VxeCarouselItem = exports.CarouselItem = void 0;
|
|
7
|
+
var _core = require("@vxe-ui/core");
|
|
8
|
+
var _carouselItem = _interopRequireDefault(require("../carousel/src/carousel-item"));
|
|
9
|
+
var _dynamics = require("../dynamics");
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
var VxeCarouselItem = exports.VxeCarouselItem = Object.assign({}, _carouselItem.default, {
|
|
12
|
+
install: function install(app) {
|
|
13
|
+
app.component(_carouselItem.default.name, _carouselItem.default);
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
_dynamics.dynamicApp.use(VxeCarouselItem);
|
|
17
|
+
_core.VxeUI.component(_carouselItem.default);
|
|
18
|
+
var CarouselItem = exports.CarouselItem = VxeCarouselItem;
|
|
19
|
+
var _default = exports.default = VxeCarouselItem;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=exports.VxeCarouselItem=exports.CarouselItem=void 0;var _core=require("@vxe-ui/core"),_carouselItem=_interopRequireDefault(require("../carousel/src/carousel-item")),_dynamics=require("../dynamics");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var VxeCarouselItem=exports.VxeCarouselItem=Object.assign({},_carouselItem.default,{install:function(e){e.component(_carouselItem.default.name,_carouselItem.default)}}),CarouselItem=(_dynamics.dynamicApp.use(VxeCarouselItem),_core.VxeUI.component(_carouselItem.default),exports.CarouselItem=VxeCarouselItem),_default=exports.default=VxeCarouselItem;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
require('./style.css')
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = exports.VxeCheckbox = exports.Checkbox = void 0;
|
|
7
|
+
var _core = require("@vxe-ui/core");
|
|
8
|
+
var _checkbox = _interopRequireDefault(require("./src/checkbox"));
|
|
9
|
+
var _dynamics = require("../dynamics");
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
11
|
+
var VxeCheckbox = exports.VxeCheckbox = Object.assign(_checkbox.default, {
|
|
12
|
+
install: function install(app) {
|
|
13
|
+
app.component(_checkbox.default.name, _checkbox.default);
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
_dynamics.dynamicApp.use(VxeCheckbox);
|
|
17
|
+
_core.VxeUI.component(_checkbox.default);
|
|
18
|
+
var Checkbox = exports.Checkbox = VxeCheckbox;
|
|
19
|
+
var _default = exports.default = VxeCheckbox;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=exports.VxeCheckbox=exports.Checkbox=void 0;var _core=require("@vxe-ui/core"),_checkbox=_interopRequireDefault(require("./src/checkbox")),_dynamics=require("../dynamics");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var VxeCheckbox=exports.VxeCheckbox=Object.assign(_checkbox.default,{install:function(e){e.component(_checkbox.default.name,_checkbox.default)}}),Checkbox=(_dynamics.dynamicApp.use(VxeCheckbox),_core.VxeUI.component(_checkbox.default),exports.Checkbox=VxeCheckbox),_default=exports.default=VxeCheckbox;
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _comp = require("../../ui/src/comp");
|
|
8
|
+
var _xeUtils = _interopRequireDefault(require("xe-utils"));
|
|
9
|
+
var _utils = require("../../ui/src/utils");
|
|
10
|
+
var _ui = require("../../ui");
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
13
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
14
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
15
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
16
|
+
var _default2 = exports.default = (0, _comp.defineVxeComponent)({
|
|
17
|
+
name: 'VxeCheckbox',
|
|
18
|
+
mixins: [_ui.globalMixins.sizeMixin],
|
|
19
|
+
props: {
|
|
20
|
+
value: [String, Number, Boolean],
|
|
21
|
+
label: {
|
|
22
|
+
type: [String, Number],
|
|
23
|
+
default: null
|
|
24
|
+
},
|
|
25
|
+
indeterminate: Boolean,
|
|
26
|
+
title: [String, Number],
|
|
27
|
+
checkedValue: {
|
|
28
|
+
type: [String, Number, Boolean],
|
|
29
|
+
default: true
|
|
30
|
+
},
|
|
31
|
+
uncheckedValue: {
|
|
32
|
+
type: [String, Number, Boolean],
|
|
33
|
+
default: false
|
|
34
|
+
},
|
|
35
|
+
content: [String, Number],
|
|
36
|
+
disabled: {
|
|
37
|
+
type: Boolean,
|
|
38
|
+
default: null
|
|
39
|
+
},
|
|
40
|
+
size: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: function _default() {
|
|
43
|
+
return (0, _ui.getConfig)().checkbox.size || (0, _ui.getConfig)().size;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
inject: {
|
|
48
|
+
$xeForm: {
|
|
49
|
+
default: null
|
|
50
|
+
},
|
|
51
|
+
formItemInfo: {
|
|
52
|
+
from: 'xeFormItemInfo',
|
|
53
|
+
default: null
|
|
54
|
+
},
|
|
55
|
+
$xeCheckboxGroup: {
|
|
56
|
+
default: null
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
data: function data() {
|
|
60
|
+
var reactData = {};
|
|
61
|
+
return {
|
|
62
|
+
xID: _xeUtils.default.uniqueId(),
|
|
63
|
+
reactData: reactData
|
|
64
|
+
};
|
|
65
|
+
},
|
|
66
|
+
computed: Object.assign(Object.assign({}, {}), {
|
|
67
|
+
computeIsChecked: function computeIsChecked() {
|
|
68
|
+
var $xeCheckbox = this;
|
|
69
|
+
var props = $xeCheckbox;
|
|
70
|
+
var $xeCheckboxGroup = $xeCheckbox.$xeCheckboxGroup;
|
|
71
|
+
if ($xeCheckboxGroup) {
|
|
72
|
+
return _xeUtils.default.includes($xeCheckboxGroup.value, props.label);
|
|
73
|
+
}
|
|
74
|
+
return props.value === props.checkedValue;
|
|
75
|
+
},
|
|
76
|
+
computeIsDisabled: function computeIsDisabled() {
|
|
77
|
+
var $xeCheckbox = this;
|
|
78
|
+
var props = $xeCheckbox;
|
|
79
|
+
var $xeCheckboxGroup = $xeCheckbox.$xeCheckboxGroup;
|
|
80
|
+
var disabled = props.disabled;
|
|
81
|
+
var isChecked = $xeCheckbox.computeIsChecked;
|
|
82
|
+
if (disabled === null) {
|
|
83
|
+
if ($xeCheckboxGroup) {
|
|
84
|
+
var isGroupDisabled = $xeCheckboxGroup.computeIsDisabled;
|
|
85
|
+
var isGroupMaximize = $xeCheckboxGroup.computeIsMaximize;
|
|
86
|
+
return isGroupDisabled || isGroupMaximize && !isChecked;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
return disabled;
|
|
90
|
+
}
|
|
91
|
+
}),
|
|
92
|
+
methods: {
|
|
93
|
+
//
|
|
94
|
+
// Method
|
|
95
|
+
//
|
|
96
|
+
dispatchEvent: function dispatchEvent(type, params, evnt) {
|
|
97
|
+
var $xeCheckbox = this;
|
|
98
|
+
$xeCheckbox.$emit(type, (0, _ui.createEvent)(evnt, {
|
|
99
|
+
$checkbox: $xeCheckbox
|
|
100
|
+
}, params));
|
|
101
|
+
},
|
|
102
|
+
changeEvent: function changeEvent(evnt) {
|
|
103
|
+
var $xeCheckbox = this;
|
|
104
|
+
var props = $xeCheckbox;
|
|
105
|
+
var $xeCheckboxGroup = $xeCheckbox.$xeCheckboxGroup;
|
|
106
|
+
var $xeForm = $xeCheckbox.$xeForm;
|
|
107
|
+
var formItemInfo = $xeCheckbox.formItemInfo;
|
|
108
|
+
var checkedValue = props.checkedValue,
|
|
109
|
+
uncheckedValue = props.uncheckedValue;
|
|
110
|
+
var isDisabled = $xeCheckbox.computeIsDisabled;
|
|
111
|
+
if (!isDisabled) {
|
|
112
|
+
var checked = evnt.target.checked;
|
|
113
|
+
var value = checked ? checkedValue : uncheckedValue;
|
|
114
|
+
var params = {
|
|
115
|
+
checked: checked,
|
|
116
|
+
value: value,
|
|
117
|
+
label: props.label
|
|
118
|
+
};
|
|
119
|
+
if ($xeCheckboxGroup) {
|
|
120
|
+
$xeCheckboxGroup.handleChecked(params, evnt);
|
|
121
|
+
} else {
|
|
122
|
+
$xeCheckbox.$emit('input', value);
|
|
123
|
+
$xeCheckbox.dispatchEvent('change', params, evnt);
|
|
124
|
+
// 自动更新校验状态
|
|
125
|
+
if ($xeForm && formItemInfo) {
|
|
126
|
+
$xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, value);
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
},
|
|
131
|
+
//
|
|
132
|
+
// Render
|
|
133
|
+
//
|
|
134
|
+
renderVN: function renderVN(h) {
|
|
135
|
+
var $xeCheckbox = this;
|
|
136
|
+
var props = $xeCheckbox;
|
|
137
|
+
var slots = $xeCheckbox.$scopedSlots;
|
|
138
|
+
var vSize = $xeCheckbox.computeSize;
|
|
139
|
+
var isDisabled = $xeCheckbox.computeIsDisabled;
|
|
140
|
+
var isChecked = $xeCheckbox.computeIsChecked;
|
|
141
|
+
var indeterminate = !isChecked && props.indeterminate;
|
|
142
|
+
return h('label', {
|
|
143
|
+
class: ['vxe-checkbox', _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "size--".concat(vSize), vSize), 'is--indeterminate', indeterminate), 'is--disabled', isDisabled), 'is--checked', isChecked)],
|
|
144
|
+
attrs: {
|
|
145
|
+
title: props.title
|
|
146
|
+
}
|
|
147
|
+
}, [h('input', {
|
|
148
|
+
class: 'vxe-checkbox--input',
|
|
149
|
+
domProps: {
|
|
150
|
+
checked: isChecked
|
|
151
|
+
},
|
|
152
|
+
attrs: {
|
|
153
|
+
type: 'checkbox',
|
|
154
|
+
disabled: isDisabled
|
|
155
|
+
},
|
|
156
|
+
on: {
|
|
157
|
+
change: $xeCheckbox.changeEvent
|
|
158
|
+
}
|
|
159
|
+
}), h('span', {
|
|
160
|
+
class: ['vxe-checkbox--icon', indeterminate ? (0, _ui.getIcon)().CHECKBOX_INDETERMINATE : isChecked ? (0, _ui.getIcon)().CHECKBOX_CHECKED : (0, _ui.getIcon)().CHECKBOX_UNCHECKED]
|
|
161
|
+
}), h('span', {
|
|
162
|
+
class: 'vxe-checkbox--label'
|
|
163
|
+
}, slots.default ? slots.default({}) : (0, _utils.getFuncText)(props.content))]);
|
|
164
|
+
}
|
|
165
|
+
},
|
|
166
|
+
render: function render(h) {
|
|
167
|
+
return this.renderVN(h);
|
|
168
|
+
}
|
|
169
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var _comp=require("../../ui/src/comp"),_xeUtils=_interopRequireDefault(require("xe-utils")),_utils=require("../../ui/src/utils"),_ui=require("../../ui");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function _typeof(e){return(_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function _defineProperty(e,t,i){return(t=_toPropertyKey(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function _toPropertyKey(e){e=_toPrimitive(e,"string");return"symbol"==_typeof(e)?e:e+""}function _toPrimitive(e,t){if("object"!=_typeof(e)||!e)return e;var i=e[Symbol.toPrimitive];if(void 0===i)return("string"===t?String:Number)(e);i=i.call(e,t||"default");if("object"!=_typeof(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}var _default2=exports.default=(0,_comp.defineVxeComponent)({name:"VxeCheckbox",mixins:[_ui.globalMixins.sizeMixin],props:{value:[String,Number,Boolean],label:{type:[String,Number],default:null},indeterminate:Boolean,title:[String,Number],checkedValue:{type:[String,Number,Boolean],default:!0},uncheckedValue:{type:[String,Number,Boolean],default:!1},content:[String,Number],disabled:{type:Boolean,default:null},size:{type:String,default:function(){return(0,_ui.getConfig)().checkbox.size||(0,_ui.getConfig)().size}}},inject:{$xeForm:{default:null},formItemInfo:{from:"xeFormItemInfo",default:null},$xeCheckboxGroup:{default:null}},data:function(){return{xID:_xeUtils.default.uniqueId(),reactData:{}}},computed:Object.assign(Object.assign({},{}),{computeIsChecked:function(){var e=this,t=this.$xeCheckboxGroup;return t?_xeUtils.default.includes(t.value,e.label):e.value===e.checkedValue},computeIsDisabled:function(){var e,t=this,i=t.$xeCheckboxGroup,n=t.disabled,t=t.computeIsChecked;if(null===n&&i)return e=i.computeIsDisabled,i=i.computeIsMaximize,e||i&&!t;return n}}),methods:{dispatchEvent:function(e,t,i){this.$emit(e,(0,_ui.createEvent)(i,{$checkbox:this},t))},changeEvent:function(e){var t,i=this,n=i.$xeCheckboxGroup,o=i.$xeForm,r=i.formItemInfo,u=i.checkedValue;i.computeIsDisabled||(u={checked:t=e.target.checked,value:t=t?u:i.uncheckedValue,label:i.label},n?n.handleChecked(u,e):(i.$emit("input",t),i.dispatchEvent("change",u,e),o&&r&&o.triggerItemEvent(e,r.itemConfig.field,t)))},renderVN:function(e){var t=this,i=t,n=t.$scopedSlots,o=t.computeSize,r=t.computeIsDisabled,u=t.computeIsChecked,c=!u&&i.indeterminate;return e("label",{class:["vxe-checkbox",_defineProperty(_defineProperty(_defineProperty(_defineProperty({},"size--".concat(o),o),"is--indeterminate",c),"is--disabled",r),"is--checked",u)],attrs:{title:i.title}},[e("input",{class:"vxe-checkbox--input",domProps:{checked:u},attrs:{type:"checkbox",disabled:r},on:{change:t.changeEvent}}),e("span",{class:["vxe-checkbox--icon",c?(0,_ui.getIcon)().CHECKBOX_INDETERMINATE:u?(0,_ui.getIcon)().CHECKBOX_CHECKED:(0,_ui.getIcon)().CHECKBOX_UNCHECKED]}),e("span",{class:"vxe-checkbox--label"},n.default?n.default({}):(0,_utils.getFuncText)(i.content))])}},render:function(e){return this.renderVN(e)}});
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.default = void 0;
|
|
7
|
+
var _comp = require("../../ui/src/comp");
|
|
8
|
+
var _xeUtils = _interopRequireDefault(require("xe-utils"));
|
|
9
|
+
var _ui = require("../../ui");
|
|
10
|
+
var _checkbox = _interopRequireDefault(require("./checkbox"));
|
|
11
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
var _default2 = exports.default = (0, _comp.defineVxeComponent)({
|
|
13
|
+
name: 'VxeCheckboxGroup',
|
|
14
|
+
mixins: [_ui.globalMixins.sizeMixin],
|
|
15
|
+
props: {
|
|
16
|
+
value: Array,
|
|
17
|
+
options: Array,
|
|
18
|
+
optionProps: Object,
|
|
19
|
+
disabled: {
|
|
20
|
+
type: Boolean,
|
|
21
|
+
default: null
|
|
22
|
+
},
|
|
23
|
+
max: {
|
|
24
|
+
type: [String, Number],
|
|
25
|
+
default: null
|
|
26
|
+
},
|
|
27
|
+
size: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: function _default() {
|
|
30
|
+
return (0, _ui.getConfig)().checkboxGroup.size || (0, _ui.getConfig)().size;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
inject: {
|
|
35
|
+
$xeForm: {
|
|
36
|
+
default: null
|
|
37
|
+
},
|
|
38
|
+
formItemInfo: {
|
|
39
|
+
from: 'xeFormItemInfo',
|
|
40
|
+
default: null
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
provide: function provide() {
|
|
44
|
+
var $xeCheckboxGroup = this;
|
|
45
|
+
return {
|
|
46
|
+
$xeCheckboxGroup: $xeCheckboxGroup
|
|
47
|
+
};
|
|
48
|
+
},
|
|
49
|
+
data: function data() {
|
|
50
|
+
var reactData = {};
|
|
51
|
+
return {
|
|
52
|
+
xID: _xeUtils.default.uniqueId(),
|
|
53
|
+
reactData: reactData
|
|
54
|
+
};
|
|
55
|
+
},
|
|
56
|
+
computed: Object.assign(Object.assign({}, {}), {
|
|
57
|
+
computeIsDisabled: function computeIsDisabled() {
|
|
58
|
+
var $xeCheckboxGroup = this;
|
|
59
|
+
var props = $xeCheckboxGroup;
|
|
60
|
+
var $xeForm = $xeCheckboxGroup.$xeForm;
|
|
61
|
+
var disabled = props.disabled;
|
|
62
|
+
if (disabled === null) {
|
|
63
|
+
if ($xeForm) {
|
|
64
|
+
return $xeForm.readonly || $xeForm.disabled;
|
|
65
|
+
}
|
|
66
|
+
return false;
|
|
67
|
+
}
|
|
68
|
+
return disabled;
|
|
69
|
+
},
|
|
70
|
+
computeIsMaximize: function computeIsMaximize() {
|
|
71
|
+
var $xeCheckboxGroup = this;
|
|
72
|
+
var props = $xeCheckboxGroup;
|
|
73
|
+
var value = props.value,
|
|
74
|
+
max = props.max;
|
|
75
|
+
if (max) {
|
|
76
|
+
return (value ? value.length : 0) >= _xeUtils.default.toNumber(max);
|
|
77
|
+
}
|
|
78
|
+
return false;
|
|
79
|
+
},
|
|
80
|
+
computePropsOpts: function computePropsOpts() {
|
|
81
|
+
var $xeCheckboxGroup = this;
|
|
82
|
+
var props = $xeCheckboxGroup;
|
|
83
|
+
return Object.assign({}, props.optionProps);
|
|
84
|
+
},
|
|
85
|
+
computeLabelField: function computeLabelField() {
|
|
86
|
+
var $xeCheckboxGroup = this;
|
|
87
|
+
var propsOpts = $xeCheckboxGroup.computePropsOpts;
|
|
88
|
+
return propsOpts.label || 'label';
|
|
89
|
+
},
|
|
90
|
+
computeValueField: function computeValueField() {
|
|
91
|
+
var $xeCheckboxGroup = this;
|
|
92
|
+
var propsOpts = $xeCheckboxGroup.computePropsOpts;
|
|
93
|
+
return propsOpts.value || 'value';
|
|
94
|
+
},
|
|
95
|
+
computeDisabledField: function computeDisabledField() {
|
|
96
|
+
var $xeCheckboxGroup = this;
|
|
97
|
+
var propsOpts = $xeCheckboxGroup.computePropsOpts;
|
|
98
|
+
return propsOpts.disabled || 'disabled';
|
|
99
|
+
}
|
|
100
|
+
}),
|
|
101
|
+
methods: {
|
|
102
|
+
//
|
|
103
|
+
// Method
|
|
104
|
+
//
|
|
105
|
+
dispatchEvent: function dispatchEvent(type, params, evnt) {
|
|
106
|
+
var $xeCheckboxGroup = this;
|
|
107
|
+
$xeCheckboxGroup.$emit(type, (0, _ui.createEvent)(evnt, {
|
|
108
|
+
$checkboxGroup: $xeCheckboxGroup
|
|
109
|
+
}, params));
|
|
110
|
+
},
|
|
111
|
+
handleChecked: function handleChecked(params, evnt) {
|
|
112
|
+
var $xeCheckboxGroup = this;
|
|
113
|
+
var props = $xeCheckboxGroup;
|
|
114
|
+
var $xeForm = $xeCheckboxGroup.$xeForm;
|
|
115
|
+
var formItemInfo = $xeCheckboxGroup.formItemInfo;
|
|
116
|
+
var checked = params.checked,
|
|
117
|
+
label = params.label;
|
|
118
|
+
var checklist = props.value || [];
|
|
119
|
+
var checkIndex = checklist.indexOf(label);
|
|
120
|
+
if (checked) {
|
|
121
|
+
if (checkIndex === -1) {
|
|
122
|
+
checklist.push(label);
|
|
123
|
+
}
|
|
124
|
+
} else {
|
|
125
|
+
checklist.splice(checkIndex, 1);
|
|
126
|
+
}
|
|
127
|
+
$xeCheckboxGroup.$emit('input', checklist);
|
|
128
|
+
$xeCheckboxGroup.dispatchEvent('change', Object.assign({
|
|
129
|
+
checklist: checklist
|
|
130
|
+
}, params), evnt);
|
|
131
|
+
// 自动更新校验状态
|
|
132
|
+
if ($xeForm && formItemInfo) {
|
|
133
|
+
$xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, checklist);
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
//
|
|
137
|
+
// Render
|
|
138
|
+
//
|
|
139
|
+
renderVN: function renderVN(h) {
|
|
140
|
+
var $xeCheckboxGroup = this;
|
|
141
|
+
var props = $xeCheckboxGroup;
|
|
142
|
+
var slots = $xeCheckboxGroup.$scopedSlots;
|
|
143
|
+
var options = props.options;
|
|
144
|
+
var defaultSlot = slots.default;
|
|
145
|
+
var valueField = $xeCheckboxGroup.computeValueField;
|
|
146
|
+
var labelField = $xeCheckboxGroup.computeLabelField;
|
|
147
|
+
var disabledField = $xeCheckboxGroup.computeDisabledField;
|
|
148
|
+
return h('div', {
|
|
149
|
+
class: 'vxe-checkbox-group'
|
|
150
|
+
}, defaultSlot ? defaultSlot({}) : options ? options.map(function (item) {
|
|
151
|
+
return h(_checkbox.default, {
|
|
152
|
+
props: {
|
|
153
|
+
label: item[valueField],
|
|
154
|
+
content: item[labelField],
|
|
155
|
+
disabled: item[disabledField]
|
|
156
|
+
}
|
|
157
|
+
});
|
|
158
|
+
}) : []);
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
render: function render(h) {
|
|
162
|
+
return this.renderVN(h);
|
|
163
|
+
}
|
|
164
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var _comp=require("../../ui/src/comp"),_xeUtils=_interopRequireDefault(require("xe-utils")),_ui=require("../../ui"),_checkbox=_interopRequireDefault(require("./checkbox"));function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var _default2=exports.default=(0,_comp.defineVxeComponent)({name:"VxeCheckboxGroup",mixins:[_ui.globalMixins.sizeMixin],props:{value:Array,options:Array,optionProps:Object,disabled:{type:Boolean,default:null},max:{type:[String,Number],default:null},size:{type:String,default:function(){return(0,_ui.getConfig)().checkboxGroup.size||(0,_ui.getConfig)().size}}},inject:{$xeForm:{default:null},formItemInfo:{from:"xeFormItemInfo",default:null}},provide:function(){return{$xeCheckboxGroup:this}},data:function(){return{xID:_xeUtils.default.uniqueId(),reactData:{}}},computed:Object.assign(Object.assign({},{}),{computeIsDisabled:function(){var e=this.$xeForm,t=this.disabled;return null===t?!!e&&(e.readonly||e.disabled):t},computeIsMaximize:function(){var e=this.value,t=this.max;return!!t&&(e?e.length:0)>=_xeUtils.default.toNumber(t)},computePropsOpts:function(){return Object.assign({},this.optionProps)},computeLabelField:function(){return this.computePropsOpts.label||"label"},computeValueField:function(){return this.computePropsOpts.value||"value"},computeDisabledField:function(){return this.computePropsOpts.disabled||"disabled"}}),methods:{dispatchEvent:function(e,t,i){this.$emit(e,(0,_ui.createEvent)(i,{$checkboxGroup:this},t))},handleChecked:function(e,t){var i=this,u=i.$xeForm,o=i.formItemInfo,n=e.checked,r=e.label,l=i.value||[],s=l.indexOf(r);n?-1===s&&l.push(r):l.splice(s,1),i.$emit("input",l),i.dispatchEvent("change",Object.assign({checklist:l},e),t),u&&o&&u.triggerItemEvent(t,o.itemConfig.field,l)},renderVN:function(t){var e=this,i=e.$scopedSlots,u=e.options,i=i.default,o=e.computeValueField,n=e.computeLabelField,r=e.computeDisabledField;return t("div",{class:"vxe-checkbox-group"},i?i({}):u?u.map(function(e){return t(_checkbox.default,{props:{label:e[o],content:e[n],disabled:e[r]}})}):[])}},render:function(e){return this.renderVN(e)}});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
require('./style.css')
|