@cimplify/sdk 0.105.0 → 0.106.1
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/advanced.d.mts +2 -2
- package/dist/advanced.d.ts +2 -2
- package/dist/advanced.js +20 -20
- package/dist/advanced.mjs +1 -1
- package/dist/{catalogue-DjutZ0FC.d.mts → catalogue-CVKH9faR.d.mts} +5 -0
- package/dist/{catalogue-D1jkpGcr.d.ts → catalogue-ChBjPPME.d.ts} +5 -0
- package/dist/{chunk-37ZZCE7P.mjs → chunk-ABAK4YVY.mjs} +8 -50
- package/dist/{chunk-TINYV5E2.mjs → chunk-IWXVKW22.mjs} +28 -14
- package/dist/{chunk-Q5HX7LVE.mjs → chunk-L4XKIMUO.mjs} +1 -0
- package/dist/{chunk-PDTXSUHZ.js → chunk-LJSQ7TUV.js} +30 -16
- package/dist/{chunk-7PMMV5X4.js → chunk-NJK3THWT.js} +1 -0
- package/dist/{chunk-3IMPJEUI.js → chunk-QKL5L5IU.js} +92 -138
- package/dist/{chunk-XHVQDEVO.js → chunk-SFG2LMRD.js} +99 -12
- package/dist/{chunk-X7RPMALQ.mjs → chunk-YHR6LFQ7.mjs} +95 -13
- package/dist/{client-CZ8MjJ_o.d.mts → client-BfKFK7cn.d.mts} +12 -2
- package/dist/{client-BBZj15JJ.d.ts → client-DoczTJbs.d.ts} +12 -2
- package/dist/{index-DNxWfRHF.d.mts → index-DEUorPUO.d.mts} +1 -1
- package/dist/{index-CZjNWbQf.d.ts → index-Dn6xCpDe.d.ts} +1 -1
- package/dist/index.d.mts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +67 -67
- package/dist/index.mjs +3 -3
- package/dist/mock/cli.mjs +1 -0
- package/dist/mock/library.js +1 -0
- package/dist/mock/library.mjs +1 -0
- package/dist/mock/msw.js +1 -0
- package/dist/mock/msw.mjs +1 -0
- package/dist/react.d.mts +1 -1
- package/dist/react.d.ts +1 -1
- package/dist/react.js +31 -31
- package/dist/react.mjs +2 -2
- package/dist/{server-C_RIDnHU.d.ts → server-7soMMUgP.d.ts} +2 -1
- package/dist/{server-Byr4d0hL.d.mts → server-DDEJ7e9s.d.mts} +2 -1
- package/dist/server.d.mts +2 -2
- package/dist/server.d.ts +2 -2
- package/dist/server.js +7 -7
- package/dist/server.mjs +2 -2
- package/dist/testing/msw.d.mts +1 -1
- package/dist/testing/msw.d.ts +1 -1
- package/dist/testing/msw.js +2 -2
- package/dist/testing/msw.mjs +1 -1
- package/dist/testing/suite.d.mts +4 -4
- package/dist/testing/suite.d.ts +4 -4
- package/dist/testing/suite.js +24 -23
- package/dist/testing/suite.mjs +5 -4
- package/dist/testing.d.mts +10 -4
- package/dist/testing.d.ts +10 -4
- package/dist/testing.js +116 -116
- package/dist/testing.mjs +5 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
var chunk2P4KXFB6_js = require('./chunk-2P4KXFB6.js');
|
|
4
4
|
var chunkL5GKVQVJ_js = require('./chunk-L5GKVQVJ.js');
|
|
5
|
-
var
|
|
5
|
+
var chunkQKL5L5IU_js = require('./chunk-QKL5L5IU.js');
|
|
6
6
|
require('./chunk-XREIZ56K.js');
|
|
7
|
-
var
|
|
7
|
+
var chunkSFG2LMRD_js = require('./chunk-SFG2LMRD.js');
|
|
8
8
|
var chunkEV2EVOYS_js = require('./chunk-EV2EVOYS.js');
|
|
9
9
|
var chunkUYFTOIFW_js = require('./chunk-UYFTOIFW.js');
|
|
10
10
|
var chunkAVXA4F6G_js = require('./chunk-AVXA4F6G.js');
|
|
@@ -29,9 +29,9 @@ async function signInSilent(opts) {
|
|
|
29
29
|
} catch {
|
|
30
30
|
}
|
|
31
31
|
const callbackUri = opts.callbackUri ?? "/auth/callback";
|
|
32
|
-
const authorizeEndpoint = opts.authUrl ? `${opts.authUrl.replace(/\/$/, "")}/oauth/authorize` : await
|
|
33
|
-
const pkce = await
|
|
34
|
-
const state =
|
|
32
|
+
const authorizeEndpoint = opts.authUrl ? `${opts.authUrl.replace(/\/$/, "")}/oauth/authorize` : await chunkSFG2LMRD_js.getAuthorizationEndpoint(opts.issuer ?? chunkSFG2LMRD_js.DEFAULT_ISSUER);
|
|
33
|
+
const pkce = await chunkSFG2LMRD_js.generatePkce();
|
|
34
|
+
const state = chunkSFG2LMRD_js.generateState();
|
|
35
35
|
const params = new URLSearchParams({
|
|
36
36
|
response_type: RESPONSE_TYPE_CODE,
|
|
37
37
|
response_mode: RESPONSE_MODE_WEB_MESSAGE,
|
|
@@ -189,251 +189,251 @@ Object.defineProperty(exports, "resolvePhoneCountryCode", {
|
|
|
189
189
|
});
|
|
190
190
|
Object.defineProperty(exports, "ActivityService", {
|
|
191
191
|
enumerable: true,
|
|
192
|
-
get: function () { return
|
|
192
|
+
get: function () { return chunkQKL5L5IU_js.ActivityService; }
|
|
193
193
|
});
|
|
194
194
|
Object.defineProperty(exports, "CimplifyClient", {
|
|
195
195
|
enumerable: true,
|
|
196
|
-
get: function () { return
|
|
196
|
+
get: function () { return chunkQKL5L5IU_js.CimplifyClient; }
|
|
197
197
|
});
|
|
198
198
|
Object.defineProperty(exports, "DeliveryService", {
|
|
199
199
|
enumerable: true,
|
|
200
|
-
get: function () { return
|
|
200
|
+
get: function () { return chunkQKL5L5IU_js.DeliveryService; }
|
|
201
201
|
});
|
|
202
202
|
Object.defineProperty(exports, "HostedPurchaseIntentService", {
|
|
203
203
|
enumerable: true,
|
|
204
|
-
get: function () { return
|
|
204
|
+
get: function () { return chunkQKL5L5IU_js.HostedPurchaseIntentService; }
|
|
205
205
|
});
|
|
206
206
|
Object.defineProperty(exports, "PURCHASE_INTENT_ROUTE", {
|
|
207
207
|
enumerable: true,
|
|
208
|
-
get: function () { return
|
|
208
|
+
get: function () { return chunkQKL5L5IU_js.PURCHASE_INTENT_ROUTE; }
|
|
209
209
|
});
|
|
210
210
|
Object.defineProperty(exports, "PlacesService", {
|
|
211
211
|
enumerable: true,
|
|
212
|
-
get: function () { return
|
|
212
|
+
get: function () { return chunkQKL5L5IU_js.PlacesService; }
|
|
213
213
|
});
|
|
214
214
|
Object.defineProperty(exports, "PurchaseIntentResolver", {
|
|
215
215
|
enumerable: true,
|
|
216
|
-
get: function () { return
|
|
216
|
+
get: function () { return chunkQKL5L5IU_js.PurchaseIntentResolver; }
|
|
217
217
|
});
|
|
218
218
|
Object.defineProperty(exports, "PurchaseIntentService", {
|
|
219
219
|
enumerable: true,
|
|
220
|
-
get: function () { return
|
|
220
|
+
get: function () { return chunkQKL5L5IU_js.PurchaseIntentService; }
|
|
221
221
|
});
|
|
222
222
|
Object.defineProperty(exports, "SESSION_CHANGE_SOURCE", {
|
|
223
223
|
enumerable: true,
|
|
224
|
-
get: function () { return
|
|
224
|
+
get: function () { return chunkQKL5L5IU_js.SESSION_CHANGE_SOURCE; }
|
|
225
225
|
});
|
|
226
226
|
Object.defineProperty(exports, "StoreCreditQueries", {
|
|
227
227
|
enumerable: true,
|
|
228
|
-
get: function () { return
|
|
228
|
+
get: function () { return chunkQKL5L5IU_js.StoreCreditQueries; }
|
|
229
229
|
});
|
|
230
230
|
Object.defineProperty(exports, "SubscriptionService", {
|
|
231
231
|
enumerable: true,
|
|
232
|
-
get: function () { return
|
|
232
|
+
get: function () { return chunkQKL5L5IU_js.SubscriptionService; }
|
|
233
233
|
});
|
|
234
234
|
Object.defineProperty(exports, "SupportService", {
|
|
235
235
|
enumerable: true,
|
|
236
|
-
get: function () { return
|
|
236
|
+
get: function () { return chunkQKL5L5IU_js.SupportService; }
|
|
237
237
|
});
|
|
238
238
|
Object.defineProperty(exports, "UploadService", {
|
|
239
239
|
enumerable: true,
|
|
240
|
-
get: function () { return
|
|
240
|
+
get: function () { return chunkQKL5L5IU_js.UploadService; }
|
|
241
241
|
});
|
|
242
242
|
Object.defineProperty(exports, "createCimplifyClient", {
|
|
243
243
|
enumerable: true,
|
|
244
|
-
get: function () { return
|
|
244
|
+
get: function () { return chunkQKL5L5IU_js.createCimplifyClient; }
|
|
245
245
|
});
|
|
246
246
|
Object.defineProperty(exports, "AuthService", {
|
|
247
247
|
enumerable: true,
|
|
248
|
-
get: function () { return
|
|
248
|
+
get: function () { return chunkSFG2LMRD_js.AuthService; }
|
|
249
249
|
});
|
|
250
250
|
Object.defineProperty(exports, "BusinessService", {
|
|
251
251
|
enumerable: true,
|
|
252
|
-
get: function () { return
|
|
252
|
+
get: function () { return chunkSFG2LMRD_js.BusinessService; }
|
|
253
253
|
});
|
|
254
254
|
Object.defineProperty(exports, "CartOperations", {
|
|
255
255
|
enumerable: true,
|
|
256
|
-
get: function () { return
|
|
256
|
+
get: function () { return chunkSFG2LMRD_js.CartOperations; }
|
|
257
257
|
});
|
|
258
258
|
Object.defineProperty(exports, "CatalogueQueries", {
|
|
259
259
|
enumerable: true,
|
|
260
|
-
get: function () { return
|
|
260
|
+
get: function () { return chunkSFG2LMRD_js.CatalogueQueries; }
|
|
261
261
|
});
|
|
262
262
|
Object.defineProperty(exports, "CheckoutOperations", {
|
|
263
263
|
enumerable: true,
|
|
264
|
-
get: function () { return
|
|
264
|
+
get: function () { return chunkSFG2LMRD_js.CheckoutService; }
|
|
265
265
|
});
|
|
266
266
|
Object.defineProperty(exports, "CheckoutService", {
|
|
267
267
|
enumerable: true,
|
|
268
|
-
get: function () { return
|
|
268
|
+
get: function () { return chunkSFG2LMRD_js.CheckoutService; }
|
|
269
269
|
});
|
|
270
270
|
Object.defineProperty(exports, "CimplifyElement", {
|
|
271
271
|
enumerable: true,
|
|
272
|
-
get: function () { return
|
|
272
|
+
get: function () { return chunkSFG2LMRD_js.CimplifyElement; }
|
|
273
273
|
});
|
|
274
274
|
Object.defineProperty(exports, "CimplifyElements", {
|
|
275
275
|
enumerable: true,
|
|
276
|
-
get: function () { return
|
|
276
|
+
get: function () { return chunkSFG2LMRD_js.CimplifyElements; }
|
|
277
277
|
});
|
|
278
278
|
Object.defineProperty(exports, "ELEMENTS_AUTH_CONTACT_TYPES", {
|
|
279
279
|
enumerable: true,
|
|
280
|
-
get: function () { return
|
|
280
|
+
get: function () { return chunkSFG2LMRD_js.ELEMENTS_AUTH_CONTACT_TYPES; }
|
|
281
281
|
});
|
|
282
282
|
Object.defineProperty(exports, "ELEMENTS_AUTH_MODES", {
|
|
283
283
|
enumerable: true,
|
|
284
|
-
get: function () { return
|
|
284
|
+
get: function () { return chunkSFG2LMRD_js.ELEMENTS_AUTH_MODES; }
|
|
285
285
|
});
|
|
286
286
|
Object.defineProperty(exports, "ELEMENTS_AUTH_PROMPTS", {
|
|
287
287
|
enumerable: true,
|
|
288
|
-
get: function () { return
|
|
288
|
+
get: function () { return chunkSFG2LMRD_js.ELEMENTS_AUTH_PROMPTS; }
|
|
289
289
|
});
|
|
290
290
|
Object.defineProperty(exports, "ELEMENT_TYPES", {
|
|
291
291
|
enumerable: true,
|
|
292
|
-
get: function () { return
|
|
292
|
+
get: function () { return chunkSFG2LMRD_js.ELEMENT_TYPES; }
|
|
293
293
|
});
|
|
294
294
|
Object.defineProperty(exports, "EVENT_TYPES", {
|
|
295
295
|
enumerable: true,
|
|
296
|
-
get: function () { return
|
|
296
|
+
get: function () { return chunkSFG2LMRD_js.EVENT_TYPES; }
|
|
297
297
|
});
|
|
298
298
|
Object.defineProperty(exports, "FxService", {
|
|
299
299
|
enumerable: true,
|
|
300
|
-
get: function () { return
|
|
300
|
+
get: function () { return chunkSFG2LMRD_js.FxService; }
|
|
301
301
|
});
|
|
302
302
|
Object.defineProperty(exports, "InventoryService", {
|
|
303
303
|
enumerable: true,
|
|
304
|
-
get: function () { return
|
|
304
|
+
get: function () { return chunkSFG2LMRD_js.InventoryService; }
|
|
305
305
|
});
|
|
306
306
|
Object.defineProperty(exports, "LinkService", {
|
|
307
307
|
enumerable: true,
|
|
308
|
-
get: function () { return
|
|
308
|
+
get: function () { return chunkSFG2LMRD_js.LinkService; }
|
|
309
309
|
});
|
|
310
310
|
Object.defineProperty(exports, "LiteService", {
|
|
311
311
|
enumerable: true,
|
|
312
|
-
get: function () { return
|
|
312
|
+
get: function () { return chunkSFG2LMRD_js.LiteService; }
|
|
313
313
|
});
|
|
314
314
|
Object.defineProperty(exports, "MESSAGE_TYPES", {
|
|
315
315
|
enumerable: true,
|
|
316
|
-
get: function () { return
|
|
316
|
+
get: function () { return chunkSFG2LMRD_js.MESSAGE_TYPES; }
|
|
317
317
|
});
|
|
318
318
|
Object.defineProperty(exports, "OrderQueries", {
|
|
319
319
|
enumerable: true,
|
|
320
|
-
get: function () { return
|
|
320
|
+
get: function () { return chunkSFG2LMRD_js.OrderQueries; }
|
|
321
321
|
});
|
|
322
322
|
Object.defineProperty(exports, "PAYMENT_AUTHORIZATION_OUTCOME_STATUS", {
|
|
323
323
|
enumerable: true,
|
|
324
|
-
get: function () { return
|
|
324
|
+
get: function () { return chunkSFG2LMRD_js.PAYMENT_AUTHORIZATION_OUTCOME_STATUS; }
|
|
325
325
|
});
|
|
326
326
|
Object.defineProperty(exports, "PAYMENT_AUTHORIZATION_PROVIDER", {
|
|
327
327
|
enumerable: true,
|
|
328
|
-
get: function () { return
|
|
328
|
+
get: function () { return chunkSFG2LMRD_js.PAYMENT_AUTHORIZATION_PROVIDER; }
|
|
329
329
|
});
|
|
330
330
|
Object.defineProperty(exports, "PaymentAuthorizationAdapterRegistry", {
|
|
331
331
|
enumerable: true,
|
|
332
|
-
get: function () { return
|
|
332
|
+
get: function () { return chunkSFG2LMRD_js.PaymentAuthorizationAdapterRegistry; }
|
|
333
333
|
});
|
|
334
334
|
Object.defineProperty(exports, "PaystackAuthorizationAdapter", {
|
|
335
335
|
enumerable: true,
|
|
336
|
-
get: function () { return
|
|
336
|
+
get: function () { return chunkSFG2LMRD_js.PaystackAuthorizationAdapter; }
|
|
337
337
|
});
|
|
338
338
|
Object.defineProperty(exports, "SchedulingService", {
|
|
339
339
|
enumerable: true,
|
|
340
|
-
get: function () { return
|
|
340
|
+
get: function () { return chunkSFG2LMRD_js.SchedulingService; }
|
|
341
341
|
});
|
|
342
342
|
Object.defineProperty(exports, "StripeAuthorizationAdapter", {
|
|
343
343
|
enumerable: true,
|
|
344
|
-
get: function () { return
|
|
344
|
+
get: function () { return chunkSFG2LMRD_js.StripeAuthorizationAdapter; }
|
|
345
345
|
});
|
|
346
346
|
Object.defineProperty(exports, "clearPurchaseIntentIdempotencyKey", {
|
|
347
347
|
enumerable: true,
|
|
348
|
-
get: function () { return
|
|
348
|
+
get: function () { return chunkSFG2LMRD_js.clearIntentIdempotencyKey; }
|
|
349
349
|
});
|
|
350
350
|
Object.defineProperty(exports, "combine", {
|
|
351
351
|
enumerable: true,
|
|
352
|
-
get: function () { return
|
|
352
|
+
get: function () { return chunkSFG2LMRD_js.combine; }
|
|
353
353
|
});
|
|
354
354
|
Object.defineProperty(exports, "combineObject", {
|
|
355
355
|
enumerable: true,
|
|
356
|
-
get: function () { return
|
|
356
|
+
get: function () { return chunkSFG2LMRD_js.combineObject; }
|
|
357
357
|
});
|
|
358
358
|
Object.defineProperty(exports, "createDefaultPaymentAuthorizationAdapterRegistry", {
|
|
359
359
|
enumerable: true,
|
|
360
|
-
get: function () { return
|
|
360
|
+
get: function () { return chunkSFG2LMRD_js.createDefaultPaymentAuthorizationAdapterRegistry; }
|
|
361
361
|
});
|
|
362
362
|
Object.defineProperty(exports, "createElements", {
|
|
363
363
|
enumerable: true,
|
|
364
|
-
get: function () { return
|
|
364
|
+
get: function () { return chunkSFG2LMRD_js.createElements; }
|
|
365
365
|
});
|
|
366
366
|
Object.defineProperty(exports, "createPurchaseIntentConfirmation", {
|
|
367
367
|
enumerable: true,
|
|
368
|
-
get: function () { return
|
|
368
|
+
get: function () { return chunkSFG2LMRD_js.createPurchaseIntentConfirmation; }
|
|
369
369
|
});
|
|
370
370
|
Object.defineProperty(exports, "err", {
|
|
371
371
|
enumerable: true,
|
|
372
|
-
get: function () { return
|
|
372
|
+
get: function () { return chunkSFG2LMRD_js.err; }
|
|
373
373
|
});
|
|
374
374
|
Object.defineProperty(exports, "flatMap", {
|
|
375
375
|
enumerable: true,
|
|
376
|
-
get: function () { return
|
|
376
|
+
get: function () { return chunkSFG2LMRD_js.flatMap; }
|
|
377
377
|
});
|
|
378
378
|
Object.defineProperty(exports, "fromPromise", {
|
|
379
379
|
enumerable: true,
|
|
380
|
-
get: function () { return
|
|
380
|
+
get: function () { return chunkSFG2LMRD_js.fromPromise; }
|
|
381
381
|
});
|
|
382
382
|
Object.defineProperty(exports, "generateIdempotencyKey", {
|
|
383
383
|
enumerable: true,
|
|
384
|
-
get: function () { return
|
|
384
|
+
get: function () { return chunkSFG2LMRD_js.generateIdempotencyKey; }
|
|
385
385
|
});
|
|
386
386
|
Object.defineProperty(exports, "getOrElse", {
|
|
387
387
|
enumerable: true,
|
|
388
|
-
get: function () { return
|
|
388
|
+
get: function () { return chunkSFG2LMRD_js.getOrElse; }
|
|
389
389
|
});
|
|
390
390
|
Object.defineProperty(exports, "isErr", {
|
|
391
391
|
enumerable: true,
|
|
392
|
-
get: function () { return
|
|
392
|
+
get: function () { return chunkSFG2LMRD_js.isErr; }
|
|
393
393
|
});
|
|
394
394
|
Object.defineProperty(exports, "isOk", {
|
|
395
395
|
enumerable: true,
|
|
396
|
-
get: function () { return
|
|
396
|
+
get: function () { return chunkSFG2LMRD_js.isOk; }
|
|
397
397
|
});
|
|
398
398
|
Object.defineProperty(exports, "mapError", {
|
|
399
399
|
enumerable: true,
|
|
400
|
-
get: function () { return
|
|
400
|
+
get: function () { return chunkSFG2LMRD_js.mapError; }
|
|
401
401
|
});
|
|
402
402
|
Object.defineProperty(exports, "mapResult", {
|
|
403
403
|
enumerable: true,
|
|
404
|
-
get: function () { return
|
|
404
|
+
get: function () { return chunkSFG2LMRD_js.mapResult; }
|
|
405
405
|
});
|
|
406
406
|
Object.defineProperty(exports, "ok", {
|
|
407
407
|
enumerable: true,
|
|
408
|
-
get: function () { return
|
|
408
|
+
get: function () { return chunkSFG2LMRD_js.ok; }
|
|
409
409
|
});
|
|
410
410
|
Object.defineProperty(exports, "purchaseIntentIdempotencyKey", {
|
|
411
411
|
enumerable: true,
|
|
412
|
-
get: function () { return
|
|
412
|
+
get: function () { return chunkSFG2LMRD_js.intentIdempotencyKey; }
|
|
413
413
|
});
|
|
414
414
|
Object.defineProperty(exports, "purchaseIntentRequiresPaymentOption", {
|
|
415
415
|
enumerable: true,
|
|
416
|
-
get: function () { return
|
|
416
|
+
get: function () { return chunkSFG2LMRD_js.purchaseIntentRequiresPaymentOption; }
|
|
417
417
|
});
|
|
418
418
|
Object.defineProperty(exports, "selectPurchaseIntentPaymentOption", {
|
|
419
419
|
enumerable: true,
|
|
420
|
-
get: function () { return
|
|
420
|
+
get: function () { return chunkSFG2LMRD_js.selectPurchaseIntentPaymentOption; }
|
|
421
421
|
});
|
|
422
422
|
Object.defineProperty(exports, "startSignIn", {
|
|
423
423
|
enumerable: true,
|
|
424
|
-
get: function () { return
|
|
424
|
+
get: function () { return chunkSFG2LMRD_js.startSignIn; }
|
|
425
425
|
});
|
|
426
426
|
Object.defineProperty(exports, "toNullable", {
|
|
427
427
|
enumerable: true,
|
|
428
|
-
get: function () { return
|
|
428
|
+
get: function () { return chunkSFG2LMRD_js.toNullable; }
|
|
429
429
|
});
|
|
430
430
|
Object.defineProperty(exports, "tryCatch", {
|
|
431
431
|
enumerable: true,
|
|
432
|
-
get: function () { return
|
|
432
|
+
get: function () { return chunkSFG2LMRD_js.tryCatch; }
|
|
433
433
|
});
|
|
434
434
|
Object.defineProperty(exports, "unwrap", {
|
|
435
435
|
enumerable: true,
|
|
436
|
-
get: function () { return
|
|
436
|
+
get: function () { return chunkSFG2LMRD_js.unwrap; }
|
|
437
437
|
});
|
|
438
438
|
Object.defineProperty(exports, "AUTHORIZATION_TYPE", {
|
|
439
439
|
enumerable: true,
|
package/dist/index.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export { BOUNDARY_KIND, CIMPLIFY_CDN_HOSTS, DEFAULT_CDN_BASE_URL, DURATION_UNIT, INPUT_FIELD_TYPE, PRODUCT_TYPE, RENDER_HINT, allGalleryImages, assetUrl, chatMessageCards, displaysGrossPrices, getVariantDisplayName, isCimplifyAsset, isMultiDayService, priceBasisLabel, resolveGallery, serviceBillingMultiplier, stayLength, stayPeriods } from './chunk-3V4DVXV3.mjs';
|
|
2
2
|
export { isValidPhoneForContext, normalizePhoneToE164, resolvePhoneCountryCode } from './chunk-YOIVZ6OA.mjs';
|
|
3
|
-
export { ActivityService, CimplifyClient, DeliveryService, HostedPurchaseIntentService, PURCHASE_INTENT_ROUTE, PlacesService, PurchaseIntentResolver, PurchaseIntentService, SESSION_CHANGE_SOURCE, StoreCreditQueries, SubscriptionService, SupportService, UploadService, createCimplifyClient } from './chunk-
|
|
3
|
+
export { ActivityService, CimplifyClient, DeliveryService, HostedPurchaseIntentService, PURCHASE_INTENT_ROUTE, PlacesService, PurchaseIntentResolver, PurchaseIntentService, SESSION_CHANGE_SOURCE, StoreCreditQueries, SubscriptionService, SupportService, UploadService, createCimplifyClient } from './chunk-ABAK4YVY.mjs';
|
|
4
4
|
import './chunk-U4MW6PYU.mjs';
|
|
5
|
-
import { getAuthorizationEndpoint, DEFAULT_ISSUER, generatePkce, generateState } from './chunk-
|
|
6
|
-
export { AuthService, BusinessService, CartOperations, CatalogueQueries, CheckoutService as CheckoutOperations, CheckoutService, CimplifyElement, CimplifyElements, ELEMENTS_AUTH_CONTACT_TYPES, ELEMENTS_AUTH_MODES, ELEMENTS_AUTH_PROMPTS, ELEMENT_TYPES, EVENT_TYPES, FxService, InventoryService, LinkService, LiteService, MESSAGE_TYPES, OrderQueries, PAYMENT_AUTHORIZATION_OUTCOME_STATUS, PAYMENT_AUTHORIZATION_PROVIDER, PaymentAuthorizationAdapterRegistry, PaystackAuthorizationAdapter, SchedulingService, StripeAuthorizationAdapter, clearIntentIdempotencyKey as clearPurchaseIntentIdempotencyKey, combine, combineObject, createDefaultPaymentAuthorizationAdapterRegistry, createElements, createPurchaseIntentConfirmation, err, flatMap, fromPromise, generateIdempotencyKey, getOrElse, isErr, isOk, mapError, mapResult, ok, intentIdempotencyKey as purchaseIntentIdempotencyKey, purchaseIntentRequiresPaymentOption, selectPurchaseIntentPaymentOption, startSignIn, toNullable, tryCatch, unwrap } from './chunk-
|
|
5
|
+
import { getAuthorizationEndpoint, DEFAULT_ISSUER, generatePkce, generateState } from './chunk-YHR6LFQ7.mjs';
|
|
6
|
+
export { AuthService, BusinessService, CartOperations, CatalogueQueries, CheckoutService as CheckoutOperations, CheckoutService, CimplifyElement, CimplifyElements, ELEMENTS_AUTH_CONTACT_TYPES, ELEMENTS_AUTH_MODES, ELEMENTS_AUTH_PROMPTS, ELEMENT_TYPES, EVENT_TYPES, FxService, InventoryService, LinkService, LiteService, MESSAGE_TYPES, OrderQueries, PAYMENT_AUTHORIZATION_OUTCOME_STATUS, PAYMENT_AUTHORIZATION_PROVIDER, PaymentAuthorizationAdapterRegistry, PaystackAuthorizationAdapter, SchedulingService, StripeAuthorizationAdapter, clearIntentIdempotencyKey as clearPurchaseIntentIdempotencyKey, combine, combineObject, createDefaultPaymentAuthorizationAdapterRegistry, createElements, createPurchaseIntentConfirmation, err, flatMap, fromPromise, generateIdempotencyKey, getOrElse, isErr, isOk, mapError, mapResult, ok, intentIdempotencyKey as purchaseIntentIdempotencyKey, purchaseIntentRequiresPaymentOption, selectPurchaseIntentPaymentOption, startSignIn, toNullable, tryCatch, unwrap } from './chunk-YHR6LFQ7.mjs';
|
|
7
7
|
export { AUTHORIZATION_TYPE, AUTH_MUTATION, CHECKOUT_MODE, CHECKOUT_MUTATION, CHECKOUT_NEXT_ACTION, CHECKOUT_ORDER_RESULT_STATUS, CHECKOUT_STATUS, CHECKOUT_STEP, CONTACT_TYPE, DEFAULT_COUNTRY, DEFAULT_CURRENCY, DEVICE_TYPE, LINK_MUTATION, LINK_QUERY, MAX_PAYMENT_AUTHORIZATION_STEPS, MOBILE_MONEY_PROVIDER, ORDER_MUTATION, ORDER_TYPE, PAYMENT_METHOD, PAYMENT_MUTATION, PAYMENT_STATE, PICKUP_TIME_TYPE } from './chunk-33VCYWVL.mjs';
|
|
8
8
|
export { CURRENCY_SYMBOLS, MOBILE_MONEY_PROVIDERS, PAYMENT_TERMINAL_FAILURE_STATUSES, canonicalMobileMoneyProvider, categorizePaymentError, detectMobileMoneyProvider, formatMoney, formatNumberCompact, formatPrice, formatPriceAdjustment, formatPriceCompact, formatPriceRange, formatPriceWithTax, formatProductPrice, getBasePrice, getCurrencySymbol, getDiscountPercentage, getDisplayPrice, getMarkupPercentage, getPriceRange, getProductCurrency, getTaxAmount, getUnitPriceAtQuantity, hasTaxInfo, isOnSale, isPaymentStatusFailure, isPaymentStatusRequiresAction, isPaymentStatusSuccess, isTaxInclusive, normalizePaymentResponse, normalizeStatusResponse, parsePrice, paymentAuthorizationUrl, purchaseIntentMobileMoneyNetwork } from './chunk-NYDVVNZI.mjs';
|
|
9
9
|
export { CHECKOUT_COMPLIANCE_LANE, CHECKOUT_COMPLIANCE_REASON, CHECKOUT_INVALIDATION_REASON, CHECKOUT_MATERIAL_TERMS_COMPONENT, CHECKOUT_PROTECTION_STATUS, CHECKOUT_PURCHASE_SURFACE, CHECKOUT_TERMS_COMPONENT, CHECKOUT_TERMS_DELTA_KIND, CimplifyError, ERROR_HINTS, ErrorCode, IdempotencyMismatchError, LEGACY_CHECKOUT_PAYMENT_METHOD_ALIAS, LEGACY_CHECKOUT_PAYMENT_STATUS, MOBILE_MONEY_TENDER_AUTHORITY_KIND, NATIVE_PURCHASE_PLATFORM, PAYMENT_COLLECTION_MODE, PAYMENT_INSTRUMENT_DISPLAY_KIND, PAYMENT_OPTION_NEXT_ACTION, PAYMENT_OPTION_STATUS, PURCHASE_DISPOSITION, PURCHASE_INTENT_ACTION_DECISION, PURCHASE_INTENT_CONFIRM_STATUS, PURCHASE_INTENT_ERROR_CODE, PURCHASE_INTENT_LINE_CONFIGURATION_KIND, PURCHASE_INTENT_MOBILE_MONEY_NETWORK, PURCHASE_INTENT_OFFER_KIND, PURCHASE_INTENT_PAYMENT_METHOD, PURCHASE_INTENT_PAYMENT_PROVIDER, PURCHASE_INTENT_RESOLUTION_KIND, PURCHASE_INTENT_RESOLVE_STATUS, PURCHASE_INTENT_SELLABLE_KIND, PURCHASE_INTENT_SOURCE_KIND, PURCHASE_INTENT_STATUS, PURCHASE_SURFACE, PURCHASING_PRINCIPAL_KIND, ZERO, currencyCode, enrichError, getErrorHint, isCimplifyError, isIdempotencyMismatchError, isQuoteConflictRequiringConsent, isQuoteError, isRetryableError, isSupportedCurrency, money, moneyFromNumber } from './chunk-NJYR6GGM.mjs';
|
package/dist/mock/cli.mjs
CHANGED
|
@@ -7159,6 +7159,7 @@ function createPurchaseIntentMockService(options) {
|
|
|
7159
7159
|
}
|
|
7160
7160
|
const checkoutInput = request.checkout;
|
|
7161
7161
|
if (!checkoutInput) throw validation("Cart checkout input is required");
|
|
7162
|
+
if (!checkoutInput.address_info) throw validation("Checkout address_info is required");
|
|
7162
7163
|
assertSupportedTenderPreference(request);
|
|
7163
7164
|
const cart = registry.carts.get(request.source.cart_id);
|
|
7164
7165
|
if (!cart) throw notFound(`Cart ${request.source.cart_id} not found`);
|
package/dist/mock/library.js
CHANGED
|
@@ -5981,6 +5981,7 @@ function createPurchaseIntentMockService(options) {
|
|
|
5981
5981
|
}
|
|
5982
5982
|
const checkoutInput = request.checkout;
|
|
5983
5983
|
if (!checkoutInput) throw validation("Cart checkout input is required");
|
|
5984
|
+
if (!checkoutInput.address_info) throw validation("Checkout address_info is required");
|
|
5984
5985
|
assertSupportedTenderPreference(request);
|
|
5985
5986
|
const cart = registry.carts.get(request.source.cart_id);
|
|
5986
5987
|
if (!cart) throw notFound(`Cart ${request.source.cart_id} not found`);
|
package/dist/mock/library.mjs
CHANGED
|
@@ -5979,6 +5979,7 @@ function createPurchaseIntentMockService(options) {
|
|
|
5979
5979
|
}
|
|
5980
5980
|
const checkoutInput = request.checkout;
|
|
5981
5981
|
if (!checkoutInput) throw validation("Cart checkout input is required");
|
|
5982
|
+
if (!checkoutInput.address_info) throw validation("Checkout address_info is required");
|
|
5982
5983
|
assertSupportedTenderPreference(request);
|
|
5983
5984
|
const cart = registry.carts.get(request.source.cart_id);
|
|
5984
5985
|
if (!cart) throw notFound(`Cart ${request.source.cart_id} not found`);
|
package/dist/mock/msw.js
CHANGED
|
@@ -5979,6 +5979,7 @@ function createPurchaseIntentMockService(options) {
|
|
|
5979
5979
|
}
|
|
5980
5980
|
const checkoutInput = request.checkout;
|
|
5981
5981
|
if (!checkoutInput) throw validation("Cart checkout input is required");
|
|
5982
|
+
if (!checkoutInput.address_info) throw validation("Checkout address_info is required");
|
|
5982
5983
|
assertSupportedTenderPreference(request);
|
|
5983
5984
|
const cart = registry.carts.get(request.source.cart_id);
|
|
5984
5985
|
if (!cart) throw notFound(`Cart ${request.source.cart_id} not found`);
|
package/dist/mock/msw.mjs
CHANGED
|
@@ -5977,6 +5977,7 @@ function createPurchaseIntentMockService(options) {
|
|
|
5977
5977
|
}
|
|
5978
5978
|
const checkoutInput = request.checkout;
|
|
5979
5979
|
if (!checkoutInput) throw validation("Cart checkout input is required");
|
|
5980
|
+
if (!checkoutInput.address_info) throw validation("Checkout address_info is required");
|
|
5980
5981
|
assertSupportedTenderPreference(request);
|
|
5981
5982
|
const cart = registry.carts.get(request.source.cart_id);
|
|
5982
5983
|
if (!cart) throw notFound(`Cart ${request.source.cart_id} not found`);
|
package/dist/react.d.mts
CHANGED
|
@@ -2,7 +2,7 @@ import * as React$1 from 'react';
|
|
|
2
2
|
import React__default, { ReactNode, PointerEvent, MouseEvent } from 'react';
|
|
3
3
|
import { d as AdSlot, c as AdPosition, a as AdContextValue, S as SignInOptions } from './sign-in-DQlIdqsi.mjs';
|
|
4
4
|
export { A as AdConfig, g as getVariantDisplayName } from './sign-in-DQlIdqsi.mjs';
|
|
5
|
-
import { C as CimplifyClient, aj as EnrichedOrderItem, ai as EnrichedOrder, u as Business, aN as Location, bQ as ReorderResult, be as OrderStatus, aV as Order, bC as QuoteBundleSelectionInput, bD as QuoteCompositeSelectionInput, bs as PriceQuote, bG as QuoteUiMessage, c8 as Service, p as AvailableSlot, a8 as DayAvailability, a5 as CustomerBooking, F as CancelBookingResult, h as ActivityStateResponse, ci as SessionMessage, A as ActivityRecommendation, aa as DeliveryFeeResponse, ae as DeliveryOptionsResponse, aw as FxRateResponse, cr as StoreCreditBalance, ct as StorefrontBootstrap, W as ChatWidgetStarter, T as ChatMessage, V as ChatUploadAttachment, a1 as CimplifyElements, O as ChatAttachment, aG as LineItem, cl as Staff, c2 as Room, U as ChatReplyContext } from './catalogue-
|
|
5
|
+
import { C as CimplifyClient, aj as EnrichedOrderItem, ai as EnrichedOrder, u as Business, aN as Location, bQ as ReorderResult, be as OrderStatus, aV as Order, bC as QuoteBundleSelectionInput, bD as QuoteCompositeSelectionInput, bs as PriceQuote, bG as QuoteUiMessage, c8 as Service, p as AvailableSlot, a8 as DayAvailability, a5 as CustomerBooking, F as CancelBookingResult, h as ActivityStateResponse, ci as SessionMessage, A as ActivityRecommendation, aa as DeliveryFeeResponse, ae as DeliveryOptionsResponse, aw as FxRateResponse, cr as StoreCreditBalance, ct as StorefrontBootstrap, W as ChatWidgetStarter, T as ChatMessage, V as ChatUploadAttachment, a1 as CimplifyElements, O as ChatAttachment, aG as LineItem, cl as Staff, c2 as Room, U as ChatReplyContext } from './catalogue-CVKH9faR.mjs';
|
|
6
6
|
import { g as CheckoutTermsView, cP as OrderType, dK as ProcessCheckoutResult, aW as CheckoutStatus, aX as CheckoutStatusContext, C as CurrencyCode, P as Product, dd as Pagination, c as CimplifyError, e as ProductWithDetails, b as Category, cH as Money, a as ChosenPrice, a1 as BundleSelectionInput, b5 as ComponentSelectionInput, a0 as BundleSelectionData, be as CompositeSelectionData, d as Collection, dT as ProductTaxonomy, eI as TaxonomyWithChildren, dU as ProductTimeProfile, bx as Deal, dP as ProductDealInfo, bH as DiscountValidation, a3 as BundleSummary, bc as CompositePriceResult, eD as SubscriptionWithDetails, eC as SubscriptionStatus, ez as Subscription, bl as CustomAttributeDefinition, dY as PropertyFacet, dO as ProductBillingPlan, f0 as VariantView, eW as VariantAxisWithValues, w as AddressInfo, J as AuthenticatedData, c3 as ElementsOptions, dn as PaymentMethodInfo, c1 as ElementsCheckoutResult, dJ as ProcessCheckoutOptions, s as AddOnWithOptions, Z as BundleComponentView, _ as BundlePriceType, ba as CompositeGroupView, bK as DisplayCart, dQ as ProductInputField, x as AddressValue, S as SaleInfo, U as UpcomingSale, D as DurationUnit, R as BoundaryKind, er as SchedulingMode, bz as DepositType, bm as CustomAttributeValue, dR as ProductProperty, eh as QuantityPricingTier } from './checkout-XoV4HNg2.mjs';
|
|
7
7
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
8
8
|
import { P as ProductWithPrice } from './price-CUGIYRtD.mjs';
|
package/dist/react.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import * as React$1 from 'react';
|
|
|
2
2
|
import React__default, { ReactNode, PointerEvent, MouseEvent } from 'react';
|
|
3
3
|
import { d as AdSlot, c as AdPosition, a as AdContextValue, S as SignInOptions } from './sign-in-DQlIdqsi.js';
|
|
4
4
|
export { A as AdConfig, g as getVariantDisplayName } from './sign-in-DQlIdqsi.js';
|
|
5
|
-
import { C as CimplifyClient, aj as EnrichedOrderItem, ai as EnrichedOrder, u as Business, aN as Location, bQ as ReorderResult, be as OrderStatus, aV as Order, bC as QuoteBundleSelectionInput, bD as QuoteCompositeSelectionInput, bs as PriceQuote, bG as QuoteUiMessage, c8 as Service, p as AvailableSlot, a8 as DayAvailability, a5 as CustomerBooking, F as CancelBookingResult, h as ActivityStateResponse, ci as SessionMessage, A as ActivityRecommendation, aa as DeliveryFeeResponse, ae as DeliveryOptionsResponse, aw as FxRateResponse, cr as StoreCreditBalance, ct as StorefrontBootstrap, W as ChatWidgetStarter, T as ChatMessage, V as ChatUploadAttachment, a1 as CimplifyElements, O as ChatAttachment, aG as LineItem, cl as Staff, c2 as Room, U as ChatReplyContext } from './catalogue-
|
|
5
|
+
import { C as CimplifyClient, aj as EnrichedOrderItem, ai as EnrichedOrder, u as Business, aN as Location, bQ as ReorderResult, be as OrderStatus, aV as Order, bC as QuoteBundleSelectionInput, bD as QuoteCompositeSelectionInput, bs as PriceQuote, bG as QuoteUiMessage, c8 as Service, p as AvailableSlot, a8 as DayAvailability, a5 as CustomerBooking, F as CancelBookingResult, h as ActivityStateResponse, ci as SessionMessage, A as ActivityRecommendation, aa as DeliveryFeeResponse, ae as DeliveryOptionsResponse, aw as FxRateResponse, cr as StoreCreditBalance, ct as StorefrontBootstrap, W as ChatWidgetStarter, T as ChatMessage, V as ChatUploadAttachment, a1 as CimplifyElements, O as ChatAttachment, aG as LineItem, cl as Staff, c2 as Room, U as ChatReplyContext } from './catalogue-ChBjPPME.js';
|
|
6
6
|
import { g as CheckoutTermsView, cP as OrderType, dK as ProcessCheckoutResult, aW as CheckoutStatus, aX as CheckoutStatusContext, C as CurrencyCode, P as Product, dd as Pagination, c as CimplifyError, e as ProductWithDetails, b as Category, cH as Money, a as ChosenPrice, a1 as BundleSelectionInput, b5 as ComponentSelectionInput, a0 as BundleSelectionData, be as CompositeSelectionData, d as Collection, dT as ProductTaxonomy, eI as TaxonomyWithChildren, dU as ProductTimeProfile, bx as Deal, dP as ProductDealInfo, bH as DiscountValidation, a3 as BundleSummary, bc as CompositePriceResult, eD as SubscriptionWithDetails, eC as SubscriptionStatus, ez as Subscription, bl as CustomAttributeDefinition, dY as PropertyFacet, dO as ProductBillingPlan, f0 as VariantView, eW as VariantAxisWithValues, w as AddressInfo, J as AuthenticatedData, c3 as ElementsOptions, dn as PaymentMethodInfo, c1 as ElementsCheckoutResult, dJ as ProcessCheckoutOptions, s as AddOnWithOptions, Z as BundleComponentView, _ as BundlePriceType, ba as CompositeGroupView, bK as DisplayCart, dQ as ProductInputField, x as AddressValue, S as SaleInfo, U as UpcomingSale, D as DurationUnit, R as BoundaryKind, er as SchedulingMode, bz as DepositType, bm as CustomAttributeValue, dR as ProductProperty, eh as QuantityPricingTier } from './checkout-XoV4HNg2.js';
|
|
7
7
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
8
8
|
import { P as ProductWithPrice } from './price-De-sxcuj.js';
|
package/dist/react.js
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
'use strict';
|
|
3
3
|
|
|
4
4
|
var chunk2P4KXFB6_js = require('./chunk-2P4KXFB6.js');
|
|
5
|
-
var
|
|
5
|
+
var chunkQKL5L5IU_js = require('./chunk-QKL5L5IU.js');
|
|
6
6
|
var chunkXREIZ56K_js = require('./chunk-XREIZ56K.js');
|
|
7
|
-
var
|
|
7
|
+
var chunkSFG2LMRD_js = require('./chunk-SFG2LMRD.js');
|
|
8
8
|
var chunkEV2EVOYS_js = require('./chunk-EV2EVOYS.js');
|
|
9
9
|
var chunkUYFTOIFW_js = require('./chunk-UYFTOIFW.js');
|
|
10
10
|
var chunkAVXA4F6G_js = require('./chunk-AVXA4F6G.js');
|
|
@@ -863,7 +863,7 @@ async function syncFromServer(entry) {
|
|
|
863
863
|
return next;
|
|
864
864
|
}
|
|
865
865
|
function emitMutationError(entry, operation, opId, idempotencyKey, error) {
|
|
866
|
-
entry.client.events.emit(
|
|
866
|
+
entry.client.events.emit(chunkSFG2LMRD_js.MUTATION_ERROR, {
|
|
867
867
|
service: "cart",
|
|
868
868
|
operation,
|
|
869
869
|
opId,
|
|
@@ -903,10 +903,10 @@ function getOrCreateStore(params) {
|
|
|
903
903
|
syncTail: Promise.resolve(),
|
|
904
904
|
failedOpRemovers: /* @__PURE__ */ new Set()
|
|
905
905
|
};
|
|
906
|
-
client.events.on(
|
|
906
|
+
client.events.on(chunkSFG2LMRD_js.SESSION_CLAIMED, () => {
|
|
907
907
|
if (entry.initialized) void syncFromServer(entry);
|
|
908
908
|
});
|
|
909
|
-
client.events.on(
|
|
909
|
+
client.events.on(chunkSFG2LMRD_js.SESSION_CLEARED, () => {
|
|
910
910
|
if (entry.initialized) void syncFromServer(entry);
|
|
911
911
|
});
|
|
912
912
|
cartStores.set(storeKey, entry);
|
|
@@ -1214,7 +1214,7 @@ var DEFAULT_COUNTRY = "US";
|
|
|
1214
1214
|
function createDefaultClient() {
|
|
1215
1215
|
const processRef = globalThis.process;
|
|
1216
1216
|
const envPublicKey = processRef?.env?.NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY || "";
|
|
1217
|
-
return
|
|
1217
|
+
return chunkQKL5L5IU_js.createCimplifyClient({ publicKey: envPublicKey });
|
|
1218
1218
|
}
|
|
1219
1219
|
function getStoredLocationId() {
|
|
1220
1220
|
if (typeof window === "undefined" || !window.localStorage) {
|
|
@@ -1772,7 +1772,7 @@ function CimplifyCheckout({
|
|
|
1772
1772
|
linkUrl
|
|
1773
1773
|
});
|
|
1774
1774
|
elementsRef.current = elements;
|
|
1775
|
-
const checkout = elements.create(
|
|
1775
|
+
const checkout = elements.create(chunkSFG2LMRD_js.ELEMENT_TYPES.CHECKOUT, {
|
|
1776
1776
|
orderTypes: resolvedOrderTypes,
|
|
1777
1777
|
defaultOrderType: resolvedDefaultOrderType,
|
|
1778
1778
|
submitLabel,
|
|
@@ -1783,19 +1783,19 @@ function CimplifyCheckout({
|
|
|
1783
1783
|
if (checkoutMountRef.current) {
|
|
1784
1784
|
checkout.mount(checkoutMountRef.current);
|
|
1785
1785
|
}
|
|
1786
|
-
checkout.on(
|
|
1786
|
+
checkout.on(chunkSFG2LMRD_js.EVENT_TYPES.READY, () => {
|
|
1787
1787
|
const cart = resolvedCartRef.current;
|
|
1788
1788
|
if (cart) {
|
|
1789
1789
|
checkout.setCart(transformToCheckoutCart(cart, fxOptionsRef.current));
|
|
1790
1790
|
}
|
|
1791
1791
|
});
|
|
1792
|
-
checkout.on(
|
|
1792
|
+
checkout.on(chunkSFG2LMRD_js.EVENT_TYPES.ORDER_TYPE_CHANGED, (data) => {
|
|
1793
1793
|
const typed = data;
|
|
1794
1794
|
if (typed.orderType) {
|
|
1795
1795
|
setOrderType(typed.orderType);
|
|
1796
1796
|
}
|
|
1797
1797
|
});
|
|
1798
|
-
checkout.on(
|
|
1798
|
+
checkout.on(chunkSFG2LMRD_js.EVENT_TYPES.REQUEST_SUBMIT, () => {
|
|
1799
1799
|
void handleSubmit();
|
|
1800
1800
|
});
|
|
1801
1801
|
return () => {
|
|
@@ -1816,7 +1816,7 @@ function CimplifyCheckout({
|
|
|
1816
1816
|
]);
|
|
1817
1817
|
React14.useEffect(() => {
|
|
1818
1818
|
if (!resolvedCart || !elementsRef.current) return;
|
|
1819
|
-
const checkoutElement = elementsRef.current.getElement(
|
|
1819
|
+
const checkoutElement = elementsRef.current.getElement(chunkSFG2LMRD_js.ELEMENT_TYPES.CHECKOUT);
|
|
1820
1820
|
if (checkoutElement) {
|
|
1821
1821
|
checkoutElement.setCart(transformToCheckoutCart(resolvedCart, fxOptions));
|
|
1822
1822
|
}
|
|
@@ -3555,7 +3555,7 @@ function CimplifySignInButton({
|
|
|
3555
3555
|
const onClick = async () => {
|
|
3556
3556
|
if (busy || disabled || !signInOpts.clientId) return;
|
|
3557
3557
|
setBusy(true);
|
|
3558
|
-
await
|
|
3558
|
+
await chunkSFG2LMRD_js.startSignIn({
|
|
3559
3559
|
...signInOpts,
|
|
3560
3560
|
onSuccess: () => {
|
|
3561
3561
|
setBusy(false);
|
|
@@ -5026,9 +5026,9 @@ function useClientSessionEpoch(client) {
|
|
|
5026
5026
|
const subscribe = React14.useCallback(
|
|
5027
5027
|
(notify) => {
|
|
5028
5028
|
const unsubscribe = [
|
|
5029
|
-
client.events.on(
|
|
5030
|
-
client.events.on(
|
|
5031
|
-
client.events.on(
|
|
5029
|
+
client.events.on(chunkSFG2LMRD_js.AUTH_TOKEN_CHANGED, notify),
|
|
5030
|
+
client.events.on(chunkSFG2LMRD_js.SESSION_CLAIMED, notify),
|
|
5031
|
+
client.events.on(chunkSFG2LMRD_js.SESSION_CLEARED, notify)
|
|
5032
5032
|
];
|
|
5033
5033
|
return () => {
|
|
5034
5034
|
for (const stopListening of unsubscribe) {
|
|
@@ -6268,7 +6268,7 @@ function useChat(options = {}) {
|
|
|
6268
6268
|
ws.onmessage = (event) => {
|
|
6269
6269
|
try {
|
|
6270
6270
|
const envelope = JSON.parse(event.data);
|
|
6271
|
-
const update =
|
|
6271
|
+
const update = chunkQKL5L5IU_js.chatRealtimeUpdateFromWire(envelope);
|
|
6272
6272
|
if (update.kind === "message") {
|
|
6273
6273
|
appendMessages([update.message]);
|
|
6274
6274
|
} else if (update.kind === "message_updated") {
|
|
@@ -6379,7 +6379,7 @@ function useChat(options = {}) {
|
|
|
6379
6379
|
const watchSessionClaims = React14.useCallback(() => {
|
|
6380
6380
|
const c = clientRef.current;
|
|
6381
6381
|
if (!c || claimUnsubRef.current) return;
|
|
6382
|
-
const unsubClaimed = c.events.on(
|
|
6382
|
+
const unsubClaimed = c.events.on(chunkSFG2LMRD_js.SESSION_CLAIMED, (event) => {
|
|
6383
6383
|
setClaimedAs(event.customerName || c.support.claimedCustomerName || null);
|
|
6384
6384
|
if (!openedRef.current) {
|
|
6385
6385
|
void openIfExisting();
|
|
@@ -6388,7 +6388,7 @@ function useChat(options = {}) {
|
|
|
6388
6388
|
connectWebSocket();
|
|
6389
6389
|
void resyncConversation();
|
|
6390
6390
|
});
|
|
6391
|
-
const unsubCleared = c.events.on(
|
|
6391
|
+
const unsubCleared = c.events.on(chunkSFG2LMRD_js.SESSION_CLEARED, resetConversation);
|
|
6392
6392
|
claimUnsubRef.current = () => {
|
|
6393
6393
|
unsubClaimed();
|
|
6394
6394
|
unsubCleared();
|
|
@@ -6440,7 +6440,7 @@ function useChat(options = {}) {
|
|
|
6440
6440
|
if (!openedRef.current) return false;
|
|
6441
6441
|
}
|
|
6442
6442
|
const replyTo = opts?.replyTo;
|
|
6443
|
-
const clientId =
|
|
6443
|
+
const clientId = chunkSFG2LMRD_js.generateIdempotencyKey();
|
|
6444
6444
|
const localId = optimisticId(clientId);
|
|
6445
6445
|
const optimistic = {
|
|
6446
6446
|
id: localId,
|
|
@@ -6629,15 +6629,15 @@ function AuthElement({
|
|
|
6629
6629
|
}, [onReady, onAuthenticated, onError]);
|
|
6630
6630
|
React14.useEffect(() => {
|
|
6631
6631
|
if (!elements || !containerRef.current) return;
|
|
6632
|
-
const element = elements.create(
|
|
6632
|
+
const element = elements.create(chunkSFG2LMRD_js.ELEMENT_TYPES.AUTH, { prefillEmail });
|
|
6633
6633
|
elementRef.current = element;
|
|
6634
|
-
element.on(
|
|
6634
|
+
element.on(chunkSFG2LMRD_js.EVENT_TYPES.READY, () => onReadyRef.current?.());
|
|
6635
6635
|
element.on(
|
|
6636
|
-
|
|
6636
|
+
chunkSFG2LMRD_js.EVENT_TYPES.AUTHENTICATED,
|
|
6637
6637
|
(data) => onAuthenticatedRef.current?.(data)
|
|
6638
6638
|
);
|
|
6639
6639
|
element.on(
|
|
6640
|
-
|
|
6640
|
+
chunkSFG2LMRD_js.EVENT_TYPES.ERROR,
|
|
6641
6641
|
(data) => onErrorRef.current?.(data)
|
|
6642
6642
|
);
|
|
6643
6643
|
element.mount(containerRef.current);
|
|
@@ -6666,15 +6666,15 @@ function AddressElement({
|
|
|
6666
6666
|
}, [onReady, onChange, onError]);
|
|
6667
6667
|
React14.useEffect(() => {
|
|
6668
6668
|
if (!elements || !containerRef.current) return;
|
|
6669
|
-
const element = elements.create(
|
|
6669
|
+
const element = elements.create(chunkSFG2LMRD_js.ELEMENT_TYPES.ADDRESS, { mode });
|
|
6670
6670
|
elementRef.current = element;
|
|
6671
|
-
element.on(
|
|
6671
|
+
element.on(chunkSFG2LMRD_js.EVENT_TYPES.READY, () => onReadyRef.current?.());
|
|
6672
6672
|
element.on(
|
|
6673
|
-
|
|
6673
|
+
chunkSFG2LMRD_js.EVENT_TYPES.CHANGE,
|
|
6674
6674
|
(data) => onChangeRef.current?.(data)
|
|
6675
6675
|
);
|
|
6676
6676
|
element.on(
|
|
6677
|
-
|
|
6677
|
+
chunkSFG2LMRD_js.EVENT_TYPES.ERROR,
|
|
6678
6678
|
(data) => onErrorRef.current?.(data)
|
|
6679
6679
|
);
|
|
6680
6680
|
element.mount(containerRef.current);
|
|
@@ -6704,15 +6704,15 @@ function PaymentElement({
|
|
|
6704
6704
|
}, [onReady, onChange, onError]);
|
|
6705
6705
|
React14.useEffect(() => {
|
|
6706
6706
|
if (!elements || !containerRef.current) return;
|
|
6707
|
-
const element = elements.create(
|
|
6707
|
+
const element = elements.create(chunkSFG2LMRD_js.ELEMENT_TYPES.PAYMENT, { amount, currency });
|
|
6708
6708
|
elementRef.current = element;
|
|
6709
|
-
element.on(
|
|
6709
|
+
element.on(chunkSFG2LMRD_js.EVENT_TYPES.READY, () => onReadyRef.current?.());
|
|
6710
6710
|
element.on(
|
|
6711
|
-
|
|
6711
|
+
chunkSFG2LMRD_js.EVENT_TYPES.CHANGE,
|
|
6712
6712
|
(data) => onChangeRef.current?.(data)
|
|
6713
6713
|
);
|
|
6714
6714
|
element.on(
|
|
6715
|
-
|
|
6715
|
+
chunkSFG2LMRD_js.EVENT_TYPES.ERROR,
|
|
6716
6716
|
(data) => onErrorRef.current?.(data)
|
|
6717
6717
|
);
|
|
6718
6718
|
element.mount(containerRef.current);
|