@pi-oxide/extension-js 0.6.0 → 0.7.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/content-script.js +2 -2
- package/extension_js.d.ts +11 -6
- package/extension_js.js +62441 -62170
- package/index.js +1388 -1152
- package/package.json +1 -1
- package/worker.js +3902 -397
package/extension_js.d.ts
CHANGED
|
@@ -148,6 +148,11 @@ export interface FsWriteParams {
|
|
|
148
148
|
data: string;
|
|
149
149
|
}
|
|
150
150
|
|
|
151
|
+
export interface FsWriteResult {
|
|
152
|
+
path: string;
|
|
153
|
+
bytes_written: number;
|
|
154
|
+
}
|
|
155
|
+
|
|
151
156
|
export interface JsApiAlias {
|
|
152
157
|
namespace: string;
|
|
153
158
|
name: string;
|
|
@@ -268,9 +273,9 @@ export class ExtensionSession {
|
|
|
268
273
|
* Generate API documentation for every registered public API.
|
|
269
274
|
*/
|
|
270
275
|
apiDocs(format: string): string;
|
|
271
|
-
fsAppend(params: FsWriteParams): Promise<
|
|
272
|
-
fsAppendBase64(params: FsWriteParams): Promise<
|
|
273
|
-
fsAppendText(params: FsWriteParams): Promise<
|
|
276
|
+
fsAppend(params: FsWriteParams): Promise<FsWriteResult>;
|
|
277
|
+
fsAppendBase64(params: FsWriteParams): Promise<FsWriteResult>;
|
|
278
|
+
fsAppendText(params: FsWriteParams): Promise<FsWriteResult>;
|
|
274
279
|
fsCopy(params: FsCopyParams): Promise<FsBoolResult>;
|
|
275
280
|
fsDelete(params: FsPathParams): Promise<FsBoolResult>;
|
|
276
281
|
fsExists(params: FsPathParams): Promise<FsExistsResult>;
|
|
@@ -284,9 +289,9 @@ export class ExtensionSession {
|
|
|
284
289
|
fsReadText(params: FsPathParams): Promise<FsStringResult>;
|
|
285
290
|
fsStat(params: FsPathParams): Promise<FsStatResult>;
|
|
286
291
|
fsUpdate(params: FsReadRangeDataParams): Promise<FsBoolResult>;
|
|
287
|
-
fsWrite(params: FsWriteParams): Promise<
|
|
288
|
-
fsWriteBase64(params: FsWriteParams): Promise<
|
|
289
|
-
fsWriteText(params: FsWriteParams): Promise<
|
|
292
|
+
fsWrite(params: FsWriteParams): Promise<FsWriteResult>;
|
|
293
|
+
fsWriteBase64(params: FsWriteParams): Promise<FsWriteResult>;
|
|
294
|
+
fsWriteText(params: FsWriteParams): Promise<FsWriteResult>;
|
|
290
295
|
/**
|
|
291
296
|
* Inject async and sync API bindings from the doc registry into the JS environment.
|
|
292
297
|
* Must be called after all manifest entries are registered.
|