@liveblocks/core 2.18.4-uns2 → 2.20.0

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/index.cjs CHANGED
@@ -6,7 +6,7 @@ var __export = (target, all) => {
6
6
 
7
7
  // src/version.ts
8
8
  var PKG_NAME = "@liveblocks/core";
9
- var PKG_VERSION = "2.18.4-uns2";
9
+ var PKG_VERSION = "2.20.0";
10
10
  var PKG_FORMAT = "cjs";
11
11
 
12
12
  // src/dupe-detection.ts
@@ -3604,7 +3604,7 @@ function unlinkDevTools(roomId) {
3604
3604
  }
3605
3605
 
3606
3606
  // src/protocol/UserNotificationSettings.ts
3607
- var kPrivate = Symbol("user-notification-settings-private");
3607
+ var kPlain = Symbol("user-notification-settings-plain");
3608
3608
  function createUserNotificationSettings(plain) {
3609
3609
  const channels = [
3610
3610
  "email",
@@ -3613,10 +3613,8 @@ function createUserNotificationSettings(plain) {
3613
3613
  "webPush"
3614
3614
  ];
3615
3615
  const descriptors = {
3616
- [kPrivate]: {
3617
- value: {
3618
- __plain__: plain
3619
- },
3616
+ [kPlain]: {
3617
+ value: plain,
3620
3618
  enumerable: false
3621
3619
  }
3622
3620
  };
@@ -3635,10 +3633,10 @@ function createUserNotificationSettings(plain) {
3635
3633
  * creating a well known shaped object → `UserNotificationSettings`.
3636
3634
  */
3637
3635
  get() {
3638
- const value = this[kPrivate].__plain__[channel];
3636
+ const value = this[kPlain][channel];
3639
3637
  if (typeof value === "undefined") {
3640
3638
  error2(
3641
- `In order to use the '${channel}' channel, please set up your project first. For more information https://liveblocks.io/docs/errors/enable-a-notification-channel`
3639
+ `In order to use the '${channel}' channel, please set up your project first. For more information: https://liveblocks.io/docs/errors/enable-a-notification-channel`
3642
3640
  );
3643
3641
  return null;
3644
3642
  }
@@ -3650,7 +3648,7 @@ function createUserNotificationSettings(plain) {
3650
3648
  }
3651
3649
  function patchUserNotificationSettings(existing, patch) {
3652
3650
  const outcoming = createUserNotificationSettings({
3653
- ...existing[kPrivate].__plain__
3651
+ ...existing[kPlain]
3654
3652
  });
3655
3653
  for (const channel of keys(patch)) {
3656
3654
  const updates = patch[channel];
@@ -3658,8 +3656,8 @@ function patchUserNotificationSettings(existing, patch) {
3658
3656
  const kindUpdates = Object.fromEntries(
3659
3657
  entries(updates).filter(([, value]) => value !== void 0)
3660
3658
  );
3661
- outcoming[kPrivate].__plain__[channel] = {
3662
- ...outcoming[kPrivate].__plain__[channel],
3659
+ outcoming[kPlain][channel] = {
3660
+ ...outcoming[kPlain][channel],
3663
3661
  ...kindUpdates
3664
3662
  };
3665
3663
  }