@opexa/portal-components 0.0.1001 → 0.0.1002

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.
@@ -90,6 +90,7 @@ export interface GlobalStore {
90
90
  responsibleGamingReminder: ResponsibleGamingReminderStore;
91
91
  pendingBonus: HasPendingBonusStore;
92
92
  kycVerificationStatus: PopupStore;
93
+ kycAccountVerificationRequired: PopupStore;
93
94
  bankInformationDetails: PopupStore;
94
95
  isNonRegulated: boolean;
95
96
  setIsNonRegulated: (isNonRegulated: boolean) => void;
@@ -27,6 +27,19 @@ export const useGlobalStore = create()(devtools(subscribeWithSelector((set) => (
27
27
  },
28
28
  '~touched': false,
29
29
  },
30
+ kycAccountVerificationRequired: {
31
+ open: false,
32
+ setOpen(open) {
33
+ set((prev) => ({
34
+ kycAccountVerificationRequired: {
35
+ ...prev.kycAccountVerificationRequired,
36
+ open,
37
+ '~touched': true,
38
+ },
39
+ }));
40
+ },
41
+ '~touched': false,
42
+ },
30
43
  kycVerificationStatus: {
31
44
  open: false,
32
45
  setOpen(open) {
@@ -1,6 +1,6 @@
1
1
  export declare const AurixPayQRPHDepositContext: (props: {
2
2
  value: {
3
- status: "confirmed" | "failed" | "idle" | "generating-qr-code" | "qr-code-generated";
3
+ status: "idle" | "generating-qr-code" | "qr-code-generated" | "failed" | "confirmed";
4
4
  deposit: import("../../../../types").Deposit | null;
5
5
  errorMessage: {
6
6
  name: string;
@@ -13,7 +13,7 @@ export declare const AurixPayQRPHDepositContext: (props: {
13
13
  } & {
14
14
  children?: import("react").ReactNode | undefined;
15
15
  }) => React.ReactNode, useAurixPayQRPHDepositContext: () => {
16
- status: "confirmed" | "failed" | "idle" | "generating-qr-code" | "qr-code-generated";
16
+ status: "idle" | "generating-qr-code" | "qr-code-generated" | "failed" | "confirmed";
17
17
  deposit: import("../../../../types").Deposit | null;
18
18
  errorMessage: {
19
19
  name: string;
@@ -5,7 +5,7 @@ export interface GenerateQRCodeInput {
5
5
  promo?: string | null;
6
6
  }
7
7
  export declare function useAurixPayQRPHDeposit(): {
8
- status: "confirmed" | "failed" | "idle" | "generating-qr-code" | "qr-code-generated";
8
+ status: "idle" | "generating-qr-code" | "qr-code-generated" | "failed" | "confirmed";
9
9
  deposit: Deposit | null;
10
10
  errorMessage: {
11
11
  name: string;
@@ -0,0 +1 @@
1
+ export declare function KYCAccountVerificationRequired(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,10 @@
1
+ 'use client';
2
+ import { jsx as _jsx } from "react/jsx-runtime";
3
+ import dynamic from 'next/dynamic';
4
+ const Component = dynamic(() => import('./KYCAccountVerificationRequired.lazy.js').then((m) => m.default), {
5
+ ssr: false,
6
+ loading: () => null,
7
+ });
8
+ export function KYCAccountVerificationRequired() {
9
+ return _jsx(Component, {});
10
+ }
@@ -0,0 +1,2 @@
1
+ declare function KYCAccountVerificationRequired_lazy(): import("react/jsx-runtime").JSX.Element;
2
+ export default KYCAccountVerificationRequired_lazy;
@@ -0,0 +1,17 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useShallow } from 'zustand/shallow';
3
+ import { useGlobalStore } from '../../client/hooks/useGlobalStore.js';
4
+ import { FileX02Icon } from '../../icons/FileX02Icon.js';
5
+ import { Button } from '../../ui/Button/index.js';
6
+ import { Dialog } from '../../ui/Dialog/index.js';
7
+ function KYCAccountVerificationRequired_lazy() {
8
+ const globalStore = useGlobalStore(useShallow((s) => ({
9
+ kycVerificationRequired: s.kycAccountVerificationRequired,
10
+ kycReminder: s.kycReminder,
11
+ })));
12
+ return (_jsxs(Dialog.Root, { open: globalStore.kycVerificationRequired.open, closeOnEscape: false, closeOnInteractOutside: false, lazyMount: true, unmountOnExit: true, children: [_jsx(Dialog.Backdrop, { className: "z-[999]" }), _jsx(Dialog.Positioner, { className: "z-[999] flex items-center justify-center", children: _jsx(Dialog.Content, { className: "mx-auto h-fit max-w-[calc(100dvw-1rem)] overflow-y-auto rounded-lg bg-bg-primary lg:max-w-[400px]", children: _jsxs("div", { className: "p-3xl text-center", children: [_jsx("div", { className: "mx-auto w-fit rounded-full bg-bg-brand-secondary p-2", children: _jsx(FileX02Icon, { className: "text-shadow-text-brand" }) }), _jsx("h2", { className: "mt-4 font-semibold text-lg", children: "Account Verification Rejected!" }), _jsxs("p", { className: "mt-xs flex flex-col gap-4 text-sm text-text-tertiary-600", children: [_jsx("span", { children: "We're sorry, but your verification was rejected for the following reasons:" }), _jsxs("span", { children: [_jsx("b", { children: "Missing Documents:" }), " Some required documents were not uploaded. Please ensure you provide all necessary files as outlined in our guidelines."] }), _jsxs("span", { children: [_jsx("b", { children: "Unclear Images:" }), " The documents uploaded were blurry or not legible. Please re-upload clear, high-quality images where all text and details are visible."] }), _jsx("span", { children: "To resolve this, double-check the document requirements and re-submit. If you're unsure about the guidelines or need further clarification, feel free to contact our support team for assistance. We're here to help!" })] }), _jsx(Button, { type: "button", className: "mt-lg", onClick: () => {
13
+ globalStore.kycVerificationRequired.setOpen(false);
14
+ globalStore.kycReminder.setOpen(true);
15
+ }, children: "Ok" })] }) }) })] }));
16
+ }
17
+ export default KYCAccountVerificationRequired_lazy;
@@ -6,6 +6,7 @@ import { useMemberVerificationQuery } from '../../client/hooks/useMemberVerifica
6
6
  export function KycOpenOnHomeMount(props) {
7
7
  const setkycReminderOpen = useGlobalStore((s) => s.kycReminder.setOpen);
8
8
  const setkycOpen = useGlobalStore((s) => s.kyc.setOpen);
9
+ const setkycAccountVerificationRequired = useGlobalStore((s) => s.kycAccountVerificationRequired.setOpen);
9
10
  const isSignUpOpen = useGlobalStore((s) => s.signUp.open);
10
11
  const { data: verification, isLoading: verificationLoading } = useMemberVerificationQuery();
11
12
  const { data: account, isLoading: accountLoading } = useAccountQuery();
@@ -40,7 +41,8 @@ export function KycOpenOnHomeMount(props) {
40
41
  if (isFirstVisit) {
41
42
  //show verification locked message after logging in
42
43
  if (isVerificationLocked) {
43
- setkycReminderOpen(true);
44
+ setkycAccountVerificationRequired(true);
45
+ setkycReminderOpen(false);
44
46
  setkycOpen(false);
45
47
  return;
46
48
  }
@@ -58,7 +60,8 @@ export function KycOpenOnHomeMount(props) {
58
60
  if (isFirstVisit) {
59
61
  //show verification locked message after logging in
60
62
  if (isVerificationLocked) {
61
- setkycReminderOpen(true);
63
+ setkycAccountVerificationRequired(true);
64
+ setkycReminderOpen(false);
62
65
  setkycOpen(false);
63
66
  return;
64
67
  }
@@ -80,6 +83,7 @@ export function KycOpenOnHomeMount(props) {
80
83
  }, [
81
84
  setkycReminderOpen,
82
85
  setkycOpen,
86
+ setkycAccountVerificationRequired,
83
87
  verificationLoading,
84
88
  accountLoading,
85
89
  isSignUpOpen,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opexa/portal-components",
3
- "version": "0.0.1001",
3
+ "version": "0.0.1002",
4
4
  "exports": {
5
5
  "./ui/*": {
6
6
  "types": "./dist/ui/*/index.d.ts",