@taskon/widget-react 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +118 -64
- package/dist/CommunityTaskList.css +2694 -2951
- package/dist/EligibilityInfo.css +2221 -1332
- package/dist/LeaderboardWidget.css +403 -198
- package/dist/PageBuilder.css +57 -0
- package/dist/Quest.css +1347 -1477
- package/dist/TaskOnProvider.css +337 -29
- package/dist/ThemeProvider.css +228 -0
- package/dist/UserCenterWidget.css +168 -0
- package/dist/UserCenterWidget2.css +4917 -0
- package/dist/WidgetShell.css +417 -130
- package/dist/chunks/{CommunityTaskList-CrH6r4Av.js → CommunityTaskList-2nFy6l6m.js} +2612 -2074
- package/dist/chunks/{EligibilityInfo-DesW9-k9.js → EligibilityInfo-CKTl_cdU.js} +2714 -4077
- package/dist/chunks/{LeaderboardWidget-BSGpHKTk.js → LeaderboardWidget-DyoiiNS6.js} +288 -349
- package/dist/chunks/PageBuilder-DHM3Il6f.js +150 -0
- package/dist/chunks/{Quest-uSIVq78I.js → Quest-Dqx4OCat.js} +1380 -726
- package/dist/chunks/TaskOnProvider-CxtFIs3n.js +2072 -0
- package/dist/chunks/{WidgetShell-NlOgn1x5.js → ThemeProvider-CulHkqqY.js} +1397 -103
- package/dist/chunks/UserCenterWidget-SE5hqpnZ.js +8335 -0
- package/dist/chunks/UserCenterWidget-XL6LZRZM.js +3259 -0
- package/dist/chunks/{Table-CWGf2FKV.js → WidgetShell-8xn-Jivw.js} +237 -27
- package/dist/chunks/communitytask-es-CBNnS4o2.js +521 -0
- package/dist/chunks/communitytask-ja-GRf9cbdx.js +521 -0
- package/dist/chunks/communitytask-ko-Bf24PQKI.js +521 -0
- package/dist/chunks/communitytask-ru-CZm2CPoV.js +521 -0
- package/dist/chunks/leaderboardwidget-es-vKjrjQaz.js +146 -0
- package/dist/chunks/leaderboardwidget-ja-Q6u0HxKG.js +146 -0
- package/dist/chunks/leaderboardwidget-ko-CG6SWgxf.js +146 -0
- package/dist/chunks/leaderboardwidget-ru-DCcHcJGz.js +146 -0
- package/dist/chunks/quest-es-Dyyy0zaw.js +863 -0
- package/dist/chunks/quest-ja-Depog33y.js +863 -0
- package/dist/chunks/quest-ko-BMu3uRQJ.js +863 -0
- package/dist/chunks/quest-ru-xne814Rw.js +863 -0
- package/dist/chunks/taskwidget-es-Do9b3Mqw.js +245 -0
- package/dist/chunks/taskwidget-ja-CqSu-yWA.js +245 -0
- package/dist/chunks/taskwidget-ko-EHgXFV4B.js +245 -0
- package/dist/chunks/taskwidget-ru-CMbLQDK4.js +245 -0
- package/dist/chunks/useIsMobile-D6Ybur-6.js +30 -0
- package/dist/chunks/usercenter-es-Dz3Wp2vV.js +512 -0
- package/dist/chunks/usercenter-ja-CKE4DJC6.js +512 -0
- package/dist/chunks/usercenter-ko-Dtpkn2qb.js +512 -0
- package/dist/chunks/usercenter-ru-DnBGee45.js +512 -0
- package/dist/community-task.d.ts +29 -388
- package/dist/community-task.js +2 -7
- package/dist/core.d.ts +95 -28
- package/dist/core.js +11 -12
- package/dist/index.d.ts +260 -602
- package/dist/index.js +28 -7361
- package/dist/leaderboard.d.ts +5 -496
- package/dist/leaderboard.js +2 -15
- package/dist/page-builder.d.ts +20 -0
- package/dist/page-builder.js +4 -0
- package/dist/quest.d.ts +20 -292
- package/dist/quest.js +2 -5
- package/dist/user-center.d.ts +56 -0
- package/dist/user-center.js +4 -0
- package/package.json +22 -3
- package/dist/Table.css +0 -389
- package/dist/chunks/TaskOnProvider-QMwxGL44.js +0 -1435
- package/dist/chunks/ThemeProvider-Cs8IUVQj.js +0 -1118
- package/dist/chunks/leaderboardwidget-ja-Bj6gz6y1.js +0 -119
- package/dist/chunks/leaderboardwidget-ko-f1cLO9ic.js +0 -119
- package/dist/chunks/useWidgetLocale-BVcopbZS.js +0 -74
- package/dist/chunks/usercenter-ja-DBj_dtuz.js +0 -329
- package/dist/chunks/usercenter-ko-DYTkHAld.js +0 -329
- package/dist/index.css +0 -3662
package/dist/Table.css
DELETED
|
@@ -1,389 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Pagination 通用分页组件样式
|
|
3
|
-
* @description 使用 taskon-pagination 命名空间
|
|
4
|
-
*
|
|
5
|
-
* 设计参考 Figma: node-id=4000-1995
|
|
6
|
-
* - 按钮: 30x30px 圆形
|
|
7
|
-
* - 页码: 16px Regular
|
|
8
|
-
* - 当前页: 白色
|
|
9
|
-
* - 分隔符+总页数: rgba(255,255,255,0.4)
|
|
10
|
-
*/
|
|
11
|
-
|
|
12
|
-
/* ==================== 容器 ==================== */
|
|
13
|
-
.taskon-pagination {
|
|
14
|
-
display: flex;
|
|
15
|
-
align-items: center;
|
|
16
|
-
justify-content: center;
|
|
17
|
-
width: 100%;
|
|
18
|
-
gap: 16px;
|
|
19
|
-
padding: 12px 0;
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
/* ==================== 范围信息 ==================== */
|
|
23
|
-
.taskon-pagination-range {
|
|
24
|
-
font-size: 14px;
|
|
25
|
-
color: var(--taskon-color-text-secondary, rgba(255, 255, 255, 0.4));
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/* ==================== 控制区 ==================== */
|
|
29
|
-
.taskon-pagination-controls {
|
|
30
|
-
display: flex;
|
|
31
|
-
align-items: center;
|
|
32
|
-
gap: 16px;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
/* ==================== 页码信息 - 基于 Figma 设计 ==================== */
|
|
36
|
-
.taskon-pagination-info {
|
|
37
|
-
display: flex;
|
|
38
|
-
align-items: center;
|
|
39
|
-
font-size: 16px;
|
|
40
|
-
font-weight: 400;
|
|
41
|
-
white-space: nowrap;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
/* 当前页码 - 白色 */
|
|
45
|
-
.taskon-pagination-info-current {
|
|
46
|
-
color: var(--taskon-color-text-lightest, #ffffff);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
/* 分隔符 - 灰色 */
|
|
50
|
-
.taskon-pagination-info-separator {
|
|
51
|
-
color: var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
/* 总页数 - 灰色 */
|
|
55
|
-
.taskon-pagination-info-total {
|
|
56
|
-
color: var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
/* ==================== 图标 ==================== */
|
|
60
|
-
.taskon-pagination-icon {
|
|
61
|
-
width: 16px;
|
|
62
|
-
height: 16px;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
/* ==================== 按钮样式 - 圆形按钮 ==================== */
|
|
66
|
-
.taskon-pagination-btn {
|
|
67
|
-
display: inline-flex;
|
|
68
|
-
align-items: center;
|
|
69
|
-
justify-content: center;
|
|
70
|
-
width: 30px;
|
|
71
|
-
height: 30px;
|
|
72
|
-
min-width: 30px !important;
|
|
73
|
-
padding: 0 !important;
|
|
74
|
-
border-radius: 50% !important;
|
|
75
|
-
background-color: transparent !important;
|
|
76
|
-
border: 1px solid var(--taskon-color-border, rgba(255, 255, 255, 0.1)) !important;
|
|
77
|
-
color: var(--taskon-color-text-lightest, #ffffff) !important;
|
|
78
|
-
transition: all 0.2s ease;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
.taskon-pagination-btn:hover:not(:disabled) {
|
|
82
|
-
background-color: var(--taskon-color-bg-hover, rgba(255, 255, 255, 0.04)) !important;
|
|
83
|
-
border-color: var(--taskon-color-border-hover, rgba(255, 255, 255, 0.2)) !important;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.taskon-pagination-btn:disabled {
|
|
87
|
-
opacity: 0.4;
|
|
88
|
-
cursor: not-allowed;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
/* ==================== 尺寸变体 ==================== */
|
|
92
|
-
.taskon-pagination--small .taskon-pagination-range {
|
|
93
|
-
font-size: 12px;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.taskon-pagination--small .taskon-pagination-info {
|
|
97
|
-
font-size: 14px;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.taskon-pagination--small .taskon-pagination-icon {
|
|
101
|
-
width: 14px;
|
|
102
|
-
height: 14px;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.taskon-pagination--small .taskon-pagination-btn {
|
|
106
|
-
width: 24px;
|
|
107
|
-
height: 24px;
|
|
108
|
-
min-width: 24px !important;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
/* ==================== 响应式 ==================== */
|
|
112
|
-
@media (max-width: 750px) {
|
|
113
|
-
.taskon-pagination {
|
|
114
|
-
gap: 12px;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.taskon-pagination-range {
|
|
118
|
-
font-size: 3.2vw;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
.taskon-pagination-info {
|
|
122
|
-
font-size: 14px;
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
/**
|
|
126
|
-
* Table 通用表格组件样式
|
|
127
|
-
*
|
|
128
|
-
* 采用 BEM 命名规范
|
|
129
|
-
* 前缀: taskon-table
|
|
130
|
-
*
|
|
131
|
-
* 设计参考 Figma: node-id=4000-1908
|
|
132
|
-
* - 表头: 半透明背景、圆角、暗色文字
|
|
133
|
-
* - 行: 边框分隔、悬停效果、交替背景
|
|
134
|
-
* - 单元格: 可配置宽度和对齐方式
|
|
135
|
-
*/
|
|
136
|
-
|
|
137
|
-
/* ============================================================================
|
|
138
|
-
容器
|
|
139
|
-
============================================================================ */
|
|
140
|
-
|
|
141
|
-
.taskon-table-container {
|
|
142
|
-
width: 100%;
|
|
143
|
-
overflow-x: auto;
|
|
144
|
-
position: relative;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
.taskon-table {
|
|
148
|
-
width: 100%;
|
|
149
|
-
border-collapse: separate;
|
|
150
|
-
border-spacing: 0;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
/* ============================================================================
|
|
154
|
-
表头 - 参考 Figma 设计:45px 高度,深色半透明背景,无圆角
|
|
155
|
-
============================================================================ */
|
|
156
|
-
|
|
157
|
-
.taskon-table__head {
|
|
158
|
-
/* 不在 thead 上设置背景,由 th 元素控制 */
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
.taskon-table__head tr {
|
|
162
|
-
height: 45px;
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
/* 表头单元格 - 16px Regular,深色半透明背景 */
|
|
166
|
-
.taskon-table__header {
|
|
167
|
-
padding: 10px 20px;
|
|
168
|
-
font-size: 16px;
|
|
169
|
-
font-weight: 400;
|
|
170
|
-
text-align: left;
|
|
171
|
-
line-height: 24px;
|
|
172
|
-
color: var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
173
|
-
white-space: nowrap;
|
|
174
|
-
vertical-align: middle;
|
|
175
|
-
background-color: var(--taskon-color-table-header-bg, rgba(255, 255, 255, 0.04));
|
|
176
|
-
}
|
|
177
|
-
|
|
178
|
-
/* 表头对齐方式 */
|
|
179
|
-
.taskon-table__header--left {
|
|
180
|
-
text-align: left;
|
|
181
|
-
}
|
|
182
|
-
|
|
183
|
-
.taskon-table__header--center {
|
|
184
|
-
text-align: center;
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
.taskon-table__header--right {
|
|
188
|
-
text-align: right;
|
|
189
|
-
}
|
|
190
|
-
|
|
191
|
-
/* ============================================================================
|
|
192
|
-
表体
|
|
193
|
-
============================================================================ */
|
|
194
|
-
|
|
195
|
-
.taskon-table__body {
|
|
196
|
-
/* 默认样式 */
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
/* ============================================================================
|
|
200
|
-
数据行 - 参考 Figma 设计:更大行高(76px),无边框
|
|
201
|
-
============================================================================ */
|
|
202
|
-
|
|
203
|
-
.taskon-table__row {
|
|
204
|
-
transition: background-color 0.2s ease;
|
|
205
|
-
height: 76px;
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
/* 行边框 - 默认不显示,使用 borderless 类控制 */
|
|
209
|
-
.taskon-table__row td {
|
|
210
|
-
border-top: none;
|
|
211
|
-
border-bottom: none;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
/* 需要边框时的样式 */
|
|
215
|
-
.taskon-table--bordered .taskon-table__row td {
|
|
216
|
-
border-top: 1px solid var(--taskon-color-table-border, rgba(255, 255, 255, 0.04));
|
|
217
|
-
border-bottom: 1px solid var(--taskon-color-table-border, rgba(255, 255, 255, 0.04));
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
/* 悬停效果 */
|
|
221
|
-
.taskon-table__row:hover {
|
|
222
|
-
background-color: var(--taskon-color-table-row-hover, rgba(255, 255, 255, 0.04));
|
|
223
|
-
}
|
|
224
|
-
|
|
225
|
-
/* 交替行背景 (striped) */
|
|
226
|
-
.taskon-table--striped .taskon-table__row:nth-child(even) {
|
|
227
|
-
background-color: var(--taskon-color-table-row-alt, rgba(255, 255, 255, 0.04));
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
/* 高亮行 */
|
|
231
|
-
.taskon-table__row--highlighted {
|
|
232
|
-
background-color: var(--taskon-color-primary-bg, rgba(99, 102, 241, 0.1));
|
|
233
|
-
}
|
|
234
|
-
|
|
235
|
-
.taskon-table__row--highlighted:hover {
|
|
236
|
-
background-color: var(--taskon-color-primary-bg-hover, rgba(99, 102, 241, 0.15));
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
/* 禁用行 */
|
|
240
|
-
.taskon-table__row--disabled {
|
|
241
|
-
opacity: 0.4;
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
/* 可点击行 */
|
|
245
|
-
.taskon-table__row--clickable {
|
|
246
|
-
cursor: pointer;
|
|
247
|
-
}
|
|
248
|
-
|
|
249
|
-
/* ============================================================================
|
|
250
|
-
单元格 - 参考 Figma 设计:16px SemiBold,白色文字
|
|
251
|
-
============================================================================ */
|
|
252
|
-
|
|
253
|
-
.taskon-table__cell {
|
|
254
|
-
padding: 16px 20px;
|
|
255
|
-
font-size: 16px;
|
|
256
|
-
font-weight: 600;
|
|
257
|
-
line-height: 24px;
|
|
258
|
-
color: var(--taskon-color-text-lightest, #ffffff);
|
|
259
|
-
vertical-align: middle;
|
|
260
|
-
}
|
|
261
|
-
|
|
262
|
-
/* 单元格对齐方式 */
|
|
263
|
-
.taskon-table__cell--left {
|
|
264
|
-
text-align: left;
|
|
265
|
-
}
|
|
266
|
-
|
|
267
|
-
.taskon-table__cell--center {
|
|
268
|
-
text-align: center;
|
|
269
|
-
}
|
|
270
|
-
|
|
271
|
-
.taskon-table__cell--right {
|
|
272
|
-
text-align: right;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
/* 单元格文本溢出 */
|
|
276
|
-
.taskon-table__cell--ellipsis {
|
|
277
|
-
text-overflow: ellipsis;
|
|
278
|
-
overflow: hidden;
|
|
279
|
-
white-space: nowrap;
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
/* ============================================================================
|
|
283
|
-
空状态和加载状态
|
|
284
|
-
============================================================================ */
|
|
285
|
-
|
|
286
|
-
.taskon-table__loading,
|
|
287
|
-
.taskon-table__empty {
|
|
288
|
-
padding: 40px 16px;
|
|
289
|
-
text-align: center;
|
|
290
|
-
color: var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
291
|
-
}
|
|
292
|
-
|
|
293
|
-
.taskon-table__empty-content {
|
|
294
|
-
display: flex;
|
|
295
|
-
flex-direction: column;
|
|
296
|
-
align-items: center;
|
|
297
|
-
gap: 8px;
|
|
298
|
-
}
|
|
299
|
-
|
|
300
|
-
.taskon-table__empty-icon {
|
|
301
|
-
font-size: 48px;
|
|
302
|
-
opacity: 0.5;
|
|
303
|
-
}
|
|
304
|
-
|
|
305
|
-
.taskon-table__empty-title {
|
|
306
|
-
font-size: 16px;
|
|
307
|
-
font-weight: 600;
|
|
308
|
-
color: var(--taskon-color-text-lightest, #ffffff);
|
|
309
|
-
margin: 0;
|
|
310
|
-
}
|
|
311
|
-
|
|
312
|
-
.taskon-table__empty-desc {
|
|
313
|
-
font-size: 14px;
|
|
314
|
-
color: var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
315
|
-
margin: 0;
|
|
316
|
-
}
|
|
317
|
-
|
|
318
|
-
/* 加载指示器 */
|
|
319
|
-
.taskon-table__loading-spinner {
|
|
320
|
-
display: inline-block;
|
|
321
|
-
width: 24px;
|
|
322
|
-
height: 24px;
|
|
323
|
-
border: 2px solid var(--taskon-color-text-dark, rgba(255, 255, 255, 0.4));
|
|
324
|
-
border-top-color: var(--taskon-color-primary, #6366f1);
|
|
325
|
-
border-radius: 50%;
|
|
326
|
-
animation: taskon-table-spin 0.8s linear infinite;
|
|
327
|
-
}
|
|
328
|
-
|
|
329
|
-
@keyframes taskon-table-spin {
|
|
330
|
-
from {
|
|
331
|
-
transform: rotate(0deg);
|
|
332
|
-
}
|
|
333
|
-
to {
|
|
334
|
-
transform: rotate(360deg);
|
|
335
|
-
}
|
|
336
|
-
}
|
|
337
|
-
|
|
338
|
-
/* Overlay loading - 覆盖在表格数据上方 */
|
|
339
|
-
.taskon-table__loading-overlay {
|
|
340
|
-
position: absolute;
|
|
341
|
-
top: 0;
|
|
342
|
-
left: 0;
|
|
343
|
-
right: 0;
|
|
344
|
-
bottom: 0;
|
|
345
|
-
display: flex;
|
|
346
|
-
align-items: center;
|
|
347
|
-
justify-content: center;
|
|
348
|
-
background-color: var(--taskon-color-overlay-bg, rgba(0, 0, 0, 0.5));
|
|
349
|
-
backdrop-filter: blur(2px);
|
|
350
|
-
z-index: 10;
|
|
351
|
-
border-radius: 4px;
|
|
352
|
-
}
|
|
353
|
-
|
|
354
|
-
/* ============================================================================
|
|
355
|
-
紧凑模式
|
|
356
|
-
============================================================================ */
|
|
357
|
-
|
|
358
|
-
.taskon-table--compact .taskon-table__header {
|
|
359
|
-
padding: 4px 12px;
|
|
360
|
-
}
|
|
361
|
-
|
|
362
|
-
.taskon-table--compact .taskon-table__cell {
|
|
363
|
-
padding: 12px;
|
|
364
|
-
}
|
|
365
|
-
|
|
366
|
-
/* ============================================================================
|
|
367
|
-
无边框模式
|
|
368
|
-
============================================================================ */
|
|
369
|
-
|
|
370
|
-
.taskon-table--borderless .taskon-table__row td {
|
|
371
|
-
border-top: none;
|
|
372
|
-
border-bottom: none;
|
|
373
|
-
}
|
|
374
|
-
|
|
375
|
-
/* ============================================================================
|
|
376
|
-
响应式
|
|
377
|
-
============================================================================ */
|
|
378
|
-
|
|
379
|
-
@media (max-width: 640px) {
|
|
380
|
-
.taskon-table__header,
|
|
381
|
-
.taskon-table__cell {
|
|
382
|
-
padding: 8px 12px;
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
.taskon-table--compact .taskon-table__header,
|
|
386
|
-
.taskon-table--compact .taskon-table__cell {
|
|
387
|
-
padding: 4px 8px;
|
|
388
|
-
}
|
|
389
|
-
}
|