@memberstack/dom 2.0.2-beta.0 → 2.0.2

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 (87) hide show
  1. package/lib/index.d.mts +61 -26
  2. package/lib/index.d.ts +61 -26
  3. package/lib/index.js +793 -53
  4. package/lib/index.mjs +793 -53
  5. package/lib/{models-CTRKogoR.d.ts → models-CFT_ABd5.d.ts} +2 -2
  6. package/lib/testing/index.d.mts +25 -2
  7. package/lib/testing/index.d.ts +25 -2
  8. package/lib/testing/index.js +28 -6
  9. package/lib/testing/index.mjs +26 -5
  10. package/package.json +1 -1
  11. package/lib/auth/index.d.mts +0 -63
  12. package/lib/auth/index.d.ts +0 -63
  13. package/lib/auth/index.global.js +0 -244
  14. package/lib/auth/index.js +0 -161
  15. package/lib/auth/index.mjs +0 -123
  16. package/lib/constants/endpoints.d.mts +0 -5
  17. package/lib/constants/endpoints.d.ts +0 -5
  18. package/lib/constants/endpoints.global.js +0 -29
  19. package/lib/constants/endpoints.js +0 -32
  20. package/lib/constants/endpoints.mjs +0 -7
  21. package/lib/methods/dom/index.d.mts +0 -2
  22. package/lib/methods/dom/index.d.ts +0 -2
  23. package/lib/methods/dom/index.global.js +0 -2
  24. package/lib/methods/dom/index.js +0 -1
  25. package/lib/methods/dom/index.mjs +0 -0
  26. package/lib/methods/dom/main-dom.d.mts +0 -2
  27. package/lib/methods/dom/main-dom.d.ts +0 -2
  28. package/lib/methods/dom/main-dom.global.js +0 -30620
  29. package/lib/methods/dom/main-dom.js +0 -15611
  30. package/lib/methods/dom/main-dom.mjs +0 -15593
  31. package/lib/methods/dom/methods.d.mts +0 -100
  32. package/lib/methods/dom/methods.d.ts +0 -100
  33. package/lib/methods/dom/methods.global.js +0 -30827
  34. package/lib/methods/dom/methods.js +0 -335
  35. package/lib/methods/dom/methods.mjs +0 -302
  36. package/lib/methods/index.d.mts +0 -185
  37. package/lib/methods/index.d.ts +0 -185
  38. package/lib/methods/index.global.js +0 -46361
  39. package/lib/methods/index.js +0 -2530
  40. package/lib/methods/index.mjs +0 -2500
  41. package/lib/methods/requests/index.d.mts +0 -912
  42. package/lib/methods/requests/index.d.ts +0 -912
  43. package/lib/methods/requests/index.global.js +0 -15553
  44. package/lib/methods/requests/index.js +0 -2145
  45. package/lib/methods/requests/index.mjs +0 -2110
  46. package/lib/methods/requests/requests.d.mts +0 -43
  47. package/lib/methods/requests/requests.d.ts +0 -43
  48. package/lib/methods/requests/requests.global.js +0 -14528
  49. package/lib/methods/requests/requests.js +0 -244
  50. package/lib/methods/requests/requests.mjs +0 -210
  51. package/lib/models-BmZS-mc4.d.ts +0 -193
  52. package/lib/models-le7xaT4H.d.ts +0 -193
  53. package/lib/types/index.d.mts +0 -5
  54. package/lib/types/index.d.ts +0 -5
  55. package/lib/types/index.global.js +0 -19
  56. package/lib/types/index.js +0 -18
  57. package/lib/types/index.mjs +0 -0
  58. package/lib/types/params.d.mts +0 -946
  59. package/lib/types/params.d.ts +0 -946
  60. package/lib/types/params.global.js +0 -19
  61. package/lib/types/params.js +0 -18
  62. package/lib/types/params.mjs +0 -0
  63. package/lib/types/payloads.d.mts +0 -342
  64. package/lib/types/payloads.d.ts +0 -342
  65. package/lib/types/payloads.global.js +0 -19
  66. package/lib/types/payloads.js +0 -18
  67. package/lib/types/payloads.mjs +0 -0
  68. package/lib/types/translations.d.mts +0 -101
  69. package/lib/types/translations.d.ts +0 -101
  70. package/lib/types/translations.global.js +0 -19
  71. package/lib/types/translations.js +0 -18
  72. package/lib/types/translations.mjs +0 -0
  73. package/lib/types/utils/payloads.d.mts +0 -297
  74. package/lib/types/utils/payloads.d.ts +0 -297
  75. package/lib/types/utils/payloads.global.js +0 -19
  76. package/lib/types/utils/payloads.js +0 -18
  77. package/lib/types/utils/payloads.mjs +0 -0
  78. package/lib/utils/cookies.d.mts +0 -13
  79. package/lib/utils/cookies.d.ts +0 -13
  80. package/lib/utils/cookies.global.js +0 -261
  81. package/lib/utils/cookies.js +0 -190
  82. package/lib/utils/cookies.mjs +0 -148
  83. package/lib/utils/defaultMessageBox.d.mts +0 -5
  84. package/lib/utils/defaultMessageBox.d.ts +0 -5
  85. package/lib/utils/defaultMessageBox.global.js +0 -125
  86. package/lib/utils/defaultMessageBox.js +0 -130
  87. package/lib/utils/defaultMessageBox.mjs +0 -103
@@ -1,297 +0,0 @@
1
- declare namespace Payload {
2
- interface PaginatedResponse<T> {
3
- hasNext: boolean;
4
- endCursor: string | null;
5
- totalCount: number;
6
- data: T[];
7
- }
8
- interface Transforms {
9
- Pagination: {
10
- hasNext: boolean;
11
- endCursor: string | null;
12
- totalCount: number;
13
- };
14
- RemovePlan: {
15
- member: Transforms["Member"];
16
- };
17
- SendMemberVerificationEmail: {
18
- success: boolean;
19
- };
20
- ResetMemberPassword: {
21
- success: boolean;
22
- };
23
- GetAppAndMember: {
24
- app: Transforms["App"];
25
- member: Transforms["Member"] | null;
26
- };
27
- SecureContent: {
28
- content: string;
29
- type: "HTML" | "CSS" | "LINK" | "JS" | "JSON" | "TEXT" | "IMAGE" | "FILE";
30
- };
31
- Post: {
32
- id: string;
33
- internalOrder: string;
34
- createdAt: string;
35
- content: string;
36
- member: {
37
- id: string;
38
- customFields: object;
39
- profileImage: string;
40
- };
41
- _count: {
42
- Threads: number;
43
- likedBy: number;
44
- dislikedBy: number;
45
- };
46
- };
47
- DeletedMember: {
48
- id: string;
49
- };
50
- Posts: {
51
- posts: Transforms["Post"][];
52
- totalCount: number;
53
- };
54
- Thread: {
55
- id: string;
56
- internalOrder: string;
57
- createdAt: string;
58
- content: string;
59
- member: {
60
- id: string;
61
- customFields: object;
62
- profileImage: string;
63
- };
64
- _count: {
65
- Threads: number;
66
- likedBy: number;
67
- };
68
- };
69
- Threads: {
70
- threads: Transforms["Thread"][];
71
- };
72
- App: {
73
- id: string;
74
- name: string;
75
- mode: "live" | "sandbox";
76
- plans: Transforms["Plan"][];
77
- contentGroups: Transforms["RestrictedUrlGroup"][];
78
- emailVerificationEnabled: boolean;
79
- requireEmailVerification: boolean;
80
- customField: Transforms["CustomField"][];
81
- branding: Transforms["Branding"];
82
- authProviders: Transforms["AuthProvider"][];
83
- };
84
- Branding: {
85
- logo: string;
86
- colors: {
87
- lightMode: {
88
- primaryButton: string;
89
- };
90
- };
91
- };
92
- RestrictedUrlGroup: {
93
- id: string;
94
- name: string;
95
- key: string;
96
- allowAllMembers: boolean;
97
- activeMemberHasAccess?: boolean;
98
- redirect: string;
99
- urls: {
100
- url: string;
101
- filter: string;
102
- }[];
103
- plans: {
104
- id: string;
105
- }[];
106
- };
107
- MemberAuth: {
108
- tokens: {
109
- accessToken: string;
110
- expires: number;
111
- type: "bearer";
112
- };
113
- member: Transforms["Member"];
114
- redirect: string;
115
- contentGroups?: Transforms["RestrictedUrlGroup"][];
116
- };
117
- MemberJSON: object;
118
- AuthProviders: {
119
- providers: {
120
- provider: string;
121
- }[];
122
- message?: string;
123
- };
124
- Member: {
125
- id: string;
126
- verified: boolean;
127
- profileImage: string;
128
- auth: {
129
- email: string;
130
- hasPassword: boolean;
131
- providers: {
132
- provider: string;
133
- }[];
134
- };
135
- loginRedirect: string;
136
- stripeCustomerId: string;
137
- createdAt: string;
138
- metaData: object;
139
- customFields: object;
140
- permissions: string[] | [];
141
- planConnections: Transforms["MemberPlanConnection"][];
142
- };
143
- MemberReceipt: {
144
- id: string;
145
- amount: number;
146
- url: string;
147
- stripe?: {
148
- url: string;
149
- };
150
- number: string;
151
- purchase: string;
152
- invoice: string;
153
- createdAt: string;
154
- currency: string;
155
- };
156
- MemberInvoices: PaginatedResponse<{
157
- id: string;
158
- status: string;
159
- amount: number;
160
- url: string;
161
- description: string;
162
- number: string;
163
- purchase: string;
164
- }>;
165
- MemberReceipts: PaginatedResponse<{
166
- id: string;
167
- amount: string;
168
- url: string;
169
- number: string;
170
- planConnection: string;
171
- invoice: Transforms["MemberInvoice"];
172
- }>;
173
- MemberCard: {
174
- id: string;
175
- brand: string;
176
- expMonth: string;
177
- expYear: string;
178
- last4: string;
179
- default: boolean;
180
- };
181
- MemberInvoice: {
182
- id: string;
183
- status: string;
184
- amount: number;
185
- url: string;
186
- description: string;
187
- number: string;
188
- planConnection: string;
189
- createdAt: string;
190
- currency: string;
191
- };
192
- Plan: {
193
- id: string;
194
- name: string;
195
- description: string;
196
- status: string;
197
- redirects: {
198
- afterLogin: string;
199
- afterLogout: string;
200
- afterSignup: string;
201
- };
202
- prices?: Transforms["Price"][] | [];
203
- };
204
- Price: {
205
- id: string;
206
- amount: string;
207
- interval: {
208
- type: string;
209
- count: number;
210
- };
211
- name: string;
212
- type: string;
213
- status: string;
214
- currency: string;
215
- };
216
- Permission: {
217
- id: string;
218
- name: string;
219
- description: string;
220
- };
221
- PermissionGroup: {
222
- id: string;
223
- name: string;
224
- permissions: Transforms["Permission"][];
225
- };
226
- CustomField: {
227
- order: number;
228
- key: string;
229
- label: string;
230
- hidden: boolean;
231
- };
232
- MemberPlanConnection: {
233
- id: string;
234
- active: boolean;
235
- status: string;
236
- planId: string;
237
- type: string;
238
- payment: {
239
- amount: number;
240
- currency: string;
241
- status: string;
242
- lastBillingDate: number | null;
243
- nextBillingDate: number | null;
244
- cancelAtDate: number | null;
245
- priceId: string;
246
- } | null;
247
- };
248
- Purchase: {
249
- plan: string;
250
- payment: {
251
- requiresPayment: boolean;
252
- requiresAuthentication: boolean;
253
- };
254
- };
255
- AddPlan: {
256
- redirect: string;
257
- member: Transforms["Member"];
258
- };
259
- PurchaseWithCheckout: {
260
- url: string;
261
- };
262
- LaunchStripeCustomerPortal: {
263
- url: string;
264
- };
265
- OpenStripeCustomerPortal: {
266
- url: string;
267
- };
268
- AuthenticationClientSecret: string;
269
- AuthProvider: {
270
- clientId: string;
271
- provider: string;
272
- providerType: string;
273
- icon: string;
274
- };
275
- TotalCheckoutAmount: {
276
- total: number;
277
- subTotal: number;
278
- currency: string;
279
- setupFee?: {
280
- enabled: boolean;
281
- amount: number;
282
- name: string;
283
- };
284
- freeTrial?: {
285
- days: number;
286
- enabled: boolean;
287
- };
288
- tax?: {
289
- name: string;
290
- percent: number;
291
- description: string;
292
- }[];
293
- };
294
- }
295
- }
296
-
297
- export { Payload };
@@ -1,297 +0,0 @@
1
- declare namespace Payload {
2
- interface PaginatedResponse<T> {
3
- hasNext: boolean;
4
- endCursor: string | null;
5
- totalCount: number;
6
- data: T[];
7
- }
8
- interface Transforms {
9
- Pagination: {
10
- hasNext: boolean;
11
- endCursor: string | null;
12
- totalCount: number;
13
- };
14
- RemovePlan: {
15
- member: Transforms["Member"];
16
- };
17
- SendMemberVerificationEmail: {
18
- success: boolean;
19
- };
20
- ResetMemberPassword: {
21
- success: boolean;
22
- };
23
- GetAppAndMember: {
24
- app: Transforms["App"];
25
- member: Transforms["Member"] | null;
26
- };
27
- SecureContent: {
28
- content: string;
29
- type: "HTML" | "CSS" | "LINK" | "JS" | "JSON" | "TEXT" | "IMAGE" | "FILE";
30
- };
31
- Post: {
32
- id: string;
33
- internalOrder: string;
34
- createdAt: string;
35
- content: string;
36
- member: {
37
- id: string;
38
- customFields: object;
39
- profileImage: string;
40
- };
41
- _count: {
42
- Threads: number;
43
- likedBy: number;
44
- dislikedBy: number;
45
- };
46
- };
47
- DeletedMember: {
48
- id: string;
49
- };
50
- Posts: {
51
- posts: Transforms["Post"][];
52
- totalCount: number;
53
- };
54
- Thread: {
55
- id: string;
56
- internalOrder: string;
57
- createdAt: string;
58
- content: string;
59
- member: {
60
- id: string;
61
- customFields: object;
62
- profileImage: string;
63
- };
64
- _count: {
65
- Threads: number;
66
- likedBy: number;
67
- };
68
- };
69
- Threads: {
70
- threads: Transforms["Thread"][];
71
- };
72
- App: {
73
- id: string;
74
- name: string;
75
- mode: "live" | "sandbox";
76
- plans: Transforms["Plan"][];
77
- contentGroups: Transforms["RestrictedUrlGroup"][];
78
- emailVerificationEnabled: boolean;
79
- requireEmailVerification: boolean;
80
- customField: Transforms["CustomField"][];
81
- branding: Transforms["Branding"];
82
- authProviders: Transforms["AuthProvider"][];
83
- };
84
- Branding: {
85
- logo: string;
86
- colors: {
87
- lightMode: {
88
- primaryButton: string;
89
- };
90
- };
91
- };
92
- RestrictedUrlGroup: {
93
- id: string;
94
- name: string;
95
- key: string;
96
- allowAllMembers: boolean;
97
- activeMemberHasAccess?: boolean;
98
- redirect: string;
99
- urls: {
100
- url: string;
101
- filter: string;
102
- }[];
103
- plans: {
104
- id: string;
105
- }[];
106
- };
107
- MemberAuth: {
108
- tokens: {
109
- accessToken: string;
110
- expires: number;
111
- type: "bearer";
112
- };
113
- member: Transforms["Member"];
114
- redirect: string;
115
- contentGroups?: Transforms["RestrictedUrlGroup"][];
116
- };
117
- MemberJSON: object;
118
- AuthProviders: {
119
- providers: {
120
- provider: string;
121
- }[];
122
- message?: string;
123
- };
124
- Member: {
125
- id: string;
126
- verified: boolean;
127
- profileImage: string;
128
- auth: {
129
- email: string;
130
- hasPassword: boolean;
131
- providers: {
132
- provider: string;
133
- }[];
134
- };
135
- loginRedirect: string;
136
- stripeCustomerId: string;
137
- createdAt: string;
138
- metaData: object;
139
- customFields: object;
140
- permissions: string[] | [];
141
- planConnections: Transforms["MemberPlanConnection"][];
142
- };
143
- MemberReceipt: {
144
- id: string;
145
- amount: number;
146
- url: string;
147
- stripe?: {
148
- url: string;
149
- };
150
- number: string;
151
- purchase: string;
152
- invoice: string;
153
- createdAt: string;
154
- currency: string;
155
- };
156
- MemberInvoices: PaginatedResponse<{
157
- id: string;
158
- status: string;
159
- amount: number;
160
- url: string;
161
- description: string;
162
- number: string;
163
- purchase: string;
164
- }>;
165
- MemberReceipts: PaginatedResponse<{
166
- id: string;
167
- amount: string;
168
- url: string;
169
- number: string;
170
- planConnection: string;
171
- invoice: Transforms["MemberInvoice"];
172
- }>;
173
- MemberCard: {
174
- id: string;
175
- brand: string;
176
- expMonth: string;
177
- expYear: string;
178
- last4: string;
179
- default: boolean;
180
- };
181
- MemberInvoice: {
182
- id: string;
183
- status: string;
184
- amount: number;
185
- url: string;
186
- description: string;
187
- number: string;
188
- planConnection: string;
189
- createdAt: string;
190
- currency: string;
191
- };
192
- Plan: {
193
- id: string;
194
- name: string;
195
- description: string;
196
- status: string;
197
- redirects: {
198
- afterLogin: string;
199
- afterLogout: string;
200
- afterSignup: string;
201
- };
202
- prices?: Transforms["Price"][] | [];
203
- };
204
- Price: {
205
- id: string;
206
- amount: string;
207
- interval: {
208
- type: string;
209
- count: number;
210
- };
211
- name: string;
212
- type: string;
213
- status: string;
214
- currency: string;
215
- };
216
- Permission: {
217
- id: string;
218
- name: string;
219
- description: string;
220
- };
221
- PermissionGroup: {
222
- id: string;
223
- name: string;
224
- permissions: Transforms["Permission"][];
225
- };
226
- CustomField: {
227
- order: number;
228
- key: string;
229
- label: string;
230
- hidden: boolean;
231
- };
232
- MemberPlanConnection: {
233
- id: string;
234
- active: boolean;
235
- status: string;
236
- planId: string;
237
- type: string;
238
- payment: {
239
- amount: number;
240
- currency: string;
241
- status: string;
242
- lastBillingDate: number | null;
243
- nextBillingDate: number | null;
244
- cancelAtDate: number | null;
245
- priceId: string;
246
- } | null;
247
- };
248
- Purchase: {
249
- plan: string;
250
- payment: {
251
- requiresPayment: boolean;
252
- requiresAuthentication: boolean;
253
- };
254
- };
255
- AddPlan: {
256
- redirect: string;
257
- member: Transforms["Member"];
258
- };
259
- PurchaseWithCheckout: {
260
- url: string;
261
- };
262
- LaunchStripeCustomerPortal: {
263
- url: string;
264
- };
265
- OpenStripeCustomerPortal: {
266
- url: string;
267
- };
268
- AuthenticationClientSecret: string;
269
- AuthProvider: {
270
- clientId: string;
271
- provider: string;
272
- providerType: string;
273
- icon: string;
274
- };
275
- TotalCheckoutAmount: {
276
- total: number;
277
- subTotal: number;
278
- currency: string;
279
- setupFee?: {
280
- enabled: boolean;
281
- amount: number;
282
- name: string;
283
- };
284
- freeTrial?: {
285
- days: number;
286
- enabled: boolean;
287
- };
288
- tax?: {
289
- name: string;
290
- percent: number;
291
- description: string;
292
- }[];
293
- };
294
- }
295
- }
296
-
297
- export { Payload };
@@ -1,19 +0,0 @@
1
- var MemberstackDOM = (() => {
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __copyProps = (to, from, except, desc) => {
7
- if (from && typeof from === "object" || typeof from === "function") {
8
- for (let key of __getOwnPropNames(from))
9
- if (!__hasOwnProp.call(to, key) && key !== except)
10
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
- }
12
- return to;
13
- };
14
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
-
16
- // src/types/utils/payloads.ts
17
- var payloads_exports = {};
18
- return __toCommonJS(payloads_exports);
19
- })();
@@ -1,18 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __copyProps = (to, from, except, desc) => {
7
- if (from && typeof from === "object" || typeof from === "function") {
8
- for (let key of __getOwnPropNames(from))
9
- if (!__hasOwnProp.call(to, key) && key !== except)
10
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
11
- }
12
- return to;
13
- };
14
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
15
-
16
- // src/types/utils/payloads.ts
17
- var payloads_exports = {};
18
- module.exports = __toCommonJS(payloads_exports);
File without changes
@@ -1,13 +0,0 @@
1
- declare const setUseCookies: (setCookieOnRoot?: boolean) => void;
2
- declare const setApiDomain: (domain: string) => void;
3
- declare const extractDomainFromHostname: (hostname: string) => string;
4
- declare const useCookiesValid: () => boolean;
5
- declare const setMemberToken: (token: string, expires?: number) => void;
6
- declare const removeMemberToken: () => void;
7
- declare const getMemberToken: () => any;
8
- declare const setMemberTokenIfAvailable: () => void;
9
- declare const getSessionId: () => string;
10
- declare const setSessionId: (sessionId: string) => void;
11
- declare const removeSessionId: () => void;
12
-
13
- export { extractDomainFromHostname, getMemberToken, getSessionId, removeMemberToken, removeSessionId, setApiDomain, setMemberToken, setMemberTokenIfAvailable, setSessionId, setUseCookies, useCookiesValid };
@@ -1,13 +0,0 @@
1
- declare const setUseCookies: (setCookieOnRoot?: boolean) => void;
2
- declare const setApiDomain: (domain: string) => void;
3
- declare const extractDomainFromHostname: (hostname: string) => string;
4
- declare const useCookiesValid: () => boolean;
5
- declare const setMemberToken: (token: string, expires?: number) => void;
6
- declare const removeMemberToken: () => void;
7
- declare const getMemberToken: () => any;
8
- declare const setMemberTokenIfAvailable: () => void;
9
- declare const getSessionId: () => string;
10
- declare const setSessionId: (sessionId: string) => void;
11
- declare const removeSessionId: () => void;
12
-
13
- export { extractDomainFromHostname, getMemberToken, getSessionId, removeMemberToken, removeSessionId, setApiDomain, setMemberToken, setMemberTokenIfAvailable, setSessionId, setUseCookies, useCookiesValid };