mindoodb-app-sdk 0.0.51 → 0.0.53
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 +34 -0
- package/TESTING.md +57 -0
- package/dist/{chunk-R76XXRJ6.js → chunk-6NTVTL6G.js} +1 -1
- package/dist/index.d.ts +74 -3
- package/dist/index.js +389 -17
- package/dist/testing/index.d.ts +97 -2
- package/dist/testing/index.js +412 -141
- package/dist/{types-BLyV6Ejy.d.ts → types-CsKw_niD.d.ts} +46 -1
- package/package.json +3 -3
|
@@ -94,11 +94,56 @@ interface MindooDBAppDefinition {
|
|
|
94
94
|
/** `logicalDatabaseId` the app should open first. */
|
|
95
95
|
defaultLaunchDatabaseId?: string;
|
|
96
96
|
databases?: MindooDBAppDefinitionDatabase[];
|
|
97
|
+
/**
|
|
98
|
+
* What a person sees before installing: the app's landing page when its URL is
|
|
99
|
+
* opened directly, and Haven's setup wizard when it arrives through a shared link.
|
|
100
|
+
* Display-only; nothing in here affects what the app is granted.
|
|
101
|
+
*/
|
|
102
|
+
listing?: MindooDBAppDefinitionListing;
|
|
103
|
+
}
|
|
104
|
+
/**
|
|
105
|
+
* Text in one language, or a map from locale (`de`, `fr`, …) to text. A map must carry
|
|
106
|
+
* `en`, the fallback for every locale it does not name.
|
|
107
|
+
*/
|
|
108
|
+
type MindooDBAppLocalizedText = string | ({
|
|
109
|
+
en: string;
|
|
110
|
+
} & Record<string, string>);
|
|
111
|
+
interface MindooDBAppDefinitionScreenshot {
|
|
112
|
+
/** Image path relative to the app origin, or an absolute `https:` URL. */
|
|
113
|
+
file: string;
|
|
114
|
+
caption?: MindooDBAppLocalizedText;
|
|
115
|
+
}
|
|
116
|
+
interface MindooDBAppDefinitionListing {
|
|
117
|
+
/** One or two sentences: what the app is for. */
|
|
118
|
+
summary?: MindooDBAppLocalizedText;
|
|
119
|
+
/** Longer plain text. Blank lines separate paragraphs; no markup is rendered. */
|
|
120
|
+
description?: MindooDBAppLocalizedText;
|
|
121
|
+
/** Square icon, path relative to the app origin or an absolute `https:` URL. */
|
|
122
|
+
icon?: string;
|
|
123
|
+
screenshots?: MindooDBAppDefinitionScreenshot[];
|
|
124
|
+
/** Who publishes the app. Shown next to the app's origin, never instead of it. */
|
|
125
|
+
publisher?: {
|
|
126
|
+
name: string;
|
|
127
|
+
url?: string;
|
|
128
|
+
};
|
|
97
129
|
}
|
|
130
|
+
declare const MINDOODB_APP_LISTING_SUMMARY_MAX = 300;
|
|
131
|
+
declare const MINDOODB_APP_LISTING_DESCRIPTION_MAX = 4000;
|
|
132
|
+
declare const MINDOODB_APP_LISTING_MAX_SCREENSHOTS = 8;
|
|
98
133
|
interface MindooDBAppDefinitionValidation {
|
|
99
134
|
definition: MindooDBAppDefinition | null;
|
|
100
135
|
errors: string[];
|
|
101
136
|
}
|
|
137
|
+
/**
|
|
138
|
+
* Picks the text for `locale` out of a localized value: the exact locale, then its
|
|
139
|
+
* language (`de` for `de-CH`), then `en`.
|
|
140
|
+
*/
|
|
141
|
+
declare function resolveMindooDBAppLocalizedText(text: MindooDBAppLocalizedText | undefined, locale: string): string;
|
|
142
|
+
/**
|
|
143
|
+
* Resolves a listing asset (icon, screenshot) against the app origin. Returns `null`
|
|
144
|
+
* for anything that would leave `https:` or the origin's own scheme.
|
|
145
|
+
*/
|
|
146
|
+
declare function resolveMindooDBAppListingAssetUrl(path: string, originUrl: string): string | null;
|
|
102
147
|
/**
|
|
103
148
|
* Structural validation of a `haven-app.json` payload. Returns the normalized
|
|
104
149
|
* definition, or `null` plus every problem found so a publisher can fix them in one
|
|
@@ -2850,4 +2895,4 @@ interface MindooDBAppBridge {
|
|
|
2850
2895
|
connect(options?: MindooDBAppBridgeConnectOptions): Promise<MindooDBAppSession>;
|
|
2851
2896
|
}
|
|
2852
2897
|
|
|
2853
|
-
export { type
|
|
2898
|
+
export { type MindooDBAppBridgeRpcRequest as $, type MindooDBAppAttachmentApi as A, type MindooDBAppAttachmentChunk as B, type MindooDBAppAttachmentInfo as C, type MindooDBAppAttachmentPreviewOptions as D, type MindooDBAppAttachmentPreviewSession as E, type MindooDBAppAutomergeChangesPatch as F, type MindooDBAppAutomergeChangesSince as G, type MindooDBAppAutomergeGetOptions as H, type MindooDBAppAutomergePatchResult as I, type MindooDBAppAutomergeSnapshot as J, type MindooDBAppBridgeBeforeCloseAck as K, type MindooDBAppBridgeBeforeCloseMessage as L, type MindooDBAppAttachmentPreviewMode as M, type MindooDBAppBridgeConnectMessage as N, type MindooDBAppBridgeConnectOptions as O, type MindooDBAppBridgeConnectedMessage as P, type MindooDBAppBridgeDragDropMessage as Q, type MindooDBAppBridgeDragLeaveMessage as R, type MindooDBAppBridgeDragOverMessage as S, type MindooDBAppBridgeErrorPayload as T, type MindooDBAppBridgeHandshakeErrorMessage as U, type MindooDBAppBridgeHostFocusChangedMessage as V, type MindooDBAppBridgeLocaleChangedMessage as W, type MindooDBAppBridgePortMessage as X, type MindooDBAppBridgeQueryResultMessage as Y, type MindooDBAppBridgeRpcError as Z, type MindooDBAppBridgeRpcMessage as _, type MindooDBAppDragBindSourceOptions as a, type MindooDBAppEntryProvenance as a$, type MindooDBAppBridgeRpcSuccess as a0, type MindooDBAppBridgeShortcutInvokedMessage as a1, type MindooDBAppBridgeShortcutsChangedMessage as a2, type MindooDBAppBridgeStreamAbortRequest as a3, type MindooDBAppBridgeStreamAck as a4, type MindooDBAppBridgeStreamCloseRequest as a5, type MindooDBAppBridgeStreamError as a6, type MindooDBAppBridgeStreamMessage as a7, type MindooDBAppBridgeStreamOpenResult as a8, type MindooDBAppBridgeStreamReadRequest as a9, type MindooDBAppDefinitionDatabase as aA, type MindooDBAppDefinitionListing as aB, type MindooDBAppDefinitionPermission as aC, type MindooDBAppDefinitionRegistrationPermission as aD, type MindooDBAppDefinitionScreenshot as aE, type MindooDBAppDefinitionValidation as aF, type MindooDBAppDirectoryApi as aG, type MindooDBAppDirectoryEntry as aH, type MindooDBAppDocumentApi as aI, type MindooDBAppDocumentHeadCursorResult as aJ, type MindooDBAppDocumentHistoryEntry as aK, type MindooDBAppDocumentListQuery as aL, type MindooDBAppDocumentListResult as aM, type MindooDBAppDocumentQuery as aN, type MindooDBAppDocumentRevisionId as aO, type MindooDBAppDocumentScanPreset as aP, type MindooDBAppDocumentSummary as aQ, type MindooDBAppDragApi as aR, type MindooDBAppDragCancelReason as aS, type MindooDBAppDragDropEvent as aT, type MindooDBAppDragEffect as aU, type MindooDBAppDragHoverResult as aV, type MindooDBAppDragOffer as aW, type MindooDBAppDragOverEvent as aX, type MindooDBAppDragPointer as aY, type MindooDBAppDragProfile as aZ, type MindooDBAppEntryAttachmentRef as a_, type MindooDBAppBridgeStreamWriteRequest as aa, type MindooDBAppBridgeThemeChangedMessage as ab, type MindooDBAppBridgeUiPreferencesChangedMessage as ac, type MindooDBAppBridgeViewChangedMessage as ad, type MindooDBAppBridgeViewportChangedMessage as ae, type MindooDBAppBridgeWorkspaceFocusRequestedMessage as af, type MindooDBAppCapability as ag, type MindooDBAppConfiguredViewCategorizationStyle as ah, type MindooDBAppConfiguredViewColumn as ai, type MindooDBAppConfiguredViewColumnRole as aj, type MindooDBAppConfiguredViewExpressionMode as ak, type MindooDBAppConfiguredViewFieldExpression as al, type MindooDBAppConfiguredViewFilterDefinition as am, type MindooDBAppConfiguredViewFilterMode as an, type MindooDBAppConfiguredViewFilterRule as ao, type MindooDBAppConfiguredViewFormulaExpression as ap, type MindooDBAppConfiguredViewFormulaFilterDefinition as aq, type MindooDBAppConfiguredViewPreviewMode as ar, type MindooDBAppConfiguredViewRuleFilterDefinition as as, type MindooDBAppConfiguredViewRuleMatchMode as at, type MindooDBAppConfiguredViewRuleOperator as au, type MindooDBAppConfiguredViewValueExpression as av, type MindooDBAppCreateKeyInfo as aw, type MindooDBAppCreateViewInput as ax, type MindooDBAppCreateViewNavigatorInput as ay, type MindooDBAppDatabaseInfo as az, type MindooDBAppDragStartInput as b, type MindooDBAppRichTextSpliceStep as b$, type MindooDBAppExtractDocumentTextInput as b0, type MindooDBAppExtractDocumentTextResult as b1, type MindooDBAppExtractTextFormat as b2, type MindooDBAppExtractionSetup as b3, type MindooDBAppFulltextSetup as b4, type MindooDBAppHistoricalDocument as b5, type MindooDBAppHistoryQuery as b6, type MindooDBAppHostTheme as b7, type MindooDBAppIdentityApi as b8, type MindooDBAppInaccessibleDocument as b9, type MindooDBAppMenuSeparatorItem as bA, type MindooDBAppNotificationSeverity as bB, type MindooDBAppNotifyInput as bC, type MindooDBAppNotifyResult as bD, type MindooDBAppProposeAppInput as bE, type MindooDBAppProposeAppResult as bF, type MindooDBAppQueryCoverage as bG, type MindooDBAppQueryInclude as bH, type MindooDBAppQueryIncludeCardinality as bI, type MindooDBAppQueryIncludeSlots as bJ, type MindooDBAppQueryResult as bK, type MindooDBAppQueryRow as bL, type MindooDBAppQuerySortKey as bM, type MindooDBAppQueryTextClause as bN, type MindooDBAppReadableAttachmentStream as bO, type MindooDBAppRecipientOptions as bP, type MindooDBAppResolvedViewDefinition as bQ, type MindooDBAppResolvedViewSource as bR, type MindooDBAppRevisionPhase as bS, type MindooDBAppRevisionVerification as bT, type MindooDBAppRichTextBlockSpan as bU, type MindooDBAppRichTextGetOptions as bV, type MindooDBAppRichTextImmutableString as bW, type MindooDBAppRichTextMarkRange as bX, type MindooDBAppRichTextMaterializeValue as bY, type MindooDBAppRichTextPatch as bZ, type MindooDBAppRichTextScalar as b_, type MindooDBAppInaccessibleDocumentListQuery as ba, type MindooDBAppInaccessibleDocumentListResult as bb, type MindooDBAppJsonCounterIncrementPatch as bc, type MindooDBAppJsonListDeletePatch as bd, type MindooDBAppJsonListInsertPatch as be, type MindooDBAppJsonPatch as bf, type MindooDBAppJsonSetPatch as bg, type MindooDBAppJsonTextMarkPatch as bh, type MindooDBAppJsonTextSplicePatch as bi, type MindooDBAppJsonTextUnmarkPatch as bj, type MindooDBAppJsonUnsetPatch as bk, type MindooDBAppLaunchContext as bl, type MindooDBAppLiveQuerySubscription as bm, type MindooDBAppLocalizedText as bn, type MindooDBAppMenuAnchor as bo, type MindooDBAppMenuApi as bp, type MindooDBAppMenuCommandItem as bq, type MindooDBAppMenuDismissReason as br, type MindooDBAppMenuDismissedResult as bs, type MindooDBAppMenuItem as bt, type MindooDBAppMenuKind as bu, type MindooDBAppMenuPlacement as bv, type MindooDBAppMenuPointAnchor as bw, type MindooDBAppMenuRect as bx, type MindooDBAppMenuRectAnchor as by, type MindooDBAppMenuSelectionResult as bz, type MindooDBAppDragStartResult as c, type MindooDBAppRichTextStep as c0, type MindooDBAppRichTextStepPatch as c1, type MindooDBAppRichTextTextSpan as c2, type MindooDBAppRuntime as c3, type MindooDBAppScanAttachmentOptions as c4, type MindooDBAppScanAttachmentResult as c5, type MindooDBAppScopedDocId as c6, type MindooDBAppScopedDocumentSummary as c7, type MindooDBAppSealIntent as c8, type MindooDBAppSealedChannelOpenInput as c9, type MindooDBAppViewEntry as cA, type MindooDBAppViewEntryKind as cB, type MindooDBAppViewNavigator as cC, type MindooDBAppViewNavigatorExpansionState as cD, type MindooDBAppViewNavigatorOpenOptions as cE, type MindooDBAppViewNavigatorPageOptions as cF, type MindooDBAppViewNavigatorPageResult as cG, type MindooDBAppViewNavigatorRangeQuery as cH, type MindooDBAppViewNavigatorSelectionState as cI, type MindooDBAppViewUpdateStats as cJ, type MindooDBAppViewport as cK, type MindooDBAppWellKnownDragType as cL, type MindooDBAppWritableAttachmentStream as cM, resolveMindooDBAppDefinitionUrl as cN, resolveMindooDBAppListingAssetUrl as cO, resolveMindooDBAppLocalizedText as cP, validateMindooDBAppDefinition as cQ, type MindooDBAppSealedChannelOpenResult as ca, type MindooDBAppSealedChannelRequestInput as cb, type MindooDBAppSession as cc, type MindooDBAppShowMenuInput as cd, type MindooDBAppShowMenuResult as ce, type MindooDBAppSignPreview as cf, type MindooDBAppSignPreviewScope as cg, type MindooDBAppSignStatementInput as ch, type MindooDBAppSignStatementResult as ci, type MindooDBAppStorageApi as cj, type MindooDBAppSummarySetup as ck, type MindooDBAppTextCursorOptions as cl, type MindooDBAppTextCursorPosition as cm, type MindooDBAppTextCursorPositionsResult as cn, type MindooDBAppTextCursorsResult as co, type MindooDBAppTextEdit as cp, type MindooDBAppTextPatch as cq, type MindooDBAppThemeMode as cr, type MindooDBAppTimestampApi as cs, type MindooDBAppTimestampInput as ct, type MindooDBAppTimestampProvider as cu, type MindooDBAppTimestampResult as cv, type MindooDBAppUiPreferences as cw, type MindooDBAppUpdateDocumentInput as cx, type MindooDBAppViewCursorDocumentListResult as cy, type MindooDBAppViewCursorResult as cz, type MindooDBAppDragPreview as d, type MindooDBAppBridge as e, type MindooDBAppHostShortcutBinding as f, type MindooDBAppHostShortcutAction as g, type MindooDBAppHostingMode as h, type MindooDBAppDefinition as i, type MindooDBAppDatabase as j, type MindooDBAppDocument as k, type MindooDBAppRichTextSpan as l, type MindooDBAppRichTextSnapshot as m, type MindooDBAppCreateDocumentInput as n, MINDOODB_APP_DEFINITION_FILE_NAME as o, MINDOODB_APP_DEFINITION_FORMAT as p, MINDOODB_APP_DEFINITION_PERMISSIONS as q, MINDOODB_APP_DEFINITION_REGISTRATION_PERMISSIONS as r, MINDOODB_APP_DEFINITION_VERSION as s, MINDOODB_APP_LISTING_DESCRIPTION_MAX as t, MINDOODB_APP_LISTING_MAX_SCREENSHOTS as u, MINDOODB_APP_LISTING_SUMMARY_MAX as v, MINDOODB_APP_SEAL_SIGNING_DOMAIN as w, MINDOODB_APP_WELL_KNOWN_DRAG_TYPES as x, type MindooDBAppAccessDecision as y, type MindooDBAppAccessTier as z };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mindoodb-app-sdk",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.53",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=22.13.0"
|
|
6
6
|
},
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"@automerge/automerge": "^3.3.2",
|
|
48
|
-
"mindoodb": ">=0.0.
|
|
48
|
+
"mindoodb": ">=0.0.69"
|
|
49
49
|
},
|
|
50
50
|
"peerDependenciesMeta": {
|
|
51
51
|
"@automerge/automerge": {
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@automerge/automerge": "^3.3.2",
|
|
60
|
-
"mindoodb": "^0.0.
|
|
60
|
+
"mindoodb": "^0.0.69",
|
|
61
61
|
"@types/node": "25.5.0",
|
|
62
62
|
"jsdom": "^29.0.1",
|
|
63
63
|
"tsup": "^8.5.1",
|