chrome-types 0.1.428 → 0.1.430
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/_all.d.ts +220 -48
- package/index.d.ts +220 -48
- package/package.json +2 -2
package/_all.d.ts
CHANGED
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
-
// Generated on Thu
|
|
18
|
-
// Built at
|
|
17
|
+
// Generated on Thu Jun 25 2026 22:48:21 GMT+0000 (Coordinated Universal Time)
|
|
18
|
+
// Built at 40eff249d43ce574d7772af8be25f8d7a66e8e70
|
|
19
19
|
|
|
20
20
|
// Includes all types, including MV2 + Platform Apps APIs.
|
|
21
21
|
|
|
@@ -753,7 +753,7 @@ declare namespace chrome {
|
|
|
753
753
|
/**
|
|
754
754
|
* Whether the alarm should persist across sessions (browser restarts).
|
|
755
755
|
*
|
|
756
|
-
* @since
|
|
756
|
+
* @since Chrome 150
|
|
757
757
|
*/
|
|
758
758
|
persistAcrossSessions: boolean;
|
|
759
759
|
}
|
|
@@ -778,7 +778,7 @@ declare namespace chrome {
|
|
|
778
778
|
/**
|
|
779
779
|
* Whether the alarm should persist across sessions (browser restarts). In Chrome, this defaults to true to match historical behavior, but you should set this explicitly to maximize compatibility across browsers.
|
|
780
780
|
*
|
|
781
|
-
* @since
|
|
781
|
+
* @since Chrome 150
|
|
782
782
|
*/
|
|
783
783
|
persistAcrossSessions?: boolean;
|
|
784
784
|
}
|
|
@@ -9765,26 +9765,69 @@ declare namespace chrome {
|
|
|
9765
9765
|
/**
|
|
9766
9766
|
* Gets the content of the resource.
|
|
9767
9767
|
*
|
|
9768
|
-
* @
|
|
9768
|
+
* @chrome-returns-extra since Pending
|
|
9769
|
+
* @returns A function that receives resource content when the request completes.
|
|
9770
|
+
*/
|
|
9771
|
+
getContent(): Promise<{
|
|
9772
|
+
|
|
9773
|
+
/**
|
|
9774
|
+
* Content of the resource (potentially encoded).
|
|
9775
|
+
*/
|
|
9776
|
+
content: string,
|
|
9777
|
+
|
|
9778
|
+
/**
|
|
9779
|
+
* Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
9780
|
+
*/
|
|
9781
|
+
encoding: string,
|
|
9782
|
+
}>;
|
|
9783
|
+
|
|
9784
|
+
/**
|
|
9785
|
+
* Gets the content of the resource.
|
|
9769
9786
|
*/
|
|
9770
9787
|
getContent(
|
|
9771
9788
|
|
|
9772
9789
|
/**
|
|
9773
|
-
* @param
|
|
9774
|
-
* @param encoding Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
9790
|
+
* @param response An object containing the resource content and its encoding.
|
|
9775
9791
|
*/
|
|
9776
|
-
callback
|
|
9777
|
-
|
|
9778
|
-
|
|
9792
|
+
callback?: (
|
|
9793
|
+
/**
|
|
9794
|
+
* @since Pending
|
|
9795
|
+
*/
|
|
9796
|
+
response: {
|
|
9797
|
+
|
|
9798
|
+
/**
|
|
9799
|
+
* Content of the resource (potentially encoded).
|
|
9800
|
+
*/
|
|
9801
|
+
content: string,
|
|
9802
|
+
|
|
9803
|
+
/**
|
|
9804
|
+
* Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
9805
|
+
*/
|
|
9806
|
+
encoding: string,
|
|
9807
|
+
},
|
|
9779
9808
|
) => void,
|
|
9780
9809
|
): void;
|
|
9781
9810
|
|
|
9811
|
+
/**
|
|
9812
|
+
* Sets the content of the resource.
|
|
9813
|
+
*
|
|
9814
|
+
* @chrome-returns-extra since Pending
|
|
9815
|
+
* @param content New content of the resource. Only resources with the text type are currently supported.
|
|
9816
|
+
* @param commit True if the user has finished editing the resource, and the new content of the resource should be persisted; false if this is a minor change sent in progress of the user editing the resource.
|
|
9817
|
+
* @returns A function called upon request completion.
|
|
9818
|
+
*/
|
|
9819
|
+
setContent(
|
|
9820
|
+
|
|
9821
|
+
content: string,
|
|
9822
|
+
|
|
9823
|
+
commit: boolean,
|
|
9824
|
+
): Promise<{[name: string]: any} | undefined>;
|
|
9825
|
+
|
|
9782
9826
|
/**
|
|
9783
9827
|
* Sets the content of the resource.
|
|
9784
9828
|
*
|
|
9785
9829
|
* @param content New content of the resource. Only resources with the text type are currently supported.
|
|
9786
9830
|
* @param commit True if the user has finished editing the resource, and the new content of the resource should be persisted; false if this is a minor change sent in progress of the user editing the resource.
|
|
9787
|
-
* @param callback A function called upon request completion.
|
|
9788
9831
|
*/
|
|
9789
9832
|
setContent(
|
|
9790
9833
|
|
|
@@ -9823,12 +9866,86 @@ declare namespace chrome {
|
|
|
9823
9866
|
|
|
9824
9867
|
export {_eval as eval};
|
|
9825
9868
|
|
|
9869
|
+
/**
|
|
9870
|
+
* Evaluates a JavaScript expression in the context of the main frame of the inspected page. The expression must evaluate to a JSON-compliant object, otherwise an exception is thrown. The eval function can report either a DevTools-side error or a JavaScript exception that occurs during evaluation. In either case, the `result` parameter of the callback is `undefined`. In the case of a DevTools-side error, the `isException` parameter is non-null and has `isError` set to true and `code` set to an error code. In the case of a JavaScript error, `isException` is set to true and `value` is set to the string value of thrown object.
|
|
9871
|
+
*
|
|
9872
|
+
* @chrome-returns-extra since Pending
|
|
9873
|
+
* @param expression An expression to evaluate.
|
|
9874
|
+
* @param options The options parameter can contain one or more options.
|
|
9875
|
+
* @returns A function called when evaluation completes.
|
|
9876
|
+
*/
|
|
9877
|
+
function _eval(
|
|
9878
|
+
|
|
9879
|
+
expression: string,
|
|
9880
|
+
|
|
9881
|
+
options?: {
|
|
9882
|
+
|
|
9883
|
+
/**
|
|
9884
|
+
* If specified, the expression is evaluated on the iframe whose URL matches the one specified. By default, the expression is evaluated in the top frame of the inspected page.
|
|
9885
|
+
*/
|
|
9886
|
+
frameURL?: string,
|
|
9887
|
+
|
|
9888
|
+
/**
|
|
9889
|
+
* Evaluate the expression in the context of the content script of the calling extension, provided that the content script is already injected into the inspected page. If not, the expression is not evaluated and the callback is invoked with the exception parameter set to an object that has the `isError` field set to true and the `code` field set to `E_NOTFOUND`.
|
|
9890
|
+
*/
|
|
9891
|
+
useContentScriptContext?: boolean,
|
|
9892
|
+
|
|
9893
|
+
/**
|
|
9894
|
+
* Evaluate the expression in the context of a content script of an extension that matches the specified origin. If given, scriptExecutionContext overrides the 'true' setting on useContentScriptContext.
|
|
9895
|
+
*
|
|
9896
|
+
* @since Chrome 107
|
|
9897
|
+
*/
|
|
9898
|
+
scriptExecutionContext?: string,
|
|
9899
|
+
},
|
|
9900
|
+
): Promise<{
|
|
9901
|
+
|
|
9902
|
+
/**
|
|
9903
|
+
* The result of evaluation.
|
|
9904
|
+
*/
|
|
9905
|
+
result: {[name: string]: any},
|
|
9906
|
+
|
|
9907
|
+
/**
|
|
9908
|
+
* An object providing details if an exception occurred while evaluating the expression.
|
|
9909
|
+
*/
|
|
9910
|
+
exceptionInfo: {
|
|
9911
|
+
|
|
9912
|
+
/**
|
|
9913
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
9914
|
+
*/
|
|
9915
|
+
isError: boolean,
|
|
9916
|
+
|
|
9917
|
+
/**
|
|
9918
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
9919
|
+
*/
|
|
9920
|
+
code: string,
|
|
9921
|
+
|
|
9922
|
+
/**
|
|
9923
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
9924
|
+
*/
|
|
9925
|
+
description: string,
|
|
9926
|
+
|
|
9927
|
+
/**
|
|
9928
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated, contains the array of the values that may be substituted into the description string to provide more information about the cause of the error.
|
|
9929
|
+
*/
|
|
9930
|
+
details: any[],
|
|
9931
|
+
|
|
9932
|
+
/**
|
|
9933
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
9934
|
+
*/
|
|
9935
|
+
isException: boolean,
|
|
9936
|
+
|
|
9937
|
+
/**
|
|
9938
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
9939
|
+
*/
|
|
9940
|
+
value: string,
|
|
9941
|
+
},
|
|
9942
|
+
}>;
|
|
9943
|
+
|
|
9826
9944
|
/**
|
|
9827
9945
|
* Evaluates a JavaScript expression in the context of the main frame of the inspected page. The expression must evaluate to a JSON-compliant object, otherwise an exception is thrown. The eval function can report either a DevTools-side error or a JavaScript exception that occurs during evaluation. In either case, the `result` parameter of the callback is `undefined`. In the case of a DevTools-side error, the `isException` parameter is non-null and has `isError` set to true and `code` set to an error code. In the case of a JavaScript error, `isException` is set to true and `value` is set to the string value of thrown object.
|
|
9828
9946
|
*
|
|
9829
9947
|
* @param expression An expression to evaluate.
|
|
9830
9948
|
* @param options The options parameter can contain one or more options.
|
|
9831
|
-
* @param callback A function called when evaluation completes.
|
|
9832
9949
|
*/
|
|
9833
9950
|
function _eval(
|
|
9834
9951
|
|
|
@@ -9855,42 +9972,54 @@ declare namespace chrome {
|
|
|
9855
9972
|
},
|
|
9856
9973
|
|
|
9857
9974
|
/**
|
|
9858
|
-
* @param
|
|
9859
|
-
* @param exceptionInfo An object providing details if an exception occurred while evaluating the expression.
|
|
9975
|
+
* @param response The result of evaluation and exception information.
|
|
9860
9976
|
*/
|
|
9861
9977
|
callback?: (
|
|
9862
|
-
|
|
9863
|
-
|
|
9978
|
+
/**
|
|
9979
|
+
* @since Pending
|
|
9980
|
+
*/
|
|
9981
|
+
response: {
|
|
9864
9982
|
|
|
9865
9983
|
/**
|
|
9866
|
-
*
|
|
9984
|
+
* The result of evaluation.
|
|
9867
9985
|
*/
|
|
9868
|
-
|
|
9986
|
+
result: {[name: string]: any},
|
|
9869
9987
|
|
|
9870
9988
|
/**
|
|
9871
|
-
*
|
|
9989
|
+
* An object providing details if an exception occurred while evaluating the expression.
|
|
9872
9990
|
*/
|
|
9873
|
-
|
|
9991
|
+
exceptionInfo: {
|
|
9874
9992
|
|
|
9875
|
-
|
|
9876
|
-
|
|
9877
|
-
|
|
9878
|
-
|
|
9993
|
+
/**
|
|
9994
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
9995
|
+
*/
|
|
9996
|
+
isError: boolean,
|
|
9879
9997
|
|
|
9880
|
-
|
|
9881
|
-
|
|
9882
|
-
|
|
9883
|
-
|
|
9998
|
+
/**
|
|
9999
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
10000
|
+
*/
|
|
10001
|
+
code: string,
|
|
9884
10002
|
|
|
9885
|
-
|
|
9886
|
-
|
|
9887
|
-
|
|
9888
|
-
|
|
10003
|
+
/**
|
|
10004
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
10005
|
+
*/
|
|
10006
|
+
description: string,
|
|
9889
10007
|
|
|
9890
|
-
|
|
9891
|
-
|
|
9892
|
-
|
|
9893
|
-
|
|
10008
|
+
/**
|
|
10009
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated, contains the array of the values that may be substituted into the description string to provide more information about the cause of the error.
|
|
10010
|
+
*/
|
|
10011
|
+
details: any[],
|
|
10012
|
+
|
|
10013
|
+
/**
|
|
10014
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
10015
|
+
*/
|
|
10016
|
+
isException: boolean,
|
|
10017
|
+
|
|
10018
|
+
/**
|
|
10019
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
10020
|
+
*/
|
|
10021
|
+
value: string,
|
|
10022
|
+
},
|
|
9894
10023
|
},
|
|
9895
10024
|
) => void,
|
|
9896
10025
|
): void;
|
|
@@ -9922,14 +10051,20 @@ declare namespace chrome {
|
|
|
9922
10051
|
/**
|
|
9923
10052
|
* Retrieves the list of resources from the inspected page.
|
|
9924
10053
|
*
|
|
9925
|
-
* @
|
|
10054
|
+
* @chrome-returns-extra since Pending
|
|
10055
|
+
* @returns A function that receives the list of resources when the request completes.
|
|
10056
|
+
*/
|
|
10057
|
+
export function getResources(): Promise<Resource[]>;
|
|
10058
|
+
|
|
10059
|
+
/**
|
|
10060
|
+
* Retrieves the list of resources from the inspected page.
|
|
9926
10061
|
*/
|
|
9927
10062
|
export function getResources(
|
|
9928
10063
|
|
|
9929
10064
|
/**
|
|
9930
10065
|
* @param resources The resources within the page.
|
|
9931
10066
|
*/
|
|
9932
|
-
callback
|
|
10067
|
+
callback?: (
|
|
9933
10068
|
resources: Resource[],
|
|
9934
10069
|
) => void,
|
|
9935
10070
|
): void;
|
|
@@ -9950,17 +10085,46 @@ declare namespace chrome {
|
|
|
9950
10085
|
/**
|
|
9951
10086
|
* Returns content of the response body.
|
|
9952
10087
|
*
|
|
9953
|
-
* @
|
|
10088
|
+
* @chrome-returns-extra since Pending
|
|
10089
|
+
* @returns A function that receives the response body when the request completes.
|
|
10090
|
+
*/
|
|
10091
|
+
getContent(): Promise<{
|
|
10092
|
+
|
|
10093
|
+
/**
|
|
10094
|
+
* Content of the response body (potentially encoded).
|
|
10095
|
+
*/
|
|
10096
|
+
content: string,
|
|
10097
|
+
|
|
10098
|
+
/**
|
|
10099
|
+
* Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
10100
|
+
*/
|
|
10101
|
+
encoding: string,
|
|
10102
|
+
}>;
|
|
10103
|
+
|
|
10104
|
+
/**
|
|
10105
|
+
* Returns content of the response body.
|
|
9954
10106
|
*/
|
|
9955
10107
|
getContent(
|
|
9956
10108
|
|
|
9957
10109
|
/**
|
|
9958
|
-
* @param
|
|
9959
|
-
* @param encoding Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
10110
|
+
* @param response An object containing the response body and its encoding.
|
|
9960
10111
|
*/
|
|
9961
|
-
callback
|
|
9962
|
-
|
|
9963
|
-
|
|
10112
|
+
callback?: (
|
|
10113
|
+
/**
|
|
10114
|
+
* @since Pending
|
|
10115
|
+
*/
|
|
10116
|
+
response: {
|
|
10117
|
+
|
|
10118
|
+
/**
|
|
10119
|
+
* Content of the response body (potentially encoded).
|
|
10120
|
+
*/
|
|
10121
|
+
content: string,
|
|
10122
|
+
|
|
10123
|
+
/**
|
|
10124
|
+
* Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
10125
|
+
*/
|
|
10126
|
+
encoding: string,
|
|
10127
|
+
},
|
|
9964
10128
|
) => void,
|
|
9965
10129
|
): void;
|
|
9966
10130
|
}
|
|
@@ -9982,14 +10146,20 @@ declare namespace chrome {
|
|
|
9982
10146
|
/**
|
|
9983
10147
|
* Returns HAR log that contains all known network requests.
|
|
9984
10148
|
*
|
|
9985
|
-
* @
|
|
10149
|
+
* @chrome-returns-extra since Pending
|
|
10150
|
+
* @returns A function that receives the HAR log when the request completes.
|
|
10151
|
+
*/
|
|
10152
|
+
export function getHAR(): Promise<{[name: string]: any}>;
|
|
10153
|
+
|
|
10154
|
+
/**
|
|
10155
|
+
* Returns HAR log that contains all known network requests.
|
|
9986
10156
|
*/
|
|
9987
10157
|
export function getHAR(
|
|
9988
10158
|
|
|
9989
10159
|
/**
|
|
9990
10160
|
* @param harLog A HAR log. See HAR specification for details.
|
|
9991
10161
|
*/
|
|
9992
|
-
callback
|
|
10162
|
+
callback?: (
|
|
9993
10163
|
harLog: {[name: string]: any},
|
|
9994
10164
|
) => void,
|
|
9995
10165
|
): void;
|
|
@@ -22122,14 +22292,14 @@ declare namespace chrome {
|
|
|
22122
22292
|
* Determines whether the extension has an active document.
|
|
22123
22293
|
*
|
|
22124
22294
|
* @returns Promise that resolves with the result of whether the extension has an active offscreen document.
|
|
22125
|
-
* @since
|
|
22295
|
+
* @since Chrome 150
|
|
22126
22296
|
*/
|
|
22127
22297
|
export function hasDocument(): Promise<boolean>;
|
|
22128
22298
|
|
|
22129
22299
|
/**
|
|
22130
22300
|
* Determines whether the extension has an active document.
|
|
22131
22301
|
*
|
|
22132
|
-
* @since
|
|
22302
|
+
* @since Chrome 150
|
|
22133
22303
|
*/
|
|
22134
22304
|
export function hasDocument(
|
|
22135
22305
|
|
|
@@ -24571,6 +24741,7 @@ declare namespace chrome {
|
|
|
24571
24741
|
* @chrome-enum "mips" Specifies the native client architecture as mips.
|
|
24572
24742
|
* @chrome-enum "mips64" Specifies the native client architecture as mips64.
|
|
24573
24743
|
* @since Chrome 44
|
|
24744
|
+
* @chrome-deprecated-since Chrome 149
|
|
24574
24745
|
*/
|
|
24575
24746
|
export type PlatformNaclArch = "arm" | "x86-32" | "x86-64" | "mips" | "mips64";
|
|
24576
24747
|
|
|
@@ -24593,6 +24764,7 @@ declare namespace chrome {
|
|
|
24593
24764
|
* The native client architecture. This may be different from arch on some platforms.
|
|
24594
24765
|
*
|
|
24595
24766
|
* @deprecated This attribute is deprecated following complete removal of Native Client.
|
|
24767
|
+
* @chrome-deprecated-since Chrome 149
|
|
24596
24768
|
*/
|
|
24597
24769
|
nacl_arch?: PlatformNaclArch;
|
|
24598
24770
|
}
|
package/index.d.ts
CHANGED
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
-
// Generated on Thu
|
|
18
|
-
// Built at
|
|
17
|
+
// Generated on Thu Jun 25 2026 22:48:17 GMT+0000 (Coordinated Universal Time)
|
|
18
|
+
// Built at 40eff249d43ce574d7772af8be25f8d7a66e8e70
|
|
19
19
|
|
|
20
20
|
// Includes MV3+ APIs only.
|
|
21
21
|
|
|
@@ -811,7 +811,7 @@ declare namespace chrome {
|
|
|
811
811
|
/**
|
|
812
812
|
* Whether the alarm should persist across sessions (browser restarts).
|
|
813
813
|
*
|
|
814
|
-
* @since
|
|
814
|
+
* @since Chrome 150
|
|
815
815
|
*/
|
|
816
816
|
persistAcrossSessions: boolean;
|
|
817
817
|
}
|
|
@@ -836,7 +836,7 @@ declare namespace chrome {
|
|
|
836
836
|
/**
|
|
837
837
|
* Whether the alarm should persist across sessions (browser restarts). In Chrome, this defaults to true to match historical behavior, but you should set this explicitly to maximize compatibility across browsers.
|
|
838
838
|
*
|
|
839
|
-
* @since
|
|
839
|
+
* @since Chrome 150
|
|
840
840
|
*/
|
|
841
841
|
persistAcrossSessions?: boolean;
|
|
842
842
|
}
|
|
@@ -6031,26 +6031,69 @@ declare namespace chrome {
|
|
|
6031
6031
|
/**
|
|
6032
6032
|
* Gets the content of the resource.
|
|
6033
6033
|
*
|
|
6034
|
-
* @
|
|
6034
|
+
* @chrome-returns-extra since Pending
|
|
6035
|
+
* @returns A function that receives resource content when the request completes.
|
|
6036
|
+
*/
|
|
6037
|
+
getContent(): Promise<{
|
|
6038
|
+
|
|
6039
|
+
/**
|
|
6040
|
+
* Content of the resource (potentially encoded).
|
|
6041
|
+
*/
|
|
6042
|
+
content: string,
|
|
6043
|
+
|
|
6044
|
+
/**
|
|
6045
|
+
* Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6046
|
+
*/
|
|
6047
|
+
encoding: string,
|
|
6048
|
+
}>;
|
|
6049
|
+
|
|
6050
|
+
/**
|
|
6051
|
+
* Gets the content of the resource.
|
|
6035
6052
|
*/
|
|
6036
6053
|
getContent(
|
|
6037
6054
|
|
|
6038
6055
|
/**
|
|
6039
|
-
* @param
|
|
6040
|
-
* @param encoding Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6056
|
+
* @param response An object containing the resource content and its encoding.
|
|
6041
6057
|
*/
|
|
6042
|
-
callback
|
|
6043
|
-
|
|
6044
|
-
|
|
6058
|
+
callback?: (
|
|
6059
|
+
/**
|
|
6060
|
+
* @since Pending
|
|
6061
|
+
*/
|
|
6062
|
+
response: {
|
|
6063
|
+
|
|
6064
|
+
/**
|
|
6065
|
+
* Content of the resource (potentially encoded).
|
|
6066
|
+
*/
|
|
6067
|
+
content: string,
|
|
6068
|
+
|
|
6069
|
+
/**
|
|
6070
|
+
* Empty if the content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6071
|
+
*/
|
|
6072
|
+
encoding: string,
|
|
6073
|
+
},
|
|
6045
6074
|
) => void,
|
|
6046
6075
|
): void;
|
|
6047
6076
|
|
|
6077
|
+
/**
|
|
6078
|
+
* Sets the content of the resource.
|
|
6079
|
+
*
|
|
6080
|
+
* @chrome-returns-extra since Pending
|
|
6081
|
+
* @param content New content of the resource. Only resources with the text type are currently supported.
|
|
6082
|
+
* @param commit True if the user has finished editing the resource, and the new content of the resource should be persisted; false if this is a minor change sent in progress of the user editing the resource.
|
|
6083
|
+
* @returns A function called upon request completion.
|
|
6084
|
+
*/
|
|
6085
|
+
setContent(
|
|
6086
|
+
|
|
6087
|
+
content: string,
|
|
6088
|
+
|
|
6089
|
+
commit: boolean,
|
|
6090
|
+
): Promise<{[name: string]: any} | undefined>;
|
|
6091
|
+
|
|
6048
6092
|
/**
|
|
6049
6093
|
* Sets the content of the resource.
|
|
6050
6094
|
*
|
|
6051
6095
|
* @param content New content of the resource. Only resources with the text type are currently supported.
|
|
6052
6096
|
* @param commit True if the user has finished editing the resource, and the new content of the resource should be persisted; false if this is a minor change sent in progress of the user editing the resource.
|
|
6053
|
-
* @param callback A function called upon request completion.
|
|
6054
6097
|
*/
|
|
6055
6098
|
setContent(
|
|
6056
6099
|
|
|
@@ -6089,12 +6132,86 @@ declare namespace chrome {
|
|
|
6089
6132
|
|
|
6090
6133
|
export {_eval as eval};
|
|
6091
6134
|
|
|
6135
|
+
/**
|
|
6136
|
+
* Evaluates a JavaScript expression in the context of the main frame of the inspected page. The expression must evaluate to a JSON-compliant object, otherwise an exception is thrown. The eval function can report either a DevTools-side error or a JavaScript exception that occurs during evaluation. In either case, the `result` parameter of the callback is `undefined`. In the case of a DevTools-side error, the `isException` parameter is non-null and has `isError` set to true and `code` set to an error code. In the case of a JavaScript error, `isException` is set to true and `value` is set to the string value of thrown object.
|
|
6137
|
+
*
|
|
6138
|
+
* @chrome-returns-extra since Pending
|
|
6139
|
+
* @param expression An expression to evaluate.
|
|
6140
|
+
* @param options The options parameter can contain one or more options.
|
|
6141
|
+
* @returns A function called when evaluation completes.
|
|
6142
|
+
*/
|
|
6143
|
+
function _eval(
|
|
6144
|
+
|
|
6145
|
+
expression: string,
|
|
6146
|
+
|
|
6147
|
+
options?: {
|
|
6148
|
+
|
|
6149
|
+
/**
|
|
6150
|
+
* If specified, the expression is evaluated on the iframe whose URL matches the one specified. By default, the expression is evaluated in the top frame of the inspected page.
|
|
6151
|
+
*/
|
|
6152
|
+
frameURL?: string,
|
|
6153
|
+
|
|
6154
|
+
/**
|
|
6155
|
+
* Evaluate the expression in the context of the content script of the calling extension, provided that the content script is already injected into the inspected page. If not, the expression is not evaluated and the callback is invoked with the exception parameter set to an object that has the `isError` field set to true and the `code` field set to `E_NOTFOUND`.
|
|
6156
|
+
*/
|
|
6157
|
+
useContentScriptContext?: boolean,
|
|
6158
|
+
|
|
6159
|
+
/**
|
|
6160
|
+
* Evaluate the expression in the context of a content script of an extension that matches the specified origin. If given, scriptExecutionContext overrides the 'true' setting on useContentScriptContext.
|
|
6161
|
+
*
|
|
6162
|
+
* @since Chrome 107
|
|
6163
|
+
*/
|
|
6164
|
+
scriptExecutionContext?: string,
|
|
6165
|
+
},
|
|
6166
|
+
): Promise<{
|
|
6167
|
+
|
|
6168
|
+
/**
|
|
6169
|
+
* The result of evaluation.
|
|
6170
|
+
*/
|
|
6171
|
+
result: {[name: string]: any},
|
|
6172
|
+
|
|
6173
|
+
/**
|
|
6174
|
+
* An object providing details if an exception occurred while evaluating the expression.
|
|
6175
|
+
*/
|
|
6176
|
+
exceptionInfo: {
|
|
6177
|
+
|
|
6178
|
+
/**
|
|
6179
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6180
|
+
*/
|
|
6181
|
+
isError: boolean,
|
|
6182
|
+
|
|
6183
|
+
/**
|
|
6184
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6185
|
+
*/
|
|
6186
|
+
code: string,
|
|
6187
|
+
|
|
6188
|
+
/**
|
|
6189
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6190
|
+
*/
|
|
6191
|
+
description: string,
|
|
6192
|
+
|
|
6193
|
+
/**
|
|
6194
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated, contains the array of the values that may be substituted into the description string to provide more information about the cause of the error.
|
|
6195
|
+
*/
|
|
6196
|
+
details: any[],
|
|
6197
|
+
|
|
6198
|
+
/**
|
|
6199
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
6200
|
+
*/
|
|
6201
|
+
isException: boolean,
|
|
6202
|
+
|
|
6203
|
+
/**
|
|
6204
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
6205
|
+
*/
|
|
6206
|
+
value: string,
|
|
6207
|
+
},
|
|
6208
|
+
}>;
|
|
6209
|
+
|
|
6092
6210
|
/**
|
|
6093
6211
|
* Evaluates a JavaScript expression in the context of the main frame of the inspected page. The expression must evaluate to a JSON-compliant object, otherwise an exception is thrown. The eval function can report either a DevTools-side error or a JavaScript exception that occurs during evaluation. In either case, the `result` parameter of the callback is `undefined`. In the case of a DevTools-side error, the `isException` parameter is non-null and has `isError` set to true and `code` set to an error code. In the case of a JavaScript error, `isException` is set to true and `value` is set to the string value of thrown object.
|
|
6094
6212
|
*
|
|
6095
6213
|
* @param expression An expression to evaluate.
|
|
6096
6214
|
* @param options The options parameter can contain one or more options.
|
|
6097
|
-
* @param callback A function called when evaluation completes.
|
|
6098
6215
|
*/
|
|
6099
6216
|
function _eval(
|
|
6100
6217
|
|
|
@@ -6121,42 +6238,54 @@ declare namespace chrome {
|
|
|
6121
6238
|
},
|
|
6122
6239
|
|
|
6123
6240
|
/**
|
|
6124
|
-
* @param
|
|
6125
|
-
* @param exceptionInfo An object providing details if an exception occurred while evaluating the expression.
|
|
6241
|
+
* @param response The result of evaluation and exception information.
|
|
6126
6242
|
*/
|
|
6127
6243
|
callback?: (
|
|
6128
|
-
|
|
6129
|
-
|
|
6244
|
+
/**
|
|
6245
|
+
* @since Pending
|
|
6246
|
+
*/
|
|
6247
|
+
response: {
|
|
6130
6248
|
|
|
6131
6249
|
/**
|
|
6132
|
-
*
|
|
6250
|
+
* The result of evaluation.
|
|
6133
6251
|
*/
|
|
6134
|
-
|
|
6252
|
+
result: {[name: string]: any},
|
|
6135
6253
|
|
|
6136
6254
|
/**
|
|
6137
|
-
*
|
|
6255
|
+
* An object providing details if an exception occurred while evaluating the expression.
|
|
6138
6256
|
*/
|
|
6139
|
-
|
|
6257
|
+
exceptionInfo: {
|
|
6140
6258
|
|
|
6141
|
-
|
|
6142
|
-
|
|
6143
|
-
|
|
6144
|
-
|
|
6259
|
+
/**
|
|
6260
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6261
|
+
*/
|
|
6262
|
+
isError: boolean,
|
|
6145
6263
|
|
|
6146
|
-
|
|
6147
|
-
|
|
6148
|
-
|
|
6149
|
-
|
|
6264
|
+
/**
|
|
6265
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6266
|
+
*/
|
|
6267
|
+
code: string,
|
|
6150
6268
|
|
|
6151
|
-
|
|
6152
|
-
|
|
6153
|
-
|
|
6154
|
-
|
|
6269
|
+
/**
|
|
6270
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated.
|
|
6271
|
+
*/
|
|
6272
|
+
description: string,
|
|
6155
6273
|
|
|
6156
|
-
|
|
6157
|
-
|
|
6158
|
-
|
|
6159
|
-
|
|
6274
|
+
/**
|
|
6275
|
+
* Set if the error occurred on the DevTools side before the expression is evaluated, contains the array of the values that may be substituted into the description string to provide more information about the cause of the error.
|
|
6276
|
+
*/
|
|
6277
|
+
details: any[],
|
|
6278
|
+
|
|
6279
|
+
/**
|
|
6280
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
6281
|
+
*/
|
|
6282
|
+
isException: boolean,
|
|
6283
|
+
|
|
6284
|
+
/**
|
|
6285
|
+
* Set if the evaluated code produces an unhandled exception.
|
|
6286
|
+
*/
|
|
6287
|
+
value: string,
|
|
6288
|
+
},
|
|
6160
6289
|
},
|
|
6161
6290
|
) => void,
|
|
6162
6291
|
): void;
|
|
@@ -6188,14 +6317,20 @@ declare namespace chrome {
|
|
|
6188
6317
|
/**
|
|
6189
6318
|
* Retrieves the list of resources from the inspected page.
|
|
6190
6319
|
*
|
|
6191
|
-
* @
|
|
6320
|
+
* @chrome-returns-extra since Pending
|
|
6321
|
+
* @returns A function that receives the list of resources when the request completes.
|
|
6322
|
+
*/
|
|
6323
|
+
export function getResources(): Promise<Resource[]>;
|
|
6324
|
+
|
|
6325
|
+
/**
|
|
6326
|
+
* Retrieves the list of resources from the inspected page.
|
|
6192
6327
|
*/
|
|
6193
6328
|
export function getResources(
|
|
6194
6329
|
|
|
6195
6330
|
/**
|
|
6196
6331
|
* @param resources The resources within the page.
|
|
6197
6332
|
*/
|
|
6198
|
-
callback
|
|
6333
|
+
callback?: (
|
|
6199
6334
|
resources: Resource[],
|
|
6200
6335
|
) => void,
|
|
6201
6336
|
): void;
|
|
@@ -6216,17 +6351,46 @@ declare namespace chrome {
|
|
|
6216
6351
|
/**
|
|
6217
6352
|
* Returns content of the response body.
|
|
6218
6353
|
*
|
|
6219
|
-
* @
|
|
6354
|
+
* @chrome-returns-extra since Pending
|
|
6355
|
+
* @returns A function that receives the response body when the request completes.
|
|
6356
|
+
*/
|
|
6357
|
+
getContent(): Promise<{
|
|
6358
|
+
|
|
6359
|
+
/**
|
|
6360
|
+
* Content of the response body (potentially encoded).
|
|
6361
|
+
*/
|
|
6362
|
+
content: string,
|
|
6363
|
+
|
|
6364
|
+
/**
|
|
6365
|
+
* Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6366
|
+
*/
|
|
6367
|
+
encoding: string,
|
|
6368
|
+
}>;
|
|
6369
|
+
|
|
6370
|
+
/**
|
|
6371
|
+
* Returns content of the response body.
|
|
6220
6372
|
*/
|
|
6221
6373
|
getContent(
|
|
6222
6374
|
|
|
6223
6375
|
/**
|
|
6224
|
-
* @param
|
|
6225
|
-
* @param encoding Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6376
|
+
* @param response An object containing the response body and its encoding.
|
|
6226
6377
|
*/
|
|
6227
|
-
callback
|
|
6228
|
-
|
|
6229
|
-
|
|
6378
|
+
callback?: (
|
|
6379
|
+
/**
|
|
6380
|
+
* @since Pending
|
|
6381
|
+
*/
|
|
6382
|
+
response: {
|
|
6383
|
+
|
|
6384
|
+
/**
|
|
6385
|
+
* Content of the response body (potentially encoded).
|
|
6386
|
+
*/
|
|
6387
|
+
content: string,
|
|
6388
|
+
|
|
6389
|
+
/**
|
|
6390
|
+
* Empty if content is not encoded, encoding name otherwise. Currently, only base64 is supported.
|
|
6391
|
+
*/
|
|
6392
|
+
encoding: string,
|
|
6393
|
+
},
|
|
6230
6394
|
) => void,
|
|
6231
6395
|
): void;
|
|
6232
6396
|
}
|
|
@@ -6248,14 +6412,20 @@ declare namespace chrome {
|
|
|
6248
6412
|
/**
|
|
6249
6413
|
* Returns HAR log that contains all known network requests.
|
|
6250
6414
|
*
|
|
6251
|
-
* @
|
|
6415
|
+
* @chrome-returns-extra since Pending
|
|
6416
|
+
* @returns A function that receives the HAR log when the request completes.
|
|
6417
|
+
*/
|
|
6418
|
+
export function getHAR(): Promise<{[name: string]: any}>;
|
|
6419
|
+
|
|
6420
|
+
/**
|
|
6421
|
+
* Returns HAR log that contains all known network requests.
|
|
6252
6422
|
*/
|
|
6253
6423
|
export function getHAR(
|
|
6254
6424
|
|
|
6255
6425
|
/**
|
|
6256
6426
|
* @param harLog A HAR log. See HAR specification for details.
|
|
6257
6427
|
*/
|
|
6258
|
-
callback
|
|
6428
|
+
callback?: (
|
|
6259
6429
|
harLog: {[name: string]: any},
|
|
6260
6430
|
) => void,
|
|
6261
6431
|
): void;
|
|
@@ -15206,14 +15376,14 @@ declare namespace chrome {
|
|
|
15206
15376
|
* Determines whether the extension has an active document.
|
|
15207
15377
|
*
|
|
15208
15378
|
* @returns Promise that resolves with the result of whether the extension has an active offscreen document.
|
|
15209
|
-
* @since
|
|
15379
|
+
* @since Chrome 150
|
|
15210
15380
|
*/
|
|
15211
15381
|
export function hasDocument(): Promise<boolean>;
|
|
15212
15382
|
|
|
15213
15383
|
/**
|
|
15214
15384
|
* Determines whether the extension has an active document.
|
|
15215
15385
|
*
|
|
15216
|
-
* @since
|
|
15386
|
+
* @since Chrome 150
|
|
15217
15387
|
*/
|
|
15218
15388
|
export function hasDocument(
|
|
15219
15389
|
|
|
@@ -17375,6 +17545,7 @@ declare namespace chrome {
|
|
|
17375
17545
|
* @chrome-enum "mips" Specifies the native client architecture as mips.
|
|
17376
17546
|
* @chrome-enum "mips64" Specifies the native client architecture as mips64.
|
|
17377
17547
|
* @since Chrome 44
|
|
17548
|
+
* @chrome-deprecated-since Chrome 149
|
|
17378
17549
|
*/
|
|
17379
17550
|
export type PlatformNaclArch = "arm" | "x86-32" | "x86-64" | "mips" | "mips64";
|
|
17380
17551
|
|
|
@@ -17397,6 +17568,7 @@ declare namespace chrome {
|
|
|
17397
17568
|
* The native client architecture. This may be different from arch on some platforms.
|
|
17398
17569
|
*
|
|
17399
17570
|
* @deprecated This attribute is deprecated following complete removal of Native Client.
|
|
17571
|
+
* @chrome-deprecated-since Chrome 149
|
|
17400
17572
|
*/
|
|
17401
17573
|
nacl_arch?: PlatformNaclArch;
|
|
17402
17574
|
}
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"type": "module",
|
|
6
6
|
"name": "chrome-types",
|
|
7
7
|
"config": {
|
|
8
|
-
"build-hash": "
|
|
8
|
+
"build-hash": "4997499173c6e434"
|
|
9
9
|
},
|
|
10
10
|
"repository": {
|
|
11
11
|
"type": "git",
|
|
@@ -16,5 +16,5 @@
|
|
|
16
16
|
"url": "https://github.com/GoogleChrome/chrome-types/issues"
|
|
17
17
|
},
|
|
18
18
|
"homepage": "https://github.com/GoogleChrome/chrome-types",
|
|
19
|
-
"version": "0.1.
|
|
19
|
+
"version": "0.1.430"
|
|
20
20
|
}
|