@zidian-ui/core 0.1.4 → 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.
- package/esm/assets/packages/@zidian-ui/core/src/components/collection/List/List.css.ts.vanilla-BeW6Frwm.css +27 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/common/Button/Button.css.ts.vanilla-BgimV8hB.css +183 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/common/Tag/Tag.css.ts.vanilla-lf0HgPmO.css +103 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/input/SelectWrapper/SelectWrapper.css.ts.vanilla-C2qmBkSh.css +17 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/input/components/inputInner/InputInner.css.ts.vanilla-Dylafkkf.css +150 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/modal/Drawer/Drawer.css.ts.vanilla-g4GnhXaQ.css +45 -0
- package/esm/assets/packages/@zidian-ui/core/src/components/other/Cascader/Cascader.css.ts.vanilla-Bp7URCRM.css +49 -0
- package/esm/components/collection/List/List.css.js +9 -0
- package/esm/components/collection/List/List.js +71 -0
- package/esm/components/collection/List/components/DefaultContentPlace.js +63 -0
- package/esm/components/collection/List/components/DefaultItemPlace.js +50 -0
- package/esm/components/common/Button/Button.css.js +6 -0
- package/esm/components/common/Button/Button.js +42 -0
- package/esm/components/common/Tag/Tag.css.js +6 -0
- package/esm/components/common/Tag/Tag.js +29 -0
- package/esm/components/input/SelectWrapper/SelectWrapper.css.js +6 -0
- package/esm/components/input/SelectWrapper/SelectWrapper.js +51 -0
- package/esm/components/input/SelectWrapper/components/SelectWrapperPortal/SelectWrapperPortal.js +23 -0
- package/esm/components/input/SelectWrapper/components/SelectWrapperValue/SelectWrapperValue.js +22 -0
- package/esm/components/input/components/inputInner/InputInner.css.js +8 -0
- package/esm/components/input/components/inputInner/InputInner.js +21 -0
- package/esm/components/modal/Drawer/Drawer.css.js +7 -0
- package/esm/components/modal/Drawer/Drawer.js +54 -0
- package/esm/components/other/Cascader/Cascader.css.js +10 -0
- package/esm/components/other/Cascader/Cascader.js +109 -0
- package/esm/external/.pnpm/@vanilla-extract_recipes@0.5.7_@vanilla-extract_css@1.18.0/node_modules/@vanilla-extract/recipes/dist/createRuntimeFn-62c9670f.esm.js +111 -0
- package/esm/index.js +13 -0
- package/esm/theme/provider/ThemeProvider.js +34 -0
- package/esm/theme/token/contract.js +128 -0
- package/esm/theme/token/tokenMap.js +52 -0
- package/esm/theme/token/tokenSetup.js +87 -0
- package/esm/theme/utils/color.js +42 -0
- package/esm/theme/utils/contract.js +15 -0
- package/esm/theme/utils/token.js +39 -0
- package/lib/components/collection/List/List.css.d.ts +5 -0
- package/lib/components/collection/List/List.d.ts +1 -0
- package/lib/components/collection/List/List.prop.d.ts +13 -0
- package/lib/components/collection/List/components/DefaultContentPlace.d.ts +1 -0
- package/lib/components/collection/List/components/DefaultItemPlace.d.ts +1 -0
- package/lib/components/collection/List/index.d.ts +2 -0
- package/lib/components/collection/index.d.ts +1 -0
- package/lib/components/common/Button/Button.css.d.ts +137 -0
- package/lib/components/common/Button/Button.d.ts +2 -0
- package/lib/components/common/Button/Button.props.d.ts +10 -0
- package/lib/components/common/Button/index.d.ts +2 -0
- package/lib/components/common/Tag/Tag.css.d.ts +67 -0
- package/lib/components/common/Tag/Tag.d.ts +2 -0
- package/lib/components/common/Tag/Tag.props.d.ts +8 -0
- package/lib/components/common/Tag/index.d.ts +2 -0
- package/lib/components/common/index.d.ts +2 -0
- package/lib/components/index.d.ts +5 -0
- package/lib/components/input/SelectWrapper/SelectWrapper.css.d.ts +2 -0
- package/lib/components/input/SelectWrapper/SelectWrapper.d.ts +2 -0
- package/lib/components/input/SelectWrapper/SelectWrapper.props.d.ts +32 -0
- package/lib/components/input/SelectWrapper/components/SelectWrapperPortal/SelectWrapperPortal.d.ts +10 -0
- package/lib/components/input/SelectWrapper/components/SelectWrapperValue/SelectWrapperValue.d.ts +7 -0
- package/lib/components/input/SelectWrapper/index.d.ts +2 -0
- package/lib/components/input/components/inputInner/InputInner.css.d.ts +92 -0
- package/lib/components/input/components/inputInner/InputInner.d.ts +2 -0
- package/lib/components/input/components/inputInner/inputInner.props.d.ts +11 -0
- package/lib/components/input/index.d.ts +1 -0
- package/lib/components/modal/Drawer/Drawer.css.d.ts +34 -0
- package/lib/components/modal/Drawer/Drawer.d.ts +2 -0
- package/lib/components/modal/Drawer/Drawer.props.d.ts +10 -0
- package/lib/components/modal/Drawer/index.d.ts +2 -0
- package/lib/components/modal/index.d.ts +1 -0
- package/lib/components/other/Cascader/Cascader.css.d.ts +6 -0
- package/lib/components/other/Cascader/Cascader.d.ts +2 -0
- package/lib/components/other/Cascader/Cascader.props.d.ts +17 -0
- package/lib/components/other/Cascader/index.d.ts +2 -0
- package/lib/components/other/index.d.ts +1 -0
- package/lib/index.d.ts +2 -0
- package/lib/theme/common/common.css.d.ts +1 -0
- package/lib/theme/common/motion.d.ts +0 -0
- package/lib/theme/contract/colorContract.css.d.ts +8 -0
- package/lib/theme/contract/themeContract.css.d.ts +134 -0
- package/lib/theme/index.d.ts +8 -0
- package/lib/theme/provider/ThemeProvider.d.ts +9 -0
- package/lib/theme/token/contract.d.ts +169 -0
- package/lib/theme/token/tokenMap.d.ts +90 -0
- package/lib/theme/token/tokenSetup.d.ts +85 -0
- package/lib/theme/types/token.d.ts +41 -0
- package/lib/theme/utils/color.d.ts +37 -0
- package/lib/theme/utils/contract.d.ts +2 -0
- package/lib/theme/utils/token.d.ts +19 -0
- package/package.json +5 -5
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
.zid_list_container-1s0suq30 {
|
|
2
|
+
box-sizing: border-box;
|
|
3
|
+
width: 100%;
|
|
4
|
+
height: 100%;
|
|
5
|
+
}
|
|
6
|
+
.zid_list_item-1s0suq31 {
|
|
7
|
+
box-sizing: border-box;
|
|
8
|
+
width: 100%;
|
|
9
|
+
}
|
|
10
|
+
.zid_list_content-1s0suq32 {
|
|
11
|
+
box-sizing: border-box;
|
|
12
|
+
width: 100%;
|
|
13
|
+
}
|
|
14
|
+
.zid_list_item_place-1s0suq33 {
|
|
15
|
+
display: flex;
|
|
16
|
+
justify-content: center;
|
|
17
|
+
align-items: center;
|
|
18
|
+
gap: 8px;
|
|
19
|
+
font-size: 14px;
|
|
20
|
+
}
|
|
21
|
+
.zid_list_content_place-1s0suq34 {
|
|
22
|
+
display: flex;
|
|
23
|
+
flex-direction: column;
|
|
24
|
+
justify-content: center;
|
|
25
|
+
align-items: center;
|
|
26
|
+
gap: 12px;
|
|
27
|
+
}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
.zid_button-18fc240a {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
position: relative;
|
|
6
|
+
box-sizing: border-box;
|
|
7
|
+
border: 1px solid var(--zid_borderColor-18fc2400);
|
|
8
|
+
gap: var(--zid_contentGap-18fc2408, 8px);
|
|
9
|
+
transition: all 0.15s;
|
|
10
|
+
color: var(--zid_contentColor-18fc2401);
|
|
11
|
+
background-color: var(--zid_backgroundColor-18fc2402);
|
|
12
|
+
}
|
|
13
|
+
.zid_button-18fc240a:hover {
|
|
14
|
+
cursor: pointer;
|
|
15
|
+
}
|
|
16
|
+
.zid_button-18fc240a:active {
|
|
17
|
+
transform: scale(0.95);
|
|
18
|
+
}
|
|
19
|
+
.zid_button-18fc240a::before {
|
|
20
|
+
content: "";
|
|
21
|
+
position: absolute;
|
|
22
|
+
inset: -1px;
|
|
23
|
+
border-radius: var(--zid_borderRadius-18fc2409);
|
|
24
|
+
background-color: var(--zid_stateLayerColor-18fc2403);
|
|
25
|
+
}
|
|
26
|
+
.zid_button_color_primary-18fc240b {
|
|
27
|
+
--zid_main-1o0swjg0: var(--sys-color-primary-main);
|
|
28
|
+
--zid_onMain-1o0swjg1: var(--sys-color-primary-on-main);
|
|
29
|
+
--zid_container-1o0swjg2: var(--sys-color-primary-container);
|
|
30
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-primary-on-container);
|
|
31
|
+
}
|
|
32
|
+
.zid_button_color_secondary-18fc240c {
|
|
33
|
+
--zid_main-1o0swjg0: var(--sys-color-secondary-main);
|
|
34
|
+
--zid_onMain-1o0swjg1: var(--sys-color-secondary-on-main);
|
|
35
|
+
--zid_container-1o0swjg2: var(--sys-color-secondary-container);
|
|
36
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-secondary-on-container);
|
|
37
|
+
}
|
|
38
|
+
.zid_button_color_tertiary-18fc240d {
|
|
39
|
+
--zid_main-1o0swjg0: var(--sys-color-tertiary-main);
|
|
40
|
+
--zid_onMain-1o0swjg1: var(--sys-color-tertiary-on-main);
|
|
41
|
+
--zid_container-1o0swjg2: var(--sys-color-tertiary-container);
|
|
42
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-tertiary-on-container);
|
|
43
|
+
}
|
|
44
|
+
.zid_button_color_info-18fc240e {
|
|
45
|
+
--zid_main-1o0swjg0: var(--sys-color-info-main);
|
|
46
|
+
--zid_onMain-1o0swjg1: var(--sys-color-info-on-main);
|
|
47
|
+
--zid_container-1o0swjg2: var(--sys-color-info-container);
|
|
48
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-info-on-container);
|
|
49
|
+
}
|
|
50
|
+
.zid_button_color_error-18fc240f {
|
|
51
|
+
--zid_main-1o0swjg0: var(--sys-color-error-main);
|
|
52
|
+
--zid_onMain-1o0swjg1: var(--sys-color-error-on-main);
|
|
53
|
+
--zid_container-1o0swjg2: var(--sys-color-error-container);
|
|
54
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-error-on-container);
|
|
55
|
+
}
|
|
56
|
+
.zid_button_color_warning-18fc240g {
|
|
57
|
+
--zid_main-1o0swjg0: var(--sys-color-warning-main);
|
|
58
|
+
--zid_onMain-1o0swjg1: var(--sys-color-warning-on-main);
|
|
59
|
+
--zid_container-1o0swjg2: var(--sys-color-warning-container);
|
|
60
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-warning-on-container);
|
|
61
|
+
}
|
|
62
|
+
.zid_button_color_success-18fc240h {
|
|
63
|
+
--zid_main-1o0swjg0: var(--sys-color-success-main);
|
|
64
|
+
--zid_onMain-1o0swjg1: var(--sys-color-success-on-main);
|
|
65
|
+
--zid_container-1o0swjg2: var(--sys-color-success-container);
|
|
66
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-success-on-container);
|
|
67
|
+
}
|
|
68
|
+
.zid_button_size_small-18fc240i {
|
|
69
|
+
--zid_minHeight-18fc2407: 24px;
|
|
70
|
+
--zid_paddingX-18fc2405: var(--sys-spacing-content-sm);
|
|
71
|
+
--zid_paddingY-18fc2406: var(--sys-spacing-content-xs);
|
|
72
|
+
--zid_fontSize-18fc2404: var(--sys-font-size-title-xs);
|
|
73
|
+
min-height: var(--zid_minHeight-18fc2407);
|
|
74
|
+
padding-inline: var(--zid_paddingX-18fc2405);
|
|
75
|
+
padding-block: var(--zid_paddingY-18fc2406);
|
|
76
|
+
font-size: var(--zid_fontSize-18fc2404);
|
|
77
|
+
}
|
|
78
|
+
.zid_button_size_normal-18fc240j {
|
|
79
|
+
--zid_minHeight-18fc2407: 24px;
|
|
80
|
+
--zid_paddingX-18fc2405: var(--sys-spacing-content-md);
|
|
81
|
+
--zid_paddingY-18fc2406: var(--sys-spacing-content-xs);
|
|
82
|
+
--zid_fontSize-18fc2404: var(--sys-font-size-label-sm);
|
|
83
|
+
min-height: var(--zid_minHeight-18fc2407);
|
|
84
|
+
padding-inline: var(--zid_paddingX-18fc2405);
|
|
85
|
+
padding-block: var(--zid_paddingY-18fc2406);
|
|
86
|
+
font-size: var(--zid_fontSize-18fc2404);
|
|
87
|
+
}
|
|
88
|
+
.zid_button_size_full-18fc240k {
|
|
89
|
+
--zid_paddingX-18fc2405: var(--sys-spacing-content-sm);
|
|
90
|
+
--zid_paddingY-18fc2406: var(--sys-spacing-content-xs);
|
|
91
|
+
--zid_fontSize-18fc2404: var(--sys-font-size-label-md);
|
|
92
|
+
min-height: var(--zid_minHeight-18fc2407);
|
|
93
|
+
padding-inline: var(--zid_paddingX-18fc2405);
|
|
94
|
+
padding-block: var(--zid_paddingY-18fc2406);
|
|
95
|
+
font-size: var(--zid_fontSize-18fc2404);
|
|
96
|
+
width: 100%;
|
|
97
|
+
}
|
|
98
|
+
.zid_button_shape_round-18fc240l {
|
|
99
|
+
--zid_borderRadius-18fc2409: var(--sys-radius-full);
|
|
100
|
+
border-radius: var(--zid_borderRadius-18fc2409);
|
|
101
|
+
}
|
|
102
|
+
.zid_button_shape_square-18fc240m {
|
|
103
|
+
--zid_borderRadius-18fc2409: var(--sys-radius-sm);
|
|
104
|
+
border-radius: var(--zid_borderRadius-18fc2409);
|
|
105
|
+
}
|
|
106
|
+
.zid_button_variant_filled-18fc240n {
|
|
107
|
+
--zid_contentColor-18fc2401: var(--zid_onMain-1o0swjg1);
|
|
108
|
+
--zid_backgroundColor-18fc2402: var(--zid_main-1o0swjg0);
|
|
109
|
+
}
|
|
110
|
+
.zid_button_variant_filled-18fc240n:hover::before {
|
|
111
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_onMain-1o0swjg1) 8%, transparent);
|
|
112
|
+
}
|
|
113
|
+
.zid_button_variant_filled-18fc240n:active::before {
|
|
114
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_onMain-1o0swjg1) 12%, transparent);
|
|
115
|
+
}
|
|
116
|
+
.zid_button_variant_tonal-18fc240o {
|
|
117
|
+
--zid_contentColor-18fc2401: var(--zid_onContainer-1o0swjg3);
|
|
118
|
+
--zid_backgroundColor-18fc2402: var(--zid_container-1o0swjg2);
|
|
119
|
+
}
|
|
120
|
+
.zid_button_variant_tonal-18fc240o:hover::before {
|
|
121
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_onContainer-1o0swjg3) 8%, transparent);
|
|
122
|
+
}
|
|
123
|
+
.zid_button_variant_tonal-18fc240o:active::before {
|
|
124
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_onContainer-1o0swjg3) 12%, transparent);
|
|
125
|
+
}
|
|
126
|
+
.zid_button_variant_outlined-18fc240p {
|
|
127
|
+
--zid_contentColor-18fc2401: var(--zid_main-1o0swjg0);
|
|
128
|
+
--zid_borderColor-18fc2400: var(--zid_main-1o0swjg0);
|
|
129
|
+
}
|
|
130
|
+
.zid_button_variant_outlined-18fc240p:hover::before {
|
|
131
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_main-1o0swjg0) 8%, transparent);
|
|
132
|
+
}
|
|
133
|
+
.zid_button_variant_outlined-18fc240p:active::before {
|
|
134
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_main-1o0swjg0) 12%, transparent);
|
|
135
|
+
}
|
|
136
|
+
.zid_button_variant_plain-18fc240q {
|
|
137
|
+
--zid_contentColor-18fc2401: var(--zid_main-1o0swjg0);
|
|
138
|
+
}
|
|
139
|
+
.zid_button_variant_plain-18fc240q:hover::before {
|
|
140
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_main-1o0swjg0) 8%, transparent);
|
|
141
|
+
}
|
|
142
|
+
.zid_button_variant_plain-18fc240q:active::before {
|
|
143
|
+
--zid_stateLayerColor-18fc2403: color-mix(in srgb, var(--zid_main-1o0swjg0) 12%, transparent);
|
|
144
|
+
}
|
|
145
|
+
.zid_button_disabled_true-18fc240r {
|
|
146
|
+
cursor: not-allowed;
|
|
147
|
+
pointer-events: none;
|
|
148
|
+
background-color: color-mix(in srgb, var(--sys-color-surface-on-main) 12%, transparent);
|
|
149
|
+
}
|
|
150
|
+
.zid_button_loading_true-18fc240s {
|
|
151
|
+
cursor: wait;
|
|
152
|
+
pointer-events: none;
|
|
153
|
+
color: transparent !important;
|
|
154
|
+
}
|
|
155
|
+
.zid_button_compound_0-18fc240t {
|
|
156
|
+
color: color-mix(in srgb, var(--sys-color-surface-on-main) 45%, transparent) !important;
|
|
157
|
+
background-color: color-mix(in srgb, var(--sys-color-surface-on-main) 16%, transparent) !important;
|
|
158
|
+
}
|
|
159
|
+
.zid_button_compound_1-18fc240u {
|
|
160
|
+
color: color-mix(in srgb, var(--sys-color-surface-on-main) 32%, transparent) !important;
|
|
161
|
+
background-color: color-mix(in srgb, var(--sys-color-surface-on-main) 10%, transparent) !important;
|
|
162
|
+
}
|
|
163
|
+
.zid_button_compound_2-18fc240v {
|
|
164
|
+
background-color: transparent !important;
|
|
165
|
+
color: color-mix(in srgb, var(--sys-color-surface-on-main) 32%, transparent) !important;
|
|
166
|
+
border: 1px solid color-mix(in srgb, var(--sys-color-surface-on-main) 12%, transparent) !important;
|
|
167
|
+
}
|
|
168
|
+
.zid_button_compound_3-18fc240w {
|
|
169
|
+
color: color-mix(in srgb, var(--sys-color-surface-on-main) 32%, transparent) !important;
|
|
170
|
+
background-color: color-mix(in srgb, var(--sys-color-surface-on-main) 2%, transparent) !important;
|
|
171
|
+
}
|
|
172
|
+
.zid_button_compound_4-18fc240x {
|
|
173
|
+
background-color: color-mix(in srgb, var(--zid_main-1o0swjg0) 80%, transparent) !important;
|
|
174
|
+
}
|
|
175
|
+
.zid_button_compound_5-18fc240y {
|
|
176
|
+
background-color: color-mix(in srgb, var(--zid_container-1o0swjg2) 80%, transparent) !important;
|
|
177
|
+
}
|
|
178
|
+
.zid_button_compound_6-18fc240z {
|
|
179
|
+
border: 1px solid color-mix(in srgb, var(--zid_main-1o0swjg0) 80%, transparent) !important;
|
|
180
|
+
}
|
|
181
|
+
.zid_button_compound_7-18fc24010 {
|
|
182
|
+
background-color: color-mix(in srgb, var(--zid_main-1o0swjg0) 2%, transparent) !important;
|
|
183
|
+
}
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
.zid_tag-1vfb55ba {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
position: relative;
|
|
6
|
+
box-sizing: border-box;
|
|
7
|
+
outline: 1px solid var(--zid_borderColor-1vfb55b0);
|
|
8
|
+
outline-offset: -1px;
|
|
9
|
+
gap: var(--zid_contentGap-1vfb55b8, 8px);
|
|
10
|
+
transition: all 0.15s;
|
|
11
|
+
line-height: 1;
|
|
12
|
+
color: var(--zid_contentColor-1vfb55b1);
|
|
13
|
+
background-color: var(--zid_backgroundColor-1vfb55b2);
|
|
14
|
+
}
|
|
15
|
+
.zid_tag-1vfb55ba::before {
|
|
16
|
+
content: "";
|
|
17
|
+
position: absolute;
|
|
18
|
+
inset: -1px;
|
|
19
|
+
border-radius: var(--zid_borderRadius-1vfb55b9);
|
|
20
|
+
background-color: var(--zid_stateLayerColor-1vfb55b3);
|
|
21
|
+
}
|
|
22
|
+
.zid_tag_color_primary-1vfb55bb {
|
|
23
|
+
--zid_main-1o0swjg0: var(--sys-color-primary-main);
|
|
24
|
+
--zid_onMain-1o0swjg1: var(--sys-color-primary-on-main);
|
|
25
|
+
--zid_container-1o0swjg2: var(--sys-color-primary-container);
|
|
26
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-primary-on-container);
|
|
27
|
+
}
|
|
28
|
+
.zid_tag_color_secondary-1vfb55bc {
|
|
29
|
+
--zid_main-1o0swjg0: var(--sys-color-secondary-main);
|
|
30
|
+
--zid_onMain-1o0swjg1: var(--sys-color-secondary-on-main);
|
|
31
|
+
--zid_container-1o0swjg2: var(--sys-color-secondary-container);
|
|
32
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-secondary-on-container);
|
|
33
|
+
}
|
|
34
|
+
.zid_tag_color_tertiary-1vfb55bd {
|
|
35
|
+
--zid_main-1o0swjg0: var(--sys-color-tertiary-main);
|
|
36
|
+
--zid_onMain-1o0swjg1: var(--sys-color-tertiary-on-main);
|
|
37
|
+
--zid_container-1o0swjg2: var(--sys-color-tertiary-container);
|
|
38
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-tertiary-on-container);
|
|
39
|
+
}
|
|
40
|
+
.zid_tag_color_info-1vfb55be {
|
|
41
|
+
--zid_main-1o0swjg0: var(--sys-color-info-main);
|
|
42
|
+
--zid_onMain-1o0swjg1: var(--sys-color-info-on-main);
|
|
43
|
+
--zid_container-1o0swjg2: var(--sys-color-info-container);
|
|
44
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-info-on-container);
|
|
45
|
+
}
|
|
46
|
+
.zid_tag_color_error-1vfb55bf {
|
|
47
|
+
--zid_main-1o0swjg0: var(--sys-color-error-main);
|
|
48
|
+
--zid_onMain-1o0swjg1: var(--sys-color-error-on-main);
|
|
49
|
+
--zid_container-1o0swjg2: var(--sys-color-error-container);
|
|
50
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-error-on-container);
|
|
51
|
+
}
|
|
52
|
+
.zid_tag_color_warning-1vfb55bg {
|
|
53
|
+
--zid_main-1o0swjg0: var(--sys-color-warning-main);
|
|
54
|
+
--zid_onMain-1o0swjg1: var(--sys-color-warning-on-main);
|
|
55
|
+
--zid_container-1o0swjg2: var(--sys-color-warning-container);
|
|
56
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-warning-on-container);
|
|
57
|
+
}
|
|
58
|
+
.zid_tag_color_success-1vfb55bh {
|
|
59
|
+
--zid_main-1o0swjg0: var(--sys-color-success-main);
|
|
60
|
+
--zid_onMain-1o0swjg1: var(--sys-color-success-on-main);
|
|
61
|
+
--zid_container-1o0swjg2: var(--sys-color-success-container);
|
|
62
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-success-on-container);
|
|
63
|
+
}
|
|
64
|
+
.zid_tag_variant_filled-1vfb55bi {
|
|
65
|
+
--zid_contentColor-1vfb55b1: var(--zid_onMain-1o0swjg1, var(--sys-color-surface-main));
|
|
66
|
+
--zid_backgroundColor-1vfb55b2: var(--zid_main-1o0swjg0, var(--sys-color-surface-on-main));
|
|
67
|
+
}
|
|
68
|
+
.zid_tag_variant_tonal-1vfb55bj {
|
|
69
|
+
--zid_contentColor-1vfb55b1: var(--zid_onContainer-1o0swjg3, var(--sys-color-surface-container));
|
|
70
|
+
--zid_backgroundColor-1vfb55b2: var(--zid_container-1o0swjg2, var(--sys-color-outline-on-surface-variant));
|
|
71
|
+
}
|
|
72
|
+
.zid_tag_variant_outlined-1vfb55bk {
|
|
73
|
+
--zid_contentColor-1vfb55b1: var(--zid_main-1o0swjg0, var(--sys-color-surface-on-main));
|
|
74
|
+
--zid_borderColor-1vfb55b0: var(--zid_main-1o0swjg0, var(--sys-color-surface-on-main));
|
|
75
|
+
}
|
|
76
|
+
.zid_tag_variant_plain-1vfb55bl {
|
|
77
|
+
--zid_contentColor-1vfb55b1: var(--zid_main-1o0swjg0, var(--sys-color-surface-on-main));
|
|
78
|
+
--zid_backgroundColor-1vfb55b2: color-mix(in srgb, var(--zid_main-1o0swjg0, var(--sys-color-surface-on-main)) 12%, transparent);
|
|
79
|
+
}
|
|
80
|
+
.zid_tag_size_small-1vfb55bm {
|
|
81
|
+
--zid_paddingX-1vfb55b5: var(--sys-spacing-content-xs);
|
|
82
|
+
--zid_paddingY-1vfb55b6: var(--sys-spacing-content-xs);
|
|
83
|
+
--zid_fontSize-1vfb55b4: var(--sys-font-size-label-xs);
|
|
84
|
+
padding-inline: var(--zid_paddingX-1vfb55b5);
|
|
85
|
+
padding-block: var(--zid_paddingY-1vfb55b6);
|
|
86
|
+
font-size: var(--zid_fontSize-1vfb55b4);
|
|
87
|
+
}
|
|
88
|
+
.zid_tag_size_normal-1vfb55bn {
|
|
89
|
+
--zid_paddingX-1vfb55b5: var(--sys-spacing-content-sm);
|
|
90
|
+
--zid_paddingY-1vfb55b6: calc(var(--sys-spacing-content-xs) + 1px);
|
|
91
|
+
--zid_fontSize-1vfb55b4: var(--sys-font-size-label-sm);
|
|
92
|
+
padding-inline: var(--zid_paddingX-1vfb55b5);
|
|
93
|
+
padding-block: var(--zid_paddingY-1vfb55b6);
|
|
94
|
+
font-size: var(--zid_fontSize-1vfb55b4);
|
|
95
|
+
}
|
|
96
|
+
.zid_tag_shape_round-1vfb55bo {
|
|
97
|
+
--zid_borderRadius-1vfb55b9: var(--sys-radius-full);
|
|
98
|
+
border-radius: var(--zid_borderRadius-1vfb55b9);
|
|
99
|
+
}
|
|
100
|
+
.zid_tag_shape_square-1vfb55bp {
|
|
101
|
+
--zid_borderRadius-1vfb55b9: var(--sys-radius-sm);
|
|
102
|
+
border-radius: var(--zid_borderRadius-1vfb55b9);
|
|
103
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
.zid_select_wrapper_trigger-122uq9w0 {
|
|
2
|
+
cursor: pointer;
|
|
3
|
+
min-width: 200px;
|
|
4
|
+
}
|
|
5
|
+
.zid_select_wrapper_trigger-122uq9w0[data-placeholder] {
|
|
6
|
+
font-weight: var(--sys-font-weight-light);
|
|
7
|
+
color: var(--sys-color-outline-main);
|
|
8
|
+
}
|
|
9
|
+
.zid_select_wrapper_content-122uq9w1 {
|
|
10
|
+
border-radius: var(--sys-radius-sm);
|
|
11
|
+
padding: var(--sys-spacing-content-sm);
|
|
12
|
+
background-color: var(--sys-color-surface-container);
|
|
13
|
+
width: var(--radix-popover-trigger-width);
|
|
14
|
+
box-sizing: border-box;
|
|
15
|
+
min-height: 125px;
|
|
16
|
+
max-height: var(--radix-popover-content-available-height);
|
|
17
|
+
}
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
.zid_inner_content-18l8twl0 {
|
|
2
|
+
flex: 1;
|
|
3
|
+
line-height: 1;
|
|
4
|
+
}
|
|
5
|
+
.zid_inner_fix-18l8twl1 {
|
|
6
|
+
display: flex;
|
|
7
|
+
align-items: center;
|
|
8
|
+
justify-content: center;
|
|
9
|
+
height: 100%;
|
|
10
|
+
}
|
|
11
|
+
.zid_inner_fix-18l8twl1 > * {
|
|
12
|
+
height: 100%;
|
|
13
|
+
width: 100%;
|
|
14
|
+
}
|
|
15
|
+
.zid_input_inner-18l8twld {
|
|
16
|
+
display: flex;
|
|
17
|
+
align-items: center;
|
|
18
|
+
position: relative;
|
|
19
|
+
gap: var(--zid_contentGap-18l8twl4);
|
|
20
|
+
border: 1px solid var(--zid_borderColor-18l8twl2);
|
|
21
|
+
box-shadow: var(--zid_boxShadow-18l8twl7);
|
|
22
|
+
font-size: var(--zid_fontSize-18l8twl8);
|
|
23
|
+
height: var(--zid_height-18l8twlb);
|
|
24
|
+
padding-inline: var(--zid_paddingX-18l8twl9);
|
|
25
|
+
padding-block: var(--zid_paddingY-18l8twla);
|
|
26
|
+
border-radius: var(--zid_borderRadius-18l8twlc);
|
|
27
|
+
color: var(--zid_contentColor-18l8twl3);
|
|
28
|
+
background-color: var(--zid_backgroundColor-18l8twl5);
|
|
29
|
+
transition: all 0.15s ease-in-out;
|
|
30
|
+
}
|
|
31
|
+
.zid_input_inner-18l8twld:focus-within, .zid_input_inner-18l8twld[data-state="open"] {
|
|
32
|
+
--zid_boxShadow-18l8twl7: 0 0 6px 3px color-mix(in srgb, var(--zid_main-1o0swjg0) 20%, transparent);
|
|
33
|
+
outline: none;
|
|
34
|
+
border-color: var(--zid_main-1o0swjg0);
|
|
35
|
+
}
|
|
36
|
+
.zid_input_inner-18l8twld:where([data-placeholder]), .zid_input_inner-18l8twld:where(:has(input:placeholder-shown)) {
|
|
37
|
+
--zid_contentColor-18l8twl3: var(--zid_placeholderColor-18l8twl6, var(--sys-color-outline-variant));
|
|
38
|
+
}
|
|
39
|
+
.zid_input_inner-18l8twld:disabled {
|
|
40
|
+
cursor: not-allowed;
|
|
41
|
+
background-color: color-mix(in srgb, var(--sys-color-surface-on-main) 12%, transparent);
|
|
42
|
+
color: color-mix(in srgb, var(--sys-color-surface-on-main) 45%, transparent);
|
|
43
|
+
}
|
|
44
|
+
.zid_input_inner_color_primary-18l8twle {
|
|
45
|
+
--zid_main-1o0swjg0: var(--sys-color-primary-main);
|
|
46
|
+
--zid_onMain-1o0swjg1: var(--sys-color-primary-on-main);
|
|
47
|
+
--zid_container-1o0swjg2: var(--sys-color-primary-container);
|
|
48
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-primary-on-container);
|
|
49
|
+
}
|
|
50
|
+
.zid_input_inner_color_secondary-18l8twlf {
|
|
51
|
+
--zid_main-1o0swjg0: var(--sys-color-secondary-main);
|
|
52
|
+
--zid_onMain-1o0swjg1: var(--sys-color-secondary-on-main);
|
|
53
|
+
--zid_container-1o0swjg2: var(--sys-color-secondary-container);
|
|
54
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-secondary-on-container);
|
|
55
|
+
}
|
|
56
|
+
.zid_input_inner_color_tertiary-18l8twlg {
|
|
57
|
+
--zid_main-1o0swjg0: var(--sys-color-tertiary-main);
|
|
58
|
+
--zid_onMain-1o0swjg1: var(--sys-color-tertiary-on-main);
|
|
59
|
+
--zid_container-1o0swjg2: var(--sys-color-tertiary-container);
|
|
60
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-tertiary-on-container);
|
|
61
|
+
}
|
|
62
|
+
.zid_input_inner_color_info-18l8twlh {
|
|
63
|
+
--zid_main-1o0swjg0: var(--sys-color-info-main);
|
|
64
|
+
--zid_onMain-1o0swjg1: var(--sys-color-info-on-main);
|
|
65
|
+
--zid_container-1o0swjg2: var(--sys-color-info-container);
|
|
66
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-info-on-container);
|
|
67
|
+
}
|
|
68
|
+
.zid_input_inner_color_error-18l8twli {
|
|
69
|
+
--zid_main-1o0swjg0: var(--sys-color-error-main);
|
|
70
|
+
--zid_onMain-1o0swjg1: var(--sys-color-error-on-main);
|
|
71
|
+
--zid_container-1o0swjg2: var(--sys-color-error-container);
|
|
72
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-error-on-container);
|
|
73
|
+
}
|
|
74
|
+
.zid_input_inner_color_warning-18l8twlj {
|
|
75
|
+
--zid_main-1o0swjg0: var(--sys-color-warning-main);
|
|
76
|
+
--zid_onMain-1o0swjg1: var(--sys-color-warning-on-main);
|
|
77
|
+
--zid_container-1o0swjg2: var(--sys-color-warning-container);
|
|
78
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-warning-on-container);
|
|
79
|
+
}
|
|
80
|
+
.zid_input_inner_color_success-18l8twlk {
|
|
81
|
+
--zid_main-1o0swjg0: var(--sys-color-success-main);
|
|
82
|
+
--zid_onMain-1o0swjg1: var(--sys-color-success-on-main);
|
|
83
|
+
--zid_container-1o0swjg2: var(--sys-color-success-container);
|
|
84
|
+
--zid_onContainer-1o0swjg3: var(--sys-color-success-on-container);
|
|
85
|
+
}
|
|
86
|
+
.zid_input_inner_variant_filled-18l8twll {
|
|
87
|
+
--zid_contentColor-18l8twl3: var(--sys-color-surface-on-main);
|
|
88
|
+
--zid_backgroundColor-18l8twl5: var(--sys-color-outline-variant);
|
|
89
|
+
--zid_borderColor-18l8twl2: transparent;
|
|
90
|
+
--zid_placeholderColor-18l8twl6: var(--sys-color-outline-on-surface-variant);
|
|
91
|
+
}
|
|
92
|
+
.zid_input_inner_variant_filled-18l8twll:focus-within, .zid_input_inner_variant_filled-18l8twll[data-state="open"] {
|
|
93
|
+
background-color: transparent;
|
|
94
|
+
}
|
|
95
|
+
.zid_input_inner_variant_outlined-18l8twlm {
|
|
96
|
+
--zid_contentColor-18l8twl3: var(--sys-color-surface-on-main);
|
|
97
|
+
--zid_backgroundColor-18l8twl5: transparent;
|
|
98
|
+
--zid_borderColor-18l8twl2: var(--sys-color-outline-main);
|
|
99
|
+
}
|
|
100
|
+
.zid_input_inner_variant_styleLess-18l8twln {
|
|
101
|
+
--zid_contentColor-18l8twl3: var(--zid_main-1o0swjg0);
|
|
102
|
+
--zid_placeholderColor-18l8twl6: color-mix(in srgb, var(--zid_main-1o0swjg0) 60%, transparent);
|
|
103
|
+
border: none;
|
|
104
|
+
background-color: transparent;
|
|
105
|
+
}
|
|
106
|
+
.zid_input_inner_variant_styleLess-18l8twln:focus-within, .zid_input_inner_variant_styleLess-18l8twln[data-state="open"] {
|
|
107
|
+
--zid_boxShadow-18l8twl7: none;
|
|
108
|
+
background-color: transparent;
|
|
109
|
+
}
|
|
110
|
+
.zid_input_inner_size_small-18l8twlo {
|
|
111
|
+
--zid_height-18l8twlb: 28px;
|
|
112
|
+
--zid_contentGap-18l8twl4: 4px;
|
|
113
|
+
--zid_paddingX-18l8twl9: calc(var(--sys-spacing-content-sm) - 2px);
|
|
114
|
+
--zid_paddingY-18l8twla: var(--sys-spacing-content-xs);
|
|
115
|
+
--zid_fontSize-18l8twl8: var(--sys-font-size-label-sm);
|
|
116
|
+
min-height: var(--zid_height-18l8twlb);
|
|
117
|
+
padding-inline: var(--zid_paddingX-18l8twl9);
|
|
118
|
+
padding-block: var(--zid_paddingY-18l8twla);
|
|
119
|
+
font-size: var(--zid_fontSize-18l8twl8);
|
|
120
|
+
}
|
|
121
|
+
.zid_input_inner_size_normal-18l8twlp {
|
|
122
|
+
--zid_height-18l8twlb: 32px;
|
|
123
|
+
--zid_contentGap-18l8twl4: 4px;
|
|
124
|
+
--zid_paddingX-18l8twl9: var(--sys-spacing-content-sm);
|
|
125
|
+
--zid_paddingY-18l8twla: var(--sys-spacing-content-xs);
|
|
126
|
+
--zid_fontSize-18l8twl8: var(--sys-font-size-label-md);
|
|
127
|
+
min-height: var(--zid_height-18l8twlb);
|
|
128
|
+
padding-inline: var(--zid_paddingX-18l8twl9);
|
|
129
|
+
padding-block: var(--zid_paddingY-18l8twla);
|
|
130
|
+
font-size: var(--zid_fontSize-18l8twl8);
|
|
131
|
+
}
|
|
132
|
+
.zid_input_inner_size_large-18l8twlq {
|
|
133
|
+
--zid_height-18l8twlb: 40px;
|
|
134
|
+
--zid_contentGap-18l8twl4: 8px;
|
|
135
|
+
--zid_paddingX-18l8twl9: var(--sys-spacing-content-md);
|
|
136
|
+
--zid_paddingY-18l8twla: var(--sys-spacing-content-sm);
|
|
137
|
+
--zid_fontSize-18l8twl8: var(--sys-font-size-label-lg);
|
|
138
|
+
min-height: var(--zid_height-18l8twlb);
|
|
139
|
+
padding-inline: var(--zid_paddingX-18l8twl9);
|
|
140
|
+
padding-block: var(--zid_paddingY-18l8twla);
|
|
141
|
+
font-size: var(--zid_fontSize-18l8twl8);
|
|
142
|
+
}
|
|
143
|
+
.zid_input_inner_shape_round-18l8twlr {
|
|
144
|
+
--zid_borderRadius-18l8twlc: var(--sys-radius-full);
|
|
145
|
+
border-radius: var(--zid_borderRadius-18l8twlc);
|
|
146
|
+
}
|
|
147
|
+
.zid_input_inner_shape_square-18l8twls {
|
|
148
|
+
--zid_borderRadius-18l8twlc: var(--sys-radius-sm);
|
|
149
|
+
border-radius: var(--zid_borderRadius-18l8twlc);
|
|
150
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
.zid_drawer_overlay-16cbf8f1 {
|
|
2
|
+
position: fixed;
|
|
3
|
+
inset: 0;
|
|
4
|
+
z-index: calc(var(--drawer-level, 0) * 100 + 1000);
|
|
5
|
+
background-color: color-mix(in srgb, var(--sys-color-elevation-scrim) 60%, transparent);
|
|
6
|
+
backdrop-filter: blur(3px) saturate(100%);
|
|
7
|
+
-webkit-backdrop-filter: blur(3px) saturate(100%);
|
|
8
|
+
}
|
|
9
|
+
.zid_drawer-16cbf8f2 {
|
|
10
|
+
background-color: var(--sys-color-surface-main);
|
|
11
|
+
box-shadow: 0 4px 6px -1px var(--sys-color-elevation-shadow), 0 2px 4px -1px var(--sys-color-elevation-shadow);
|
|
12
|
+
position: fixed;
|
|
13
|
+
z-index: calc(var(--drawer-level, 0) * 100 + 1001);
|
|
14
|
+
display: flex;
|
|
15
|
+
flex-direction: column;
|
|
16
|
+
max-height: 100vh;
|
|
17
|
+
max-width: 100vw;
|
|
18
|
+
overflow: auto;
|
|
19
|
+
}
|
|
20
|
+
.zid_drawer_position_left-16cbf8f3 {
|
|
21
|
+
top: 0;
|
|
22
|
+
left: 0;
|
|
23
|
+
height: 100vh;
|
|
24
|
+
width: var(--zid_contentRatio-16cbf8f0);
|
|
25
|
+
}
|
|
26
|
+
.zid_drawer_position_right-16cbf8f4 {
|
|
27
|
+
top: 0;
|
|
28
|
+
right: 0;
|
|
29
|
+
height: 100vh;
|
|
30
|
+
width: var(--zid_contentRatio-16cbf8f0);
|
|
31
|
+
}
|
|
32
|
+
.zid_drawer_position_top-16cbf8f5 {
|
|
33
|
+
top: 0;
|
|
34
|
+
left: 0;
|
|
35
|
+
right: 0;
|
|
36
|
+
height: var(--zid_contentRatio-16cbf8f0);
|
|
37
|
+
width: 100%;
|
|
38
|
+
}
|
|
39
|
+
.zid_drawer_position_bottom-16cbf8f6 {
|
|
40
|
+
bottom: 0;
|
|
41
|
+
left: 0;
|
|
42
|
+
right: 0;
|
|
43
|
+
height: var(--zid_contentRatio-16cbf8f0);
|
|
44
|
+
width: 100%;
|
|
45
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
.zid_cascader_container-gs5grl0 {
|
|
2
|
+
display: flex;
|
|
3
|
+
align-items: flex-start;
|
|
4
|
+
justify-content: center;
|
|
5
|
+
width: 100%;
|
|
6
|
+
}
|
|
7
|
+
.zid_cascader_column-gs5grl1 {
|
|
8
|
+
flex: 1 0 0;
|
|
9
|
+
position: relative;
|
|
10
|
+
box-sizing: border-box;
|
|
11
|
+
border-right: 1px solid var(--sys-color-surface-container-high);
|
|
12
|
+
overflow-y: auto;
|
|
13
|
+
}
|
|
14
|
+
.zid_cascader_column-gs5grl1:last-child {
|
|
15
|
+
border-right: none;
|
|
16
|
+
}
|
|
17
|
+
.zid_cascader_panel-gs5grl2 {
|
|
18
|
+
position: relative;
|
|
19
|
+
box-sizing: border-box;
|
|
20
|
+
}
|
|
21
|
+
.zid_cascader_panel_indicator-gs5grl3 {
|
|
22
|
+
width: 100%;
|
|
23
|
+
top: 0px;
|
|
24
|
+
position: absolute;
|
|
25
|
+
background-color: var(--sys-color-surface-container);
|
|
26
|
+
transition: all 0.2s ease-in-out;
|
|
27
|
+
z-index: -1;
|
|
28
|
+
}
|
|
29
|
+
.zid_cascader_panel_indicator-gs5grl3::before {
|
|
30
|
+
content: "";
|
|
31
|
+
position: absolute;
|
|
32
|
+
width: var(--sys-spacing-content-xs);
|
|
33
|
+
top: 0;
|
|
34
|
+
left: 0;
|
|
35
|
+
bottom: 0;
|
|
36
|
+
background: var(--sys-color-surface-container-highest);
|
|
37
|
+
}
|
|
38
|
+
.zid_cascader_panel_header-gs5grl4 {
|
|
39
|
+
position: relative;
|
|
40
|
+
box-sizing: border-box;
|
|
41
|
+
padding-block: var(--sys-spacing-content-sm);
|
|
42
|
+
}
|
|
43
|
+
.zid_cascader_node-gs5grl5 {
|
|
44
|
+
padding-block: var(--sys-spacing-content-sm);
|
|
45
|
+
padding-inline: var(--sys-spacing-content-lg);
|
|
46
|
+
display: flex;
|
|
47
|
+
align-items: flex-start;
|
|
48
|
+
justify-content: space-between;
|
|
49
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import './../../../assets/packages/@zidian-ui/core/src/components/collection/List/List.css.ts.vanilla-BeW6Frwm.css';
|
|
2
|
+
|
|
3
|
+
var Container = 'zid_list_container-1s0suq30';
|
|
4
|
+
var Content = 'zid_list_content-1s0suq32';
|
|
5
|
+
var ContentPlace = 'zid_list_content_place-1s0suq34';
|
|
6
|
+
var Item = 'zid_list_item-1s0suq31';
|
|
7
|
+
var ItemPlace = 'zid_list_item_place-1s0suq33';
|
|
8
|
+
|
|
9
|
+
export { Container, Content, ContentPlace, Item, ItemPlace };
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { jsx } from 'react/jsx-runtime';
|
|
2
|
+
import clsx from 'clsx';
|
|
3
|
+
import { forwardRef, useMemo, useCallback } from 'react';
|
|
4
|
+
import { AnimatePresence, motion } from 'motion/react';
|
|
5
|
+
import { Slot, Slottable } from '@radix-ui/react-slot';
|
|
6
|
+
import { Container, ItemPlace, Item, Content, ContentPlace } from './List.css.js';
|
|
7
|
+
import { ListItem, ListContent, ListRoot } from '@zidian-primitive/list';
|
|
8
|
+
import { DefaultItemPlace } from './components/DefaultItemPlace.js';
|
|
9
|
+
import { DefaultContentPlace } from './components/DefaultContentPlace.js';
|
|
10
|
+
|
|
11
|
+
const List = forwardRef((props, ref) => {
|
|
12
|
+
const {
|
|
13
|
+
className,
|
|
14
|
+
itemGap,
|
|
15
|
+
list,
|
|
16
|
+
listStatusState,
|
|
17
|
+
onLoadMore,
|
|
18
|
+
itemSlot,
|
|
19
|
+
itemPlaceSlot,
|
|
20
|
+
contentPlaceSlot,
|
|
21
|
+
...elementProps
|
|
22
|
+
} = props;
|
|
23
|
+
const { status, initLoad } = listStatusState;
|
|
24
|
+
const rowCount = useMemo(() => {
|
|
25
|
+
if (status === "normal") {
|
|
26
|
+
return list.length;
|
|
27
|
+
} else {
|
|
28
|
+
return list.length + 1;
|
|
29
|
+
}
|
|
30
|
+
}, [status, list]);
|
|
31
|
+
const containerClass = useMemo(() => clsx(Container, className), [className]);
|
|
32
|
+
const RowComponent = useCallback(({ index, style, ...other }) => /* @__PURE__ */ jsx(
|
|
33
|
+
ListItem,
|
|
34
|
+
{
|
|
35
|
+
className: status !== "normal" && index === rowCount - 1 ? ItemPlace : Item,
|
|
36
|
+
index,
|
|
37
|
+
style,
|
|
38
|
+
renderComponent: status !== "normal" && index === rowCount - 1 ? itemPlaceSlot ?? DefaultItemPlace : itemSlot,
|
|
39
|
+
...other
|
|
40
|
+
}
|
|
41
|
+
), [status, rowCount, itemSlot]);
|
|
42
|
+
const ListContentPlace = useCallback(contentPlaceSlot ?? DefaultContentPlace, [contentPlaceSlot]);
|
|
43
|
+
const ContentComponent = useMemo(
|
|
44
|
+
() => initLoad ? /* @__PURE__ */ jsx(
|
|
45
|
+
ListContent,
|
|
46
|
+
{
|
|
47
|
+
className: Content,
|
|
48
|
+
loadMoreRows: onLoadMore,
|
|
49
|
+
renderItem: RowComponent
|
|
50
|
+
}
|
|
51
|
+
) : /* @__PURE__ */ jsx(
|
|
52
|
+
ListContentPlace,
|
|
53
|
+
{
|
|
54
|
+
className: ContentPlace,
|
|
55
|
+
status
|
|
56
|
+
}
|
|
57
|
+
),
|
|
58
|
+
[initLoad, status, RowComponent, onLoadMore]
|
|
59
|
+
);
|
|
60
|
+
return /* @__PURE__ */ jsx(Slot, { ...elementProps, children: /* @__PURE__ */ jsx(ListRoot, { className: containerClass, data: list, status, rowCount, itemGap, children: /* @__PURE__ */ jsx(AnimatePresence, { mode: "popLayout", children: /* @__PURE__ */ jsx(
|
|
61
|
+
motion.div,
|
|
62
|
+
{
|
|
63
|
+
style: { width: "100%", height: "100%" },
|
|
64
|
+
children: /* @__PURE__ */ jsx(Slottable, { children: ContentComponent })
|
|
65
|
+
},
|
|
66
|
+
initLoad
|
|
67
|
+
) }) }) });
|
|
68
|
+
});
|
|
69
|
+
List.displayName = "List";
|
|
70
|
+
|
|
71
|
+
export { List };
|