@taskon/widget-react 0.0.1-beta.4 → 0.0.1-beta.6
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 +13 -4
- package/dist/CommunityTaskList.css +119 -111
- package/dist/EligibilityInfo.css +114 -110
- package/dist/LeaderboardWidget.css +73 -71
- package/dist/PageBuilder.css +5 -0
- package/dist/Quest.css +259 -255
- package/dist/TaskOnProvider.css +2 -0
- package/dist/UserCenterWidget.css +6 -6
- package/dist/UserCenterWidget2.css +1626 -1601
- package/dist/{dynamic-import-helper.css → WidgetShell.css} +2 -2
- package/dist/chunks/{CommunityTaskList-C9Gv8KOF.js → CommunityTaskList-Hde2OKHH.js} +1070 -580
- package/dist/chunks/{EligibilityInfo-D-Fuy9GE.js → EligibilityInfo-BV0Z2TgY.js} +1972 -1028
- package/dist/chunks/{LeaderboardWidget-BV2D2q1N.js → LeaderboardWidget-BNGRD5Bu.js} +270 -249
- package/dist/chunks/{PageBuilder-DQoU4Mwf.js → PageBuilder-C5DSHiW9.js} +5 -5
- package/dist/chunks/{Quest-B5NyVr3o.js → Quest-DG9zfXJo.js} +723 -513
- package/dist/chunks/{TaskOnProvider-93UxARFo.js → TaskOnProvider-BhamHIyY.js} +98 -68
- package/dist/chunks/{ThemeProvider-CPI_roeh.js → ThemeProvider-mXLdLSkq.js} +107 -20
- package/dist/chunks/{UserCenterWidget-cADBSVg7.js → UserCenterWidget-D5ttw4hO.js} +1328 -1337
- package/dist/chunks/{UserCenterWidget-BRtigY_S.js → UserCenterWidget-jDO5zTN1.js} +358 -254
- package/dist/chunks/{dynamic-import-helper-DwXlQC0S.js → WidgetShell-D7yC894Y.js} +447 -457
- 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/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 +0 -390
- package/dist/community-task.js +2 -7
- package/dist/core.d.ts +46 -10
- package/dist/core.js +11 -11
- package/dist/index.d.ts +46 -667
- package/dist/index.js +19 -28
- package/dist/leaderboard.d.ts +0 -498
- package/dist/leaderboard.js +2 -16
- package/dist/page-builder.js +1 -1
- package/dist/quest.d.ts +0 -289
- package/dist/quest.js +2 -5
- package/dist/user-center.d.ts +0 -1608
- package/dist/user-center.js +2 -494
- package/package.json +5 -2
- package/dist/chunks/leaderboardwidget-ja-Bj6gz6y1.js +0 -119
- package/dist/chunks/leaderboardwidget-ko-f1cLO9ic.js +0 -119
- package/dist/chunks/usercenter-ja-B2465c1O.js +0 -326
- package/dist/chunks/usercenter-ko-xAEYxqLg.js +0 -326
package/dist/index.d.ts
CHANGED
|
@@ -1,179 +1,24 @@
|
|
|
1
|
-
import { CampaignStatusInfo } from '@taskon/core';
|
|
2
1
|
import { CampaignWinnerReward } from '@taskon/core';
|
|
3
2
|
import { ChainInfo } from '@taskon/core';
|
|
4
3
|
import { ChainType } from '@taskon/core';
|
|
5
4
|
import { CloudThemeConfig } from '@taskon/core';
|
|
6
5
|
import { CommunityInfo } from '@taskon/core';
|
|
7
|
-
import { CommunityTaskInfo } from '@taskon/core';
|
|
8
|
-
import { ComponentPropsWithoutRef } from 'react';
|
|
9
6
|
import { default as default_2 } from 'react';
|
|
10
|
-
import { ForwardRefExoticComponent } from 'react';
|
|
11
|
-
import { GtcUserTaskStatus } from '@taskon/core';
|
|
12
7
|
import { LeaderboardContentConfig } from '@taskon/core';
|
|
13
8
|
import { LoginResult } from '@taskon/core';
|
|
14
|
-
import { MeetCondition } from '@taskon/core';
|
|
15
9
|
import { PageBuilderConfig } from '@taskon/core';
|
|
16
|
-
import { QuestApi } from '@taskon/core';
|
|
17
10
|
import { QuestCampaignInfo } from '@taskon/core';
|
|
18
11
|
import { ReactNode } from 'react';
|
|
19
|
-
import { RecurrenceType } from '@taskon/core';
|
|
20
|
-
import { RefAttributes } from 'react';
|
|
21
12
|
import { RewardDisplayMode } from '@taskon/core';
|
|
22
13
|
import { RewardType } from '@taskon/core';
|
|
23
14
|
import { RewardValueInfo } from '@taskon/core';
|
|
24
15
|
import { SnsType } from '@taskon/core';
|
|
25
16
|
import { TaskOnClient } from '@taskon/core';
|
|
26
|
-
import { TaskReviewResult } from '@taskon/core';
|
|
27
|
-
import { UserCampaignStatusInfo } from '@taskon/core';
|
|
28
17
|
import { UserCenterConfig } from '@taskon/core';
|
|
29
18
|
import { UserCenterRewardCardType } from '@taskon/core';
|
|
30
19
|
import { UserCenterTabType } from '@taskon/core';
|
|
31
20
|
import { UserInfo } from '@taskon/core';
|
|
32
21
|
|
|
33
|
-
/**
|
|
34
|
-
* Button 通用按钮组件
|
|
35
|
-
*
|
|
36
|
-
* 基于 Radix UI Slot 实现,支持 asChild 模式
|
|
37
|
-
*
|
|
38
|
-
* @example
|
|
39
|
-
* ```tsx
|
|
40
|
-
* // 基础用法
|
|
41
|
-
* <Button>点击我</Button>
|
|
42
|
-
*
|
|
43
|
-
* // 不同变体
|
|
44
|
-
* <Button variant="primary">主要按钮</Button>
|
|
45
|
-
* <Button variant="secondary">次要按钮</Button>
|
|
46
|
-
* <Button variant="outline">描边按钮</Button>
|
|
47
|
-
* <Button variant="ghost">幽灵按钮</Button>
|
|
48
|
-
* <Button variant="danger">危险按钮</Button>
|
|
49
|
-
*
|
|
50
|
-
* // 不同尺寸
|
|
51
|
-
* <Button size="small">小按钮</Button>
|
|
52
|
-
* <Button size="medium">中等按钮</Button>
|
|
53
|
-
* <Button size="large">大按钮</Button>
|
|
54
|
-
*
|
|
55
|
-
* // 加载状态
|
|
56
|
-
* <Button loading>加载中</Button>
|
|
57
|
-
*
|
|
58
|
-
* // 带图标
|
|
59
|
-
* <Button leftIcon={<Icon />}>左侧图标</Button>
|
|
60
|
-
* <Button rightIcon={<Icon />}>右侧图标</Button>
|
|
61
|
-
*
|
|
62
|
-
* // 禁用状态
|
|
63
|
-
* <Button disabled>禁用按钮</Button>
|
|
64
|
-
*
|
|
65
|
-
* // asChild 模式(将 Button 样式应用到子元素)
|
|
66
|
-
* <Button asChild>
|
|
67
|
-
* <a href="/about">链接按钮</a>
|
|
68
|
-
* </Button>
|
|
69
|
-
* ```
|
|
70
|
-
*/
|
|
71
|
-
export declare const Button: ForwardRefExoticComponent<ButtonProps & RefAttributes<HTMLButtonElement>>;
|
|
72
|
-
|
|
73
|
-
/**
|
|
74
|
-
* Button 组件属性
|
|
75
|
-
*/
|
|
76
|
-
export declare interface ButtonProps extends ComponentPropsWithoutRef<"button"> {
|
|
77
|
-
/**
|
|
78
|
-
* 按钮尺寸
|
|
79
|
-
* @default "medium"
|
|
80
|
-
*/
|
|
81
|
-
size?: ButtonSize;
|
|
82
|
-
/**
|
|
83
|
-
* 按钮变体
|
|
84
|
-
* @default "primary"
|
|
85
|
-
*/
|
|
86
|
-
variant?: ButtonVariant;
|
|
87
|
-
/**
|
|
88
|
-
* 是否为加载状态
|
|
89
|
-
* @default false
|
|
90
|
-
*/
|
|
91
|
-
loading?: boolean;
|
|
92
|
-
/**
|
|
93
|
-
* 图标位置
|
|
94
|
-
*/
|
|
95
|
-
iconPosition?: "left" | "right" | "only";
|
|
96
|
-
/**
|
|
97
|
-
* 左侧图标
|
|
98
|
-
*/
|
|
99
|
-
leftIcon?: ReactNode;
|
|
100
|
-
/**
|
|
101
|
-
* 右侧图标
|
|
102
|
-
*/
|
|
103
|
-
rightIcon?: ReactNode;
|
|
104
|
-
/**
|
|
105
|
-
* 是否作为子元素渲染(使用 Radix Slot)
|
|
106
|
-
* 当为 true 时,Button 会将所有属性传递给第一个子元素
|
|
107
|
-
* @default false
|
|
108
|
-
*/
|
|
109
|
-
asChild?: boolean;
|
|
110
|
-
/**
|
|
111
|
-
* 按钮内容
|
|
112
|
-
*/
|
|
113
|
-
children?: ReactNode;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
* Button 尺寸类型
|
|
118
|
-
*/
|
|
119
|
-
export declare type ButtonSize = "small" | "medium" | "large";
|
|
120
|
-
|
|
121
|
-
/**
|
|
122
|
-
* Button 变体类型
|
|
123
|
-
*/
|
|
124
|
-
export declare type ButtonVariant = "primary" | "secondary" | "outline" | "ghost" | "danger";
|
|
125
|
-
|
|
126
|
-
/**
|
|
127
|
-
* CardSelector 组件
|
|
128
|
-
*
|
|
129
|
-
* @example
|
|
130
|
-
* ```tsx
|
|
131
|
-
* const options = [
|
|
132
|
-
* { value: 'all', label: 'All Tasks' },
|
|
133
|
-
* { value: 1, label: 'Daily Tasks' },
|
|
134
|
-
* { value: 2, label: 'Weekly Tasks' },
|
|
135
|
-
* ];
|
|
136
|
-
*
|
|
137
|
-
* <CardSelector
|
|
138
|
-
* options={options}
|
|
139
|
-
* value={selectedValue}
|
|
140
|
-
* onChange={setSelectedValue}
|
|
141
|
-
* allowDeselect
|
|
142
|
-
* />
|
|
143
|
-
* ```
|
|
144
|
-
*/
|
|
145
|
-
export declare function CardSelector<T extends string | number = string | number>({ options, value, onChange, allowDeselect, className, itemClassName, }: CardSelectorProps<T>): default_2.ReactElement;
|
|
146
|
-
|
|
147
|
-
/**
|
|
148
|
-
* 选项配置
|
|
149
|
-
*/
|
|
150
|
-
export declare interface CardSelectorOption<T = string | number> {
|
|
151
|
-
/** 选项的值 */
|
|
152
|
-
value: T;
|
|
153
|
-
/** 选项的显示文本 */
|
|
154
|
-
label: string;
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
/**
|
|
158
|
-
* CardSelector 组件属性
|
|
159
|
-
*/
|
|
160
|
-
export declare interface CardSelectorProps<T = string | number> {
|
|
161
|
-
/** 选项列表 */
|
|
162
|
-
options: CardSelectorOption<T>[];
|
|
163
|
-
/** 当前选中的值 */
|
|
164
|
-
value?: T;
|
|
165
|
-
/** 值变化回调 */
|
|
166
|
-
onChange?: (value: T | undefined) => void;
|
|
167
|
-
/** 是否允许取消选择(点击已选中项取消选择)
|
|
168
|
-
* @default true
|
|
169
|
-
*/
|
|
170
|
-
allowDeselect?: boolean;
|
|
171
|
-
/** 自定义根容器类名 */
|
|
172
|
-
className?: string;
|
|
173
|
-
/** 自定义选项类名 */
|
|
174
|
-
itemClassName?: string;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
22
|
/**
|
|
178
23
|
* Clear the locale cache
|
|
179
24
|
* Useful for testing or when you need to force reload locales
|
|
@@ -234,37 +79,6 @@ export declare interface CommonMessages {
|
|
|
234
79
|
confirm: string;
|
|
235
80
|
}
|
|
236
81
|
|
|
237
|
-
/**
|
|
238
|
-
* BaseTask 组件
|
|
239
|
-
* @description 基础任务卡片,职责:
|
|
240
|
-
* - 卡片布局(flex 容器)
|
|
241
|
-
* - 周期标签显示
|
|
242
|
-
* - 任务标题显示
|
|
243
|
-
* - 有效时间显示
|
|
244
|
-
* - 按钮区域管理
|
|
245
|
-
* - 完成状态样式
|
|
246
|
-
*
|
|
247
|
-
* @example
|
|
248
|
-
* ```tsx
|
|
249
|
-
* <BaseTask
|
|
250
|
-
* title="Follow @TaskOn_xyz"
|
|
251
|
-
* isWon={false}
|
|
252
|
-
* isCompleted={false}
|
|
253
|
-
* isPeriodic={true}
|
|
254
|
-
* recurrenceLabel="Daily"
|
|
255
|
-
* taskId={123}
|
|
256
|
-
* actionLabel="Follow"
|
|
257
|
-
* actionLink="https://twitter.com/TaskOn_xyz"
|
|
258
|
-
* reward={{ type: 'points', amount: 100, name: 'Points', icon: '/icon.png' }}
|
|
259
|
-
* onClick={() => console.log('卡片被点击')}
|
|
260
|
-
* onClaim={() => console.log('Claim 按钮被点击')}
|
|
261
|
-
* >
|
|
262
|
-
* <div>额外的任务描述内容</div>
|
|
263
|
-
* </BaseTask>
|
|
264
|
-
* ```
|
|
265
|
-
*/
|
|
266
|
-
export declare function CommunityTask(props: CommunityTaskProps): default_2.ReactElement;
|
|
267
|
-
|
|
268
82
|
/**
|
|
269
83
|
* CommunityTaskList outer wrapper
|
|
270
84
|
*
|
|
@@ -353,292 +167,6 @@ export declare interface CommunityTaskListProps {
|
|
|
353
167
|
rewardRedirectUrl?: string;
|
|
354
168
|
}
|
|
355
169
|
|
|
356
|
-
/**
|
|
357
|
-
* 任务卡片基础 Props(最小知识原则)
|
|
358
|
-
* BaseTask 只需要知道这些信息
|
|
359
|
-
*/
|
|
360
|
-
export declare interface CommunityTaskProps {
|
|
361
|
-
/** 任务名称/标题(字符串或自定义渲染节点) */
|
|
362
|
-
title: string | React.ReactNode;
|
|
363
|
-
/** 是否已中奖/完成 */
|
|
364
|
-
isWon: boolean;
|
|
365
|
-
/** 是否已提交(可能未中奖) */
|
|
366
|
-
isCompleted: boolean;
|
|
367
|
-
/** 是否是周期任务 */
|
|
368
|
-
isPeriodic: boolean;
|
|
369
|
-
/** 操作按钮文案(如 "Follow"、"Join") */
|
|
370
|
-
actionLabel?: string;
|
|
371
|
-
/** 操作按钮链接(默认在新标签页打开) */
|
|
372
|
-
actionLink?: string;
|
|
373
|
-
/** 点击操作按钮后是否自动验证 */
|
|
374
|
-
actionAutoVerify?: boolean;
|
|
375
|
-
/**
|
|
376
|
-
* 点击 Action 按钮时自动打开弹窗
|
|
377
|
-
* 用于 PowTask、InviteFriends 等需要在弹窗中填写内容的任务
|
|
378
|
-
*/
|
|
379
|
-
actionAutoDialog?: boolean;
|
|
380
|
-
/** 是否总是显示操作按钮(即使已完成) */
|
|
381
|
-
alwaysShowAction?: boolean;
|
|
382
|
-
/**
|
|
383
|
-
* 标题跳转链接
|
|
384
|
-
* 如果提供,标题将变成可点击的链接,在新标签页打开
|
|
385
|
-
*/
|
|
386
|
-
targetLink?: string;
|
|
387
|
-
/** 是否隐藏 Claim 按钮 */
|
|
388
|
-
noClaim?: boolean;
|
|
389
|
-
/**
|
|
390
|
-
* 是否需要验证后才能 Claim
|
|
391
|
-
* - true: 显示 "Verify & Claim"
|
|
392
|
-
* - false: 显示 "Claim"
|
|
393
|
-
*/
|
|
394
|
-
verifyClaim?: boolean;
|
|
395
|
-
/**
|
|
396
|
-
* 点击 Claim 仅打开弹窗(不提交)
|
|
397
|
-
* 用于 QuizTask、SurveyTask 等需要在弹窗中选择答案的任务
|
|
398
|
-
*/
|
|
399
|
-
claimDialog?: boolean;
|
|
400
|
-
/**
|
|
401
|
-
* 社交账号类型(用于 OAuth 绑定)
|
|
402
|
-
* 决定 Claim 时需要绑定哪种社交账号
|
|
403
|
-
*/
|
|
404
|
-
snsType?: SnsType;
|
|
405
|
-
/**
|
|
406
|
-
* 链类型(用于钱包绑定)
|
|
407
|
-
* 决定 Claim 时需要绑定哪种链的钱包
|
|
408
|
-
*/
|
|
409
|
-
chainType?: ChainType;
|
|
410
|
-
/** 周期标签文本(如 "Daily"、"Weekly") */
|
|
411
|
-
recurrenceLabel?: string;
|
|
412
|
-
/** 任务重复类型(用于 Claim 按钮文案逻辑) */
|
|
413
|
-
recurrence?: RecurrenceType;
|
|
414
|
-
/** 是否隐藏周期标签 */
|
|
415
|
-
noRecurrence?: boolean;
|
|
416
|
-
/**
|
|
417
|
-
* Unlimited 任务是否显示大的 Claim 按钮
|
|
418
|
-
* - true: 显示正常大小的 Claim 按钮
|
|
419
|
-
* - false: 显示小的 Update 按钮(已有积分)
|
|
420
|
-
* @default true
|
|
421
|
-
*/
|
|
422
|
-
showUnlimitedClaim?: boolean;
|
|
423
|
-
/** 任务 ID */
|
|
424
|
-
taskId: number;
|
|
425
|
-
/** 有效时间相关 */
|
|
426
|
-
validTime?: {
|
|
427
|
-
/** 开始时间(格式化字符串) */
|
|
428
|
-
startTime?: string;
|
|
429
|
-
/** 结束时间(格式化字符串) */
|
|
430
|
-
endTime?: string;
|
|
431
|
-
/** 是否已过期 */
|
|
432
|
-
isExpired?: boolean;
|
|
433
|
-
};
|
|
434
|
-
/**
|
|
435
|
-
* 验证时间范围(OnChain 任务专用)
|
|
436
|
-
* 显示 "This task only verify action during {start} - {end}(UTC)"
|
|
437
|
-
*/
|
|
438
|
-
validationTimeFrame?: {
|
|
439
|
-
/** 开始时间(毫秒或秒时间戳) */
|
|
440
|
-
start_time: number;
|
|
441
|
-
/** 结束时间(毫秒或秒时间戳) */
|
|
442
|
-
end_time: number;
|
|
443
|
-
};
|
|
444
|
-
/** 奖励信息 */
|
|
445
|
-
reward?: {
|
|
446
|
-
/** 奖励类型 */
|
|
447
|
-
type: "points" | "token" | "none";
|
|
448
|
-
/** 积分数量(points 类型,单次奖励) */
|
|
449
|
-
amount?: number;
|
|
450
|
-
/** 积分名称(points 类型) */
|
|
451
|
-
name?: string;
|
|
452
|
-
/** 积分图标(points 类型) */
|
|
453
|
-
icon?: string;
|
|
454
|
-
/** 累计积分(周期任务完成时显示) */
|
|
455
|
-
totalAmount?: number;
|
|
456
|
-
/** Token 信息(token 类型) */
|
|
457
|
-
token?: {
|
|
458
|
-
/** Token 名称 */
|
|
459
|
-
name: string;
|
|
460
|
-
/** 每次奖励数量 */
|
|
461
|
-
amount: string;
|
|
462
|
-
/** Token 图标 */
|
|
463
|
-
icon?: string;
|
|
464
|
-
/** 链名称 */
|
|
465
|
-
chain?: string;
|
|
466
|
-
/** 链图标 */
|
|
467
|
-
chainIcon?: string;
|
|
468
|
-
/** 总奖励单位数 */
|
|
469
|
-
totalUnit?: number;
|
|
470
|
-
/** 可用单位数 */
|
|
471
|
-
availableUnit?: number;
|
|
472
|
-
};
|
|
473
|
-
};
|
|
474
|
-
/** 卡片内容(由具体任务组件提供,用于展示任务特定内容) */
|
|
475
|
-
children?: React.ReactNode;
|
|
476
|
-
/**
|
|
477
|
-
* 自定义 Action 按钮区域
|
|
478
|
-
* 如果提供,将替换默认的 Action 按钮
|
|
479
|
-
* @example
|
|
480
|
-
* ```tsx
|
|
481
|
-
* <BaseTask
|
|
482
|
-
* actionSlot={<CustomActionButton onClick={handleAction} />}
|
|
483
|
-
* />
|
|
484
|
-
* ```
|
|
485
|
-
*/
|
|
486
|
-
actionSlot?: React.ReactNode;
|
|
487
|
-
/**
|
|
488
|
-
* 自定义奖励展示(已完成状态)
|
|
489
|
-
* 如果提供,将替换默认的 Won 奖励显示
|
|
490
|
-
* @example
|
|
491
|
-
* ```tsx
|
|
492
|
-
* <BaseTask
|
|
493
|
-
* rewardSlot={<CustomRewardDisplay amount={100} />}
|
|
494
|
-
* />
|
|
495
|
-
* ```
|
|
496
|
-
*/
|
|
497
|
-
rewardSlot?: React.ReactNode;
|
|
498
|
-
/**
|
|
499
|
-
* 是否已登录
|
|
500
|
-
* - true: 正常显示卡片
|
|
501
|
-
* - false/undefined: 显示登录遮层,点击触发 onLogin
|
|
502
|
-
* @default true
|
|
503
|
-
*/
|
|
504
|
-
isLoggedIn?: boolean;
|
|
505
|
-
/** 点击卡片回调(用于打开弹窗) */
|
|
506
|
-
onClick?: () => void;
|
|
507
|
-
/**
|
|
508
|
-
* 点击 Claim 按钮回调
|
|
509
|
-
* @param token - 可选的 OAuth token(reAuth 成功后传入)
|
|
510
|
-
* @returns 可选返回 Promise,包含结果信息用于 reAuth 判断和 coolDown 更新
|
|
511
|
-
*/
|
|
512
|
-
onClaim?: (token?: string) => void | Promise<{
|
|
513
|
-
successful: boolean;
|
|
514
|
-
errorCode?: string;
|
|
515
|
-
cool_down?: number;
|
|
516
|
-
}>;
|
|
517
|
-
/**
|
|
518
|
-
* 点击登录遮层回调
|
|
519
|
-
* 未登录时(isLoggedIn=false)点击卡片会触发此回调
|
|
520
|
-
*/
|
|
521
|
-
onLogin?: () => void;
|
|
522
|
-
/** 是否正在提交 */
|
|
523
|
-
isSubmitting?: boolean;
|
|
524
|
-
/** 冷却时间(毫秒) */
|
|
525
|
-
coolDown?: number;
|
|
526
|
-
/** 冷却结束回调(用于重置 coolDown 状态) */
|
|
527
|
-
onCoolDownComplete?: () => void;
|
|
528
|
-
/**
|
|
529
|
-
* 周期任务倒计时结束回调
|
|
530
|
-
* 用于在 next_time 到期后刷新单个任务卡片状态
|
|
531
|
-
*/
|
|
532
|
-
onDoneCountdownComplete?: (taskId: number) => void | Promise<void>;
|
|
533
|
-
/** 是否禁用交互 */
|
|
534
|
-
disabled?: boolean;
|
|
535
|
-
/**
|
|
536
|
-
* 审核结果状态
|
|
537
|
-
* - Passed: 审核通过
|
|
538
|
-
* - Failed: 审核失败(显示 "Oops! Failed")
|
|
539
|
-
* - UnReviewed: 审核中(显示 "Under Review")
|
|
540
|
-
*/
|
|
541
|
-
reviewResult?: TaskReviewResult;
|
|
542
|
-
/**
|
|
543
|
-
* CheckProgressTip 需要的社区信息
|
|
544
|
-
* 用于显示 "Contact {name} to check your progress"
|
|
545
|
-
*/
|
|
546
|
-
communityInfo?: {
|
|
547
|
-
/** 社区名称 */
|
|
548
|
-
name?: string;
|
|
549
|
-
/** 社区联系链接(Discord/Telegram/Twitter) */
|
|
550
|
-
contactLink?: string;
|
|
551
|
-
};
|
|
552
|
-
/**
|
|
553
|
-
* 周期任务:当前周期是否已完成
|
|
554
|
-
* 配合 nextTime 用于显示 DoneCountdown
|
|
555
|
-
*/
|
|
556
|
-
currentCompleted?: boolean;
|
|
557
|
-
/**
|
|
558
|
-
* 周期任务:下次可完成的时间戳(毫秒)
|
|
559
|
-
* 用于显示 DoneCountdown 倒计时
|
|
560
|
-
*/
|
|
561
|
-
nextTime?: number;
|
|
562
|
-
}
|
|
563
|
-
|
|
564
|
-
/**
|
|
565
|
-
* ConfirmNoticeDialog component
|
|
566
|
-
*
|
|
567
|
-
* @description
|
|
568
|
-
* - Replicates the original ConfirmNotice content structure
|
|
569
|
-
* - Supports default two-button mode and custom action slot
|
|
570
|
-
* - Reuses Dialog for accessibility / portal / keyboard interactions
|
|
571
|
-
* - Intentionally removes glow background layer
|
|
572
|
-
*/
|
|
573
|
-
export declare function ConfirmNoticeDialog({ open, onOpenChange, type, title, desc, col, cancelButton, confirmButton, onCancel, onConfirm, onClose, closeOnCancel, closeOnConfirm, cancelDisabled, confirmDisabled, showCloseButton, closeOnOverlayClick, closeOnEscapeKey, maxWidth, className, contentClassName, children, actions, footer, accessibilityTitle, accessibilityDescription, }: ConfirmNoticeDialogProps): default_2.ReactElement;
|
|
574
|
-
|
|
575
|
-
/**
|
|
576
|
-
* ConfirmNoticeDialog props
|
|
577
|
-
*/
|
|
578
|
-
export declare interface ConfirmNoticeDialogProps {
|
|
579
|
-
/** Whether the dialog is open (controlled) */
|
|
580
|
-
open: boolean;
|
|
581
|
-
/** Controlled open state callback */
|
|
582
|
-
onOpenChange: (open: boolean) => void;
|
|
583
|
-
/** Notice visual type */
|
|
584
|
-
type?: ConfirmNoticeType;
|
|
585
|
-
/** Title rendered below the icon */
|
|
586
|
-
title?: default_2.ReactNode;
|
|
587
|
-
/** Description rendered below the title */
|
|
588
|
-
desc?: default_2.ReactNode;
|
|
589
|
-
/** Allow action area wrapping on desktop */
|
|
590
|
-
col?: boolean;
|
|
591
|
-
/** Cancel button label. Hidden if omitted */
|
|
592
|
-
cancelButton?: default_2.ReactNode;
|
|
593
|
-
/** Confirm button label. Hidden if omitted */
|
|
594
|
-
confirmButton?: default_2.ReactNode;
|
|
595
|
-
/** Cancel button click callback */
|
|
596
|
-
onCancel?: () => void;
|
|
597
|
-
/** Confirm button click callback */
|
|
598
|
-
onConfirm?: () => void;
|
|
599
|
-
/** Called when dialog closes via overlay / ESC / close button / programmatic close */
|
|
600
|
-
onClose?: () => void;
|
|
601
|
-
/** Auto close after cancel click, defaults to true */
|
|
602
|
-
closeOnCancel?: boolean;
|
|
603
|
-
/** Auto close after confirm click, defaults to true */
|
|
604
|
-
closeOnConfirm?: boolean;
|
|
605
|
-
/** Disable cancel button */
|
|
606
|
-
cancelDisabled?: boolean;
|
|
607
|
-
/** Disable confirm button */
|
|
608
|
-
confirmDisabled?: boolean;
|
|
609
|
-
/** Show top-right close button, defaults to false (closer to original ConfirmNotice) */
|
|
610
|
-
showCloseButton?: boolean;
|
|
611
|
-
/** Allow closing by overlay click, defaults to true */
|
|
612
|
-
closeOnOverlayClick?: boolean;
|
|
613
|
-
/** Allow closing by ESC key, defaults to true */
|
|
614
|
-
closeOnEscapeKey?: boolean;
|
|
615
|
-
/** Dialog max width, defaults to 470 (same as original) */
|
|
616
|
-
maxWidth?: string | number;
|
|
617
|
-
/** Additional class on content root */
|
|
618
|
-
className?: string;
|
|
619
|
-
/** Additional class on Dialog.Content */
|
|
620
|
-
contentClassName?: string;
|
|
621
|
-
/** Custom body content between description and actions */
|
|
622
|
-
children?: default_2.ReactNode;
|
|
623
|
-
/** Custom action area. Overrides default cancel/confirm buttons */
|
|
624
|
-
actions?: default_2.ReactNode;
|
|
625
|
-
/** Extra content rendered after actions */
|
|
626
|
-
footer?: default_2.ReactNode;
|
|
627
|
-
/**
|
|
628
|
-
* Accessible dialog title
|
|
629
|
-
* - Falls back to string `title`
|
|
630
|
-
* - Uses default value when title is not a string
|
|
631
|
-
*/
|
|
632
|
-
accessibilityTitle?: string;
|
|
633
|
-
/** Accessible dialog description */
|
|
634
|
-
accessibilityDescription?: string;
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
/**
|
|
638
|
-
* ConfirmNotice visual style type
|
|
639
|
-
*/
|
|
640
|
-
export declare type ConfirmNoticeType = "default" | "success" | "warn";
|
|
641
|
-
|
|
642
170
|
/**
|
|
643
171
|
* Create a locale loader function for a widget
|
|
644
172
|
*
|
|
@@ -654,6 +182,8 @@ export declare type ConfirmNoticeType = "default" | "success" | "warn";
|
|
|
654
182
|
* const loadMessages = createLocaleLoader(enMessages, {
|
|
655
183
|
* ko: () => import('./locales/ko'),
|
|
656
184
|
* ja: () => import('./locales/ja'),
|
|
185
|
+
* ru: () => import('./locales/ru'),
|
|
186
|
+
* es: () => import('./locales/es'),
|
|
657
187
|
* });
|
|
658
188
|
* ```
|
|
659
189
|
*/
|
|
@@ -795,7 +325,11 @@ export declare type Locale = "en" | "ko" | "ja" | "ru" | "es";
|
|
|
795
325
|
|
|
796
326
|
/**
|
|
797
327
|
* Locale import map type
|
|
798
|
-
* Maps supported locales to their dynamic import functions
|
|
328
|
+
* Maps supported non-English locales to their dynamic import functions.
|
|
329
|
+
*
|
|
330
|
+
* Notes:
|
|
331
|
+
* - Keys are optional so widgets can incrementally adopt locales.
|
|
332
|
+
* - Missing locale imports safely fall back to inlined English messages.
|
|
799
333
|
*/
|
|
800
334
|
export declare type LocaleImportMap<T> = {
|
|
801
335
|
[K in Exclude<SupportedLocale, "en">]?: () => Promise<{
|
|
@@ -870,6 +404,9 @@ export declare interface MapToken {
|
|
|
870
404
|
fontSize?: number;
|
|
871
405
|
fontSizeSm?: number;
|
|
872
406
|
fontSizeLg?: number;
|
|
407
|
+
fontSizeXl?: number;
|
|
408
|
+
fontSizeXxl?: number;
|
|
409
|
+
fontSizeXxxl?: number;
|
|
873
410
|
spacing?: number;
|
|
874
411
|
spacingXs?: number;
|
|
875
412
|
spacingSm?: number;
|
|
@@ -1045,10 +582,13 @@ export declare interface SeedToken {
|
|
|
1045
582
|
}
|
|
1046
583
|
|
|
1047
584
|
/**
|
|
1048
|
-
* Locales
|
|
1049
|
-
*
|
|
585
|
+
* Locales recognized by the widget i18n runtime.
|
|
586
|
+
*
|
|
587
|
+
* Notes:
|
|
588
|
+
* - A widget can choose to provide only part of these locale files.
|
|
589
|
+
* - Missing locale modules still fall back to inlined English messages.
|
|
1050
590
|
*/
|
|
1051
|
-
export declare type SupportedLocale = "en" | "ko" | "ja";
|
|
591
|
+
export declare type SupportedLocale = "en" | "ko" | "ja" | "ru" | "es";
|
|
1052
592
|
|
|
1053
593
|
/**
|
|
1054
594
|
* TaskOn Context value
|
|
@@ -1063,9 +603,21 @@ export declare interface TaskOnContextValue {
|
|
|
1063
603
|
*/
|
|
1064
604
|
client: TaskOnClient | null;
|
|
1065
605
|
/**
|
|
1066
|
-
* Whether the provider is
|
|
606
|
+
* Whether the provider is in full initialization flow.
|
|
607
|
+
*
|
|
608
|
+
* Notes:
|
|
609
|
+
* - Includes session restore and token validation.
|
|
610
|
+
* - When a stored token exists, this stays true until user info validation completes.
|
|
1067
611
|
*/
|
|
1068
612
|
isInitializing: boolean;
|
|
613
|
+
/**
|
|
614
|
+
* Whether session prerequisites are ready for data requests.
|
|
615
|
+
* True means client is created and auth token has been loaded
|
|
616
|
+
* (or no token exists, anonymous mode).
|
|
617
|
+
*
|
|
618
|
+
* This can become true earlier than `isInitializing === false`.
|
|
619
|
+
*/
|
|
620
|
+
isSessionReady: boolean;
|
|
1069
621
|
/**
|
|
1070
622
|
* Resolved locale
|
|
1071
623
|
*/
|
|
@@ -1188,10 +740,13 @@ export declare interface TaskOnProviderConfig {
|
|
|
1188
740
|
/**
|
|
1189
741
|
* WalletConnect Project ID
|
|
1190
742
|
*
|
|
1191
|
-
*
|
|
1192
|
-
*
|
|
743
|
+
* Only needed when you design Web3 wallet login or wallet-based reward flows.
|
|
744
|
+
* (e.g. wallet binding, on-chain verification, NFT/token claiming)
|
|
745
|
+
*
|
|
746
|
+
* Optional. If not provided, SDK built-in default project ID will be used.
|
|
747
|
+
* For production, it is strongly recommended to set your own project ID.
|
|
1193
748
|
*
|
|
1194
|
-
*
|
|
749
|
+
* Get your project ID at https://cloud.walletconnect.com
|
|
1195
750
|
*/
|
|
1196
751
|
walletConnectProjectId?: string;
|
|
1197
752
|
}
|
|
@@ -1247,67 +802,6 @@ export declare interface TaskOnThemeConfig {
|
|
|
1247
802
|
dark?: ModeThemeConfig;
|
|
1248
803
|
}
|
|
1249
804
|
|
|
1250
|
-
/**
|
|
1251
|
-
* TemplateTask 组件
|
|
1252
|
-
*
|
|
1253
|
-
* @description 通用模版任务组件,负责:
|
|
1254
|
-
* - 解析 task.template.params 获取任务参数
|
|
1255
|
-
* - 使用 BaseTask 展示任务卡片
|
|
1256
|
-
* - 渲染描述字段(desc、desc_fields)
|
|
1257
|
-
* - 处理 Action 按钮(action_label、action_link)
|
|
1258
|
-
*
|
|
1259
|
-
* @example
|
|
1260
|
-
* ```tsx
|
|
1261
|
-
* <TemplateTask
|
|
1262
|
-
* task={taskInfo}
|
|
1263
|
-
* userStatus={userStatus}
|
|
1264
|
-
* onClick={() => console.log('卡片点击')}
|
|
1265
|
-
* onClaim={() => console.log('Claim 点击')}
|
|
1266
|
-
* />
|
|
1267
|
-
* ```
|
|
1268
|
-
*/
|
|
1269
|
-
export declare function TemplateTask({ task, userStatus, meetConditions, communityInfo, disabled, onClick, onClaim, onUpdate, onEligTaskClick, coolDown: sharedCoolDown, onCoolDownComplete: sharedOnCoolDownComplete, onDoneCountdownComplete, }: TemplateTaskProps): default_2.ReactElement;
|
|
1270
|
-
|
|
1271
|
-
/**
|
|
1272
|
-
* TemplateTask 组件属性
|
|
1273
|
-
*/
|
|
1274
|
-
export declare interface TemplateTaskProps {
|
|
1275
|
-
/** 任务信息 */
|
|
1276
|
-
task: CommunityTaskInfo;
|
|
1277
|
-
/** 用户状态 */
|
|
1278
|
-
userStatus?: GtcUserTaskStatus;
|
|
1279
|
-
/** 资格条件列表(有值时显示遮罩) */
|
|
1280
|
-
meetConditions?: MeetCondition[];
|
|
1281
|
-
/** 社区信息(用于前置任务链接跳转) */
|
|
1282
|
-
communityInfo?: {
|
|
1283
|
-
community_key?: string;
|
|
1284
|
-
dapp_domain?: string;
|
|
1285
|
-
};
|
|
1286
|
-
/** 是否禁用交互 */
|
|
1287
|
-
disabled?: boolean;
|
|
1288
|
-
/** 点击卡片回调 */
|
|
1289
|
-
onClick?: () => void;
|
|
1290
|
-
/**
|
|
1291
|
-
* 点击 Claim 回调
|
|
1292
|
-
* @param token 可选的 OAuth token(reAuth 成功后传入)
|
|
1293
|
-
*/
|
|
1294
|
-
onClaim?: (token?: string) => void | Promise<{
|
|
1295
|
-
successful: boolean;
|
|
1296
|
-
errorCode?: string;
|
|
1297
|
-
cool_down?: number;
|
|
1298
|
-
}>;
|
|
1299
|
-
/** 任务更新回调(完成/验证成功后) */
|
|
1300
|
-
onUpdate?: (taskId: number) => void | Promise<void>;
|
|
1301
|
-
/** 点击资格条件中的前置任务回调(用于打开任务弹窗) */
|
|
1302
|
-
onEligTaskClick?: (taskId: number) => void;
|
|
1303
|
-
/** 共享的 coolDown 值(来自父组件) */
|
|
1304
|
-
coolDown?: number;
|
|
1305
|
-
/** coolDown 倒计时结束回调 */
|
|
1306
|
-
onCoolDownComplete?: () => void;
|
|
1307
|
-
/** 周期任务倒计时结束回调(用于刷新单任务状态) */
|
|
1308
|
-
onDoneCountdownComplete?: (taskId: number) => void | Promise<void>;
|
|
1309
|
-
}
|
|
1310
|
-
|
|
1311
805
|
/**
|
|
1312
806
|
* Translation function type
|
|
1313
807
|
*/
|
|
@@ -1379,130 +873,6 @@ export declare function useEvmWallet(): {
|
|
|
1379
873
|
signMessage: (message: string) => Promise<string | null>;
|
|
1380
874
|
};
|
|
1381
875
|
|
|
1382
|
-
/**
|
|
1383
|
-
* 获取 Quest 详情 Hook
|
|
1384
|
-
*
|
|
1385
|
-
* @param options Hook 配置(包含从根组件传入的 api 实例)
|
|
1386
|
-
* @returns Quest 详情、加载状态、错误信息、重新加载方法
|
|
1387
|
-
*/
|
|
1388
|
-
export declare function useQuestDetail(options: UseQuestDetailOptions): UseQuestDetailReturn;
|
|
1389
|
-
|
|
1390
|
-
/**
|
|
1391
|
-
* useQuestDetail Hook 参数
|
|
1392
|
-
*/
|
|
1393
|
-
declare interface UseQuestDetailOptions {
|
|
1394
|
-
/** Quest API 实例(从根组件传入) */
|
|
1395
|
-
api: QuestApi | null;
|
|
1396
|
-
/** Campaign ID */
|
|
1397
|
-
campaignId: number;
|
|
1398
|
-
/** 渠道标识(可选) */
|
|
1399
|
-
channel?: string;
|
|
1400
|
-
/** KOL 标识(可选) */
|
|
1401
|
-
kolHandle?: string;
|
|
1402
|
-
/** 邀请码(可选) */
|
|
1403
|
-
inviteCode?: string;
|
|
1404
|
-
/** Boost ID(可选) */
|
|
1405
|
-
boostId?: number;
|
|
1406
|
-
/** 是否启用(默认 true) */
|
|
1407
|
-
enabled?: boolean;
|
|
1408
|
-
}
|
|
1409
|
-
|
|
1410
|
-
/**
|
|
1411
|
-
* useQuestDetail Hook 返回值
|
|
1412
|
-
*/
|
|
1413
|
-
declare interface UseQuestDetailReturn {
|
|
1414
|
-
/** Campaign 详情数据 */
|
|
1415
|
-
data: QuestCampaignInfo | null;
|
|
1416
|
-
/** 是否加载中 */
|
|
1417
|
-
isLoading: boolean;
|
|
1418
|
-
/** 错误信息 */
|
|
1419
|
-
error: string | null;
|
|
1420
|
-
/** 重新加载 */
|
|
1421
|
-
refetch: () => void;
|
|
1422
|
-
}
|
|
1423
|
-
|
|
1424
|
-
/**
|
|
1425
|
-
* 获取 Quest 状态信息 Hook
|
|
1426
|
-
*
|
|
1427
|
-
* @param options Hook 配置(包含从根组件传入的 api 实例)
|
|
1428
|
-
* @returns Quest 状态、加载状态、错误信息、重新加载方法
|
|
1429
|
-
*/
|
|
1430
|
-
export declare function useQuestStatus(options: UseQuestStatusOptions): UseQuestStatusReturn;
|
|
1431
|
-
|
|
1432
|
-
/**
|
|
1433
|
-
* useQuestStatus Hook 参数
|
|
1434
|
-
*/
|
|
1435
|
-
declare interface UseQuestStatusOptions {
|
|
1436
|
-
/** Quest API 实例(从根组件传入) */
|
|
1437
|
-
api: QuestApi | null;
|
|
1438
|
-
/** Campaign ID */
|
|
1439
|
-
campaignId: number;
|
|
1440
|
-
/** 渠道标识 */
|
|
1441
|
-
channel?: string;
|
|
1442
|
-
/** KOL 句柄 */
|
|
1443
|
-
kolHandle?: string;
|
|
1444
|
-
/** 是否启用(默认 true) */
|
|
1445
|
-
enabled?: boolean;
|
|
1446
|
-
}
|
|
1447
|
-
|
|
1448
|
-
/**
|
|
1449
|
-
* useQuestStatus Hook 返回值
|
|
1450
|
-
*/
|
|
1451
|
-
declare interface UseQuestStatusReturn {
|
|
1452
|
-
/** Campaign 状态数据 */
|
|
1453
|
-
data: CampaignStatusInfo | null;
|
|
1454
|
-
/** 是否加载中 */
|
|
1455
|
-
isLoading: boolean;
|
|
1456
|
-
/** 错误信息 */
|
|
1457
|
-
error: string | null;
|
|
1458
|
-
/** 重新加载 */
|
|
1459
|
-
refetch: () => void;
|
|
1460
|
-
}
|
|
1461
|
-
|
|
1462
|
-
/**
|
|
1463
|
-
* 获取用户 Quest 状态 Hook
|
|
1464
|
-
*
|
|
1465
|
-
* @param options Hook 配置(包含从根组件传入的 api 实例)
|
|
1466
|
-
* @returns 用户状态、加载状态、错误信息、重新加载方法
|
|
1467
|
-
*/
|
|
1468
|
-
export declare function useQuestUserStatus(options: UseQuestUserStatusOptions): UseQuestUserStatusReturn;
|
|
1469
|
-
|
|
1470
|
-
/**
|
|
1471
|
-
* useQuestUserStatus Hook 参数
|
|
1472
|
-
*/
|
|
1473
|
-
declare interface UseQuestUserStatusOptions {
|
|
1474
|
-
/** Quest API 实例(从根组件传入) */
|
|
1475
|
-
api: QuestApi | null;
|
|
1476
|
-
/** Campaign ID */
|
|
1477
|
-
campaignId: number;
|
|
1478
|
-
/** 渠道标识(可选) */
|
|
1479
|
-
channel?: string;
|
|
1480
|
-
/** KOL 标识(可选) */
|
|
1481
|
-
kolHandle?: string;
|
|
1482
|
-
/** 是否启用(默认 true) */
|
|
1483
|
-
enabled?: boolean;
|
|
1484
|
-
}
|
|
1485
|
-
|
|
1486
|
-
/**
|
|
1487
|
-
* useQuestUserStatus Hook 返回值
|
|
1488
|
-
*/
|
|
1489
|
-
declare interface UseQuestUserStatusReturn {
|
|
1490
|
-
/** 用户状态数据 */
|
|
1491
|
-
data: UserCampaignStatusInfo | null;
|
|
1492
|
-
/** 是否加载中 */
|
|
1493
|
-
isLoading: boolean;
|
|
1494
|
-
/** 错误信息 */
|
|
1495
|
-
error: string | null;
|
|
1496
|
-
/** 重新加载 */
|
|
1497
|
-
refetch: () => void;
|
|
1498
|
-
/**
|
|
1499
|
-
* 立即更新指定任务的本地状态(乐观更新)
|
|
1500
|
-
* @param taskId 任务 ID
|
|
1501
|
-
* @param isAsync 是否为异步任务(异步任务只更新 is_submitter)
|
|
1502
|
-
*/
|
|
1503
|
-
updateTaskStatus: (taskId: number, isAsync?: boolean) => void;
|
|
1504
|
-
}
|
|
1505
|
-
|
|
1506
876
|
/**
|
|
1507
877
|
* UserCenterWidget 外层组件
|
|
1508
878
|
*
|
|
@@ -1560,7 +930,15 @@ export { UserInfo }
|
|
|
1560
930
|
*
|
|
1561
931
|
* @example
|
|
1562
932
|
* ```tsx
|
|
1563
|
-
* const {
|
|
933
|
+
* const {
|
|
934
|
+
* login,
|
|
935
|
+
* logout,
|
|
936
|
+
* userId,
|
|
937
|
+
* isLoggedIn,
|
|
938
|
+
* isInitializing,
|
|
939
|
+
* isSessionReady,
|
|
940
|
+
* requestLogin,
|
|
941
|
+
* } = useTaskOnAuth();
|
|
1564
942
|
*
|
|
1565
943
|
* // EVM wallet login
|
|
1566
944
|
* await login({ method: 'evm_wallet', value: '0x...', sign, timestamp });
|
|
@@ -1579,6 +957,7 @@ export declare function useTaskOnAuth(): {
|
|
|
1579
957
|
userId: number | null;
|
|
1580
958
|
isLoggedIn: boolean;
|
|
1581
959
|
isInitializing: boolean;
|
|
960
|
+
isSessionReady: boolean;
|
|
1582
961
|
login: (params: LoginParams) => Promise<void>;
|
|
1583
962
|
logout: () => void;
|
|
1584
963
|
requestLogin: () => void;
|
|
@@ -1852,6 +1231,6 @@ export declare interface WalletState {
|
|
|
1852
1231
|
/**
|
|
1853
1232
|
* Supported widget names for preloading
|
|
1854
1233
|
*/
|
|
1855
|
-
export declare type WidgetName = "CommunityTask";
|
|
1234
|
+
export declare type WidgetName = "CommunityTask" | "Quest" | "TaskWidget" | "LeaderboardWidget" | "UserCenterWidget";
|
|
1856
1235
|
|
|
1857
1236
|
export { }
|