chrome-devtools-frontend 1.0.1601661 → 1.0.1602348
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/.agents/skills/version-control/SKILL.md +71 -0
- package/front_end/core/host/InspectorFrontendHostStub.ts +0 -5
- package/front_end/core/root/Runtime.ts +0 -8
- package/front_end/core/sdk/DOMModel.ts +5 -4
- package/front_end/entrypoints/inspector_main/InspectorMain.ts +1 -1
- package/front_end/entrypoints/main/GlobalAiButton.ts +1 -1
- package/front_end/generated/InspectorBackendCommands.ts +6 -5
- package/front_end/generated/protocol.ts +36 -3
- package/front_end/models/ai_assistance/agents/AccessibilityAgent.ts +167 -9
- package/front_end/models/javascript_metadata/NativeFunctions.js +4 -0
- package/front_end/models/live-metrics/LiveMetrics.ts +51 -31
- package/front_end/panels/accessibility/ARIAAttributesView.ts +2 -2
- package/front_end/panels/ai_assistance/components/ChatInput.ts +3 -2
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +15 -19
- package/front_end/panels/application/KeyValueStorageItemsView.ts +4 -4
- package/front_end/panels/common/AiCodeCompletionSummaryToolbar.ts +2 -1
- package/front_end/panels/console_counters/WarningErrorCounter.ts +7 -14
- package/front_end/panels/elements/NodeStackTraceWidget.ts +2 -1
- package/front_end/panels/elements/StylePropertyTreeElement.ts +2 -1
- package/front_end/panels/network/RequestPayloadView.ts +2 -2
- package/front_end/panels/recorder/RecorderController.ts +4 -3
- package/front_end/panels/recorder/components/CreateRecordingView.ts +2 -1
- package/front_end/panels/recorder/components/RecordingView.ts +2 -2
- package/front_end/panels/recorder/models/RecordingPlayer.ts +3 -0
- package/front_end/panels/security/SecurityPanel.ts +3 -3
- package/front_end/panels/sensors/SensorsView.ts +131 -88
- package/front_end/panels/timeline/TimelineDetailsView.ts +6 -37
- package/front_end/panels/timeline/TimelineUIUtils.ts +0 -118
- package/front_end/panels/timeline/components/IgnoreListSetting.ts +1 -1
- package/front_end/panels/timeline/components/SidebarInsightsTab.ts +2 -2
- package/front_end/panels/timeline/components/TimelineRangeSummaryView.ts +162 -9
- package/front_end/panels/timeline/components/timelineRangeSummaryView.css +20 -8
- package/front_end/panels/whats_new/ReleaseNoteText.ts +10 -10
- package/front_end/panels/whats_new/resources/WNDT.md +6 -6
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/puppeteer/README.chromium +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.js +4 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ChromeLauncher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +3 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.js +4 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ChromeLauncher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/util/version.js +1 -1
- package/front_end/third_party/puppeteer/package/package.json +1 -1
- package/front_end/third_party/puppeteer/package/src/node/ChromeLauncher.ts +8 -0
- package/front_end/third_party/puppeteer/package/src/revisions.ts +2 -2
- package/front_end/third_party/puppeteer/package/src/util/version.ts +1 -1
- package/front_end/ui/legacy/Toolbar.ts +25 -3
- package/front_end/ui/legacy/Widget.ts +35 -40
- package/package.json +1 -1
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: devtools-version-control
|
|
3
|
+
description: Use when managing branches, creating CLs, or handling stacked changes in the DevTools Gerrit-based workflow.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# DevTools Version Control
|
|
7
|
+
|
|
8
|
+
## Overview
|
|
9
|
+
Chrome DevTools uses Gerrit for code review. The standard workflow is **one branch per Change List (CL)** and **one commit per branch**. Instead of multiple commits, you amend your single commit locally.
|
|
10
|
+
|
|
11
|
+
## Core Workflow
|
|
12
|
+
|
|
13
|
+
### Creating a New CL
|
|
14
|
+
To start a new task, create a new branch from `main`:
|
|
15
|
+
```bash
|
|
16
|
+
git new-branch <branch-name>
|
|
17
|
+
```
|
|
18
|
+
*Note: This automatically sets the upstream to `origin/main`.*
|
|
19
|
+
|
|
20
|
+
### Making Changes
|
|
21
|
+
1. Make your changes.
|
|
22
|
+
2. Stage them: `git add <files>`.
|
|
23
|
+
3. Create the commit: `git commit -m "Your message"`.
|
|
24
|
+
|
|
25
|
+
### Updating a CL (Amending)
|
|
26
|
+
To update your CL after feedback or more work:
|
|
27
|
+
1. Make more changes.
|
|
28
|
+
2. Stage them: `git add <files>`.
|
|
29
|
+
3. Amend the commit: `git commit --amend`.
|
|
30
|
+
4. Upload: `git cl upload`.
|
|
31
|
+
|
|
32
|
+
### Stacked CLs
|
|
33
|
+
If CL B depends on CL A:
|
|
34
|
+
1. While on branch A, create branch B:
|
|
35
|
+
```bash
|
|
36
|
+
git new-branch --upstream_current <branch-B>
|
|
37
|
+
```
|
|
38
|
+
2. Develop on branch B.
|
|
39
|
+
3. When uploading B, Gerrit will show the dependency on A.
|
|
40
|
+
|
|
41
|
+
### Reparenting
|
|
42
|
+
If you need to change the base of a branch (e.g., move CL B to be based on `main` instead of CL A):
|
|
43
|
+
```bash
|
|
44
|
+
git reparent-branch main
|
|
45
|
+
```
|
|
46
|
+
Or to make it depend on another branch C:
|
|
47
|
+
```bash
|
|
48
|
+
git reparent-branch <branch-C>
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
### Syncing with Upstream
|
|
52
|
+
To update all your branches with the latest changes from `main` and their respective upstreams:
|
|
53
|
+
```bash
|
|
54
|
+
git rebase-update
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Quick Reference
|
|
58
|
+
|
|
59
|
+
| Action | Command |
|
|
60
|
+
| :--- | :--- |
|
|
61
|
+
| Create new CL from main | `git new-branch <name>` |
|
|
62
|
+
| Create stacked CL | `git new-branch --upstream_current <name>` |
|
|
63
|
+
| Update current CL | `git commit --amend` |
|
|
64
|
+
| Upload to Gerrit | `git cl upload` |
|
|
65
|
+
| Change branch parent | `git reparent-branch <new-parent>` |
|
|
66
|
+
| Sync all branches | `git rebase-update` |
|
|
67
|
+
|
|
68
|
+
## Common Mistakes
|
|
69
|
+
- **Multiple commits on one branch:** Gerrit expects one commit per CL. Always `commit --amend`.
|
|
70
|
+
- **Using `git checkout -b`:** Does not set up tracking information correctly for `depot_tools`. Use `git new-branch`.
|
|
71
|
+
- **Manual rebasing of stacked branches:** Can be complex. Use `git rebase-update` or `git reparent-branch` to let `depot_tools` handle the tracking updates.
|
|
@@ -389,11 +389,6 @@ export class InspectorFrontendHostStub implements InspectorFrontendHostAPI {
|
|
|
389
389
|
devToolsVeLogging: {
|
|
390
390
|
enabled: true,
|
|
391
391
|
},
|
|
392
|
-
thirdPartyCookieControls: {
|
|
393
|
-
thirdPartyCookieMetadataEnabled: true,
|
|
394
|
-
thirdPartyCookieHeuristicsEnabled: true,
|
|
395
|
-
managedBlockThirdPartyCookies: 'Unset',
|
|
396
|
-
},
|
|
397
392
|
devToolsFlexibleLayout: {
|
|
398
393
|
verticalDrawerEnabled: true,
|
|
399
394
|
},
|
|
@@ -542,13 +542,6 @@ export interface HostConfigJpegXlImageFormat {
|
|
|
542
542
|
enabled: boolean;
|
|
543
543
|
}
|
|
544
544
|
|
|
545
|
-
export interface HostConfigThirdPartyCookieControls {
|
|
546
|
-
thirdPartyCookieRestrictionEnabled: boolean;
|
|
547
|
-
thirdPartyCookieMetadataEnabled: boolean;
|
|
548
|
-
thirdPartyCookieHeuristicsEnabled: boolean;
|
|
549
|
-
managedBlockThirdPartyCookies: string|boolean;
|
|
550
|
-
}
|
|
551
|
-
|
|
552
545
|
export interface HostConfigAiAssistanceV2 {
|
|
553
546
|
enabled: boolean;
|
|
554
547
|
}
|
|
@@ -651,7 +644,6 @@ export type HostConfig = Platform.TypeScriptUtilities.RecursivePartial<{
|
|
|
651
644
|
devToolsEnableOriginBoundCookies: HostConfigEnableOriginBoundCookies,
|
|
652
645
|
devToolsAnimationStylesInStylesTab: HostConfigAnimationStylesInStylesTab,
|
|
653
646
|
devToolsJpegXlImageFormat: HostConfigJpegXlImageFormat,
|
|
654
|
-
thirdPartyCookieControls: HostConfigThirdPartyCookieControls,
|
|
655
647
|
devToolsAiGeneratedTimelineLabels: AiGeneratedTimelineLabels,
|
|
656
648
|
devToolsAllowPopoverForcing: AllowPopoverForcing,
|
|
657
649
|
devToolsGlobalAiButton: GlobalAiButton,
|
|
@@ -291,7 +291,7 @@ export class DOMNode extends Common.ObjectWrapper.ObjectWrapper<DOMNodeEventType
|
|
|
291
291
|
|
|
292
292
|
this.setPseudoElements(payload.pseudoElements);
|
|
293
293
|
|
|
294
|
-
if (payload.
|
|
294
|
+
if (payload.adProvenance) {
|
|
295
295
|
this.#isAdRelatedInternal = true;
|
|
296
296
|
}
|
|
297
297
|
|
|
@@ -1831,7 +1831,8 @@ export class DOMModel extends SDKModel<EventTypes> {
|
|
|
1831
1831
|
node.setIsScrollable(isScrollable);
|
|
1832
1832
|
}
|
|
1833
1833
|
|
|
1834
|
-
adRelatedStateUpdated(nodeId: Protocol.DOM.NodeId,
|
|
1834
|
+
adRelatedStateUpdated(nodeId: Protocol.DOM.NodeId, adProvenance?: Protocol.Network.AdProvenance): void {
|
|
1835
|
+
const isAdRelated = adProvenance !== undefined;
|
|
1835
1836
|
const node = this.nodeForId(nodeId);
|
|
1836
1837
|
if (!node || node.isAdRelatedNode() === isAdRelated) {
|
|
1837
1838
|
return;
|
|
@@ -2203,8 +2204,8 @@ class DOMDispatcher implements ProtocolProxyApi.DOMDispatcher {
|
|
|
2203
2204
|
this.#domModel.affectedByStartingStylesFlagUpdated(nodeId, affectedByStartingStyles);
|
|
2204
2205
|
}
|
|
2205
2206
|
|
|
2206
|
-
adRelatedStateUpdated({nodeId,
|
|
2207
|
-
this.#domModel.adRelatedStateUpdated(nodeId,
|
|
2207
|
+
adRelatedStateUpdated({nodeId, adProvenance}: Protocol.DOM.AdRelatedStateUpdatedEvent): void {
|
|
2208
|
+
this.#domModel.adRelatedStateUpdated(nodeId, adProvenance);
|
|
2208
2209
|
}
|
|
2209
2210
|
}
|
|
2210
2211
|
|
|
@@ -214,7 +214,7 @@ export class NodeIndicatorProvider implements UI.Toolbar.Provider {
|
|
|
214
214
|
|
|
215
215
|
private constructor() {
|
|
216
216
|
this.#widgetElement = document.createElement('devtools-widget') as UI.Widget.WidgetElement<NodeIndicator>;
|
|
217
|
-
this.#widgetElement
|
|
217
|
+
new NodeIndicator(this.#widgetElement);
|
|
218
218
|
|
|
219
219
|
this.#toolbarItem = new UI.Toolbar.ToolbarItem(this.#widgetElement);
|
|
220
220
|
this.#toolbarItem.setVisible(false);
|
|
@@ -210,7 +210,7 @@ export class GlobalAiButtonToolbarProvider implements UI.Toolbar.Provider {
|
|
|
210
210
|
|
|
211
211
|
private constructor() {
|
|
212
212
|
this.#widgetElement = document.createElement('devtools-widget') as UI.Widget.WidgetElement<GlobalAiButton>;
|
|
213
|
-
this.#widgetElement
|
|
213
|
+
new GlobalAiButton(this.#widgetElement);
|
|
214
214
|
|
|
215
215
|
this.#toolbarItem = new UI.Toolbar.ToolbarItemWithCompactLayout(this.#widgetElement);
|
|
216
216
|
this.#toolbarItem.setVisible(false);
|
|
@@ -345,7 +345,7 @@ inspectorBackend.registerCommand("Cast.stopCasting", [{"name": "sinkName", "type
|
|
|
345
345
|
inspectorBackend.registerType("Cast.Sink", [{"name": "name", "type": "string", "optional": false, "description": "", "typeRef": null}, {"name": "id", "type": "string", "optional": false, "description": "", "typeRef": null}, {"name": "session", "type": "string", "optional": true, "description": "Text describing the current session. Present only if there is an active session on the sink.", "typeRef": null}]);
|
|
346
346
|
|
|
347
347
|
// DOM.
|
|
348
|
-
inspectorBackend.registerEnum("DOM.PseudoType", {FirstLine: "first-line", FirstLetter: "first-letter", Checkmark: "checkmark", Before: "before", After: "after", PickerIcon: "picker-icon", InterestHint: "interest-hint", Marker: "marker", Backdrop: "backdrop", Column: "column", Selection: "selection", SearchText: "search-text", TargetText: "target-text", SpellingError: "spelling-error", GrammarError: "grammar-error", Highlight: "highlight", FirstLineInherited: "first-line-inherited", ScrollMarker: "scroll-marker", ScrollMarkerGroup: "scroll-marker-group", ScrollButton: "scroll-button", Scrollbar: "scrollbar", ScrollbarThumb: "scrollbar-thumb", ScrollbarButton: "scrollbar-button", ScrollbarTrack: "scrollbar-track", ScrollbarTrackPiece: "scrollbar-track-piece", ScrollbarCorner: "scrollbar-corner", Resizer: "resizer", InputListButton: "input-list-button", ViewTransition: "view-transition", ViewTransitionGroup: "view-transition-group", ViewTransitionImagePair: "view-transition-image-pair", ViewTransitionGroupChildren: "view-transition-group-children", ViewTransitionOld: "view-transition-old", ViewTransitionNew: "view-transition-new", Placeholder: "placeholder", FileSelectorButton: "file-selector-button", DetailsContent: "details-content", Picker: "picker", PermissionIcon: "permission-icon", OverscrollAreaParent: "overscroll-area-parent"});
|
|
348
|
+
inspectorBackend.registerEnum("DOM.PseudoType", {FirstLine: "first-line", FirstLetter: "first-letter", Checkmark: "checkmark", Before: "before", After: "after", ExpandIcon: "expand-icon", PickerIcon: "picker-icon", InterestHint: "interest-hint", Marker: "marker", Backdrop: "backdrop", Column: "column", Selection: "selection", SearchText: "search-text", TargetText: "target-text", SpellingError: "spelling-error", GrammarError: "grammar-error", Highlight: "highlight", FirstLineInherited: "first-line-inherited", ScrollMarker: "scroll-marker", ScrollMarkerGroup: "scroll-marker-group", ScrollButton: "scroll-button", Scrollbar: "scrollbar", ScrollbarThumb: "scrollbar-thumb", ScrollbarButton: "scrollbar-button", ScrollbarTrack: "scrollbar-track", ScrollbarTrackPiece: "scrollbar-track-piece", ScrollbarCorner: "scrollbar-corner", Resizer: "resizer", InputListButton: "input-list-button", ViewTransition: "view-transition", ViewTransitionGroup: "view-transition-group", ViewTransitionImagePair: "view-transition-image-pair", ViewTransitionGroupChildren: "view-transition-group-children", ViewTransitionOld: "view-transition-old", ViewTransitionNew: "view-transition-new", Placeholder: "placeholder", FileSelectorButton: "file-selector-button", DetailsContent: "details-content", Picker: "picker", PermissionIcon: "permission-icon", OverscrollAreaParent: "overscroll-area-parent"});
|
|
349
349
|
inspectorBackend.registerEnum("DOM.ShadowRootType", {UserAgent: "user-agent", Open: "open", Closed: "closed"});
|
|
350
350
|
inspectorBackend.registerEnum("DOM.CompatibilityMode", {QuirksMode: "QuirksMode", LimitedQuirksMode: "LimitedQuirksMode", NoQuirksMode: "NoQuirksMode"});
|
|
351
351
|
inspectorBackend.registerEnum("DOM.PhysicalAxes", {Horizontal: "Horizontal", Vertical: "Vertical", Both: "Both"});
|
|
@@ -364,7 +364,7 @@ inspectorBackend.registerEvent("DOM.inlineStyleInvalidated", ["nodeIds"]);
|
|
|
364
364
|
inspectorBackend.registerEvent("DOM.pseudoElementAdded", ["parentId", "pseudoElement"]);
|
|
365
365
|
inspectorBackend.registerEvent("DOM.topLayerElementsUpdated", []);
|
|
366
366
|
inspectorBackend.registerEvent("DOM.scrollableFlagUpdated", ["nodeId", "isScrollable"]);
|
|
367
|
-
inspectorBackend.registerEvent("DOM.adRelatedStateUpdated", ["nodeId", "
|
|
367
|
+
inspectorBackend.registerEvent("DOM.adRelatedStateUpdated", ["nodeId", "adProvenance"]);
|
|
368
368
|
inspectorBackend.registerEvent("DOM.affectedByStartingStylesFlagUpdated", ["nodeId", "affectedByStartingStyles"]);
|
|
369
369
|
inspectorBackend.registerEvent("DOM.pseudoElementRemoved", ["parentId", "pseudoElementId"]);
|
|
370
370
|
inspectorBackend.registerEvent("DOM.setChildNodes", ["parentId", "nodes"]);
|
|
@@ -426,7 +426,7 @@ inspectorBackend.registerCommand("DOM.getQueryingDescendantsForContainer", [{"na
|
|
|
426
426
|
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.");
|
|
427
427
|
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.");
|
|
428
428
|
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"}]);
|
|
429
|
-
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": "
|
|
429
|
+
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": "adProvenance", "type": "object", "optional": true, "description": "", "typeRef": "Network.AdProvenance"}]);
|
|
430
430
|
inspectorBackend.registerType("DOM.DetachedElementInfo", [{"name": "treeNode", "type": "object", "optional": false, "description": "", "typeRef": "DOM.Node"}, {"name": "retainedNodeIds", "type": "array", "optional": false, "description": "", "typeRef": "DOM.NodeId"}]);
|
|
431
431
|
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}]);
|
|
432
432
|
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"}]);
|
|
@@ -928,6 +928,7 @@ inspectorBackend.registerType("Network.ConnectTiming", [{"name": "requestTime",
|
|
|
928
928
|
inspectorBackend.registerType("Network.ClientSecurityState", [{"name": "initiatorIsSecureContext", "type": "boolean", "optional": false, "description": "", "typeRef": null}, {"name": "initiatorIPAddressSpace", "type": "string", "optional": false, "description": "", "typeRef": "Network.IPAddressSpace"}, {"name": "localNetworkAccessRequestPolicy", "type": "string", "optional": false, "description": "", "typeRef": "Network.LocalNetworkAccessRequestPolicy"}]);
|
|
929
929
|
inspectorBackend.registerType("Network.AdScriptIdentifier", [{"name": "scriptId", "type": "string", "optional": false, "description": "The script's V8 identifier.", "typeRef": "Runtime.ScriptId"}, {"name": "debuggerId", "type": "string", "optional": false, "description": "V8's debugging ID for the v8::Context.", "typeRef": "Runtime.UniqueDebuggerId"}, {"name": "name", "type": "string", "optional": false, "description": "The script's url (or generated name based on id if inline script).", "typeRef": null}]);
|
|
930
930
|
inspectorBackend.registerType("Network.AdAncestry", [{"name": "ancestryChain", "type": "array", "optional": false, "description": "A chain of `AdScriptIdentifier`s representing the ancestry of an ad script that led to the creation of a resource or element. The chain is ordered from the script itself (lowest level) up to its root ancestor that was flagged by a filter list.", "typeRef": "Network.AdScriptIdentifier"}, {"name": "rootScriptFilterlistRule", "type": "string", "optional": true, "description": "The filter list rule that caused the root (last) script in `ancestryChain` to be tagged as an ad.", "typeRef": null}]);
|
|
931
|
+
inspectorBackend.registerType("Network.AdProvenance", [{"name": "filterlistRule", "type": "string", "optional": true, "description": "The filterlist rule that matched, if any.", "typeRef": null}, {"name": "adScriptAncestry", "type": "object", "optional": true, "description": "The script ancestry that created the ad, if any.", "typeRef": "Network.AdAncestry"}]);
|
|
931
932
|
inspectorBackend.registerType("Network.CrossOriginOpenerPolicyStatus", [{"name": "value", "type": "string", "optional": false, "description": "", "typeRef": "Network.CrossOriginOpenerPolicyValue"}, {"name": "reportOnlyValue", "type": "string", "optional": false, "description": "", "typeRef": "Network.CrossOriginOpenerPolicyValue"}, {"name": "reportingEndpoint", "type": "string", "optional": true, "description": "", "typeRef": null}, {"name": "reportOnlyReportingEndpoint", "type": "string", "optional": true, "description": "", "typeRef": null}]);
|
|
932
933
|
inspectorBackend.registerType("Network.CrossOriginEmbedderPolicyStatus", [{"name": "value", "type": "string", "optional": false, "description": "", "typeRef": "Network.CrossOriginEmbedderPolicyValue"}, {"name": "reportOnlyValue", "type": "string", "optional": false, "description": "", "typeRef": "Network.CrossOriginEmbedderPolicyValue"}, {"name": "reportingEndpoint", "type": "string", "optional": true, "description": "", "typeRef": null}, {"name": "reportOnlyReportingEndpoint", "type": "string", "optional": true, "description": "", "typeRef": null}]);
|
|
933
934
|
inspectorBackend.registerType("Network.ContentSecurityPolicyStatus", [{"name": "effectiveDirectives", "type": "string", "optional": false, "description": "", "typeRef": null}, {"name": "isEnforced", "type": "boolean", "optional": false, "description": "", "typeRef": null}, {"name": "source", "type": "string", "optional": false, "description": "", "typeRef": "Network.ContentSecurityPolicySource"}]);
|
|
@@ -1493,7 +1494,7 @@ inspectorBackend.registerType("WebAudio.AudioParam", [{"name": "paramId", "type"
|
|
|
1493
1494
|
|
|
1494
1495
|
// WebAuthn.
|
|
1495
1496
|
inspectorBackend.registerEnum("WebAuthn.AuthenticatorProtocol", {U2f: "u2f", Ctap2: "ctap2"});
|
|
1496
|
-
inspectorBackend.registerEnum("WebAuthn.Ctap2Version", {Ctap2_0: "ctap2_0", Ctap2_1: "ctap2_1"});
|
|
1497
|
+
inspectorBackend.registerEnum("WebAuthn.Ctap2Version", {Ctap2_0: "ctap2_0", Ctap2_1: "ctap2_1", Ctap2_2: "ctap2_2"});
|
|
1497
1498
|
inspectorBackend.registerEnum("WebAuthn.AuthenticatorTransport", {Usb: "usb", Nfc: "nfc", Ble: "ble", Cable: "cable", Internal: "internal"});
|
|
1498
1499
|
inspectorBackend.registerEvent("WebAuthn.credentialAdded", ["authenticatorId", "credential"]);
|
|
1499
1500
|
inspectorBackend.registerEvent("WebAuthn.credentialDeleted", ["authenticatorId", "credentialId"]);
|
|
@@ -1512,7 +1513,7 @@ inspectorBackend.registerCommand("WebAuthn.clearCredentials", [{"name": "authent
|
|
|
1512
1513
|
inspectorBackend.registerCommand("WebAuthn.setUserVerified", [{"name": "authenticatorId", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorId"}, {"name": "isUserVerified", "type": "boolean", "optional": false, "description": "", "typeRef": null}], [], "Sets whether User Verification succeeds or fails for an authenticator. The default is true.");
|
|
1513
1514
|
inspectorBackend.registerCommand("WebAuthn.setAutomaticPresenceSimulation", [{"name": "authenticatorId", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorId"}, {"name": "enabled", "type": "boolean", "optional": false, "description": "", "typeRef": null}], [], "Sets whether tests of user presence will succeed immediately (if true) or fail to resolve (if false) for an authenticator. The default is true.");
|
|
1514
1515
|
inspectorBackend.registerCommand("WebAuthn.setCredentialProperties", [{"name": "authenticatorId", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorId"}, {"name": "credentialId", "type": "string", "optional": false, "description": "", "typeRef": null}, {"name": "backupEligibility", "type": "boolean", "optional": true, "description": "", "typeRef": null}, {"name": "backupState", "type": "boolean", "optional": true, "description": "", "typeRef": null}], [], "Allows setting credential properties. https://w3c.github.io/webauthn/#sctn-automation-set-credential-properties");
|
|
1515
|
-
inspectorBackend.registerType("WebAuthn.VirtualAuthenticatorOptions", [{"name": "protocol", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorProtocol"}, {"name": "ctap2Version", "type": "string", "optional": true, "description": "Defaults to ctap2_0. Ignored if |protocol| == u2f.", "typeRef": "WebAuthn.Ctap2Version"}, {"name": "transport", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorTransport"}, {"name": "hasResidentKey", "type": "boolean", "optional": true, "description": "Defaults to false.", "typeRef": null}, {"name": "hasUserVerification", "type": "boolean", "optional": true, "description": "Defaults to false.", "typeRef": null}, {"name": "hasLargeBlob", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the largeBlob extension. https://w3c.github.io/webauthn#largeBlob Defaults to false.", "typeRef": null}, {"name": "hasCredBlob", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the credBlob extension. https://fidoalliance.org/specs/fido-v2.1-rd-20201208/fido-client-to-authenticator-protocol-v2.1-rd-20201208.html#sctn-credBlob-extension Defaults to false.", "typeRef": null}, {"name": "hasMinPinLength", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the minPinLength extension. https://fidoalliance.org/specs/fido-v2.1-ps-20210615/fido-client-to-authenticator-protocol-v2.1-ps-20210615.html#sctn-minpinlength-extension Defaults to false.", "typeRef": null}, {"name": "hasPrf", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the prf extension. https://w3c.github.io/webauthn/#prf-extension Defaults to false.", "typeRef": null}, {"name": "automaticPresenceSimulation", "type": "boolean", "optional": true, "description": "If set to true, tests of user presence will succeed immediately. Otherwise, they will not be resolved. Defaults to true.", "typeRef": null}, {"name": "isUserVerified", "type": "boolean", "optional": true, "description": "Sets whether User Verification succeeds or fails for an authenticator. Defaults to false.", "typeRef": null}, {"name": "defaultBackupEligibility", "type": "boolean", "optional": true, "description": "Credentials created by this authenticator will have the backup eligibility (BE) flag set to this value. Defaults to false. https://w3c.github.io/webauthn/#sctn-credential-backup", "typeRef": null}, {"name": "defaultBackupState", "type": "boolean", "optional": true, "description": "Credentials created by this authenticator will have the backup state (BS) flag set to this value. Defaults to false. https://w3c.github.io/webauthn/#sctn-credential-backup", "typeRef": null}]);
|
|
1516
|
+
inspectorBackend.registerType("WebAuthn.VirtualAuthenticatorOptions", [{"name": "protocol", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorProtocol"}, {"name": "ctap2Version", "type": "string", "optional": true, "description": "Defaults to ctap2_0. Ignored if |protocol| == u2f.", "typeRef": "WebAuthn.Ctap2Version"}, {"name": "transport", "type": "string", "optional": false, "description": "", "typeRef": "WebAuthn.AuthenticatorTransport"}, {"name": "hasResidentKey", "type": "boolean", "optional": true, "description": "Defaults to false.", "typeRef": null}, {"name": "hasUserVerification", "type": "boolean", "optional": true, "description": "Defaults to false.", "typeRef": null}, {"name": "hasLargeBlob", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the largeBlob extension. https://w3c.github.io/webauthn#largeBlob Defaults to false.", "typeRef": null}, {"name": "hasCredBlob", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the credBlob extension. https://fidoalliance.org/specs/fido-v2.1-rd-20201208/fido-client-to-authenticator-protocol-v2.1-rd-20201208.html#sctn-credBlob-extension Defaults to false.", "typeRef": null}, {"name": "hasMinPinLength", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the minPinLength extension. https://fidoalliance.org/specs/fido-v2.1-ps-20210615/fido-client-to-authenticator-protocol-v2.1-ps-20210615.html#sctn-minpinlength-extension Defaults to false.", "typeRef": null}, {"name": "hasPrf", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the prf extension. https://w3c.github.io/webauthn/#prf-extension Defaults to false.", "typeRef": null}, {"name": "hasHmacSecret", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the hmac-secret extension. https://fidoalliance.org/specs/fido-v2.1-ps-20210615/fido-client-to-authenticator-protocol-v2.1-ps-20210615.html#sctn-hmac-secret-extension Defaults to false.", "typeRef": null}, {"name": "hasHmacSecretMc", "type": "boolean", "optional": true, "description": "If set to true, the authenticator will support the hmac-secret-mc extension. https://fidoalliance.org/specs/fido-v2.2-rd-20241003/fido-client-to-authenticator-protocol-v2.2-rd-20241003.html#sctn-hmac-secret-make-cred-extension Defaults to false.", "typeRef": null}, {"name": "automaticPresenceSimulation", "type": "boolean", "optional": true, "description": "If set to true, tests of user presence will succeed immediately. Otherwise, they will not be resolved. Defaults to true.", "typeRef": null}, {"name": "isUserVerified", "type": "boolean", "optional": true, "description": "Sets whether User Verification succeeds or fails for an authenticator. Defaults to false.", "typeRef": null}, {"name": "defaultBackupEligibility", "type": "boolean", "optional": true, "description": "Credentials created by this authenticator will have the backup eligibility (BE) flag set to this value. Defaults to false. https://w3c.github.io/webauthn/#sctn-credential-backup", "typeRef": null}, {"name": "defaultBackupState", "type": "boolean", "optional": true, "description": "Credentials created by this authenticator will have the backup state (BS) flag set to this value. Defaults to false. https://w3c.github.io/webauthn/#sctn-credential-backup", "typeRef": null}]);
|
|
1516
1517
|
inspectorBackend.registerType("WebAuthn.Credential", [{"name": "credentialId", "type": "string", "optional": false, "description": "", "typeRef": null}, {"name": "isResidentCredential", "type": "boolean", "optional": false, "description": "", "typeRef": null}, {"name": "rpId", "type": "string", "optional": true, "description": "Relying Party ID the credential is scoped to. Must be set when adding a credential.", "typeRef": null}, {"name": "privateKey", "type": "string", "optional": false, "description": "The ECDSA P-256 private key in PKCS#8 format.", "typeRef": null}, {"name": "userHandle", "type": "string", "optional": true, "description": "An opaque byte sequence with a maximum size of 64 bytes mapping the credential to a specific user.", "typeRef": null}, {"name": "signCount", "type": "number", "optional": false, "description": "Signature counter. This is incremented by one for each successful assertion. See https://w3c.github.io/webauthn/#signature-counter", "typeRef": null}, {"name": "largeBlob", "type": "string", "optional": true, "description": "The large blob associated with the credential. See https://w3c.github.io/webauthn/#sctn-large-blob-extension", "typeRef": null}, {"name": "backupEligibility", "type": "boolean", "optional": true, "description": "Assertions returned by this credential will have the backup eligibility (BE) flag set to this value. Defaults to the authenticator's defaultBackupEligibility value.", "typeRef": null}, {"name": "backupState", "type": "boolean", "optional": true, "description": "Assertions returned by this credential will have the backup state (BS) flag set to this value. Defaults to the authenticator's defaultBackupState value.", "typeRef": null}, {"name": "userName", "type": "string", "optional": true, "description": "The credential's user.name property. Equivalent to empty if not set. https://w3c.github.io/webauthn/#dom-publickeycredentialentity-name", "typeRef": null}, {"name": "userDisplayName", "type": "string", "optional": true, "description": "The credential's user.displayName property. Equivalent to empty if not set. https://w3c.github.io/webauthn/#dom-publickeycredentialuserentity-displayname", "typeRef": null}]);
|
|
1517
1518
|
|
|
1518
1519
|
// WebMCP.
|
|
@@ -4576,6 +4576,7 @@ export namespace DOM {
|
|
|
4576
4576
|
Checkmark = 'checkmark',
|
|
4577
4577
|
Before = 'before',
|
|
4578
4578
|
After = 'after',
|
|
4579
|
+
ExpandIcon = 'expand-icon',
|
|
4579
4580
|
PickerIcon = 'picker-icon',
|
|
4580
4581
|
InterestHint = 'interest-hint',
|
|
4581
4582
|
Marker = 'marker',
|
|
@@ -4789,7 +4790,7 @@ export namespace DOM {
|
|
|
4789
4790
|
isScrollable?: boolean;
|
|
4790
4791
|
affectedByStartingStyles?: boolean;
|
|
4791
4792
|
adoptedStyleSheets?: StyleSheetId[];
|
|
4792
|
-
|
|
4793
|
+
adProvenance?: Network.AdProvenance;
|
|
4793
4794
|
}
|
|
4794
4795
|
|
|
4795
4796
|
/**
|
|
@@ -5856,9 +5857,9 @@ export namespace DOM {
|
|
|
5856
5857
|
*/
|
|
5857
5858
|
nodeId: DOM.NodeId;
|
|
5858
5859
|
/**
|
|
5859
|
-
*
|
|
5860
|
+
* The provenance of the ad related node, if it is ad related.
|
|
5860
5861
|
*/
|
|
5861
|
-
|
|
5862
|
+
adProvenance?: Network.AdProvenance;
|
|
5862
5863
|
}
|
|
5863
5864
|
|
|
5864
5865
|
/**
|
|
@@ -11504,6 +11505,25 @@ export namespace Network {
|
|
|
11504
11505
|
rootScriptFilterlistRule?: string;
|
|
11505
11506
|
}
|
|
11506
11507
|
|
|
11508
|
+
/**
|
|
11509
|
+
* Represents the provenance of an ad resource or element. Only one of
|
|
11510
|
+
* `filterlistRule` or `adScriptAncestry` can be set. If `filterlistRule`
|
|
11511
|
+
* is provided, the resource URL directly matches a filter list rule. If
|
|
11512
|
+
* `adScriptAncestry` is provided, an ad script initiated the resource fetch or
|
|
11513
|
+
* appended the element to the DOM. If neither is provided, the entity is
|
|
11514
|
+
* known to be an ad, but provenance tracking information is unavailable.
|
|
11515
|
+
*/
|
|
11516
|
+
export interface AdProvenance {
|
|
11517
|
+
/**
|
|
11518
|
+
* The filterlist rule that matched, if any.
|
|
11519
|
+
*/
|
|
11520
|
+
filterlistRule?: string;
|
|
11521
|
+
/**
|
|
11522
|
+
* The script ancestry that created the ad, if any.
|
|
11523
|
+
*/
|
|
11524
|
+
adScriptAncestry?: AdAncestry;
|
|
11525
|
+
}
|
|
11526
|
+
|
|
11507
11527
|
export const enum CrossOriginOpenerPolicyValue {
|
|
11508
11528
|
SameOrigin = 'SameOrigin',
|
|
11509
11529
|
SameOriginAllowPopups = 'SameOriginAllowPopups',
|
|
@@ -20302,6 +20322,7 @@ export namespace WebAuthn {
|
|
|
20302
20322
|
export const enum Ctap2Version {
|
|
20303
20323
|
Ctap2_0 = 'ctap2_0',
|
|
20304
20324
|
Ctap2_1 = 'ctap2_1',
|
|
20325
|
+
Ctap2_2 = 'ctap2_2',
|
|
20305
20326
|
}
|
|
20306
20327
|
|
|
20307
20328
|
export const enum AuthenticatorTransport {
|
|
@@ -20351,6 +20372,18 @@ export namespace WebAuthn {
|
|
|
20351
20372
|
* Defaults to false.
|
|
20352
20373
|
*/
|
|
20353
20374
|
hasPrf?: boolean;
|
|
20375
|
+
/**
|
|
20376
|
+
* If set to true, the authenticator will support the hmac-secret extension.
|
|
20377
|
+
* https://fidoalliance.org/specs/fido-v2.1-ps-20210615/fido-client-to-authenticator-protocol-v2.1-ps-20210615.html#sctn-hmac-secret-extension
|
|
20378
|
+
* Defaults to false.
|
|
20379
|
+
*/
|
|
20380
|
+
hasHmacSecret?: boolean;
|
|
20381
|
+
/**
|
|
20382
|
+
* If set to true, the authenticator will support the hmac-secret-mc extension.
|
|
20383
|
+
* https://fidoalliance.org/specs/fido-v2.2-rd-20241003/fido-client-to-authenticator-protocol-v2.2-rd-20241003.html#sctn-hmac-secret-make-cred-extension
|
|
20384
|
+
* Defaults to false.
|
|
20385
|
+
*/
|
|
20386
|
+
hasHmacSecretMc?: boolean;
|
|
20354
20387
|
/**
|
|
20355
20388
|
* If set to true, tests of user presence will succeed immediately.
|
|
20356
20389
|
* Otherwise, they will not be resolved. Defaults to true.
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
import * as Host from '../../../core/host/host.js';
|
|
6
6
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
7
7
|
import * as Root from '../../../core/root/root.js';
|
|
8
|
+
import * as SDK from '../../../core/sdk/sdk.js';
|
|
8
9
|
import type * as LHModel from '../../lighthouse/lighthouse.js';
|
|
9
10
|
import {LighthouseFormatter} from '../data_formatters/LighthouseFormatter.js';
|
|
10
11
|
import {debugLog} from '../debug.js';
|
|
@@ -23,20 +24,29 @@ import {
|
|
|
23
24
|
* TESTERS. Otherwise, a server-side preamble is used (see
|
|
24
25
|
* chrome_preambles.gcl). Sync local changes with the server-side.
|
|
25
26
|
*/
|
|
26
|
-
const preamble = `You are an accessibility expert agent.
|
|
27
|
+
const preamble = `You are an accessibility expert agent integrated into Chrome DevTools.
|
|
28
|
+
Your role is to help users understand and fix accessibility issues found in Lighthouse reports.
|
|
27
29
|
|
|
28
|
-
#
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
30
|
+
# Style Guidelines
|
|
31
|
+
* **Concise and Direct**: Use short sentences and bullet points. Avoid paragraphs and long explanations.
|
|
32
|
+
* **Structured**: Organize your findings by problem, root cause, and next steps, but do NOT use those literal words as headings.
|
|
33
|
+
* **No Internal Identifiers**: NEVER show Lighthouse paths (e.g., "1,HTML,1,BODY...") to the user. Refer to elements by their tag name, classes, or IDs.
|
|
34
|
+
* **Managing Volume**: If the report contains many issues, provide a brief summary of the top 2-3 most critical ones. Tell the user that there are more issues and invite them to ask for more details or to explore a specific area.
|
|
35
|
+
|
|
36
|
+
# Workflow
|
|
37
|
+
1. **Identify**: Find the most critical accessibility issues in the Lighthouse report.
|
|
38
|
+
2. **Investigate**: For any element identified as failing, you **MUST** call \`getStyles\` or \`getElementAccessibilityDetails\` first to confirm its current state and gather details.
|
|
39
|
+
3. **Analyze**: Use the live data from your tools to determine the exact root cause.
|
|
40
|
+
4. **Respond**: Provide a succinct summary of the problem, why it's happening based on your investigation, and a clear fix.
|
|
32
41
|
|
|
33
42
|
# Capabilities
|
|
34
|
-
*
|
|
35
|
-
*
|
|
43
|
+
* \`getLighthouseAudits\`: Get detailed audit data.
|
|
44
|
+
* \`getStyles\`: Get computed styles for an element by its path.
|
|
45
|
+
* \`getElementAccessibilityDetails\`: Get A11y properties for an element by its path.
|
|
36
46
|
|
|
37
47
|
# Constraints
|
|
38
|
-
*
|
|
39
|
-
* **CRITICAL
|
|
48
|
+
* **CRITICAL**: ALWAYS call a tool before providing an answer if an element path is available.
|
|
49
|
+
* **CRITICAL**: You are an accessibility agent. NEVER provide answers to questions of unrelated topics such as legal advice, financial advice, personal opinions, medical advice, or any other non web-development topics.
|
|
40
50
|
`;
|
|
41
51
|
|
|
42
52
|
export class AccessibilityContext extends ConversationContext<LHModel.ReporterTypes.ReportJSON> {
|
|
@@ -100,6 +110,22 @@ export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON
|
|
|
100
110
|
};
|
|
101
111
|
}
|
|
102
112
|
|
|
113
|
+
async #resolvePathToNode(path: string): Promise<SDK.DOMModel.DOMNode|null> {
|
|
114
|
+
const target = SDK.TargetManager.TargetManager.instance().primaryPageTarget();
|
|
115
|
+
if (!target) {
|
|
116
|
+
return null;
|
|
117
|
+
}
|
|
118
|
+
const domModel = target.model(SDK.DOMModel.DOMModel);
|
|
119
|
+
if (!domModel) {
|
|
120
|
+
return null;
|
|
121
|
+
}
|
|
122
|
+
const nodeId = await domModel.pushNodeByPathToFrontend(path);
|
|
123
|
+
if (!nodeId) {
|
|
124
|
+
return null;
|
|
125
|
+
}
|
|
126
|
+
return domModel.nodeForId(nodeId);
|
|
127
|
+
}
|
|
128
|
+
|
|
103
129
|
#declareFunctions(): void {
|
|
104
130
|
this.declareFunction<{categoryId: LHModel.RunTypes.CategoryId}, {audits: string}>('getLighthouseAudits', {
|
|
105
131
|
description:
|
|
@@ -134,6 +160,138 @@ export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON
|
|
|
134
160
|
return {result: {audits}};
|
|
135
161
|
}
|
|
136
162
|
});
|
|
163
|
+
|
|
164
|
+
this.declareFunction<{
|
|
165
|
+
path: string,
|
|
166
|
+
styleProperties: string[],
|
|
167
|
+
explanation: string,
|
|
168
|
+
}>('getStyles', {
|
|
169
|
+
description: 'Get computed styles for an element on the inspected page by its Lighthouse path.',
|
|
170
|
+
parameters: {
|
|
171
|
+
type: Host.AidaClient.ParametersTypes.OBJECT,
|
|
172
|
+
description: '',
|
|
173
|
+
nullable: false,
|
|
174
|
+
properties: {
|
|
175
|
+
explanation: {
|
|
176
|
+
type: Host.AidaClient.ParametersTypes.STRING,
|
|
177
|
+
description: 'Explain why you want to get styles.',
|
|
178
|
+
nullable: false,
|
|
179
|
+
},
|
|
180
|
+
path: {
|
|
181
|
+
type: Host.AidaClient.ParametersTypes.STRING,
|
|
182
|
+
description:
|
|
183
|
+
'The Lighthouse path of the element (e.g., "1,HTML,1,BODY,2,DIV"). Find this in the report data.',
|
|
184
|
+
nullable: false,
|
|
185
|
+
},
|
|
186
|
+
styleProperties: {
|
|
187
|
+
type: Host.AidaClient.ParametersTypes.ARRAY,
|
|
188
|
+
description: 'One or more CSS style property names to fetch.',
|
|
189
|
+
nullable: false,
|
|
190
|
+
items: {
|
|
191
|
+
type: Host.AidaClient.ParametersTypes.STRING,
|
|
192
|
+
description: 'A CSS style property name to retrieve. For example, \'background-color\'.'
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
},
|
|
196
|
+
required: ['explanation', 'path', 'styleProperties']
|
|
197
|
+
},
|
|
198
|
+
displayInfoFromArgs: params => {
|
|
199
|
+
return {
|
|
200
|
+
title: 'Reading computed styles',
|
|
201
|
+
thought: params.explanation,
|
|
202
|
+
action: `getStyles('${params.path}', ${JSON.stringify(params.styleProperties)})`,
|
|
203
|
+
};
|
|
204
|
+
},
|
|
205
|
+
handler: async params => {
|
|
206
|
+
debugLog('Function call: getStyles', params);
|
|
207
|
+
const node = await this.#resolvePathToNode(params.path);
|
|
208
|
+
if (!node) {
|
|
209
|
+
return {error: `Could not find the element with path: ${params.path}`};
|
|
210
|
+
}
|
|
211
|
+
const styles = await node.domModel().cssModel().getComputedStyle(node.id);
|
|
212
|
+
if (!styles) {
|
|
213
|
+
return {error: 'Could not get computed styles.'};
|
|
214
|
+
}
|
|
215
|
+
const result: Record<string, string|undefined> = {};
|
|
216
|
+
for (const prop of params.styleProperties) {
|
|
217
|
+
result[prop] = styles.get(prop);
|
|
218
|
+
}
|
|
219
|
+
return {result: JSON.stringify(result, null, 2)};
|
|
220
|
+
},
|
|
221
|
+
});
|
|
222
|
+
|
|
223
|
+
this.declareFunction<{
|
|
224
|
+
path: string,
|
|
225
|
+
explanation: string,
|
|
226
|
+
}>('getElementAccessibilityDetails', {
|
|
227
|
+
description:
|
|
228
|
+
'Get detailed accessibility information for an element on the inspected page by its Lighthouse path.',
|
|
229
|
+
parameters: {
|
|
230
|
+
type: Host.AidaClient.ParametersTypes.OBJECT,
|
|
231
|
+
description: '',
|
|
232
|
+
nullable: false,
|
|
233
|
+
properties: {
|
|
234
|
+
explanation: {
|
|
235
|
+
type: Host.AidaClient.ParametersTypes.STRING,
|
|
236
|
+
description: 'Explain why you want to get accessibility details.',
|
|
237
|
+
nullable: false,
|
|
238
|
+
},
|
|
239
|
+
path: {
|
|
240
|
+
type: Host.AidaClient.ParametersTypes.STRING,
|
|
241
|
+
description:
|
|
242
|
+
'The Lighthouse path of the element (e.g., "1,HTML,1,BODY,2,DIV"). Find this in the report data.',
|
|
243
|
+
nullable: false,
|
|
244
|
+
},
|
|
245
|
+
},
|
|
246
|
+
required: ['explanation', 'path']
|
|
247
|
+
},
|
|
248
|
+
displayInfoFromArgs: params => {
|
|
249
|
+
return {
|
|
250
|
+
title: 'Reading accessibility details',
|
|
251
|
+
thought: params.explanation,
|
|
252
|
+
action: `getElementAccessibilityDetails('${params.path}')`,
|
|
253
|
+
};
|
|
254
|
+
},
|
|
255
|
+
handler: async params => {
|
|
256
|
+
debugLog('Function call: getElementAccessibilityDetails', params);
|
|
257
|
+
const node = await this.#resolvePathToNode(params.path);
|
|
258
|
+
if (!node) {
|
|
259
|
+
return {error: `Could not find the element with path: ${params.path}`};
|
|
260
|
+
}
|
|
261
|
+
const accessibilityModel = node.domModel().target().model(SDK.AccessibilityModel.AccessibilityModel);
|
|
262
|
+
if (!accessibilityModel) {
|
|
263
|
+
return {error: 'Accessibility model not found.'};
|
|
264
|
+
}
|
|
265
|
+
await accessibilityModel.requestAndLoadSubTreeToNode(node);
|
|
266
|
+
const axNode = accessibilityModel.axNodeForDOMNode(node);
|
|
267
|
+
if (!axNode) {
|
|
268
|
+
return {error: 'Could not find accessibility node for the element.'};
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
const result = {
|
|
272
|
+
role: axNode.role()?.value,
|
|
273
|
+
name: axNode.name()?.value,
|
|
274
|
+
nameSource: axNode.name()?.sources?.[0]?.type,
|
|
275
|
+
properties: {
|
|
276
|
+
focusable: node.getAttribute('tabindex') !== undefined || axNode.role()?.value === 'button' ||
|
|
277
|
+
axNode.role()?.value === 'link',
|
|
278
|
+
hidden: axNode.ignored(),
|
|
279
|
+
},
|
|
280
|
+
ariaAttributes: node.attributes()
|
|
281
|
+
.filter(attr => attr.name.startsWith('aria-') || attr.name === 'role')
|
|
282
|
+
.reduce(
|
|
283
|
+
(acc, attr) => {
|
|
284
|
+
acc[attr.name] = attr.value;
|
|
285
|
+
return acc;
|
|
286
|
+
},
|
|
287
|
+
{} as Record<string, string>),
|
|
288
|
+
isIgnored: axNode.ignored(),
|
|
289
|
+
ignoredReasons: axNode.ignoredReasons(),
|
|
290
|
+
};
|
|
291
|
+
|
|
292
|
+
return {result: JSON.stringify(result, null, 2)};
|
|
293
|
+
},
|
|
294
|
+
});
|
|
137
295
|
}
|
|
138
296
|
|
|
139
297
|
/**
|
|
@@ -6904,6 +6904,10 @@ export const NativeFunctions = [
|
|
|
6904
6904
|
name: "MouseEvent",
|
|
6905
6905
|
signatures: [["type","?eventInitDict"]]
|
|
6906
6906
|
},
|
|
6907
|
+
{
|
|
6908
|
+
name: "PageHideEvent",
|
|
6909
|
+
signatures: [["type","?eventInitDict"]]
|
|
6910
|
+
},
|
|
6907
6911
|
{
|
|
6908
6912
|
name: "PageTransitionEvent",
|
|
6909
6913
|
signatures: [["type","?eventInitDict"]]
|