@opexa/portal-components 0.0.85 → 0.0.86
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/useCreateGCashDepositMutation.js +2 -1
- package/dist/client/hooks/useCreateGCashWithdrawalMutation.js +2 -1
- package/dist/client/hooks/useCreateGameSessionMutation.js +2 -1
- package/dist/client/hooks/useCreateInstapayWithdrawalMutation.js +2 -1
- package/dist/client/hooks/useCreateMayaAppDepositMutation.js +2 -1
- package/dist/client/hooks/useCreateMayaAppWithdrawalMutation.js +2 -1
- package/dist/client/hooks/useCreateMayaDepositMutation.js +2 -1
- package/dist/client/hooks/useCreateMayaWithdrawalMutation.js +2 -1
- package/dist/client/hooks/useCreateOnlineBankDepositMutation.js +2 -1
- package/dist/client/hooks/useCreateQRPHDepositMutation.js +2 -1
- package/dist/components/Account/Account.d.ts +0 -2
- package/dist/components/Account/Account.js +10 -8
- package/dist/components/Account/AccountTrigger.d.ts +1 -2
- package/dist/components/Account/AccountTrigger.js +18 -6
- package/dist/components/Bonuses/BonusesTrigger.d.ts +1 -1
- package/dist/components/Bonuses/BonusesTrigger.js +3 -3
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/OnlineBankDepositContext.d.ts +2 -2
- package/dist/components/DepositWithdrawal/Deposit/OnlineBankDeposit/useOnlineBankDeposit.d.ts +1 -1
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/QRPHDepositContext.d.ts +2 -2
- package/dist/components/DepositWithdrawal/Deposit/QRPHDeposit/useQRPHDeposit.d.ts +1 -1
- package/dist/components/DepositWithdrawal/DepositWithdrawal.d.ts +1 -6
- package/dist/components/DepositWithdrawal/DepositWithdrawal.js +8 -19
- package/dist/components/DepositWithdrawal/DepositWithdrawalTrigger.d.ts +1 -1
- package/dist/components/DepositWithdrawal/DepositWithdrawalTrigger.js +12 -4
- package/dist/components/Messages/Message.d.ts +1 -4
- package/dist/components/Messages/Message.js +8 -9
- package/dist/components/Messages/MessageContext.d.ts +2 -0
- package/dist/components/Messages/MessageContext.js +2 -0
- package/dist/components/Messages/Messages.d.ts +0 -1
- package/dist/components/Messages/Messages.js +9 -8
- package/dist/components/Messages/MessagesTrigger.d.ts +1 -1
- package/dist/components/Messages/MessagesTrigger.js +8 -4
- package/dist/components/PortalProvider/Providers.js +1 -5
- package/dist/components/SignUp/SignUpForm.js +2 -1
- package/dist/handlers.js +1 -0
- package/dist/services/ObjectId.d.ts +0 -14
- package/dist/services/ObjectId.js +62 -76
- package/dist/services/ObjectType.d.ts +10 -0
- package/dist/services/ObjectType.js +10 -0
- package/dist/services/index.d.ts +4 -3
- package/dist/services/index.js +4 -3
- package/dist/styles/theme.css +2 -2
- package/dist/ui/AlertDialog/AlertDialog.d.ts +122 -122
- package/dist/ui/AlertDialog/AlertDialog.js +2 -1
- package/dist/ui/AlertDialog/alertDialog.recipe.d.ts +11 -11
- package/dist/ui/AlertDialog/alertDialog.recipe.js +1 -1
- package/dist/ui/Avatar/Avatar.d.ts +1 -1
- package/dist/ui/Avatar/Avatar.js +1 -1
- package/dist/ui/Avatar/avatar.recipe.js +1 -1
- package/dist/ui/Badge/Badge.js +1 -1
- package/dist/ui/Button/Button.js +1 -1
- package/dist/ui/Checkbox/Checkbox.d.ts +24 -24
- package/dist/ui/Checkbox/Checkbox.js +1 -1
- package/dist/ui/Checkbox/checkbox.recipe.d.ts +3 -3
- package/dist/ui/Checkbox/checkbox.recipe.js +1 -1
- package/dist/ui/Clipboard/Clipboard.d.ts +19 -19
- package/dist/ui/Clipboard/Clipboard.js +1 -1
- package/dist/ui/Clipboard/clipboard.recipe.d.ts +3 -3
- package/dist/ui/Clipboard/clipboard.recipe.js +1 -1
- package/dist/ui/Collapsible/Collapsible.d.ts +1 -1
- package/dist/ui/Collapsible/Collapsible.js +1 -1
- package/dist/ui/Collapsible/collapsible.recipe.js +1 -1
- package/dist/ui/Combobox/Combobox.d.ts +43 -43
- package/dist/ui/Combobox/Combobox.js +1 -1
- package/dist/ui/Combobox/combobox.recipe.d.ts +3 -3
- package/dist/ui/Combobox/combobox.recipe.js +1 -1
- package/dist/ui/DatePicker/DatePicker.d.ts +337 -337
- package/dist/ui/DatePicker/DatePicker.js +1 -1
- package/dist/ui/DatePicker/datePicker.recipe.d.ts +14 -14
- package/dist/ui/DatePicker/datePicker.recipe.js +1 -1
- package/dist/ui/Dialog/Dialog.d.ts +122 -122
- package/dist/ui/Dialog/Dialog.js +2 -1
- package/dist/ui/Dialog/dialog.recipe.d.ts +11 -11
- package/dist/ui/Dialog/dialog.recipe.js +1 -1
- package/dist/ui/Drawer/Drawer.d.ts +34 -34
- package/dist/ui/Drawer/Drawer.js +2 -1
- package/dist/ui/Drawer/drawer.recipe.d.ts +3 -3
- package/dist/ui/Drawer/drawer.recipe.js +1 -1
- package/dist/ui/Field/Field.d.ts +22 -22
- package/dist/ui/Field/Field.js +1 -1
- package/dist/ui/Field/field.recipe.d.ts +3 -3
- package/dist/ui/Field/field.recipe.js +1 -1
- package/dist/ui/IconButton/IconButton.js +1 -1
- package/dist/ui/NumberInput/NumberInput.d.ts +1 -1
- package/dist/ui/NumberInput/NumberInput.js +1 -1
- package/dist/ui/NumberInput/numberInput.recipe.js +1 -1
- package/dist/ui/PasswordInput/PasswordInput.d.ts +1 -1
- package/dist/ui/PasswordInput/PasswordInput.js +1 -1
- package/dist/ui/PasswordInput/passwordInput.recipe.js +1 -1
- package/dist/ui/PinInput/PinInput.d.ts +1 -1
- package/dist/ui/PinInput/PinInput.js +1 -1
- package/dist/ui/PinInput/pinInput.recipe.js +1 -1
- package/dist/ui/Popover/Popover.d.ts +89 -89
- package/dist/ui/Popover/Popover.js +1 -1
- package/dist/ui/Popover/popover.recipe.d.ts +8 -8
- package/dist/ui/Popover/popover.recipe.js +1 -1
- package/dist/ui/Progress/Progress.d.ts +1 -1
- package/dist/ui/Progress/Progress.js +1 -1
- package/dist/ui/Progress/progress.recipe.js +1 -1
- package/dist/ui/SegmentGroup/SegmentGroup.d.ts +1 -1
- package/dist/ui/SegmentGroup/SegmentGroup.js +1 -1
- package/dist/ui/SegmentGroup/segmentGroup.recipe.js +1 -1
- package/dist/ui/Select/Select.d.ts +46 -46
- package/dist/ui/Select/Select.js +1 -1
- package/dist/ui/Select/select.recipe.d.ts +3 -3
- package/dist/ui/Select/select.recipe.js +1 -1
- package/dist/ui/Table/Table.d.ts +21 -21
- package/dist/ui/Table/Table.js +1 -1
- package/dist/ui/Table/table.recipe.d.ts +3 -3
- package/dist/ui/Tabs/Tabs.d.ts +16 -16
- package/dist/ui/Tabs/Tabs.js +1 -1
- package/dist/ui/Tabs/tabs.recipe.d.ts +3 -3
- package/dist/ui/Tabs/tabs.recipe.js +1 -1
- package/package.json +27 -30
- package/dist/utils/graphqlRequest.d.ts +0 -4
- package/dist/utils/graphqlRequest.js +0 -255
- package/dist/utils/httpRequest.d.ts +0 -6
- package/dist/utils/httpRequest.js +0 -87
- package/dist/utils/sha256.d.ts +0 -4
- package/dist/utils/sha256.js +0 -16
|
@@ -1,79 +1,65 @@
|
|
|
1
|
-
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
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
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
return this._buffer.equals(other._buffer);
|
|
64
|
-
}
|
|
65
|
-
clone() {
|
|
66
|
-
const buffer = Buffer.alloc(13);
|
|
67
|
-
this.buffer.copy(buffer);
|
|
68
|
-
return ObjectId.from(buffer);
|
|
69
|
-
}
|
|
70
|
-
toString(encoding) {
|
|
71
|
-
if (!encoding || encoding === 'bs58') {
|
|
72
|
-
return bs58.encode(this._buffer);
|
|
73
|
-
}
|
|
74
|
-
return this._buffer.toString(encoding);
|
|
75
|
-
}
|
|
76
|
-
}
|
|
1
|
+
/* ref: https://github.com/HighOutputVentures/opexa/blob/main/packages/object-id/src/libs/object-id.ts */
|
|
2
|
+
// import bs58 from 'bs58';
|
|
3
|
+
// import { sha256 } from 'crypto-hash';
|
|
4
|
+
// import randomBytes from 'randombytes';
|
|
5
|
+
// const MACHINE_ID = randomBytes(5);
|
|
6
|
+
// let counter = randomBytes(4).readUInt32BE(0) & 0xffffff;
|
|
7
|
+
// export class ObjectId {
|
|
8
|
+
// constructor(private readonly _buffer: Buffer) {}
|
|
9
|
+
// /**
|
|
10
|
+
// * @param type The type of the object, e.g. `ObjectType.MemberAccount`
|
|
11
|
+
// * @example
|
|
12
|
+
// * ```ts
|
|
13
|
+
// * import { ObjectId, ObjectType } from '@opexa/portal-components';
|
|
14
|
+
// *
|
|
15
|
+
// * const id = ObjectId.generate(ObjectType.MemberAccount).toString();
|
|
16
|
+
// * ```
|
|
17
|
+
// */
|
|
18
|
+
// static generate(type: number) {
|
|
19
|
+
// const buffer = Buffer.alloc(13);
|
|
20
|
+
// const time = Math.floor(Date.now() / 1000) & 0xffffffff;
|
|
21
|
+
// counter = (counter + 1) & 0xffffff;
|
|
22
|
+
// buffer[0] = type & 0xff;
|
|
23
|
+
// buffer[1] = (time >> 24) & 0xff;
|
|
24
|
+
// buffer[2] = (time >> 16) & 0xff;
|
|
25
|
+
// buffer[3] = (time >> 8) & 0xff;
|
|
26
|
+
// buffer[4] = time & 0xff;
|
|
27
|
+
// buffer[5] = MACHINE_ID[0];
|
|
28
|
+
// buffer[6] = MACHINE_ID[1];
|
|
29
|
+
// buffer[7] = MACHINE_ID[2];
|
|
30
|
+
// buffer[8] = MACHINE_ID[3];
|
|
31
|
+
// buffer[9] = MACHINE_ID[4];
|
|
32
|
+
// buffer[10] = (counter >> 16) & 0xff;
|
|
33
|
+
// buffer[11] = (counter >> 8) & 0xff;
|
|
34
|
+
// buffer[12] = counter & 0xff;
|
|
35
|
+
// return new ObjectId(buffer);
|
|
36
|
+
// }
|
|
37
|
+
// /**
|
|
38
|
+
// *
|
|
39
|
+
// * @param type The type of the object, e.g. `ObjectType.Game`
|
|
40
|
+
// * @param key The key to generate the object ID from, e.g. `Game.id`
|
|
41
|
+
// * @example
|
|
42
|
+
// * ```ts
|
|
43
|
+
// * import { ObjectId, ObjectType } from '@opexa/portal-components';
|
|
44
|
+
// *
|
|
45
|
+
// * const id = (await ObjectId.generateFromKey(ObjectType.Game, gameId)).toString();
|
|
46
|
+
// * ```
|
|
47
|
+
// */
|
|
48
|
+
// static async generateFromKey(type: number, key: string) {
|
|
49
|
+
// const buffer = Buffer.alloc(13);
|
|
50
|
+
// buffer[0] = type & 0xff;
|
|
51
|
+
// Buffer.from(await sha256(key, { outputFormat: 'buffer' })).copy(
|
|
52
|
+
// <Uint8Array>buffer,
|
|
53
|
+
// 1,
|
|
54
|
+
// 0,
|
|
55
|
+
// 12,
|
|
56
|
+
// );
|
|
57
|
+
// return new ObjectId(buffer);
|
|
58
|
+
// }
|
|
59
|
+
// toString() {
|
|
60
|
+
// return bs58.encode(<Uint8Array>this._buffer);
|
|
61
|
+
// }
|
|
62
|
+
// }
|
|
77
63
|
export const ObjectType = {
|
|
78
64
|
MemberAccount: 8,
|
|
79
65
|
MemberVerification: 15,
|
package/dist/services/index.d.ts
CHANGED
|
@@ -3,10 +3,11 @@ export * from './auth.service';
|
|
|
3
3
|
export * from './cmsPortal.service';
|
|
4
4
|
export * from './file.service';
|
|
5
5
|
export * from './game.service';
|
|
6
|
-
export * from './graphqlRequest';
|
|
7
|
-
export * from './httpRequest';
|
|
8
6
|
export * from './portal.service';
|
|
9
7
|
export * from './report.service';
|
|
10
|
-
export * from './sha256';
|
|
11
8
|
export * from './trigger.service';
|
|
12
9
|
export * from './wallet.service';
|
|
10
|
+
export * from './graphqlRequest';
|
|
11
|
+
export * from './httpRequest';
|
|
12
|
+
export * from './ObjectType';
|
|
13
|
+
export * from './sha256';
|
package/dist/services/index.js
CHANGED
|
@@ -3,10 +3,11 @@ export * from './auth.service.js';
|
|
|
3
3
|
export * from './cmsPortal.service.js';
|
|
4
4
|
export * from './file.service.js';
|
|
5
5
|
export * from './game.service.js';
|
|
6
|
-
export * from './graphqlRequest.js';
|
|
7
|
-
export * from './httpRequest.js';
|
|
8
6
|
export * from './portal.service.js';
|
|
9
7
|
export * from './report.service.js';
|
|
10
|
-
export * from './sha256.js';
|
|
11
8
|
export * from './trigger.service.js';
|
|
12
9
|
export * from './wallet.service.js';
|
|
10
|
+
export * from './graphqlRequest.js';
|
|
11
|
+
export * from './httpRequest.js';
|
|
12
|
+
export * from './ObjectType.js';
|
|
13
|
+
export * from './sha256.js';
|
package/dist/styles/theme.css
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
@plugin '@tailwindcss/typography';
|
|
2
|
-
@plugin '
|
|
2
|
+
@plugin 'tailwind-zag';
|
|
3
3
|
|
|
4
4
|
@layer base {
|
|
5
5
|
html {
|
|
@@ -694,4 +694,4 @@
|
|
|
694
694
|
@custom-variant scrollbar (&::-webkit-scrollbar);
|
|
695
695
|
@custom-variant scrollbar-thumb (&::-webkit-scrollbar-thumb);
|
|
696
696
|
@custom-variant scrollbar-track (&::-webkit-scrollbar-track);
|
|
697
|
-
@custom-variant dark (&:where(.dark, .dark *));
|
|
697
|
+
@custom-variant dark (&:where(.dark, .dark *, [data-theme="dark"], [data-theme="dark"] *));
|