@arbidocs/client 0.5.59 → 0.5.60
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/README.md +10 -0
- package/dist/index.cjs +23 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +20 -1
- package/dist/index.d.ts +20 -1
- package/dist/index.js +22 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -40788,4 +40788,23 @@ declare function createAllWorkspacesOpener(deps: OpenAllDeps): () => Promise<voi
|
|
|
40788
40788
|
/** Per-client memory only: no browser globals, files or process-wide shared identity. */
|
|
40789
40789
|
declare function createMemorySessionPersistence(): SessionPersistence;
|
|
40790
40790
|
|
|
40791
|
-
|
|
40791
|
+
/**
|
|
40792
|
+
* One console logger for an ARBI frontend and its packages: errors always print; warnings, info
|
|
40793
|
+
* and debug lines print only when the host turns verbose logging on (in development, say:
|
|
40794
|
+
* `configureLogger({ verbose: import.meta.env.DEV })` at startup). The package never reads a
|
|
40795
|
+
* bundler's environment itself.
|
|
40796
|
+
*/
|
|
40797
|
+
interface LoggerOptions {
|
|
40798
|
+
/** Print `warn`, `info` and `debug` too. Off by default. */
|
|
40799
|
+
verbose: boolean;
|
|
40800
|
+
}
|
|
40801
|
+
declare function configureLogger(options: LoggerOptions): void;
|
|
40802
|
+
declare const logger: {
|
|
40803
|
+
/** Always printed, production included. */
|
|
40804
|
+
error: (...args: unknown[]) => void;
|
|
40805
|
+
warn: (...args: unknown[]) => void;
|
|
40806
|
+
info: (...args: unknown[]) => void;
|
|
40807
|
+
debug: (...args: unknown[]) => void;
|
|
40808
|
+
};
|
|
40809
|
+
|
|
40810
|
+
export { type $defs, ACCESS_TOKEN_STORAGE_KEY, API_PREFIX, type ArbiClient, type ArbiClientOptions, type AuthStateProvider, type AutoReloginMiddlewareConfig, type BearerAuthMiddlewareConfig, CALL_KEY_BYTES, CHAT_KEY_BYTES, type CallPeer, type ChangePasswordParams, type ChangePasswordRequest, type ChangePasswordResult, type CryptoProvider, type DisconnectSsoParams, ENCRYPTED_RECOVERY_KEY_SIZE, type HttpErrorInfo, type HttpRequestInfo, type HttpResponseInfo, type HttpTransport, type HttpTransportOptions, type KeyLoginCredentials, type KeyPair, type ListedWorkspaceKey, type LoggerOptions, type LoginCredentials, type LoginParams, type LoginProfile, type LoginProvider, type LoginRequest, type LoginResponse, type LoginResult, type LoginWithKeyParams, type OfflineSealer, type OfflineSealerOptions, type OnReloginSuccess, type OpenAllDeps, type ParsedRecoveryUrl, type PasswordChangeCredentials, RECOVERY_KEY_ERRORS, type RecoveryKeyParams, type RecoveryKeyValidationResult, type RegisterParams, type RegisterRequest, type RegisterResult, type RegistrationCredentials, type ReloginDeps, type ReloginFailure, type ReloginHandler, type ReopenDeps, SECURE_MAIL_KEY_BYTES, type SealedSecureMail, type SecureMailCiphertexts, type SecureMailClaim, type SessionClaims, type SessionData, type SessionKeys, type SessionManager, type SessionManagerOptions, type SessionPersistence, type SessionSignIn, type SessionState, type SessionStateStorage, type SessionUser, type SignInHooks, type SsoTokenSource, type StoredSessionState, type TokenProvider, UNENCRYPTED_RECOVERY_KEY_SIZE, type UserKeypairs, type WebSocketClientMessage, type WebSocketServerMessage, type WorkspaceKeyRefreshProvider, type WorkspaceKeys, type WorkspaceOpenProvider, type WorkspaceOpens, type WsAgentDmStatusMessage, type WsAuthMessage, type WsAuthResultMessage, type WsBatchCompleteMessage, type WsChatMessageMessage, type WsChatReadMessage, type WsChatUpdatedMessage, type WsConnectionClosedMessage, type WsConversationMessagePostedMessage, type WsErrorMessage, type WsNotificationResponse, type WsPresenceUpdateMessage, type WsResponseCompleteMessage, type WsTaskUpdateMessage, authRequestError, base64Decode, base64Encode, base64ToBytes, base64UrlToBytes, browserSessionStateStorage, buildCallFragment, buildCallLink, buildWebSocketUrl, bytesToBase64, bytesToBase64Url, canPersistSession, changePassword, clearAllData, clearSession, type components, computeSharedSecret, configureLogger, createAllWorkspacesOpener, createArbiClient, createAuthMessage, createAutoReloginMiddleware, createBearerAuthMiddleware, createContentHash, createHttpTransport, createMemorySessionPersistence, createOfflineSealer, createRecoveryFile, createRecoveryUrl, createReloginHandler, createSessionManager, createWorkspaceKeys, createWorkspaceOpens, createWorkspaceReopener, decodeCallKey, decodeSecureMailKey, decryptCallTitle, decryptFile, decryptMessage, decryptMessageWithSharedSecret, decryptRecoveryKey, decryptWithChatKey, deriveDirectChatKey, deriveEncryptionKeypairFromSigning, derivePublicKey, disconnectSso, encodeCallKey, encryptCallTitle, encryptFile, encryptMessage, encryptMessageWithSharedSecret, encryptRecoveryKey, encryptWithChatKey, encryptionKeypairFromSigningKey, generateCallKey, generateChatKey, generateIdentityKeypair, generateKeyPairs, generateLoginCredentials, generateLoginCredentialsFromKey, generatePasswordChangeCredentials, generateRandomSigningKeypair, generateRegistrationCredentials, generateUserKeypairs, getRecoveryKeyFilename, getSession, getUserEncryptionKeypair, hasSession, identityFromLoginResponse, initSodium, initializeDatabase, isAbortError, isEncryptedRecoveryKey, isMessageType, logger, openCallKeyOf, openSealedCallKey, openSealedChatKey, openSecureMail, type operations, parseCallFragment, parseRecoveryUrl, parseServerMessage, passwordChangeErrorMessage, type paths, prewarmKeyPairs, readSessionClaims, requestSsoDisconnectCode, saveSession, sealCallKey, sealCallKeyForPeers, sealChatKey, sealKeyForSession, sealSecureMail, sealedBoxDecrypt, sealedBoxEncrypt, secureMailClaim, signMessage, unlockIdentityWithPassword, unwrapIdentityKey, unwrapWorkspaceKey, updateWrappedIdentityKey, validateRecoveryKeyFile, type webhooks, workspaceKeyRequiredOf, wrapIdentityKey };
|
package/dist/index.d.ts
CHANGED
|
@@ -40788,4 +40788,23 @@ declare function createAllWorkspacesOpener(deps: OpenAllDeps): () => Promise<voi
|
|
|
40788
40788
|
/** Per-client memory only: no browser globals, files or process-wide shared identity. */
|
|
40789
40789
|
declare function createMemorySessionPersistence(): SessionPersistence;
|
|
40790
40790
|
|
|
40791
|
-
|
|
40791
|
+
/**
|
|
40792
|
+
* One console logger for an ARBI frontend and its packages: errors always print; warnings, info
|
|
40793
|
+
* and debug lines print only when the host turns verbose logging on (in development, say:
|
|
40794
|
+
* `configureLogger({ verbose: import.meta.env.DEV })` at startup). The package never reads a
|
|
40795
|
+
* bundler's environment itself.
|
|
40796
|
+
*/
|
|
40797
|
+
interface LoggerOptions {
|
|
40798
|
+
/** Print `warn`, `info` and `debug` too. Off by default. */
|
|
40799
|
+
verbose: boolean;
|
|
40800
|
+
}
|
|
40801
|
+
declare function configureLogger(options: LoggerOptions): void;
|
|
40802
|
+
declare const logger: {
|
|
40803
|
+
/** Always printed, production included. */
|
|
40804
|
+
error: (...args: unknown[]) => void;
|
|
40805
|
+
warn: (...args: unknown[]) => void;
|
|
40806
|
+
info: (...args: unknown[]) => void;
|
|
40807
|
+
debug: (...args: unknown[]) => void;
|
|
40808
|
+
};
|
|
40809
|
+
|
|
40810
|
+
export { type $defs, ACCESS_TOKEN_STORAGE_KEY, API_PREFIX, type ArbiClient, type ArbiClientOptions, type AuthStateProvider, type AutoReloginMiddlewareConfig, type BearerAuthMiddlewareConfig, CALL_KEY_BYTES, CHAT_KEY_BYTES, type CallPeer, type ChangePasswordParams, type ChangePasswordRequest, type ChangePasswordResult, type CryptoProvider, type DisconnectSsoParams, ENCRYPTED_RECOVERY_KEY_SIZE, type HttpErrorInfo, type HttpRequestInfo, type HttpResponseInfo, type HttpTransport, type HttpTransportOptions, type KeyLoginCredentials, type KeyPair, type ListedWorkspaceKey, type LoggerOptions, type LoginCredentials, type LoginParams, type LoginProfile, type LoginProvider, type LoginRequest, type LoginResponse, type LoginResult, type LoginWithKeyParams, type OfflineSealer, type OfflineSealerOptions, type OnReloginSuccess, type OpenAllDeps, type ParsedRecoveryUrl, type PasswordChangeCredentials, RECOVERY_KEY_ERRORS, type RecoveryKeyParams, type RecoveryKeyValidationResult, type RegisterParams, type RegisterRequest, type RegisterResult, type RegistrationCredentials, type ReloginDeps, type ReloginFailure, type ReloginHandler, type ReopenDeps, SECURE_MAIL_KEY_BYTES, type SealedSecureMail, type SecureMailCiphertexts, type SecureMailClaim, type SessionClaims, type SessionData, type SessionKeys, type SessionManager, type SessionManagerOptions, type SessionPersistence, type SessionSignIn, type SessionState, type SessionStateStorage, type SessionUser, type SignInHooks, type SsoTokenSource, type StoredSessionState, type TokenProvider, UNENCRYPTED_RECOVERY_KEY_SIZE, type UserKeypairs, type WebSocketClientMessage, type WebSocketServerMessage, type WorkspaceKeyRefreshProvider, type WorkspaceKeys, type WorkspaceOpenProvider, type WorkspaceOpens, type WsAgentDmStatusMessage, type WsAuthMessage, type WsAuthResultMessage, type WsBatchCompleteMessage, type WsChatMessageMessage, type WsChatReadMessage, type WsChatUpdatedMessage, type WsConnectionClosedMessage, type WsConversationMessagePostedMessage, type WsErrorMessage, type WsNotificationResponse, type WsPresenceUpdateMessage, type WsResponseCompleteMessage, type WsTaskUpdateMessage, authRequestError, base64Decode, base64Encode, base64ToBytes, base64UrlToBytes, browserSessionStateStorage, buildCallFragment, buildCallLink, buildWebSocketUrl, bytesToBase64, bytesToBase64Url, canPersistSession, changePassword, clearAllData, clearSession, type components, computeSharedSecret, configureLogger, createAllWorkspacesOpener, createArbiClient, createAuthMessage, createAutoReloginMiddleware, createBearerAuthMiddleware, createContentHash, createHttpTransport, createMemorySessionPersistence, createOfflineSealer, createRecoveryFile, createRecoveryUrl, createReloginHandler, createSessionManager, createWorkspaceKeys, createWorkspaceOpens, createWorkspaceReopener, decodeCallKey, decodeSecureMailKey, decryptCallTitle, decryptFile, decryptMessage, decryptMessageWithSharedSecret, decryptRecoveryKey, decryptWithChatKey, deriveDirectChatKey, deriveEncryptionKeypairFromSigning, derivePublicKey, disconnectSso, encodeCallKey, encryptCallTitle, encryptFile, encryptMessage, encryptMessageWithSharedSecret, encryptRecoveryKey, encryptWithChatKey, encryptionKeypairFromSigningKey, generateCallKey, generateChatKey, generateIdentityKeypair, generateKeyPairs, generateLoginCredentials, generateLoginCredentialsFromKey, generatePasswordChangeCredentials, generateRandomSigningKeypair, generateRegistrationCredentials, generateUserKeypairs, getRecoveryKeyFilename, getSession, getUserEncryptionKeypair, hasSession, identityFromLoginResponse, initSodium, initializeDatabase, isAbortError, isEncryptedRecoveryKey, isMessageType, logger, openCallKeyOf, openSealedCallKey, openSealedChatKey, openSecureMail, type operations, parseCallFragment, parseRecoveryUrl, parseServerMessage, passwordChangeErrorMessage, type paths, prewarmKeyPairs, readSessionClaims, requestSsoDisconnectCode, saveSession, sealCallKey, sealCallKeyForPeers, sealChatKey, sealKeyForSession, sealSecureMail, sealedBoxDecrypt, sealedBoxEncrypt, secureMailClaim, signMessage, unlockIdentityWithPassword, unwrapIdentityKey, unwrapWorkspaceKey, updateWrappedIdentityKey, validateRecoveryKeyFile, type webhooks, workspaceKeyRequiredOf, wrapIdentityKey };
|
package/dist/index.js
CHANGED
|
@@ -2399,6 +2399,27 @@ function isMessageType(msg, type) {
|
|
|
2399
2399
|
return msg.type === type;
|
|
2400
2400
|
}
|
|
2401
2401
|
|
|
2402
|
-
|
|
2402
|
+
// src/logger.ts
|
|
2403
|
+
var verbose = false;
|
|
2404
|
+
function configureLogger(options) {
|
|
2405
|
+
verbose = options.verbose;
|
|
2406
|
+
}
|
|
2407
|
+
var logger = {
|
|
2408
|
+
/** Always printed, production included. */
|
|
2409
|
+
error: (...args) => {
|
|
2410
|
+
console.error(...args);
|
|
2411
|
+
},
|
|
2412
|
+
warn: (...args) => {
|
|
2413
|
+
if (verbose) console.warn(...args);
|
|
2414
|
+
},
|
|
2415
|
+
info: (...args) => {
|
|
2416
|
+
if (verbose) console.info(...args);
|
|
2417
|
+
},
|
|
2418
|
+
debug: (...args) => {
|
|
2419
|
+
if (verbose) console.debug(...args);
|
|
2420
|
+
}
|
|
2421
|
+
};
|
|
2422
|
+
|
|
2423
|
+
export { ACCESS_TOKEN_STORAGE_KEY, API_PREFIX, CALL_KEY_BYTES, CHAT_KEY_BYTES, ENCRYPTED_RECOVERY_KEY_SIZE, RECOVERY_KEY_ERRORS, SECURE_MAIL_KEY_BYTES, UNENCRYPTED_RECOVERY_KEY_SIZE, authRequestError, base64Decode, base64Encode, base64ToBytes, base64UrlToBytes, browserSessionStateStorage, buildCallFragment, buildCallLink, buildWebSocketUrl, bytesToBase64, bytesToBase64Url, canPersistSession, changePassword, clearAllData, clearSession, computeSharedSecret, configureLogger, createAllWorkspacesOpener, createArbiClient, createAuthMessage, createAutoReloginMiddleware, createBearerAuthMiddleware, createContentHash, createHttpTransport, createMemorySessionPersistence, createOfflineSealer, createRecoveryFile, createRecoveryUrl, createReloginHandler, createSessionManager, createWorkspaceKeys, createWorkspaceOpens, createWorkspaceReopener, decodeCallKey, decodeSecureMailKey, decryptCallTitle, decryptFile, decryptMessage, decryptMessageWithSharedSecret, decryptRecoveryKey, decryptWithChatKey, deriveDirectChatKey, deriveEncryptionKeypairFromSigning, derivePublicKey, disconnectSso, encodeCallKey, encryptCallTitle, encryptFile, encryptMessage, encryptMessageWithSharedSecret, encryptRecoveryKey, encryptWithChatKey, encryptionKeypairFromSigningKey, generateCallKey, generateChatKey, generateIdentityKeypair, generateKeyPairs, generateLoginCredentials, generateLoginCredentialsFromKey, generatePasswordChangeCredentials, generateRandomSigningKeypair, generateRegistrationCredentials, generateUserKeypairs, getRecoveryKeyFilename, getSession, getUserEncryptionKeypair, hasSession, identityFromLoginResponse, initSodium, initializeDatabase, isAbortError, isEncryptedRecoveryKey, isMessageType, logger, openCallKeyOf, openSealedCallKey, openSealedChatKey, openSecureMail, parseCallFragment, parseRecoveryUrl, parseServerMessage, passwordChangeErrorMessage, prewarmKeyPairs, readSessionClaims, requestSsoDisconnectCode, saveSession, sealCallKey, sealCallKeyForPeers, sealChatKey, sealKeyForSession, sealSecureMail, sealedBoxDecrypt, sealedBoxEncrypt, secureMailClaim, signMessage, unlockIdentityWithPassword, unwrapIdentityKey, unwrapWorkspaceKey, updateWrappedIdentityKey, validateRecoveryKeyFile, workspaceKeyRequiredOf, wrapIdentityKey };
|
|
2403
2424
|
//# sourceMappingURL=index.js.map
|
|
2404
2425
|
//# sourceMappingURL=index.js.map
|