mindoodb-app-sdk 0.0.31 → 0.0.33

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
@@ -1,5 +1,5 @@
1
- import { M as MindooDBAppAttachmentPreviewMode, a as MindooDBAppBridge, b as MindooDBAppDatabase, c as MindooDBAppDocument, d as MindooDBAppRichTextSpan, e as MindooDBAppRichTextSnapshot } from './types-B2lo8s7H.js';
2
- export { f as MindooDBAppAccessDecision, g as MindooDBAppAccessTier, h as MindooDBAppAttachmentApi, i as MindooDBAppAttachmentChunk, j as MindooDBAppAttachmentInfo, k as MindooDBAppAttachmentPreviewOptions, l as MindooDBAppAttachmentPreviewSession, m as MindooDBAppAutomergeChangesPatch, n as MindooDBAppAutomergeChangesSince, o as MindooDBAppAutomergeGetOptions, p as MindooDBAppAutomergePatchResult, q as MindooDBAppAutomergeSnapshot, r as MindooDBAppBridgeConnectMessage, s as MindooDBAppBridgeConnectOptions, t as MindooDBAppBridgeConnectedMessage, u as MindooDBAppBridgeErrorPayload, v as MindooDBAppBridgeHandshakeErrorMessage, w as MindooDBAppBridgeLocaleChangedMessage, x as MindooDBAppBridgePortMessage, y as MindooDBAppBridgeQueryResultMessage, z as MindooDBAppBridgeRpcError, A as MindooDBAppBridgeRpcMessage, B as MindooDBAppBridgeRpcRequest, C as MindooDBAppBridgeRpcSuccess, D as MindooDBAppBridgeStreamAbortRequest, E as MindooDBAppBridgeStreamAck, F as MindooDBAppBridgeStreamCloseRequest, G as MindooDBAppBridgeStreamError, H as MindooDBAppBridgeStreamMessage, I as MindooDBAppBridgeStreamOpenResult, J as MindooDBAppBridgeStreamReadRequest, K as MindooDBAppBridgeStreamWriteRequest, L as MindooDBAppBridgeThemeChangedMessage, N as MindooDBAppBridgeUiPreferencesChangedMessage, O as MindooDBAppBridgeViewChangedMessage, P as MindooDBAppBridgeViewportChangedMessage, Q as MindooDBAppCapability, R as MindooDBAppConfiguredViewCategorizationStyle, S as MindooDBAppConfiguredViewColumn, T as MindooDBAppConfiguredViewColumnRole, U as MindooDBAppConfiguredViewExpressionMode, V as MindooDBAppConfiguredViewFieldExpression, W as MindooDBAppConfiguredViewFilterDefinition, X as MindooDBAppConfiguredViewFilterMode, Y as MindooDBAppConfiguredViewFilterRule, Z as MindooDBAppConfiguredViewFormulaExpression, _ as MindooDBAppConfiguredViewFormulaFilterDefinition, $ as MindooDBAppConfiguredViewPreviewMode, a0 as MindooDBAppConfiguredViewRuleFilterDefinition, a1 as MindooDBAppConfiguredViewRuleMatchMode, a2 as MindooDBAppConfiguredViewRuleOperator, a3 as MindooDBAppConfiguredViewValueExpression, a4 as MindooDBAppCreateDocumentInput, a5 as MindooDBAppCreateViewInput, a6 as MindooDBAppCreateViewNavigatorInput, a7 as MindooDBAppDatabaseInfo, a8 as MindooDBAppDocumentApi, a9 as MindooDBAppDocumentHeadCursorResult, aa as MindooDBAppDocumentHistoryEntry, ab as MindooDBAppDocumentListQuery, ac as MindooDBAppDocumentListResult, ad as MindooDBAppDocumentQuery, ae as MindooDBAppDocumentRevisionId, af as MindooDBAppDocumentScanPreset, ag as MindooDBAppDocumentSummary, ah as MindooDBAppExtractionSetup, ai as MindooDBAppFulltextSetup, aj as MindooDBAppHistoricalDocument, ak as MindooDBAppHistoryQuery, al as MindooDBAppHostTheme, am as MindooDBAppJsonListDeletePatch, an as MindooDBAppJsonListInsertPatch, ao as MindooDBAppJsonPatch, ap as MindooDBAppJsonSetPatch, aq as MindooDBAppJsonTextMarkPatch, ar as MindooDBAppJsonTextSplicePatch, as as MindooDBAppJsonTextUnmarkPatch, at as MindooDBAppJsonUnsetPatch, au as MindooDBAppLaunchContext, av as MindooDBAppLiveQuerySubscription, aw as MindooDBAppMenuAnchor, ax as MindooDBAppMenuApi, ay as MindooDBAppMenuCommandItem, az as MindooDBAppMenuDismissReason, aA as MindooDBAppMenuDismissedResult, aB as MindooDBAppMenuItem, aC as MindooDBAppMenuKind, aD as MindooDBAppMenuPlacement, aE as MindooDBAppMenuPointAnchor, aF as MindooDBAppMenuRect, aG as MindooDBAppMenuRectAnchor, aH as MindooDBAppMenuSelectionResult, aI as MindooDBAppMenuSeparatorItem, aJ as MindooDBAppQueryCoverage, aK as MindooDBAppQueryResult, aL as MindooDBAppQueryRow, aM as MindooDBAppQuerySortKey, aN as MindooDBAppQueryTextClause, aO as MindooDBAppReadableAttachmentStream, aP as MindooDBAppResolvedViewDefinition, aQ as MindooDBAppResolvedViewSource, aR as MindooDBAppRichTextBlockSpan, aS as MindooDBAppRichTextGetOptions, aT as MindooDBAppRichTextImmutableString, aU as MindooDBAppRichTextMarkRange, aV as MindooDBAppRichTextMaterializeValue, aW as MindooDBAppRichTextPatch, aX as MindooDBAppRichTextScalar, aY as MindooDBAppRichTextSpliceStep, aZ as MindooDBAppRichTextStep, a_ as MindooDBAppRichTextStepPatch, a$ as MindooDBAppRichTextTextSpan, b0 as MindooDBAppRuntime, b1 as MindooDBAppScanAttachmentOptions, b2 as MindooDBAppScanAttachmentResult, b3 as MindooDBAppScopedDocId, b4 as MindooDBAppScopedDocumentSummary, b5 as MindooDBAppSession, b6 as MindooDBAppShowMenuInput, b7 as MindooDBAppShowMenuResult, b8 as MindooDBAppTextEdit, b9 as MindooDBAppTextPatch, ba as MindooDBAppThemeMode, bb as MindooDBAppUiPreferences, bc as MindooDBAppUpdateDocumentInput, bd as MindooDBAppViewCursorDocumentListResult, be as MindooDBAppViewCursorResult, bf as MindooDBAppViewEntry, bg as MindooDBAppViewEntryKind, bh as MindooDBAppViewNavigator, bi as MindooDBAppViewNavigatorExpansionState, bj as MindooDBAppViewNavigatorOpenOptions, bk as MindooDBAppViewNavigatorPageOptions, bl as MindooDBAppViewNavigatorPageResult, bm as MindooDBAppViewNavigatorRangeQuery, bn as MindooDBAppViewNavigatorSelectionState, bo as MindooDBAppViewUpdateStats, bp as MindooDBAppViewport, bq as MindooDBAppWritableAttachmentStream } from './types-B2lo8s7H.js';
1
+ import { M as MindooDBAppAttachmentPreviewMode, a as MindooDBAppBridge, b as MindooDBAppDatabase, c as MindooDBAppDocument, d as MindooDBAppRichTextSpan, e as MindooDBAppRichTextSnapshot } from './types-c6uTlJnB.js';
2
+ export { f as MINDOODB_APP_SEAL_SIGNING_DOMAIN, g as MindooDBAppAccessDecision, h as MindooDBAppAccessTier, i as MindooDBAppAttachmentApi, j as MindooDBAppAttachmentChunk, k as MindooDBAppAttachmentInfo, l as MindooDBAppAttachmentPreviewOptions, m as MindooDBAppAttachmentPreviewSession, n as MindooDBAppAutomergeChangesPatch, o as MindooDBAppAutomergeChangesSince, p as MindooDBAppAutomergeGetOptions, q as MindooDBAppAutomergePatchResult, r as MindooDBAppAutomergeSnapshot, s as MindooDBAppBridgeConnectMessage, t as MindooDBAppBridgeConnectOptions, u as MindooDBAppBridgeConnectedMessage, v as MindooDBAppBridgeErrorPayload, w as MindooDBAppBridgeHandshakeErrorMessage, x as MindooDBAppBridgeLocaleChangedMessage, y as MindooDBAppBridgePortMessage, z as MindooDBAppBridgeQueryResultMessage, A as MindooDBAppBridgeRpcError, B as MindooDBAppBridgeRpcMessage, C as MindooDBAppBridgeRpcRequest, D as MindooDBAppBridgeRpcSuccess, E as MindooDBAppBridgeStreamAbortRequest, F as MindooDBAppBridgeStreamAck, G as MindooDBAppBridgeStreamCloseRequest, H as MindooDBAppBridgeStreamError, I as MindooDBAppBridgeStreamMessage, J as MindooDBAppBridgeStreamOpenResult, K as MindooDBAppBridgeStreamReadRequest, L as MindooDBAppBridgeStreamWriteRequest, N as MindooDBAppBridgeThemeChangedMessage, O as MindooDBAppBridgeUiPreferencesChangedMessage, P as MindooDBAppBridgeViewChangedMessage, Q as MindooDBAppBridgeViewportChangedMessage, R as MindooDBAppCapability, S as MindooDBAppConfiguredViewCategorizationStyle, T as MindooDBAppConfiguredViewColumn, U as MindooDBAppConfiguredViewColumnRole, V as MindooDBAppConfiguredViewExpressionMode, W as MindooDBAppConfiguredViewFieldExpression, X as MindooDBAppConfiguredViewFilterDefinition, Y as MindooDBAppConfiguredViewFilterMode, Z as MindooDBAppConfiguredViewFilterRule, _ as MindooDBAppConfiguredViewFormulaExpression, $ as MindooDBAppConfiguredViewFormulaFilterDefinition, a0 as MindooDBAppConfiguredViewPreviewMode, a1 as MindooDBAppConfiguredViewRuleFilterDefinition, a2 as MindooDBAppConfiguredViewRuleMatchMode, a3 as MindooDBAppConfiguredViewRuleOperator, a4 as MindooDBAppConfiguredViewValueExpression, a5 as MindooDBAppCreateDocumentInput, a6 as MindooDBAppCreateViewInput, a7 as MindooDBAppCreateViewNavigatorInput, a8 as MindooDBAppDatabaseInfo, a9 as MindooDBAppDirectoryApi, aa as MindooDBAppDirectoryEntry, ab as MindooDBAppDocumentApi, ac as MindooDBAppDocumentHeadCursorResult, ad as MindooDBAppDocumentHistoryEntry, ae as MindooDBAppDocumentListQuery, af as MindooDBAppDocumentListResult, ag as MindooDBAppDocumentQuery, ah as MindooDBAppDocumentRevisionId, ai as MindooDBAppDocumentScanPreset, aj as MindooDBAppDocumentSummary, ak as MindooDBAppEntryAttachmentRef, al as MindooDBAppEntryProvenance, am as MindooDBAppExtractionSetup, an as MindooDBAppFulltextSetup, ao as MindooDBAppHistoricalDocument, ap as MindooDBAppHistoryQuery, aq as MindooDBAppHostTheme, ar as MindooDBAppIdentityApi, as as MindooDBAppJsonListDeletePatch, at as MindooDBAppJsonListInsertPatch, au as MindooDBAppJsonPatch, av as MindooDBAppJsonSetPatch, aw as MindooDBAppJsonTextMarkPatch, ax as MindooDBAppJsonTextSplicePatch, ay as MindooDBAppJsonTextUnmarkPatch, az as MindooDBAppJsonUnsetPatch, aA as MindooDBAppLaunchContext, aB as MindooDBAppLiveQuerySubscription, aC as MindooDBAppMenuAnchor, aD as MindooDBAppMenuApi, aE as MindooDBAppMenuCommandItem, aF as MindooDBAppMenuDismissReason, aG as MindooDBAppMenuDismissedResult, aH as MindooDBAppMenuItem, aI as MindooDBAppMenuKind, aJ as MindooDBAppMenuPlacement, aK as MindooDBAppMenuPointAnchor, aL as MindooDBAppMenuRect, aM as MindooDBAppMenuRectAnchor, aN as MindooDBAppMenuSelectionResult, aO as MindooDBAppMenuSeparatorItem, aP as MindooDBAppQueryCoverage, aQ as MindooDBAppQueryResult, aR as MindooDBAppQueryRow, aS as MindooDBAppQuerySortKey, aT as MindooDBAppQueryTextClause, aU as MindooDBAppReadableAttachmentStream, aV as MindooDBAppResolvedViewDefinition, aW as MindooDBAppResolvedViewSource, aX as MindooDBAppRevisionVerification, aY as MindooDBAppRichTextBlockSpan, aZ as MindooDBAppRichTextGetOptions, a_ as MindooDBAppRichTextImmutableString, a$ as MindooDBAppRichTextMarkRange, b0 as MindooDBAppRichTextMaterializeValue, b1 as MindooDBAppRichTextPatch, b2 as MindooDBAppRichTextScalar, b3 as MindooDBAppRichTextSpliceStep, b4 as MindooDBAppRichTextStep, b5 as MindooDBAppRichTextStepPatch, b6 as MindooDBAppRichTextTextSpan, b7 as MindooDBAppRuntime, b8 as MindooDBAppScanAttachmentOptions, b9 as MindooDBAppScanAttachmentResult, ba as MindooDBAppScopedDocId, bb as MindooDBAppScopedDocumentSummary, bc as MindooDBAppSealIntent, bd as MindooDBAppSession, be as MindooDBAppShowMenuInput, bf as MindooDBAppShowMenuResult, bg as MindooDBAppSignPreview, bh as MindooDBAppSignPreviewScope, bi as MindooDBAppSignStatementInput, bj as MindooDBAppSignStatementResult, bk as MindooDBAppTextEdit, bl as MindooDBAppTextPatch, bm as MindooDBAppThemeMode, bn as MindooDBAppTimestampApi, bo as MindooDBAppTimestampInput, bp as MindooDBAppTimestampProvider, bq as MindooDBAppTimestampResult, br as MindooDBAppUiPreferences, bs as MindooDBAppUpdateDocumentInput, bt as MindooDBAppViewCursorDocumentListResult, bu as MindooDBAppViewCursorResult, bv as MindooDBAppViewEntry, bw as MindooDBAppViewEntryKind, bx as MindooDBAppViewNavigator, by as MindooDBAppViewNavigatorExpansionState, bz as MindooDBAppViewNavigatorOpenOptions, bA as MindooDBAppViewNavigatorPageOptions, bB as MindooDBAppViewNavigatorPageResult, bC as MindooDBAppViewNavigatorRangeQuery, bD as MindooDBAppViewNavigatorSelectionState, bE as MindooDBAppViewUpdateStats, bF as MindooDBAppViewport, bG as MindooDBAppWritableAttachmentStream } from './types-c6uTlJnB.js';
3
3
  import { MindooDBAppBooleanExpression } from 'mindoodb-view-language';
4
4
  export { MindooDBAppBooleanExpression, MindooDBAppExpression, MindooDBAppFilterDefinition, MindooDBAppViewCategoryChildrenPageRequest, MindooDBAppViewColumn, MindooDBAppViewColumnRole, MindooDBAppViewDefinition, MindooDBAppViewExpansionState, MindooDBAppViewExpressionBase, MindooDBAppViewExpressionDatePart, MindooDBAppViewExpressionOperation, MindooDBAppViewFieldExpression, MindooDBAppViewIfExpression, MindooDBAppViewLetExpression, MindooDBAppViewLiteralExpression, MindooDBAppViewLookupByPath, MindooDBAppViewOperationExpression, MindooDBAppViewOriginExpression, MindooDBAppViewPageRequest, MindooDBAppViewPageResult, MindooDBAppViewRow, MindooDBAppViewSortDirection, MindooDBAppViewTotalMode, MindooDBAppViewValueExpressionRef, MindooDBAppViewVariableExpression, createViewLanguage } from 'mindoodb-view-language';
5
5
  import { MindooDB, MindooQuerySortKey, MindooQueryOptions, MindooQueryResult } from 'mindoodb';
package/dist/index.js CHANGED
@@ -1,3 +1,6 @@
1
+ // src/types.ts
2
+ var MINDOODB_APP_SEAL_SIGNING_DOMAIN = "mindoodb-seal/v1";
3
+
1
4
  // src/attachmentPreview.ts
2
5
  function canPreviewAttachment(fileName, mimeType) {
3
6
  const normalizedMimeType = mimeType.toLowerCase();
@@ -911,6 +914,32 @@ var MindooDBAppDatabaseImpl = class {
911
914
  databaseId: this.databaseId,
912
915
  docId,
913
916
  revisionId
917
+ }),
918
+ listVerification: async (docId, revisionIds) => await this.rpc.call("documents.history.listVerification", {
919
+ databaseId: this.databaseId,
920
+ docId,
921
+ revisionIds
922
+ })
923
+ };
924
+ this.identity = {
925
+ signStatement: async (input) => await this.rpc.call("identity.signStatement", {
926
+ databaseId: this.databaseId,
927
+ ...input
928
+ })
929
+ };
930
+ this.timestamps = {
931
+ rfc3161: async (input) => await this.rpc.call("timestamps.rfc3161", {
932
+ databaseId: this.databaseId,
933
+ ...input
934
+ }),
935
+ listProviders: async () => await this.rpc.call("timestamps.listProviders", {
936
+ databaseId: this.databaseId
937
+ })
938
+ };
939
+ this.directory = {
940
+ excerpt: async (publicKeys) => await this.rpc.call("directory.excerpt", {
941
+ databaseId: this.databaseId,
942
+ publicKeys
914
943
  })
915
944
  };
916
945
  this.attachments = {
@@ -1032,6 +1061,9 @@ var MindooDBAppDatabaseImpl = class {
1032
1061
  databaseId;
1033
1062
  documents;
1034
1063
  attachments;
1064
+ identity;
1065
+ timestamps;
1066
+ directory;
1035
1067
  /** Returns database metadata for the currently opened binding. */
1036
1068
  async info() {
1037
1069
  return await this.rpc.call("databases.info", {
@@ -1539,6 +1571,7 @@ async function queryDocuments(db, filter, sortBy, options) {
1539
1571
  return db.query({ filter: expression, sortBy }, options);
1540
1572
  }
1541
1573
  export {
1574
+ MINDOODB_APP_SEAL_SIGNING_DOMAIN,
1542
1575
  MindooDBRichTextHandle,
1543
1576
  MindooDBTextBuffer,
1544
1577
  abbreviateCanonicalName,
@@ -1,4 +1,4 @@
1
- import { au as MindooDBAppLaunchContext, a7 as MindooDBAppDatabaseInfo, a8 as MindooDBAppDocumentApi, a6 as MindooDBAppCreateViewNavigatorInput, bh as MindooDBAppViewNavigator, bj as MindooDBAppViewNavigatorOpenOptions, h as MindooDBAppAttachmentApi, ai as MindooDBAppFulltextSetup, ah as MindooDBAppExtractionSetup, a as MindooDBAppBridge, b5 as MindooDBAppSession, B as MindooDBAppBridgeRpcRequest, al as MindooDBAppHostTheme, bp as MindooDBAppViewport, bb as MindooDBAppUiPreferences, aK as MindooDBAppQueryResult, bo as MindooDBAppViewUpdateStats, x as MindooDBAppBridgePortMessage } from '../types-B2lo8s7H.js';
1
+ import { aA as MindooDBAppLaunchContext, a8 as MindooDBAppDatabaseInfo, ab as MindooDBAppDocumentApi, a7 as MindooDBAppCreateViewNavigatorInput, bx as MindooDBAppViewNavigator, bz as MindooDBAppViewNavigatorOpenOptions, i as MindooDBAppAttachmentApi, ar as MindooDBAppIdentityApi, bn as MindooDBAppTimestampApi, a9 as MindooDBAppDirectoryApi, an as MindooDBAppFulltextSetup, am as MindooDBAppExtractionSetup, a as MindooDBAppBridge, bd as MindooDBAppSession, C as MindooDBAppBridgeRpcRequest, aq as MindooDBAppHostTheme, bF as MindooDBAppViewport, br as MindooDBAppUiPreferences, aQ as MindooDBAppQueryResult, bE as MindooDBAppViewUpdateStats, y as MindooDBAppBridgePortMessage } from '../types-c6uTlJnB.js';
2
2
  import 'mindoodb-view-language';
3
3
 
4
4
  type MaybePromise<T> = T | Promise<T>;
@@ -10,6 +10,9 @@ type MockDatabaseMethods = {
10
10
  documents?: Partial<MindooDBAppDocumentApi>;
11
11
  views?: Partial<MockViewApi>;
12
12
  attachments?: Partial<MindooDBAppAttachmentApi>;
13
+ identity?: Partial<MindooDBAppIdentityApi>;
14
+ timestamps?: Partial<MindooDBAppTimestampApi>;
15
+ directory?: Partial<MindooDBAppDirectoryApi>;
13
16
  };
14
17
  interface MockMindooDBAppDatabaseDefinition {
15
18
  info: MindooDBAppDatabaseInfo;
@@ -5,6 +5,7 @@ import {
5
5
  parseMindooDBFormulaBooleanExpression
6
6
  } from "mindoodb-view-language";
7
7
  var PROTOCOL = "mindoodb-app-bridge";
8
+ var MOCK_SIGNING_PUBLIC_KEY_PEM = "-----BEGIN PUBLIC KEY-----\nMCowBQYDK2VwAyEAmockmockmockmockmockmockmockmockmockmockmoc=\n-----END PUBLIC KEY-----\n";
8
9
  function createBridgeErrorPayload(error, fallbackCode = "bridge-error") {
9
10
  if (error && typeof error === "object" && "message" in error) {
10
11
  const namedError = error;
@@ -746,6 +747,14 @@ function createDefaultViewNavigator() {
746
747
  }
747
748
  };
748
749
  }
750
+ async function mockSha256Hex(value) {
751
+ const subtle = globalThis.crypto?.subtle;
752
+ if (!subtle) {
753
+ return null;
754
+ }
755
+ const digest = await subtle.digest("SHA-256", new TextEncoder().encode(value));
756
+ return Array.from(new Uint8Array(digest)).map((byte) => byte.toString(16).padStart(2, "0")).join("");
757
+ }
749
758
  function createDatabaseHandle(definition) {
750
759
  let createCounter = 0;
751
760
  let changeCounter = 0;
@@ -920,6 +929,9 @@ function createDatabaseHandle(definition) {
920
929
  if (input.id !== void 0 && input.idPrefix !== void 0) {
921
930
  throw new Error("documents.create: id and idPrefix are mutually exclusive");
922
931
  }
932
+ if (input.assumeUniqueId && input.id === void 0) {
933
+ throw new Error("documents.create: assumeUniqueId requires a caller-provided id");
934
+ }
923
935
  const callerId = typeof input.id === "string" && input.id.length > 0 ? input.id : null;
924
936
  if (callerId) {
925
937
  const existing = storedDocuments.get(callerId);
@@ -1064,6 +1076,59 @@ function createDatabaseHandle(definition) {
1064
1076
  data: null,
1065
1077
  attachments: []
1066
1078
  };
1079
+ },
1080
+ async listVerification() {
1081
+ return [];
1082
+ }
1083
+ };
1084
+ const defaultIdentity = {
1085
+ async signStatement(input) {
1086
+ if (input.preview.svg != null && input.preview.renderDigest != null) {
1087
+ const actual = await mockSha256Hex(input.preview.svg);
1088
+ if (actual != null && actual !== input.preview.renderDigest) {
1089
+ return { ok: false, reason: "render-mismatch" };
1090
+ }
1091
+ }
1092
+ return {
1093
+ ok: true,
1094
+ signature: `mock-signature-${input.statement.byteLength}`,
1095
+ publicKey: MOCK_SIGNING_PUBLIC_KEY_PEM,
1096
+ fingerprint: "0".repeat(64),
1097
+ domain: input.domain,
1098
+ signedAt: Date.now()
1099
+ };
1100
+ }
1101
+ };
1102
+ const defaultTimestamps = {
1103
+ async rfc3161(input) {
1104
+ return {
1105
+ token: `mock-timestamp-token-${input.digest.byteLength}`,
1106
+ providerId: input.providerId ?? "mock",
1107
+ providerName: "Mock TSA (test host)",
1108
+ transport: "direct",
1109
+ genTime: Date.now(),
1110
+ rootInPublicTrustStores: false
1111
+ };
1112
+ },
1113
+ async listProviders() {
1114
+ return [
1115
+ {
1116
+ id: "mock",
1117
+ name: "Mock TSA (test host)",
1118
+ qualified: false,
1119
+ rootInPublicTrustStores: false,
1120
+ browserReachable: true
1121
+ }
1122
+ ];
1123
+ }
1124
+ };
1125
+ const defaultDirectory = {
1126
+ async excerpt(publicKeys) {
1127
+ return publicKeys.map((signingPublicKey) => ({
1128
+ signingPublicKey,
1129
+ fingerprint: "0".repeat(64),
1130
+ status: "unknown"
1131
+ }));
1067
1132
  }
1068
1133
  };
1069
1134
  const defaultViews = {
@@ -1126,6 +1191,18 @@ function createDatabaseHandle(definition) {
1126
1191
  ...defaultAttachments,
1127
1192
  ...methods.attachments
1128
1193
  },
1194
+ identity: {
1195
+ ...defaultIdentity,
1196
+ ...methods.identity
1197
+ },
1198
+ timestamps: {
1199
+ ...defaultTimestamps,
1200
+ ...methods.timestamps
1201
+ },
1202
+ directory: {
1203
+ ...defaultDirectory,
1204
+ ...methods.directory
1205
+ },
1129
1206
  async getFulltextSetup() {
1130
1207
  return fulltextSetup === null ? null : { ...fulltextSetup };
1131
1208
  },
@@ -1675,6 +1752,27 @@ function createFakeBridgeHost(options = {}) {
1675
1752
  String(params.docId),
1676
1753
  String(params.revisionId)
1677
1754
  );
1755
+ case "documents.history.listVerification":
1756
+ return await state.getDatabase(String(params.databaseId)).documents.listVerification(
1757
+ String(params.docId),
1758
+ Array.isArray(params.revisionIds) ? params.revisionIds.map(String) : void 0
1759
+ );
1760
+ case "identity.signStatement": {
1761
+ const { databaseId: _databaseId, ...input } = params;
1762
+ return await state.getDatabase(String(params.databaseId)).identity.signStatement(
1763
+ input
1764
+ );
1765
+ }
1766
+ case "timestamps.rfc3161": {
1767
+ const { databaseId: _databaseId, ...input } = params;
1768
+ return await state.getDatabase(String(params.databaseId)).timestamps.rfc3161(input);
1769
+ }
1770
+ case "timestamps.listProviders":
1771
+ return await state.getDatabase(String(params.databaseId)).timestamps.listProviders();
1772
+ case "directory.excerpt":
1773
+ return await state.getDatabase(String(params.databaseId)).directory.excerpt(
1774
+ Array.isArray(params.publicKeys) ? params.publicKeys.map(String) : []
1775
+ );
1678
1776
  case "attachments.list":
1679
1777
  return await state.getDatabase(String(params.databaseId)).attachments.list(
1680
1778
  String(params.docId),
@@ -102,7 +102,7 @@ interface MindooDBAppResolvedViewDefinition {
102
102
  columns: MindooDBAppConfiguredViewColumn[];
103
103
  }
104
104
  /** Permission/capability flags exposed for a database binding inside the app session. */
105
- type MindooDBAppCapability = "read" | "create" | "update" | "delete" | "history" | "attachments" | "views";
105
+ type MindooDBAppCapability = "read" | "create" | "update" | "delete" | "history" | "attachments" | "views" | "sign" | "timestamps" | "directory";
106
106
  /** Metadata about the current app launch supplied by the Haven host. */
107
107
  interface MindooDBAppLaunchContext {
108
108
  appId: string;
@@ -209,6 +209,86 @@ interface MindooDBAppDocumentHistoryEntry {
209
209
  isCurrent: boolean;
210
210
  summary?: string;
211
211
  }
212
+ /**
213
+ * The cryptographic record behind one revision, as it sits in the append-only
214
+ * store — what a seal or an audit needs and what {@link MindooDBAppDocumentHistoryEntry}
215
+ * deliberately omits.
216
+ *
217
+ * Nothing here requires the document's decryption key. `metadataSignature`
218
+ * covers the entry id, and an entry id ends in the hash of the *plaintext*
219
+ * Automerge change, so an outsider can attribute every change to a key and
220
+ * order the whole edit DAG while learning nothing about what any change
221
+ * contained.
222
+ *
223
+ * Byte fields are base64 rather than `Uint8Array` because these records are
224
+ * written verbatim into evidence bundles as JSON, and read back years later by
225
+ * a verifier that has no Haven, no tenant and no network.
226
+ */
227
+ interface MindooDBAppRevisionVerification {
228
+ /** Matches `revisionId` in {@link MindooDBAppDocumentHistoryEntry}. */
229
+ revisionId: MindooDBAppDocumentRevisionId;
230
+ /** Store entry id: `<docId>_d_<depsFingerprint>_<automergeChangeHash>`. */
231
+ entryId: string;
232
+ entryType: string;
233
+ docId: string;
234
+ /** Database name the entry lives under; bound into the witness receipt. */
235
+ dbid: string;
236
+ /** SHA-256 of the *encrypted* payload. */
237
+ contentHash: string;
238
+ createdAt: number;
239
+ createdByPublicKey: string;
240
+ decryptionKeyId: string;
241
+ dependencyIds: string[];
242
+ attachmentRefs?: MindooDBAppEntryAttachmentRef[];
243
+ provenance?: MindooDBAppEntryProvenance;
244
+ /** Base64 legacy signature, over the ciphertext only. */
245
+ signature: string;
246
+ /**
247
+ * Base64 signature over the canonical metadata layout, which includes the
248
+ * entry id. Absent on entries written before this field existed — those
249
+ * cannot be bound to a plaintext change at all, and a verifier must report
250
+ * them as unattributable rather than pass them.
251
+ */
252
+ metadataSignature?: string;
253
+ /** Epoch ms at which a witnessing server accepted the entry. */
254
+ receivedAt?: number;
255
+ receivedByPublicKey?: string;
256
+ /** Base64 Ed25519 signature by the witness over the receipt layout. */
257
+ receivedDateSignature?: string;
258
+ receiptScheme?: string;
259
+ entryVersion?: number;
260
+ /**
261
+ * The tenant's trusted witness keys *as of* `receivedAt`. A receipt is only
262
+ * worth something if its signer was trusted when it was made, and that set
263
+ * changes over a tenant's life — so it is resolved at read time and carried
264
+ * along, not left for the verifier to guess.
265
+ */
266
+ trustedWitnessKeys?: string[];
267
+ }
268
+ /** Attachment reference bound into an entry's metadata signature. */
269
+ interface MindooDBAppEntryAttachmentRef {
270
+ attachmentId: string;
271
+ lastChunkId: string;
272
+ size: number;
273
+ }
274
+ /** Where a copied entry came from, as recorded in its signed metadata. */
275
+ interface MindooDBAppEntryProvenance {
276
+ sourceTenantId: string;
277
+ sourceDbId: string;
278
+ source: {
279
+ entryType: string;
280
+ id: string;
281
+ docId: string;
282
+ decryptionKeyId: string;
283
+ createdAt: number;
284
+ dependencyIds: string[];
285
+ contentHash: string;
286
+ createdByPublicKey: string;
287
+ attachmentRefs?: MindooDBAppEntryAttachmentRef[];
288
+ };
289
+ /** Base64 signature by the original author. */
290
+ sourceMetadataSignature?: string;
291
+ }
212
292
  /** Historical snapshot returned for a document at a specific timestamp. */
213
293
  interface MindooDBAppHistoricalDocument {
214
294
  id: string;
@@ -333,6 +413,22 @@ interface MindooDBAppCreateDocumentInput {
333
413
  * Mutually exclusive with `idPrefix`.
334
414
  */
335
415
  id?: string;
416
+ /**
417
+ * Caller assertion that the provided `id` was generated randomly with
418
+ * enough entropy that no other replica can create the same id concurrently
419
+ * (e.g. an app-side `<prefix>_<uuid>` scheme). Only meaningful together
420
+ * with `id`.
421
+ *
422
+ * With this flag the create behaves like the `idPrefix` path: the initial
423
+ * `set` values are baked into the single `doc_create` entry — no
424
+ * deterministic seed change and no follow-up change entry. This halves the
425
+ * store entries for bulk imports whose documents cross-reference each other
426
+ * by pre-generated random ids.
427
+ *
428
+ * WARNING: do NOT set this for fixed/well-known ids (settings singletons
429
+ * etc.) — concurrent creates of the same id would fork instead of converge.
430
+ */
431
+ assumeUniqueId?: boolean;
336
432
  /**
337
433
  * Optional short prefix (1–10 ASCII-alphanumeric chars, starting with a
338
434
  * letter, no `_`) for a host-generated document id. The final id is
@@ -1159,8 +1255,10 @@ interface MindooDBAppDocumentApi {
1159
1255
  getDefaultCreateKeyId(): Promise<string>;
1160
1256
  /**
1161
1257
  * List the document's revision timeline (newest first), including author
1162
- * identity metadata and the stable `revisionId` per entry. Requires the
1163
- * `history` capability.
1258
+ * identity metadata and the stable `revisionId` per entry. Entries are
1259
+ * metadata-only — document bodies are not included; load a revision with
1260
+ * {@link getAtRevision} or {@link getAtTimestamp}. Requires the `history`
1261
+ * capability.
1164
1262
  */
1165
1263
  listHistory(docId: string): Promise<MindooDBAppDocumentHistoryEntry[]>;
1166
1264
  /**
@@ -1178,6 +1276,184 @@ interface MindooDBAppDocumentApi {
1178
1276
  * capability.
1179
1277
  */
1180
1278
  getAtRevision(docId: string, revisionId: MindooDBAppDocumentRevisionId): Promise<MindooDBAppHistoricalDocument>;
1279
+ /**
1280
+ * The signatures and witness receipts behind a document's revisions —
1281
+ * everything {@link listHistory} leaves out because a timeline UI does not
1282
+ * need it and an audit cannot do without it.
1283
+ *
1284
+ * Pass `revisionIds` to fetch only the revisions being sealed; omit it for
1285
+ * the whole document. Requires the `history` capability.
1286
+ */
1287
+ listVerification(docId: string, revisionIds?: MindooDBAppDocumentRevisionId[]): Promise<MindooDBAppRevisionVerification[]>;
1288
+ }
1289
+ /**
1290
+ * Signing with the launching user's MindooDB identity key.
1291
+ *
1292
+ * The app never touches the key, and never signs silently: every call opens a
1293
+ * Haven dialog showing what is about to be signed. Requires the `sign`
1294
+ * capability, which only grants the *right to ask*.
1295
+ */
1296
+ interface MindooDBAppIdentityApi {
1297
+ /**
1298
+ * Ask the user to sign `input.statement` under `input.domain`.
1299
+ *
1300
+ * Resolves with `ok: false` when the user declines or when the preview SVG
1301
+ * does not match the `renderDigest` inside the statement — neither is an
1302
+ * error, and both should leave the app's UI intact.
1303
+ */
1304
+ signStatement(input: MindooDBAppSignStatementInput): Promise<MindooDBAppSignStatementResult>;
1305
+ }
1306
+ /** RFC 3161 timestamps over app-supplied digests. */
1307
+ interface MindooDBAppTimestampApi {
1308
+ /**
1309
+ * Obtain a timestamp token. Haven calls a browser-reachable TSA directly
1310
+ * where it can, and otherwise proxies through the tenant's server; the
1311
+ * returned `transport` says which happened.
1312
+ *
1313
+ * A token proves the digest existed *no later than* `genTime`. It cannot
1314
+ * prove a lower bound, and no amount of UI wording should imply otherwise.
1315
+ * Requires the `timestamps` capability.
1316
+ */
1317
+ rfc3161(input: MindooDBAppTimestampInput): Promise<MindooDBAppTimestampResult>;
1318
+ /** Providers this host can currently reach, best first. */
1319
+ listProviders(): Promise<MindooDBAppTimestampProvider[]>;
1320
+ }
1321
+ /** Read-only lookups against the tenant's user directory. */
1322
+ interface MindooDBAppDirectoryApi {
1323
+ /**
1324
+ * Resolve the directory's claims about specific signing keys.
1325
+ *
1326
+ * Only the keys asked for are returned, and unknown keys come back with
1327
+ * `status: "unknown"` rather than being dropped — an evidence excerpt should
1328
+ * name the keys it could not resolve. Requires the `directory` capability.
1329
+ */
1330
+ excerpt(publicKeys: string[]): Promise<MindooDBAppDirectoryEntry[]>;
1331
+ }
1332
+ /**
1333
+ * The only signing domain apps may request today. Domain separation is not
1334
+ * decoration: the same Ed25519 key signs store entries and auth challenges, and
1335
+ * an app that could choose its own prefix could have the user unwittingly sign
1336
+ * something that replays as one of those.
1337
+ */
1338
+ declare const MINDOODB_APP_SEAL_SIGNING_DOMAIN = "mindoodb-seal/v1";
1339
+ /** What the seal asserts about the material it covers. */
1340
+ type MindooDBAppSealIntent = "approval" | "countersign" | "authorship";
1341
+ /**
1342
+ * What Haven shows the user before signing.
1343
+ *
1344
+ * This is the WYSIWYS ("what you see is what you sign") surface. The app hands
1345
+ * over the exact picture and wording it wants attested; Haven checks the SVG
1346
+ * against `renderDigest` — which is inside the signed bytes — and refuses to
1347
+ * sign when they disagree. Without that check a signature would attest to bytes
1348
+ * nobody ever looked at.
1349
+ */
1350
+ interface MindooDBAppSignPreview {
1351
+ /** Headline of the consent dialog, e.g. "Approve page 3 of Site survey". */
1352
+ title: string;
1353
+ intent: MindooDBAppSealIntent;
1354
+ /**
1355
+ * SVG source of what is being sealed, shown inline. Haven verifies that its
1356
+ * SHA-256 equals {@link renderDigest} before rendering it.
1357
+ */
1358
+ svg?: string;
1359
+ /** Lower-case hex SHA-256 of `svg`, as it appears in the statement. */
1360
+ renderDigest?: string;
1361
+ /** One row per sealed document, shown as a list the user can read. */
1362
+ scope: MindooDBAppSignPreviewScope[];
1363
+ /** Free-text note that is part of the signed statement. */
1364
+ note?: string;
1365
+ }
1366
+ /** One sealed document as presented in the consent dialog. */
1367
+ interface MindooDBAppSignPreviewScope {
1368
+ label: string;
1369
+ detail?: string;
1370
+ }
1371
+ /** Request to sign a canonical statement with the launching user's identity key. */
1372
+ interface MindooDBAppSignStatementInput {
1373
+ /** Must be {@link MINDOODB_APP_SEAL_SIGNING_DOMAIN}. */
1374
+ domain: string;
1375
+ /** Canonical (RFC 8785) statement bytes. Signed verbatim under `domain`. */
1376
+ statement: Uint8Array;
1377
+ preview: MindooDBAppSignPreview;
1378
+ }
1379
+ /**
1380
+ * Outcome of a signing request.
1381
+ *
1382
+ * Declining is an ordinary outcome, not an error: `ok: false` with a `reason`,
1383
+ * so an app can distinguish "the user said no" from "the bridge broke" without
1384
+ * inspecting error strings.
1385
+ */
1386
+ type MindooDBAppSignStatementResult = {
1387
+ ok: true;
1388
+ /** Base64 Ed25519 signature over `domain || 0x00 || statement`. */
1389
+ signature: string;
1390
+ /** PEM public key of the signing identity. */
1391
+ publicKey: string;
1392
+ /** Lower-case hex SHA-256 of the DER SubjectPublicKeyInfo. */
1393
+ fingerprint: string;
1394
+ domain: string;
1395
+ /** Client wall-clock at signing. Not evidence — the TSA token is. */
1396
+ signedAt: number;
1397
+ } | {
1398
+ ok: false;
1399
+ reason: "declined" | "render-mismatch";
1400
+ };
1401
+ /** Request for an RFC 3161 token over a digest the app computed. */
1402
+ interface MindooDBAppTimestampInput {
1403
+ /** Raw digest bytes to be timestamped (32 bytes for SHA-256). */
1404
+ digest: Uint8Array;
1405
+ /** @defaultValue `"SHA-256"` */
1406
+ hashAlgorithm?: "SHA-256" | "SHA-512";
1407
+ /**
1408
+ * Preferred provider id from {@link MindooDBAppTimestampProvider}. Apps name
1409
+ * a provider, never a URL — the URL set is server configuration, so a hostile
1410
+ * app cannot aim the host at an address of its choosing.
1411
+ */
1412
+ providerId?: string;
1413
+ /** Ask the TSA to include its certificate chain in the token. @defaultValue `true` */
1414
+ requestCertificates?: boolean;
1415
+ }
1416
+ /** A timestamp token, with enough context to verify it offline later. */
1417
+ interface MindooDBAppTimestampResult {
1418
+ /** Base64 DER `TimeStampResp`. */
1419
+ token: string;
1420
+ providerId: string;
1421
+ providerName?: string;
1422
+ /** Where the token came from: a direct browser call or the tenant's server. */
1423
+ transport: "direct" | "proxy";
1424
+ /** TSA-asserted time, epoch ms, as parsed from the token. */
1425
+ genTime?: number;
1426
+ policyOid?: string;
1427
+ /** True when the token chains to a root in public trust stores. */
1428
+ rootInPublicTrustStores?: boolean;
1429
+ /** PEM chain extracted from the token, for a verifier with no trust store. */
1430
+ certificateChainPem?: string;
1431
+ }
1432
+ /** A timestamping provider this host can reach. */
1433
+ interface MindooDBAppTimestampProvider {
1434
+ id: string;
1435
+ name: string;
1436
+ /** eIDAS-qualified. Free and non-qualified are the common case. */
1437
+ qualified: boolean;
1438
+ rootInPublicTrustStores: boolean;
1439
+ policyOid?: string;
1440
+ /** Reachable straight from the browser (CORS-enabled), no server needed. */
1441
+ browserReachable: boolean;
1442
+ }
1443
+ /**
1444
+ * One directory entry, for the identity excerpt a bundle carries.
1445
+ *
1446
+ * This is the weakest link in the evidence and the docs say so plainly: it
1447
+ * records what the tenant's directory claimed about a key, which is an
1448
+ * agreement between the parties, not a cryptographic fact.
1449
+ */
1450
+ interface MindooDBAppDirectoryEntry {
1451
+ /** PEM Ed25519 signing key, as it appears in entry metadata. */
1452
+ signingPublicKey: string;
1453
+ fingerprint: string;
1454
+ label?: string;
1455
+ email?: string;
1456
+ status: "active" | "revoked" | "unknown";
1181
1457
  }
1182
1458
  type MindooDBAppViewEntryKind = "category" | "document";
1183
1459
  /** Unique document identity within a multi-source view. */
@@ -1469,6 +1745,17 @@ interface MindooDBAppDatabase {
1469
1745
  info(): Promise<MindooDBAppDatabaseInfo>;
1470
1746
  documents: MindooDBAppDocumentApi;
1471
1747
  attachments: MindooDBAppAttachmentApi;
1748
+ /**
1749
+ * Signing, timestamping and directory lookups.
1750
+ *
1751
+ * These hang off a database rather than the session because each one is
1752
+ * granted per binding and resolves through that binding's tenant — the
1753
+ * signing identity, the server that proxies timestamps and the directory
1754
+ * being quoted are all the tenant's, not the app's.
1755
+ */
1756
+ identity: MindooDBAppIdentityApi;
1757
+ timestamps: MindooDBAppTimestampApi;
1758
+ directory: MindooDBAppDirectoryApi;
1472
1759
  /**
1473
1760
  * Read the database's full-text index configuration from the synced
1474
1761
  * `dbsetup` document. Resolves to `null` when full-text indexing has
@@ -1598,4 +1885,4 @@ interface MindooDBAppBridge {
1598
1885
  connect(options?: MindooDBAppBridgeConnectOptions): Promise<MindooDBAppSession>;
1599
1886
  }
1600
1887
 
1601
- export type { MindooDBAppConfiguredViewPreviewMode as $, MindooDBAppBridgeRpcMessage as A, MindooDBAppBridgeRpcRequest as B, MindooDBAppBridgeRpcSuccess as C, MindooDBAppBridgeStreamAbortRequest as D, MindooDBAppBridgeStreamAck as E, MindooDBAppBridgeStreamCloseRequest as F, MindooDBAppBridgeStreamError as G, MindooDBAppBridgeStreamMessage as H, MindooDBAppBridgeStreamOpenResult as I, MindooDBAppBridgeStreamReadRequest as J, MindooDBAppBridgeStreamWriteRequest as K, MindooDBAppBridgeThemeChangedMessage as L, MindooDBAppAttachmentPreviewMode as M, MindooDBAppBridgeUiPreferencesChangedMessage as N, MindooDBAppBridgeViewChangedMessage as O, MindooDBAppBridgeViewportChangedMessage as P, MindooDBAppCapability as Q, MindooDBAppConfiguredViewCategorizationStyle as R, MindooDBAppConfiguredViewColumn as S, MindooDBAppConfiguredViewColumnRole as T, MindooDBAppConfiguredViewExpressionMode as U, MindooDBAppConfiguredViewFieldExpression as V, MindooDBAppConfiguredViewFilterDefinition as W, MindooDBAppConfiguredViewFilterMode as X, MindooDBAppConfiguredViewFilterRule as Y, MindooDBAppConfiguredViewFormulaExpression as Z, MindooDBAppConfiguredViewFormulaFilterDefinition as _, MindooDBAppBridge as a, MindooDBAppRichTextTextSpan as a$, MindooDBAppConfiguredViewRuleFilterDefinition as a0, MindooDBAppConfiguredViewRuleMatchMode as a1, MindooDBAppConfiguredViewRuleOperator as a2, MindooDBAppConfiguredViewValueExpression as a3, MindooDBAppCreateDocumentInput as a4, MindooDBAppCreateViewInput as a5, MindooDBAppCreateViewNavigatorInput as a6, MindooDBAppDatabaseInfo as a7, MindooDBAppDocumentApi as a8, MindooDBAppDocumentHeadCursorResult as a9, MindooDBAppMenuDismissedResult as aA, MindooDBAppMenuItem as aB, MindooDBAppMenuKind as aC, MindooDBAppMenuPlacement as aD, MindooDBAppMenuPointAnchor as aE, MindooDBAppMenuRect as aF, MindooDBAppMenuRectAnchor as aG, MindooDBAppMenuSelectionResult as aH, MindooDBAppMenuSeparatorItem as aI, MindooDBAppQueryCoverage as aJ, MindooDBAppQueryResult as aK, MindooDBAppQueryRow as aL, MindooDBAppQuerySortKey as aM, MindooDBAppQueryTextClause as aN, MindooDBAppReadableAttachmentStream as aO, MindooDBAppResolvedViewDefinition as aP, MindooDBAppResolvedViewSource as aQ, MindooDBAppRichTextBlockSpan as aR, MindooDBAppRichTextGetOptions as aS, MindooDBAppRichTextImmutableString as aT, MindooDBAppRichTextMarkRange as aU, MindooDBAppRichTextMaterializeValue as aV, MindooDBAppRichTextPatch as aW, MindooDBAppRichTextScalar as aX, MindooDBAppRichTextSpliceStep as aY, MindooDBAppRichTextStep as aZ, MindooDBAppRichTextStepPatch as a_, MindooDBAppDocumentHistoryEntry as aa, MindooDBAppDocumentListQuery as ab, MindooDBAppDocumentListResult as ac, MindooDBAppDocumentQuery as ad, MindooDBAppDocumentRevisionId as ae, MindooDBAppDocumentScanPreset as af, MindooDBAppDocumentSummary as ag, MindooDBAppExtractionSetup as ah, MindooDBAppFulltextSetup as ai, MindooDBAppHistoricalDocument as aj, MindooDBAppHistoryQuery as ak, MindooDBAppHostTheme as al, MindooDBAppJsonListDeletePatch as am, MindooDBAppJsonListInsertPatch as an, MindooDBAppJsonPatch as ao, MindooDBAppJsonSetPatch as ap, MindooDBAppJsonTextMarkPatch as aq, MindooDBAppJsonTextSplicePatch as ar, MindooDBAppJsonTextUnmarkPatch as as, MindooDBAppJsonUnsetPatch as at, MindooDBAppLaunchContext as au, MindooDBAppLiveQuerySubscription as av, MindooDBAppMenuAnchor as aw, MindooDBAppMenuApi as ax, MindooDBAppMenuCommandItem as ay, MindooDBAppMenuDismissReason as az, MindooDBAppDatabase as b, MindooDBAppRuntime as b0, MindooDBAppScanAttachmentOptions as b1, MindooDBAppScanAttachmentResult as b2, MindooDBAppScopedDocId as b3, MindooDBAppScopedDocumentSummary as b4, MindooDBAppSession as b5, MindooDBAppShowMenuInput as b6, MindooDBAppShowMenuResult as b7, MindooDBAppTextEdit as b8, MindooDBAppTextPatch as b9, MindooDBAppThemeMode as ba, MindooDBAppUiPreferences as bb, MindooDBAppUpdateDocumentInput as bc, MindooDBAppViewCursorDocumentListResult as bd, MindooDBAppViewCursorResult as be, MindooDBAppViewEntry as bf, MindooDBAppViewEntryKind as bg, MindooDBAppViewNavigator as bh, MindooDBAppViewNavigatorExpansionState as bi, MindooDBAppViewNavigatorOpenOptions as bj, MindooDBAppViewNavigatorPageOptions as bk, MindooDBAppViewNavigatorPageResult as bl, MindooDBAppViewNavigatorRangeQuery as bm, MindooDBAppViewNavigatorSelectionState as bn, MindooDBAppViewUpdateStats as bo, MindooDBAppViewport as bp, MindooDBAppWritableAttachmentStream as bq, MindooDBAppDocument as c, MindooDBAppRichTextSpan as d, MindooDBAppRichTextSnapshot as e, MindooDBAppAccessDecision as f, MindooDBAppAccessTier as g, MindooDBAppAttachmentApi as h, MindooDBAppAttachmentChunk as i, MindooDBAppAttachmentInfo as j, MindooDBAppAttachmentPreviewOptions as k, MindooDBAppAttachmentPreviewSession as l, MindooDBAppAutomergeChangesPatch as m, MindooDBAppAutomergeChangesSince as n, MindooDBAppAutomergeGetOptions as o, MindooDBAppAutomergePatchResult as p, MindooDBAppAutomergeSnapshot as q, MindooDBAppBridgeConnectMessage as r, MindooDBAppBridgeConnectOptions as s, MindooDBAppBridgeConnectedMessage as t, MindooDBAppBridgeErrorPayload as u, MindooDBAppBridgeHandshakeErrorMessage as v, MindooDBAppBridgeLocaleChangedMessage as w, MindooDBAppBridgePortMessage as x, MindooDBAppBridgeQueryResultMessage as y, MindooDBAppBridgeRpcError as z };
1888
+ export { type MindooDBAppConfiguredViewFormulaFilterDefinition as $, type MindooDBAppBridgeRpcError as A, type MindooDBAppBridgeRpcMessage as B, type MindooDBAppBridgeRpcRequest as C, type MindooDBAppBridgeRpcSuccess as D, type MindooDBAppBridgeStreamAbortRequest as E, type MindooDBAppBridgeStreamAck as F, type MindooDBAppBridgeStreamCloseRequest as G, type MindooDBAppBridgeStreamError as H, type MindooDBAppBridgeStreamMessage as I, type MindooDBAppBridgeStreamOpenResult as J, type MindooDBAppBridgeStreamReadRequest as K, type MindooDBAppBridgeStreamWriteRequest as L, type MindooDBAppAttachmentPreviewMode as M, type MindooDBAppBridgeThemeChangedMessage as N, type MindooDBAppBridgeUiPreferencesChangedMessage as O, type MindooDBAppBridgeViewChangedMessage as P, type MindooDBAppBridgeViewportChangedMessage as Q, type MindooDBAppCapability as R, type MindooDBAppConfiguredViewCategorizationStyle as S, type MindooDBAppConfiguredViewColumn as T, type MindooDBAppConfiguredViewColumnRole as U, type MindooDBAppConfiguredViewExpressionMode as V, type MindooDBAppConfiguredViewFieldExpression as W, type MindooDBAppConfiguredViewFilterDefinition as X, type MindooDBAppConfiguredViewFilterMode as Y, type MindooDBAppConfiguredViewFilterRule as Z, type MindooDBAppConfiguredViewFormulaExpression as _, type MindooDBAppBridge as a, type MindooDBAppRichTextMarkRange as a$, type MindooDBAppConfiguredViewPreviewMode as a0, type MindooDBAppConfiguredViewRuleFilterDefinition as a1, type MindooDBAppConfiguredViewRuleMatchMode as a2, type MindooDBAppConfiguredViewRuleOperator as a3, type MindooDBAppConfiguredViewValueExpression as a4, type MindooDBAppCreateDocumentInput as a5, type MindooDBAppCreateViewInput as a6, type MindooDBAppCreateViewNavigatorInput as a7, type MindooDBAppDatabaseInfo as a8, type MindooDBAppDirectoryApi as a9, type MindooDBAppLaunchContext as aA, type MindooDBAppLiveQuerySubscription as aB, type MindooDBAppMenuAnchor as aC, type MindooDBAppMenuApi as aD, type MindooDBAppMenuCommandItem as aE, type MindooDBAppMenuDismissReason as aF, type MindooDBAppMenuDismissedResult as aG, type MindooDBAppMenuItem as aH, type MindooDBAppMenuKind as aI, type MindooDBAppMenuPlacement as aJ, type MindooDBAppMenuPointAnchor as aK, type MindooDBAppMenuRect as aL, type MindooDBAppMenuRectAnchor as aM, type MindooDBAppMenuSelectionResult as aN, type MindooDBAppMenuSeparatorItem as aO, type MindooDBAppQueryCoverage as aP, type MindooDBAppQueryResult as aQ, type MindooDBAppQueryRow as aR, type MindooDBAppQuerySortKey as aS, type MindooDBAppQueryTextClause as aT, type MindooDBAppReadableAttachmentStream as aU, type MindooDBAppResolvedViewDefinition as aV, type MindooDBAppResolvedViewSource as aW, type MindooDBAppRevisionVerification as aX, type MindooDBAppRichTextBlockSpan as aY, type MindooDBAppRichTextGetOptions as aZ, type MindooDBAppRichTextImmutableString as a_, type MindooDBAppDirectoryEntry as aa, type MindooDBAppDocumentApi as ab, type MindooDBAppDocumentHeadCursorResult as ac, type MindooDBAppDocumentHistoryEntry as ad, type MindooDBAppDocumentListQuery as ae, type MindooDBAppDocumentListResult as af, type MindooDBAppDocumentQuery as ag, type MindooDBAppDocumentRevisionId as ah, type MindooDBAppDocumentScanPreset as ai, type MindooDBAppDocumentSummary as aj, type MindooDBAppEntryAttachmentRef as ak, type MindooDBAppEntryProvenance as al, type MindooDBAppExtractionSetup as am, type MindooDBAppFulltextSetup as an, type MindooDBAppHistoricalDocument as ao, type MindooDBAppHistoryQuery as ap, type MindooDBAppHostTheme as aq, type MindooDBAppIdentityApi as ar, type MindooDBAppJsonListDeletePatch as as, type MindooDBAppJsonListInsertPatch as at, type MindooDBAppJsonPatch as au, type MindooDBAppJsonSetPatch as av, type MindooDBAppJsonTextMarkPatch as aw, type MindooDBAppJsonTextSplicePatch as ax, type MindooDBAppJsonTextUnmarkPatch as ay, type MindooDBAppJsonUnsetPatch as az, type MindooDBAppDatabase as b, type MindooDBAppRichTextMaterializeValue as b0, type MindooDBAppRichTextPatch as b1, type MindooDBAppRichTextScalar as b2, type MindooDBAppRichTextSpliceStep as b3, type MindooDBAppRichTextStep as b4, type MindooDBAppRichTextStepPatch as b5, type MindooDBAppRichTextTextSpan as b6, type MindooDBAppRuntime as b7, type MindooDBAppScanAttachmentOptions as b8, type MindooDBAppScanAttachmentResult as b9, type MindooDBAppViewNavigatorPageOptions as bA, type MindooDBAppViewNavigatorPageResult as bB, type MindooDBAppViewNavigatorRangeQuery as bC, type MindooDBAppViewNavigatorSelectionState as bD, type MindooDBAppViewUpdateStats as bE, type MindooDBAppViewport as bF, type MindooDBAppWritableAttachmentStream as bG, type MindooDBAppScopedDocId as ba, type MindooDBAppScopedDocumentSummary as bb, type MindooDBAppSealIntent as bc, type MindooDBAppSession as bd, type MindooDBAppShowMenuInput as be, type MindooDBAppShowMenuResult as bf, type MindooDBAppSignPreview as bg, type MindooDBAppSignPreviewScope as bh, type MindooDBAppSignStatementInput as bi, type MindooDBAppSignStatementResult as bj, type MindooDBAppTextEdit as bk, type MindooDBAppTextPatch as bl, type MindooDBAppThemeMode as bm, type MindooDBAppTimestampApi as bn, type MindooDBAppTimestampInput as bo, type MindooDBAppTimestampProvider as bp, type MindooDBAppTimestampResult as bq, type MindooDBAppUiPreferences as br, type MindooDBAppUpdateDocumentInput as bs, type MindooDBAppViewCursorDocumentListResult as bt, type MindooDBAppViewCursorResult as bu, type MindooDBAppViewEntry as bv, type MindooDBAppViewEntryKind as bw, type MindooDBAppViewNavigator as bx, type MindooDBAppViewNavigatorExpansionState as by, type MindooDBAppViewNavigatorOpenOptions as bz, type MindooDBAppDocument as c, type MindooDBAppRichTextSpan as d, type MindooDBAppRichTextSnapshot as e, MINDOODB_APP_SEAL_SIGNING_DOMAIN as f, type MindooDBAppAccessDecision as g, type MindooDBAppAccessTier as h, type MindooDBAppAttachmentApi as i, type MindooDBAppAttachmentChunk as j, type MindooDBAppAttachmentInfo as k, type MindooDBAppAttachmentPreviewOptions as l, type MindooDBAppAttachmentPreviewSession as m, type MindooDBAppAutomergeChangesPatch as n, type MindooDBAppAutomergeChangesSince as o, type MindooDBAppAutomergeGetOptions as p, type MindooDBAppAutomergePatchResult as q, type MindooDBAppAutomergeSnapshot as r, type MindooDBAppBridgeConnectMessage as s, type MindooDBAppBridgeConnectOptions as t, type MindooDBAppBridgeConnectedMessage as u, type MindooDBAppBridgeErrorPayload as v, type MindooDBAppBridgeHandshakeErrorMessage as w, type MindooDBAppBridgeLocaleChangedMessage as x, type MindooDBAppBridgePortMessage as y, type MindooDBAppBridgeQueryResultMessage as z };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mindoodb-app-sdk",
3
- "version": "0.0.31",
3
+ "version": "0.0.33",
4
4
  "engines": {
5
5
  "node": ">=22.13.0"
6
6
  },
@@ -48,7 +48,7 @@
48
48
  },
49
49
  "devDependencies": {
50
50
  "@automerge/automerge": "^3.2.1",
51
- "mindoodb": "^0.0.38",
51
+ "mindoodb": "^0.0.46",
52
52
  "@types/node": "25.5.0",
53
53
  "tsup": "^8.5.1",
54
54
  "typescript": "^6.0.2",