calmlens 0.20.0 → 0.22.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/README.md +15 -10
- package/bin/calmlens.js +1848 -679
- package/cjs/{BrowserUpload-C07aL9Vq.d.ts → BrowserUpload-BWjZ9ntu.d.ts} +2 -2
- package/cjs/{BrowserUpload-CjSHjx3C.js → BrowserUpload-Bwlib4Zc.js} +1 -1
- package/cjs/{CalmLensAppClient-DDLojj0P.d.ts → CalmLensAppClient-BaW3ddUR.d.ts} +13 -3
- package/cjs/{CalmLensAppClient-NaCxOVlM.js → CalmLensAppClient-DUYMo9PZ.js} +30 -10
- package/cjs/{CalmLensOptionKeys-p2QK687A.js → CalmLensOptionKeys-YvgV995V.js} +318 -374
- package/cjs/{CalmLensServerClient-BDzTthxE.js → CalmLensServerClient-3N-gdsxC.js} +346 -89
- package/cjs/CalmLensServerClient-BKzn8zmp.d.ts +353 -0
- package/cjs/{CalmLensTypes-COJbOuiv.d.ts → CalmLensTypes-BDKwThbO.d.ts} +26993 -27187
- package/cjs/{Classification-D3SkprrQ-CMnQKW13.d.ts → Classification-Q5zGpR8l-CEWjnE39.d.ts} +731 -607
- package/cjs/Core-C33pkBmf.d.ts +826 -0
- package/cjs/Core-Cm5Z1oJ9.js +1001 -0
- package/cjs/FileIcons-4qSX7DW2.d.ts +67 -0
- package/cjs/{ModerationContextLimits-2nIv7Zh3.js → ModerationContextLimits-ud1xpZRK.js} +727 -268
- package/cjs/{ReactUpload-BdTRCTGA.js → ReactUpload-DQ0BYISX.js} +1 -1
- package/cjs/{ReactUpload-CRJNPB5T.d.ts → ReactUpload-DhF8mm51.d.ts} +1 -1
- package/{esm/TestTriggers-D-fwfhEP-hlaP1oW2.d.ts → cjs/TestTriggers-D0pYHbkr-D5T0VdSn.d.ts} +146 -8
- package/cjs/{TestTriggers-DbhsNPdg-DjvVuc2h.js → TestTriggers-D29T_R0M-D6Bu-Mln.js} +355 -47
- package/cjs/{UploadController-MLVs97Zt.js → UploadController-l8fZM2qT.js} +34 -14
- package/{esm/WebhookPayload-DkukERKE.d.ts → cjs/WebhookPayload-Dt6DttS0.d.ts} +120 -86
- package/cjs/app.d.ts +6 -7
- package/cjs/app.js +4 -3
- package/cjs/elements.d.ts +123 -22
- package/cjs/elements.js +553 -156
- package/cjs/file-icons.d.ts +2 -67
- package/cjs/index-Bde1wjiw.d.ts +16 -0
- package/cjs/index.d.ts +5 -6
- package/cjs/index.js +3 -2
- package/cjs/react-native.d.ts +52 -11
- package/cjs/react-native.js +231 -99
- package/cjs/react.d.ts +42 -9
- package/cjs/react.js +381 -118
- package/cjs/server.d.ts +48 -7
- package/cjs/server.js +7 -3
- package/cjs/test-inputs.d.ts +2 -2
- package/cjs/test-inputs.js +13 -9
- package/cjs/testing.d.ts +29 -15
- package/cjs/testing.js +1722 -433
- package/cjs/ui-BRA4HQ8r.js +1359 -0
- package/cjs/ui-YQuvbidU.d.ts +139 -0
- package/cjs/ui.d.ts +3 -2
- package/cjs/ui.js +45 -22
- package/cjs/vue.d.ts +802 -199
- package/cjs/vue.js +359 -127
- package/esm/{BrowserUpload-C07aL9Vq.d.ts → BrowserUpload-BWjZ9ntu.d.ts} +2 -2
- package/esm/{BrowserUpload-CAVkRotw.js → BrowserUpload-GRZVB0G_.js} +1 -1
- package/esm/{CalmLensAppClient-PQ9VBvlW.js → CalmLensAppClient-B5QIJ6KS.js} +30 -10
- package/esm/{CalmLensAppClient-DDLojj0P.d.ts → CalmLensAppClient-BaW3ddUR.d.ts} +13 -3
- package/esm/{CalmLensOptionKeys-Do2mPP6w.js → CalmLensOptionKeys-BG7Qrh8-.js} +317 -367
- package/esm/CalmLensServerClient-BKzn8zmp.d.ts +353 -0
- package/esm/{CalmLensServerClient-C_H5aAsV.js → CalmLensServerClient-bRUAebi-.js} +323 -90
- package/esm/{CalmLensTypes-COJbOuiv.d.ts → CalmLensTypes-BDKwThbO.d.ts} +26993 -27187
- package/esm/{Classification-D3SkprrQ-CMnQKW13.d.ts → Classification-Q5zGpR8l-CEWjnE39.d.ts} +731 -607
- package/esm/Core-BvQe4moS.js +846 -0
- package/esm/Core-C33pkBmf.d.ts +826 -0
- package/esm/FileIcons-4qSX7DW2.d.ts +67 -0
- package/esm/{ModerationContextLimits-Chw-AzgL.js → ModerationContextLimits-CrxSnVZ3.js} +682 -253
- package/esm/{ReactUpload-CMmL0R5Q.js → ReactUpload-BMO8saxT.js} +1 -1
- package/esm/{ReactUpload-CRJNPB5T.d.ts → ReactUpload-DhF8mm51.d.ts} +1 -1
- package/{cjs/TestTriggers-D-fwfhEP-hlaP1oW2.d.ts → esm/TestTriggers-D0pYHbkr-D5T0VdSn.d.ts} +146 -8
- package/esm/{TestTriggers-DbhsNPdg-CUdrv8Nm.js → TestTriggers-D29T_R0M-Ztc74ucs.js} +332 -48
- package/esm/{UploadController-BJZghJpg.js → UploadController-DnJrWiE4.js} +34 -14
- package/{cjs/WebhookPayload-DkukERKE.d.ts → esm/WebhookPayload-Dt6DttS0.d.ts} +120 -86
- package/esm/app.d.ts +6 -7
- package/esm/app.js +3 -3
- package/esm/elements.d.ts +123 -22
- package/esm/elements.js +497 -128
- package/esm/file-icons.d.ts +2 -67
- package/esm/index-Bde1wjiw.d.ts +16 -0
- package/esm/index.d.ts +5 -6
- package/esm/index.js +1 -1
- package/esm/react-native.d.ts +52 -11
- package/esm/react-native.js +205 -75
- package/esm/react.d.ts +42 -9
- package/esm/react.js +327 -91
- package/esm/server.d.ts +48 -7
- package/esm/server.js +3 -3
- package/esm/styles.css +142 -22
- package/esm/svelte/AssetViewer.svelte +25 -0
- package/esm/svelte/CalmLensAsset.svelte +318 -0
- package/esm/svelte/CalmLensDocumentViewer.svelte +7 -0
- package/esm/svelte/CalmLensImageViewer.svelte +7 -0
- package/esm/svelte/CalmLensSpreadsheetViewer.svelte +7 -0
- package/esm/svelte/CalmLensTextViewer.svelte +7 -0
- package/esm/svelte/CalmLensWebsiteViewer.svelte +7 -0
- package/esm/svelte/index.d.ts +29 -6
- package/esm/svelte/index.js +7 -2
- package/esm/test-inputs.d.ts +2 -2
- package/esm/test-inputs.js +1 -1
- package/esm/testing.d.ts +29 -15
- package/esm/testing.js +1718 -429
- package/esm/ui-YQuvbidU.d.ts +139 -0
- package/esm/ui-heryDd6g.js +1258 -0
- package/esm/ui.d.ts +3 -2
- package/esm/ui.js +4 -3
- package/esm/vue.d.ts +802 -199
- package/esm/vue.js +308 -103
- package/package.json +4 -2
- package/cjs/CalmLensServerClient-C-jsjn8m.d.ts +0 -259
- package/cjs/ModerationContext-9lGm-Mna-CcmbRnOy.d.ts +0 -67
- package/cjs/index-DxbJ_Xaa.d.ts +0 -253
- package/cjs/ui-BSqPGKrZ.d.ts +0 -539
- package/cjs/ui-CX1z2pD9.js +0 -586
- package/esm/CalmLensServerClient-C-jsjn8m.d.ts +0 -259
- package/esm/ModerationContext-9lGm-Mna-CcmbRnOy.d.ts +0 -67
- package/esm/index-DxbJ_Xaa.d.ts +0 -253
- package/esm/svelte/CalmLensMedia.svelte +0 -134
- package/esm/ui-BSqPGKrZ.d.ts +0 -539
- package/esm/ui-CXH7xJpb.js +0 -461
package/cjs/vue.d.ts
CHANGED
|
@@ -1,8 +1,709 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "./index-
|
|
3
|
-
import { A as
|
|
4
|
-
import { a as UploaderProps, i as UploadSnapshot, n as UploadControllerOptions, r as UploadItem, s as createUploadController, t as CalmLensUpload } from "./BrowserUpload-
|
|
1
|
+
import { D as CalmLensAppClientOptions, h as AssetModerationStatus, r as AssetAvailability, sn as ViewerClaims } from "./CalmLensTypes-BDKwThbO.js";
|
|
2
|
+
import "./index-Bde1wjiw.js";
|
|
3
|
+
import { $ as getAssetViewKey, A as CustomUploadResult, B as AssetDisplay, C as formatMessage, D as resolveMessages, E as getUploadItemOutcome, G as AssetSession, H as AssetImageOptions, J as AssetVideoOptions, K as AssetSessionState, L as UploadStage, M as UploadController, P as UploadFile, Q as getAssetView, S as formatBytes, T as getUploadItemMessage, U as AssetImageSource, V as AssetDocumentOptions, W as AssetOptions, X as MediaPlayback, Y as AssetView, Z as getAssetAspectRatio, _ as DEFAULT_MESSAGES, _t as formatViewerMessage, a as ProgressFetchOptions, at as ImageViewerOptions, b as describeUploadItem, c as ICON_ATTRIBUTES, ct as TextViewerOptions, d as AssetDisplayOptions, dt as ViewerTextOptions, et as getPeakHeights, f as AssetEventHandlers, ft as WebsiteViewerOptions, g as CalmLensMessages, gt as ViewerMessages, ht as DEFAULT_VIEWER_MESSAGES, i as CALMLENS_STYLES, it as DocumentViewerOptions, j as UploadClient, k as CustomUploadContext, l as IconName, lt as ViewerAsset, m as UploaderDisplayOptions, mt as isSpreadsheetFormat, n as CalmLensTheme, nt as pickAssetSource, o as createProgressFetch, ot as PdfAssetOptions, p as AssetProps, pt as getAssetViewerKind, q as AssetSpreadsheetOptions, r as resolveTheme, rt as AssetViewerKind, s as ICONS, st as SpreadsheetViewerOptions, t as CALMLENS_THEME, tt as getPlayedPercent, u as ASSET_FILE_ICON_SIZE, ut as ViewerOptions, v as UploadItemView, vt as resolveViewerMessages, w as getDropzoneHint, x as describeUploader, y as UploaderView, z as isFileAccepted } from "./Core-C33pkBmf.js";
|
|
4
|
+
import { a as UploaderProps, i as UploadSnapshot, n as UploadControllerOptions, r as UploadItem, s as createUploadController, t as CalmLensUpload } from "./BrowserUpload-BWjZ9ntu.js";
|
|
5
|
+
import { C as ViewerState, S as AssetViewer, _ as spreadsheetColumnIndex, a as isMountedViewerKind, b as createWebsiteViewer, c as AssetViewerOptionsByKind, d as createTextViewer, f as SpreadsheetCell, g as parseSpreadsheetText, h as getSpreadsheetPage, i as getMountedViewerOptions, l as VIEWER_STYLES, m as SpreadsheetSheet, n as AssetViewerMount, o as ASSET_VIEWERS, p as SpreadsheetRow, r as MountedViewerKind, s as AssetViewerName, t as MediaStreamPlayer, u as createSpreadsheetViewer, v as loadPdfJs, x as createDocumentViewer, y as createImageViewer } from "./ui-YQuvbidU.js";
|
|
5
6
|
import { MaybeRefOrGetter, PropType, ShallowRef } from "vue";
|
|
7
|
+
/** Shows an image asset's rendered file, fitted to the element, over its placeholder. */
|
|
8
|
+
export declare const CalmLensImageViewer: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
9
|
+
/** The asset URL, public or signed. */
|
|
10
|
+
src: {
|
|
11
|
+
type: StringConstructor;
|
|
12
|
+
required: true;
|
|
13
|
+
};
|
|
14
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
15
|
+
asset: {
|
|
16
|
+
type: PropType<ViewerAsset>;
|
|
17
|
+
required: true;
|
|
18
|
+
};
|
|
19
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
20
|
+
onExpired: {
|
|
21
|
+
type: PropType<() => string | Promise<string>>;
|
|
22
|
+
default: undefined;
|
|
23
|
+
};
|
|
24
|
+
onUnavailable: {
|
|
25
|
+
type: PropType<() => void>;
|
|
26
|
+
default: undefined;
|
|
27
|
+
};
|
|
28
|
+
viewerClaims: {
|
|
29
|
+
type: PropType<ViewerClaims>;
|
|
30
|
+
default: undefined;
|
|
31
|
+
};
|
|
32
|
+
label: {
|
|
33
|
+
type: PropType<string>;
|
|
34
|
+
default: undefined;
|
|
35
|
+
};
|
|
36
|
+
messages: {
|
|
37
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
38
|
+
default: undefined;
|
|
39
|
+
};
|
|
40
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
41
|
+
sizes: {
|
|
42
|
+
type: PropType<string>;
|
|
43
|
+
default: undefined;
|
|
44
|
+
};
|
|
45
|
+
/** Text and spreadsheets: text your app already has. */
|
|
46
|
+
text: {
|
|
47
|
+
type: PropType<string>;
|
|
48
|
+
default: undefined;
|
|
49
|
+
};
|
|
50
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
51
|
+
getText: {
|
|
52
|
+
type: PropType<() => Promise<string>>;
|
|
53
|
+
default: undefined;
|
|
54
|
+
};
|
|
55
|
+
/** Spreadsheets: rows shown at a time. */
|
|
56
|
+
pageSize: {
|
|
57
|
+
type: PropType<number>;
|
|
58
|
+
default: undefined;
|
|
59
|
+
};
|
|
60
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
61
|
+
pdf: {
|
|
62
|
+
type: PropType<PdfAssetOptions>;
|
|
63
|
+
default: undefined;
|
|
64
|
+
};
|
|
65
|
+
/** Documents: the page shown first. */
|
|
66
|
+
initialPage: {
|
|
67
|
+
type: PropType<number>;
|
|
68
|
+
default: undefined;
|
|
69
|
+
};
|
|
70
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
71
|
+
[key: string]: any;
|
|
72
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
73
|
+
/** The asset URL, public or signed. */
|
|
74
|
+
src: {
|
|
75
|
+
type: StringConstructor;
|
|
76
|
+
required: true;
|
|
77
|
+
};
|
|
78
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
79
|
+
asset: {
|
|
80
|
+
type: PropType<ViewerAsset>;
|
|
81
|
+
required: true;
|
|
82
|
+
};
|
|
83
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
84
|
+
onExpired: {
|
|
85
|
+
type: PropType<() => string | Promise<string>>;
|
|
86
|
+
default: undefined;
|
|
87
|
+
};
|
|
88
|
+
onUnavailable: {
|
|
89
|
+
type: PropType<() => void>;
|
|
90
|
+
default: undefined;
|
|
91
|
+
};
|
|
92
|
+
viewerClaims: {
|
|
93
|
+
type: PropType<ViewerClaims>;
|
|
94
|
+
default: undefined;
|
|
95
|
+
};
|
|
96
|
+
label: {
|
|
97
|
+
type: PropType<string>;
|
|
98
|
+
default: undefined;
|
|
99
|
+
};
|
|
100
|
+
messages: {
|
|
101
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
102
|
+
default: undefined;
|
|
103
|
+
};
|
|
104
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
105
|
+
sizes: {
|
|
106
|
+
type: PropType<string>;
|
|
107
|
+
default: undefined;
|
|
108
|
+
};
|
|
109
|
+
/** Text and spreadsheets: text your app already has. */
|
|
110
|
+
text: {
|
|
111
|
+
type: PropType<string>;
|
|
112
|
+
default: undefined;
|
|
113
|
+
};
|
|
114
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
115
|
+
getText: {
|
|
116
|
+
type: PropType<() => Promise<string>>;
|
|
117
|
+
default: undefined;
|
|
118
|
+
};
|
|
119
|
+
/** Spreadsheets: rows shown at a time. */
|
|
120
|
+
pageSize: {
|
|
121
|
+
type: PropType<number>;
|
|
122
|
+
default: undefined;
|
|
123
|
+
};
|
|
124
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
125
|
+
pdf: {
|
|
126
|
+
type: PropType<PdfAssetOptions>;
|
|
127
|
+
default: undefined;
|
|
128
|
+
};
|
|
129
|
+
/** Documents: the page shown first. */
|
|
130
|
+
initialPage: {
|
|
131
|
+
type: PropType<number>;
|
|
132
|
+
default: undefined;
|
|
133
|
+
};
|
|
134
|
+
}>> & Readonly<{}>, {
|
|
135
|
+
onExpired: () => string | Promise<string>;
|
|
136
|
+
onUnavailable: () => void;
|
|
137
|
+
viewerClaims: ViewerClaims;
|
|
138
|
+
label: string;
|
|
139
|
+
messages: Partial<ViewerMessages>;
|
|
140
|
+
sizes: string;
|
|
141
|
+
text: string;
|
|
142
|
+
getText: () => Promise<string>;
|
|
143
|
+
pageSize: number;
|
|
144
|
+
pdf: PdfAssetOptions;
|
|
145
|
+
initialPage: number;
|
|
146
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
147
|
+
/** Shows a website asset's screenshot with a link to the original page. */
|
|
148
|
+
export declare const CalmLensWebsiteViewer: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
149
|
+
/** The asset URL, public or signed. */
|
|
150
|
+
src: {
|
|
151
|
+
type: StringConstructor;
|
|
152
|
+
required: true;
|
|
153
|
+
};
|
|
154
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
155
|
+
asset: {
|
|
156
|
+
type: PropType<ViewerAsset>;
|
|
157
|
+
required: true;
|
|
158
|
+
};
|
|
159
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
160
|
+
onExpired: {
|
|
161
|
+
type: PropType<() => string | Promise<string>>;
|
|
162
|
+
default: undefined;
|
|
163
|
+
};
|
|
164
|
+
onUnavailable: {
|
|
165
|
+
type: PropType<() => void>;
|
|
166
|
+
default: undefined;
|
|
167
|
+
};
|
|
168
|
+
viewerClaims: {
|
|
169
|
+
type: PropType<ViewerClaims>;
|
|
170
|
+
default: undefined;
|
|
171
|
+
};
|
|
172
|
+
label: {
|
|
173
|
+
type: PropType<string>;
|
|
174
|
+
default: undefined;
|
|
175
|
+
};
|
|
176
|
+
messages: {
|
|
177
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
178
|
+
default: undefined;
|
|
179
|
+
};
|
|
180
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
181
|
+
sizes: {
|
|
182
|
+
type: PropType<string>;
|
|
183
|
+
default: undefined;
|
|
184
|
+
};
|
|
185
|
+
/** Text and spreadsheets: text your app already has. */
|
|
186
|
+
text: {
|
|
187
|
+
type: PropType<string>;
|
|
188
|
+
default: undefined;
|
|
189
|
+
};
|
|
190
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
191
|
+
getText: {
|
|
192
|
+
type: PropType<() => Promise<string>>;
|
|
193
|
+
default: undefined;
|
|
194
|
+
};
|
|
195
|
+
/** Spreadsheets: rows shown at a time. */
|
|
196
|
+
pageSize: {
|
|
197
|
+
type: PropType<number>;
|
|
198
|
+
default: undefined;
|
|
199
|
+
};
|
|
200
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
201
|
+
pdf: {
|
|
202
|
+
type: PropType<PdfAssetOptions>;
|
|
203
|
+
default: undefined;
|
|
204
|
+
};
|
|
205
|
+
/** Documents: the page shown first. */
|
|
206
|
+
initialPage: {
|
|
207
|
+
type: PropType<number>;
|
|
208
|
+
default: undefined;
|
|
209
|
+
};
|
|
210
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
211
|
+
[key: string]: any;
|
|
212
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
213
|
+
/** The asset URL, public or signed. */
|
|
214
|
+
src: {
|
|
215
|
+
type: StringConstructor;
|
|
216
|
+
required: true;
|
|
217
|
+
};
|
|
218
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
219
|
+
asset: {
|
|
220
|
+
type: PropType<ViewerAsset>;
|
|
221
|
+
required: true;
|
|
222
|
+
};
|
|
223
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
224
|
+
onExpired: {
|
|
225
|
+
type: PropType<() => string | Promise<string>>;
|
|
226
|
+
default: undefined;
|
|
227
|
+
};
|
|
228
|
+
onUnavailable: {
|
|
229
|
+
type: PropType<() => void>;
|
|
230
|
+
default: undefined;
|
|
231
|
+
};
|
|
232
|
+
viewerClaims: {
|
|
233
|
+
type: PropType<ViewerClaims>;
|
|
234
|
+
default: undefined;
|
|
235
|
+
};
|
|
236
|
+
label: {
|
|
237
|
+
type: PropType<string>;
|
|
238
|
+
default: undefined;
|
|
239
|
+
};
|
|
240
|
+
messages: {
|
|
241
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
242
|
+
default: undefined;
|
|
243
|
+
};
|
|
244
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
245
|
+
sizes: {
|
|
246
|
+
type: PropType<string>;
|
|
247
|
+
default: undefined;
|
|
248
|
+
};
|
|
249
|
+
/** Text and spreadsheets: text your app already has. */
|
|
250
|
+
text: {
|
|
251
|
+
type: PropType<string>;
|
|
252
|
+
default: undefined;
|
|
253
|
+
};
|
|
254
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
255
|
+
getText: {
|
|
256
|
+
type: PropType<() => Promise<string>>;
|
|
257
|
+
default: undefined;
|
|
258
|
+
};
|
|
259
|
+
/** Spreadsheets: rows shown at a time. */
|
|
260
|
+
pageSize: {
|
|
261
|
+
type: PropType<number>;
|
|
262
|
+
default: undefined;
|
|
263
|
+
};
|
|
264
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
265
|
+
pdf: {
|
|
266
|
+
type: PropType<PdfAssetOptions>;
|
|
267
|
+
default: undefined;
|
|
268
|
+
};
|
|
269
|
+
/** Documents: the page shown first. */
|
|
270
|
+
initialPage: {
|
|
271
|
+
type: PropType<number>;
|
|
272
|
+
default: undefined;
|
|
273
|
+
};
|
|
274
|
+
}>> & Readonly<{}>, {
|
|
275
|
+
onExpired: () => string | Promise<string>;
|
|
276
|
+
onUnavailable: () => void;
|
|
277
|
+
viewerClaims: ViewerClaims;
|
|
278
|
+
label: string;
|
|
279
|
+
messages: Partial<ViewerMessages>;
|
|
280
|
+
sizes: string;
|
|
281
|
+
text: string;
|
|
282
|
+
getText: () => Promise<string>;
|
|
283
|
+
pageSize: number;
|
|
284
|
+
pdf: PdfAssetOptions;
|
|
285
|
+
initialPage: number;
|
|
286
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
287
|
+
/** Shows a text asset's text, escaped, in a scrolling region. */
|
|
288
|
+
export declare const CalmLensTextViewer: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
289
|
+
/** The asset URL, public or signed. */
|
|
290
|
+
src: {
|
|
291
|
+
type: StringConstructor;
|
|
292
|
+
required: true;
|
|
293
|
+
};
|
|
294
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
295
|
+
asset: {
|
|
296
|
+
type: PropType<ViewerAsset>;
|
|
297
|
+
required: true;
|
|
298
|
+
};
|
|
299
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
300
|
+
onExpired: {
|
|
301
|
+
type: PropType<() => string | Promise<string>>;
|
|
302
|
+
default: undefined;
|
|
303
|
+
};
|
|
304
|
+
onUnavailable: {
|
|
305
|
+
type: PropType<() => void>;
|
|
306
|
+
default: undefined;
|
|
307
|
+
};
|
|
308
|
+
viewerClaims: {
|
|
309
|
+
type: PropType<ViewerClaims>;
|
|
310
|
+
default: undefined;
|
|
311
|
+
};
|
|
312
|
+
label: {
|
|
313
|
+
type: PropType<string>;
|
|
314
|
+
default: undefined;
|
|
315
|
+
};
|
|
316
|
+
messages: {
|
|
317
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
318
|
+
default: undefined;
|
|
319
|
+
};
|
|
320
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
321
|
+
sizes: {
|
|
322
|
+
type: PropType<string>;
|
|
323
|
+
default: undefined;
|
|
324
|
+
};
|
|
325
|
+
/** Text and spreadsheets: text your app already has. */
|
|
326
|
+
text: {
|
|
327
|
+
type: PropType<string>;
|
|
328
|
+
default: undefined;
|
|
329
|
+
};
|
|
330
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
331
|
+
getText: {
|
|
332
|
+
type: PropType<() => Promise<string>>;
|
|
333
|
+
default: undefined;
|
|
334
|
+
};
|
|
335
|
+
/** Spreadsheets: rows shown at a time. */
|
|
336
|
+
pageSize: {
|
|
337
|
+
type: PropType<number>;
|
|
338
|
+
default: undefined;
|
|
339
|
+
};
|
|
340
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
341
|
+
pdf: {
|
|
342
|
+
type: PropType<PdfAssetOptions>;
|
|
343
|
+
default: undefined;
|
|
344
|
+
};
|
|
345
|
+
/** Documents: the page shown first. */
|
|
346
|
+
initialPage: {
|
|
347
|
+
type: PropType<number>;
|
|
348
|
+
default: undefined;
|
|
349
|
+
};
|
|
350
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
351
|
+
[key: string]: any;
|
|
352
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
353
|
+
/** The asset URL, public or signed. */
|
|
354
|
+
src: {
|
|
355
|
+
type: StringConstructor;
|
|
356
|
+
required: true;
|
|
357
|
+
};
|
|
358
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
359
|
+
asset: {
|
|
360
|
+
type: PropType<ViewerAsset>;
|
|
361
|
+
required: true;
|
|
362
|
+
};
|
|
363
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
364
|
+
onExpired: {
|
|
365
|
+
type: PropType<() => string | Promise<string>>;
|
|
366
|
+
default: undefined;
|
|
367
|
+
};
|
|
368
|
+
onUnavailable: {
|
|
369
|
+
type: PropType<() => void>;
|
|
370
|
+
default: undefined;
|
|
371
|
+
};
|
|
372
|
+
viewerClaims: {
|
|
373
|
+
type: PropType<ViewerClaims>;
|
|
374
|
+
default: undefined;
|
|
375
|
+
};
|
|
376
|
+
label: {
|
|
377
|
+
type: PropType<string>;
|
|
378
|
+
default: undefined;
|
|
379
|
+
};
|
|
380
|
+
messages: {
|
|
381
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
382
|
+
default: undefined;
|
|
383
|
+
};
|
|
384
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
385
|
+
sizes: {
|
|
386
|
+
type: PropType<string>;
|
|
387
|
+
default: undefined;
|
|
388
|
+
};
|
|
389
|
+
/** Text and spreadsheets: text your app already has. */
|
|
390
|
+
text: {
|
|
391
|
+
type: PropType<string>;
|
|
392
|
+
default: undefined;
|
|
393
|
+
};
|
|
394
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
395
|
+
getText: {
|
|
396
|
+
type: PropType<() => Promise<string>>;
|
|
397
|
+
default: undefined;
|
|
398
|
+
};
|
|
399
|
+
/** Spreadsheets: rows shown at a time. */
|
|
400
|
+
pageSize: {
|
|
401
|
+
type: PropType<number>;
|
|
402
|
+
default: undefined;
|
|
403
|
+
};
|
|
404
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
405
|
+
pdf: {
|
|
406
|
+
type: PropType<PdfAssetOptions>;
|
|
407
|
+
default: undefined;
|
|
408
|
+
};
|
|
409
|
+
/** Documents: the page shown first. */
|
|
410
|
+
initialPage: {
|
|
411
|
+
type: PropType<number>;
|
|
412
|
+
default: undefined;
|
|
413
|
+
};
|
|
414
|
+
}>> & Readonly<{}>, {
|
|
415
|
+
onExpired: () => string | Promise<string>;
|
|
416
|
+
onUnavailable: () => void;
|
|
417
|
+
viewerClaims: ViewerClaims;
|
|
418
|
+
label: string;
|
|
419
|
+
messages: Partial<ViewerMessages>;
|
|
420
|
+
sizes: string;
|
|
421
|
+
text: string;
|
|
422
|
+
getText: () => Promise<string>;
|
|
423
|
+
pageSize: number;
|
|
424
|
+
pdf: PdfAssetOptions;
|
|
425
|
+
initialPage: number;
|
|
426
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
427
|
+
/** Shows a PDF, or a document rendered as one, a page at a time with pdf.js (loaded lazily). */
|
|
428
|
+
export declare const CalmLensDocumentViewer: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
429
|
+
/** The asset URL, public or signed. */
|
|
430
|
+
src: {
|
|
431
|
+
type: StringConstructor;
|
|
432
|
+
required: true;
|
|
433
|
+
};
|
|
434
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
435
|
+
asset: {
|
|
436
|
+
type: PropType<ViewerAsset>;
|
|
437
|
+
required: true;
|
|
438
|
+
};
|
|
439
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
440
|
+
onExpired: {
|
|
441
|
+
type: PropType<() => string | Promise<string>>;
|
|
442
|
+
default: undefined;
|
|
443
|
+
};
|
|
444
|
+
onUnavailable: {
|
|
445
|
+
type: PropType<() => void>;
|
|
446
|
+
default: undefined;
|
|
447
|
+
};
|
|
448
|
+
viewerClaims: {
|
|
449
|
+
type: PropType<ViewerClaims>;
|
|
450
|
+
default: undefined;
|
|
451
|
+
};
|
|
452
|
+
label: {
|
|
453
|
+
type: PropType<string>;
|
|
454
|
+
default: undefined;
|
|
455
|
+
};
|
|
456
|
+
messages: {
|
|
457
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
458
|
+
default: undefined;
|
|
459
|
+
};
|
|
460
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
461
|
+
sizes: {
|
|
462
|
+
type: PropType<string>;
|
|
463
|
+
default: undefined;
|
|
464
|
+
};
|
|
465
|
+
/** Text and spreadsheets: text your app already has. */
|
|
466
|
+
text: {
|
|
467
|
+
type: PropType<string>;
|
|
468
|
+
default: undefined;
|
|
469
|
+
};
|
|
470
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
471
|
+
getText: {
|
|
472
|
+
type: PropType<() => Promise<string>>;
|
|
473
|
+
default: undefined;
|
|
474
|
+
};
|
|
475
|
+
/** Spreadsheets: rows shown at a time. */
|
|
476
|
+
pageSize: {
|
|
477
|
+
type: PropType<number>;
|
|
478
|
+
default: undefined;
|
|
479
|
+
};
|
|
480
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
481
|
+
pdf: {
|
|
482
|
+
type: PropType<PdfAssetOptions>;
|
|
483
|
+
default: undefined;
|
|
484
|
+
};
|
|
485
|
+
/** Documents: the page shown first. */
|
|
486
|
+
initialPage: {
|
|
487
|
+
type: PropType<number>;
|
|
488
|
+
default: undefined;
|
|
489
|
+
};
|
|
490
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
491
|
+
[key: string]: any;
|
|
492
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
493
|
+
/** The asset URL, public or signed. */
|
|
494
|
+
src: {
|
|
495
|
+
type: StringConstructor;
|
|
496
|
+
required: true;
|
|
497
|
+
};
|
|
498
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
499
|
+
asset: {
|
|
500
|
+
type: PropType<ViewerAsset>;
|
|
501
|
+
required: true;
|
|
502
|
+
};
|
|
503
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
504
|
+
onExpired: {
|
|
505
|
+
type: PropType<() => string | Promise<string>>;
|
|
506
|
+
default: undefined;
|
|
507
|
+
};
|
|
508
|
+
onUnavailable: {
|
|
509
|
+
type: PropType<() => void>;
|
|
510
|
+
default: undefined;
|
|
511
|
+
};
|
|
512
|
+
viewerClaims: {
|
|
513
|
+
type: PropType<ViewerClaims>;
|
|
514
|
+
default: undefined;
|
|
515
|
+
};
|
|
516
|
+
label: {
|
|
517
|
+
type: PropType<string>;
|
|
518
|
+
default: undefined;
|
|
519
|
+
};
|
|
520
|
+
messages: {
|
|
521
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
522
|
+
default: undefined;
|
|
523
|
+
};
|
|
524
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
525
|
+
sizes: {
|
|
526
|
+
type: PropType<string>;
|
|
527
|
+
default: undefined;
|
|
528
|
+
};
|
|
529
|
+
/** Text and spreadsheets: text your app already has. */
|
|
530
|
+
text: {
|
|
531
|
+
type: PropType<string>;
|
|
532
|
+
default: undefined;
|
|
533
|
+
};
|
|
534
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
535
|
+
getText: {
|
|
536
|
+
type: PropType<() => Promise<string>>;
|
|
537
|
+
default: undefined;
|
|
538
|
+
};
|
|
539
|
+
/** Spreadsheets: rows shown at a time. */
|
|
540
|
+
pageSize: {
|
|
541
|
+
type: PropType<number>;
|
|
542
|
+
default: undefined;
|
|
543
|
+
};
|
|
544
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
545
|
+
pdf: {
|
|
546
|
+
type: PropType<PdfAssetOptions>;
|
|
547
|
+
default: undefined;
|
|
548
|
+
};
|
|
549
|
+
/** Documents: the page shown first. */
|
|
550
|
+
initialPage: {
|
|
551
|
+
type: PropType<number>;
|
|
552
|
+
default: undefined;
|
|
553
|
+
};
|
|
554
|
+
}>> & Readonly<{}>, {
|
|
555
|
+
onExpired: () => string | Promise<string>;
|
|
556
|
+
onUnavailable: () => void;
|
|
557
|
+
viewerClaims: ViewerClaims;
|
|
558
|
+
label: string;
|
|
559
|
+
messages: Partial<ViewerMessages>;
|
|
560
|
+
sizes: string;
|
|
561
|
+
text: string;
|
|
562
|
+
getText: () => Promise<string>;
|
|
563
|
+
pageSize: number;
|
|
564
|
+
pdf: PdfAssetOptions;
|
|
565
|
+
initialPage: number;
|
|
566
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
567
|
+
/** Shows a spreadsheet's sheets as tabs and paged tables, from its extracted text. */
|
|
568
|
+
export declare const CalmLensSpreadsheetViewer: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
569
|
+
/** The asset URL, public or signed. */
|
|
570
|
+
src: {
|
|
571
|
+
type: StringConstructor;
|
|
572
|
+
required: true;
|
|
573
|
+
};
|
|
574
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
575
|
+
asset: {
|
|
576
|
+
type: PropType<ViewerAsset>;
|
|
577
|
+
required: true;
|
|
578
|
+
};
|
|
579
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
580
|
+
onExpired: {
|
|
581
|
+
type: PropType<() => string | Promise<string>>;
|
|
582
|
+
default: undefined;
|
|
583
|
+
};
|
|
584
|
+
onUnavailable: {
|
|
585
|
+
type: PropType<() => void>;
|
|
586
|
+
default: undefined;
|
|
587
|
+
};
|
|
588
|
+
viewerClaims: {
|
|
589
|
+
type: PropType<ViewerClaims>;
|
|
590
|
+
default: undefined;
|
|
591
|
+
};
|
|
592
|
+
label: {
|
|
593
|
+
type: PropType<string>;
|
|
594
|
+
default: undefined;
|
|
595
|
+
};
|
|
596
|
+
messages: {
|
|
597
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
598
|
+
default: undefined;
|
|
599
|
+
};
|
|
600
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
601
|
+
sizes: {
|
|
602
|
+
type: PropType<string>;
|
|
603
|
+
default: undefined;
|
|
604
|
+
};
|
|
605
|
+
/** Text and spreadsheets: text your app already has. */
|
|
606
|
+
text: {
|
|
607
|
+
type: PropType<string>;
|
|
608
|
+
default: undefined;
|
|
609
|
+
};
|
|
610
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
611
|
+
getText: {
|
|
612
|
+
type: PropType<() => Promise<string>>;
|
|
613
|
+
default: undefined;
|
|
614
|
+
};
|
|
615
|
+
/** Spreadsheets: rows shown at a time. */
|
|
616
|
+
pageSize: {
|
|
617
|
+
type: PropType<number>;
|
|
618
|
+
default: undefined;
|
|
619
|
+
};
|
|
620
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
621
|
+
pdf: {
|
|
622
|
+
type: PropType<PdfAssetOptions>;
|
|
623
|
+
default: undefined;
|
|
624
|
+
};
|
|
625
|
+
/** Documents: the page shown first. */
|
|
626
|
+
initialPage: {
|
|
627
|
+
type: PropType<number>;
|
|
628
|
+
default: undefined;
|
|
629
|
+
};
|
|
630
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
631
|
+
[key: string]: any;
|
|
632
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
633
|
+
/** The asset URL, public or signed. */
|
|
634
|
+
src: {
|
|
635
|
+
type: StringConstructor;
|
|
636
|
+
required: true;
|
|
637
|
+
};
|
|
638
|
+
/** The asset's display info (`getAssetInfo`), or the asset from the API. */
|
|
639
|
+
asset: {
|
|
640
|
+
type: PropType<ViewerAsset>;
|
|
641
|
+
required: true;
|
|
642
|
+
};
|
|
643
|
+
/** Returns a fresh asset URL once a signed one expires. */
|
|
644
|
+
onExpired: {
|
|
645
|
+
type: PropType<() => string | Promise<string>>;
|
|
646
|
+
default: undefined;
|
|
647
|
+
};
|
|
648
|
+
onUnavailable: {
|
|
649
|
+
type: PropType<() => void>;
|
|
650
|
+
default: undefined;
|
|
651
|
+
};
|
|
652
|
+
viewerClaims: {
|
|
653
|
+
type: PropType<ViewerClaims>;
|
|
654
|
+
default: undefined;
|
|
655
|
+
};
|
|
656
|
+
label: {
|
|
657
|
+
type: PropType<string>;
|
|
658
|
+
default: undefined;
|
|
659
|
+
};
|
|
660
|
+
messages: {
|
|
661
|
+
type: PropType<Partial<ViewerMessages>>;
|
|
662
|
+
default: undefined;
|
|
663
|
+
};
|
|
664
|
+
/** Images: the `sizes` of a public image's responsive widths. */
|
|
665
|
+
sizes: {
|
|
666
|
+
type: PropType<string>;
|
|
667
|
+
default: undefined;
|
|
668
|
+
};
|
|
669
|
+
/** Text and spreadsheets: text your app already has. */
|
|
670
|
+
text: {
|
|
671
|
+
type: PropType<string>;
|
|
672
|
+
default: undefined;
|
|
673
|
+
};
|
|
674
|
+
/** Text and spreadsheets: reads the text yourself. */
|
|
675
|
+
getText: {
|
|
676
|
+
type: PropType<() => Promise<string>>;
|
|
677
|
+
default: undefined;
|
|
678
|
+
};
|
|
679
|
+
/** Spreadsheets: rows shown at a time. */
|
|
680
|
+
pageSize: {
|
|
681
|
+
type: PropType<number>;
|
|
682
|
+
default: undefined;
|
|
683
|
+
};
|
|
684
|
+
/** Documents: where pdf.js loads its worker, fonts and decoders from. */
|
|
685
|
+
pdf: {
|
|
686
|
+
type: PropType<PdfAssetOptions>;
|
|
687
|
+
default: undefined;
|
|
688
|
+
};
|
|
689
|
+
/** Documents: the page shown first. */
|
|
690
|
+
initialPage: {
|
|
691
|
+
type: PropType<number>;
|
|
692
|
+
default: undefined;
|
|
693
|
+
};
|
|
694
|
+
}>> & Readonly<{}>, {
|
|
695
|
+
onExpired: () => string | Promise<string>;
|
|
696
|
+
onUnavailable: () => void;
|
|
697
|
+
viewerClaims: ViewerClaims;
|
|
698
|
+
label: string;
|
|
699
|
+
messages: Partial<ViewerMessages>;
|
|
700
|
+
sizes: string;
|
|
701
|
+
text: string;
|
|
702
|
+
getText: () => Promise<string>;
|
|
703
|
+
pageSize: number;
|
|
704
|
+
pdf: PdfAssetOptions;
|
|
705
|
+
initialPage: number;
|
|
706
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
6
707
|
export interface UseCalmLensUploadResult<F extends UploadFile = File> {
|
|
7
708
|
snapshot: Readonly<ShallowRef<UploadSnapshot<F>>>;
|
|
8
709
|
controller: UploadController<F>;
|
|
@@ -208,108 +909,44 @@ export declare const CalmLensUploader: import("vue").DefineComponent<import("vue
|
|
|
208
909
|
controller: UploadController<File>;
|
|
209
910
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
210
911
|
/**
|
|
211
|
-
* Shows
|
|
212
|
-
*
|
|
213
|
-
*
|
|
912
|
+
* Shows any asset from its asset URL (public, or signed by your server), natively in the page: an
|
|
913
|
+
* image with responsive widths, a website's screenshot and link, video and audio with their
|
|
914
|
+
* adaptive stream, a document, text or spreadsheet viewer, or a preview still or file icon. It
|
|
915
|
+
* reads `{src}/info` once mounted, unless `info` is given, in which case the first render, on the
|
|
916
|
+
* server too, is the real element. Emits `load`, `error`, `availability-change`, `play`, `ended`
|
|
917
|
+
* and `timeupdate`; listen for `age-confirm-request` to show the reveal button on age-restricted
|
|
918
|
+
* content. The `unavailable` and `age-gate` slots (`{ placeholderUrl, confirm }`) replace the
|
|
919
|
+
* notices.
|
|
214
920
|
*/
|
|
215
|
-
export declare const
|
|
216
|
-
/**
|
|
217
|
-
|
|
218
|
-
type: PropType<MediaAsset>;
|
|
219
|
-
default: undefined;
|
|
220
|
-
};
|
|
221
|
-
/** Required without `asset`. */
|
|
222
|
-
projectId: {
|
|
223
|
-
type: PropType<string>;
|
|
224
|
-
default: undefined;
|
|
225
|
-
};
|
|
226
|
-
/** Required without `asset`. */
|
|
227
|
-
assetId: {
|
|
228
|
-
type: PropType<string>;
|
|
229
|
-
default: undefined;
|
|
230
|
-
};
|
|
231
|
-
status: {
|
|
232
|
-
type: PropType<AssetModerationStatus>;
|
|
233
|
-
default: undefined;
|
|
234
|
-
};
|
|
235
|
-
contentRemoved: {
|
|
236
|
-
type: PropType<boolean>;
|
|
237
|
-
default: undefined;
|
|
238
|
-
};
|
|
239
|
-
type: {
|
|
240
|
-
type: PropType<"audio" | "image" | "video">;
|
|
241
|
-
default: undefined;
|
|
242
|
-
};
|
|
243
|
-
resource: {
|
|
244
|
-
type: PropType<"original" | "rendered">;
|
|
245
|
-
default: undefined;
|
|
246
|
-
};
|
|
247
|
-
lens: {
|
|
248
|
-
type: PropType<string>;
|
|
249
|
-
default: undefined;
|
|
250
|
-
};
|
|
251
|
-
transform: {
|
|
252
|
-
type: PropType<CdnTransform>;
|
|
253
|
-
default: undefined;
|
|
254
|
-
};
|
|
255
|
-
widths: {
|
|
256
|
-
type: PropType<number[]>;
|
|
257
|
-
default: undefined;
|
|
258
|
-
};
|
|
259
|
-
url: {
|
|
260
|
-
type: PropType<string>;
|
|
261
|
-
default: undefined;
|
|
262
|
-
};
|
|
263
|
-
placeholder: {
|
|
264
|
-
type: BooleanConstructor;
|
|
265
|
-
default: boolean;
|
|
266
|
-
};
|
|
267
|
-
placeholderHash: {
|
|
268
|
-
type: PropType<string>;
|
|
269
|
-
default: undefined;
|
|
270
|
-
};
|
|
271
|
-
placeholderUrl: {
|
|
921
|
+
export declare const CalmLensAsset: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
922
|
+
/** The asset URL, public or signed. Nothing is requested until it is set. */
|
|
923
|
+
src: {
|
|
272
924
|
type: PropType<string>;
|
|
273
925
|
default: undefined;
|
|
274
926
|
};
|
|
275
|
-
|
|
276
|
-
type: PropType<
|
|
277
|
-
default: undefined;
|
|
278
|
-
};
|
|
279
|
-
cdnBaseUrl: {
|
|
280
|
-
type: PropType<string>;
|
|
927
|
+
display: {
|
|
928
|
+
type: PropType<AssetDisplay>;
|
|
281
929
|
default: undefined;
|
|
282
930
|
};
|
|
283
931
|
viewerClaims: {
|
|
284
932
|
type: PropType<ViewerClaims>;
|
|
285
933
|
default: undefined;
|
|
286
934
|
};
|
|
935
|
+
/** The asset's display info, prefetched with `getAssetInfo`. */
|
|
936
|
+
info: {
|
|
937
|
+
type: PropType<ViewerAsset>;
|
|
938
|
+
default: undefined;
|
|
939
|
+
};
|
|
287
940
|
alt: {
|
|
288
941
|
type: StringConstructor;
|
|
289
942
|
default: string;
|
|
290
943
|
};
|
|
291
|
-
aspectRatio: {
|
|
292
|
-
type: PropType<number>;
|
|
293
|
-
default: undefined;
|
|
294
|
-
};
|
|
295
|
-
width: {
|
|
296
|
-
type: PropType<number>;
|
|
297
|
-
default: undefined;
|
|
298
|
-
};
|
|
299
|
-
height: {
|
|
300
|
-
type: PropType<number>;
|
|
301
|
-
default: undefined;
|
|
302
|
-
};
|
|
303
|
-
sizes: {
|
|
304
|
-
type: PropType<string>;
|
|
305
|
-
default: undefined;
|
|
306
|
-
};
|
|
307
944
|
fit: {
|
|
308
945
|
type: PropType<"contain" | "cover">;
|
|
309
946
|
default: undefined;
|
|
310
947
|
};
|
|
311
|
-
|
|
312
|
-
type: PropType<
|
|
948
|
+
aspectRatio: {
|
|
949
|
+
type: PropType<number>;
|
|
313
950
|
default: undefined;
|
|
314
951
|
};
|
|
315
952
|
lazy: {
|
|
@@ -320,171 +957,137 @@ export declare const CalmLensMedia: import("vue").DefineComponent<import("vue").
|
|
|
320
957
|
type: PropType<"auto" | "high" | "low">;
|
|
321
958
|
default: undefined;
|
|
322
959
|
};
|
|
323
|
-
|
|
324
|
-
type:
|
|
325
|
-
default: boolean;
|
|
326
|
-
};
|
|
327
|
-
messages: {
|
|
328
|
-
type: PropType<Partial<CalmLensMessages>>;
|
|
329
|
-
default: undefined;
|
|
330
|
-
};
|
|
331
|
-
/** Bound by `@reveal`; declared as a prop so the button shows only when something listens. */
|
|
332
|
-
onReveal: {
|
|
333
|
-
type: PropType<() => void>;
|
|
334
|
-
default: undefined;
|
|
335
|
-
};
|
|
336
|
-
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
337
|
-
[key: string]: any;
|
|
338
|
-
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
339
|
-
/** An asset from the API, which supplies the project, ID, status, type and preview. */
|
|
340
|
-
asset: {
|
|
341
|
-
type: PropType<MediaAsset>;
|
|
342
|
-
default: undefined;
|
|
343
|
-
};
|
|
344
|
-
/** Required without `asset`. */
|
|
345
|
-
projectId: {
|
|
346
|
-
type: PropType<string>;
|
|
347
|
-
default: undefined;
|
|
348
|
-
};
|
|
349
|
-
/** Required without `asset`. */
|
|
350
|
-
assetId: {
|
|
351
|
-
type: PropType<string>;
|
|
352
|
-
default: undefined;
|
|
353
|
-
};
|
|
354
|
-
status: {
|
|
355
|
-
type: PropType<AssetModerationStatus>;
|
|
356
|
-
default: undefined;
|
|
357
|
-
};
|
|
358
|
-
contentRemoved: {
|
|
359
|
-
type: PropType<boolean>;
|
|
360
|
-
default: undefined;
|
|
361
|
-
};
|
|
362
|
-
type: {
|
|
363
|
-
type: PropType<"audio" | "image" | "video">;
|
|
364
|
-
default: undefined;
|
|
365
|
-
};
|
|
366
|
-
resource: {
|
|
367
|
-
type: PropType<"original" | "rendered">;
|
|
960
|
+
image: {
|
|
961
|
+
type: PropType<AssetImageOptions>;
|
|
368
962
|
default: undefined;
|
|
369
963
|
};
|
|
370
|
-
|
|
371
|
-
type: PropType<
|
|
964
|
+
video: {
|
|
965
|
+
type: PropType<AssetVideoOptions>;
|
|
372
966
|
default: undefined;
|
|
373
967
|
};
|
|
374
|
-
|
|
375
|
-
type: PropType<
|
|
968
|
+
document: {
|
|
969
|
+
type: PropType<AssetDocumentOptions>;
|
|
376
970
|
default: undefined;
|
|
377
971
|
};
|
|
378
|
-
|
|
379
|
-
type: PropType<
|
|
972
|
+
spreadsheet: {
|
|
973
|
+
type: PropType<AssetSpreadsheetOptions>;
|
|
380
974
|
default: undefined;
|
|
381
975
|
};
|
|
382
|
-
|
|
383
|
-
|
|
976
|
+
/** Returns a fresh asset URL from your server once a signed one expires. */
|
|
977
|
+
onExpired: {
|
|
978
|
+
type: PropType<() => string | Promise<string>>;
|
|
384
979
|
default: undefined;
|
|
385
980
|
};
|
|
386
|
-
|
|
387
|
-
type:
|
|
388
|
-
default: boolean;
|
|
389
|
-
};
|
|
390
|
-
placeholderHash: {
|
|
391
|
-
type: PropType<string>;
|
|
981
|
+
messages: {
|
|
982
|
+
type: PropType<Partial<CalmLensMessages>>;
|
|
392
983
|
default: undefined;
|
|
393
984
|
};
|
|
394
|
-
|
|
395
|
-
|
|
985
|
+
/** Bound by `@age-confirm-request`; a prop so the reveal button shows only when bound. */
|
|
986
|
+
onAgeConfirmRequest: {
|
|
987
|
+
type: PropType<() => void>;
|
|
396
988
|
default: undefined;
|
|
397
989
|
};
|
|
398
|
-
|
|
990
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
991
|
+
[key: string]: any;
|
|
992
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
993
|
+
load: () => true;
|
|
994
|
+
error: () => true;
|
|
995
|
+
"availability-change": (_availability: AssetAvailability) => true;
|
|
996
|
+
play: () => true;
|
|
997
|
+
ended: () => true;
|
|
998
|
+
timeupdate: (_currentTime: number) => true;
|
|
999
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
1000
|
+
/** The asset URL, public or signed. Nothing is requested until it is set. */
|
|
1001
|
+
src: {
|
|
399
1002
|
type: PropType<string>;
|
|
400
1003
|
default: undefined;
|
|
401
1004
|
};
|
|
402
|
-
|
|
403
|
-
type: PropType<
|
|
1005
|
+
display: {
|
|
1006
|
+
type: PropType<AssetDisplay>;
|
|
404
1007
|
default: undefined;
|
|
405
1008
|
};
|
|
406
1009
|
viewerClaims: {
|
|
407
1010
|
type: PropType<ViewerClaims>;
|
|
408
1011
|
default: undefined;
|
|
409
1012
|
};
|
|
1013
|
+
/** The asset's display info, prefetched with `getAssetInfo`. */
|
|
1014
|
+
info: {
|
|
1015
|
+
type: PropType<ViewerAsset>;
|
|
1016
|
+
default: undefined;
|
|
1017
|
+
};
|
|
410
1018
|
alt: {
|
|
411
1019
|
type: StringConstructor;
|
|
412
1020
|
default: string;
|
|
413
1021
|
};
|
|
414
|
-
|
|
415
|
-
type: PropType<
|
|
1022
|
+
fit: {
|
|
1023
|
+
type: PropType<"contain" | "cover">;
|
|
416
1024
|
default: undefined;
|
|
417
1025
|
};
|
|
418
|
-
|
|
1026
|
+
aspectRatio: {
|
|
419
1027
|
type: PropType<number>;
|
|
420
1028
|
default: undefined;
|
|
421
1029
|
};
|
|
422
|
-
|
|
423
|
-
type:
|
|
424
|
-
default:
|
|
1030
|
+
lazy: {
|
|
1031
|
+
type: BooleanConstructor;
|
|
1032
|
+
default: boolean;
|
|
425
1033
|
};
|
|
426
|
-
|
|
427
|
-
type: PropType<
|
|
1034
|
+
fetchPriority: {
|
|
1035
|
+
type: PropType<"auto" | "high" | "low">;
|
|
428
1036
|
default: undefined;
|
|
429
1037
|
};
|
|
430
|
-
|
|
431
|
-
type: PropType<
|
|
1038
|
+
image: {
|
|
1039
|
+
type: PropType<AssetImageOptions>;
|
|
432
1040
|
default: undefined;
|
|
433
1041
|
};
|
|
434
|
-
|
|
435
|
-
type: PropType<
|
|
1042
|
+
video: {
|
|
1043
|
+
type: PropType<AssetVideoOptions>;
|
|
436
1044
|
default: undefined;
|
|
437
1045
|
};
|
|
438
|
-
|
|
439
|
-
type:
|
|
440
|
-
default:
|
|
1046
|
+
document: {
|
|
1047
|
+
type: PropType<AssetDocumentOptions>;
|
|
1048
|
+
default: undefined;
|
|
441
1049
|
};
|
|
442
|
-
|
|
443
|
-
type: PropType<
|
|
1050
|
+
spreadsheet: {
|
|
1051
|
+
type: PropType<AssetSpreadsheetOptions>;
|
|
444
1052
|
default: undefined;
|
|
445
1053
|
};
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
1054
|
+
/** Returns a fresh asset URL from your server once a signed one expires. */
|
|
1055
|
+
onExpired: {
|
|
1056
|
+
type: PropType<() => string | Promise<string>>;
|
|
1057
|
+
default: undefined;
|
|
449
1058
|
};
|
|
450
1059
|
messages: {
|
|
451
1060
|
type: PropType<Partial<CalmLensMessages>>;
|
|
452
1061
|
default: undefined;
|
|
453
1062
|
};
|
|
454
|
-
/** Bound by `@
|
|
455
|
-
|
|
1063
|
+
/** Bound by `@age-confirm-request`; a prop so the reveal button shows only when bound. */
|
|
1064
|
+
onAgeConfirmRequest: {
|
|
456
1065
|
type: PropType<() => void>;
|
|
457
1066
|
default: undefined;
|
|
458
1067
|
};
|
|
459
|
-
}>> & Readonly<{
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
widths: number[];
|
|
470
|
-
url: string;
|
|
471
|
-
placeholder: boolean;
|
|
472
|
-
placeholderHash: string;
|
|
473
|
-
placeholderUrl: string;
|
|
474
|
-
averageColor: string;
|
|
475
|
-
cdnBaseUrl: string;
|
|
1068
|
+
}>> & Readonly<{
|
|
1069
|
+
"onAvailability-change"?: ((_availability: "age-restricted" | "available" | "unavailable") => any) | undefined;
|
|
1070
|
+
onEnded?: (() => any) | undefined;
|
|
1071
|
+
onError?: (() => any) | undefined;
|
|
1072
|
+
onLoad?: (() => any) | undefined;
|
|
1073
|
+
onPlay?: (() => any) | undefined;
|
|
1074
|
+
onTimeupdate?: ((_currentTime: number) => any) | undefined;
|
|
1075
|
+
}>, {
|
|
1076
|
+
src: string;
|
|
1077
|
+
display: AssetDisplay;
|
|
476
1078
|
viewerClaims: ViewerClaims;
|
|
1079
|
+
info: ViewerAsset;
|
|
477
1080
|
alt: string;
|
|
478
|
-
aspectRatio: number;
|
|
479
|
-
width: number;
|
|
480
|
-
height: number;
|
|
481
|
-
sizes: string;
|
|
482
1081
|
fit: "contain" | "cover";
|
|
483
|
-
|
|
1082
|
+
aspectRatio: number;
|
|
484
1083
|
lazy: boolean;
|
|
485
1084
|
fetchPriority: "auto" | "high" | "low";
|
|
486
|
-
|
|
1085
|
+
image: AssetImageOptions;
|
|
1086
|
+
video: AssetVideoOptions;
|
|
1087
|
+
document: AssetDocumentOptions;
|
|
1088
|
+
spreadsheet: AssetSpreadsheetOptions;
|
|
1089
|
+
onExpired: () => string | Promise<string>;
|
|
487
1090
|
messages: Partial<CalmLensMessages>;
|
|
488
|
-
|
|
1091
|
+
onAgeConfirmRequest: () => void;
|
|
489
1092
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
490
|
-
export { CALMLENS_STYLES, CALMLENS_THEME, type CalmLensMessages, type CalmLensTheme, type CalmLensUpload, type CustomUploadContext, type CustomUploadResult, DEFAULT_MESSAGES, ICONS, ICON_ATTRIBUTES, type IconName, type
|
|
1093
|
+
export { ASSET_FILE_ICON_SIZE, ASSET_VIEWERS, type AssetDisplay, type AssetDisplayOptions, type AssetDocumentOptions, type AssetEventHandlers, type AssetImageOptions, type AssetImageSource, type AssetOptions, type AssetProps, AssetSession, type AssetSessionState, type AssetSpreadsheetOptions, type AssetVideoOptions, type AssetView, type AssetViewer, type AssetViewerKind, AssetViewerMount, AssetViewerName, AssetViewerOptionsByKind, CALMLENS_STYLES, CALMLENS_THEME, type CalmLensMessages, type CalmLensTheme, type CalmLensUpload, type CustomUploadContext, type CustomUploadResult, DEFAULT_MESSAGES, DEFAULT_VIEWER_MESSAGES, type DocumentViewerOptions, ICONS, ICON_ATTRIBUTES, type IconName, type ImageViewerOptions, type MediaPlayback, MediaStreamPlayer, type MountedViewerKind, type PdfAssetOptions, type ProgressFetchOptions, type SpreadsheetCell, type SpreadsheetRow, type SpreadsheetSheet, type SpreadsheetViewerOptions, type TextViewerOptions, type UploadClient, UploadController, type UploadControllerOptions, type UploadFile, type UploadItem, type UploadItemView, type UploadSnapshot, type UploadStage, type UploaderDisplayOptions, type UploaderProps, type UploaderView, VIEWER_STYLES, type ViewerAsset, type ViewerMessages, type ViewerOptions, type ViewerState, type ViewerTextOptions, type WebsiteViewerOptions, createDocumentViewer, createImageViewer, createProgressFetch, createSpreadsheetViewer, createTextViewer, createUploadController, createWebsiteViewer, describeUploadItem, describeUploader, formatBytes, formatMessage, formatViewerMessage, getAssetAspectRatio, getAssetView, getAssetViewKey, getAssetViewerKind, getDropzoneHint, getMountedViewerOptions, getPeakHeights, getPlayedPercent, getSpreadsheetPage, getUploadItemMessage, getUploadItemOutcome, isFileAccepted, isMountedViewerKind, isSpreadsheetFormat, loadPdfJs, parseSpreadsheetText, pickAssetSource, resolveMessages, resolveTheme, resolveViewerMessages, spreadsheetColumnIndex };
|