@vacantthinker/firefox-addon-framework-easy 2026.611.2203 → 2026.612.1531
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/browserRuntime.d.ts +6 -2
- package/dist/browserRuntime.d.ts.map +1 -1
- package/dist/browserRuntime.js +9 -6
- package/dist/opStorage.d.ts +1 -0
- package/dist/opStorage.d.ts.map +1 -1
- package/dist/opStorage.js +3 -0
- package/dist/serviceCommon.d.ts +4 -0
- package/dist/serviceCommon.d.ts.map +1 -1
- package/dist/serviceCommon.js +9 -0
- package/package.json +1 -1
package/dist/browserRuntime.d.ts
CHANGED
|
@@ -9,15 +9,19 @@ export declare function browserRuntimeReload(): void;
|
|
|
9
9
|
export declare function browserRuntimeSetUninstallURL(url?: string): Promise<void>;
|
|
10
10
|
/**
|
|
11
11
|
* Adds a listener for available updates.
|
|
12
|
-
* @param callback Callback to execute when an update is available.
|
|
13
12
|
*/
|
|
14
|
-
export declare function browserRuntimeOnUpdateAvailable(
|
|
13
|
+
export declare function browserRuntimeOnUpdateAvailable(): void;
|
|
15
14
|
/**
|
|
16
15
|
* Converts a relative path to a fully qualified URL.
|
|
17
16
|
* @param path The path to the resource.
|
|
18
17
|
* @returns The absolute URL string.
|
|
19
18
|
*/
|
|
20
19
|
export declare function browserRuntimeGetURL(path: string): string;
|
|
20
|
+
/**
|
|
21
|
+
* `pages/${path}`
|
|
22
|
+
* @param path
|
|
23
|
+
*/
|
|
24
|
+
export declare function browserRuntimeGetPagesURL(path: string): string;
|
|
21
25
|
/**
|
|
22
26
|
* Retrieves the Gecko ID from the manifest.
|
|
23
27
|
* @returns The Gecko ID or empty string if not found.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"browserRuntime.d.ts","sourceRoot":"","sources":["../src/browserRuntime.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,oBAAoB,IAAI,IAAI,CAE3C;AAED;;;GAGG;AACH,wBAAsB,6BAA6B,CAAC,GAAG,GAAE,MAAW,GAAG,OAAO,CAAC,IAAI,CAAC,CAEnF;AAED
|
|
1
|
+
{"version":3,"file":"browserRuntime.d.ts","sourceRoot":"","sources":["../src/browserRuntime.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,oBAAoB,IAAI,IAAI,CAE3C;AAED;;;GAGG;AACH,wBAAsB,6BAA6B,CAAC,GAAG,GAAE,MAAW,GAAG,OAAO,CAAC,IAAI,CAAC,CAEnF;AAED;;GAEG;AACH,wBAAgB,+BAA+B,IAAI,IAAI,CAGtD;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAEzD;AAED;;;GAGG;AACH,wBAAgB,yBAAyB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,CAE9D;AAED;;;GAGG;AACH,wBAAgB,qBAAqB,IAAI,MAAM,CAG9C;AAED;;;GAGG;AACH,wBAAsB,0BAA0B,IAAI,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,CAExF;AAED;;;GAGG;AACH,wBAAgB,6BAA6B,IAAI,MAAM,CAEtD;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,IAAI,MAAM,CAEnD"}
|
package/dist/browserRuntime.js
CHANGED
|
@@ -13,13 +13,9 @@ export async function browserRuntimeSetUninstallURL(url = '') {
|
|
|
13
13
|
}
|
|
14
14
|
/**
|
|
15
15
|
* Adds a listener for available updates.
|
|
16
|
-
* @param callback Callback to execute when an update is available.
|
|
17
16
|
*/
|
|
18
|
-
export function browserRuntimeOnUpdateAvailable(
|
|
19
|
-
browser.runtime.onUpdateAvailable.addListener(
|
|
20
|
-
if (callback) {
|
|
21
|
-
await callback(details);
|
|
22
|
-
}
|
|
17
|
+
export function browserRuntimeOnUpdateAvailable() {
|
|
18
|
+
browser.runtime.onUpdateAvailable.addListener(() => {
|
|
23
19
|
});
|
|
24
20
|
}
|
|
25
21
|
/**
|
|
@@ -30,6 +26,13 @@ export function browserRuntimeOnUpdateAvailable(callback) {
|
|
|
30
26
|
export function browserRuntimeGetURL(path) {
|
|
31
27
|
return browser.runtime.getURL(path);
|
|
32
28
|
}
|
|
29
|
+
/**
|
|
30
|
+
* `pages/${path}`
|
|
31
|
+
* @param path
|
|
32
|
+
*/
|
|
33
|
+
export function browserRuntimeGetPagesURL(path) {
|
|
34
|
+
return browser.runtime.getURL(`pages/${path}`);
|
|
35
|
+
}
|
|
33
36
|
/**
|
|
34
37
|
* Retrieves the Gecko ID from the manifest.
|
|
35
38
|
* @returns The Gecko ID or empty string if not found.
|
package/dist/opStorage.d.ts
CHANGED
|
@@ -15,6 +15,7 @@ export declare function stoOpGet<T = any>(key: string): Promise<T | null>;
|
|
|
15
15
|
* @returns Promise resolving to an object containing all storage items.
|
|
16
16
|
*/
|
|
17
17
|
export declare function stoOpGetAll<T = Record<string, any>>(): Promise<T>;
|
|
18
|
+
export declare function stoOpClear(): Promise<void>;
|
|
18
19
|
/**
|
|
19
20
|
* Queries keys that start with a specific prefix.
|
|
20
21
|
* @param prefix The prefix to filter keys.
|
package/dist/opStorage.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"opStorage.d.ts","sourceRoot":"","sources":["../src/opStorage.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAsB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAG9D;AAED;;;;GAIG;AACH,wBAAsB,QAAQ,CAAC,CAAC,GAAG,GAAG,EAAE,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,CAAC,GAAG,IAAI,CAAC,CAGtE;AAED;;;GAGG;AACH,wBAAsB,WAAW,CAAC,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,OAAO,CAAC,CAAC,CAAC,CAGvE;AAED;;;;GAIG;AACH,wBAAsB,mBAAmB,CAAC,MAAM,EAAE,MAAM,G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ist/opStorage.js
CHANGED
|
@@ -24,6 +24,9 @@ export async function stoOpGetAll() {
|
|
|
24
24
|
const result = await browser.storage.local.get();
|
|
25
25
|
return result;
|
|
26
26
|
}
|
|
27
|
+
export async function stoOpClear() {
|
|
28
|
+
await browser.storage.local.clear();
|
|
29
|
+
}
|
|
27
30
|
/**
|
|
28
31
|
* Queries keys that start with a specific prefix.
|
|
29
32
|
* @param prefix The prefix to filter keys.
|
package/dist/serviceCommon.d.ts
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { DownloadParams } from './browserDownload';
|
|
2
|
+
/**
|
|
3
|
+
* clear storage, then raload addon
|
|
4
|
+
*/
|
|
5
|
+
export declare function serviceResetAddon(): Promise<void>;
|
|
2
6
|
/**
|
|
3
7
|
* Service to handle download operations.
|
|
4
8
|
* Attempts a full download with filename; if it fails, retries with downlink only.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"serviceCommon.d.ts","sourceRoot":"","sources":["../src/serviceCommon.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"serviceCommon.d.ts","sourceRoot":"","sources":["../src/serviceCommon.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,cAAc,EACf,MAAM,mBAAmB,CAAC;AAK3B;;GAEG;AACH,wBAAsB,iBAAiB,kBAGtC;AAED;;;;GAIG;AACH,wBAAsB,yBAAyB,CAAC,MAAM,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAcrF"}
|
package/dist/serviceCommon.js
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
import { browserDownloadByDownlink } from './browserDownload';
|
|
2
2
|
import { browserNotificationCreate } from './browserNotification';
|
|
3
|
+
import { stoOpClear } from "./opStorage";
|
|
4
|
+
import { browserRuntimeReload } from "./browserRuntime";
|
|
5
|
+
/**
|
|
6
|
+
* clear storage, then raload addon
|
|
7
|
+
*/
|
|
8
|
+
export async function serviceResetAddon() {
|
|
9
|
+
await stoOpClear();
|
|
10
|
+
browserRuntimeReload();
|
|
11
|
+
}
|
|
3
12
|
/**
|
|
4
13
|
* Service to handle download operations.
|
|
5
14
|
* Attempts a full download with filename; if it fails, retries with downlink only.
|