mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-31 18:33:25 +08:00
Update protocol resources
This CL updates protocol resources from these CLs: https://crrev.com/c/2988302 https://crrev.com/c/2951908 https://crrev.com/c/2987822 https://crrev.com/c/2935645 https://crrev.com/c/2840423 https://crrev.com/c/2964539 Bug: chromium:1146422 Change-Id: I993f2e4469988d6c9854a8f26d0ba5e65580c0e2 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2992876 Reviewed-by: Changhao Han <changhaohan@chromium.org> Reviewed-by: Johan Bay <jobay@chromium.org> Commit-Queue: Changhao Han <changhaohan@chromium.org>
This commit is contained in:
committed by
Devtools-frontend LUCI CQ
parent
3812c7134c
commit
907dfdffa3
@@ -828,6 +828,13 @@ export function registerCommands(inspectorBackend) {
|
||||
inspectorBackend.registerCommand('DOM.undo', [], []);
|
||||
inspectorBackend.registerCommand(
|
||||
'DOM.getFrameOwner', [{'name': 'frameId', 'type': 'string', 'optional': false}], ['backendNodeId', 'nodeId']);
|
||||
inspectorBackend.registerCommand(
|
||||
'DOM.getContainerForNode',
|
||||
[
|
||||
{'name': 'nodeId', 'type': 'number', 'optional': false},
|
||||
{'name': 'containerName', 'type': 'string', 'optional': true}
|
||||
],
|
||||
['nodeId']);
|
||||
|
||||
// DOMDebugger.
|
||||
inspectorBackend.registerEnum(
|
||||
@@ -1910,6 +1917,7 @@ export function registerCommands(inspectorBackend) {
|
||||
ChRtt: 'ch-rtt',
|
||||
ChUa: 'ch-ua',
|
||||
ChUaArch: 'ch-ua-arch',
|
||||
ChUaBitness: 'ch-ua-bitness',
|
||||
ChUaPlatform: 'ch-ua-platform',
|
||||
ChUaModel: 'ch-ua-model',
|
||||
ChUaMobile: 'ch-ua-mobile',
|
||||
@@ -2063,20 +2071,14 @@ export function registerCommands(inspectorBackend) {
|
||||
BrowsingInstanceNotSwapped: 'BrowsingInstanceNotSwapped',
|
||||
BackForwardCacheDisabledForDelegate: 'BackForwardCacheDisabledForDelegate',
|
||||
OptInUnloadHeaderNotPresent: 'OptInUnloadHeaderNotPresent',
|
||||
UnloadHandlerExistsInMainFrame: 'UnloadHandlerExistsInMainFrame',
|
||||
UnloadHandlerExistsInSubFrame: 'UnloadHandlerExistsInSubFrame',
|
||||
ServiceWorkerUnregistration: 'ServiceWorkerUnregistration',
|
||||
WebSocket: 'WebSocket',
|
||||
WebRTC: 'WebRTC',
|
||||
MainResourceHasCacheControlNoStore: 'MainResourceHasCacheControlNoStore',
|
||||
MainResourceHasCacheControlNoCache: 'MainResourceHasCacheControlNoCache',
|
||||
SubresourceHasCacheControlNoStore: 'SubresourceHasCacheControlNoStore',
|
||||
SubresourceHasCacheControlNoCache: 'SubresourceHasCacheControlNoCache',
|
||||
PageShowEventListener: 'PageShowEventListener',
|
||||
PageHideEventListener: 'PageHideEventListener',
|
||||
BeforeUnloadEventListener: 'BeforeUnloadEventListener',
|
||||
UnloadEventListener: 'UnloadEventListener',
|
||||
FreezeEventListener: 'FreezeEventListener',
|
||||
ResumeEventListener: 'ResumeEventListener',
|
||||
ContainsPlugins: 'ContainsPlugins',
|
||||
DocumentLoaded: 'DocumentLoaded',
|
||||
DedicatedWorkerOrWorklet: 'DedicatedWorkerOrWorklet',
|
||||
@@ -2165,7 +2167,7 @@ export function registerCommands(inspectorBackend) {
|
||||
],
|
||||
['identifier']);
|
||||
inspectorBackend.registerCommand('Page.bringToFront', [], []);
|
||||
inspectorBackend.registerEnum('Page.CaptureScreenshotRequestFormat', {Jpeg: 'jpeg', Png: 'png'});
|
||||
inspectorBackend.registerEnum('Page.CaptureScreenshotRequestFormat', {Jpeg: 'jpeg', Png: 'png', Webp: 'webp'});
|
||||
inspectorBackend.registerCommand(
|
||||
'Page.captureScreenshot',
|
||||
[
|
||||
|
||||
+7
@@ -1316,6 +1316,13 @@ export namespace ProtocolMapping {
|
||||
*/
|
||||
'DOM.getFrameOwner':
|
||||
{paramsType: [Protocol.DOM.GetFrameOwnerRequest]; returnType: Protocol.DOM.GetFrameOwnerResponse;};
|
||||
/**
|
||||
* Returns the container of the given node based on container query conditions.
|
||||
* If containerName is given, it will find the nearest container with a matching name;
|
||||
* otherwise it will find the nearest container regardless of its container name.
|
||||
*/
|
||||
'DOM.getContainerForNode':
|
||||
{paramsType: [Protocol.DOM.GetContainerForNodeRequest]; returnType: Protocol.DOM.GetContainerForNodeResponse;};
|
||||
/**
|
||||
* Returns event listeners of the given object.
|
||||
*/
|
||||
|
||||
+8
@@ -952,6 +952,14 @@ declare namespace ProtocolProxyApi {
|
||||
* Returns iframe node that owns iframe with the given domain.
|
||||
*/
|
||||
invoke_getFrameOwner(params: Protocol.DOM.GetFrameOwnerRequest): Promise<Protocol.DOM.GetFrameOwnerResponse>;
|
||||
|
||||
/**
|
||||
* Returns the container of the given node based on container query conditions.
|
||||
* If containerName is given, it will find the nearest container with a matching name;
|
||||
* otherwise it will find the nearest container regardless of its container name.
|
||||
*/
|
||||
invoke_getContainerForNode(params: Protocol.DOM.GetContainerForNodeRequest):
|
||||
Promise<Protocol.DOM.GetContainerForNodeResponse>;
|
||||
}
|
||||
export interface DOMDispatcher {
|
||||
/**
|
||||
|
||||
Vendored
+31
-10
@@ -1081,6 +1081,12 @@ declare namespace Protocol {
|
||||
navigatorUserAgentIssueDetails?: NavigatorUserAgentIssueDetails;
|
||||
}
|
||||
|
||||
/**
|
||||
* A unique id for a DevTools inspector issue. Allows other entities (e.g.
|
||||
* exceptions, CDP message, console messages, etc.) to reference an issue.
|
||||
*/
|
||||
export type IssueId = string;
|
||||
|
||||
/**
|
||||
* An inspector issue reported from the back-end.
|
||||
*/
|
||||
@@ -1091,7 +1097,7 @@ declare namespace Protocol {
|
||||
* A unique id for this issue. May be omitted if no other entity (e.g.
|
||||
* exception, CDP message, etc.) is referencing this issue.
|
||||
*/
|
||||
issueId?: string;
|
||||
issueId?: IssueId;
|
||||
}
|
||||
|
||||
export const enum GetEncodedResponseRequestEncoding {
|
||||
@@ -1754,7 +1760,9 @@ declare namespace Protocol {
|
||||
*/
|
||||
frameId: Page.FrameId;
|
||||
/**
|
||||
* Stylesheet resource URL.
|
||||
* Stylesheet resource URL. Empty if this is a constructed stylesheet created using
|
||||
* new CSSStyleSheet() (but non-empty if this is a constructed sylesheet imported
|
||||
* as a CSS module script).
|
||||
*/
|
||||
sourceURL: string;
|
||||
/**
|
||||
@@ -1794,7 +1802,8 @@ declare namespace Protocol {
|
||||
*/
|
||||
isMutable: boolean;
|
||||
/**
|
||||
* Whether this stylesheet is a constructed stylesheet (created using new CSSStyleSheet()).
|
||||
* True if this stylesheet is created through new CSSStyleSheet() or imported as a
|
||||
* CSS module script.
|
||||
*/
|
||||
isConstructed: boolean;
|
||||
/**
|
||||
@@ -2086,6 +2095,10 @@ declare namespace Protocol {
|
||||
* Identifier of the stylesheet containing this object (if exists).
|
||||
*/
|
||||
styleSheetId?: StyleSheetId;
|
||||
/**
|
||||
* Optional name for the container.
|
||||
*/
|
||||
name?: string;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -3745,6 +3758,18 @@ declare namespace Protocol {
|
||||
nodeId?: NodeId;
|
||||
}
|
||||
|
||||
export interface GetContainerForNodeRequest {
|
||||
nodeId: NodeId;
|
||||
containerName?: string;
|
||||
}
|
||||
|
||||
export interface GetContainerForNodeResponse extends ProtocolResponseWithError {
|
||||
/**
|
||||
* The container node for the given node, or null if not found.
|
||||
*/
|
||||
nodeId?: NodeId;
|
||||
}
|
||||
|
||||
/**
|
||||
* Fired when `Element`'s attribute is modified.
|
||||
*/
|
||||
@@ -9612,6 +9637,7 @@ declare namespace Protocol {
|
||||
ChRtt = 'ch-rtt',
|
||||
ChUa = 'ch-ua',
|
||||
ChUaArch = 'ch-ua-arch',
|
||||
ChUaBitness = 'ch-ua-bitness',
|
||||
ChUaPlatform = 'ch-ua-platform',
|
||||
ChUaModel = 'ch-ua-model',
|
||||
ChUaMobile = 'ch-ua-mobile',
|
||||
@@ -10257,20 +10283,14 @@ declare namespace Protocol {
|
||||
BrowsingInstanceNotSwapped = 'BrowsingInstanceNotSwapped',
|
||||
BackForwardCacheDisabledForDelegate = 'BackForwardCacheDisabledForDelegate',
|
||||
OptInUnloadHeaderNotPresent = 'OptInUnloadHeaderNotPresent',
|
||||
UnloadHandlerExistsInMainFrame = 'UnloadHandlerExistsInMainFrame',
|
||||
UnloadHandlerExistsInSubFrame = 'UnloadHandlerExistsInSubFrame',
|
||||
ServiceWorkerUnregistration = 'ServiceWorkerUnregistration',
|
||||
WebSocket = 'WebSocket',
|
||||
WebRTC = 'WebRTC',
|
||||
MainResourceHasCacheControlNoStore = 'MainResourceHasCacheControlNoStore',
|
||||
MainResourceHasCacheControlNoCache = 'MainResourceHasCacheControlNoCache',
|
||||
SubresourceHasCacheControlNoStore = 'SubresourceHasCacheControlNoStore',
|
||||
SubresourceHasCacheControlNoCache = 'SubresourceHasCacheControlNoCache',
|
||||
PageShowEventListener = 'PageShowEventListener',
|
||||
PageHideEventListener = 'PageHideEventListener',
|
||||
BeforeUnloadEventListener = 'BeforeUnloadEventListener',
|
||||
UnloadEventListener = 'UnloadEventListener',
|
||||
FreezeEventListener = 'FreezeEventListener',
|
||||
ResumeEventListener = 'ResumeEventListener',
|
||||
ContainsPlugins = 'ContainsPlugins',
|
||||
DocumentLoaded = 'DocumentLoaded',
|
||||
DedicatedWorkerOrWorklet = 'DedicatedWorkerOrWorklet',
|
||||
@@ -10369,6 +10389,7 @@ declare namespace Protocol {
|
||||
export const enum CaptureScreenshotRequestFormat {
|
||||
Jpeg = 'jpeg',
|
||||
Png = 'png',
|
||||
Webp = 'webp',
|
||||
}
|
||||
|
||||
export interface CaptureScreenshotRequest {
|
||||
|
||||
@@ -1666,6 +1666,11 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "IssueId",
|
||||
"description": "A unique id for a DevTools inspector issue. Allows other entities (e.g.\nexceptions, CDP message, console messages, etc.) to reference an issue.",
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"id": "InspectorIssue",
|
||||
"description": "An inspector issue reported from the back-end.",
|
||||
@@ -1683,7 +1688,7 @@
|
||||
"name": "issueId",
|
||||
"description": "A unique id for this issue. May be omitted if no other entity (e.g.\nexception, CDP message, etc.) is referencing this issue.",
|
||||
"optional": true,
|
||||
"type": "string"
|
||||
"$ref": "IssueId"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -2660,7 +2665,7 @@
|
||||
},
|
||||
{
|
||||
"name": "sourceURL",
|
||||
"description": "Stylesheet resource URL.",
|
||||
"description": "Stylesheet resource URL. Empty if this is a constructed stylesheet created using\nnew CSSStyleSheet() (but non-empty if this is a constructed sylesheet imported\nas a CSS module script).",
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
@@ -2708,7 +2713,7 @@
|
||||
},
|
||||
{
|
||||
"name": "isConstructed",
|
||||
"description": "Whether this stylesheet is a constructed stylesheet (created using new CSSStyleSheet()).",
|
||||
"description": "True if this stylesheet is created through new CSSStyleSheet() or imported as a\nCSS module script.",
|
||||
"type": "boolean"
|
||||
},
|
||||
{
|
||||
@@ -3097,6 +3102,12 @@
|
||||
"description": "Identifier of the stylesheet containing this object (if exists).",
|
||||
"optional": true,
|
||||
"$ref": "StyleSheetId"
|
||||
},
|
||||
{
|
||||
"name": "name",
|
||||
"description": "Optional name for the container.",
|
||||
"optional": true,
|
||||
"type": "string"
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -5607,6 +5618,30 @@
|
||||
"$ref": "NodeId"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "getContainerForNode",
|
||||
"description": "Returns the container of the given node based on container query conditions.\nIf containerName is given, it will find the nearest container with a matching name;\notherwise it will find the nearest container regardless of its container name.",
|
||||
"experimental": true,
|
||||
"parameters": [
|
||||
{
|
||||
"name": "nodeId",
|
||||
"$ref": "NodeId"
|
||||
},
|
||||
{
|
||||
"name": "containerName",
|
||||
"optional": true,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"returns": [
|
||||
{
|
||||
"name": "nodeId",
|
||||
"description": "The container node for the given node, or null if not found.",
|
||||
"optional": true,
|
||||
"$ref": "NodeId"
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"events": [
|
||||
@@ -14153,6 +14188,7 @@
|
||||
"ch-rtt",
|
||||
"ch-ua",
|
||||
"ch-ua-arch",
|
||||
"ch-ua-bitness",
|
||||
"ch-ua-platform",
|
||||
"ch-ua-model",
|
||||
"ch-ua-mobile",
|
||||
@@ -15045,20 +15081,14 @@
|
||||
"BrowsingInstanceNotSwapped",
|
||||
"BackForwardCacheDisabledForDelegate",
|
||||
"OptInUnloadHeaderNotPresent",
|
||||
"UnloadHandlerExistsInMainFrame",
|
||||
"UnloadHandlerExistsInSubFrame",
|
||||
"ServiceWorkerUnregistration",
|
||||
"WebSocket",
|
||||
"WebRTC",
|
||||
"MainResourceHasCacheControlNoStore",
|
||||
"MainResourceHasCacheControlNoCache",
|
||||
"SubresourceHasCacheControlNoStore",
|
||||
"SubresourceHasCacheControlNoCache",
|
||||
"PageShowEventListener",
|
||||
"PageHideEventListener",
|
||||
"BeforeUnloadEventListener",
|
||||
"UnloadEventListener",
|
||||
"FreezeEventListener",
|
||||
"ResumeEventListener",
|
||||
"ContainsPlugins",
|
||||
"DocumentLoaded",
|
||||
"DedicatedWorkerOrWorklet",
|
||||
@@ -15196,7 +15226,8 @@
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"jpeg",
|
||||
"png"
|
||||
"png",
|
||||
"webp"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
+27
-11
@@ -793,6 +793,10 @@ experimental domain Audits
|
||||
optional QuirksModeIssueDetails quirksModeIssueDetails
|
||||
optional NavigatorUserAgentIssueDetails navigatorUserAgentIssueDetails
|
||||
|
||||
# A unique id for a DevTools inspector issue. Allows other entities (e.g.
|
||||
# exceptions, CDP message, console messages, etc.) to reference an issue.
|
||||
type IssueId extends string
|
||||
|
||||
# An inspector issue reported from the back-end.
|
||||
type InspectorIssue extends object
|
||||
properties
|
||||
@@ -800,7 +804,7 @@ experimental domain Audits
|
||||
InspectorIssueDetails details
|
||||
# A unique id for this issue. May be omitted if no other entity (e.g.
|
||||
# exception, CDP message, etc.) is referencing this issue.
|
||||
optional string issueId
|
||||
optional IssueId issueId
|
||||
|
||||
# Returns the response body and size if it were re-encoded with the specified settings. Only
|
||||
# applies to images.
|
||||
@@ -1265,7 +1269,9 @@ experimental domain CSS
|
||||
StyleSheetId styleSheetId
|
||||
# Owner frame identifier.
|
||||
Page.FrameId frameId
|
||||
# Stylesheet resource URL.
|
||||
# Stylesheet resource URL. Empty if this is a constructed stylesheet created using
|
||||
# new CSSStyleSheet() (but non-empty if this is a constructed sylesheet imported
|
||||
# as a CSS module script).
|
||||
string sourceURL
|
||||
# URL of source map associated with the stylesheet (if any).
|
||||
optional string sourceMapURL
|
||||
@@ -1287,7 +1293,8 @@ experimental domain CSS
|
||||
# <link> element's stylesheets become mutable only if DevTools modifies them.
|
||||
# Constructed stylesheets (new CSSStyleSheet()) are mutable immediately after creation.
|
||||
boolean isMutable
|
||||
# Whether this stylesheet is a constructed stylesheet (created using new CSSStyleSheet()).
|
||||
# True if this stylesheet is created through new CSSStyleSheet() or imported as a
|
||||
# CSS module script.
|
||||
boolean isConstructed
|
||||
# Line offset of the stylesheet within the resource (zero based).
|
||||
number startLine
|
||||
@@ -1451,6 +1458,8 @@ experimental domain CSS
|
||||
optional SourceRange range
|
||||
# Identifier of the stylesheet containing this object (if exists).
|
||||
optional StyleSheetId styleSheetId
|
||||
# Optional name for the container.
|
||||
optional string name
|
||||
|
||||
# Information about amount of glyphs that were rendered with given font.
|
||||
type PlatformFontUsage extends object
|
||||
@@ -2605,6 +2614,17 @@ domain DOM
|
||||
# Id of the node at given coordinates, only when enabled and requested document.
|
||||
optional NodeId nodeId
|
||||
|
||||
# Returns the container of the given node based on container query conditions.
|
||||
# If containerName is given, it will find the nearest container with a matching name;
|
||||
# otherwise it will find the nearest container regardless of its container name.
|
||||
experimental command getContainerForNode
|
||||
parameters
|
||||
NodeId nodeId
|
||||
optional string containerName
|
||||
returns
|
||||
# The container node for the given node, or null if not found.
|
||||
optional NodeId nodeId
|
||||
|
||||
# Fired when `Element`'s attribute is modified.
|
||||
event attributeModified
|
||||
parameters
|
||||
@@ -6546,6 +6566,7 @@ domain Page
|
||||
ch-rtt
|
||||
ch-ua
|
||||
ch-ua-arch
|
||||
ch-ua-bitness
|
||||
ch-ua-platform
|
||||
ch-ua-model
|
||||
ch-ua-mobile
|
||||
@@ -6971,6 +6992,7 @@ domain Page
|
||||
optional enum format
|
||||
jpeg
|
||||
png
|
||||
webp
|
||||
# Compression quality from range [0..100] (jpeg only).
|
||||
optional integer quality
|
||||
# Capture the screenshot of a given region only.
|
||||
@@ -7684,21 +7706,15 @@ domain Page
|
||||
BrowsingInstanceNotSwapped
|
||||
BackForwardCacheDisabledForDelegate
|
||||
OptInUnloadHeaderNotPresent
|
||||
UnloadHandlerExistsInMainFrame
|
||||
UnloadHandlerExistsInSubFrame
|
||||
# Blocklisted features
|
||||
ServiceWorkerUnregistration
|
||||
#Blocklisted features
|
||||
WebSocket
|
||||
WebRTC
|
||||
MainResourceHasCacheControlNoStore
|
||||
MainResourceHasCacheControlNoCache
|
||||
SubresourceHasCacheControlNoStore
|
||||
SubresourceHasCacheControlNoCache
|
||||
PageShowEventListener
|
||||
PageHideEventListener
|
||||
BeforeUnloadEventListener
|
||||
UnloadEventListener
|
||||
FreezeEventListener
|
||||
ResumeEventListener
|
||||
ContainsPlugins
|
||||
DocumentLoaded
|
||||
DedicatedWorkerOrWorklet
|
||||
|
||||
Reference in New Issue
Block a user