@opexa/portal-components 0.0.293 → 0.0.295
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/dist/client/hooks/useCheckInDailyCheckInQuestMutation.js +3 -0
- package/dist/components/Quests/JourneyQuest.js +82 -32
- package/dist/components/Quests/Quests.client.js +2 -2
- package/dist/services/queries.d.ts +2 -1
- package/dist/services/queries.js +29 -0
- package/dist/types/index.d.ts +10 -1
- package/dist/ui/AlertDialog/AlertDialog.d.ts +88 -88
- package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +8 -8
- package/dist/ui/Badge/Badge.d.ts +12 -12
- package/dist/ui/Badge/badge.anatomy.d.ts +1 -1
- package/dist/ui/Badge/badge.recipe.d.ts +3 -3
- package/dist/ui/Carousel/Carousel.d.ts +45 -45
- package/dist/ui/Carousel/carousel.recipe.d.ts +5 -5
- package/dist/ui/Checkbox/Checkbox.d.ts +23 -23
- package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
- package/dist/ui/Clipboard/Clipboard.d.ts +18 -18
- package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
- package/dist/ui/Collapsible/Collapsible.d.ts +20 -20
- package/dist/ui/Collapsible/collapsible.recipe.d.ts +5 -5
- package/dist/ui/Combobox/Combobox.d.ts +42 -42
- package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
- package/dist/ui/DatePicker/DatePicker.d.ts +72 -72
- package/dist/ui/DatePicker/datePicker.recipe.d.ts +3 -3
- package/dist/ui/Dialog/Dialog.d.ts +88 -88
- package/dist/ui/Dialog/dialog.recipe.d.ts +8 -8
- package/dist/ui/Drawer/Drawer.d.ts +33 -33
- package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
- package/dist/ui/Field/Field.d.ts +21 -21
- package/dist/ui/Field/field.recipe.d.ts +3 -3
- package/dist/ui/Menu/Menu.d.ts +252 -252
- package/dist/ui/Menu/menu.recipe.d.ts +14 -14
- package/dist/ui/NumberInput/NumberInput.d.ts +24 -24
- package/dist/ui/NumberInput/numberInput.recipe.d.ts +3 -3
- package/dist/ui/PasswordInput/PasswordInput.d.ts +18 -18
- package/dist/ui/PasswordInput/passwordInput.recipe.d.ts +3 -3
- package/dist/ui/PinInput/PinInput.d.ts +12 -12
- package/dist/ui/PinInput/pinInput.recipe.d.ts +3 -3
- package/dist/ui/Popover/Popover.d.ts +55 -55
- package/dist/ui/Popover/popover.recipe.d.ts +5 -5
- package/dist/ui/Progress/Progress.d.ts +27 -27
- package/dist/ui/Progress/progress.recipe.d.ts +3 -3
- package/dist/ui/QrCode/QrCode.d.ts +25 -25
- package/dist/ui/QrCode/qrCode.recipe.d.ts +5 -5
- package/dist/ui/SegmentGroup/SegmentGroup.d.ts +18 -18
- package/dist/ui/SegmentGroup/segmentGroup.recipe.d.ts +3 -3
- package/dist/ui/Select/Select.d.ts +45 -45
- package/dist/ui/Select/select.recipe.d.ts +3 -3
- package/dist/ui/Table/Table.d.ts +21 -21
- package/dist/ui/Table/table.anatomy.d.ts +1 -1
- package/dist/ui/Table/table.recipe.d.ts +3 -3
- package/dist/ui/Tabs/Tabs.d.ts +15 -15
- package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
- package/package.json +1 -1
|
@@ -29,6 +29,9 @@ export const useCheckInDailyCheckInQuestMutation = (config) => {
|
|
|
29
29
|
status: progressPercentage >= 100 ? 'COMPLETED' : quest.status,
|
|
30
30
|
lastCheckInDate: new Date().toISOString(),
|
|
31
31
|
progressPercentage: progressPercentage.toFixed(2),
|
|
32
|
+
checkInStreak: quest.checkInStreak
|
|
33
|
+
? quest.checkInStreak + 1
|
|
34
|
+
: 1,
|
|
32
35
|
};
|
|
33
36
|
}
|
|
34
37
|
return quest;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { useCallback, useMemo } from 'react';
|
|
3
|
+
import { useShallow } from 'zustand/react/shallow';
|
|
2
4
|
import { useControllableState } from '../../client/hooks/useControllableState.js';
|
|
3
5
|
import { useDisclosure } from '../../client/hooks/useDisclosure.js';
|
|
6
|
+
import { useGlobalStore } from '../../client/hooks/useGlobalStore.js';
|
|
4
7
|
import { useLocaleInfo } from '../../client/hooks/useLocaleInfo.js';
|
|
5
8
|
import { CheckIcon } from '../../icons/CheckIcon.js';
|
|
6
9
|
import { XIcon } from '../../icons/XIcon.js';
|
|
@@ -9,41 +12,51 @@ import { Checkbox } from '../../ui/Checkbox/index.js';
|
|
|
9
12
|
import { Dialog } from '../../ui/Dialog/index.js';
|
|
10
13
|
import { Portal } from '../../ui/Portal/index.js';
|
|
11
14
|
import { Progress } from '../../ui/Progress/index.js';
|
|
15
|
+
import { Prose } from '../../ui/Prose/index.js';
|
|
12
16
|
import { formatNumber } from '../../utils/formatNumber.js';
|
|
13
17
|
import { getPercentage } from '../../utils/getPercentage.js';
|
|
18
|
+
import { useQuestContext } from './QuestsContext.js';
|
|
19
|
+
import { RemainingTime } from './RemainingTime.js';
|
|
14
20
|
export function JourneyQuest() {
|
|
15
21
|
const disclosure = useDisclosure();
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
22
|
+
const quest = useQuestContext();
|
|
23
|
+
const { milestones, totalMilestones, currentMilestone, progressPercentage } = useMemo(() => {
|
|
24
|
+
if (!quest?.milestones) {
|
|
25
|
+
return {
|
|
26
|
+
milestones: [],
|
|
27
|
+
totalMilestones: 0,
|
|
28
|
+
currentMilestone: 0,
|
|
29
|
+
progressPercentage: 0,
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
const transformedMilestones = quest.milestones.map((milestone) => ({
|
|
33
|
+
key: milestone.type,
|
|
34
|
+
label: milestone.name,
|
|
35
|
+
bonus: milestone.bonusAmount
|
|
36
|
+
? parseFloat(milestone.bonusAmount)
|
|
37
|
+
: null,
|
|
38
|
+
isCompleted: milestone.cleared,
|
|
39
|
+
id: milestone.id,
|
|
40
|
+
description: milestone.description,
|
|
41
|
+
}));
|
|
42
|
+
const completedCount = quest.milestones.filter((m) => m.cleared).length;
|
|
43
|
+
const total = quest.milestones.length;
|
|
44
|
+
return {
|
|
45
|
+
milestones: transformedMilestones,
|
|
46
|
+
totalMilestones: total,
|
|
47
|
+
currentMilestone: completedCount,
|
|
48
|
+
progressPercentage: quest.progressPercentage
|
|
49
|
+
? parseFloat(quest.progressPercentage)
|
|
50
|
+
: getPercentage(completedCount, total),
|
|
51
|
+
};
|
|
52
|
+
}, [quest]);
|
|
53
|
+
const progressValue = useMemo(() => {
|
|
54
|
+
return (progressPercentage || getPercentage(currentMilestone, totalMilestones));
|
|
55
|
+
}, [progressPercentage, currentMilestone, totalMilestones]);
|
|
56
|
+
const handleViewDetails = useCallback(() => {
|
|
57
|
+
disclosure.setOpen(true);
|
|
58
|
+
}, [disclosure]);
|
|
59
|
+
return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "border-border-primary bg-bg-tertiary flex h-full w-full flex-col space-y-6 rounded-2xl border px-4 pb-6 pt-5", children: [_jsxs("div", { className: "flex flex-col space-y-2", children: [_jsx("div", { className: "flex max-h-7.5 items-start justify-between", children: _jsx(RemainingTime, {}) }), _jsx("p", { className: "text-xl font-semibold", children: quest?.name || 'Journey Quest' }), _jsxs("div", { className: "flex w-full items-center space-x-2", children: [_jsx(Progress.Root, { max: 100, className: "bg-bg-primary h-2 rounded-full", value: progressValue, children: _jsx(Progress.Track, { children: _jsx(Progress.Range, { className: "bg-utility-brand-600" }) }) }), _jsxs("p", { className: "text-text-quarterary-brand text-xs", children: [currentMilestone, "/", totalMilestones] })] }), _jsx("div", { className: "flex w-full flex-col space-y-3", children: milestones.map((milestone) => (_jsx(QuestMilestone, { label: milestone.label, bonus: milestone.bonus, isCompleted: milestone.isCompleted }, milestone.key))) })] }), _jsx("div", { className: "flex h-full items-end", children: _jsx(Button, { size: "sm", onClick: handleViewDetails, "aria-label": "View Details", disabled: false, className: "disabled:bg-bg-primary disabled:text-text-disabled", children: "View Details" }) })] }), _jsx(Rules, { open: disclosure.open, onOpenChange: disclosure.setOpen, quest: quest, milestones: milestones })] }));
|
|
47
60
|
}
|
|
48
61
|
function Rules(props) {
|
|
49
62
|
const [open, setOpen] = useControllableState({
|
|
@@ -51,7 +64,44 @@ function Rules(props) {
|
|
|
51
64
|
defaultValue: props.defaultOpen ?? false,
|
|
52
65
|
onChange: props.onOpenChange,
|
|
53
66
|
});
|
|
54
|
-
|
|
67
|
+
const globalStore = useGlobalStore(useShallow((ctx) => ({
|
|
68
|
+
kyc: ctx.kyc,
|
|
69
|
+
depositWithdrawal: ctx.depositWithdrawal,
|
|
70
|
+
})));
|
|
71
|
+
const { quest, milestones } = useMemo(() => {
|
|
72
|
+
return {
|
|
73
|
+
quest: props.quest,
|
|
74
|
+
milestones: props.milestones || [],
|
|
75
|
+
};
|
|
76
|
+
}, [props.quest, props.milestones]);
|
|
77
|
+
const allMilestonesCompleted = useMemo(() => {
|
|
78
|
+
if (!milestones.length)
|
|
79
|
+
return false;
|
|
80
|
+
return milestones.every((milestone) => milestone.isCompleted);
|
|
81
|
+
}, [milestones]);
|
|
82
|
+
return (_jsx(Dialog.Root, { lazyMount: true, unmountOnExit: true, open: open, onOpenChange: (details) => setOpen(details.open), closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(Dialog.Backdrop, { className: "!z-[calc(var(--z-dialog)+1)]" }), _jsx(Dialog.Positioner, { className: "!z-[calc(var(--z-dialog)+2)] flex items-center justify-center", children: _jsxs(Dialog.Content, { className: "min-h-auto mx-auto max-w-[400px] overflow-y-auto rounded-xl px-4 py-5", children: [_jsx(Dialog.CloseTrigger, { children: _jsx(XIcon, {}) }), _jsxs("div", { className: "text-text-quarterary-brand group flex flex-col space-y-5 text-sm", children: [_jsx("h2", { className: "text-text-primary-900 text-lg font-semibold", children: quest?.name || 'Quest' }), _jsx("p", { children: quest?.description ||
|
|
83
|
+
'Ready for a challenge? Complete them all and get amazing rewards!' }), milestones.map((milestone) => (_jsxs("div", { className: "bg-bg-tertiary flex flex-col space-y-2.5 rounded-xl p-3", children: [_jsxs("div", { className: "flex items-center justify-between", children: [_jsx("p", { className: "text-base font-medium text-white", children: milestone.label }), milestone.isCompleted && (_jsx("div", { className: "border-utility-success-200 bg-utility-success-50 text-utility-success-700 flex w-fit items-center gap-1 rounded-full border px-2 py-0.5 text-xs font-medium", children: "Complete" }))] }), milestone.description ? (_jsx(Prose, { dangerouslySetInnerHTML: {
|
|
84
|
+
__html: milestone.description,
|
|
85
|
+
} })) : (_jsxs("p", { className: "ml-1", children: [milestone.key === 'REGISTRATION' &&
|
|
86
|
+
`Register and win Php ${milestone.bonus} Bonus`, milestone.key === 'ACCOUNT_VERIFICATION' &&
|
|
87
|
+
`Verify your account and get Php ${milestone.bonus} Bonus`, milestone.key === 'FIRST_DEPOSIT' &&
|
|
88
|
+
`Make your first deposit and get Php ${milestone.bonus} Bonus`, milestone.key === 'IOS_FIRST_LOGIN' &&
|
|
89
|
+
`Login using iOS and get Php ${milestone.bonus} Bonus`, milestone.key === 'ANDROID_FIRST_LOGIN' &&
|
|
90
|
+
`Login using Android and get Php ${milestone.bonus} Bonus`] })), !milestone.isCompleted &&
|
|
91
|
+
(milestone.key === 'ACCOUNT_VERIFICATION' ||
|
|
92
|
+
milestone.key === 'FIRST_DEPOSIT') && (_jsx(Button, { size: "sm", onClick: () => {
|
|
93
|
+
if (milestone.key === 'ACCOUNT_VERIFICATION') {
|
|
94
|
+
setOpen(false);
|
|
95
|
+
globalStore.kyc.setOpen(true);
|
|
96
|
+
}
|
|
97
|
+
if (milestone.key === 'FIRST_DEPOSIT') {
|
|
98
|
+
setOpen(false);
|
|
99
|
+
globalStore.depositWithdrawal.setOpen(true);
|
|
100
|
+
globalStore.depositWithdrawal.setTab('DEPOSIT');
|
|
101
|
+
}
|
|
102
|
+
}, "aria-label": `Complete ${milestone.label}`, children: milestone.key === 'FIRST_DEPOSIT'
|
|
103
|
+
? 'Deposit'
|
|
104
|
+
: 'Verify Account' }))] }, milestone.key))), quest?.bonus && (_jsx("div", { className: "flex h-full items-end", children: allMilestonesCompleted ? (_jsx(Button, { size: "sm", onClick: () => setOpen(false), "aria-label": "Close", className: "w-full", children: "Close" })) : (_jsx("div", { className: "bg-button-secondary-bg border-bg-primary-hover w-full rounded-md border px-3.5 py-2.5 text-center text-white", children: _jsxs("p", { children: ["Complete target to", ' ', _jsxs("span", { className: "text-brand-400", children: ["\u20B1", quest?.bonus] }), ' ', "bonus!"] }) })) }))] })] }) })] }) }));
|
|
55
105
|
}
|
|
56
106
|
function QuestMilestone({ label, bonus, isCompleted = false, }) {
|
|
57
107
|
const localeInfo = useLocaleInfo();
|
|
@@ -8,7 +8,7 @@ import { SpinnerIcon } from '../../icons/SpinnerIcon.js';
|
|
|
8
8
|
import closeChest from '../../images/close-chest.png';
|
|
9
9
|
import { SegmentGroup } from '../../ui/SegmentGroup/index.js';
|
|
10
10
|
import { DailyCheckInQuest } from './DailyCheckInQuest.js';
|
|
11
|
-
|
|
11
|
+
import { JourneyQuest } from './JourneyQuest.js';
|
|
12
12
|
import { OnboardingQuest } from './OnboardingQuest.js';
|
|
13
13
|
import { QuestContext } from './QuestsContext.js';
|
|
14
14
|
import { WageringQuest } from './WageringQuest.js';
|
|
@@ -16,7 +16,7 @@ const QUEST_COMPONENT_MAP = {
|
|
|
16
16
|
DAILY_CHECKIN: DailyCheckInQuest,
|
|
17
17
|
ONBOARDING: OnboardingQuest,
|
|
18
18
|
WAGERING: WageringQuest,
|
|
19
|
-
|
|
19
|
+
JOURNEY: JourneyQuest,
|
|
20
20
|
};
|
|
21
21
|
const TabDefinition = z.enum(['AVAILABLE', 'COMPLETED']);
|
|
22
22
|
export function Quests__client(props) {
|
|
@@ -109,8 +109,9 @@ export declare const SKIP_ONBOARDING = "\n mutation SkipOnboarding {\n skipO
|
|
|
109
109
|
export declare const QUEST_PROGRAM_FRAGMENT = "\n fragment QuestProgramFragment on QuestProgram {\n status\n type\n name\n description\n }\n";
|
|
110
110
|
export declare const DAILY_CHECKIN_FRAGMENT = "\n \n fragment QuestProgramFragment on QuestProgram {\n status\n type\n name\n description\n }\n\n fragment DailyCheckinQuestFragment on DailyCheckInQuest {\n id\n name\n description\n type\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n endDateTime\n dateTimeCreated\n lastCheckInDate\n startDateTime\n checkInStreak\n\n thirdDayBonusAmount\n seventhDayBonusAmount\n sixthDayBonusAmount\n }\n";
|
|
111
111
|
export declare const WAGERING_FRAGMENT = "\n fragment WageringQuestFragment on WageringQuest {\n bonus\n id\n name\n type\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n targetTurnover\n endDateTime\n dateTimeCreated\n }\n";
|
|
112
|
+
export declare const JOURNEY_FRAGMENT = "\n fragment JourneyQuestFragment on JourneyQuest {\n id\n name\n description\n program {\n ...QuestProgramFragment\n }\n status\n type\n progressPercentage\n bonus\n bonusAwarded\n dateTimeCreated\n endDateTime\n milestones {\n id\n type\n name\n bonusAmount\n cleared\n description\n }\n }\n";
|
|
112
113
|
export declare const ONBOARDING_QUEST_FRAGMENT = "\n fragment OnboardingQuestFragment on OnboardingQuest {\n id\n name\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n type\n progressPercentage\n bonus\n endDateTime\n dateTimeCreated\n firstDepositCompleted\n accountVerificationCompleted\n }\n";
|
|
113
|
-
export declare const AVAILABLE_QUESTS = "\n \n fragment WageringQuestFragment on WageringQuest {\n bonus\n id\n name\n type\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n targetTurnover\n endDateTime\n dateTimeCreated\n }\n\n \n \n fragment QuestProgramFragment on QuestProgram {\n status\n type\n name\n description\n }\n\n fragment DailyCheckinQuestFragment on DailyCheckInQuest {\n id\n name\n description\n type\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n endDateTime\n dateTimeCreated\n lastCheckInDate\n startDateTime\n checkInStreak\n\n thirdDayBonusAmount\n seventhDayBonusAmount\n sixthDayBonusAmount\n }\n\n \n fragment OnboardingQuestFragment on OnboardingQuest {\n id\n name\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n type\n progressPercentage\n bonus\n endDateTime\n dateTimeCreated\n firstDepositCompleted\n accountVerificationCompleted\n }\n\n\n query AvailableQuests {\n availableQuests {\n ... on Quest {\n ... on WageringQuest {\n ...WageringQuestFragment\n }\n ... on DailyCheckInQuest {\n ...DailyCheckinQuestFragment\n }\n ... on OnboardingQuest {\n ...OnboardingQuestFragment\n }\n }\n }\n }\n";
|
|
114
|
+
export declare const AVAILABLE_QUESTS = "\n \n fragment WageringQuestFragment on WageringQuest {\n bonus\n id\n name\n type\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n targetTurnover\n endDateTime\n dateTimeCreated\n }\n\n \n \n fragment QuestProgramFragment on QuestProgram {\n status\n type\n name\n description\n }\n\n fragment DailyCheckinQuestFragment on DailyCheckInQuest {\n id\n name\n description\n type\n program {\n ...QuestProgramFragment\n }\n\n status\n progressPercentage\n turnover\n endDateTime\n dateTimeCreated\n lastCheckInDate\n startDateTime\n checkInStreak\n\n thirdDayBonusAmount\n seventhDayBonusAmount\n sixthDayBonusAmount\n }\n\n \n fragment OnboardingQuestFragment on OnboardingQuest {\n id\n name\n description\n program {\n ...QuestProgramFragment\n }\n\n status\n type\n progressPercentage\n bonus\n endDateTime\n dateTimeCreated\n firstDepositCompleted\n accountVerificationCompleted\n }\n\n \n fragment JourneyQuestFragment on JourneyQuest {\n id\n name\n description\n program {\n ...QuestProgramFragment\n }\n status\n type\n progressPercentage\n bonus\n bonusAwarded\n dateTimeCreated\n endDateTime\n milestones {\n id\n type\n name\n bonusAmount\n cleared\n description\n }\n }\n\n\n query AvailableQuests {\n availableQuests {\n ... on Quest {\n ... on WageringQuest {\n ...WageringQuestFragment\n }\n ... on DailyCheckInQuest {\n ...DailyCheckinQuestFragment\n }\n ... on OnboardingQuest {\n ...OnboardingQuestFragment\n }\n ... on JourneyQuest {\n ...JourneyQuestFragment\n }\n }\n }\n }\n";
|
|
114
115
|
export declare const AVAILABLE_QUEST_IDS = "\n query AvailableQuestIds {\n availableQuests {\n ... on Node {\n id\n }\n }\n }\n";
|
|
115
116
|
export declare const CHECK_IN_DAILY_QUEST = "\n mutation checkInDailyCheckInQuest($input: CheckInDailyCheckInQuestInput!) {\n checkInDailyCheckInQuest(input: $input)\n }\n";
|
|
116
117
|
export declare const TOP_WINS = "\n query TopWins($first: Int) {\n topWins(first: $first) {\n id\n game {\n id\n name\n type\n provider\n }\n member {\n id\n name\n }\n multiplier\n payout\n }\n }\n";
|
package/dist/services/queries.js
CHANGED
|
@@ -2301,6 +2301,31 @@ export const WAGERING_FRAGMENT = /* GraphQL */ `
|
|
|
2301
2301
|
dateTimeCreated
|
|
2302
2302
|
}
|
|
2303
2303
|
`;
|
|
2304
|
+
export const JOURNEY_FRAGMENT = /* GraphQL */ `
|
|
2305
|
+
fragment JourneyQuestFragment on JourneyQuest {
|
|
2306
|
+
id
|
|
2307
|
+
name
|
|
2308
|
+
description
|
|
2309
|
+
program {
|
|
2310
|
+
...QuestProgramFragment
|
|
2311
|
+
}
|
|
2312
|
+
status
|
|
2313
|
+
type
|
|
2314
|
+
progressPercentage
|
|
2315
|
+
bonus
|
|
2316
|
+
bonusAwarded
|
|
2317
|
+
dateTimeCreated
|
|
2318
|
+
endDateTime
|
|
2319
|
+
milestones {
|
|
2320
|
+
id
|
|
2321
|
+
type
|
|
2322
|
+
name
|
|
2323
|
+
bonusAmount
|
|
2324
|
+
cleared
|
|
2325
|
+
description
|
|
2326
|
+
}
|
|
2327
|
+
}
|
|
2328
|
+
`;
|
|
2304
2329
|
export const ONBOARDING_QUEST_FRAGMENT = /* GraphQL */ `
|
|
2305
2330
|
fragment OnboardingQuestFragment on OnboardingQuest {
|
|
2306
2331
|
id
|
|
@@ -2324,6 +2349,7 @@ export const AVAILABLE_QUESTS = /* GraphQL */ `
|
|
|
2324
2349
|
${WAGERING_FRAGMENT}
|
|
2325
2350
|
${DAILY_CHECKIN_FRAGMENT}
|
|
2326
2351
|
${ONBOARDING_QUEST_FRAGMENT}
|
|
2352
|
+
${JOURNEY_FRAGMENT}
|
|
2327
2353
|
|
|
2328
2354
|
query AvailableQuests {
|
|
2329
2355
|
availableQuests {
|
|
@@ -2337,6 +2363,9 @@ export const AVAILABLE_QUESTS = /* GraphQL */ `
|
|
|
2337
2363
|
... on OnboardingQuest {
|
|
2338
2364
|
...OnboardingQuestFragment
|
|
2339
2365
|
}
|
|
2366
|
+
... on JourneyQuest {
|
|
2367
|
+
...JourneyQuestFragment
|
|
2368
|
+
}
|
|
2340
2369
|
}
|
|
2341
2370
|
}
|
|
2342
2371
|
}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -684,7 +684,7 @@ export interface Message {
|
|
|
684
684
|
}
|
|
685
685
|
export type OnboardingStatus = 'PENDING' | 'SKIPPED' | 'COMPLETED';
|
|
686
686
|
export type OnboardingPlayerExperience = 'ROOKIE' | 'VETERAN';
|
|
687
|
-
export type QuestType = 'WAGERING' | 'DAILY_CHECKIN' | 'ONBOARDING';
|
|
687
|
+
export type QuestType = 'WAGERING' | 'DAILY_CHECKIN' | 'ONBOARDING' | 'JOURNEY';
|
|
688
688
|
export type QuestStatus = 'IN_PROGRESS' | 'COMPLETED' | 'FAILED';
|
|
689
689
|
export type QuestProgramStatus = 'ACTIVE' | 'INACTIVE' | 'DELETED';
|
|
690
690
|
export interface QuestProgram {
|
|
@@ -694,6 +694,15 @@ export interface QuestProgram {
|
|
|
694
694
|
description: string;
|
|
695
695
|
}
|
|
696
696
|
export type MemberStatus = 'ACTIVE' | 'BLACKLISTED' | 'SUSPENDED';
|
|
697
|
+
export type JourneyQuestMilestoneType = 'REGISTRATION' | 'ACCOUNT_VERIFICATION' | 'FIRST_DEPOSIT' | 'IOS_FIRST_LOGIN' | 'ANDROID_FIRST_LOGIN' | 'CUSTOM';
|
|
698
|
+
export interface JourneyQuestMilestone {
|
|
699
|
+
id: string;
|
|
700
|
+
type: JourneyQuestMilestoneType;
|
|
701
|
+
name: string;
|
|
702
|
+
bonusAmount: string;
|
|
703
|
+
cleared: boolean;
|
|
704
|
+
description: string;
|
|
705
|
+
}
|
|
697
706
|
export interface Quest {
|
|
698
707
|
id: string;
|
|
699
708
|
name: string;
|