webext-schema 4.0.0 → 4.1.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/modules/browser.js +11 -1
- package/package.json +18 -18
- package/schemas/beta/webext.json +4 -2
- package/schemas/central/webext.json +4 -2
- package/schemas/mail/mailext.json +20 -14
- package/schemas/release/webext.json +27 -13
package/modules/browser.js
CHANGED
|
@@ -412,6 +412,16 @@ export const getManifestIcons = () => {
|
|
|
412
412
|
return icons;
|
|
413
413
|
};
|
|
414
414
|
|
|
415
|
+
/**
|
|
416
|
+
* get manifest version
|
|
417
|
+
*
|
|
418
|
+
* @returns {number} - version
|
|
419
|
+
*/
|
|
420
|
+
export const getManifestVersion = () => {
|
|
421
|
+
const { manifest_version: version } = runtime.getManifest();
|
|
422
|
+
return version;
|
|
423
|
+
};
|
|
424
|
+
|
|
415
425
|
/**
|
|
416
426
|
* get OS
|
|
417
427
|
*
|
|
@@ -474,7 +484,7 @@ export const sendMessage = async (id, msg, opt) => {
|
|
|
474
484
|
} else if (id && isString(id)) {
|
|
475
485
|
func = runtime.sendMessage(id, msg, opt);
|
|
476
486
|
} else {
|
|
477
|
-
func = runtime.sendMessage(
|
|
487
|
+
func = runtime.sendMessage(msg, opt);
|
|
478
488
|
}
|
|
479
489
|
}
|
|
480
490
|
return func || null;
|
package/package.json
CHANGED
|
@@ -14,39 +14,39 @@
|
|
|
14
14
|
"scripts": {
|
|
15
15
|
"lint": "eslint --fix .",
|
|
16
16
|
"start": "node index",
|
|
17
|
-
"test": "npm run test
|
|
18
|
-
"test
|
|
19
|
-
"test
|
|
20
|
-
"test
|
|
21
|
-
"test
|
|
22
|
-
"test_all": "npm-run-all -s test
|
|
17
|
+
"test": "npm run test-central",
|
|
18
|
+
"test-beta": "c8 mocha --require=test/mocha/setup.js --channel=beta --exit test/*.test.js",
|
|
19
|
+
"test-central": "c8 mocha --require=test/mocha/setup.js --channel=central --exit test/*.test.js",
|
|
20
|
+
"test-esr": "c8 mocha --require=test/mocha/setup.js --channel=esr --exit test/*.test.js",
|
|
21
|
+
"test-release": "c8 mocha --require=test/mocha/setup.js --channel=release --exit test/*.test.js",
|
|
22
|
+
"test_all": "npm-run-all -s test-*",
|
|
23
23
|
"update": "node index update -i",
|
|
24
|
-
"update
|
|
25
|
-
"update
|
|
26
|
-
"update
|
|
27
|
-
"update
|
|
28
|
-
"update
|
|
24
|
+
"update-beta": "node index update --channel=beta -i",
|
|
25
|
+
"update-central": "node index update --channel=central -i",
|
|
26
|
+
"update-esr": "node index update --channel=esr -i",
|
|
27
|
+
"update-mail": "node index update --channel=mail -i",
|
|
28
|
+
"update-release": "node index update --channel=release -i"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"camelize": "^1.0.0",
|
|
32
|
-
"commander": "^9.
|
|
32
|
+
"commander": "^9.4.0",
|
|
33
33
|
"decamelize": "^6.0.0",
|
|
34
34
|
"json5": "^2.2.1",
|
|
35
|
-
"node-fetch": "^3.2.
|
|
35
|
+
"node-fetch": "^3.2.9",
|
|
36
36
|
"sinon": "^14.0.0"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"c8": "^7.
|
|
39
|
+
"c8": "^7.12.0",
|
|
40
40
|
"chai": "^4.3.6",
|
|
41
|
-
"eslint": "^8.
|
|
41
|
+
"eslint": "^8.20.0",
|
|
42
42
|
"eslint-config-standard": "^17.0.0",
|
|
43
43
|
"eslint-plugin-import": "^2.26.0",
|
|
44
|
-
"eslint-plugin-jsdoc": "^39.3.
|
|
44
|
+
"eslint-plugin-jsdoc": "^39.3.3",
|
|
45
45
|
"eslint-plugin-node": "^11.1.0",
|
|
46
46
|
"eslint-plugin-promise": "^6.0.0",
|
|
47
47
|
"mocha": "^10.0.0",
|
|
48
|
-
"nock": "^13.2.
|
|
48
|
+
"nock": "^13.2.9",
|
|
49
49
|
"npm-run-all": "^4.1.5"
|
|
50
50
|
},
|
|
51
|
-
"version": "4.
|
|
51
|
+
"version": "4.1.2"
|
|
52
52
|
}
|
package/schemas/beta/webext.json
CHANGED
|
@@ -11587,7 +11587,6 @@
|
|
|
11587
11587
|
"screenshots",
|
|
11588
11588
|
"seqstyle",
|
|
11589
11589
|
"stackwalk",
|
|
11590
|
-
"jstracer",
|
|
11591
11590
|
"jsallocations",
|
|
11592
11591
|
"nostacksampling",
|
|
11593
11592
|
"preferencereads",
|
|
@@ -11601,6 +11600,7 @@
|
|
|
11601
11600
|
"markersallthreads",
|
|
11602
11601
|
"unregisteredthreads",
|
|
11603
11602
|
"processcpu",
|
|
11603
|
+
"power",
|
|
11604
11604
|
"responsiveness"
|
|
11605
11605
|
]
|
|
11606
11606
|
},
|
|
@@ -12892,7 +12892,7 @@
|
|
|
12892
12892
|
"matches": {
|
|
12893
12893
|
"type": "array",
|
|
12894
12894
|
"items": {
|
|
12895
|
-
"$ref": "
|
|
12895
|
+
"$ref": "MatchPattern"
|
|
12896
12896
|
}
|
|
12897
12897
|
}
|
|
12898
12898
|
}
|
|
@@ -19320,6 +19320,8 @@
|
|
|
19320
19320
|
"fingerprinting_content",
|
|
19321
19321
|
"cryptomining",
|
|
19322
19322
|
"cryptomining_content",
|
|
19323
|
+
"emailtracking",
|
|
19324
|
+
"emailtracking_content",
|
|
19323
19325
|
"tracking",
|
|
19324
19326
|
"tracking_ad",
|
|
19325
19327
|
"tracking_analytics",
|
|
@@ -11587,7 +11587,6 @@
|
|
|
11587
11587
|
"screenshots",
|
|
11588
11588
|
"seqstyle",
|
|
11589
11589
|
"stackwalk",
|
|
11590
|
-
"jstracer",
|
|
11591
11590
|
"jsallocations",
|
|
11592
11591
|
"nostacksampling",
|
|
11593
11592
|
"preferencereads",
|
|
@@ -11601,6 +11600,7 @@
|
|
|
11601
11600
|
"markersallthreads",
|
|
11602
11601
|
"unregisteredthreads",
|
|
11603
11602
|
"processcpu",
|
|
11603
|
+
"power",
|
|
11604
11604
|
"responsiveness"
|
|
11605
11605
|
]
|
|
11606
11606
|
},
|
|
@@ -12892,7 +12892,7 @@
|
|
|
12892
12892
|
"matches": {
|
|
12893
12893
|
"type": "array",
|
|
12894
12894
|
"items": {
|
|
12895
|
-
"$ref": "
|
|
12895
|
+
"$ref": "MatchPattern"
|
|
12896
12896
|
}
|
|
12897
12897
|
}
|
|
12898
12898
|
}
|
|
@@ -19320,6 +19320,8 @@
|
|
|
19320
19320
|
"fingerprinting_content",
|
|
19321
19321
|
"cryptomining",
|
|
19322
19322
|
"cryptomining_content",
|
|
19323
|
+
"emailtracking",
|
|
19324
|
+
"emailtracking_content",
|
|
19323
19325
|
"tracking",
|
|
19324
19326
|
"tracking_ad",
|
|
19325
19327
|
"tracking_analytics",
|
|
@@ -3402,7 +3402,7 @@
|
|
|
3402
3402
|
{
|
|
3403
3403
|
"id": "ContactProperties",
|
|
3404
3404
|
"type": "object",
|
|
3405
|
-
"description": "A set of properties for a particular contact
|
|
3405
|
+
"description": "A set of individual properties for a particular contact, and its vCard string. Further information can be found in :ref:`howto_contacts`.",
|
|
3406
3406
|
"patternProperties": {
|
|
3407
3407
|
"^\\w+$": {
|
|
3408
3408
|
"choices": [
|
|
@@ -3579,12 +3579,13 @@
|
|
|
3579
3579
|
{
|
|
3580
3580
|
"name": "id",
|
|
3581
3581
|
"type": "string",
|
|
3582
|
-
"description": "Assigns the contact an id. If an existing contact has this id, an exception is thrown.",
|
|
3582
|
+
"description": "Assigns the contact an id. If an existing contact has this id, an exception is thrown. **Note:** Deprecated, the card's id should be specified in the vCard string instead.",
|
|
3583
3583
|
"optional": true
|
|
3584
3584
|
},
|
|
3585
3585
|
{
|
|
3586
3586
|
"name": "properties",
|
|
3587
|
-
"$ref": "ContactProperties"
|
|
3587
|
+
"$ref": "ContactProperties",
|
|
3588
|
+
"description": "The properties object for the new contact. If it includes a <code>vCard</code> member, all specified `legacy properties <https://searchfox.org/comm-central/rev/8a1ae67088acf237dab2fd704db18589e7bf119e/mailnews/addrbook/modules/VCardUtils.jsm#295-334>`__ are ignored and the new contact will be based on the provided vCard string. If a UID is specified in the vCard string, which is already used by another contact, an exception is thrown. **Note:** Using individual properties is deprecated, use the <code>vCard</code> member instead."
|
|
3588
3589
|
},
|
|
3589
3590
|
{
|
|
3590
3591
|
"type": "function",
|
|
@@ -3611,10 +3612,11 @@
|
|
|
3611
3612
|
},
|
|
3612
3613
|
{
|
|
3613
3614
|
"name": "properties",
|
|
3614
|
-
"$ref": "ContactProperties"
|
|
3615
|
+
"$ref": "ContactProperties",
|
|
3616
|
+
"description": "An object with properties to update the specified contact. Individual properties are removed, if they are set to <code>null</code>. If the provided object includes a <code>vCard</code> member, all specified `legacy properties <https://searchfox.org/comm-central/rev/8a1ae67088acf237dab2fd704db18589e7bf119e/mailnews/addrbook/modules/VCardUtils.jsm#295-334>`__ are ignored and the details of the contact will be replaced by the provided vCard. Changes to the UID will be ignored. **Note:** Using individual properties is deprecated, use the <code>vCard</code> member instead. "
|
|
3615
3617
|
}
|
|
3616
3618
|
],
|
|
3617
|
-
"description": "
|
|
3619
|
+
"description": "Updates a contact."
|
|
3618
3620
|
},
|
|
3619
3621
|
{
|
|
3620
3622
|
"name": "delete",
|
|
@@ -9761,19 +9763,19 @@
|
|
|
9761
9763
|
"properties": {
|
|
9762
9764
|
"key": {
|
|
9763
9765
|
"type": "string",
|
|
9764
|
-
"description": "
|
|
9766
|
+
"description": "Unique tag identifier."
|
|
9765
9767
|
},
|
|
9766
9768
|
"tag": {
|
|
9767
9769
|
"type": "string",
|
|
9768
|
-
"description": "Human-readable tag name"
|
|
9770
|
+
"description": "Human-readable tag name."
|
|
9769
9771
|
},
|
|
9770
9772
|
"color": {
|
|
9771
9773
|
"type": "string",
|
|
9772
|
-
"description": "Tag color"
|
|
9774
|
+
"description": "Tag color."
|
|
9773
9775
|
},
|
|
9774
9776
|
"ordinal": {
|
|
9775
9777
|
"type": "string",
|
|
9776
|
-
"description": "Custom sort string (usually empty)"
|
|
9778
|
+
"description": "Custom sort string (usually empty)."
|
|
9777
9779
|
}
|
|
9778
9780
|
}
|
|
9779
9781
|
},
|
|
@@ -10321,7 +10323,7 @@
|
|
|
10321
10323
|
{
|
|
10322
10324
|
"name": "createTag",
|
|
10323
10325
|
"type": "function",
|
|
10324
|
-
"description": "Creates a new message tag. Tagging a message will store the tag's key in the user's message.",
|
|
10326
|
+
"description": "Creates a new message tag. Tagging a message will store the tag's key in the user's message. Throws if the specified tag key is used already.",
|
|
10325
10327
|
"async": true,
|
|
10326
10328
|
"permissions": [
|
|
10327
10329
|
"messagesTags"
|
|
@@ -10330,15 +10332,18 @@
|
|
|
10330
10332
|
{
|
|
10331
10333
|
"type": "string",
|
|
10332
10334
|
"name": "key",
|
|
10335
|
+
"description": "Unique tag identifier (must use only alphanumeric characters).",
|
|
10333
10336
|
"pattern": "^[$a-zA-Z0-9]+$"
|
|
10334
10337
|
},
|
|
10335
10338
|
{
|
|
10336
10339
|
"type": "string",
|
|
10337
|
-
"name": "tag"
|
|
10340
|
+
"name": "tag",
|
|
10341
|
+
"description": "Human-readable tag name."
|
|
10338
10342
|
},
|
|
10339
10343
|
{
|
|
10340
10344
|
"type": "string",
|
|
10341
10345
|
"name": "color",
|
|
10346
|
+
"description": "Tag color in hex format (i.e.: #000080 for navy blue)",
|
|
10342
10347
|
"pattern": "^#[0-9a-f]{6}"
|
|
10343
10348
|
}
|
|
10344
10349
|
]
|
|
@@ -10355,6 +10360,7 @@
|
|
|
10355
10360
|
{
|
|
10356
10361
|
"type": "string",
|
|
10357
10362
|
"name": "key",
|
|
10363
|
+
"description": "Unique tag identifier.",
|
|
10358
10364
|
"pattern": "^[$a-zA-Z0-9]+$"
|
|
10359
10365
|
},
|
|
10360
10366
|
{
|
|
@@ -10363,11 +10369,13 @@
|
|
|
10363
10369
|
"properties": {
|
|
10364
10370
|
"tag": {
|
|
10365
10371
|
"type": "string",
|
|
10366
|
-
"optional": "true"
|
|
10372
|
+
"optional": "true",
|
|
10373
|
+
"description": "Human-readable tag name."
|
|
10367
10374
|
},
|
|
10368
10375
|
"color": {
|
|
10369
10376
|
"type": "string",
|
|
10370
10377
|
"pattern": "^#[0-9a-f]{6}",
|
|
10378
|
+
"description": "Tag color in hex format (i.e.: #000080 for navy blue).",
|
|
10371
10379
|
"optional": "true"
|
|
10372
10380
|
}
|
|
10373
10381
|
}
|
|
@@ -10669,7 +10677,6 @@
|
|
|
10669
10677
|
"panel",
|
|
10670
10678
|
"app",
|
|
10671
10679
|
"devtools",
|
|
10672
|
-
"addressBook",
|
|
10673
10680
|
"messageCompose",
|
|
10674
10681
|
"messageDisplay"
|
|
10675
10682
|
]
|
|
@@ -11501,7 +11508,6 @@
|
|
|
11501
11508
|
"panel",
|
|
11502
11509
|
"app",
|
|
11503
11510
|
"devtools",
|
|
11504
|
-
"addressBook",
|
|
11505
11511
|
"messageCompose",
|
|
11506
11512
|
"messageDisplay"
|
|
11507
11513
|
]
|
|
@@ -3066,7 +3066,7 @@
|
|
|
3066
3066
|
"namespace": "manifest",
|
|
3067
3067
|
"types": [
|
|
3068
3068
|
{
|
|
3069
|
-
"$extend": "
|
|
3069
|
+
"$extend": "PermissionPrivileged",
|
|
3070
3070
|
"choices": [
|
|
3071
3071
|
{
|
|
3072
3072
|
"type": "string",
|
|
@@ -6430,7 +6430,7 @@
|
|
|
6430
6430
|
"namespace": "manifest",
|
|
6431
6431
|
"types": [
|
|
6432
6432
|
{
|
|
6433
|
-
"$extend": "
|
|
6433
|
+
"$extend": "PermissionPrivileged",
|
|
6434
6434
|
"choices": [
|
|
6435
6435
|
{
|
|
6436
6436
|
"type": "string",
|
|
@@ -7275,7 +7275,7 @@
|
|
|
7275
7275
|
"namespace": "manifest",
|
|
7276
7276
|
"types": [
|
|
7277
7277
|
{
|
|
7278
|
-
"$extend": "
|
|
7278
|
+
"$extend": "PermissionPrivileged",
|
|
7279
7279
|
"choices": [
|
|
7280
7280
|
{
|
|
7281
7281
|
"type": "string",
|
|
@@ -10910,7 +10910,8 @@
|
|
|
10910
10910
|
"additionalProperties": {
|
|
10911
10911
|
"$ref": "experiments.ExperimentAPI"
|
|
10912
10912
|
},
|
|
10913
|
-
"optional": true
|
|
10913
|
+
"optional": true,
|
|
10914
|
+
"privileged": true
|
|
10914
10915
|
}
|
|
10915
10916
|
}
|
|
10916
10917
|
}
|
|
@@ -11761,7 +11762,8 @@
|
|
|
11761
11762
|
"items": {
|
|
11762
11763
|
"type": "string"
|
|
11763
11764
|
},
|
|
11764
|
-
"optional": true
|
|
11765
|
+
"optional": true,
|
|
11766
|
+
"privileged": true
|
|
11765
11767
|
}
|
|
11766
11768
|
}
|
|
11767
11769
|
}
|
|
@@ -13089,17 +13091,30 @@
|
|
|
13089
13091
|
}
|
|
13090
13092
|
]
|
|
13091
13093
|
},
|
|
13094
|
+
{
|
|
13095
|
+
"id": "PermissionPrivileged",
|
|
13096
|
+
"choices": [
|
|
13097
|
+
{
|
|
13098
|
+
"type": "string",
|
|
13099
|
+
"enum": [
|
|
13100
|
+
"mozillaAddons"
|
|
13101
|
+
]
|
|
13102
|
+
}
|
|
13103
|
+
]
|
|
13104
|
+
},
|
|
13092
13105
|
{
|
|
13093
13106
|
"id": "PermissionNoPrompt",
|
|
13094
13107
|
"choices": [
|
|
13095
13108
|
{
|
|
13096
|
-
"$ref": "
|
|
13109
|
+
"$ref": "OptionalPermissionNoPrompt"
|
|
13110
|
+
},
|
|
13111
|
+
{
|
|
13112
|
+
"$ref": "PermissionPrivileged"
|
|
13097
13113
|
},
|
|
13098
13114
|
{
|
|
13099
13115
|
"type": "string",
|
|
13100
13116
|
"enum": [
|
|
13101
13117
|
"alarms",
|
|
13102
|
-
"mozillaAddons",
|
|
13103
13118
|
"storage",
|
|
13104
13119
|
"unlimitedStorage"
|
|
13105
13120
|
]
|
|
@@ -13443,7 +13458,7 @@
|
|
|
13443
13458
|
"namespace": "manifest",
|
|
13444
13459
|
"types": [
|
|
13445
13460
|
{
|
|
13446
|
-
"$extend": "
|
|
13461
|
+
"$extend": "PermissionPrivileged",
|
|
13447
13462
|
"choices": [
|
|
13448
13463
|
{
|
|
13449
13464
|
"type": "string",
|
|
@@ -14865,7 +14880,8 @@
|
|
|
14865
14880
|
"type": "boolean",
|
|
14866
14881
|
"optional": true,
|
|
14867
14882
|
"default": false,
|
|
14868
|
-
"description": "Whether to create all cookies as nonPersistent (i.e., session) cookies."
|
|
14883
|
+
"description": "Whether to create all cookies as nonPersistent (i.e., session) cookies.",
|
|
14884
|
+
"deprecated": "This property has no effect anymore and its value is always <code>false<code>."
|
|
14869
14885
|
}
|
|
14870
14886
|
}
|
|
14871
14887
|
}
|
|
@@ -15720,8 +15736,7 @@
|
|
|
15720
15736
|
"type": "string",
|
|
15721
15737
|
"enum": [
|
|
15722
15738
|
"scripting"
|
|
15723
|
-
]
|
|
15724
|
-
"min_manifest_version": 3
|
|
15739
|
+
]
|
|
15725
15740
|
}
|
|
15726
15741
|
]
|
|
15727
15742
|
}
|
|
@@ -15733,7 +15748,6 @@
|
|
|
15733
15748
|
"permissions": [
|
|
15734
15749
|
"scripting"
|
|
15735
15750
|
],
|
|
15736
|
-
"min_manifest_version": 3,
|
|
15737
15751
|
"types": [
|
|
15738
15752
|
{
|
|
15739
15753
|
"id": "ScriptInjection",
|
|
@@ -16635,7 +16649,7 @@
|
|
|
16635
16649
|
}
|
|
16636
16650
|
},
|
|
16637
16651
|
{
|
|
16638
|
-
"$extend": "
|
|
16652
|
+
"$extend": "PermissionPrivileged",
|
|
16639
16653
|
"choices": [
|
|
16640
16654
|
{
|
|
16641
16655
|
"type": "string",
|