@liveblocks/core 2.23.0 → 2.24.0-deque1

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.d.cts CHANGED
@@ -175,7 +175,7 @@ type EventSource<T> = Observable<T> & {
175
175
  * Be careful when using this API, because the subscribers may not have any
176
176
  * idea they won't be notified anymore.
177
177
  */
178
- [Symbol.dispose](): void;
178
+ dispose(): void;
179
179
  };
180
180
  /**
181
181
  * makeEventSource allows you to generate a subscribe/notify pair of functions
@@ -2896,7 +2896,7 @@ interface ISignal<T> {
2896
2896
  declare abstract class AbstractSignal<T> implements ISignal<T>, Observable<void> {
2897
2897
  #private;
2898
2898
  constructor(equals?: (a: T, b: T) => boolean);
2899
- [Symbol.dispose](): void;
2899
+ dispose(): void;
2900
2900
  abstract get(): T;
2901
2901
  get hasWatchers(): boolean;
2902
2902
  [kTrigger](): void;
@@ -2911,7 +2911,7 @@ declare abstract class AbstractSignal<T> implements ISignal<T>, Observable<void>
2911
2911
  declare class Signal<T> extends AbstractSignal<T> {
2912
2912
  #private;
2913
2913
  constructor(value: T, equals?: (a: T, b: T) => boolean);
2914
- [Symbol.dispose](): void;
2914
+ dispose(): void;
2915
2915
  get(): T;
2916
2916
  set(newValue: T | ((oldValue: T) => T)): void;
2917
2917
  }
@@ -2924,7 +2924,7 @@ declare class DerivedSignal<T> extends AbstractSignal<T> {
2924
2924
  [K in keyof Ts]: ISignal<Ts[K]>;
2925
2925
  }, transform: (...values: Ts) => V, equals: (a: V, b: V) => boolean]): DerivedSignal<V>;
2926
2926
  private constructor();
2927
- [Symbol.dispose](): void;
2927
+ dispose(): void;
2928
2928
  get isDirty(): boolean;
2929
2929
  markDirty(): void;
2930
2930
  get(): T;
@@ -2947,7 +2947,7 @@ declare class DerivedSignal<T> extends AbstractSignal<T> {
2947
2947
  declare class MutableSignal<T extends object> extends AbstractSignal<T> {
2948
2948
  #private;
2949
2949
  constructor(initialState: T);
2950
- [Symbol.dispose](): void;
2950
+ dispose(): void;
2951
2951
  get(): T;
2952
2952
  /**
2953
2953
  * Invokes a callback function that is allowed to mutate the given state
@@ -3638,6 +3638,35 @@ declare function throwUsageError(message: string): void;
3638
3638
  */
3639
3639
  declare function errorIf(condition: unknown, message: string): void;
3640
3640
 
3641
+ /**
3642
+ * A Deque (= Double Ended Queue) is like a stack, but where elements can be
3643
+ * efficiently pushed or popped from either side.
3644
+ *
3645
+ * The following calls are equivalent with arrays (but insertions are O(n)
3646
+ * instead of O(n^2)):
3647
+ *
3648
+ * - deque.push(1) ⇔ array.push(1)
3649
+ * - deque.push([1, 2, 3]) ⇔ array.push(1, 2, 3)
3650
+ * - deque.push(many) ⇔ array.push(...many)
3651
+ * - deque.pop() ⇔ array.pop()
3652
+ *
3653
+ * - deque.pushLeft(1) ⇔ array.unshift(1)
3654
+ * - deque.pushLeft([1, 2, 3]) ⇔ array.unshift(1, 2, 3)
3655
+ * - deque.pushLeft(many) ⇔ array.unshift(...many)
3656
+ * - deque.popLeft() ⇔ array.shift()
3657
+ *
3658
+ */
3659
+ declare class Deque<T> {
3660
+ #private;
3661
+ constructor();
3662
+ get length(): number;
3663
+ [Symbol.iterator](): IterableIterator<T>;
3664
+ push(value: T | readonly T[]): void;
3665
+ pop(): T | undefined;
3666
+ pushLeft(value: T | readonly T[]): void;
3667
+ popLeft(): T | undefined;
3668
+ }
3669
+
3641
3670
  declare const warn: (message: string, ...args: readonly unknown[]) => void;
3642
3671
  declare const error: (message: string, ...args: readonly unknown[]) => void;
3643
3672
  declare const warnWithTitle: (title: string, message: string, ...args: readonly unknown[]) => void;
@@ -4089,4 +4118,4 @@ declare const CommentsApiError: typeof HttpError;
4089
4118
  /** @deprecated Use HttpError instead. */
4090
4119
  declare const NotificationsApiError: typeof HttpError;
4091
4120
 
4092
- export { type AckOp, type ActivityData, type AsyncError, type AsyncLoading, type AsyncResult, type AsyncSuccess, type Awaitable, type BaseActivitiesData, type BaseAuthResult, type BaseMetadata, type BaseRoomInfo, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type Client, type ClientMsg, ClientMsgCode, type ClientOptions, type CommentAttachment, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentLocalAttachment, type CommentMixedAttachment, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, type ContextualPromptContext, type ContextualPromptResponse, CrdtType, type CreateListOp, type CreateManagedPoolOptions, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type DAD, type DE, type DM, type DP, type DRI, type DS, type DU, DefaultMap, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, DerivedSignal, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type DistributiveOmit, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type HistoryVersion, HttpError, type ISignal, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IYjsProvider, type IdTuple, type Immutable, type InboxNotificationCustomData, type InboxNotificationCustomDataPlain, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationDeleteInfo, type InboxNotificationTextMentionData, type InboxNotificationTextMentionDataPlain, type InboxNotificationThreadData, type InboxNotificationThreadDataPlain, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type KDAD, type LargeMessageStrategy, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, LiveblocksError, type LiveblocksErrorContext, type LostConnectionEvent, type Lson, type LsonObject, type ManagedPool, MutableSignal, type NoInfr, type NodeMap, type NotificationChannel, type NotificationChannelSettings, type NotificationKind, NotificationsApiError, type Observable, type Op, OpCode, type OpaqueClient, type OpaqueRoom, type OptionalTupleUnless, type OthersEvent, type ParentToChildNodeMap, type PartialUnless, type PartialUserNotificationSettings, type Patchable, Permission, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type Poller, type PrivateClientApi, type PrivateRoomApi, Promise_withResolvers, type QueryMetadata, type QueryParams, type RejectedStorageOpServerMsg, type Relax, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, Signal, type SignalType, SortedList, type Status, type StorageStatus, type StorageUpdate, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type SyncSource, type SyncStatus, TextEditorType, type ThreadData, type ThreadDataPlain, type ThreadDataWithDeleteInfo, type ThreadDeleteInfo, type ToImmutable, type ToJson, type URLSafeString, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type UploadAttachmentOptions, type User, type UserJoinServerMsg, type UserLeftServerMsg, type UserNotificationSettings, type UserNotificationSettingsPlain, WebsocketCloseCodes, type YDocUpdateServerMsg, type YjsSyncStatus, ackOp, asPos, assert, assertNever, autoRetry, b64decode, batch, checkBounds, chunk, cloneLson, compactObject, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToInboxNotificationData, convertToThreadData, createClient, createCommentAttachmentId, createCommentId, createInboxNotificationId, createManagedPool, createThreadId, createUserNotificationSettings, deprecate, deprecateIf, detectDupes, entries, errorIf, freeze, generateCommentUrl, getMentionedIdsFromCommentBody, html, htmlSafe, isChildCrdt, isCommentBodyLink, isCommentBodyMention, isCommentBodyText, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isNotificationChannelEnabled, isPlainObject, isRootCrdt, isStartsWithOperator, kInternal, keys, legacy_patchImmutableObject, lsonToJson, makeAbortController, makeEventSource, makePoller, makePosition, mapValues, memoizeOnSuccess, nanoid, nn, objectToQuery, patchLiveObjectKey, patchUserNotificationSettings, raise, resolveUsersInCommentBody, shallow, stableStringify, stringifyCommentBody, throwUsageError, toAbsoluteUrl, toPlainLson, tryParseJson, url, urljoin, wait, withTimeout };
4121
+ export { type AckOp, type ActivityData, type AsyncError, type AsyncLoading, type AsyncResult, type AsyncSuccess, type Awaitable, type BaseActivitiesData, type BaseAuthResult, type BaseMetadata, type BaseRoomInfo, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type Client, type ClientMsg, ClientMsgCode, type ClientOptions, type CommentAttachment, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentLocalAttachment, type CommentMixedAttachment, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, type ContextualPromptContext, type ContextualPromptResponse, CrdtType, type CreateListOp, type CreateManagedPoolOptions, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type DAD, type DE, type DM, type DP, type DRI, type DS, type DU, DefaultMap, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, Deque, DerivedSignal, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type DistributiveOmit, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type HistoryVersion, HttpError, type ISignal, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IYjsProvider, type IdTuple, type Immutable, type InboxNotificationCustomData, type InboxNotificationCustomDataPlain, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationDeleteInfo, type InboxNotificationTextMentionData, type InboxNotificationTextMentionDataPlain, type InboxNotificationThreadData, type InboxNotificationThreadDataPlain, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type KDAD, type LargeMessageStrategy, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, LiveblocksError, type LiveblocksErrorContext, type LostConnectionEvent, type Lson, type LsonObject, type ManagedPool, MutableSignal, type NoInfr, type NodeMap, type NotificationChannel, type NotificationChannelSettings, type NotificationKind, NotificationsApiError, type Observable, type Op, OpCode, type OpaqueClient, type OpaqueRoom, type OptionalTupleUnless, type OthersEvent, type ParentToChildNodeMap, type PartialUnless, type PartialUserNotificationSettings, type Patchable, Permission, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type Poller, type PrivateClientApi, type PrivateRoomApi, Promise_withResolvers, type QueryMetadata, type QueryParams, type RejectedStorageOpServerMsg, type Relax, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, Signal, type SignalType, SortedList, type Status, type StorageStatus, type StorageUpdate, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type SyncSource, type SyncStatus, TextEditorType, type ThreadData, type ThreadDataPlain, type ThreadDataWithDeleteInfo, type ThreadDeleteInfo, type ToImmutable, type ToJson, type URLSafeString, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type UploadAttachmentOptions, type User, type UserJoinServerMsg, type UserLeftServerMsg, type UserNotificationSettings, type UserNotificationSettingsPlain, WebsocketCloseCodes, type YDocUpdateServerMsg, type YjsSyncStatus, ackOp, asPos, assert, assertNever, autoRetry, b64decode, batch, checkBounds, chunk, cloneLson, compactObject, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToInboxNotificationData, convertToThreadData, createClient, createCommentAttachmentId, createCommentId, createInboxNotificationId, createManagedPool, createThreadId, createUserNotificationSettings, deprecate, deprecateIf, detectDupes, entries, errorIf, freeze, generateCommentUrl, getMentionedIdsFromCommentBody, html, htmlSafe, isChildCrdt, isCommentBodyLink, isCommentBodyMention, isCommentBodyText, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isNotificationChannelEnabled, isPlainObject, isRootCrdt, isStartsWithOperator, kInternal, keys, legacy_patchImmutableObject, lsonToJson, makeAbortController, makeEventSource, makePoller, makePosition, mapValues, memoizeOnSuccess, nanoid, nn, objectToQuery, patchLiveObjectKey, patchUserNotificationSettings, raise, resolveUsersInCommentBody, shallow, stableStringify, stringifyCommentBody, throwUsageError, toAbsoluteUrl, toPlainLson, tryParseJson, url, urljoin, wait, withTimeout };
package/dist/index.d.ts CHANGED
@@ -175,7 +175,7 @@ type EventSource<T> = Observable<T> & {
175
175
  * Be careful when using this API, because the subscribers may not have any
176
176
  * idea they won't be notified anymore.
177
177
  */
178
- [Symbol.dispose](): void;
178
+ dispose(): void;
179
179
  };
180
180
  /**
181
181
  * makeEventSource allows you to generate a subscribe/notify pair of functions
@@ -2896,7 +2896,7 @@ interface ISignal<T> {
2896
2896
  declare abstract class AbstractSignal<T> implements ISignal<T>, Observable<void> {
2897
2897
  #private;
2898
2898
  constructor(equals?: (a: T, b: T) => boolean);
2899
- [Symbol.dispose](): void;
2899
+ dispose(): void;
2900
2900
  abstract get(): T;
2901
2901
  get hasWatchers(): boolean;
2902
2902
  [kTrigger](): void;
@@ -2911,7 +2911,7 @@ declare abstract class AbstractSignal<T> implements ISignal<T>, Observable<void>
2911
2911
  declare class Signal<T> extends AbstractSignal<T> {
2912
2912
  #private;
2913
2913
  constructor(value: T, equals?: (a: T, b: T) => boolean);
2914
- [Symbol.dispose](): void;
2914
+ dispose(): void;
2915
2915
  get(): T;
2916
2916
  set(newValue: T | ((oldValue: T) => T)): void;
2917
2917
  }
@@ -2924,7 +2924,7 @@ declare class DerivedSignal<T> extends AbstractSignal<T> {
2924
2924
  [K in keyof Ts]: ISignal<Ts[K]>;
2925
2925
  }, transform: (...values: Ts) => V, equals: (a: V, b: V) => boolean]): DerivedSignal<V>;
2926
2926
  private constructor();
2927
- [Symbol.dispose](): void;
2927
+ dispose(): void;
2928
2928
  get isDirty(): boolean;
2929
2929
  markDirty(): void;
2930
2930
  get(): T;
@@ -2947,7 +2947,7 @@ declare class DerivedSignal<T> extends AbstractSignal<T> {
2947
2947
  declare class MutableSignal<T extends object> extends AbstractSignal<T> {
2948
2948
  #private;
2949
2949
  constructor(initialState: T);
2950
- [Symbol.dispose](): void;
2950
+ dispose(): void;
2951
2951
  get(): T;
2952
2952
  /**
2953
2953
  * Invokes a callback function that is allowed to mutate the given state
@@ -3638,6 +3638,35 @@ declare function throwUsageError(message: string): void;
3638
3638
  */
3639
3639
  declare function errorIf(condition: unknown, message: string): void;
3640
3640
 
3641
+ /**
3642
+ * A Deque (= Double Ended Queue) is like a stack, but where elements can be
3643
+ * efficiently pushed or popped from either side.
3644
+ *
3645
+ * The following calls are equivalent with arrays (but insertions are O(n)
3646
+ * instead of O(n^2)):
3647
+ *
3648
+ * - deque.push(1) ⇔ array.push(1)
3649
+ * - deque.push([1, 2, 3]) ⇔ array.push(1, 2, 3)
3650
+ * - deque.push(many) ⇔ array.push(...many)
3651
+ * - deque.pop() ⇔ array.pop()
3652
+ *
3653
+ * - deque.pushLeft(1) ⇔ array.unshift(1)
3654
+ * - deque.pushLeft([1, 2, 3]) ⇔ array.unshift(1, 2, 3)
3655
+ * - deque.pushLeft(many) ⇔ array.unshift(...many)
3656
+ * - deque.popLeft() ⇔ array.shift()
3657
+ *
3658
+ */
3659
+ declare class Deque<T> {
3660
+ #private;
3661
+ constructor();
3662
+ get length(): number;
3663
+ [Symbol.iterator](): IterableIterator<T>;
3664
+ push(value: T | readonly T[]): void;
3665
+ pop(): T | undefined;
3666
+ pushLeft(value: T | readonly T[]): void;
3667
+ popLeft(): T | undefined;
3668
+ }
3669
+
3641
3670
  declare const warn: (message: string, ...args: readonly unknown[]) => void;
3642
3671
  declare const error: (message: string, ...args: readonly unknown[]) => void;
3643
3672
  declare const warnWithTitle: (title: string, message: string, ...args: readonly unknown[]) => void;
@@ -4089,4 +4118,4 @@ declare const CommentsApiError: typeof HttpError;
4089
4118
  /** @deprecated Use HttpError instead. */
4090
4119
  declare const NotificationsApiError: typeof HttpError;
4091
4120
 
4092
- export { type AckOp, type ActivityData, type AsyncError, type AsyncLoading, type AsyncResult, type AsyncSuccess, type Awaitable, type BaseActivitiesData, type BaseAuthResult, type BaseMetadata, type BaseRoomInfo, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type Client, type ClientMsg, ClientMsgCode, type ClientOptions, type CommentAttachment, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentLocalAttachment, type CommentMixedAttachment, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, type ContextualPromptContext, type ContextualPromptResponse, CrdtType, type CreateListOp, type CreateManagedPoolOptions, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type DAD, type DE, type DM, type DP, type DRI, type DS, type DU, DefaultMap, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, DerivedSignal, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type DistributiveOmit, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type HistoryVersion, HttpError, type ISignal, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IYjsProvider, type IdTuple, type Immutable, type InboxNotificationCustomData, type InboxNotificationCustomDataPlain, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationDeleteInfo, type InboxNotificationTextMentionData, type InboxNotificationTextMentionDataPlain, type InboxNotificationThreadData, type InboxNotificationThreadDataPlain, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type KDAD, type LargeMessageStrategy, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, LiveblocksError, type LiveblocksErrorContext, type LostConnectionEvent, type Lson, type LsonObject, type ManagedPool, MutableSignal, type NoInfr, type NodeMap, type NotificationChannel, type NotificationChannelSettings, type NotificationKind, NotificationsApiError, type Observable, type Op, OpCode, type OpaqueClient, type OpaqueRoom, type OptionalTupleUnless, type OthersEvent, type ParentToChildNodeMap, type PartialUnless, type PartialUserNotificationSettings, type Patchable, Permission, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type Poller, type PrivateClientApi, type PrivateRoomApi, Promise_withResolvers, type QueryMetadata, type QueryParams, type RejectedStorageOpServerMsg, type Relax, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, Signal, type SignalType, SortedList, type Status, type StorageStatus, type StorageUpdate, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type SyncSource, type SyncStatus, TextEditorType, type ThreadData, type ThreadDataPlain, type ThreadDataWithDeleteInfo, type ThreadDeleteInfo, type ToImmutable, type ToJson, type URLSafeString, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type UploadAttachmentOptions, type User, type UserJoinServerMsg, type UserLeftServerMsg, type UserNotificationSettings, type UserNotificationSettingsPlain, WebsocketCloseCodes, type YDocUpdateServerMsg, type YjsSyncStatus, ackOp, asPos, assert, assertNever, autoRetry, b64decode, batch, checkBounds, chunk, cloneLson, compactObject, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToInboxNotificationData, convertToThreadData, createClient, createCommentAttachmentId, createCommentId, createInboxNotificationId, createManagedPool, createThreadId, createUserNotificationSettings, deprecate, deprecateIf, detectDupes, entries, errorIf, freeze, generateCommentUrl, getMentionedIdsFromCommentBody, html, htmlSafe, isChildCrdt, isCommentBodyLink, isCommentBodyMention, isCommentBodyText, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isNotificationChannelEnabled, isPlainObject, isRootCrdt, isStartsWithOperator, kInternal, keys, legacy_patchImmutableObject, lsonToJson, makeAbortController, makeEventSource, makePoller, makePosition, mapValues, memoizeOnSuccess, nanoid, nn, objectToQuery, patchLiveObjectKey, patchUserNotificationSettings, raise, resolveUsersInCommentBody, shallow, stableStringify, stringifyCommentBody, throwUsageError, toAbsoluteUrl, toPlainLson, tryParseJson, url, urljoin, wait, withTimeout };
4121
+ export { type AckOp, type ActivityData, type AsyncError, type AsyncLoading, type AsyncResult, type AsyncSuccess, type Awaitable, type BaseActivitiesData, type BaseAuthResult, type BaseMetadata, type BaseRoomInfo, type BaseUserMeta, type Brand, type BroadcastEventClientMsg, type BroadcastOptions, type BroadcastedEventServerMsg, type Client, type ClientMsg, ClientMsgCode, type ClientOptions, type CommentAttachment, type CommentBody, type CommentBodyBlockElement, type CommentBodyElement, type CommentBodyInlineElement, type CommentBodyLink, type CommentBodyLinkElementArgs, type CommentBodyMention, type CommentBodyMentionElementArgs, type CommentBodyParagraph, type CommentBodyParagraphElementArgs, type CommentBodyText, type CommentBodyTextElementArgs, type CommentData, type CommentDataPlain, type CommentLocalAttachment, type CommentMixedAttachment, type CommentReaction, type CommentUserReaction, type CommentUserReactionPlain, CommentsApiError, type CommentsEventServerMsg, type ContextualPromptContext, type ContextualPromptResponse, CrdtType, type CreateListOp, type CreateManagedPoolOptions, type CreateMapOp, type CreateObjectOp, type CreateOp, type CreateRegisterOp, type CustomAuthenticationResult, type DAD, type DE, type DM, type DP, type DRI, type DS, type DU, DefaultMap, type Delegates, type DeleteCrdtOp, type DeleteObjectKeyOp, Deque, DerivedSignal, DevToolsTreeNode as DevTools, protocol as DevToolsMsg, type DistributiveOmit, type EnsureJson, type EnterOptions, type EventSource, type FetchStorageClientMsg, type FetchYDocClientMsg, type GetThreadsOptions, type History, type HistoryVersion, HttpError, type ISignal, type IUserInfo, type IWebSocket, type IWebSocketCloseEvent, type IWebSocketEvent, type IWebSocketInstance, type IWebSocketMessageEvent, type IYjsProvider, type IdTuple, type Immutable, type InboxNotificationCustomData, type InboxNotificationCustomDataPlain, type InboxNotificationData, type InboxNotificationDataPlain, type InboxNotificationDeleteInfo, type InboxNotificationTextMentionData, type InboxNotificationTextMentionDataPlain, type InboxNotificationThreadData, type InboxNotificationThreadDataPlain, type InitialDocumentStateServerMsg, type Json, type JsonArray, type JsonObject, type JsonScalar, type KDAD, type LargeMessageStrategy, LiveList, type LiveListUpdate, LiveMap, type LiveMapUpdate, type LiveNode, LiveObject, type LiveObjectUpdate, type LiveStructure, LiveblocksError, type LiveblocksErrorContext, type LostConnectionEvent, type Lson, type LsonObject, type ManagedPool, MutableSignal, type NoInfr, type NodeMap, type NotificationChannel, type NotificationChannelSettings, type NotificationKind, NotificationsApiError, type Observable, type Op, OpCode, type OpaqueClient, type OpaqueRoom, type OptionalTupleUnless, type OthersEvent, type ParentToChildNodeMap, type PartialUnless, type PartialUserNotificationSettings, type Patchable, Permission, type PlainLson, type PlainLsonFields, type PlainLsonList, type PlainLsonMap, type PlainLsonObject, type Poller, type PrivateClientApi, type PrivateRoomApi, Promise_withResolvers, type QueryMetadata, type QueryParams, type RejectedStorageOpServerMsg, type Relax, type Resolve, type ResolveMentionSuggestionsArgs, type ResolveRoomsInfoArgs, type ResolveUsersArgs, type Room, type RoomEventMessage, type RoomNotificationSettings, type RoomStateServerMsg, type SerializedChild, type SerializedCrdt, type SerializedList, type SerializedMap, type SerializedObject, type SerializedRegister, type SerializedRootObject, type ServerMsg, ServerMsgCode, type SetParentKeyOp, Signal, type SignalType, SortedList, type Status, type StorageStatus, type StorageUpdate, type StringifyCommentBodyElements, type StringifyCommentBodyOptions, type SyncSource, type SyncStatus, TextEditorType, type ThreadData, type ThreadDataPlain, type ThreadDataWithDeleteInfo, type ThreadDeleteInfo, type ToImmutable, type ToJson, type URLSafeString, type UnsubscribeCallback, type UpdateObjectOp, type UpdatePresenceClientMsg, type UpdatePresenceServerMsg, type UpdateStorageClientMsg, type UpdateStorageServerMsg, type UpdateYDocClientMsg, type UploadAttachmentOptions, type User, type UserJoinServerMsg, type UserLeftServerMsg, type UserNotificationSettings, type UserNotificationSettingsPlain, WebsocketCloseCodes, type YDocUpdateServerMsg, type YjsSyncStatus, ackOp, asPos, assert, assertNever, autoRetry, b64decode, batch, checkBounds, chunk, cloneLson, compactObject, fancyConsole as console, convertToCommentData, convertToCommentUserReaction, convertToInboxNotificationData, convertToThreadData, createClient, createCommentAttachmentId, createCommentId, createInboxNotificationId, createManagedPool, createThreadId, createUserNotificationSettings, deprecate, deprecateIf, detectDupes, entries, errorIf, freeze, generateCommentUrl, getMentionedIdsFromCommentBody, html, htmlSafe, isChildCrdt, isCommentBodyLink, isCommentBodyMention, isCommentBodyText, isJsonArray, isJsonObject, isJsonScalar, isLiveNode, isNotificationChannelEnabled, isPlainObject, isRootCrdt, isStartsWithOperator, kInternal, keys, legacy_patchImmutableObject, lsonToJson, makeAbortController, makeEventSource, makePoller, makePosition, mapValues, memoizeOnSuccess, nanoid, nn, objectToQuery, patchLiveObjectKey, patchUserNotificationSettings, raise, resolveUsersInCommentBody, shallow, stableStringify, stringifyCommentBody, throwUsageError, toAbsoluteUrl, toPlainLson, tryParseJson, url, urljoin, wait, withTimeout };
package/dist/index.js 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.23.0";
9
+ var PKG_VERSION = "2.24.0-deque1";
10
10
  var PKG_FORMAT = "esm";
11
11
 
12
12
  // src/dupe-detection.ts
@@ -395,7 +395,7 @@ function makeEventSource() {
395
395
  subscribeOnce,
396
396
  count,
397
397
  waitUntil,
398
- [Symbol.dispose]: () => {
398
+ dispose() {
399
399
  _observers.clear();
400
400
  },
401
401
  // Publicly exposable subscription API
@@ -434,8 +434,8 @@ function makeBufferableEventSource() {
434
434
  notify: notifyOrBuffer,
435
435
  pause,
436
436
  unpause,
437
- [Symbol.dispose]: () => {
438
- eventSource2[Symbol.dispose]();
437
+ dispose() {
438
+ eventSource2.dispose();
439
439
  if (_buffer !== null) {
440
440
  _buffer.length = 0;
441
441
  }
@@ -504,8 +504,8 @@ var AbstractSignal = class {
504
504
  this.subscribe = this.subscribe.bind(this);
505
505
  this.subscribeOnce = this.subscribeOnce.bind(this);
506
506
  }
507
- [Symbol.dispose]() {
508
- this.#eventSource[Symbol.dispose]();
507
+ dispose() {
508
+ this.#eventSource.dispose();
509
509
  this.#eventSource = "(disposed)";
510
510
  this.equals = "(disposed)";
511
511
  }
@@ -561,8 +561,8 @@ var Signal = class extends AbstractSignal {
561
561
  super(equals);
562
562
  this.#value = freeze(value);
563
563
  }
564
- [Symbol.dispose]() {
565
- super[Symbol.dispose]();
564
+ dispose() {
565
+ super.dispose();
566
566
  this.#value = "(disposed)";
567
567
  }
568
568
  get() {
@@ -626,7 +626,7 @@ var DerivedSignal = class _DerivedSignal extends AbstractSignal {
626
626
  this.#sources = /* @__PURE__ */ new Set();
627
627
  this.#transform = transform;
628
628
  }
629
- [Symbol.dispose]() {
629
+ dispose() {
630
630
  for (const src of this.#sources) {
631
631
  src.removeSink(this);
632
632
  }
@@ -701,8 +701,8 @@ var MutableSignal = class extends AbstractSignal {
701
701
  super();
702
702
  this.#state = initialState;
703
703
  }
704
- [Symbol.dispose]() {
705
- super[Symbol.dispose]();
704
+ dispose() {
705
+ super.dispose();
706
706
  this.#state = "(disposed)";
707
707
  }
708
708
  get() {
@@ -7866,7 +7866,7 @@ ${Array.from(traces).join("\n\n")}`
7866
7866
  destroy: () => {
7867
7867
  const { roomWillDestroy, ...eventsExceptDestroy } = eventHub;
7868
7868
  for (const source of Object.values(eventsExceptDestroy)) {
7869
- source[Symbol.dispose]();
7869
+ source.dispose();
7870
7870
  }
7871
7871
  eventHub.roomWillDestroy.notify();
7872
7872
  context.yjsProvider?.off("status", yjsStatusDidChange);
@@ -7874,7 +7874,7 @@ ${Array.from(traces).join("\n\n")}`
7874
7874
  syncSourceForYjs.destroy();
7875
7875
  uninstallBgTabSpy();
7876
7876
  managedSocket.destroy();
7877
- roomWillDestroy[Symbol.dispose]();
7877
+ roomWillDestroy.dispose();
7878
7878
  },
7879
7879
  // Presence
7880
7880
  updatePresence,
@@ -9315,6 +9315,7 @@ export {
9315
9315
  CommentsApiError,
9316
9316
  CrdtType,
9317
9317
  DefaultMap,
9318
+ Deque,
9318
9319
  DerivedSignal,
9319
9320
  HttpError,
9320
9321
  LiveList,