Skip to content

Commit 016a6b9

Browse files
author
copybara-service
committed
deploy: 00b9b45
1 parent 489ddef commit 016a6b9

153 files changed

Lines changed: 2995 additions & 2233 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

extension-api/ExtensionAPI.d.ts

Lines changed: 83 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,35 @@ export namespace Chrome {
1919
*/
2020
readonly buildId?: string;
2121

22+
/**
23+
* Returns the `content` and `encoding` of the resource. If a `callback`
24+
* is provided, it is invoked with the `content` and `encoding` and the
25+
* method returns `void`. If no `callback` is provided, the method returns
26+
* a `Promise`.
27+
*
28+
* @param callback Optional callback to be invoked with the content and
29+
* encoding.
30+
* @returns A Promise that resolves to an object containing the content
31+
* and encoding if no callback is provided, otherwise void. Rejects with
32+
* an error object on failure.
33+
*/
34+
getContent(): Promise<{content: string, encoding: string}>;
2235
getContent(callback: (content: string, encoding: string) => unknown): void;
23-
setContent(content: string, commit: boolean, callback?: (error?: Object) => unknown): void;
36+
37+
/**
38+
* Sets the content of the resource. If a `callback` is provided, it is
39+
* invoked when the content is set and the method returns `void`. If no
40+
* `callback` is provided, the method returns a `Promise`.
41+
*
42+
* @param content The new content of the resource.
43+
* @param commit Whether to commit the changes.
44+
* @param callback Optional callback to be invoked when the content is
45+
* set.
46+
* @returns A Promise that resolves when the content is set if no callback
47+
* is provided, otherwise void. Rejects with an error object on failure.
48+
*/
49+
setContent(content: string, commit: boolean): Promise<void>;
50+
setContent(content: string, commit: boolean, callback: (error?: object) => unknown): void;
2451
/**
2552
* Augments this resource's scopes information based on the list of {@link NamedFunctionRange}s
2653
* for improved debuggability and function naming.
@@ -40,18 +67,62 @@ export namespace Chrome {
4067
onResourceAdded: EventSink<(resource: Resource) => unknown>;
4168
onResourceContentCommitted: EventSink<(resource: Resource, content: string) => unknown>;
4269

43-
eval(
44-
expression: string,
45-
options?: {scriptExecutionContext?: string, frameURL?: string, useContentScriptContext?: boolean},
46-
callback?: (result: unknown, exceptioninfo: {
47-
code: string,
48-
description: string,
49-
details: unknown[],
50-
isError: boolean,
51-
isException: boolean,
52-
value: string,
53-
}) => unknown): void;
70+
/**
71+
* Evaluates a JavaScript expression in the context of the inspected page.
72+
*
73+
* If a `callback` is provided, it is invoked with the result and
74+
* exception information and the method returns `void`. If no `callback`
75+
* is provided, the method returns a `Promise`.
76+
*
77+
* @template E The type of the value that the Promise resolves to.
78+
* @param expression The JavaScript expression to evaluate.
79+
* @param optionsOrCallback Optional options for evaluation, or a callback
80+
* function.
81+
* @param callback Optional callback to be invoked with the evaluation
82+
* result and exception information.
83+
* @returns A Promise that resolves to the result if no callback is
84+
* provided, otherwise void. Rejects with an error object on failure.
85+
*/
86+
eval<E = unknown>(expression: string, options?: {
87+
scriptExecutionContext?: string,
88+
frameURL?: string,
89+
useContentScriptContext?: boolean,
90+
}): Promise<E>;
91+
eval(expression: string,
92+
optionsOrCallback: {scriptExecutionContext?: string, frameURL?: string, useContentScriptContext?: boolean}|
93+
undefined|((result: unknown, exceptioninfo: {
94+
code: string,
95+
description: string,
96+
details: unknown[],
97+
isError: boolean,
98+
isException: boolean,
99+
value: string,
100+
}) => unknown),
101+
callback?: (result: unknown, exceptioninfo: {
102+
code: string,
103+
description: string,
104+
details: unknown[],
105+
isError: boolean,
106+
isException: boolean,
107+
value: string,
108+
}) => unknown): void;
109+
110+
/**
111+
* Retrieves all resources within the inspected window.
112+
*
113+
* If a `callback` is provided, it is invoked with the array of resources
114+
* and the method returns `void`. If no `callback` is provided, the method
115+
* returns a `Promise`.
116+
*
117+
* @param callback Optional callback to be invoked with the array of
118+
* resources.
119+
* @returns A Promise that resolves to an array of resources if no
120+
* callback is provided, otherwise void. Rejects with an error object on
121+
* failure.
122+
*/
123+
getResources(): Promise<Resource[]>;
54124
getResources(callback: (resources: Resource[]) => unknown): void;
125+
55126
reload(reloadOptions?: {ignoreCache?: boolean, injectedScript?: string, userAgent?: string}): void;
56127
}
57128

front_end/core/host/UserMetrics.d.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -515,7 +515,6 @@ export declare const enum IssueOpener {
515515
export declare enum DevtoolsExperiments {
516516
'protocol-monitor' = 13,
517517
'instrumentation-breakpoints' = 61,
518-
'use-source-map-scopes' = 76,
519518
'durable-messages' = 110,
520519
'jpeg-xl' = 111,
521520
'plus-button' = 112,

front_end/core/host/UserMetrics.js

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

front_end/core/host/UserMetrics.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

front_end/core/host/host.js

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

front_end/core/host/host.js.map

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

front_end/core/i18n/locales/en-US.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

front_end/core/i18n/locales/generated/collected-ui-strings.d

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

front_end/core/i18n/locales/generated/en-US.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2639,9 +2639,15 @@
26392639
"models/trace/Styles.ts | signReply": {
26402640
"message": "Sign reply"
26412641
},
2642+
"models/trace/Styles.ts | softFirstContentfulPaint": {
2643+
"message": "Soft First Contentful Paint"
2644+
},
26422645
"models/trace/Styles.ts | softLargestContentfulPaint": {
26432646
"message": "Soft Largest Contentful Paint"
26442647
},
2648+
"models/trace/Styles.ts | softNavigationStart": {
2649+
"message": "Soft navigation start"
2650+
},
26452651
"models/trace/Styles.ts | streamingCompileTask": {
26462652
"message": "Streaming compile task"
26472653
},

front_end/core/root/ExperimentNames.d.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ export declare enum ExperimentName {
22
ALL = "*",
33
PROTOCOL_MONITOR = "protocol-monitor",
44
INSTRUMENTATION_BREAKPOINTS = "instrumentation-breakpoints",
5-
USE_SOURCE_MAP_SCOPES = "use-source-map-scopes",
65
DURABLE_MESSAGES = "durable-messages",
76
JPEG_XL = "jpeg-xl",
87
PLUS_BUTTON = "plus-button"

0 commit comments

Comments
 (0)