@snap/push2web 0.15.1 → 0.16.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 (40) hide show
  1. package/README.md +11 -7
  2. package/dist/Push2Web.d.ts +8 -9
  3. package/dist/Push2Web.js +9 -8
  4. package/dist/Push2WebSDKExtension.d.ts +5 -6
  5. package/dist/Push2WebSDKExtension.js +33 -18
  6. package/dist/generated-api-client/camera_kit/v3/export.d.ts +19 -19
  7. package/dist/generated-api-client/camera_kit/v3/export.js +18 -21
  8. package/dist/generated-api-client/camera_kit/v3/push_to_device.d.ts +12 -12
  9. package/dist/generated-api-client/camera_kit/v3/push_to_device.js +14 -17
  10. package/dist/generated-api-client/google/protobuf/descriptor.d.ts +4830 -4830
  11. package/dist/generated-api-client/google/protobuf/descriptor.js +14 -17
  12. package/docs/html/assets/main.js +4 -3
  13. package/docs/html/assets/navigation.js +1 -0
  14. package/docs/html/assets/search.js +1 -1
  15. package/docs/html/assets/style.css +72 -25
  16. package/docs/html/classes/Push2Web.html +15 -147
  17. package/docs/html/enums/Code.html +28 -198
  18. package/docs/html/enums/ListenLensPushResponse_ExcludedLens_Code.html +8 -98
  19. package/docs/html/enums/State.html +5 -79
  20. package/docs/html/index.html +6 -69
  21. package/docs/html/interfaces/Lens.html +12 -143
  22. package/docs/html/modules.html +12 -66
  23. package/docs/html/types/CommunicationErrorEvent.html +6 -76
  24. package/docs/html/types/ErrorEvent.html +1 -50
  25. package/docs/html/types/GenericErrorEvent.html +4 -66
  26. package/docs/html/types/LensExcludedErrorEvent.html +7 -78
  27. package/docs/html/types/LensReceivedEvent.html +1 -50
  28. package/docs/html/types/Push2WebEvents.html +1 -50
  29. package/docs/html/types/SubscriptionChangedEvent.html +1 -50
  30. package/docs/html/types/SubscriptionInstance.html +5 -79
  31. package/docs/md/README.md +12 -7
  32. package/docs/md/classes/Push2Web.md +16 -12
  33. package/docs/md/enums/Code.md +1 -1
  34. package/docs/md/enums/ListenLensPushResponse_ExcludedLens_Code.md +1 -1
  35. package/docs/md/enums/State.md +1 -1
  36. package/docs/md/interfaces/Lens.md +2 -2
  37. package/docs/md/modules.md +6 -6
  38. package/package.json +8 -5
  39. package/dist/reportEvent.d.ts +0 -3
  40. package/dist/reportEvent.js +0 -30
@@ -320,7 +320,7 @@ export const PushLensSubscriptionResponse_LensesEntry = {
320
320
  }
321
321
  };
322
322
  function createBasePushLensSubscriptionResponse_ExcludedLens() {
323
- return { lensId: 0, code: PushLensSubscriptionResponse_ExcludedLens_Code.UNSET };
323
+ return { lensId: "0", code: PushLensSubscriptionResponse_ExcludedLens_Code.UNSET };
324
324
  }
325
325
  export const PushLensSubscriptionResponse_ExcludedLens = {
326
326
  decode(input, length) {
@@ -331,7 +331,7 @@ export const PushLensSubscriptionResponse_ExcludedLens = {
331
331
  const tag = reader.uint32();
332
332
  switch (tag >>> 3) {
333
333
  case 1:
334
- message.lensId = longToNumber(reader.int64());
334
+ message.lensId = longToString(reader.int64());
335
335
  break;
336
336
  case 2:
337
337
  message.code = pushLensSubscriptionResponse_ExcludedLens_CodeFromJSON(reader.int32());
@@ -346,8 +346,8 @@ export const PushLensSubscriptionResponse_ExcludedLens = {
346
346
  fromJSON(object) {
347
347
  return {
348
348
  lensId: isSet(object.lensId)
349
- ? Number(object.lensId)
350
- : 0,
349
+ ? String(object.lensId)
350
+ : "0",
351
351
  code: isSet(object.code)
352
352
  ? pushLensSubscriptionResponse_ExcludedLens_CodeFromJSON(object.code)
353
353
  : PushLensSubscriptionResponse_ExcludedLens_Code.UNSET,
@@ -355,13 +355,13 @@ export const PushLensSubscriptionResponse_ExcludedLens = {
355
355
  },
356
356
  toJSON(message) {
357
357
  const obj = {};
358
- message.lensId !== undefined && (obj.lensId = Math.round(message.lensId));
358
+ message.lensId !== undefined && (obj.lensId = message.lensId);
359
359
  message.code !== undefined && (obj.code = pushLensSubscriptionResponse_ExcludedLens_CodeToJSON(message.code));
360
360
  return obj;
361
361
  },
362
362
  fromPartial(object) {
363
363
  const message = createBasePushLensSubscriptionResponse_ExcludedLens();
364
- message.lensId = object.lensId ?? 0;
364
+ message.lensId = object.lensId ?? "0";
365
365
  message.code = object.code ?? PushLensSubscriptionResponse_ExcludedLens_Code.UNSET;
366
366
  return message;
367
367
  }
@@ -543,7 +543,7 @@ export const ListenLensPushResponse_LensesEntry = {
543
543
  }
544
544
  };
545
545
  function createBaseListenLensPushResponse_ExcludedLens() {
546
- return { lensId: 0, code: ListenLensPushResponse_ExcludedLens_Code.UNSET };
546
+ return { lensId: "0", code: ListenLensPushResponse_ExcludedLens_Code.UNSET };
547
547
  }
548
548
  export const ListenLensPushResponse_ExcludedLens = {
549
549
  decode(input, length) {
@@ -554,7 +554,7 @@ export const ListenLensPushResponse_ExcludedLens = {
554
554
  const tag = reader.uint32();
555
555
  switch (tag >>> 3) {
556
556
  case 1:
557
- message.lensId = longToNumber(reader.int64());
557
+ message.lensId = longToString(reader.int64());
558
558
  break;
559
559
  case 2:
560
560
  message.code = listenLensPushResponse_ExcludedLens_CodeFromJSON(reader.int32());
@@ -569,8 +569,8 @@ export const ListenLensPushResponse_ExcludedLens = {
569
569
  fromJSON(object) {
570
570
  return {
571
571
  lensId: isSet(object.lensId)
572
- ? Number(object.lensId)
573
- : 0,
572
+ ? String(object.lensId)
573
+ : "0",
574
574
  code: isSet(object.code)
575
575
  ? listenLensPushResponse_ExcludedLens_CodeFromJSON(object.code)
576
576
  : ListenLensPushResponse_ExcludedLens_Code.UNSET,
@@ -578,13 +578,13 @@ export const ListenLensPushResponse_ExcludedLens = {
578
578
  },
579
579
  toJSON(message) {
580
580
  const obj = {};
581
- message.lensId !== undefined && (obj.lensId = Math.round(message.lensId));
581
+ message.lensId !== undefined && (obj.lensId = message.lensId);
582
582
  message.code !== undefined && (obj.code = listenLensPushResponse_ExcludedLens_CodeToJSON(message.code));
583
583
  return obj;
584
584
  },
585
585
  fromPartial(object) {
586
586
  const message = createBaseListenLensPushResponse_ExcludedLens();
587
- message.lensId = object.lensId ?? 0;
587
+ message.lensId = object.lensId ?? "0";
588
588
  message.code = object.code ?? ListenLensPushResponse_ExcludedLens_Code.UNSET;
589
589
  return message;
590
590
  }
@@ -733,11 +733,8 @@ function base64FromBytes(arr) {
733
733
  }
734
734
  return btoa(bin.join(''));
735
735
  }
736
- function longToNumber(long) {
737
- if (long.gt(Number.MAX_SAFE_INTEGER)) {
738
- throw new globalThis.Error("Value is larger than Number.MAX_SAFE_INTEGER");
739
- }
740
- return long.toNumber();
736
+ function longToString(long) {
737
+ return long.toString();
741
738
  }
742
739
  if (_m0.util.Long !== Long) {
743
740
  _m0.util.Long = Long;