@sparkvault/sdk-js 11.2.0 → 11.2.2
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.cjs +19 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +18 -4
- package/dist/index.mjs +19 -8
- package/dist/index.mjs.map +1 -1
- package/dist/ingots/types.d.ts +18 -4
- package/dist/sparkvault.js +1 -1
- package/dist/sparkvault.js.map +1 -1
- package/package.json +1 -1
package/dist/ingots/types.d.ts
CHANGED
|
@@ -127,7 +127,11 @@ export interface UploadIngotOptions {
|
|
|
127
127
|
file: File | Blob;
|
|
128
128
|
/** Optional name (defaults to file name) */
|
|
129
129
|
name?: string;
|
|
130
|
-
/**
|
|
130
|
+
/**
|
|
131
|
+
* Content type (the file's own `type` if not provided). A file of no type is
|
|
132
|
+
* sent with none, and Core stores the type the registry lists for the name's
|
|
133
|
+
* extension, else `application/octet-stream`.
|
|
134
|
+
*/
|
|
131
135
|
contentType?: string;
|
|
132
136
|
/** Slash-delimited folder path (find-or-created from root). */
|
|
133
137
|
folder?: string;
|
|
@@ -175,7 +179,11 @@ export interface ReplaceIngotOptions {
|
|
|
175
179
|
name?: string;
|
|
176
180
|
/** Vault-keyed plaintext HMAC (43-char base64url) for the NEW content. */
|
|
177
181
|
contentHmac?: string;
|
|
178
|
-
/**
|
|
182
|
+
/**
|
|
183
|
+
* Content type (the file's own `type` if not provided). A file of no type
|
|
184
|
+
* keeps the type the ingot stores, which Core reads from the name by its
|
|
185
|
+
* extension only when it is `application/octet-stream` or unparsable.
|
|
186
|
+
*/
|
|
179
187
|
contentType?: string;
|
|
180
188
|
/** Progress callback for the Forge/TUS transfer */
|
|
181
189
|
onProgress?: (bytesUploaded: number, bytesTotal: number) => void;
|
|
@@ -221,9 +229,15 @@ export interface FolderContents {
|
|
|
221
229
|
}
|
|
222
230
|
/** Options for search. */
|
|
223
231
|
export interface SearchIngotsOptions {
|
|
224
|
-
/**
|
|
232
|
+
/** The beginning of the ingot's name, in any case: a prefix, never a substring or a fuzzy match. */
|
|
225
233
|
q?: string;
|
|
226
|
-
/**
|
|
234
|
+
/**
|
|
235
|
+
* The MIME type to match, in lowercase: a family (`image`, `video`,
|
|
236
|
+
* `audio`, `text`, `application`, ...), which every type under it matches,
|
|
237
|
+
* or an exact type (`application/pdf`), which matches that type whatever
|
|
238
|
+
* its parameters. A well-formed value no ingot carries matches none; the
|
|
239
|
+
* server refuses a value that is neither.
|
|
240
|
+
*/
|
|
227
241
|
fileType?: string;
|
|
228
242
|
/** Scope the search to one folder (whole vault when omitted) */
|
|
229
243
|
folderId?: string;
|