@abraca/dabra 2.95.0 → 2.96.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.d.ts CHANGED
@@ -169,7 +169,35 @@ declare class OfflineStore {
169
169
  private dbPromise;
170
170
  private _destroyed;
171
171
  private getDb;
172
+ /** Updates buffered for the next batched write. */
173
+ private writeBuffer;
174
+ /** Callers of `persistUpdate` awaiting the batch that carries their update. */
175
+ private writeWaiters;
176
+ private flushTimer;
177
+ /**
178
+ * Queue a local update for persistence.
179
+ *
180
+ * The returned promise settles when the update has actually been committed,
181
+ * not when it was queued — so `await persistUpdate(u)` still means "on disk",
182
+ * exactly as it did when every call opened its own transaction.
183
+ */
172
184
  persistUpdate(update: Uint8Array): Promise<void>;
185
+ /**
186
+ * Commit every buffered update as ONE transaction.
187
+ *
188
+ * Safe to call at any time, including with an empty buffer — every read path
189
+ * calls it first so a caller can never observe a store that is missing writes
190
+ * still sitting in memory.
191
+ */
192
+ flushWrites(): Promise<void>;
193
+ /**
194
+ * Issue the buffered writes synchronously, without awaiting them.
195
+ *
196
+ * For teardown paths that cannot await: `pagehide` (the page may not survive
197
+ * a microtask) and `destroy()`. IndexedDB will not close a connection until
198
+ * its running transactions finish, so writes issued here still land.
199
+ */
200
+ flushWritesSync(): void;
173
201
  getPendingUpdates(): Promise<Uint8Array[]>;
174
202
  clearPendingUpdates(): Promise<void>;
175
203
  /**
@@ -1751,6 +1779,16 @@ declare class AbracadabraProvider extends AbracadabraBaseProvider {
1751
1779
  private evictLRU;
1752
1780
  /** Return all currently-loaded child providers. */
1753
1781
  get children(): Map<string, AbracadabraProvider>;
1782
+ /**
1783
+ * Land buffered offline writes before the page goes away.
1784
+ *
1785
+ * `OfflineStore` coalesces local updates into one transaction per ~150 ms
1786
+ * window (see WRITE_COALESCE_MS). That window is the only moment an edit
1787
+ * exists in memory but not on disk, and a closing tab is exactly when it
1788
+ * would be lost — so pagehide flushes it synchronously. `super.pageHide()`
1789
+ * still clears our awareness state for peers.
1790
+ */
1791
+ pageHide(): void;
1754
1792
  /**
1755
1793
  * Override to persist every local update to IndexedDB before sending it
1756
1794
  * over the wire, ensuring no work is lost during connection outages.
@@ -2696,6 +2734,7 @@ declare class AbracadabraWS extends EventEmitter {
2696
2734
  } | null;
2697
2735
  private onlineListener;
2698
2736
  private offlineListener;
2737
+ unsubscribeLifecycle: (() => void) | null;
2699
2738
  constructor(configuration: AbracadabraWSConfiguration);
2700
2739
  /**
2701
2740
  * Whether the device currently believes it has network connectivity.
@@ -3096,6 +3135,30 @@ interface CompleteAbracadabraBaseProviderConfiguration {
3096
3135
  * socket connection, or ensure that the Provider receives messages before running into `AbracadabraWS.messageReconnectTimeout`.
3097
3136
  */
3098
3137
  awareness: Awareness | null;
3138
+ /**
3139
+ * Defer building the Awareness instance until something actually reads
3140
+ * `provider.awareness`.
3141
+ *
3142
+ * Every Awareness costs a 3 s `setInterval` for as long as it lives, plus a
3143
+ * wire frame every 15 s to renew its clock — forever, whether or not a human
3144
+ * is looking at the document. That is the right price for a document someone
3145
+ * has open, and pure waste for the dozens a background indexer or a search
3146
+ * sweep opens and closes. Measured: 10 loaded children = 11 instances = 66
3147
+ * heartbeat callbacks per 20 s idle.
3148
+ *
3149
+ * When this is set, the instance is built on first access instead of in the
3150
+ * constructor, and building it also publishes local state and queries peers,
3151
+ * so a document that later gains an editor gets symmetric presence exactly as
3152
+ * if it had been eager all along. Consumers see no difference: the public
3153
+ * `awareness` accessor always returns a usable instance.
3154
+ *
3155
+ * `AbracadabraProvider.loadChild` sets this. Top-level providers stay eager,
3156
+ * so every socket keeps at least one heartbeat and the liveness assumption in
3157
+ * `AbracadabraWS.checkConnection` is untouched.
3158
+ *
3159
+ * Ignored when an explicit `awareness` (including `null`) is supplied.
3160
+ */
3161
+ lazyAwareness?: boolean;
3099
3162
  /**
3100
3163
  * A token that's sent to the backend for authentication purposes.
3101
3164
  */
@@ -3223,7 +3286,42 @@ declare class AbracadabraBaseProvider extends EventEmitter {
3223
3286
  setConfiguration(configuration?: Partial<AbracadabraBaseProviderConfiguration>): void;
3224
3287
  get document(): Y.Doc;
3225
3288
  get isAttached(): boolean;
3289
+ /** True while an Awareness instance is owed but has not been built yet. */
3290
+ private _awarenessDeferred;
3291
+ /** True when the caller passed `awareness: null` and meant it. */
3292
+ private _awarenessExplicitlyNull;
3293
+ /**
3294
+ * The presence instance for this document, built on demand.
3295
+ *
3296
+ * Reading this materializes a deferred instance (see `lazyAwareness`), which
3297
+ * is why every consumer — TipTap's CollaborationCaret, presence UI, app code
3298
+ * — keeps working unchanged: touching `.awareness` is itself the signal that
3299
+ * this document needs presence.
3300
+ *
3301
+ * Provider INTERNALS must use `peekAwareness()` instead, or the lazy path
3302
+ * materializes everything it was meant to avoid.
3303
+ */
3226
3304
  get awareness(): Awareness | null;
3305
+ /**
3306
+ * The Awareness instance if one exists, without ever creating one.
3307
+ *
3308
+ * @internal Used by provider internals and `MessageReceiver`. A deferred
3309
+ * document has no local presence, so there is nothing for an inbound
3310
+ * awareness frame to be applied to and nothing to answer a peer's query with
3311
+ * — and materializing on a peer's frame would hand every idle background
3312
+ * document a heartbeat as soon as anyone else joined the space.
3313
+ */
3314
+ peekAwareness(): Awareness | null;
3315
+ /**
3316
+ * Build the deferred Awareness instance and bring it fully up to date:
3317
+ * seeded, wired, published, and caught up with the peers already present.
3318
+ */
3319
+ private _materializeAwareness;
3320
+ /**
3321
+ * Seed and wire an Awareness instance. Shared by the eager constructor path
3322
+ * and the lazy materialization path so the two cannot drift.
3323
+ */
3324
+ private _initAwareness;
3227
3325
  get hasUnsyncedChanges(): boolean;
3228
3326
  private resetUnsyncedChanges;
3229
3327
  incrementUnsyncedChanges(): void;
@@ -6386,4 +6484,207 @@ declare function collectMediaFileBlocks(root: Y.XmlFragment | Y.XmlElement): Med
6386
6484
  */
6387
6485
  declare function reconcileDocCover(treeMap: Y.Map<unknown>, docId: string, fragment: Y.XmlFragment | Y.XmlElement): void;
6388
6486
  //#endregion
6389
- export { AbracadabraBaseProvider, AbracadabraBaseProviderConfiguration, AbracadabraClient, AbracadabraClientConfig, AbracadabraOutgoingMessageArguments, AbracadabraProvider, AbracadabraProviderConfiguration, AbracadabraWS, AbracadabraWSConfiguration, AbracadabraWebRTC, type AbracadabraWebRTCConfiguration, AbracadabraWebSocketConn, AdminConfigField, AdminConfigOriginKind, AuditLogEntry, AuditQueryOpts, AuditVerifyResult, AuthFailureContext, AuthFailureReason, AuthMessageType, AuthorizedScope, AwarenessError, BackgroundSyncManager, type BackgroundSyncManagerOptions, BackgroundSyncPersistence, BroadcastChannelSync, CHANNEL_NAMES, ChannelKeyResolver, type ChatChannel, ChatClient, type ChatClientTransport, type MarkReadInput as ChatMarkReadInput, type ChatMessage, type ChatReadCursor, type ChatReadReceipt, type ChatTypingEvent, type ChildrenPage, CloseEvent, CompleteAbracadabraBaseProviderConfiguration, CompleteAbracadabraWSConfiguration, CompleteHocuspocusProviderConfiguration, CompleteHocuspocusProviderWebsocketConfiguration, type ConnectPolicyResult, ConnectionTimeout, Constructable, ConstructableOutgoingMessage, ContentManager, type CreateNotificationInput, CryptoIdentity, CryptoIdentityKeystore, DEFAULT_FILE_CHUNK_SIZE, DEFAULT_ICE_SERVERS, DataChannelRouter, type DeleteMessageInput, DevicePairingChannel, type DevicePairingConfig, DeviceRegistrationService, type DeviceServerStatus, type DeviceSessionRecord, type DeviceSessionStorage, type DeviceTier, DocBacklink, type DocEncryptionInfo, DocKeyManager, DocSearchHit, type DocSyncState, type DocSyncStatus, type DocumentBlock, DocumentCache, type DocumentCacheOptions, type DocumentContent, DocumentManager, type DocumentManagerConfig, DocumentMeta, type DocumentMetaInfo, type DocumentMetaWire, E2EAbracadabraProvider, E2EEChannel, type E2EEIdentity, E2EOfflineStore, type EditMessageInput, EffectivePermissionEntry, EffectivePermissionsResponse, EffectiveRole, EncryptedChatClient, EncryptedYMap, EncryptedYText, EnvSnapshotExtension, EnvSnapshotItem, EnvSnapshotResponse, type FetchInboxInput, type FetchNotificationsInput, FileBlobStore, FileTransferChannel, FileTransferHandle, type FileTransferMeta, type FileTransferStatus, type FoldedMessage, Forbidden, GEO_TYPE_META_SCHEMAS, type GetChatHistoryInput, HealthStatus, HocusPocusWebSocket, HocuspocusProvider, HocuspocusProviderConfiguration, HocuspocusProviderWebsocket, HocuspocusProviderWebsocketConfiguration, HocuspocusWebSocket, type IdentityDeviceEntry, type IdentityDocConfiguration, IdentityDocProvider, type IdentityProfile, type IdentityServerEntry, type IdentitySpaceEntry, type InboxEntry, type MarkReadInput$1 as InboxMarkReadInput, InviteRow, KEY_EXCHANGE_CHANNEL, type KeyAuthClient, Kind, type LoadKeyFileOptions, LocalStorageDeviceSessionStorage, type LoginOrRegisterOptions, ManualSignaling, type ManualSignalingBlob, type MediaFileBlock, type MessageRecord, MessageTooBig, MessageType, MetaFieldType, MetaManager, MetaValidationError, type NodeKeypair, type NotificationReadUpdate, type NotificationRecord, NotificationsClient, OfflineStore, OutgoingMessageArguments, OutgoingMessageInterface, PAGE_TYPES, PageMeta, PageTypeInfo, PageTypeMetaField, type PairingRequest, type PairingResult, PeerConnection, type PeerInfo, type PeerState, PendingSubdoc, PermissionEntry, type PolicyAuthClient, PublicKeyInfo, QUERY_PREFIX, QueryClient, QueryError, type QueryFrame, type QueryKind, type QuerySpec, type QuerySubscriptionHandle, type QuerySubscriptionHandlers, type QueryTransport, RPC_PREFIX, ReadyzStatus, ResetConnection, type RpcCallHandle, type RpcCallOptions, RpcClient, RpcError, type RpcErrorCode, type RpcErrorPayload, type RpcFrame, type RpcHandler, type RpcHandlerContext, type RpcKind, type RpcTarget, type RpcTransport, SERVER_ROOT_ID, type SchemaDocTypeName, type SchemaMetaOf, type SchemaRegistryLike, type SchemaValidatorLike, SearchIndex, SearchResult, type SendChatMessageInput, type SendMessageInput, type SendMessageResult, ServerInfo, type ServerProfile, type ServerRegistry, ServerResetOutcome, type SignalingIncoming, type SignalingOutgoing, SignalingSocket, SnapshotCreateResult, SnapshotData, SnapshotFileEntry, SnapshotForkResult, SnapshotMeta, SnapshotRestoreResult, StatesArray, StreamTokenInfo, SubdocMessage, SubdocRegisteredEvent, TYPE_ALIASES, ThumbnailOptions, TokenManager, type TokenManagerOptions, TreeEntry, TreeManager, TreeNode, TreeSearchResult, TypedDocTypeMismatchError, type TypedDocsClient, type TypedTreeEntry, Unauthorized, UploadInfo, UploadMeta, UploadQueueEntry, UploadQueueStatus, UserMetaField, UserProfile, WebSocketStatus, WriteRejectionKind, WsReadyStates, YjsDataChannel, addServer, attachUpdatedAtObserver, awarenessStatesToArray, wordlist as bip39Wordlist, buildBlockquoteElement, buildBlocksFromMarkdown, buildBulletListElement, buildCodeBlockElement, buildHeadingElement, buildHorizontalRuleElement, buildOrderedListElement, buildParagraphElement, buildTaskListElement, collectMediaFileBlocks, decryptChatContent, decryptField, defaultKeyFileFor, deriveDmDocId, deriveIdentityDocId, deriveSeedWrappingKey, deterministicKeypair, dropCachesIfServerReplaced, encryptChatContent, encryptField, filenameToLabel, foldRecords, forgetServerIdentity, generateMnemonic, isEncryptedContent, isPlaceholderLabel, isServerScopedStore, loadOrCreateKeyFile, loadServerRegistry, loginOrRegisterWithKey, loginOrRegisterWithPolicy, makeChallengeSigner, makeEncryptedYMap, makeEncryptedYText, makeEntryMap, migrateLegacyDefault, mnemonicToEd25519Seed, mnemonicToKeyPair, normalizeRootId, onAuthenticatedParameters, onAuthenticationFailedParameters, onAwarenessChangeParameters, onAwarenessUpdateParameters, onCloseParameters, onCompactedParameters, onDisconnectParameters, onMessageParameters, onOpenParameters, onOutgoingMessageParameters, onReconnectedParameters, onServerErrorParameters, onStatelessParameters, onStatusParameters, onSubdocLoadedParameters, onSubdocRegisteredParameters, onSyncedParameters, onUnsyncedChangesParameters, onWriteRejectedParameters, openSyncedProvider, parseFrontmatter, patchEntry, pickEntrySpace, populateYDocFromMarkdown, readAuthMessage, readBlocksFromFragment, readEntries, reconcileDocCover, recordFromYAny, removeServer, resolvePageType, resolveServer, saveServerRegistry, serverRegistryPath, setDefault, signChallengeWithSeed, toPlain, unwrapSeed, validateMnemonic, waitForSync, withTimeout, wrapSeed, writeAuthenticated, writeAuthentication, writePermissionDenied, writeTokenSyncRequest, yjsToMarkdown };
6487
+ //#region packages/provider/src/PerfCounters.d.ts
6488
+ /**
6489
+ * PerfCounters — opt-in resource accounting for the provider.
6490
+ *
6491
+ * WHY THIS EXISTS
6492
+ *
6493
+ * The provider's expensive behaviour is idle behaviour: timers that fire and
6494
+ * frames that go out when nobody is doing anything. That cost is invisible to
6495
+ * ordinary profiling of a busy app and invisible to the test suite, so it grew
6496
+ * unnoticed. This module makes it countable, so a budget can be asserted
6497
+ * instead of argued about.
6498
+ *
6499
+ * DESIGN CONSTRAINTS
6500
+ *
6501
+ * 1. **Inert until installed.** Importing this module patches nothing and
6502
+ * costs nothing. Only `installPerfCounters()` wraps anything, and
6503
+ * `uninstall()` restores the exact original references. Nothing in the
6504
+ * production path ever calls in here.
6505
+ *
6506
+ * 2. **Attribute by stack, don't instrument by hand.** Timers are the unit of
6507
+ * battery cost, and the ones that matter are created inside dependencies
6508
+ * (`y-protocols`' Awareness starts a 3 s interval per instance). Recording
6509
+ * a creation stack for every timer means we count the real cost wherever it
6510
+ * comes from — including timers added later by code that never heard of
6511
+ * this module — instead of sprinkling counter calls through the provider
6512
+ * and hoping they stay in sync with reality.
6513
+ *
6514
+ * 3. **No global socket patching.** In Node the provider runs on the `ws`
6515
+ * package, not `globalThis.WebSocket`, so a global patch would silently
6516
+ * measure nothing. `instrumentSocket()` takes an explicit AbracadabraWS
6517
+ * instead — the same approach `_perf_client.mts` already uses.
6518
+ *
6519
+ * Not covered here on purpose: `Y.encodeStateAsUpdate` cost. It cannot be
6520
+ * patched through an ES import binding, and the perf harness measures it
6521
+ * directly by calling it, which is more accurate anyway.
6522
+ */
6523
+ /** One group of timers sharing an origin and a delay. */
6524
+ interface TimerGroup {
6525
+ /** Best-effort source attribution, e.g. "y-protocols/awareness.js". */
6526
+ origin: string;
6527
+ /** The delay the timer was created with, in ms. */
6528
+ delayMs: number;
6529
+ /** Timers of this shape created since the last reset. */
6530
+ created: number;
6531
+ /** Timers of this shape still live right now. */
6532
+ live: number;
6533
+ /** Callback invocations of this shape since the last reset. */
6534
+ fired: number;
6535
+ }
6536
+ interface PerfSnapshot {
6537
+ /** Wall-clock ms since the last `reset()` (or install). */
6538
+ elapsedMs: number;
6539
+ timers: {
6540
+ intervalsCreated: number;
6541
+ intervalsLive: number;
6542
+ timeoutsCreated: number;
6543
+ timeoutsLive: number; /** Every callback invocation from a wrapped timer. */
6544
+ fired: number; /** Fired per second over the elapsed window — the battery number. */
6545
+ firedPerSecond: number; /** Grouped by origin + delay, largest `live` first. */
6546
+ groups: TimerGroup[];
6547
+ };
6548
+ animationFrames: {
6549
+ requested: number;
6550
+ fired: number;
6551
+ };
6552
+ awareness: {
6553
+ /**
6554
+ * Live `y-protocols` Awareness instances, derived from their
6555
+ * characteristic heartbeat interval (outdatedTimeout / 10 = 3000 ms
6556
+ * created inside awareness.js). This is the count the whole idle-cost
6557
+ * ledger hinges on.
6558
+ */
6559
+ liveInstances: number; /** Heartbeat callback invocations since the last reset. */
6560
+ heartbeatFires: number;
6561
+ };
6562
+ indexedDb: {
6563
+ transactions: number; /** Transactions by object-store name. */
6564
+ byStore: Record<string, number>;
6565
+ databasesOpened: number;
6566
+ };
6567
+ sockets: {
6568
+ framesSent: number;
6569
+ bytesSent: number;
6570
+ framesReceived: number;
6571
+ bytesReceived: number; /** Frames sent grouped by the wire message type byte, when readable. */
6572
+ sentByType: Record<string, number>;
6573
+ };
6574
+ }
6575
+ /** An AbracadabraWS-shaped object. Kept structural to avoid an import cycle. */
6576
+ interface SocketLike {
6577
+ send(message: unknown): void;
6578
+ on(event: string, handler: (...args: any[]) => void): unknown;
6579
+ off(event: string, handler: (...args: any[]) => void): unknown;
6580
+ }
6581
+ /**
6582
+ * Begin counting. Idempotent — a second call is a no-op rather than a
6583
+ * double-wrap, which would double every number and be very hard to notice.
6584
+ */
6585
+ declare function installPerfCounters(): void;
6586
+ /** Restore every patched global. Safe to call when not installed. */
6587
+ declare function uninstall(): void;
6588
+ /** Zero every counter. Live-timer bookkeeping is preserved — it is a census. */
6589
+ declare function reset(): void;
6590
+ /**
6591
+ * Count frames on one AbracadabraWS. Returns a restore function; the restore is
6592
+ * also run by `uninstall()`.
6593
+ *
6594
+ * Wrapping the instance (rather than a global) is deliberate: in Node the
6595
+ * provider runs on the `ws` package, so patching `globalThis.WebSocket` would
6596
+ * silently measure nothing at all.
6597
+ */
6598
+ declare function instrumentSocket(socket: SocketLike): () => void;
6599
+ declare function snapshot(): PerfSnapshot;
6600
+ /** Field-by-field difference of two snapshots, for before/after comparisons. */
6601
+ declare function diff(before: PerfSnapshot, after: PerfSnapshot): {
6602
+ elapsedMs: number;
6603
+ timersFired: number;
6604
+ intervalsCreated: number;
6605
+ intervalsLive: number;
6606
+ awarenessLive: number;
6607
+ heartbeatFires: number;
6608
+ framesSent: number;
6609
+ bytesSent: number;
6610
+ idbTransactions: number;
6611
+ };
6612
+ /** Whether counting is currently active. */
6613
+ declare function isInstalled(): boolean;
6614
+ //#endregion
6615
+ //#region packages/provider/src/LifecycleGate.d.ts
6616
+ /**
6617
+ * LifecycleGate — one place that knows whether the app is actually being looked at.
6618
+ *
6619
+ * Nothing in the provider used to ask. A grep for `visibilitychange` across the
6620
+ * package returned exactly one hit, in `TokenManager`, and it used the signal to
6621
+ * do MORE work on resume — nothing anywhere used it to do less. So a backgrounded
6622
+ * PWA kept its socket liveness checker running, kept re-running a full-tree
6623
+ * background sync every five minutes, and kept broadcasting presence, at exactly
6624
+ * the same rate as a phone held open in front of a person.
6625
+ *
6626
+ * Two design points that matter:
6627
+ *
6628
+ * 1. **The visibility source is injectable.** Hidden-state behaviour is the part
6629
+ * of this that most needs testing and is the hardest to reach from a test
6630
+ * runner, so `setSource()` lets a test drive it deterministically instead of
6631
+ * the tests having to fake a DOM.
6632
+ *
6633
+ * 2. **Hiding is debounced, revealing is not.** Alt-tabbing to look something up
6634
+ * is not "the user has gone away", and treating it as such would make presence
6635
+ * avatars flicker across everyone else's screen every time someone checked
6636
+ * their mail. Coming back is always immediate — a user who returns must never
6637
+ * wait on a timer to see live data.
6638
+ *
6639
+ * In Node, and anywhere else without a `document`, this is inert and reports
6640
+ * visible forever.
6641
+ */
6642
+ type VisibilityState = "visible" | "hidden";
6643
+ /** Something that can report visibility and notify on change. */
6644
+ interface VisibilitySource {
6645
+ /** Current state at the moment of the call. */
6646
+ get(): VisibilityState;
6647
+ /** Subscribe to changes. Returns an unsubscribe function. */
6648
+ subscribe(onChange: () => void): () => void;
6649
+ }
6650
+ /** How long the app must stay hidden before we act on it. */
6651
+ declare const HIDE_GRACE_MS = 10000;
6652
+ declare class LifecycleGate {
6653
+ private readonly graceMs;
6654
+ private source;
6655
+ private unsubscribe;
6656
+ private hideTimer;
6657
+ private _backgrounded;
6658
+ private listeners;
6659
+ constructor(source?: VisibilitySource, graceMs?: number);
6660
+ /**
6661
+ * True when the app has been hidden for longer than the grace period.
6662
+ *
6663
+ * Deliberately NOT the same as `document.hidden`: a tab that was hidden two
6664
+ * seconds ago is still, for our purposes, in use.
6665
+ */
6666
+ get backgrounded(): boolean;
6667
+ /** Subscribe to background/foreground transitions. Returns an unsubscribe fn. */
6668
+ onChange(listener: (backgrounded: boolean) => void): () => void;
6669
+ /** Swap the visibility source. Used by tests to drive state deterministically. */
6670
+ setSource(source: VisibilitySource): void;
6671
+ private onVisibilityChange;
6672
+ private setBackgrounded;
6673
+ destroy(): void;
6674
+ }
6675
+ declare function getLifecycleGate(): LifecycleGate;
6676
+ /**
6677
+ * Replace the shared gate. Tests use this to install a controllable source;
6678
+ * passing `null` restores the default browser-backed gate on next access.
6679
+ */
6680
+ declare function setLifecycleGate(gate: LifecycleGate | null): void;
6681
+ /** A visibility source a test (or an embedder) can drive by hand. */
6682
+ declare class ManualVisibilitySource implements VisibilitySource {
6683
+ private state;
6684
+ private listeners;
6685
+ get(): VisibilityState;
6686
+ subscribe(onChange: () => void): () => void;
6687
+ set(state: VisibilityState): void;
6688
+ }
6689
+ //#endregion
6690
+ export { AbracadabraBaseProvider, AbracadabraBaseProviderConfiguration, AbracadabraClient, AbracadabraClientConfig, AbracadabraOutgoingMessageArguments, AbracadabraProvider, AbracadabraProviderConfiguration, AbracadabraWS, AbracadabraWSConfiguration, AbracadabraWebRTC, type AbracadabraWebRTCConfiguration, AbracadabraWebSocketConn, AdminConfigField, AdminConfigOriginKind, AuditLogEntry, AuditQueryOpts, AuditVerifyResult, AuthFailureContext, AuthFailureReason, AuthMessageType, AuthorizedScope, AwarenessError, BackgroundSyncManager, type BackgroundSyncManagerOptions, BackgroundSyncPersistence, BroadcastChannelSync, CHANNEL_NAMES, ChannelKeyResolver, type ChatChannel, ChatClient, type ChatClientTransport, type MarkReadInput as ChatMarkReadInput, type ChatMessage, type ChatReadCursor, type ChatReadReceipt, type ChatTypingEvent, type ChildrenPage, CloseEvent, CompleteAbracadabraBaseProviderConfiguration, CompleteAbracadabraWSConfiguration, CompleteHocuspocusProviderConfiguration, CompleteHocuspocusProviderWebsocketConfiguration, type ConnectPolicyResult, ConnectionTimeout, Constructable, ConstructableOutgoingMessage, ContentManager, type CreateNotificationInput, CryptoIdentity, CryptoIdentityKeystore, DEFAULT_FILE_CHUNK_SIZE, DEFAULT_ICE_SERVERS, DataChannelRouter, type DeleteMessageInput, DevicePairingChannel, type DevicePairingConfig, DeviceRegistrationService, type DeviceServerStatus, type DeviceSessionRecord, type DeviceSessionStorage, type DeviceTier, DocBacklink, type DocEncryptionInfo, DocKeyManager, DocSearchHit, type DocSyncState, type DocSyncStatus, type DocumentBlock, DocumentCache, type DocumentCacheOptions, type DocumentContent, DocumentManager, type DocumentManagerConfig, DocumentMeta, type DocumentMetaInfo, type DocumentMetaWire, E2EAbracadabraProvider, E2EEChannel, type E2EEIdentity, E2EOfflineStore, type EditMessageInput, EffectivePermissionEntry, EffectivePermissionsResponse, EffectiveRole, EncryptedChatClient, EncryptedYMap, EncryptedYText, EnvSnapshotExtension, EnvSnapshotItem, EnvSnapshotResponse, type FetchInboxInput, type FetchNotificationsInput, FileBlobStore, FileTransferChannel, FileTransferHandle, type FileTransferMeta, type FileTransferStatus, type FoldedMessage, Forbidden, GEO_TYPE_META_SCHEMAS, type GetChatHistoryInput, HIDE_GRACE_MS, HealthStatus, HocusPocusWebSocket, HocuspocusProvider, HocuspocusProviderConfiguration, HocuspocusProviderWebsocket, HocuspocusProviderWebsocketConfiguration, HocuspocusWebSocket, type IdentityDeviceEntry, type IdentityDocConfiguration, IdentityDocProvider, type IdentityProfile, type IdentityServerEntry, type IdentitySpaceEntry, type InboxEntry, type MarkReadInput$1 as InboxMarkReadInput, InviteRow, KEY_EXCHANGE_CHANNEL, type KeyAuthClient, Kind, LifecycleGate, type LoadKeyFileOptions, LocalStorageDeviceSessionStorage, type LoginOrRegisterOptions, ManualSignaling, type ManualSignalingBlob, ManualVisibilitySource, type MediaFileBlock, type MessageRecord, MessageTooBig, MessageType, MetaFieldType, MetaManager, MetaValidationError, type NodeKeypair, type NotificationReadUpdate, type NotificationRecord, NotificationsClient, OfflineStore, OutgoingMessageArguments, OutgoingMessageInterface, PAGE_TYPES, PageMeta, PageTypeInfo, PageTypeMetaField, type PairingRequest, type PairingResult, PeerConnection, type PeerInfo, type PeerState, PendingSubdoc, type PerfSnapshot, PermissionEntry, type PolicyAuthClient, PublicKeyInfo, QUERY_PREFIX, QueryClient, QueryError, type QueryFrame, type QueryKind, type QuerySpec, type QuerySubscriptionHandle, type QuerySubscriptionHandlers, type QueryTransport, RPC_PREFIX, ReadyzStatus, ResetConnection, type RpcCallHandle, type RpcCallOptions, RpcClient, RpcError, type RpcErrorCode, type RpcErrorPayload, type RpcFrame, type RpcHandler, type RpcHandlerContext, type RpcKind, type RpcTarget, type RpcTransport, SERVER_ROOT_ID, type SchemaDocTypeName, type SchemaMetaOf, type SchemaRegistryLike, type SchemaValidatorLike, SearchIndex, SearchResult, type SendChatMessageInput, type SendMessageInput, type SendMessageResult, ServerInfo, type ServerProfile, type ServerRegistry, ServerResetOutcome, type SignalingIncoming, type SignalingOutgoing, SignalingSocket, SnapshotCreateResult, SnapshotData, SnapshotFileEntry, SnapshotForkResult, SnapshotMeta, SnapshotRestoreResult, StatesArray, StreamTokenInfo, SubdocMessage, SubdocRegisteredEvent, TYPE_ALIASES, ThumbnailOptions, type TimerGroup, TokenManager, type TokenManagerOptions, TreeEntry, TreeManager, TreeNode, TreeSearchResult, TypedDocTypeMismatchError, type TypedDocsClient, type TypedTreeEntry, Unauthorized, UploadInfo, UploadMeta, UploadQueueEntry, UploadQueueStatus, UserMetaField, UserProfile, type VisibilitySource, type VisibilityState, WebSocketStatus, WriteRejectionKind, WsReadyStates, YjsDataChannel, addServer, attachUpdatedAtObserver, awarenessStatesToArray, wordlist as bip39Wordlist, buildBlockquoteElement, buildBlocksFromMarkdown, buildBulletListElement, buildCodeBlockElement, buildHeadingElement, buildHorizontalRuleElement, buildOrderedListElement, buildParagraphElement, buildTaskListElement, collectMediaFileBlocks, decryptChatContent, decryptField, defaultKeyFileFor, deriveDmDocId, deriveIdentityDocId, deriveSeedWrappingKey, deterministicKeypair, dropCachesIfServerReplaced, encryptChatContent, encryptField, filenameToLabel, foldRecords, forgetServerIdentity, generateMnemonic, getLifecycleGate, installPerfCounters, isEncryptedContent, isPlaceholderLabel, isServerScopedStore, loadOrCreateKeyFile, loadServerRegistry, loginOrRegisterWithKey, loginOrRegisterWithPolicy, makeChallengeSigner, makeEncryptedYMap, makeEncryptedYText, makeEntryMap, migrateLegacyDefault, mnemonicToEd25519Seed, mnemonicToKeyPair, normalizeRootId, onAuthenticatedParameters, onAuthenticationFailedParameters, onAwarenessChangeParameters, onAwarenessUpdateParameters, onCloseParameters, onCompactedParameters, onDisconnectParameters, onMessageParameters, onOpenParameters, onOutgoingMessageParameters, onReconnectedParameters, onServerErrorParameters, onStatelessParameters, onStatusParameters, onSubdocLoadedParameters, onSubdocRegisteredParameters, onSyncedParameters, onUnsyncedChangesParameters, onWriteRejectedParameters, openSyncedProvider, parseFrontmatter, patchEntry, isInstalled as perfCountersInstalled, diff as perfDiff, instrumentSocket as perfInstrumentSocket, snapshot as perfSnapshot, pickEntrySpace, populateYDocFromMarkdown, readAuthMessage, readBlocksFromFragment, readEntries, reconcileDocCover, recordFromYAny, removeServer, reset as resetPerfCounters, resolvePageType, resolveServer, saveServerRegistry, serverRegistryPath, setDefault, setLifecycleGate, signChallengeWithSeed, toPlain, uninstall as uninstallPerfCounters, unwrapSeed, validateMnemonic, waitForSync, withTimeout, wrapSeed, writeAuthenticated, writeAuthentication, writePermissionDenied, writeTokenSyncRequest, yjsToMarkdown };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abraca/dabra",
3
- "version": "2.95.0",
3
+ "version": "2.96.0",
4
4
  "description": "abracadabra provider",
5
5
  "keywords": [
6
6
  "abracadabra",
@@ -35,7 +35,7 @@
35
35
  "yjs": "^13.6.8"
36
36
  },
37
37
  "devDependencies": {
38
- "@abraca/schema": "2.95.0"
38
+ "@abraca/schema": "2.96.0"
39
39
  },
40
40
  "scripts": {
41
41
  "test": "node --no-warnings --conditions=source --experimental-transform-types --test 'tests/*.test.ts'"