@opexa/portal-components 0.0.54 → 0.0.55

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.
Files changed (55) hide show
  1. package/dist/components/JackpotCounter/JackpotCounterItem.module.css +184 -184
  2. package/dist/components/Promos/PromoItem.js +1 -1
  3. package/dist/styles/theme.css +696 -696
  4. package/dist/tsconfig.build.tsbuildinfo +1 -1
  5. package/dist/ui/AlertDialog/AlertDialog.d.ts +154 -154
  6. package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +14 -14
  7. package/dist/ui/Badge/Badge.d.ts +12 -12
  8. package/dist/ui/Badge/badge.recipe.d.ts +3 -3
  9. package/dist/ui/Checkbox/Checkbox.d.ts +23 -23
  10. package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
  11. package/dist/ui/Clipboard/Clipboard.d.ts +18 -18
  12. package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
  13. package/dist/ui/Collapsible/Collapsible.d.ts +20 -20
  14. package/dist/ui/Collapsible/collapsible.recipe.d.ts +5 -5
  15. package/dist/ui/Combobox/Combobox.d.ts +42 -42
  16. package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
  17. package/dist/ui/DatePicker/DatePicker.d.ts +192 -192
  18. package/dist/ui/DatePicker/datePicker.recipe.d.ts +8 -8
  19. package/dist/ui/Dialog/Dialog.d.ts +154 -154
  20. package/dist/ui/Dialog/dialog.recipe.d.ts +14 -14
  21. package/dist/ui/Drawer/Drawer.d.ts +33 -33
  22. package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
  23. package/dist/ui/PasswordInput/PasswordInput.d.ts +18 -18
  24. package/dist/ui/PasswordInput/passwordInput.recipe.d.ts +3 -3
  25. package/dist/ui/Popover/Popover.d.ts +88 -88
  26. package/dist/ui/Popover/popover.recipe.d.ts +8 -8
  27. package/dist/ui/Select/Select.d.ts +45 -45
  28. package/dist/ui/Select/select.recipe.d.ts +3 -3
  29. package/dist/ui/Table/Table.d.ts +21 -21
  30. package/dist/ui/Table/table.recipe.d.ts +3 -3
  31. package/dist/ui/Tabs/Tabs.d.ts +15 -15
  32. package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
  33. package/package.json +156 -156
  34. package/dist/components/AccountPaymentMethods/AccountPaymentMethods.d.ts +0 -1
  35. package/dist/components/AccountPaymentMethods/AccountPaymentMethods.js +0 -3
  36. package/dist/components/AccountPaymentMethods/index.d.ts +0 -1
  37. package/dist/components/AccountPaymentMethods/index.js +0 -1
  38. package/dist/components/AccountVerification/AccountVerificationContext.d.ts +0 -14
  39. package/dist/components/AccountVerification/AccountVerificationContext.js +0 -27
  40. package/dist/components/AccountVerification/VerificationCapture.d.ts +0 -1
  41. package/dist/components/AccountVerification/VerificationCapture.js +0 -28
  42. package/dist/components/AccountVerification/VerificationComplete.d.ts +0 -1
  43. package/dist/components/AccountVerification/VerificationComplete.js +0 -9
  44. package/dist/components/AccountVerification/VerificationDetails.d.ts +0 -1
  45. package/dist/components/AccountVerification/VerificationDetails.js +0 -38
  46. package/dist/components/GamesSearch/GamesSearchTrigger.d.ts +0 -5
  47. package/dist/components/GamesSearch/GamesSearchTrigger.js +0 -14
  48. package/dist/components/KYC/AccountVerificationContext.d.ts +0 -14
  49. package/dist/components/KYC/AccountVerificationContext.js +0 -27
  50. package/dist/components/KYC/VerificationCapture.d.ts +0 -1
  51. package/dist/components/KYC/VerificationCapture.js +0 -28
  52. package/dist/components/KYC/VerificationComplete.d.ts +0 -1
  53. package/dist/components/KYC/VerificationComplete.js +0 -9
  54. package/dist/components/KYC/VerificationDetails.d.ts +0 -1
  55. package/dist/components/KYC/VerificationDetails.js +0 -38
package/package.json CHANGED
@@ -1,156 +1,156 @@
1
- {
2
- "name": "@opexa/portal-components",
3
- "version": "0.0.54",
4
- "exports": {
5
- ".": {
6
- "types": "./dist/components/index.d.ts",
7
- "default": "./dist/components/index.js"
8
- },
9
- "./ui": {
10
- "types": "./dist/ui/index.d.ts",
11
- "default": "./dist/ui/index.js"
12
- },
13
- "./utils": {
14
- "types": "./dist/utils/index.d.ts",
15
- "import": "./dist/utils/index.js"
16
- },
17
- "./types": {
18
- "types": "./dist/types/index.d.ts",
19
- "import": "./dist/types/index.js"
20
- },
21
- "./handlers": {
22
- "types": "./dist/handlers.d.ts",
23
- "default": "./dist/handlers.js"
24
- },
25
- "./middleware": {
26
- "types": "./dist/middleware.d.ts",
27
- "default": "./dist/middleware.js"
28
- },
29
- "./client-utils": {
30
- "types": "./dist/client/utils/index.d.ts",
31
- "import": "./dist/client/utils/index.mjs",
32
- "require": "./dist/client/utils/index.js"
33
- },
34
- "./client-hooks": {
35
- "types": "./dist/client/hooks/index.d.ts",
36
- "default": "./dist/client/hooks/index.js"
37
- },
38
- "./client-services": {
39
- "types": "./dist/client/services/index.d.ts",
40
- "default": "./dist/client/services/index.js"
41
- },
42
- "./server-utils": {
43
- "types": "./dist/server/utils/index.d.ts",
44
- "default": "./dist/server/utils/index.js"
45
- },
46
- "./server-services": {
47
- "types": "./dist/server/services/index.d.ts",
48
- "default": "./dist/server/services/index.js"
49
- },
50
- "./next.config": {
51
- "types": "./dist/next.config.d.ts",
52
- "default": "./dist/next.config.js"
53
- },
54
- "./theme.css": "./dist/styles/theme.css",
55
- "./package.json": "./package.json"
56
- },
57
- "files": [
58
- "dist"
59
- ],
60
- "publishConfig": {
61
- "access": "public"
62
- },
63
- "scripts": {
64
- "dev": "next dev --port 4000 --turbopack",
65
- "build": "tsc --project tsconfig.build.json && tsc-alias -p tsconfig.build.json && copy-files-from-to",
66
- "build:app": "next build",
67
- "start": "next start",
68
- "lint": "next lint",
69
- "release": "release-it"
70
- },
71
- "dependencies": {
72
- "@ark-ui/anatomy": "3.5.0",
73
- "@ark-ui/react": "5.11.0",
74
- "@date-fns/tz": "^1.2.0",
75
- "@next/third-parties": "^15.3.3",
76
- "@tailwindcss/typography": "0.5.16",
77
- "date-fns": "4.1.0",
78
- "embla-carousel-autoplay": "8.6.0",
79
- "embla-carousel-react": "8.6.0",
80
- "is-mobile": "^5.0.0",
81
- "lodash-es": "4.17.21",
82
- "next-themes": "^0.4.6",
83
- "tailwind-merge": "3.3.0",
84
- "tailwind-variants": "1.0.0",
85
- "tailwindcss-plugin-zag": "0.1.0",
86
- "tiny-invariant": "1.3.3",
87
- "type-fest": "4.41.0",
88
- "usehooks-ts": "3.1.1",
89
- "zustand": "5.0.5"
90
- },
91
- "devDependencies": {
92
- "@eslint/eslintrc": "3",
93
- "@hookform/resolvers": "5.0.1",
94
- "@opexa/portal-sdk-core": "0.0.33",
95
- "@tailwindcss/postcss": "4",
96
- "@tanstack/react-query": "5.80.0",
97
- "@tanstack/react-query-devtools": "5.80.0",
98
- "@total-typescript/ts-reset": "0.6.1",
99
- "@types/lodash-es": "4.17.12",
100
- "@types/node": "22",
101
- "@types/react": "19",
102
- "@types/react-dom": "19",
103
- "copy-files-from-to": "^3.12.1",
104
- "eslint": "9",
105
- "eslint-config-next": "15.3.3",
106
- "next": "15.4.0-canary.61",
107
- "react": "19.1.0",
108
- "react-dom": "19.1.0",
109
- "react-hook-form": "7.57.0",
110
- "release-it": "19.0.3",
111
- "tailwindcss": "4.1.8",
112
- "tsc-alias": "^1.8.16",
113
- "typescript": "5",
114
- "zod": "3.25.49"
115
- },
116
- "peerDependencies": {
117
- "@hookform/resolvers": "^4.0.0 || ^5.0.0",
118
- "@opexa/portal-sdk-core": "^0.0.32",
119
- "@tanstack/react-query": "^5.0.0",
120
- "next": "^15.4.0-canary.1",
121
- "react": "^19.0.0",
122
- "react-dom": "^19.0.0",
123
- "react-hook-form": "^7.0.0",
124
- "tailwindcss": "^4.0.0",
125
- "zod": "^3.0.0"
126
- },
127
- "release-it": {
128
- "git": {
129
- "commitMessage": "chore: release ${npm.name} v${version}",
130
- "tagName": "${npm.name}@${version}"
131
- },
132
- "github": {
133
- "release": false
134
- },
135
- "hooks": {
136
- "before:bump": [
137
- "pnpm lint"
138
- ],
139
- "after:bump": [
140
- "pnpm build"
141
- ]
142
- }
143
- },
144
- "copyFiles": [
145
- {
146
- "from": "src/lib/**/*.{png,jpg,jpeg,gif,svg,css,json}",
147
- "to": "dist/",
148
- "toFlat": false
149
- }
150
- ],
151
- "copyFilesSettings": {
152
- "whenFileExists": "overwrite",
153
- "removeSourceMappingURL": true,
154
- "ignoreDotFilesAndFolders": false
155
- }
156
- }
1
+ {
2
+ "name": "@opexa/portal-components",
3
+ "version": "0.0.55",
4
+ "exports": {
5
+ ".": {
6
+ "types": "./dist/components/index.d.ts",
7
+ "default": "./dist/components/index.js"
8
+ },
9
+ "./ui": {
10
+ "types": "./dist/ui/index.d.ts",
11
+ "default": "./dist/ui/index.js"
12
+ },
13
+ "./utils": {
14
+ "types": "./dist/utils/index.d.ts",
15
+ "import": "./dist/utils/index.js"
16
+ },
17
+ "./types": {
18
+ "types": "./dist/types/index.d.ts",
19
+ "import": "./dist/types/index.js"
20
+ },
21
+ "./handlers": {
22
+ "types": "./dist/handlers.d.ts",
23
+ "default": "./dist/handlers.js"
24
+ },
25
+ "./middleware": {
26
+ "types": "./dist/middleware.d.ts",
27
+ "default": "./dist/middleware.js"
28
+ },
29
+ "./client-utils": {
30
+ "types": "./dist/client/utils/index.d.ts",
31
+ "import": "./dist/client/utils/index.mjs",
32
+ "require": "./dist/client/utils/index.js"
33
+ },
34
+ "./client-hooks": {
35
+ "types": "./dist/client/hooks/index.d.ts",
36
+ "default": "./dist/client/hooks/index.js"
37
+ },
38
+ "./client-services": {
39
+ "types": "./dist/client/services/index.d.ts",
40
+ "default": "./dist/client/services/index.js"
41
+ },
42
+ "./server-utils": {
43
+ "types": "./dist/server/utils/index.d.ts",
44
+ "default": "./dist/server/utils/index.js"
45
+ },
46
+ "./server-services": {
47
+ "types": "./dist/server/services/index.d.ts",
48
+ "default": "./dist/server/services/index.js"
49
+ },
50
+ "./next.config": {
51
+ "types": "./dist/next.config.d.ts",
52
+ "default": "./dist/next.config.js"
53
+ },
54
+ "./theme.css": "./dist/styles/theme.css",
55
+ "./package.json": "./package.json"
56
+ },
57
+ "files": [
58
+ "dist"
59
+ ],
60
+ "publishConfig": {
61
+ "access": "public"
62
+ },
63
+ "scripts": {
64
+ "dev": "next dev --port 4000 --turbopack",
65
+ "build": "tsc --project tsconfig.build.json && tsc-alias -p tsconfig.build.json && copy-files-from-to",
66
+ "build:app": "next build",
67
+ "start": "next start",
68
+ "lint": "next lint",
69
+ "release": "release-it"
70
+ },
71
+ "dependencies": {
72
+ "@ark-ui/anatomy": "3.5.0",
73
+ "@ark-ui/react": "5.11.0",
74
+ "@date-fns/tz": "^1.2.0",
75
+ "@next/third-parties": "^15.3.3",
76
+ "@tailwindcss/typography": "0.5.16",
77
+ "date-fns": "4.1.0",
78
+ "embla-carousel-autoplay": "8.6.0",
79
+ "embla-carousel-react": "8.6.0",
80
+ "is-mobile": "^5.0.0",
81
+ "lodash-es": "4.17.21",
82
+ "next-themes": "^0.4.6",
83
+ "tailwind-merge": "3.3.0",
84
+ "tailwind-variants": "1.0.0",
85
+ "tailwindcss-plugin-zag": "0.1.0",
86
+ "tiny-invariant": "1.3.3",
87
+ "type-fest": "4.41.0",
88
+ "usehooks-ts": "3.1.1",
89
+ "zustand": "5.0.5"
90
+ },
91
+ "devDependencies": {
92
+ "@eslint/eslintrc": "3",
93
+ "@hookform/resolvers": "5.0.1",
94
+ "@opexa/portal-sdk-core": "0.0.33",
95
+ "@tailwindcss/postcss": "4",
96
+ "@tanstack/react-query": "5.80.0",
97
+ "@tanstack/react-query-devtools": "5.80.0",
98
+ "@total-typescript/ts-reset": "0.6.1",
99
+ "@types/lodash-es": "4.17.12",
100
+ "@types/node": "22",
101
+ "@types/react": "19",
102
+ "@types/react-dom": "19",
103
+ "copy-files-from-to": "^3.12.1",
104
+ "eslint": "9",
105
+ "eslint-config-next": "15.3.3",
106
+ "next": "15.4.0-canary.61",
107
+ "react": "19.1.0",
108
+ "react-dom": "19.1.0",
109
+ "react-hook-form": "7.57.0",
110
+ "release-it": "19.0.3",
111
+ "tailwindcss": "4.1.8",
112
+ "tsc-alias": "^1.8.16",
113
+ "typescript": "5",
114
+ "zod": "3.25.49"
115
+ },
116
+ "peerDependencies": {
117
+ "@hookform/resolvers": "^4.0.0 || ^5.0.0",
118
+ "@opexa/portal-sdk-core": "^0.0.32",
119
+ "@tanstack/react-query": "^5.0.0",
120
+ "next": "^15.4.0-canary.1",
121
+ "react": "^19.0.0",
122
+ "react-dom": "^19.0.0",
123
+ "react-hook-form": "^7.0.0",
124
+ "tailwindcss": "^4.0.0",
125
+ "zod": "^3.0.0"
126
+ },
127
+ "release-it": {
128
+ "git": {
129
+ "commitMessage": "chore: release ${npm.name} v${version}",
130
+ "tagName": "${npm.name}@${version}"
131
+ },
132
+ "github": {
133
+ "release": false
134
+ },
135
+ "hooks": {
136
+ "before:bump": [
137
+ "pnpm lint"
138
+ ],
139
+ "after:bump": [
140
+ "pnpm build"
141
+ ]
142
+ }
143
+ },
144
+ "copyFiles": [
145
+ {
146
+ "from": "src/lib/**/*.{png,jpg,jpeg,gif,svg,css,json}",
147
+ "to": "dist/",
148
+ "toFlat": false
149
+ }
150
+ ],
151
+ "copyFilesSettings": {
152
+ "whenFileExists": "overwrite",
153
+ "removeSourceMappingURL": true,
154
+ "ignoreDotFilesAndFolders": false
155
+ }
156
+ }
@@ -1 +0,0 @@
1
- export declare function AccountPaymentMethods(): null;
@@ -1,3 +0,0 @@
1
- export function AccountPaymentMethods() {
2
- return null;
3
- }
@@ -1 +0,0 @@
1
- export * from './AccountPaymentMethods';
@@ -1 +0,0 @@
1
- export * from './AccountPaymentMethods.js';
@@ -1,14 +0,0 @@
1
- type Step = 1 | 2 | 3 | (number & {});
2
- interface UseAccountVerificationReturn {
3
- step: Step;
4
- setStep: (step: Step) => void;
5
- started: boolean;
6
- setStarted: (started: boolean) => void;
7
- completed: boolean;
8
- setCompleted: (completed: boolean) => void;
9
- reset: () => void;
10
- }
11
- export declare function useAccountVerification(): UseAccountVerificationReturn;
12
- export declare const AccountVerificationContext: import("react").Context<UseAccountVerificationReturn | null>;
13
- export declare function useAccountVerificationContext(): UseAccountVerificationReturn;
14
- export {};
@@ -1,27 +0,0 @@
1
- import { createContext, useContext, useState } from 'react';
2
- import invariant from 'tiny-invariant';
3
- export function useAccountVerification() {
4
- const [step, setStep] = useState(1);
5
- const [started, setStarted] = useState(false);
6
- const [completed, setCompleted] = useState(false);
7
- function reset() {
8
- setStep(1);
9
- setStarted(false);
10
- setCompleted(false);
11
- }
12
- return {
13
- step,
14
- setStep,
15
- started,
16
- setStarted,
17
- completed,
18
- setCompleted,
19
- reset,
20
- };
21
- }
22
- export const AccountVerificationContext = createContext(null);
23
- export function useAccountVerificationContext() {
24
- const context = useContext(AccountVerificationContext);
25
- invariant(context);
26
- return context;
27
- }
@@ -1 +0,0 @@
1
- export declare function VerificationCapture(): import("react/jsx-runtime").JSX.Element | null;
@@ -1,28 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { noop } from 'lodash-es';
3
- import Image from 'next/image';
4
- import { ArrowLeftIcon, CheckIcon, XIcon } from '../../icons/index.js';
5
- import uploadId from '../../images/capture-id-banner.png';
6
- import selfie from '../../images/capture-selfie-banner.png';
7
- import { Button, Checkbox, Field, Progress } from '../../ui/index.js';
8
- import { useAccountVerificationContext } from './AccountVerificationContext.js';
9
- export function VerificationCapture() {
10
- const context = useAccountVerificationContext();
11
- if (!context.started)
12
- return null;
13
- return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "grid grid-cols-4 items-center", children: [_jsxs("button", { className: "text-text-tertiary-600 flex gap-sm text-sm font-semibold", disabled: context.step <= 1, onClick: () => context.setStep(context.step - 1), children: [_jsx(ArrowLeftIcon, { className: "size-5" }), "Back"] }), _jsxs("div", { className: "col-span-2 flex justify-center gap-2", children: [_jsx(Progress.Root, { value: context.step >= 2 ? 100 : context.step >= 1 ? 50 : 0, onValueChange: noop, className: "w-22.5 shrink-0", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx(Progress.Root, { value: context.completed ? 100 : context.step >= 3 ? 50 : 0, onValueChange: noop, className: "w-22.5 shrink-0", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) })] })] }), context.step === 1 && _jsx(Step1, {}), context.step === 2 && _jsx(Step2, {}), context.step === 3 && _jsx(Step3, {})] }));
14
- }
15
- function Step1() {
16
- const context = useAccountVerificationContext();
17
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Prepare to upload your ID" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsx(Image, { src: uploadId, alt: "", className: "h-auto w-full", width: 600, height: 352 }), _jsxs("ul", { className: "mt-2xl space-y-3", children: [_jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Upload front side of your ID"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Take a photo in a well lit room"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(XIcon, { className: "text-text-featured-icon-light-error size-6" }), "Don't edit image of your ID"] })] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => context.setStep(2), children: "Continue" }) })] })] }));
18
- }
19
- function Step2() {
20
- const context = useAccountVerificationContext();
21
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Take a selfie holding your ID" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsx(Image, { src: selfie, alt: "", className: "h-auto w-full", width: 600, height: 352 }), _jsxs("ul", { className: "mt-2xl space-y-3", children: [_jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Face and ID must be clearly visible"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Take a photo in a well lit room"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(XIcon, { className: "text-text-featured-icon-light-error size-6" }), "No hats, sunglasses, or masks"] })] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => context.setStep(3), children: "Continue" }) })] })] }));
22
- }
23
- function Step3() {
24
- const context = useAccountVerificationContext();
25
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Enter your basic and work-related information" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsxs(Field.Root, { children: [_jsx(Field.Label, { children: "Permanent address" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Current address" }), _jsx(Field.Input, {})] }), _jsxs(Checkbox.Root, { className: "mt-sm", children: [_jsx(Checkbox.Control, { children: _jsx(Checkbox.Indicator, { asChild: true, children: _jsx(CheckIcon, {}) }) }), _jsx(Checkbox.Label, { children: "Same as permanent address" }), _jsx(Checkbox.HiddenInput, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Source of income" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Nature of work" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Place of birth" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Nationality" }), _jsx(Field.Input, {})] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => {
26
- context.setCompleted(true);
27
- }, children: "Continue" }) })] })] }));
28
- }
@@ -1 +0,0 @@
1
- export declare function VerificationComplete(): import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Portal } from '@ark-ui/react';
3
- import { CheckCircleIcon } from '../../icons/index.js';
4
- import { AlertDialog, Button } from '../../ui/index.js';
5
- import { useAccountVerificationContext } from './AccountVerificationContext.js';
6
- export function VerificationComplete() {
7
- const context = useAccountVerificationContext();
8
- return (_jsx(AlertDialog.Root, { open: context.completed, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, { className: "bg-bg-overlay/75 backdrop-blur-sm" }), _jsx(AlertDialog.Positioner, { children: _jsxs(AlertDialog.Content, { className: "mx-auto w-[21.438rem] p-xl", children: [_jsx("div", { className: "bg-bg-success-secondary text-text-featured-icon-light-success mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(CheckCircleIcon, {}) }), _jsx(AlertDialog.Title, { className: "mt-3 text-center", children: "Submission Successful" }), _jsx(AlertDialog.Description, { className: "text-text-tertiary-600 text-center", children: "Your documents have been submitted successfully. They\u2019re now under review, and you\u2019ll receive a notification as soon as your account is verified." }), _jsx(Button, { className: "mt-3xl", onClick: () => context.reset(), children: "Ok" })] }) })] }) }));
9
- }
@@ -1 +0,0 @@
1
- export declare function VerificationDetails(): import("react/jsx-runtime").JSX.Element | null;
@@ -1,38 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { ark } from '@ark-ui/react';
3
- import { twMerge } from 'tailwind-merge';
4
- import { useMemberVerificationQuery, useProfileCompletionQuery, } from '../../client/hooks/index.js';
5
- import { AlertCircleIcon, CheckVerified02Icon, CreditCard02Icon, FaceIdIcon, FileCheck02Icon, FileSearch02Icon, FileX02Icon, Globe05Icon, } from '../../icons/index.js';
6
- import { Button } from '../../ui/index.js';
7
- import { useAccountVerificationContext } from './AccountVerificationContext.js';
8
- export function VerificationDetails() {
9
- const context = useAccountVerificationContext();
10
- const profileCompletionQuery = useProfileCompletionQuery();
11
- const profileCompletion = profileCompletionQuery.data;
12
- const verificationQuery = useMemberVerificationQuery();
13
- const verification = verificationQuery.data;
14
- const empty = verification == null;
15
- const pending = verification?.status === 'PENDING';
16
- const success = verification?.status === 'VERIFIED' || verification?.status === 'APPROVED';
17
- const failed = verification?.status === 'REJECTED' ||
18
- verification?.status === 'UNVERIFIED';
19
- if (context.started)
20
- return null;
21
- return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "flex items-start gap-8", children: [_jsxs("div", { className: "grow", children: [_jsx("h2", { className: "text-text-secondary-700 text-sm font-semibold", children: "Verify your identity" }), _jsx("p", { className: "text-text-tertiary-600 text-sm", children: "Complete personal verification to unlock all features and enhance account security." })] }), _jsx(ark.svg, { asChild: true, className: twMerge('size-6', profileCompletion?.accountVerification
22
- ? 'text-text-success-primary'
23
- : 'text-text-warning-primary'), children: profileCompletion?.accountVerification ? (_jsx(CheckVerified02Icon, {})) : (_jsx(AlertCircleIcon, {})) })] }), _jsxs("div", { className: "shadow-xs border-border-secondary bg-bg-primary-alt mt-5 rounded-xl border", children: [_jsx("div", { className: "px-4 py-5", children: _jsxs("ul", { className: "space-y-lg", children: [_jsxs("li", { className: "text-text-secondary-700 icon:size-6 icon:text-text-nav-item-button-icon flex items-center gap-lg", children: [_jsx(FileCheck02Icon, {}), "Basic Information"] }), _jsxs("li", { className: "text-text-secondary-700 icon:size-6 icon:text-text-nav-item-button-icon flex items-center gap-lg", children: [_jsx(Globe05Icon, {}), "Proof of address"] }), _jsxs("li", { className: "text-text-secondary-700 icon:size-6 icon:text-text-nav-item-button-icon flex items-center gap-lg", children: [_jsx(CreditCard02Icon, {}), "Government ID"] }), _jsxs("li", { className: "text-text-secondary-700 icon:size-6 icon:text-text-nav-item-button-icon flex items-center gap-lg", children: [_jsx(FaceIdIcon, {}), "Facial Verification"] })] }) }), _jsx("div", { className: "border-border-secondary flex justify-end border-t px-4 py-3 lg:py-xl", children: _jsx(Button, { size: "sm", onClick: () => {
24
- context.setStarted(true);
25
- }, className: "w-full lg:w-fit", children: "Verify Now" }) })] }), success && _jsx(VerificationSuccess, {}), pending && _jsx(VerificationInProgress, {}), failed && _jsx(VerificationFailed, {}), empty && _jsx(VerificationNotSubmitted, {})] }));
26
- }
27
- function VerificationNotSubmitted() {
28
- return (_jsxs("div", { className: "shadow-xs border-border-primary bg-bg-primary-alt mt-6 flex flex-col gap-2 rounded-xl border p-xl lg:flex-row", children: [_jsx("div", { className: "border-text-warning-primary/10 flex size-[2.1875rem] items-center justify-center rounded-full border-2", children: _jsx("div", { className: "border-text-warning-primary/30 flex size-[1.666625rem] items-center justify-center rounded-full border-2", children: _jsx(AlertCircleIcon, { className: "text-text-warning-primary size-5" }) }) }), _jsx("p", { className: "text-text-tertiary-600 max-w-[800px] text-sm", children: "To serve you better and unlock all features, please provide valid identification documents. This helps protect your account and makes recovery easier if ever needed." })] }));
29
- }
30
- function VerificationInProgress() {
31
- return (_jsxs("div", { className: "shadow-xs border-border-primary bg-bg-primary-alt mt-6 flex flex-col gap-2 rounded-xl border p-xl lg:flex-row", children: [_jsx("div", { className: "border-text-warning-primary/10 flex size-[2.1875rem] items-center justify-center rounded-full border-2", children: _jsx("div", { className: "border-text-warning-primary/30 flex size-[1.666625rem] items-center justify-center rounded-full border-2", children: _jsx(FileSearch02Icon, { className: "text-text-warning-primary size-5" }) }) }), _jsxs("div", { children: [_jsx("h2", { className: "text-text-secondary-700 text-sm font-semibold", children: "Under review" }), _jsx("p", { className: "text-text-tertiary-600 mt-xs text-sm", children: "To serve you better and unlock all features, please provide valid identification documents. This helps protect your account and makes recovery easier if ever needed." })] })] }));
32
- }
33
- function VerificationSuccess() {
34
- return (_jsxs("div", { className: "shadow-xs border-border-primary bg-bg-primary-alt mt-6 flex flex-col gap-2 rounded-xl border p-xl lg:flex-row", children: [_jsx("div", { className: "border-text-success-primary/10 flex size-[2.1875rem] items-center justify-center rounded-full border-2", children: _jsx("div", { className: "border-text-success-primary/30 flex size-[1.666625rem] items-center justify-center rounded-full border-2", children: _jsx(FileCheck02Icon, { className: "text-text-success-primary size-5" }) }) }), _jsxs("div", { children: [_jsx("h2", { className: "text-text-secondary-700 text-sm font-semibold", children: "Verification successful" }), _jsx("p", { className: "text-text-tertiary-600 mt-xs text-sm", children: "Your account has been successfully verified. You now have full access to all features and improved account security." })] })] }));
35
- }
36
- function VerificationFailed() {
37
- return (_jsxs("div", { className: "shadow-xs border-border-primary bg-bg-primary-alt mt-6 flex flex-col gap-2 rounded-xl border p-xl lg:flex-row", children: [_jsx("div", { className: "border-text-error-primary/10 flex size-[2.1875rem] items-center justify-center rounded-full border-2", children: _jsx("div", { className: "border-text-error-primary/30 flex size-[1.666625rem] items-center justify-center rounded-full border-2", children: _jsx(FileX02Icon, { className: "text-text-error-primary size-5" }) }) }), _jsxs("div", { children: [_jsx("h2", { className: "text-text-secondary-700 text-sm font-semibold", children: "Verification failed" }), _jsx("p", { className: "text-text-tertiary-600 mt-xs text-sm", children: "There was an issue with the verification process. Please try again or contact support for assistance." })] })] }));
38
- }
@@ -1,5 +0,0 @@
1
- import type { ComponentPropsWithRef } from 'react';
2
- export interface GamesSearchTriggerProps extends ComponentPropsWithRef<'button'> {
3
- asChild?: boolean;
4
- }
5
- export declare function GamesSearchTrigger(props: GamesSearchTriggerProps): import("react/jsx-runtime").JSX.Element;
@@ -1,14 +0,0 @@
1
- 'use client';
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { ark } from '@ark-ui/react';
4
- import { useShallow } from 'zustand/shallow';
5
- import { useGlobalStore } from '../../client/hooks/index.js';
6
- export function GamesSearchTrigger(props) {
7
- const globalStore = useGlobalStore(useShallow((ctx) => ({
8
- gamesSearch: ctx.gamesSearch,
9
- })));
10
- return (_jsx(ark.button, { type: "button", ...props, onClick: (e) => {
11
- globalStore.gamesSearch.setOpen(!globalStore.gamesSearch.open);
12
- return props.onClick?.(e);
13
- }, "data-state": globalStore.gamesSearch.open ? 'open' : 'closed' }));
14
- }
@@ -1,14 +0,0 @@
1
- type Step = 1 | 2 | 3 | (number & {});
2
- interface UseAccountVerificationReturn {
3
- step: Step;
4
- setStep: (step: Step) => void;
5
- started: boolean;
6
- setStarted: (started: boolean) => void;
7
- completed: boolean;
8
- setCompleted: (completed: boolean) => void;
9
- reset: () => void;
10
- }
11
- export declare function useAccountVerification(): UseAccountVerificationReturn;
12
- export declare const AccountVerificationContext: import("react").Context<UseAccountVerificationReturn | null>;
13
- export declare function useAccountVerificationContext(): UseAccountVerificationReturn;
14
- export {};
@@ -1,27 +0,0 @@
1
- import { createContext, useContext, useState } from 'react';
2
- import invariant from 'tiny-invariant';
3
- export function useAccountVerification() {
4
- const [step, setStep] = useState(1);
5
- const [started, setStarted] = useState(false);
6
- const [completed, setCompleted] = useState(false);
7
- function reset() {
8
- setStep(1);
9
- setStarted(false);
10
- setCompleted(false);
11
- }
12
- return {
13
- step,
14
- setStep,
15
- started,
16
- setStarted,
17
- completed,
18
- setCompleted,
19
- reset,
20
- };
21
- }
22
- export const AccountVerificationContext = createContext(null);
23
- export function useAccountVerificationContext() {
24
- const context = useContext(AccountVerificationContext);
25
- invariant(context);
26
- return context;
27
- }
@@ -1 +0,0 @@
1
- export declare function VerificationCapture(): import("react/jsx-runtime").JSX.Element | null;
@@ -1,28 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
2
- import { noop } from 'lodash-es';
3
- import Image from 'next/image';
4
- import { ArrowLeftIcon, CheckIcon, XIcon } from '../../icons/index.js';
5
- import uploadId from '../../images/capture-id-banner.png';
6
- import selfie from '../../images/capture-selfie-banner.png';
7
- import { Button, Checkbox, Field, Progress } from '../../ui/index.js';
8
- import { useAccountVerificationContext } from './AccountVerificationContext.js';
9
- export function VerificationCapture() {
10
- const context = useAccountVerificationContext();
11
- if (!context.started)
12
- return null;
13
- return (_jsxs(_Fragment, { children: [_jsxs("div", { className: "grid grid-cols-4 items-center", children: [_jsxs("button", { className: "text-text-tertiary-600 flex gap-sm text-sm font-semibold", disabled: context.step <= 1, onClick: () => context.setStep(context.step - 1), children: [_jsx(ArrowLeftIcon, { className: "size-5" }), "Back"] }), _jsxs("div", { className: "col-span-2 flex justify-center gap-2", children: [_jsx(Progress.Root, { value: context.step >= 2 ? 100 : context.step >= 1 ? 50 : 0, onValueChange: noop, className: "w-22.5 shrink-0", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) }), _jsx(Progress.Root, { value: context.completed ? 100 : context.step >= 3 ? 50 : 0, onValueChange: noop, className: "w-22.5 shrink-0", children: _jsx(Progress.Track, { children: _jsx(Progress.Range, {}) }) })] })] }), context.step === 1 && _jsx(Step1, {}), context.step === 2 && _jsx(Step2, {}), context.step === 3 && _jsx(Step3, {})] }));
14
- }
15
- function Step1() {
16
- const context = useAccountVerificationContext();
17
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Prepare to upload your ID" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsx(Image, { src: uploadId, alt: "", className: "h-auto w-full", width: 600, height: 352 }), _jsxs("ul", { className: "mt-2xl space-y-3", children: [_jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Upload front side of your ID"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Take a photo in a well lit room"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(XIcon, { className: "text-text-featured-icon-light-error size-6" }), "Don't edit image of your ID"] })] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => context.setStep(2), children: "Continue" }) })] })] }));
18
- }
19
- function Step2() {
20
- const context = useAccountVerificationContext();
21
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Take a selfie holding your ID" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsx(Image, { src: selfie, alt: "", className: "h-auto w-full", width: 600, height: 352 }), _jsxs("ul", { className: "mt-2xl space-y-3", children: [_jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Face and ID must be clearly visible"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(CheckIcon, { className: "text-text-featured-icon-light-success size-6" }), "Take a photo in a well lit room"] }), _jsxs("li", { className: "text-text-secondary-700 flex items-center gap-lg", children: [_jsx(XIcon, { className: "text-text-featured-icon-light-error size-6" }), "No hats, sunglasses, or masks"] })] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => context.setStep(3), children: "Continue" }) })] })] }));
22
- }
23
- function Step3() {
24
- const context = useAccountVerificationContext();
25
- return (_jsxs(_Fragment, { children: [_jsx("p", { className: "mt-2xl text-center text-2xl font-semibold", children: "Enter your basic and work-related information" }), _jsxs("div", { className: "border-border-secondary bg-bg-primary-alt shadow-xs mt-6 rounded-2xl border", children: [_jsxs("div", { className: "px-4 py-5", children: [_jsxs(Field.Root, { children: [_jsx(Field.Label, { children: "Permanent address" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Current address" }), _jsx(Field.Input, {})] }), _jsxs(Checkbox.Root, { className: "mt-sm", children: [_jsx(Checkbox.Control, { children: _jsx(Checkbox.Indicator, { asChild: true, children: _jsx(CheckIcon, {}) }) }), _jsx(Checkbox.Label, { children: "Same as permanent address" }), _jsx(Checkbox.HiddenInput, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Source of income" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Nature of work" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Place of birth" }), _jsx(Field.Input, {})] }), _jsxs(Field.Root, { className: "mt-6", children: [_jsx(Field.Label, { children: "Nationality" }), _jsx(Field.Input, {})] })] }), _jsx("div", { className: "border-border-secondary border-t px-xl py-lg", children: _jsx(Button, { size: "sm", onClick: () => {
26
- context.setCompleted(true);
27
- }, children: "Continue" }) })] })] }));
28
- }
@@ -1 +0,0 @@
1
- export declare function VerificationComplete(): import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Portal } from '@ark-ui/react';
3
- import { CheckCircleIcon } from '../../icons/index.js';
4
- import { AlertDialog, Button } from '../../ui/index.js';
5
- import { useAccountVerificationContext } from './AccountVerificationContext.js';
6
- export function VerificationComplete() {
7
- const context = useAccountVerificationContext();
8
- return (_jsx(AlertDialog.Root, { open: context.completed, lazyMount: true, unmountOnExit: true, closeOnEscape: false, closeOnInteractOutside: false, children: _jsxs(Portal, { children: [_jsx(AlertDialog.Backdrop, { className: "bg-bg-overlay/75 backdrop-blur-sm" }), _jsx(AlertDialog.Positioner, { children: _jsxs(AlertDialog.Content, { className: "mx-auto w-[21.438rem] p-xl", children: [_jsx("div", { className: "bg-bg-success-secondary text-text-featured-icon-light-success mx-auto flex size-12 items-center justify-center rounded-full", children: _jsx(CheckCircleIcon, {}) }), _jsx(AlertDialog.Title, { className: "mt-3 text-center", children: "Submission Successful" }), _jsx(AlertDialog.Description, { className: "text-text-tertiary-600 text-center", children: "Your documents have been submitted successfully. They\u2019re now under review, and you\u2019ll receive a notification as soon as your account is verified." }), _jsx(Button, { className: "mt-3xl", onClick: () => context.reset(), children: "Ok" })] }) })] }) }));
9
- }
@@ -1 +0,0 @@
1
- export declare function VerificationDetails(): import("react/jsx-runtime").JSX.Element | null;