webext-schema 5.4.3 → 5.5.1
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 +36 -10
- package/modules/commander.js +1 -1
- package/modules/schema.js +10 -2
- package/modules/update.js +43 -22
- package/package.json +16 -13
- package/schemas/beta/webext.json +519 -156
- package/schemas/central/webext.json +514 -67
- package/schemas/mail/mailext.json +239 -18
- package/schemas/release/webext.json +11 -93
- package/tsconfig.json +4 -1
- package/types/modules/browser.d.ts +11 -10
- package/types/modules/schema.d.ts +10 -10
- package/types/modules/update.d.ts +4 -4
|
@@ -748,54 +748,6 @@
|
|
|
748
748
|
"type": "boolean",
|
|
749
749
|
"optional": true,
|
|
750
750
|
"description": "Sets the default engine to a built-in engine only."
|
|
751
|
-
},
|
|
752
|
-
"params": {
|
|
753
|
-
"optional": true,
|
|
754
|
-
"max_manifest_version": 2,
|
|
755
|
-
"type": "array",
|
|
756
|
-
"items": {
|
|
757
|
-
"type": "object",
|
|
758
|
-
"properties": {
|
|
759
|
-
"name": {
|
|
760
|
-
"type": "string",
|
|
761
|
-
"description": "A url parameter name"
|
|
762
|
-
},
|
|
763
|
-
"condition": {
|
|
764
|
-
"type": "string",
|
|
765
|
-
"optional": true,
|
|
766
|
-
"enum": [
|
|
767
|
-
"purpose",
|
|
768
|
-
"pref"
|
|
769
|
-
],
|
|
770
|
-
"description": "The type of param can be either \"purpose\" or \"pref\"."
|
|
771
|
-
},
|
|
772
|
-
"pref": {
|
|
773
|
-
"type": "string",
|
|
774
|
-
"optional": true,
|
|
775
|
-
"description": "The preference to retrieve the value from.",
|
|
776
|
-
"preprocess": "localize"
|
|
777
|
-
},
|
|
778
|
-
"purpose": {
|
|
779
|
-
"type": "string",
|
|
780
|
-
"optional": true,
|
|
781
|
-
"enum": [
|
|
782
|
-
"contextmenu",
|
|
783
|
-
"searchbar",
|
|
784
|
-
"homepage",
|
|
785
|
-
"keyword",
|
|
786
|
-
"newtab"
|
|
787
|
-
],
|
|
788
|
-
"description": "The context that initiates a search, required if condition is \"purpose\"."
|
|
789
|
-
},
|
|
790
|
-
"value": {
|
|
791
|
-
"type": "string",
|
|
792
|
-
"optional": true,
|
|
793
|
-
"description": "A url parameter value.",
|
|
794
|
-
"preprocess": "localize"
|
|
795
|
-
}
|
|
796
|
-
}
|
|
797
|
-
},
|
|
798
|
-
"description": "A list of optional search url parameters. This allows the additon of search url parameters based on how the search is performed in Firefox."
|
|
799
751
|
}
|
|
800
752
|
}
|
|
801
753
|
}
|
|
@@ -12444,7 +12396,9 @@
|
|
|
12444
12396
|
"responsiveness",
|
|
12445
12397
|
"cpufreq",
|
|
12446
12398
|
"bandwidth",
|
|
12447
|
-
"memory"
|
|
12399
|
+
"memory",
|
|
12400
|
+
"tracing",
|
|
12401
|
+
"sandbox"
|
|
12448
12402
|
]
|
|
12449
12403
|
},
|
|
12450
12404
|
{
|
|
@@ -13911,6 +13865,15 @@
|
|
|
13911
13865
|
"$ref": "UnrecognizedProperty"
|
|
13912
13866
|
}
|
|
13913
13867
|
},
|
|
13868
|
+
{
|
|
13869
|
+
"id": "OptionalOnlyPermission",
|
|
13870
|
+
"choices": [
|
|
13871
|
+
{
|
|
13872
|
+
"type": "string",
|
|
13873
|
+
"enum": []
|
|
13874
|
+
}
|
|
13875
|
+
]
|
|
13876
|
+
},
|
|
13914
13877
|
{
|
|
13915
13878
|
"id": "OptionalPermissionNoPrompt",
|
|
13916
13879
|
"choices": [
|
|
@@ -13945,6 +13908,9 @@
|
|
|
13945
13908
|
{
|
|
13946
13909
|
"$ref": "OptionalPermission"
|
|
13947
13910
|
},
|
|
13911
|
+
{
|
|
13912
|
+
"$ref": "OptionalOnlyPermission"
|
|
13913
|
+
},
|
|
13948
13914
|
{
|
|
13949
13915
|
"$ref": "MatchPattern"
|
|
13950
13916
|
}
|
|
@@ -14418,7 +14384,7 @@
|
|
|
14418
14384
|
{
|
|
14419
14385
|
"name": "getLinkInfo",
|
|
14420
14386
|
"type": "function",
|
|
14421
|
-
"description": "Returns the $(ref:NetworkLinkInfo
|
|
14387
|
+
"description": "Returns the $(ref:NetworkLinkInfo) of the current network connection.",
|
|
14422
14388
|
"async": true,
|
|
14423
14389
|
"parameters": []
|
|
14424
14390
|
}
|
|
@@ -15248,7 +15214,14 @@
|
|
|
15248
15214
|
"permissions": {
|
|
15249
15215
|
"type": "array",
|
|
15250
15216
|
"items": {
|
|
15251
|
-
"
|
|
15217
|
+
"choices": [
|
|
15218
|
+
{
|
|
15219
|
+
"$ref": "manifest.OptionalPermission"
|
|
15220
|
+
},
|
|
15221
|
+
{
|
|
15222
|
+
"$ref": "manifest.OptionalOnlyPermission"
|
|
15223
|
+
}
|
|
15224
|
+
]
|
|
15252
15225
|
},
|
|
15253
15226
|
"optional": true,
|
|
15254
15227
|
"default": []
|
|
@@ -15270,7 +15243,14 @@
|
|
|
15270
15243
|
"permissions": {
|
|
15271
15244
|
"type": "array",
|
|
15272
15245
|
"items": {
|
|
15273
|
-
"
|
|
15246
|
+
"choices": [
|
|
15247
|
+
{
|
|
15248
|
+
"$ref": "manifest.Permission"
|
|
15249
|
+
},
|
|
15250
|
+
{
|
|
15251
|
+
"$ref": "manifest.OptionalOnlyPermission"
|
|
15252
|
+
}
|
|
15253
|
+
]
|
|
15274
15254
|
},
|
|
15275
15255
|
"optional": true,
|
|
15276
15256
|
"default": []
|
|
@@ -16047,6 +16027,11 @@
|
|
|
16047
16027
|
"type": "string",
|
|
16048
16028
|
"optional": true,
|
|
16049
16029
|
"description": "The TLS channel ID of the page or frame that opened the connection, if requested by the extension or app, and if available."
|
|
16030
|
+
},
|
|
16031
|
+
"userScriptWorldId": {
|
|
16032
|
+
"type": "string",
|
|
16033
|
+
"optional": true,
|
|
16034
|
+
"description": "The worldId of the USER_SCRIPT world that sent the message. Only present on onUserScriptMessage and onUserScriptConnect (in port.sender) events."
|
|
16050
16035
|
}
|
|
16051
16036
|
}
|
|
16052
16037
|
},
|
|
@@ -16715,6 +16700,20 @@
|
|
|
16715
16700
|
}
|
|
16716
16701
|
]
|
|
16717
16702
|
},
|
|
16703
|
+
{
|
|
16704
|
+
"name": "onUserScriptConnect",
|
|
16705
|
+
"type": "function",
|
|
16706
|
+
"description": "Fired when a connection is made from a USER_SCRIPT world registered through the userScripts API.",
|
|
16707
|
+
"permissions": [
|
|
16708
|
+
"userScripts"
|
|
16709
|
+
],
|
|
16710
|
+
"parameters": [
|
|
16711
|
+
{
|
|
16712
|
+
"$ref": "Port",
|
|
16713
|
+
"name": "port"
|
|
16714
|
+
}
|
|
16715
|
+
]
|
|
16716
|
+
},
|
|
16718
16717
|
{
|
|
16719
16718
|
"name": "onConnectExternal",
|
|
16720
16719
|
"type": "function",
|
|
@@ -16784,6 +16783,36 @@
|
|
|
16784
16783
|
"description": "Return true from the event listener if you wish to call <code>sendResponse</code> after the event listener returns."
|
|
16785
16784
|
}
|
|
16786
16785
|
},
|
|
16786
|
+
{
|
|
16787
|
+
"name": "onUserScriptMessage",
|
|
16788
|
+
"type": "function",
|
|
16789
|
+
"description": "Fired when a message is sent from a USER_SCRIPT world registered through the userScripts API.",
|
|
16790
|
+
"permissions": [
|
|
16791
|
+
"userScripts"
|
|
16792
|
+
],
|
|
16793
|
+
"parameters": [
|
|
16794
|
+
{
|
|
16795
|
+
"name": "message",
|
|
16796
|
+
"type": "any",
|
|
16797
|
+
"optional": true,
|
|
16798
|
+
"description": "The message sent by the calling script."
|
|
16799
|
+
},
|
|
16800
|
+
{
|
|
16801
|
+
"name": "sender",
|
|
16802
|
+
"$ref": "MessageSender"
|
|
16803
|
+
},
|
|
16804
|
+
{
|
|
16805
|
+
"name": "sendResponse",
|
|
16806
|
+
"type": "function",
|
|
16807
|
+
"description": "Function to call (at most once) when you have a response. The argument should be any JSON-ifiable object. If you have more than one <code>onMessage</code> listener in the same document, then only one may send a response. This function becomes invalid when the event listener returns, unless you return true from the event listener to indicate you wish to send a response asynchronously (this will keep the message channel open to the other end until <code>sendResponse</code> is called)."
|
|
16808
|
+
}
|
|
16809
|
+
],
|
|
16810
|
+
"returns": {
|
|
16811
|
+
"type": "boolean",
|
|
16812
|
+
"optional": true,
|
|
16813
|
+
"description": "Return true from the event listener if you wish to call <code>sendResponse</code> after the event listener returns."
|
|
16814
|
+
}
|
|
16815
|
+
},
|
|
16787
16816
|
{
|
|
16788
16817
|
"name": "onRestartRequired",
|
|
16789
16818
|
"unsupported": true,
|
|
@@ -17873,6 +17902,7 @@
|
|
|
17873
17902
|
},
|
|
17874
17903
|
{
|
|
17875
17904
|
"name": "scalarAdd",
|
|
17905
|
+
"deprecated": "`scalarAdd` is a no-op since Firefox 134 (see bug 1930196)",
|
|
17876
17906
|
"type": "function",
|
|
17877
17907
|
"description": "Adds the value to the given scalar.",
|
|
17878
17908
|
"async": true,
|
|
@@ -17892,6 +17922,7 @@
|
|
|
17892
17922
|
},
|
|
17893
17923
|
{
|
|
17894
17924
|
"name": "scalarSet",
|
|
17925
|
+
"deprecated": "`scalarSet` is a no-op since Firefox 134 (see bug 1930196)",
|
|
17895
17926
|
"type": "function",
|
|
17896
17927
|
"description": "Sets the named scalar to the given value. Throws if the value type doesn't match the scalar type.",
|
|
17897
17928
|
"async": true,
|
|
@@ -17926,6 +17957,7 @@
|
|
|
17926
17957
|
},
|
|
17927
17958
|
{
|
|
17928
17959
|
"name": "scalarSetMaximum",
|
|
17960
|
+
"deprecated": "`scalarSetMaximum` is a no-op since Firefox 134 (see bug 1930196)",
|
|
17929
17961
|
"type": "function",
|
|
17930
17962
|
"description": "Sets the scalar to the maximum of the current and the passed value",
|
|
17931
17963
|
"async": true,
|
|
@@ -17945,6 +17977,7 @@
|
|
|
17945
17977
|
},
|
|
17946
17978
|
{
|
|
17947
17979
|
"name": "keyedScalarAdd",
|
|
17980
|
+
"deprecated": "`keyedScalarAdd` is a no-op since Firefox 134 (see bug 1930196)",
|
|
17948
17981
|
"type": "function",
|
|
17949
17982
|
"description": "Adds the value to the given keyed scalar.",
|
|
17950
17983
|
"async": true,
|
|
@@ -17969,6 +18002,7 @@
|
|
|
17969
18002
|
},
|
|
17970
18003
|
{
|
|
17971
18004
|
"name": "keyedScalarSet",
|
|
18005
|
+
"deprecated": "`keyedScalarSet` is a no-op since Firefox 134 (see bug 1930196)",
|
|
17972
18006
|
"type": "function",
|
|
17973
18007
|
"description": "Sets the keyed scalar to the given value. Throws if the value type doesn't match the scalar type.",
|
|
17974
18008
|
"async": true,
|
|
@@ -18008,6 +18042,7 @@
|
|
|
18008
18042
|
},
|
|
18009
18043
|
{
|
|
18010
18044
|
"name": "keyedScalarSetMaximum",
|
|
18045
|
+
"deprecated": "`keyedScalarSetMaximum` is a no-op since Firefox 134 (see bug 1930196)",
|
|
18011
18046
|
"type": "function",
|
|
18012
18047
|
"description": "Sets the keyed scalar to the maximum of the current and the passed value",
|
|
18013
18048
|
"async": true,
|
|
@@ -18032,7 +18067,7 @@
|
|
|
18032
18067
|
},
|
|
18033
18068
|
{
|
|
18034
18069
|
"name": "recordEvent",
|
|
18035
|
-
"deprecated": "`recordEvent`
|
|
18070
|
+
"deprecated": "`recordEvent` is a no-op since Firefox 132 (see bug 1894533)",
|
|
18036
18071
|
"type": "function",
|
|
18037
18072
|
"description": "Record an event in Telemetry. Throws when trying to record an unknown event.",
|
|
18038
18073
|
"async": true,
|
|
@@ -18071,6 +18106,7 @@
|
|
|
18071
18106
|
},
|
|
18072
18107
|
{
|
|
18073
18108
|
"name": "registerScalars",
|
|
18109
|
+
"deprecated": "`registerScalars` is a no-op since Firefox 134 (see bug 1930196)",
|
|
18074
18110
|
"type": "function",
|
|
18075
18111
|
"description": "Register new scalars to record them from addons. See nsITelemetry.idl for more details.",
|
|
18076
18112
|
"async": true,
|
|
@@ -18092,7 +18128,7 @@
|
|
|
18092
18128
|
},
|
|
18093
18129
|
{
|
|
18094
18130
|
"name": "registerEvents",
|
|
18095
|
-
"deprecated": "`registerEvents`
|
|
18131
|
+
"deprecated": "`registerEvents` is a no-op since Firefox 132 (see bug 1894533)",
|
|
18096
18132
|
"type": "function",
|
|
18097
18133
|
"description": "Register new events to record them from addons. See nsITelemetry.idl for more details.",
|
|
18098
18134
|
"async": true,
|
|
@@ -18114,8 +18150,9 @@
|
|
|
18114
18150
|
},
|
|
18115
18151
|
{
|
|
18116
18152
|
"name": "setEventRecordingEnabled",
|
|
18153
|
+
"deprecated": "`setEventRecordingEnabled` is a no-op since Firefox 133 (see bug 1920562)",
|
|
18117
18154
|
"type": "function",
|
|
18118
|
-
"description": "Enable recording of events in a category. Events default to recording
|
|
18155
|
+
"description": "Enable recording of events in a category. Events default to recording enabled. This allows to toggle recording for all events in the specified category.",
|
|
18119
18156
|
"async": true,
|
|
18120
18157
|
"parameters": [
|
|
18121
18158
|
{
|
|
@@ -18937,6 +18974,110 @@
|
|
|
18937
18974
|
]
|
|
18938
18975
|
}
|
|
18939
18976
|
],
|
|
18977
|
+
"trial_ml.json": [
|
|
18978
|
+
{
|
|
18979
|
+
"namespace": "manifest",
|
|
18980
|
+
"types": [
|
|
18981
|
+
{
|
|
18982
|
+
"$extend": "OptionalOnlyPermission",
|
|
18983
|
+
"choices": [
|
|
18984
|
+
{
|
|
18985
|
+
"type": "string",
|
|
18986
|
+
"enum": [
|
|
18987
|
+
"trialML"
|
|
18988
|
+
]
|
|
18989
|
+
}
|
|
18990
|
+
]
|
|
18991
|
+
}
|
|
18992
|
+
]
|
|
18993
|
+
},
|
|
18994
|
+
{
|
|
18995
|
+
"namespace": "trial",
|
|
18996
|
+
"allowedContexts": [
|
|
18997
|
+
"content"
|
|
18998
|
+
],
|
|
18999
|
+
"permissions": [
|
|
19000
|
+
"trialML"
|
|
19001
|
+
]
|
|
19002
|
+
},
|
|
19003
|
+
{
|
|
19004
|
+
"namespace": "trial.ml",
|
|
19005
|
+
"description": "Use the trial ML API to run Machine Learning models requests from extensions pages or content scripts.",
|
|
19006
|
+
"allowedContexts": [
|
|
19007
|
+
"content"
|
|
19008
|
+
],
|
|
19009
|
+
"permissions": [
|
|
19010
|
+
"trialML"
|
|
19011
|
+
],
|
|
19012
|
+
"events": [
|
|
19013
|
+
{
|
|
19014
|
+
"name": "onProgress",
|
|
19015
|
+
"type": "function",
|
|
19016
|
+
"allowedContexts": [
|
|
19017
|
+
"content"
|
|
19018
|
+
],
|
|
19019
|
+
"description": "Events from the inference engine.",
|
|
19020
|
+
"parameters": [
|
|
19021
|
+
{
|
|
19022
|
+
"name": "progressData",
|
|
19023
|
+
"description": "Object containing the data, see https://firefox-source-docs.mozilla.org/toolkit/components/ml/notifications.html",
|
|
19024
|
+
"type": "object"
|
|
19025
|
+
}
|
|
19026
|
+
]
|
|
19027
|
+
}
|
|
19028
|
+
],
|
|
19029
|
+
"types": [
|
|
19030
|
+
{
|
|
19031
|
+
"id": "CreateEngineRequest",
|
|
19032
|
+
"type": "object",
|
|
19033
|
+
"additionalProperties": true
|
|
19034
|
+
},
|
|
19035
|
+
{
|
|
19036
|
+
"id": "RunEngineRequest",
|
|
19037
|
+
"type": "object",
|
|
19038
|
+
"additionalProperties": true
|
|
19039
|
+
}
|
|
19040
|
+
],
|
|
19041
|
+
"functions": [
|
|
19042
|
+
{
|
|
19043
|
+
"name": "createEngine",
|
|
19044
|
+
"type": "function",
|
|
19045
|
+
"description": "Prepare the inference engine",
|
|
19046
|
+
"async": true,
|
|
19047
|
+
"parameters": [
|
|
19048
|
+
{
|
|
19049
|
+
"name": "CreateEngineRequest",
|
|
19050
|
+
"$ref": "CreateEngineRequest"
|
|
19051
|
+
}
|
|
19052
|
+
]
|
|
19053
|
+
},
|
|
19054
|
+
{
|
|
19055
|
+
"name": "runEngine",
|
|
19056
|
+
"type": "function",
|
|
19057
|
+
"allowedContexts": [
|
|
19058
|
+
"content"
|
|
19059
|
+
],
|
|
19060
|
+
"description": "Call the inference engine",
|
|
19061
|
+
"async": true,
|
|
19062
|
+
"parameters": [
|
|
19063
|
+
{
|
|
19064
|
+
"name": "RunEngineRequest",
|
|
19065
|
+
"$ref": "RunEngineRequest"
|
|
19066
|
+
}
|
|
19067
|
+
]
|
|
19068
|
+
},
|
|
19069
|
+
{
|
|
19070
|
+
"name": "deleteCachedModels",
|
|
19071
|
+
"type": "function",
|
|
19072
|
+
"allowedContexts": [
|
|
19073
|
+
"content"
|
|
19074
|
+
],
|
|
19075
|
+
"description": "Delete the models the extension downloaded.",
|
|
19076
|
+
"async": true
|
|
19077
|
+
}
|
|
19078
|
+
]
|
|
19079
|
+
}
|
|
19080
|
+
],
|
|
18940
19081
|
"types.json": [
|
|
18941
19082
|
{
|
|
18942
19083
|
"namespace": "types",
|
|
@@ -19109,6 +19250,17 @@
|
|
|
19109
19250
|
{
|
|
19110
19251
|
"namespace": "manifest",
|
|
19111
19252
|
"types": [
|
|
19253
|
+
{
|
|
19254
|
+
"$extend": "OptionalOnlyPermission",
|
|
19255
|
+
"choices": [
|
|
19256
|
+
{
|
|
19257
|
+
"type": "string",
|
|
19258
|
+
"enum": [
|
|
19259
|
+
"userScripts"
|
|
19260
|
+
]
|
|
19261
|
+
}
|
|
19262
|
+
]
|
|
19263
|
+
},
|
|
19112
19264
|
{
|
|
19113
19265
|
"$extend": "WebExtensionManifest",
|
|
19114
19266
|
"properties": {
|
|
@@ -19132,13 +19284,14 @@
|
|
|
19132
19284
|
},
|
|
19133
19285
|
{
|
|
19134
19286
|
"namespace": "userScripts",
|
|
19135
|
-
"max_manifest_version": 2,
|
|
19136
19287
|
"permissions": [
|
|
19137
|
-
"manifest:user_scripts"
|
|
19288
|
+
"manifest:user_scripts",
|
|
19289
|
+
"userScripts"
|
|
19138
19290
|
],
|
|
19139
19291
|
"types": [
|
|
19140
19292
|
{
|
|
19141
19293
|
"id": "UserScriptOptions",
|
|
19294
|
+
"max_manifest_version": 2,
|
|
19142
19295
|
"type": "object",
|
|
19143
19296
|
"description": "Details of a user script",
|
|
19144
19297
|
"properties": {
|
|
@@ -19224,29 +19377,322 @@
|
|
|
19224
19377
|
},
|
|
19225
19378
|
{
|
|
19226
19379
|
"id": "RegisteredUserScript",
|
|
19380
|
+
"min_manifest_version": 3,
|
|
19227
19381
|
"type": "object",
|
|
19228
19382
|
"description": "An object that represents a user script registered programmatically",
|
|
19229
|
-
"
|
|
19383
|
+
"properties": {
|
|
19384
|
+
"id": {
|
|
19385
|
+
"type": "string",
|
|
19386
|
+
"optional": false,
|
|
19387
|
+
"description": "The ID of the user script specified in the API call. This property must not start with a '_' as it's reserved as a prefix for generated script IDs."
|
|
19388
|
+
},
|
|
19389
|
+
"allFrames": {
|
|
19390
|
+
"type": "boolean",
|
|
19391
|
+
"optional": true,
|
|
19392
|
+
"description": "If allFrames is <code>true</code>, implies that the JavaScript should be injected into all frames of current page. By default, it's <code>false</code> and is only injected into the top frame."
|
|
19393
|
+
},
|
|
19394
|
+
"js": {
|
|
19395
|
+
"type": "array",
|
|
19396
|
+
"optional": false,
|
|
19397
|
+
"description": "The list of ScriptSource objects defining sources of scripts to be injected into matching pages.",
|
|
19398
|
+
"items": {
|
|
19399
|
+
"$ref": "ScriptSource"
|
|
19400
|
+
}
|
|
19401
|
+
},
|
|
19402
|
+
"matches": {
|
|
19403
|
+
"type": "array",
|
|
19404
|
+
"optional": true,
|
|
19405
|
+
"description": "At least one of matches or includeGlobs should be non-empty. The script runs in documents whose URL match either pattern.",
|
|
19406
|
+
"items": {
|
|
19407
|
+
"$ref": "manifest.MatchPattern"
|
|
19408
|
+
}
|
|
19409
|
+
},
|
|
19410
|
+
"excludeMatches": {
|
|
19411
|
+
"type": "array",
|
|
19412
|
+
"optional": true,
|
|
19413
|
+
"items": {
|
|
19414
|
+
"$ref": "manifest.MatchPattern"
|
|
19415
|
+
}
|
|
19416
|
+
},
|
|
19417
|
+
"includeGlobs": {
|
|
19418
|
+
"type": "array",
|
|
19419
|
+
"optional": true,
|
|
19420
|
+
"description": "At least one of matches or includeGlobs should be non-empty. The script runs in documents whose URL match either pattern.",
|
|
19421
|
+
"items": {
|
|
19422
|
+
"type": "string"
|
|
19423
|
+
}
|
|
19424
|
+
},
|
|
19425
|
+
"excludeGlobs": {
|
|
19426
|
+
"type": "array",
|
|
19427
|
+
"optional": true,
|
|
19428
|
+
"items": {
|
|
19429
|
+
"type": "string"
|
|
19430
|
+
}
|
|
19431
|
+
},
|
|
19432
|
+
"runAt": {
|
|
19433
|
+
"$ref": "extensionTypes.RunAt",
|
|
19434
|
+
"optional": true,
|
|
19435
|
+
"description": "The soonest that the JavaScript will be injected into the tab. Defaults to \"document_idle\"."
|
|
19436
|
+
},
|
|
19437
|
+
"world": {
|
|
19438
|
+
"$ref": "ExecutionWorld",
|
|
19439
|
+
"optional": true,
|
|
19440
|
+
"description": "The JavaScript script for a script to execute within. Defaults to \"USER_SCRIPT\"."
|
|
19441
|
+
},
|
|
19442
|
+
"worldId": {
|
|
19443
|
+
"type": "string",
|
|
19444
|
+
"optional": true,
|
|
19445
|
+
"description": "If specified, specifies a specific user script world ID to execute in. Only valid if `world` is omitted or is `USER_SCRIPT`. If `worldId` is omitted, the script will execute in the default user script world (\"\"). Values with leading underscores (`_`) are reserved. The maximum length is 256."
|
|
19446
|
+
}
|
|
19447
|
+
}
|
|
19448
|
+
},
|
|
19449
|
+
{
|
|
19450
|
+
"id": "ExecutionWorld",
|
|
19451
|
+
"min_manifest_version": 3,
|
|
19452
|
+
"type": "string",
|
|
19453
|
+
"enum": [
|
|
19454
|
+
"MAIN",
|
|
19455
|
+
"USER_SCRIPT"
|
|
19456
|
+
],
|
|
19457
|
+
"description": "The JavaScript world for a script to execute within. <code>USER_SCRIPT</code> is the default execution environment of user scripts, <code>MAIN</code> is the web page's execution environment."
|
|
19458
|
+
},
|
|
19459
|
+
{
|
|
19460
|
+
"id": "UserScriptFilter",
|
|
19461
|
+
"min_manifest_version": 3,
|
|
19462
|
+
"type": "object",
|
|
19463
|
+
"description": "Optional filter to use with getScripts() and unregister().",
|
|
19464
|
+
"properties": {
|
|
19465
|
+
"ids": {
|
|
19466
|
+
"type": "array",
|
|
19467
|
+
"optional": true,
|
|
19468
|
+
"items": {
|
|
19469
|
+
"type": "string"
|
|
19470
|
+
}
|
|
19471
|
+
}
|
|
19472
|
+
}
|
|
19473
|
+
},
|
|
19474
|
+
{
|
|
19475
|
+
"id": "ScriptSource",
|
|
19476
|
+
"min_manifest_version": 3,
|
|
19477
|
+
"description": "Object with file xor code property. Equivalent to the ExtensionFileOrCode, except the file remains a relative URL.",
|
|
19478
|
+
"choices": [
|
|
19230
19479
|
{
|
|
19231
|
-
"
|
|
19232
|
-
"
|
|
19233
|
-
|
|
19234
|
-
|
|
19235
|
-
|
|
19480
|
+
"type": "object",
|
|
19481
|
+
"properties": {
|
|
19482
|
+
"file": {
|
|
19483
|
+
"type": "string",
|
|
19484
|
+
"description": "The path of the JavaScript file to inject relative to the extension's root directory.",
|
|
19485
|
+
"format": "unresolvedRelativeUrl"
|
|
19486
|
+
}
|
|
19487
|
+
}
|
|
19488
|
+
},
|
|
19489
|
+
{
|
|
19490
|
+
"type": "object",
|
|
19491
|
+
"properties": {
|
|
19492
|
+
"code": {
|
|
19493
|
+
"type": "string"
|
|
19494
|
+
}
|
|
19495
|
+
}
|
|
19236
19496
|
}
|
|
19237
19497
|
]
|
|
19498
|
+
},
|
|
19499
|
+
{
|
|
19500
|
+
"id": "WorldProperties",
|
|
19501
|
+
"min_manifest_version": 3,
|
|
19502
|
+
"type": "object",
|
|
19503
|
+
"description": "The configuration of a USER_SCRIPT world.",
|
|
19504
|
+
"properties": {
|
|
19505
|
+
"worldId": {
|
|
19506
|
+
"type": "string",
|
|
19507
|
+
"optional": true,
|
|
19508
|
+
"default": "",
|
|
19509
|
+
"description": "The identifier of the world. Values with leading underscores (`_`) are reserved. The maximum length is 256. Defaults to the default USER_SCRIPT world (\"\")."
|
|
19510
|
+
},
|
|
19511
|
+
"csp": {
|
|
19512
|
+
"type": "string",
|
|
19513
|
+
"optional": true,
|
|
19514
|
+
"description": "The world's Content Security Policy. Defaults to the CSP of regular content scripts, which prohibits dynamic code execution such as eval."
|
|
19515
|
+
},
|
|
19516
|
+
"messaging": {
|
|
19517
|
+
"type": "boolean",
|
|
19518
|
+
"optional": true,
|
|
19519
|
+
"default": false,
|
|
19520
|
+
"description": "Whether the runtime.sendMessage and runtime.connect methods are exposed. Defaults to not exposing these messaging APIs."
|
|
19521
|
+
}
|
|
19522
|
+
}
|
|
19238
19523
|
}
|
|
19239
19524
|
],
|
|
19240
19525
|
"functions": [
|
|
19241
19526
|
{
|
|
19242
19527
|
"name": "register",
|
|
19528
|
+
"max_manifest_version": 2,
|
|
19243
19529
|
"type": "function",
|
|
19244
|
-
"description": "Register a user script programmatically given its $(ref:userScripts.UserScriptOptions), and resolves to
|
|
19245
|
-
"async":
|
|
19530
|
+
"description": "Register a user script programmatically given its $(ref:userScripts.UserScriptOptions), and resolves to an object with the unregister() function",
|
|
19531
|
+
"async": "callback",
|
|
19246
19532
|
"parameters": [
|
|
19247
19533
|
{
|
|
19248
19534
|
"name": "userScriptOptions",
|
|
19249
19535
|
"$ref": "UserScriptOptions"
|
|
19536
|
+
},
|
|
19537
|
+
{
|
|
19538
|
+
"name": "callback",
|
|
19539
|
+
"type": "function",
|
|
19540
|
+
"parameters": [
|
|
19541
|
+
{
|
|
19542
|
+
"name": "legacyRegisteredUserScript",
|
|
19543
|
+
"type": "object",
|
|
19544
|
+
"description": "An object that represents a user script registered programmatically",
|
|
19545
|
+
"properties": {
|
|
19546
|
+
"unregister": {
|
|
19547
|
+
"type": "function",
|
|
19548
|
+
"description": "Unregister a user script registered programmatically",
|
|
19549
|
+
"async": true,
|
|
19550
|
+
"parameters": []
|
|
19551
|
+
}
|
|
19552
|
+
}
|
|
19553
|
+
}
|
|
19554
|
+
]
|
|
19555
|
+
}
|
|
19556
|
+
]
|
|
19557
|
+
},
|
|
19558
|
+
{
|
|
19559
|
+
"name": "register",
|
|
19560
|
+
"min_manifest_version": 3,
|
|
19561
|
+
"type": "function",
|
|
19562
|
+
"description": "Registers one or more user scripts for this extension.",
|
|
19563
|
+
"async": true,
|
|
19564
|
+
"parameters": [
|
|
19565
|
+
{
|
|
19566
|
+
"name": "scripts",
|
|
19567
|
+
"type": "array",
|
|
19568
|
+
"items": {
|
|
19569
|
+
"$ref": "RegisteredUserScript"
|
|
19570
|
+
},
|
|
19571
|
+
"description": "List of user scripts to be registered."
|
|
19572
|
+
}
|
|
19573
|
+
]
|
|
19574
|
+
},
|
|
19575
|
+
{
|
|
19576
|
+
"name": "update",
|
|
19577
|
+
"min_manifest_version": 3,
|
|
19578
|
+
"type": "function",
|
|
19579
|
+
"description": "Updates one or more user scripts for this extension.",
|
|
19580
|
+
"async": true,
|
|
19581
|
+
"parameters": [
|
|
19582
|
+
{
|
|
19583
|
+
"name": "scripts",
|
|
19584
|
+
"type": "array",
|
|
19585
|
+
"items": {
|
|
19586
|
+
"type": "object",
|
|
19587
|
+
"$import": "RegisteredUserScript",
|
|
19588
|
+
"properties": {
|
|
19589
|
+
"js": {
|
|
19590
|
+
"type": "array",
|
|
19591
|
+
"optional": true,
|
|
19592
|
+
"items": {
|
|
19593
|
+
"$ref": "ScriptSource"
|
|
19594
|
+
}
|
|
19595
|
+
}
|
|
19596
|
+
}
|
|
19597
|
+
},
|
|
19598
|
+
"description": "List of user scripts to be updated."
|
|
19599
|
+
}
|
|
19600
|
+
]
|
|
19601
|
+
},
|
|
19602
|
+
{
|
|
19603
|
+
"name": "unregister",
|
|
19604
|
+
"min_manifest_version": 3,
|
|
19605
|
+
"type": "function",
|
|
19606
|
+
"description": "Unregisters all dynamically-registered user scripts for this extension.",
|
|
19607
|
+
"async": true,
|
|
19608
|
+
"parameters": [
|
|
19609
|
+
{
|
|
19610
|
+
"name": "filter",
|
|
19611
|
+
"$ref": "UserScriptFilter",
|
|
19612
|
+
"optional": true,
|
|
19613
|
+
"description": "If specified, this method unregisters only the user scripts that match it."
|
|
19614
|
+
}
|
|
19615
|
+
]
|
|
19616
|
+
},
|
|
19617
|
+
{
|
|
19618
|
+
"name": "getScripts",
|
|
19619
|
+
"min_manifest_version": 3,
|
|
19620
|
+
"type": "function",
|
|
19621
|
+
"description": "Returns all dynamically-registered user scripts for this extension.",
|
|
19622
|
+
"async": "callback",
|
|
19623
|
+
"parameters": [
|
|
19624
|
+
{
|
|
19625
|
+
"name": "filter",
|
|
19626
|
+
"$ref": "UserScriptFilter",
|
|
19627
|
+
"optional": true,
|
|
19628
|
+
"description": "If specified, this method returns only the user scripts that match it."
|
|
19629
|
+
},
|
|
19630
|
+
{
|
|
19631
|
+
"name": "callback",
|
|
19632
|
+
"type": "function",
|
|
19633
|
+
"parameters": [
|
|
19634
|
+
{
|
|
19635
|
+
"name": "scripts",
|
|
19636
|
+
"type": "array",
|
|
19637
|
+
"items": {
|
|
19638
|
+
"$ref": "RegisteredUserScript"
|
|
19639
|
+
},
|
|
19640
|
+
"description": "List of registered user scripts."
|
|
19641
|
+
}
|
|
19642
|
+
]
|
|
19643
|
+
}
|
|
19644
|
+
]
|
|
19645
|
+
},
|
|
19646
|
+
{
|
|
19647
|
+
"name": "configureWorld",
|
|
19648
|
+
"min_manifest_version": 3,
|
|
19649
|
+
"type": "function",
|
|
19650
|
+
"description": "Configures the environment for scripts running in a USER_SCRIPT world.",
|
|
19651
|
+
"async": true,
|
|
19652
|
+
"parameters": [
|
|
19653
|
+
{
|
|
19654
|
+
"name": "properties",
|
|
19655
|
+
"$ref": "WorldProperties",
|
|
19656
|
+
"description": "The desired configuration for a USER_SCRIPT world."
|
|
19657
|
+
}
|
|
19658
|
+
]
|
|
19659
|
+
},
|
|
19660
|
+
{
|
|
19661
|
+
"name": "resetWorldConfiguration",
|
|
19662
|
+
"min_manifest_version": 3,
|
|
19663
|
+
"type": "function",
|
|
19664
|
+
"description": "Resets the configuration for a given world. That world will fall back to the default world's configuration.",
|
|
19665
|
+
"async": true,
|
|
19666
|
+
"parameters": [
|
|
19667
|
+
{
|
|
19668
|
+
"name": "worldId",
|
|
19669
|
+
"type": "string",
|
|
19670
|
+
"optional": true,
|
|
19671
|
+
"default": "",
|
|
19672
|
+
"description": "The ID of the USER_SCRIPT world to reset. If omitted or empty, resets the default world's configuration."
|
|
19673
|
+
}
|
|
19674
|
+
]
|
|
19675
|
+
},
|
|
19676
|
+
{
|
|
19677
|
+
"name": "getWorldConfigurations",
|
|
19678
|
+
"min_manifest_version": 3,
|
|
19679
|
+
"type": "function",
|
|
19680
|
+
"description": "Returns all registered USER_SCRIPT world configurations.",
|
|
19681
|
+
"async": "callback",
|
|
19682
|
+
"parameters": [
|
|
19683
|
+
{
|
|
19684
|
+
"name": "callback",
|
|
19685
|
+
"type": "function",
|
|
19686
|
+
"parameters": [
|
|
19687
|
+
{
|
|
19688
|
+
"name": "configurations",
|
|
19689
|
+
"type": "array",
|
|
19690
|
+
"items": {
|
|
19691
|
+
"$ref": "WorldProperties"
|
|
19692
|
+
},
|
|
19693
|
+
"description": "All configurations registered with configureWorld()."
|
|
19694
|
+
}
|
|
19695
|
+
]
|
|
19250
19696
|
}
|
|
19251
19697
|
]
|
|
19252
19698
|
}
|
|
@@ -19256,9 +19702,9 @@
|
|
|
19256
19702
|
"user_scripts_content.json": [
|
|
19257
19703
|
{
|
|
19258
19704
|
"namespace": "userScripts",
|
|
19259
|
-
"max_manifest_version": 2,
|
|
19260
19705
|
"permissions": [
|
|
19261
|
-
"manifest:user_scripts"
|
|
19706
|
+
"manifest:user_scripts",
|
|
19707
|
+
"userScripts"
|
|
19262
19708
|
],
|
|
19263
19709
|
"allowedContexts": [
|
|
19264
19710
|
"content"
|
|
@@ -19266,6 +19712,7 @@
|
|
|
19266
19712
|
"events": [
|
|
19267
19713
|
{
|
|
19268
19714
|
"name": "onBeforeScript",
|
|
19715
|
+
"max_manifest_version": 2,
|
|
19269
19716
|
"permissions": [
|
|
19270
19717
|
"manifest:user_scripts.api_script"
|
|
19271
19718
|
],
|