chrome-devtools-frontend 1.0.1587905 → 1.0.1588580
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/front_end/core/sdk/DOMModel.ts +3 -0
- package/front_end/core/sdk/PreloadingModel.ts +15 -6
- package/front_end/generated/InspectorBackendCommands.ts +5 -3
- package/front_end/generated/SupportedCSSProperties.js +46 -0
- package/front_end/generated/protocol-mapping.d.ts +4 -0
- package/front_end/generated/protocol-proxy-api.d.ts +5 -0
- package/front_end/generated/protocol.ts +49 -0
- package/front_end/models/computed_style/ComputedStyleModel.ts +2 -1
- package/front_end/models/javascript_metadata/NativeFunctions.js +4 -16
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +15 -21
- package/front_end/panels/application/preloading/PreloadingView.ts +18 -0
- package/front_end/panels/application/preloading/components/RuleSetDetailsView.css +12 -0
- package/front_end/panels/application/preloading/components/RuleSetDetailsView.ts +3 -3
- package/front_end/panels/console/ConsoleViewMessage.ts +3 -3
- package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +1 -1
- package/front_end/panels/elements/ComputedStyleWidget.ts +2 -16
- package/front_end/panels/elements/ElementsPanel.ts +12 -4
- package/front_end/panels/elements/PropertiesWidget.ts +62 -61
- package/front_end/panels/elements/StylePropertyTreeElement.ts +11 -12
- package/front_end/panels/elements/StylesSidebarPane.ts +25 -5
- package/front_end/panels/elements/elementsPanel.css +6 -2
- package/front_end/panels/network/RequestHeadersView.ts +113 -128
- package/front_end/panels/sources/CSSPlugin.ts +1 -1
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/ui/legacy/components/inline_editor/ColorSwatch.ts +32 -28
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +31 -6
- package/front_end/ui/visual_logging/KnownContextValues.ts +7 -0
- package/package.json +1 -1
|
@@ -2054,6 +2054,9 @@ class DOMDispatcher implements ProtocolProxyApi.DOMDispatcher {
|
|
|
2054
2054
|
Protocol.DOM.AffectedByStartingStylesFlagUpdatedEvent): void {
|
|
2055
2055
|
this.#domModel.affectedByStartingStylesFlagUpdated(nodeId, affectedByStartingStyles);
|
|
2056
2056
|
}
|
|
2057
|
+
|
|
2058
|
+
adRelatedStateUpdated(_: Protocol.DOM.AdRelatedStateUpdatedEvent): void {
|
|
2059
|
+
}
|
|
2057
2060
|
}
|
|
2058
2061
|
|
|
2059
2062
|
let domModelUndoStackInstance: DOMModelUndoStack|null = null;
|
|
@@ -64,6 +64,20 @@ export class PreloadingModel extends SDKModel<EventTypes> {
|
|
|
64
64
|
void this.agent.invoke_disable();
|
|
65
65
|
}
|
|
66
66
|
|
|
67
|
+
reset(): void {
|
|
68
|
+
this.documents.clear();
|
|
69
|
+
this.loaderIds = [];
|
|
70
|
+
this.targetJustAttached = true;
|
|
71
|
+
this.dispatchEventToListeners(Events.MODEL_UPDATED);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
private maybeInferLoaderId(loaderId: Protocol.Network.LoaderId): void {
|
|
75
|
+
if (this.currentLoaderId() === null) {
|
|
76
|
+
this.loaderIds = [loaderId];
|
|
77
|
+
this.targetJustAttached = false;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
|
|
67
81
|
private ensureDocumentPreloadingData(loaderId: Protocol.Network.LoaderId): void {
|
|
68
82
|
if (this.documents.get(loaderId) === undefined) {
|
|
69
83
|
this.documents.set(loaderId, new DocumentPreloadingData());
|
|
@@ -241,12 +255,7 @@ export class PreloadingModel extends SDKModel<EventTypes> {
|
|
|
241
255
|
|
|
242
256
|
const loaderId = ruleSet.loaderId;
|
|
243
257
|
|
|
244
|
-
|
|
245
|
-
if (this.currentLoaderId() === null) {
|
|
246
|
-
this.loaderIds = [loaderId];
|
|
247
|
-
this.targetJustAttached = false;
|
|
248
|
-
}
|
|
249
|
-
|
|
258
|
+
this.maybeInferLoaderId(loaderId);
|
|
250
259
|
this.ensureDocumentPreloadingData(loaderId);
|
|
251
260
|
this.documents.get(loaderId)?.ruleSets.upsert(ruleSet);
|
|
252
261
|
this.dispatchEventToListeners(Events.MODEL_UPDATED);
|
|
@@ -363,6 +363,7 @@ inspectorBackend.registerEvent("DOM.inlineStyleInvalidated", ["nodeIds"]);
|
|
|
363
363
|
inspectorBackend.registerEvent("DOM.pseudoElementAdded", ["parentId", "pseudoElement"]);
|
|
364
364
|
inspectorBackend.registerEvent("DOM.topLayerElementsUpdated", []);
|
|
365
365
|
inspectorBackend.registerEvent("DOM.scrollableFlagUpdated", ["nodeId", "isScrollable"]);
|
|
366
|
+
inspectorBackend.registerEvent("DOM.adRelatedStateUpdated", ["nodeId", "isAdRelated"]);
|
|
366
367
|
inspectorBackend.registerEvent("DOM.affectedByStartingStylesFlagUpdated", ["nodeId", "affectedByStartingStyles"]);
|
|
367
368
|
inspectorBackend.registerEvent("DOM.pseudoElementRemoved", ["parentId", "pseudoElementId"]);
|
|
368
369
|
inspectorBackend.registerEvent("DOM.setChildNodes", ["parentId", "nodes"]);
|
|
@@ -424,7 +425,7 @@ inspectorBackend.registerCommand("DOM.getQueryingDescendantsForContainer", [{"na
|
|
|
424
425
|
inspectorBackend.registerCommand("DOM.getAnchorElement", [{"name": "nodeId", "type": "number", "optional": false, "description": "Id of the positioned element from which to find the anchor.", "typeRef": "DOM.NodeId"}, {"name": "anchorSpecifier", "type": "string", "optional": true, "description": "An optional anchor specifier, as defined in https://www.w3.org/TR/css-anchor-position-1/#anchor-specifier. If not provided, it will return the implicit anchor element for the given positioned element.", "typeRef": null}], ["nodeId"], "Returns the target anchor element of the given anchor query according to https://www.w3.org/TR/css-anchor-position-1/#target.");
|
|
425
426
|
inspectorBackend.registerCommand("DOM.forceShowPopover", [{"name": "nodeId", "type": "number", "optional": false, "description": "Id of the popover HTMLElement", "typeRef": "DOM.NodeId"}, {"name": "enable", "type": "boolean", "optional": false, "description": "If true, opens the popover and keeps it open. If false, closes the popover if it was previously force-opened.", "typeRef": null}], ["nodeIds"], "When enabling, this API force-opens the popover identified by nodeId and keeps it open until disabled.");
|
|
426
427
|
inspectorBackend.registerType("DOM.BackendNode", [{"name": "nodeType", "type": "number", "optional": false, "description": "`Node`'s nodeType.", "typeRef": null}, {"name": "nodeName", "type": "string", "optional": false, "description": "`Node`'s nodeName.", "typeRef": null}, {"name": "backendNodeId", "type": "number", "optional": false, "description": "", "typeRef": "DOM.BackendNodeId"}]);
|
|
427
|
-
inspectorBackend.registerType("DOM.Node", [{"name": "nodeId", "type": "number", "optional": false, "description": "Node identifier that is passed into the rest of the DOM messages as the `nodeId`. Backend will only push node with given `id` once. It is aware of all requested nodes and will only fire DOM events for nodes known to the client.", "typeRef": "DOM.NodeId"}, {"name": "parentId", "type": "number", "optional": true, "description": "The id of the parent node if any.", "typeRef": "DOM.NodeId"}, {"name": "backendNodeId", "type": "number", "optional": false, "description": "The BackendNodeId for this node.", "typeRef": "DOM.BackendNodeId"}, {"name": "nodeType", "type": "number", "optional": false, "description": "`Node`'s nodeType.", "typeRef": null}, {"name": "nodeName", "type": "string", "optional": false, "description": "`Node`'s nodeName.", "typeRef": null}, {"name": "localName", "type": "string", "optional": false, "description": "`Node`'s localName.", "typeRef": null}, {"name": "nodeValue", "type": "string", "optional": false, "description": "`Node`'s nodeValue.", "typeRef": null}, {"name": "childNodeCount", "type": "number", "optional": true, "description": "Child count for `Container` nodes.", "typeRef": null}, {"name": "children", "type": "array", "optional": true, "description": "Child nodes of this node when requested with children.", "typeRef": "DOM.Node"}, {"name": "attributes", "type": "array", "optional": true, "description": "Attributes of the `Element` node in the form of flat array `[name1, value1, name2, value2]`.", "typeRef": "string"}, {"name": "documentURL", "type": "string", "optional": true, "description": "Document URL that `Document` or `FrameOwner` node points to.", "typeRef": null}, {"name": "baseURL", "type": "string", "optional": true, "description": "Base URL that `Document` or `FrameOwner` node uses for URL completion.", "typeRef": null}, {"name": "publicId", "type": "string", "optional": true, "description": "`DocumentType`'s publicId.", "typeRef": null}, {"name": "systemId", "type": "string", "optional": true, "description": "`DocumentType`'s systemId.", "typeRef": null}, {"name": "internalSubset", "type": "string", "optional": true, "description": "`DocumentType`'s internalSubset.", "typeRef": null}, {"name": "xmlVersion", "type": "string", "optional": true, "description": "`Document`'s XML version in case of XML documents.", "typeRef": null}, {"name": "name", "type": "string", "optional": true, "description": "`Attr`'s name.", "typeRef": null}, {"name": "value", "type": "string", "optional": true, "description": "`Attr`'s value.", "typeRef": null}, {"name": "pseudoType", "type": "string", "optional": true, "description": "Pseudo element type for this node.", "typeRef": "DOM.PseudoType"}, {"name": "pseudoIdentifier", "type": "string", "optional": true, "description": "Pseudo element identifier for this node. Only present if there is a valid pseudoType.", "typeRef": null}, {"name": "shadowRootType", "type": "string", "optional": true, "description": "Shadow root type.", "typeRef": "DOM.ShadowRootType"}, {"name": "frameId", "type": "string", "optional": true, "description": "Frame ID for frame owner elements.", "typeRef": "Page.FrameId"}, {"name": "contentDocument", "type": "object", "optional": true, "description": "Content document for frame owner elements.", "typeRef": "DOM.Node"}, {"name": "shadowRoots", "type": "array", "optional": true, "description": "Shadow root list for given element host.", "typeRef": "DOM.Node"}, {"name": "templateContent", "type": "object", "optional": true, "description": "Content document fragment for template elements.", "typeRef": "DOM.Node"}, {"name": "pseudoElements", "type": "array", "optional": true, "description": "Pseudo elements associated with this node.", "typeRef": "DOM.Node"}, {"name": "importedDocument", "type": "object", "optional": true, "description": "Deprecated, as the HTML Imports API has been removed (crbug.com/937746). This property used to return the imported document for the HTMLImport links. The property is always undefined now.", "typeRef": "DOM.Node"}, {"name": "distributedNodes", "type": "array", "optional": true, "description": "Distributed nodes for given insertion point.", "typeRef": "DOM.BackendNode"}, {"name": "isSVG", "type": "boolean", "optional": true, "description": "Whether the node is SVG.", "typeRef": null}, {"name": "compatibilityMode", "type": "string", "optional": true, "description": "", "typeRef": "DOM.CompatibilityMode"}, {"name": "assignedSlot", "type": "object", "optional": true, "description": "", "typeRef": "DOM.BackendNode"}, {"name": "isScrollable", "type": "boolean", "optional": true, "description": "", "typeRef": null}, {"name": "affectedByStartingStyles", "type": "boolean", "optional": true, "description": "", "typeRef": null}, {"name": "adoptedStyleSheets", "type": "array", "optional": true, "description": "", "typeRef": "DOM.StyleSheetId"}]);
|
|
428
|
+
inspectorBackend.registerType("DOM.Node", [{"name": "nodeId", "type": "number", "optional": false, "description": "Node identifier that is passed into the rest of the DOM messages as the `nodeId`. Backend will only push node with given `id` once. It is aware of all requested nodes and will only fire DOM events for nodes known to the client.", "typeRef": "DOM.NodeId"}, {"name": "parentId", "type": "number", "optional": true, "description": "The id of the parent node if any.", "typeRef": "DOM.NodeId"}, {"name": "backendNodeId", "type": "number", "optional": false, "description": "The BackendNodeId for this node.", "typeRef": "DOM.BackendNodeId"}, {"name": "nodeType", "type": "number", "optional": false, "description": "`Node`'s nodeType.", "typeRef": null}, {"name": "nodeName", "type": "string", "optional": false, "description": "`Node`'s nodeName.", "typeRef": null}, {"name": "localName", "type": "string", "optional": false, "description": "`Node`'s localName.", "typeRef": null}, {"name": "nodeValue", "type": "string", "optional": false, "description": "`Node`'s nodeValue.", "typeRef": null}, {"name": "childNodeCount", "type": "number", "optional": true, "description": "Child count for `Container` nodes.", "typeRef": null}, {"name": "children", "type": "array", "optional": true, "description": "Child nodes of this node when requested with children.", "typeRef": "DOM.Node"}, {"name": "attributes", "type": "array", "optional": true, "description": "Attributes of the `Element` node in the form of flat array `[name1, value1, name2, value2]`.", "typeRef": "string"}, {"name": "documentURL", "type": "string", "optional": true, "description": "Document URL that `Document` or `FrameOwner` node points to.", "typeRef": null}, {"name": "baseURL", "type": "string", "optional": true, "description": "Base URL that `Document` or `FrameOwner` node uses for URL completion.", "typeRef": null}, {"name": "publicId", "type": "string", "optional": true, "description": "`DocumentType`'s publicId.", "typeRef": null}, {"name": "systemId", "type": "string", "optional": true, "description": "`DocumentType`'s systemId.", "typeRef": null}, {"name": "internalSubset", "type": "string", "optional": true, "description": "`DocumentType`'s internalSubset.", "typeRef": null}, {"name": "xmlVersion", "type": "string", "optional": true, "description": "`Document`'s XML version in case of XML documents.", "typeRef": null}, {"name": "name", "type": "string", "optional": true, "description": "`Attr`'s name.", "typeRef": null}, {"name": "value", "type": "string", "optional": true, "description": "`Attr`'s value.", "typeRef": null}, {"name": "pseudoType", "type": "string", "optional": true, "description": "Pseudo element type for this node.", "typeRef": "DOM.PseudoType"}, {"name": "pseudoIdentifier", "type": "string", "optional": true, "description": "Pseudo element identifier for this node. Only present if there is a valid pseudoType.", "typeRef": null}, {"name": "shadowRootType", "type": "string", "optional": true, "description": "Shadow root type.", "typeRef": "DOM.ShadowRootType"}, {"name": "frameId", "type": "string", "optional": true, "description": "Frame ID for frame owner elements.", "typeRef": "Page.FrameId"}, {"name": "contentDocument", "type": "object", "optional": true, "description": "Content document for frame owner elements.", "typeRef": "DOM.Node"}, {"name": "shadowRoots", "type": "array", "optional": true, "description": "Shadow root list for given element host.", "typeRef": "DOM.Node"}, {"name": "templateContent", "type": "object", "optional": true, "description": "Content document fragment for template elements.", "typeRef": "DOM.Node"}, {"name": "pseudoElements", "type": "array", "optional": true, "description": "Pseudo elements associated with this node.", "typeRef": "DOM.Node"}, {"name": "importedDocument", "type": "object", "optional": true, "description": "Deprecated, as the HTML Imports API has been removed (crbug.com/937746). This property used to return the imported document for the HTMLImport links. The property is always undefined now.", "typeRef": "DOM.Node"}, {"name": "distributedNodes", "type": "array", "optional": true, "description": "Distributed nodes for given insertion point.", "typeRef": "DOM.BackendNode"}, {"name": "isSVG", "type": "boolean", "optional": true, "description": "Whether the node is SVG.", "typeRef": null}, {"name": "compatibilityMode", "type": "string", "optional": true, "description": "", "typeRef": "DOM.CompatibilityMode"}, {"name": "assignedSlot", "type": "object", "optional": true, "description": "", "typeRef": "DOM.BackendNode"}, {"name": "isScrollable", "type": "boolean", "optional": true, "description": "", "typeRef": null}, {"name": "affectedByStartingStyles", "type": "boolean", "optional": true, "description": "", "typeRef": null}, {"name": "adoptedStyleSheets", "type": "array", "optional": true, "description": "", "typeRef": "DOM.StyleSheetId"}, {"name": "isAdRelated", "type": "boolean", "optional": true, "description": "", "typeRef": null}]);
|
|
428
429
|
inspectorBackend.registerType("DOM.DetachedElementInfo", [{"name": "treeNode", "type": "object", "optional": false, "description": "", "typeRef": "DOM.Node"}, {"name": "retainedNodeIds", "type": "array", "optional": false, "description": "", "typeRef": "DOM.NodeId"}]);
|
|
429
430
|
inspectorBackend.registerType("DOM.RGBA", [{"name": "r", "type": "number", "optional": false, "description": "The red component, in the [0-255] range.", "typeRef": null}, {"name": "g", "type": "number", "optional": false, "description": "The green component, in the [0-255] range.", "typeRef": null}, {"name": "b", "type": "number", "optional": false, "description": "The blue component, in the [0-255] range.", "typeRef": null}, {"name": "a", "type": "number", "optional": true, "description": "The alpha component, in the [0-1] range (default: 1).", "typeRef": null}]);
|
|
430
431
|
inspectorBackend.registerType("DOM.Quad", [{"name": "Quad", "type": "array", "optional": false, "description": "An array of quad vertices, x immediately followed by y for each point, points clock-wise.", "typeRef": "number"}]);
|
|
@@ -930,8 +931,9 @@ inspectorBackend.registerType("Network.DeviceBoundSessionCookieCraving", [{"name
|
|
|
930
931
|
inspectorBackend.registerType("Network.DeviceBoundSessionUrlRule", [{"name": "ruleType", "type": "string", "optional": false, "description": "See comments on `net::device_bound_sessions::SessionInclusionRules::UrlRule::rule_type`.", "typeRef": null}, {"name": "hostPattern", "type": "string", "optional": false, "description": "See comments on `net::device_bound_sessions::SessionInclusionRules::UrlRule::host_pattern`.", "typeRef": null}, {"name": "pathPrefix", "type": "string", "optional": false, "description": "See comments on `net::device_bound_sessions::SessionInclusionRules::UrlRule::path_prefix`.", "typeRef": null}]);
|
|
931
932
|
inspectorBackend.registerType("Network.DeviceBoundSessionInclusionRules", [{"name": "origin", "type": "string", "optional": false, "description": "See comments on `net::device_bound_sessions::SessionInclusionRules::origin_`.", "typeRef": null}, {"name": "includeSite", "type": "boolean", "optional": false, "description": "Whether the whole site is included. See comments on `net::device_bound_sessions::SessionInclusionRules::include_site_` for more details; this boolean is true if that value is populated.", "typeRef": null}, {"name": "urlRules", "type": "array", "optional": false, "description": "See comments on `net::device_bound_sessions::SessionInclusionRules::url_rules_`.", "typeRef": "Network.DeviceBoundSessionUrlRule"}]);
|
|
932
933
|
inspectorBackend.registerType("Network.DeviceBoundSession", [{"name": "key", "type": "object", "optional": false, "description": "The site and session ID of the session.", "typeRef": "Network.DeviceBoundSessionKey"}, {"name": "refreshUrl", "type": "string", "optional": false, "description": "See comments on `net::device_bound_sessions::Session::refresh_url_`.", "typeRef": null}, {"name": "inclusionRules", "type": "object", "optional": false, "description": "See comments on `net::device_bound_sessions::Session::inclusion_rules_`.", "typeRef": "Network.DeviceBoundSessionInclusionRules"}, {"name": "cookieCravings", "type": "array", "optional": false, "description": "See comments on `net::device_bound_sessions::Session::cookie_cravings_`.", "typeRef": "Network.DeviceBoundSessionCookieCraving"}, {"name": "expiryDate", "type": "number", "optional": false, "description": "See comments on `net::device_bound_sessions::Session::expiry_date_`.", "typeRef": "Network.TimeSinceEpoch"}, {"name": "cachedChallenge", "type": "string", "optional": true, "description": "See comments on `net::device_bound_sessions::Session::cached_challenge__`.", "typeRef": null}, {"name": "allowedRefreshInitiators", "type": "array", "optional": false, "description": "See comments on `net::device_bound_sessions::Session::allowed_refresh_initiators_`.", "typeRef": "string"}]);
|
|
933
|
-
inspectorBackend.registerType("Network.
|
|
934
|
-
inspectorBackend.registerType("Network.
|
|
934
|
+
inspectorBackend.registerType("Network.DeviceBoundSessionFailedRequest", [{"name": "requestUrl", "type": "string", "optional": false, "description": "The failed request URL.", "typeRef": null}, {"name": "netError", "type": "string", "optional": true, "description": "The net error of the response if it was not OK.", "typeRef": null}, {"name": "responseError", "type": "number", "optional": true, "description": "The response code if the net error was OK and the response code was not 200.", "typeRef": null}, {"name": "responseErrorBody", "type": "string", "optional": true, "description": "The body of the response if the net error was OK, the response code was not 200, and the response body was not empty.", "typeRef": null}]);
|
|
935
|
+
inspectorBackend.registerType("Network.CreationEventDetails", [{"name": "fetchResult", "type": "string", "optional": false, "description": "The result of the fetch attempt.", "typeRef": "Network.DeviceBoundSessionFetchResult"}, {"name": "newSession", "type": "object", "optional": true, "description": "The session if there was a newly created session. This is populated for all successful creation events.", "typeRef": "Network.DeviceBoundSession"}, {"name": "failedRequest", "type": "object", "optional": true, "description": "Details about a failed device bound session network request if there was one.", "typeRef": "Network.DeviceBoundSessionFailedRequest"}]);
|
|
936
|
+
inspectorBackend.registerType("Network.RefreshEventDetails", [{"name": "refreshResult", "type": "string", "optional": false, "description": "The result of a refresh.", "typeRef": null}, {"name": "fetchResult", "type": "string", "optional": true, "description": "If there was a fetch attempt, the result of that.", "typeRef": "Network.DeviceBoundSessionFetchResult"}, {"name": "newSession", "type": "object", "optional": true, "description": "The session display if there was a newly created session. This is populated for any refresh event that modifies the session config.", "typeRef": "Network.DeviceBoundSession"}, {"name": "wasFullyProactiveRefresh", "type": "boolean", "optional": false, "description": "See comments on `net::device_bound_sessions::RefreshEventResult::was_fully_proactive_refresh`.", "typeRef": null}, {"name": "failedRequest", "type": "object", "optional": true, "description": "Details about a failed device bound session network request if there was one.", "typeRef": "Network.DeviceBoundSessionFailedRequest"}]);
|
|
935
937
|
inspectorBackend.registerType("Network.TerminationEventDetails", [{"name": "deletionReason", "type": "string", "optional": false, "description": "The reason for a session being deleted.", "typeRef": null}]);
|
|
936
938
|
inspectorBackend.registerType("Network.ChallengeEventDetails", [{"name": "challengeResult", "type": "string", "optional": false, "description": "The result of a challenge.", "typeRef": null}, {"name": "challenge", "type": "string", "optional": false, "description": "The challenge set.", "typeRef": null}]);
|
|
937
939
|
inspectorBackend.registerType("Network.LoadNetworkResourcePageResult", [{"name": "success", "type": "boolean", "optional": false, "description": "", "typeRef": null}, {"name": "netError", "type": "number", "optional": true, "description": "Optional values used for error reporting.", "typeRef": null}, {"name": "netErrorName", "type": "string", "optional": true, "description": "", "typeRef": null}, {"name": "httpStatusCode", "type": "number", "optional": true, "description": "", "typeRef": null}, {"name": "stream", "type": "string", "optional": true, "description": "If successful, one of the following two fields holds the result.", "typeRef": "IO.StreamHandle"}, {"name": "headers", "type": "object", "optional": true, "description": "Response headers.", "typeRef": "Network.Headers"}]);
|
|
@@ -1761,6 +1761,20 @@ export const generatedProperties = [
|
|
|
1761
1761
|
],
|
|
1762
1762
|
"name": "column-rule-inset"
|
|
1763
1763
|
},
|
|
1764
|
+
{
|
|
1765
|
+
"longhands": [
|
|
1766
|
+
"column-rule-edge-inset-end",
|
|
1767
|
+
"column-rule-interior-inset-end"
|
|
1768
|
+
],
|
|
1769
|
+
"name": "column-rule-inset-end"
|
|
1770
|
+
},
|
|
1771
|
+
{
|
|
1772
|
+
"longhands": [
|
|
1773
|
+
"column-rule-edge-inset-start",
|
|
1774
|
+
"column-rule-interior-inset-start"
|
|
1775
|
+
],
|
|
1776
|
+
"name": "column-rule-inset-start"
|
|
1777
|
+
},
|
|
1764
1778
|
{
|
|
1765
1779
|
"longhands": [
|
|
1766
1780
|
"column-rule-interior-inset-start",
|
|
@@ -3808,6 +3822,20 @@ export const generatedProperties = [
|
|
|
3808
3822
|
],
|
|
3809
3823
|
"name": "row-rule-inset"
|
|
3810
3824
|
},
|
|
3825
|
+
{
|
|
3826
|
+
"longhands": [
|
|
3827
|
+
"row-rule-edge-inset-end",
|
|
3828
|
+
"row-rule-interior-inset-end"
|
|
3829
|
+
],
|
|
3830
|
+
"name": "row-rule-inset-end"
|
|
3831
|
+
},
|
|
3832
|
+
{
|
|
3833
|
+
"longhands": [
|
|
3834
|
+
"row-rule-edge-inset-start",
|
|
3835
|
+
"row-rule-interior-inset-start"
|
|
3836
|
+
],
|
|
3837
|
+
"name": "row-rule-inset-start"
|
|
3838
|
+
},
|
|
3811
3839
|
{
|
|
3812
3840
|
"longhands": [
|
|
3813
3841
|
"row-rule-interior-inset-start",
|
|
@@ -3929,6 +3957,24 @@ export const generatedProperties = [
|
|
|
3929
3957
|
],
|
|
3930
3958
|
"name": "rule-inset"
|
|
3931
3959
|
},
|
|
3960
|
+
{
|
|
3961
|
+
"longhands": [
|
|
3962
|
+
"column-rule-edge-inset-end",
|
|
3963
|
+
"column-rule-interior-inset-end",
|
|
3964
|
+
"row-rule-edge-inset-end",
|
|
3965
|
+
"row-rule-interior-inset-end"
|
|
3966
|
+
],
|
|
3967
|
+
"name": "rule-inset-end"
|
|
3968
|
+
},
|
|
3969
|
+
{
|
|
3970
|
+
"longhands": [
|
|
3971
|
+
"column-rule-edge-inset-start",
|
|
3972
|
+
"column-rule-interior-inset-start",
|
|
3973
|
+
"row-rule-edge-inset-start",
|
|
3974
|
+
"row-rule-interior-inset-start"
|
|
3975
|
+
],
|
|
3976
|
+
"name": "rule-inset-start"
|
|
3977
|
+
},
|
|
3932
3978
|
{
|
|
3933
3979
|
"longhands": [
|
|
3934
3980
|
"row-rule-interior-inset-start",
|
|
@@ -164,6 +164,10 @@ export namespace ProtocolMapping {
|
|
|
164
164
|
* Fired when a node's scrollability state changes.
|
|
165
165
|
*/
|
|
166
166
|
'DOM.scrollableFlagUpdated': [Protocol.DOM.ScrollableFlagUpdatedEvent];
|
|
167
|
+
/**
|
|
168
|
+
* Fired when a node's ad related state changes.
|
|
169
|
+
*/
|
|
170
|
+
'DOM.adRelatedStateUpdated': [Protocol.DOM.AdRelatedStateUpdatedEvent];
|
|
167
171
|
/**
|
|
168
172
|
* Fired when a node's starting styles changes.
|
|
169
173
|
*/
|
|
@@ -1405,6 +1405,11 @@ declare namespace ProtocolProxyApi {
|
|
|
1405
1405
|
*/
|
|
1406
1406
|
scrollableFlagUpdated(params: Protocol.DOM.ScrollableFlagUpdatedEvent): void;
|
|
1407
1407
|
|
|
1408
|
+
/**
|
|
1409
|
+
* Fired when a node's ad related state changes.
|
|
1410
|
+
*/
|
|
1411
|
+
adRelatedStateUpdated(params: Protocol.DOM.AdRelatedStateUpdatedEvent): void;
|
|
1412
|
+
|
|
1408
1413
|
/**
|
|
1409
1414
|
* Fired when a node's starting styles changes.
|
|
1410
1415
|
*/
|
|
@@ -4736,6 +4736,7 @@ export namespace DOM {
|
|
|
4736
4736
|
isScrollable?: boolean;
|
|
4737
4737
|
affectedByStartingStyles?: boolean;
|
|
4738
4738
|
adoptedStyleSheets?: StyleSheetId[];
|
|
4739
|
+
isAdRelated?: boolean;
|
|
4739
4740
|
}
|
|
4740
4741
|
|
|
4741
4742
|
/**
|
|
@@ -5793,6 +5794,20 @@ export namespace DOM {
|
|
|
5793
5794
|
isScrollable: boolean;
|
|
5794
5795
|
}
|
|
5795
5796
|
|
|
5797
|
+
/**
|
|
5798
|
+
* Fired when a node's ad related state changes.
|
|
5799
|
+
*/
|
|
5800
|
+
export interface AdRelatedStateUpdatedEvent {
|
|
5801
|
+
/**
|
|
5802
|
+
* The id of the node.
|
|
5803
|
+
*/
|
|
5804
|
+
nodeId: DOM.NodeId;
|
|
5805
|
+
/**
|
|
5806
|
+
* If the node is ad related.
|
|
5807
|
+
*/
|
|
5808
|
+
isAdRelated: boolean;
|
|
5809
|
+
}
|
|
5810
|
+
|
|
5796
5811
|
/**
|
|
5797
5812
|
* Fired when a node's starting styles changes.
|
|
5798
5813
|
*/
|
|
@@ -11603,6 +11618,30 @@ export namespace Network {
|
|
|
11603
11618
|
SessionDeletedDuringRefresh = 'SessionDeletedDuringRefresh',
|
|
11604
11619
|
}
|
|
11605
11620
|
|
|
11621
|
+
/**
|
|
11622
|
+
* Details about a failed device bound session network request.
|
|
11623
|
+
*/
|
|
11624
|
+
export interface DeviceBoundSessionFailedRequest {
|
|
11625
|
+
/**
|
|
11626
|
+
* The failed request URL.
|
|
11627
|
+
*/
|
|
11628
|
+
requestUrl: string;
|
|
11629
|
+
/**
|
|
11630
|
+
* The net error of the response if it was not OK.
|
|
11631
|
+
*/
|
|
11632
|
+
netError?: string;
|
|
11633
|
+
/**
|
|
11634
|
+
* The response code if the net error was OK and the response code was not
|
|
11635
|
+
* 200.
|
|
11636
|
+
*/
|
|
11637
|
+
responseError?: integer;
|
|
11638
|
+
/**
|
|
11639
|
+
* The body of the response if the net error was OK, the response code was
|
|
11640
|
+
* not 200, and the response body was not empty.
|
|
11641
|
+
*/
|
|
11642
|
+
responseErrorBody?: string;
|
|
11643
|
+
}
|
|
11644
|
+
|
|
11606
11645
|
/**
|
|
11607
11646
|
* Session event details specific to creation.
|
|
11608
11647
|
*/
|
|
@@ -11616,6 +11655,11 @@ export namespace Network {
|
|
|
11616
11655
|
* all successful creation events.
|
|
11617
11656
|
*/
|
|
11618
11657
|
newSession?: DeviceBoundSession;
|
|
11658
|
+
/**
|
|
11659
|
+
* Details about a failed device bound session network request if there was
|
|
11660
|
+
* one.
|
|
11661
|
+
*/
|
|
11662
|
+
failedRequest?: DeviceBoundSessionFailedRequest;
|
|
11619
11663
|
}
|
|
11620
11664
|
|
|
11621
11665
|
export const enum RefreshEventDetailsRefreshResult {
|
|
@@ -11649,6 +11693,11 @@ export namespace Network {
|
|
|
11649
11693
|
* See comments on `net::device_bound_sessions::RefreshEventResult::was_fully_proactive_refresh`.
|
|
11650
11694
|
*/
|
|
11651
11695
|
wasFullyProactiveRefresh: boolean;
|
|
11696
|
+
/**
|
|
11697
|
+
* Details about a failed device bound session network request if there was
|
|
11698
|
+
* one.
|
|
11699
|
+
*/
|
|
11700
|
+
failedRequest?: DeviceBoundSessionFailedRequest;
|
|
11652
11701
|
}
|
|
11653
11702
|
|
|
11654
11703
|
export const enum TerminationEventDetailsDeletionReason {
|
|
@@ -176,7 +176,8 @@ export const enum Events {
|
|
|
176
176
|
}
|
|
177
177
|
|
|
178
178
|
export type CSSModelChangedEvent = SDK.CSSStyleSheetHeader.CSSStyleSheetHeader|SDK.CSSModel.StyleSheetChangedEvent|
|
|
179
|
-
SDK.CSSModel.PseudoStateForcedEvent|SDK.DOMModel.DOMNode|
|
|
179
|
+
SDK.CSSModel.PseudoStateForcedEvent|SDK.DOMModel.DOMNode|
|
|
180
|
+
SDK.CSSModel.ComputedStyleUpdatedEvent|null|void;
|
|
180
181
|
|
|
181
182
|
export interface EventTypes {
|
|
182
183
|
[Events.CSS_MODEL_CHANGED]: CSSModelChangedEvent;
|
|
@@ -6551,14 +6551,6 @@ export const NativeFunctions = [
|
|
|
6551
6551
|
name: "timeout",
|
|
6552
6552
|
signatures: [["milliseconds"]]
|
|
6553
6553
|
},
|
|
6554
|
-
{
|
|
6555
|
-
name: "AttributePart",
|
|
6556
|
-
signatures: [["root","element","localName","?init"]]
|
|
6557
|
-
},
|
|
6558
|
-
{
|
|
6559
|
-
name: "ChildNodePart",
|
|
6560
|
-
signatures: [["root","previousSibling","nextSibling","?init"]]
|
|
6561
|
-
},
|
|
6562
6554
|
{
|
|
6563
6555
|
name: "Comment",
|
|
6564
6556
|
signatures: [["?data"]]
|
|
@@ -6623,10 +6615,6 @@ export const NativeFunctions = [
|
|
|
6623
6615
|
name: "Event",
|
|
6624
6616
|
signatures: [["type","?eventInitDict"]]
|
|
6625
6617
|
},
|
|
6626
|
-
{
|
|
6627
|
-
name: "getValueRange",
|
|
6628
|
-
signatures: [["start","end"]]
|
|
6629
|
-
},
|
|
6630
6618
|
{
|
|
6631
6619
|
name: "getBoxQuads",
|
|
6632
6620
|
signatures: [["?options"]]
|
|
@@ -6647,10 +6635,6 @@ export const NativeFunctions = [
|
|
|
6647
6635
|
name: "MutationObserver",
|
|
6648
6636
|
signatures: [["callback"]]
|
|
6649
6637
|
},
|
|
6650
|
-
{
|
|
6651
|
-
name: "NodePart",
|
|
6652
|
-
signatures: [["root","node","?init"]]
|
|
6653
|
-
},
|
|
6654
6638
|
{
|
|
6655
6639
|
name: "Observable",
|
|
6656
6640
|
signatures: [["callback"]]
|
|
@@ -6683,6 +6667,10 @@ export const NativeFunctions = [
|
|
|
6683
6667
|
name: "last",
|
|
6684
6668
|
signatures: [["?options"]]
|
|
6685
6669
|
},
|
|
6670
|
+
{
|
|
6671
|
+
name: "getValueRange",
|
|
6672
|
+
signatures: [["start","end"]]
|
|
6673
|
+
},
|
|
6686
6674
|
{
|
|
6687
6675
|
name: "moveBefore",
|
|
6688
6676
|
signatures: [["node","child"]]
|
|
@@ -275,9 +275,9 @@ async function getEmptyStateSuggestions(conversation?: AiAssistanceModel.AiConve
|
|
|
275
275
|
|
|
276
276
|
case AiAssistanceModel.AiHistoryStorage.ConversationType.NONE: {
|
|
277
277
|
return [
|
|
278
|
-
{title: '
|
|
279
|
-
{title: 'What performance issues exist
|
|
280
|
-
{title: 'What are the slowest requests on this page?', jslogContext: 'empty'},
|
|
278
|
+
{title: 'What can you help me with?', jslogContext: 'empty'},
|
|
279
|
+
{title: 'What performance issues exist on the page?', jslogContext: 'empty'},
|
|
280
|
+
{title: 'What are the slowest network requests on this page?', jslogContext: 'empty'},
|
|
281
281
|
];
|
|
282
282
|
}
|
|
283
283
|
|
|
@@ -503,7 +503,6 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
503
503
|
#selectedRequest: AiAssistanceModel.NetworkAgent.RequestContext|null = null;
|
|
504
504
|
// Messages displayed in the `ChatView` component.
|
|
505
505
|
#messages: Message[] = [];
|
|
506
|
-
#isContextAutoSelectionSuspended = false;
|
|
507
506
|
|
|
508
507
|
// Whether the UI should show loading or not.
|
|
509
508
|
#isLoading = false;
|
|
@@ -703,13 +702,6 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
703
702
|
// If there already is an agent and if it is not empty,
|
|
704
703
|
// we don't automatically change the agent.
|
|
705
704
|
if (this.#conversation && !this.#conversation.isEmpty) {
|
|
706
|
-
// If the context selection agent is enabled,
|
|
707
|
-
// we update the context of the current agent.
|
|
708
|
-
const context = this.#getConversationContext(this.#getDefaultConversationType());
|
|
709
|
-
if (context && isAiAssistanceContextSelectionAgentEnabled()) {
|
|
710
|
-
this.#conversation?.setContext(context);
|
|
711
|
-
this.requestUpdate();
|
|
712
|
-
}
|
|
713
705
|
return;
|
|
714
706
|
}
|
|
715
707
|
|
|
@@ -758,13 +750,20 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
758
750
|
}
|
|
759
751
|
|
|
760
752
|
this.#conversation = conversation;
|
|
761
|
-
this.#isContextAutoSelectionSuspended = false;
|
|
762
753
|
}
|
|
763
754
|
|
|
764
|
-
if (
|
|
765
|
-
this.#conversation
|
|
766
|
-
|
|
767
|
-
|
|
755
|
+
if (this.#conversation) {
|
|
756
|
+
if (this.#conversation.isEmpty && isAiAssistanceContextSelectionAgentEnabled()) {
|
|
757
|
+
this.#conversation.setContext(this.#getConversationContext(this.#getDefaultConversationType()));
|
|
758
|
+
} else {
|
|
759
|
+
const context = this.#getConversationContext(this.#conversation.type);
|
|
760
|
+
// Don't reset to the context selection agent if
|
|
761
|
+
// we remove context automatically.
|
|
762
|
+
// Require explicit user action.
|
|
763
|
+
if (context || !isAiAssistanceContextSelectionAgentEnabled()) {
|
|
764
|
+
this.#conversation.setContext(context);
|
|
765
|
+
}
|
|
766
|
+
}
|
|
768
767
|
}
|
|
769
768
|
|
|
770
769
|
this.requestUpdate();
|
|
@@ -1132,12 +1131,10 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1132
1131
|
|
|
1133
1132
|
#handleContextRemoved(): void {
|
|
1134
1133
|
this.#conversation?.setContext(null);
|
|
1135
|
-
this.#isContextAutoSelectionSuspended = true;
|
|
1136
1134
|
this.requestUpdate();
|
|
1137
1135
|
}
|
|
1138
1136
|
|
|
1139
1137
|
#handleContextAdd(): void {
|
|
1140
|
-
this.#isContextAutoSelectionSuspended = false;
|
|
1141
1138
|
this.#conversation?.setContext(this.#getConversationContext(this.#getDefaultConversationType()));
|
|
1142
1139
|
this.requestUpdate();
|
|
1143
1140
|
}
|
|
@@ -1159,7 +1156,6 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1159
1156
|
return;
|
|
1160
1157
|
}
|
|
1161
1158
|
|
|
1162
|
-
this.#isContextAutoSelectionSuspended = false;
|
|
1163
1159
|
let targetConversationType: AiAssistanceModel.AiHistoryStorage.ConversationType|undefined;
|
|
1164
1160
|
switch (actionId) {
|
|
1165
1161
|
case 'freestyler.elements-floating-button': {
|
|
@@ -1354,8 +1350,6 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1354
1350
|
this.#selectedPerformanceTrace = data;
|
|
1355
1351
|
}
|
|
1356
1352
|
|
|
1357
|
-
this.#isContextAutoSelectionSuspended = false;
|
|
1358
|
-
|
|
1359
1353
|
void VisualLogging.logFunctionCall(`context-change-${this.#conversation?.type}`);
|
|
1360
1354
|
|
|
1361
1355
|
this.requestUpdate();
|
|
@@ -374,6 +374,7 @@ export class PreloadingAttemptView extends UI.Widget.VBox {
|
|
|
374
374
|
private readonly preloadingDetails =
|
|
375
375
|
new PreloadingComponents.PreloadingDetailsReportView.PreloadingDetailsReportView();
|
|
376
376
|
private readonly ruleSetSelector: PreloadingRuleSetSelector;
|
|
377
|
+
private clearButton: UI.Toolbar.ToolbarButton;
|
|
377
378
|
|
|
378
379
|
constructor(model: SDK.PreloadingModel.PreloadingModel) {
|
|
379
380
|
super({
|
|
@@ -415,6 +416,23 @@ export class PreloadingAttemptView extends UI.Widget.VBox {
|
|
|
415
416
|
|
|
416
417
|
const toolbar = vbox.contentElement.createChild('devtools-toolbar', 'preloading-toolbar');
|
|
417
418
|
toolbar.setAttribute('jslog', `${VisualLogging.toolbar()}`);
|
|
419
|
+
|
|
420
|
+
// Clear button first (leftmost)
|
|
421
|
+
this.clearButton =
|
|
422
|
+
new UI.Toolbar.ToolbarButton('Clear speculative loads', 'clear', undefined, 'clear-speculative-loads');
|
|
423
|
+
this.clearButton.addEventListener(UI.Toolbar.ToolbarButton.Events.CLICK, () => {
|
|
424
|
+
const model =
|
|
425
|
+
SDK.TargetManager.TargetManager.instance().scopeTarget()?.model(SDK.PreloadingModel.PreloadingModel);
|
|
426
|
+
if (!model) {
|
|
427
|
+
return;
|
|
428
|
+
}
|
|
429
|
+
|
|
430
|
+
model.reset();
|
|
431
|
+
this.ruleSetSelector.select(null);
|
|
432
|
+
});
|
|
433
|
+
toolbar.appendToolbarItem(this.clearButton);
|
|
434
|
+
|
|
435
|
+
// Rule set dropdown
|
|
418
436
|
this.ruleSetSelector = new PreloadingRuleSetSelector(() => this.render());
|
|
419
437
|
toolbar.appendToolbarItem(this.ruleSetSelector.item());
|
|
420
438
|
|
|
@@ -4,11 +4,19 @@
|
|
|
4
4
|
* found in the LICENSE file.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
+
:host {
|
|
8
|
+
height: 100%;
|
|
9
|
+
}
|
|
10
|
+
|
|
7
11
|
.placeholder {
|
|
8
12
|
display: flex;
|
|
9
13
|
height: 100%;
|
|
10
14
|
}
|
|
11
15
|
|
|
16
|
+
.ruleset-header-container {
|
|
17
|
+
flex-shrink: 0;
|
|
18
|
+
}
|
|
19
|
+
|
|
12
20
|
.ruleset-header {
|
|
13
21
|
padding: 4px 8px;
|
|
14
22
|
white-space: nowrap;
|
|
@@ -20,3 +28,7 @@
|
|
|
20
28
|
.ruleset-header devtools-icon {
|
|
21
29
|
vertical-align: sub;
|
|
22
30
|
}
|
|
31
|
+
|
|
32
|
+
.text-editor-container {
|
|
33
|
+
overflow: auto;
|
|
34
|
+
}
|
|
@@ -49,7 +49,7 @@ export const DEFAULT_VIEW = (input: ViewInput|null, _output: object, target: HTM
|
|
|
49
49
|
<style>${UI.inspectorCommonStyles}</style>
|
|
50
50
|
${input
|
|
51
51
|
? html`
|
|
52
|
-
<div class="
|
|
52
|
+
<div class="ruleset-header-container">
|
|
53
53
|
<div class="ruleset-header" id="ruleset-url">${input.url}</div>
|
|
54
54
|
${input.errorMessage ? html`
|
|
55
55
|
<div class="ruleset-header">
|
|
@@ -59,8 +59,8 @@ export const DEFAULT_VIEW = (input: ViewInput|null, _output: object, target: HTM
|
|
|
59
59
|
</div>
|
|
60
60
|
` : nothing}
|
|
61
61
|
</div>
|
|
62
|
-
<div class="text-
|
|
63
|
-
<devtools-text-editor .
|
|
62
|
+
<div class="text-editor-container">
|
|
63
|
+
<devtools-text-editor .state=${input.editorState}></devtools-text-editor>
|
|
64
64
|
</div>`
|
|
65
65
|
: html`
|
|
66
66
|
<div class="placeholder">
|
|
@@ -252,9 +252,9 @@ export const concatErrorDescriptionAndIssueSummary = (description: string, issue
|
|
|
252
252
|
return description;
|
|
253
253
|
};
|
|
254
254
|
|
|
255
|
-
// This value reflects the 18px min-height of .console-message
|
|
256
|
-
//
|
|
257
|
-
const defaultConsoleRowHeight =
|
|
255
|
+
// This value reflects the 18px min-height of .console-message.
|
|
256
|
+
// Keep in sync with consoleView.css.
|
|
257
|
+
const defaultConsoleRowHeight = 18;
|
|
258
258
|
|
|
259
259
|
const parameterToRemoteObject = (runtimeModel: SDK.RuntimeModel.RuntimeModel|null):
|
|
260
260
|
(parameter?: SDK.RemoteObject.RemoteObject|Protocol.Runtime.RemoteObject|string) => SDK.RemoteObject.RemoteObject =>
|
|
@@ -277,7 +277,7 @@ export class ColorSwatchPopoverIcon extends Common.ObjectWrapper.ObjectWrapper<C
|
|
|
277
277
|
return;
|
|
278
278
|
}
|
|
279
279
|
|
|
280
|
-
this.swatch.color
|
|
280
|
+
this.swatch.renderColor(color);
|
|
281
281
|
this.dispatchEventToListeners(ColorSwatchPopoverIconEvents.COLOR_CHANGED, color);
|
|
282
282
|
}
|
|
283
283
|
|
|
@@ -48,7 +48,6 @@ import * as Lit from '../../ui/lit/lit.js';
|
|
|
48
48
|
import * as ElementsComponents from './components/components.js';
|
|
49
49
|
import computedStyleWidgetStyles from './computedStyleWidget.css.js';
|
|
50
50
|
import {ImagePreviewPopover} from './ImagePreviewPopover.js';
|
|
51
|
-
import {PlatformFontsWidget} from './PlatformFontsWidget.js';
|
|
52
51
|
import {categorizePropertyName, type Category, DefaultCategoryOrder} from './PropertyNameCategories.js';
|
|
53
52
|
import {Renderer, rendererBase, type RenderingContext, StringRenderer, URLRenderer} from './PropertyRenderer.js';
|
|
54
53
|
import {StylePropertiesSection} from './StylePropertiesSection.js';
|
|
@@ -208,8 +207,8 @@ class ColorRenderer extends rendererBase(SDK.CSSPropertyParserMatchers.ColorMatc
|
|
|
208
207
|
}
|
|
209
208
|
|
|
210
209
|
const swatch = new InlineEditor.ColorSwatch.ColorSwatch();
|
|
211
|
-
swatch.
|
|
212
|
-
swatch.color
|
|
210
|
+
swatch.setReadonly(true);
|
|
211
|
+
swatch.renderColor(color);
|
|
213
212
|
const valueElement = document.createElement('span');
|
|
214
213
|
valueElement.textContent = match.text;
|
|
215
214
|
|
|
@@ -265,7 +264,6 @@ type ComputedStyleData = {
|
|
|
265
264
|
interface ComputedStyleWidgetInput {
|
|
266
265
|
computedStylesTree: TreeOutline.TreeOutline.TreeOutline<ComputedStyleData>;
|
|
267
266
|
hasMatches: boolean;
|
|
268
|
-
computedStyleModel?: ComputedStyleModule.ComputedStyleModel.ComputedStyleModel;
|
|
269
267
|
showInheritedComputedStylePropertiesSetting: Common.Settings.Setting<boolean>;
|
|
270
268
|
groupComputedStylesSetting: Common.Settings.Setting<boolean>;
|
|
271
269
|
onFilterChanged: (event: CustomEvent<string>) => void;
|
|
@@ -301,7 +299,6 @@ export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
301
299
|
</div>
|
|
302
300
|
${input.computedStylesTree}
|
|
303
301
|
${!input.hasMatches ? html`<div class="gray-info-message">${i18nString(UIStrings.noMatchingProperty)}</div>` : ''}
|
|
304
|
-
${input.computedStyleModel ? html`<devtools-widget .widgetConfig=${UI.Widget.widgetConfig(PlatformFontsWidget, { sharedModel: input.computedStyleModel})}></devtools-widget>` : ''}
|
|
305
302
|
`, target);
|
|
306
303
|
// clang-format on
|
|
307
304
|
};
|
|
@@ -355,16 +352,6 @@ export class ComputedStyleWidget extends UI.Widget.VBox {
|
|
|
355
352
|
this.#computedStylesTree.classList.toggle('computed-narrow', isNarrow);
|
|
356
353
|
}
|
|
357
354
|
|
|
358
|
-
override wasShown(): void {
|
|
359
|
-
UI.Context.Context.instance().setFlavor(ComputedStyleWidget, this);
|
|
360
|
-
super.wasShown();
|
|
361
|
-
}
|
|
362
|
-
|
|
363
|
-
override willHide(): void {
|
|
364
|
-
super.willHide();
|
|
365
|
-
UI.Context.Context.instance().setFlavor(ComputedStyleWidget, null);
|
|
366
|
-
}
|
|
367
|
-
|
|
368
355
|
/**
|
|
369
356
|
* @param input.hasMatches Whether any properties matched the current filter (or if any properties exist at all).
|
|
370
357
|
*/
|
|
@@ -373,7 +360,6 @@ export class ComputedStyleWidget extends UI.Widget.VBox {
|
|
|
373
360
|
{
|
|
374
361
|
computedStylesTree: this.#computedStylesTree,
|
|
375
362
|
hasMatches,
|
|
376
|
-
computedStyleModel: this.#computedStyleModel,
|
|
377
363
|
showInheritedComputedStylePropertiesSetting: this.showInheritedComputedStylePropertiesSetting,
|
|
378
364
|
groupComputedStylesSetting: this.groupComputedStylesSetting,
|
|
379
365
|
onFilterChanged: this.onFilterChanged.bind(this),
|