chrome-devtools-frontend 1.0.1690531 → 1.0.1696904

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.
Files changed (356) hide show
  1. package/.agents/skills/devtools-model-management/SKILL.md +3 -3
  2. package/.agents/skills/foundation-test-migration/SKILL.md +2 -2
  3. package/.agents/skills/merging-devtools-module/SKILL.md +5 -5
  4. package/.gitmodules +0 -4
  5. package/AUTHORS +3 -0
  6. package/config/typescript/tsconfig.base.json +1 -0
  7. package/docs/get_the_code.md +4 -9
  8. package/front_end/Images/src/comment-mode-cursor.svg +23 -0
  9. package/front_end/Tests.js +1 -1
  10. package/front_end/application_tokens.css +5 -0
  11. package/front_end/core/common/ColorConverter.ts +3 -3
  12. package/front_end/core/host/UserMetrics.ts +27 -0
  13. package/front_end/core/platform/Size.ts +43 -0
  14. package/front_end/core/platform/platform.ts +1 -0
  15. package/front_end/core/protocol_client/DevToolsCDPConnection.ts +0 -46
  16. package/front_end/core/protocol_client/InspectorBackend.ts +6 -6
  17. package/front_end/core/sdk/AccessibilityModel.ts +2 -2
  18. package/front_end/core/sdk/CSSLocation.ts +32 -0
  19. package/front_end/core/sdk/CSSMatchedStyles.ts +2 -0
  20. package/front_end/core/sdk/CSSModel.ts +2 -22
  21. package/front_end/core/sdk/CSSPropertyParserMatchers.ts +29 -0
  22. package/front_end/core/sdk/CSSQuery.ts +2 -1
  23. package/front_end/core/sdk/CSSRule.ts +29 -0
  24. package/front_end/core/sdk/DOMModel.ts +10 -6
  25. package/front_end/core/sdk/DebuggerModel.ts +5 -1
  26. package/front_end/core/sdk/NetworkManager.ts +2 -0
  27. package/front_end/core/sdk/NetworkRequest.ts +14 -1
  28. package/front_end/core/sdk/NetworkRequestAccess.ts +41 -22
  29. package/front_end/core/sdk/ResourceTreeModel.ts +72 -23
  30. package/front_end/core/sdk/SecurityOrigin.ts +89 -29
  31. package/front_end/core/sdk/Target.ts +18 -0
  32. package/front_end/core/sdk/sdk.ts +2 -0
  33. package/front_end/entrypoints/main/MainImpl.ts +8 -1
  34. package/front_end/foundation/Universe.ts +14 -11
  35. package/front_end/generated/Deprecation.ts +8 -0
  36. package/front_end/generated/InspectorBackendCommands.ts +15 -11
  37. package/front_end/generated/SupportedCSSProperties.ts +13 -3
  38. package/front_end/generated/protocol-mapping.d.ts +7 -0
  39. package/front_end/generated/protocol-proxy-api.d.ts +5 -0
  40. package/front_end/generated/protocol.ts +60 -3
  41. package/front_end/models/ai_assistance/AiAgent2.ts +44 -11
  42. package/front_end/models/ai_assistance/AiConversation.ts +6 -6
  43. package/front_end/models/ai_assistance/README.md +5 -3
  44. package/front_end/models/ai_assistance/agents/AccessibilityAgent.ts +1 -0
  45. package/front_end/models/ai_assistance/agents/AiAgent.ts +32 -34
  46. package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +13 -17
  47. package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +5 -3
  48. package/front_end/models/ai_assistance/agents/StorageAgent.ts +16 -10
  49. package/front_end/models/ai_assistance/agents/StylingAgent.ts +3 -4
  50. package/front_end/models/ai_assistance/ai_assistance.ts +0 -2
  51. package/front_end/models/ai_assistance/contexts/AccessibilityContext.ts +12 -2
  52. package/front_end/models/ai_assistance/contexts/DOMNodeContext.ts +18 -5
  53. package/front_end/models/ai_assistance/contexts/FileContext.ts +14 -6
  54. package/front_end/models/ai_assistance/contexts/PerformanceTraceContext.ts +53 -25
  55. package/front_end/models/ai_assistance/contexts/RequestContext.ts +19 -34
  56. package/front_end/models/ai_assistance/contexts/StorageContext.ts +15 -3
  57. package/front_end/models/ai_assistance/data_formatters/FileFormatter.ts +2 -5
  58. package/front_end/models/ai_assistance/data_formatters/NetworkRequestFormatter.ts +135 -58
  59. package/front_end/models/ai_assistance/tools/CookieUtils.ts +25 -35
  60. package/front_end/models/ai_assistance/tools/DOMStorageUtils.ts +6 -3
  61. package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +9 -2
  62. package/front_end/models/ai_assistance/tools/GetCookieValues.ts +1 -1
  63. package/front_end/models/ai_assistance/tools/GetElementAccessibilityDetails.ts +6 -8
  64. package/front_end/models/ai_assistance/tools/GetFunctionCode.ts +3 -5
  65. package/front_end/models/ai_assistance/tools/GetInsightDetails.ts +1 -1
  66. package/front_end/models/ai_assistance/tools/GetNetworkRequestDetails.ts +11 -18
  67. package/front_end/models/ai_assistance/tools/GetResourceContent.ts +2 -4
  68. package/front_end/models/ai_assistance/tools/GetSourceContent.ts +6 -11
  69. package/front_end/models/ai_assistance/tools/GetStorageBreakdown.ts +1 -1
  70. package/front_end/models/ai_assistance/tools/GetStorageValues.ts +9 -9
  71. package/front_end/models/ai_assistance/tools/GetStyles.ts +11 -6
  72. package/front_end/models/ai_assistance/tools/ListCookies.ts +1 -1
  73. package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +6 -14
  74. package/front_end/models/ai_assistance/tools/ListPageOrigins.ts +10 -15
  75. package/front_end/models/ai_assistance/tools/ListSources.ts +30 -13
  76. package/front_end/models/ai_assistance/tools/ListStorageKeys.ts +9 -9
  77. package/front_end/models/ai_assistance/tools/README.md +4 -2
  78. package/front_end/models/ai_assistance/tools/ResolveDevtoolsNodePath.ts +6 -10
  79. package/front_end/models/ai_assistance/tools/Tool.ts +35 -4
  80. package/front_end/models/comment_manager/CD4ABridge.ts +128 -0
  81. package/front_end/models/comment_manager/CommentManager.ts +77 -11
  82. package/front_end/models/comment_manager/comment_manager.ts +2 -0
  83. package/front_end/models/emulation/DeviceModeModel.ts +48 -59
  84. package/front_end/models/javascript_metadata/NativeFunctions.ts +10 -6
  85. package/front_end/models/live-metrics/web-vitals-injected/README.md +1 -1
  86. package/front_end/models/source_map_scopes/NamesResolver.ts +9 -7
  87. package/front_end/models/trace/ModelImpl.ts +2 -0
  88. package/front_end/models/trace/Processor.ts +6 -4
  89. package/front_end/models/trace/handlers/LayerTreeHandler.ts +3 -3
  90. package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +1 -1
  91. package/front_end/models/trace/helpers/SyntheticEvents.ts +23 -1
  92. package/front_end/models/trace/types/Configuration.ts +7 -0
  93. package/front_end/models/trace/types/TraceEvents.ts +20 -4
  94. package/front_end/panels/accessibility/ARIAAttributesView.ts +3 -0
  95. package/front_end/panels/accessibility/AccessibilityAnnouncementRecordingListView.ts +177 -0
  96. package/front_end/panels/accessibility/accessibility.ts +2 -0
  97. package/front_end/panels/accessibility/accessibilityAnnouncementRecordingListView.css +33 -0
  98. package/front_end/panels/ai_assistance/AiAssistancePanel.ts +98 -32
  99. package/front_end/panels/ai_assistance/components/AIv2MarkdownRenderer.ts +14 -3
  100. package/front_end/panels/ai_assistance/components/ChatMessage.ts +6 -35
  101. package/front_end/panels/ai_assistance/components/DisabledWidget.ts +4 -3
  102. package/front_end/panels/animation/AnimationTimeline.ts +1 -0
  103. package/front_end/panels/animation/AnimationUI.ts +1 -1
  104. package/front_end/panels/application/CookieItemsView.ts +1 -1
  105. package/front_end/panels/application/CrashReportContextView.ts +0 -1
  106. package/front_end/panels/application/FrameDetailsView.ts +5 -4
  107. package/front_end/panels/application/IndexedDBViews.ts +4 -4
  108. package/front_end/panels/application/KeyValueStorageItemsView.ts +1 -1
  109. package/front_end/panels/application/components/AdsView.ts +134 -5
  110. package/front_end/panels/application/components/adScriptsTable.css +22 -0
  111. package/front_end/panels/application/indexedDBViews.css +0 -14
  112. package/front_end/panels/application/resourcesPanel.css +17 -17
  113. package/front_end/panels/common/CPUThrottlingOption.ts +0 -1
  114. package/front_end/panels/common/GdpSignUpDialog.ts +1 -1
  115. package/front_end/panels/common/GeminiRebrandPromoDialog.ts +1 -1
  116. package/front_end/panels/console/ConsoleContextSelector.ts +12 -5
  117. package/front_end/panels/console/ConsoleViewMessage.ts +12 -8
  118. package/front_end/panels/coverage/coverageView.css +8 -8
  119. package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +5 -6
  120. package/front_end/panels/developer_resources/developerResourcesView.css +3 -3
  121. package/front_end/panels/elements/ElementsTreeElement.ts +39 -12
  122. package/front_end/panels/elements/ElementsTreeOutline.ts +184 -108
  123. package/front_end/panels/elements/ShortcutTreeElement.ts +4 -0
  124. package/front_end/panels/elements/StylePropertiesSection.ts +1 -34
  125. package/front_end/panels/elements/StylePropertyTreeElement.ts +83 -0
  126. package/front_end/panels/elements/components/CSSPropertyIconResolver.ts +5 -4
  127. package/front_end/panels/elements/components/StylePropertyEditor.ts +1 -0
  128. package/front_end/panels/elements/components/computedStyleProperty.css +5 -5
  129. package/front_end/panels/elements/components/computedStyleTrace.css +5 -5
  130. package/front_end/panels/elements/components/cssHintDetailsView.css +1 -1
  131. package/front_end/panels/elements/components/cssPropertyDocsView.css +3 -3
  132. package/front_end/panels/elements/components/cssVariableValueView.css +4 -4
  133. package/front_end/panels/elements/components/elementsBreadcrumbs.css +3 -3
  134. package/front_end/panels/elements/components/elementsTreeExpandButton.css +5 -5
  135. package/front_end/panels/elements/components/queryContainer.css +2 -2
  136. package/front_end/panels/elements/elementsTreeOutline.css +20 -4
  137. package/front_end/panels/elements/stylePropertiesTreeOutline.css +2 -1
  138. package/front_end/panels/emulation/DeviceModeView.ts +1 -1
  139. package/front_end/panels/event_listeners/EventListenersView.ts +57 -88
  140. package/front_end/panels/event_listeners/eventListenersView.css +1 -1
  141. package/front_end/panels/issues/AffectedElementsView.ts +3 -0
  142. package/front_end/panels/issues/issues.ts +2 -0
  143. package/front_end/panels/layer_viewer/LayerDetailsView.ts +12 -10
  144. package/front_end/panels/layer_viewer/LayerTreeOutline.ts +1 -0
  145. package/front_end/panels/layer_viewer/Layers3DView.ts +14 -12
  146. package/front_end/panels/layers/LayerTreeModel.ts +1 -1
  147. package/front_end/panels/lighthouse/LighthouseStatusView.ts +1 -1
  148. package/front_end/panels/lighthouse/LighthouseTimespanView.ts +1 -1
  149. package/front_end/panels/linear_memory_inspector/components/LinearMemoryHighlightChipList.ts +1 -1
  150. package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspectorUtils.ts +2 -2
  151. package/front_end/panels/linear_memory_inspector/components/ValueInterpreterDisplayUtils.ts +1 -1
  152. package/front_end/panels/linear_memory_inspector/components/ValueInterpreterSettings.ts +1 -1
  153. package/front_end/panels/linear_memory_inspector/components/linearMemoryHighlightChipList.css +11 -11
  154. package/front_end/panels/media/PlayerPropertiesView.ts +1 -1
  155. package/front_end/panels/media/TickingFlameChart.ts +3 -2
  156. package/front_end/panels/mobile_throttling/CalibrationController.ts +3 -0
  157. package/front_end/panels/mobile_throttling/NetworkThrottlingSelector.ts +2 -1
  158. package/front_end/panels/mobile_throttling/ThrottlingManager.ts +11 -1
  159. package/front_end/panels/mobile_throttling/ThrottlingPresets.ts +2 -1
  160. package/front_end/panels/network/NetworkLogViewColumns.ts +5 -2
  161. package/front_end/panels/network/RequestHeadersView.ts +46 -10
  162. package/front_end/panels/network/components/RequestHeadersView.css +12 -0
  163. package/front_end/panels/performance_monitor/PerformanceMonitor.ts +3 -3
  164. package/front_end/panels/profiler/HeapProfileView.ts +1 -1
  165. package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +1 -1
  166. package/front_end/panels/protocol_monitor/JSONEditor.ts +1 -1
  167. package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +3 -3
  168. package/front_end/panels/recorder/RecordingListView.ts +0 -6
  169. package/front_end/panels/recorder/RecordingView.ts +0 -6
  170. package/front_end/panels/recorder/controlButton.css +10 -10
  171. package/front_end/panels/recorder/startView.css +1 -1
  172. package/front_end/panels/screencast/ScreencastView.ts +4 -2
  173. package/front_end/panels/search/SearchView.ts +1 -1
  174. package/front_end/panels/security/OriginTreeElement.ts +59 -0
  175. package/front_end/panels/security/SecurityPanel.ts +52 -40
  176. package/front_end/panels/security/SecurityPanelSidebar.ts +231 -64
  177. package/front_end/panels/security/SecurityPanelSidebarTreeElement.ts +30 -0
  178. package/front_end/panels/security/security.ts +4 -0
  179. package/front_end/panels/sensors/SensorsView.ts +1 -1
  180. package/front_end/panels/sources/CSSPlugin.ts +1 -1
  181. package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +1 -1
  182. package/front_end/panels/timeline/TimelineFlameChartView.ts +0 -32
  183. package/front_end/panels/timeline/TimelinePaintProfilerView.ts +1 -1
  184. package/front_end/panels/timeline/TimelinePanel.ts +0 -17
  185. package/front_end/panels/timeline/components/cwvMetrics.css +2 -2
  186. package/front_end/panels/timeline/components/insights/checklist.css +1 -1
  187. package/front_end/panels/timeline/components/insights/table.css +3 -3
  188. package/front_end/panels/timeline/overlays/components/entriesLinkOverlay.css +4 -4
  189. package/front_end/panels/timeline/overlays/components/entryLabelOverlay.css +4 -4
  190. package/front_end/panels/timeline/overlays/components/timeRangeOverlay.css +2 -2
  191. package/front_end/panels/timeline/overlays/components/timespanBreakdownOverlay.css +4 -4
  192. package/front_end/panels/timeline/timelineMiniMap.css +9 -9
  193. package/front_end/panels/timeline/timelinePanel.css +0 -74
  194. package/front_end/panels/timeline/timelineStatusDialog.css +9 -9
  195. package/front_end/panels/web_audio/webAudio.css +5 -5
  196. package/front_end/third_party/chromium/README.chromium +1 -1
  197. package/front_end/third_party/csp_evaluator/package/tsconfig.json +1 -0
  198. package/front_end/third_party/diff/DiffWrapper.ts +1 -8
  199. package/front_end/third_party/puppeteer/README.chromium +2 -2
  200. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +183 -4
  201. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +708 -122
  202. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts +85 -3
  203. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts.map +1 -1
  204. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.js +84 -11
  205. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.js.map +1 -1
  206. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.d.ts +75 -0
  207. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.d.ts.map +1 -0
  208. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.js +102 -0
  209. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.js.map +1 -0
  210. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.d.ts +1 -0
  211. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.d.ts.map +1 -1
  212. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.js +1 -0
  213. package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.js.map +1 -1
  214. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.d.ts +6 -1
  215. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.d.ts.map +1 -1
  216. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.js +7 -0
  217. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.js.map +1 -1
  218. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.d.ts +31 -0
  219. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.d.ts.map +1 -0
  220. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.js +138 -0
  221. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.js.map +1 -0
  222. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.d.ts +1 -0
  223. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.d.ts.map +1 -1
  224. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.js +1 -0
  225. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.js.map +1 -1
  226. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.d.ts +6 -0
  227. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
  228. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.js +23 -0
  229. package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
  230. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.d.ts +6 -1
  231. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.d.ts.map +1 -1
  232. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.js +7 -0
  233. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.js.map +1 -1
  234. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.d.ts +31 -0
  235. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.d.ts.map +1 -0
  236. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.js +131 -0
  237. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.js.map +1 -0
  238. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.d.ts +1 -0
  239. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.d.ts.map +1 -1
  240. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.js +1 -0
  241. package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.js.map +1 -1
  242. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js +7 -4
  243. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js.map +1 -1
  244. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.d.ts +4 -1
  245. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.d.ts.map +1 -1
  246. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.js +5 -1
  247. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.js.map +1 -1
  248. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/ConnectOptions.d.ts +42 -0
  249. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/ConnectOptions.d.ts.map +1 -1
  250. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.d.ts +2 -2
  251. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.d.ts.map +1 -1
  252. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.js +265 -1
  253. package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.js.map +1 -1
  254. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.d.ts +4 -0
  255. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  256. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.js +24 -3
  257. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.js.map +1 -1
  258. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.d.ts +23 -2
  259. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.d.ts.map +1 -1
  260. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.js +49 -3
  261. package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.js.map +1 -1
  262. package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.d.ts +3 -3
  263. package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.js +3 -3
  264. package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.d.ts +1 -1
  265. package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.d.ts.map +1 -1
  266. package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js +1 -1
  267. package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js.map +1 -1
  268. package/front_end/third_party/puppeteer/package/lib/types.d.ts +183 -4
  269. package/front_end/third_party/puppeteer/package/package.json +4 -4
  270. package/front_end/third_party/puppeteer/package/src/api/Page.ts +143 -11
  271. package/front_end/third_party/puppeteer/package/src/api/ScreenRecording.ts +145 -0
  272. package/front_end/third_party/puppeteer/package/src/api/api.ts +1 -0
  273. package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +11 -0
  274. package/front_end/third_party/puppeteer/package/src/bidi/ScreenRecording.ts +106 -0
  275. package/front_end/third_party/puppeteer/package/src/bidi/bidi.ts +1 -0
  276. package/front_end/third_party/puppeteer/package/src/bidi/core/BrowsingContext.ts +41 -0
  277. package/front_end/third_party/puppeteer/package/src/cdp/Page.ts +11 -0
  278. package/front_end/third_party/puppeteer/package/src/cdp/ScreenRecording.ts +101 -0
  279. package/front_end/third_party/puppeteer/package/src/cdp/cdp.ts +1 -0
  280. package/front_end/third_party/puppeteer/package/src/common/BrowserConnector.ts +17 -9
  281. package/front_end/third_party/puppeteer/package/src/common/BrowserWebSocketTransport.ts +4 -0
  282. package/front_end/third_party/puppeteer/package/src/common/ConnectOptions.ts +46 -0
  283. package/front_end/third_party/puppeteer/package/src/common/Device.ts +287 -1
  284. package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +30 -1
  285. package/front_end/third_party/puppeteer/package/src/node/NodeWebSocketTransport.ts +73 -2
  286. package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
  287. package/front_end/third_party/puppeteer/package/src/util/version.ts +1 -1
  288. package/front_end/third_party/puppeteer/puppeteer-tsconfig.json +194 -0
  289. package/front_end/tsconfig.json +1 -2
  290. package/front_end/ui/comments/CommentAnchorResolver.ts +122 -6
  291. package/front_end/ui/comments/CommentOverlayManager.ts +147 -27
  292. package/front_end/ui/comments/CommentsOverlayWidget.ts +3 -3
  293. package/front_end/ui/comments/CommentsStatusBarPill.ts +96 -0
  294. package/front_end/ui/comments/comments-meta.ts +21 -0
  295. package/front_end/ui/comments/comments.ts +2 -0
  296. package/front_end/ui/comments/commentsOverlay.css +22 -3
  297. package/front_end/ui/components/dialogs/TypeToAllowDialog.ts +1 -1
  298. package/front_end/ui/components/markdown_view/MarkdownView.ts +31 -1
  299. package/front_end/ui/components/markdown_view/codeBlock.css +3 -8
  300. package/front_end/ui/components/markdown_view/markdownView.css +2 -7
  301. package/front_end/{models → ui}/geometry/GeometryImpl.ts +4 -40
  302. package/front_end/ui/kit/icons/Icon.ts +0 -1
  303. package/front_end/ui/kit/link/Link.ts +8 -1
  304. package/front_end/ui/legacy/GlassPane.ts +1 -1
  305. package/front_end/ui/legacy/InspectorView.ts +17 -1
  306. package/front_end/ui/legacy/SoftDropDown.ts +1 -1
  307. package/front_end/ui/legacy/SplitWidget.ts +17 -3
  308. package/front_end/ui/legacy/StatusBar.ts +78 -0
  309. package/front_end/ui/legacy/SuggestBox.ts +1 -1
  310. package/front_end/ui/legacy/TabbedPane.ts +1 -1
  311. package/front_end/ui/legacy/Toolbar.ts +4 -0
  312. package/front_end/ui/legacy/Treeoutline.ts +82 -11
  313. package/front_end/ui/legacy/UIUtils.ts +3 -2
  314. package/front_end/ui/legacy/ViewRegistration.ts +1 -0
  315. package/front_end/ui/legacy/Widget.ts +1 -1
  316. package/front_end/ui/legacy/components/data_grid/dataGrid.css +23 -23
  317. package/front_end/ui/legacy/components/inline_editor/AnimationTimingModel.ts +1 -1
  318. package/front_end/ui/legacy/components/inline_editor/AnimationTimingUI.ts +1 -1
  319. package/front_end/ui/legacy/components/inline_editor/BezierUI.ts +1 -1
  320. package/front_end/ui/legacy/components/inline_editor/CSSAngleUtils.ts +1 -1
  321. package/front_end/ui/legacy/components/inline_editor/CSSShadowEditor.ts +1 -1
  322. package/front_end/ui/legacy/components/inline_editor/PositionAreaEditor.docs.ts +83 -0
  323. package/front_end/ui/legacy/components/inline_editor/PositionAreaEditor.ts +787 -0
  324. package/front_end/ui/legacy/components/inline_editor/animationNameSwatch.css +1 -1
  325. package/front_end/ui/legacy/components/inline_editor/colorMixSwatch.css +4 -4
  326. package/front_end/ui/legacy/components/inline_editor/cssAngleSwatch.css +3 -3
  327. package/front_end/ui/legacy/components/inline_editor/inline_editor.ts +2 -0
  328. package/front_end/ui/legacy/components/inline_editor/linkSwatch.css +1 -1
  329. package/front_end/ui/legacy/components/inline_editor/positionAreaEditor.css +160 -0
  330. package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +113 -51
  331. package/front_end/ui/legacy/components/object_ui/ObjectPopoverHelper.ts +11 -8
  332. package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +16 -97
  333. package/front_end/ui/legacy/components/object_ui/customPreviewComponent.css +7 -3
  334. package/front_end/ui/legacy/components/object_ui/objectPropertiesSection.css +1 -1
  335. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +0 -66
  336. package/front_end/ui/legacy/components/perf_ui/perf_ui.ts +0 -2
  337. package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +1 -1
  338. package/front_end/ui/legacy/inspectorCommon.css +30 -6
  339. package/front_end/ui/legacy/legacy.ts +2 -0
  340. package/front_end/ui/legacy/statusBar.css +18 -0
  341. package/front_end/ui/visual_logging/KnownContextValues.ts +14 -0
  342. package/inspector_overlay/main.ts +8 -8
  343. package/mcp/mcp.ts +5 -0
  344. package/package.json +2 -9
  345. package/front_end/Images/generate-css-vars.js +0 -52
  346. package/front_end/Images/rollup.config.mjs +0 -36
  347. package/front_end/models/ai_assistance/AiOrigins.ts +0 -107
  348. package/front_end/models/live-metrics/web-vitals-injected/rollup.config.mjs +0 -20
  349. package/front_end/panels/recorder/injected/rollup.config.mjs +0 -20
  350. package/front_end/panels/timeline/EasterEgg.d.ts +0 -6
  351. package/front_end/panels/timeline/easter-egg-tsconfig.json +0 -8
  352. package/front_end/panels/timeline/enable-easter-egg.js +0 -20
  353. package/front_end/third_party/puppeteer-replay/puppeteer-replay-tsconfig.json +0 -8
  354. package/front_end/ui/legacy/components/perf_ui/BrickBreaker.ts +0 -606
  355. package/inspector_overlay/loadCSS.rollup.js +0 -29
  356. /package/front_end/{models → ui}/geometry/geometry.ts +0 -0
@@ -22,12 +22,12 @@ This guide outlines the standard procedure for creating a new model or migrating
22
22
  ## 2. Build Configuration (`BUILD.gn`)
23
23
  Every model requires a `BUILD.gn` file in its directory with three specific targets:
24
24
 
25
- 1. **`devtools_module("<model_name>")`**: Lists implementation source files (`sources`) and dependencies (`deps`).
25
+ 1. **`devtools_module("<model_name>")`**: Lists implementation source files (`sources`) and TypeScript dependencies (`ts_deps`). Non-TypeScript dependencies (e.g. CSS, assets) go into `deps`.
26
26
  * **Crucial:** Do NOT include the barrel file (`<model_name>.ts`) in `sources`.
27
27
  2. **`devtools_entrypoint("bundle")`**: Defines the barrel file (`entrypoint = "<model_name>.ts"`).
28
- * **Crucial:** Must depend on the module target: `deps = [ ":<model_name>" ]`.
28
+ * **Crucial:** Must depend on the module target: `ts_deps = [ ":<model_name>" ]`.
29
29
  3. **`ts_library("unittests")`**: Lists test files and test-only dependencies.
30
- * **Crucial:** Must depend on the bundle: `deps = [ ":bundle" ]`.
30
+ * **Crucial:** Must depend on the bundle: `ts_deps = [ ":bundle" ]`.
31
31
 
32
32
  ## 3. Global Registration (Crucial)
33
33
  The build system does not auto-detect new modules. You must manually register them in **`config/gni/devtools_grd_files.gni`**:
@@ -143,13 +143,13 @@ When a module and its tests are ready, update `BUILD.gn`:
143
143
 
144
144
  devtools_foundation_module("my_module") {
145
145
  sources = [ "MyModule.ts" ]
146
- deps = [ "../../core/common:bundle" ]
146
+ ts_deps = [ "../../core/common:bundle" ]
147
147
  }
148
148
 
149
149
  devtools_foundation_module("unittests") {
150
150
  testonly = true
151
151
  sources = [ "MyModule.test.ts" ]
152
- deps = [
152
+ ts_deps = [
153
153
  ":my_module",
154
154
  "../../testing",
155
155
  ]
@@ -19,7 +19,7 @@ You will need the following information:
19
19
 
20
20
  Read the contents of the `BUILD.gn` file from both the child module and the parent module. Identify the following from the child's `BUILD.gn`:
21
21
  - The list of `sources` in the `devtools_module`.
22
- - The list of `deps` (dependencies) in the `devtools_module`.
22
+ - The list of `ts_deps` (and non-TypeScript `deps`) in the `devtools_module`.
23
23
  - The `entrypoint` for the `devtools_entrypoint("bundle")`.
24
24
 
25
25
  ### 2. Modify the Parent `BUILD.gn`
@@ -27,8 +27,8 @@ Read the contents of the `BUILD.gn` file from both the child module and the pare
27
27
  Edit the `BUILD.gn` file in the parent module's directory to incorporate the child module's configuration.
28
28
 
29
29
  1. **Add Child's Sources:** Append the list of `sources` from the child's `devtools_module` to the parent's `sources` list. Remember to maintain the relative path from the parent's directory (e.g., `extensions/ExtensionUI.ts`).
30
- 2. **Merge Dependencies:** Add the `deps` from the child's `devtools_module` to the parent's `deps` list. Remove any duplicate entries.
31
- 3. **Remove Child Bundle Dependency:** Delete the dependency on the child's bundle from the parent's `deps` list (e.g., remove `./extensions:bundle`).
30
+ 2. **Merge Dependencies:** Add the `ts_deps` from the child's `devtools_module` to the parent's `ts_deps` list (and merge any non-TypeScript `deps`). Remove any duplicate entries.
31
+ 3. **Remove Child Bundle Dependency:** Delete the dependency on the child's bundle from the parent's `ts_deps` list (e.g., remove `./extensions:bundle`).
32
32
 
33
33
  ### 3. Delete the Child `BUILD.gn`
34
34
 
@@ -63,7 +63,7 @@ devtools_module("timeline") {
63
63
  "UIDevtoolsUtils.ts",
64
64
  ]
65
65
 
66
- deps = [
66
+ ts_deps = [
67
67
  ...
68
68
  "./components:bundle",
69
69
  "./extensions:bundle",
@@ -82,7 +82,7 @@ devtools_module("timeline") {
82
82
  "extensions/ExtensionUI.ts", # Added from child
83
83
  ]
84
84
 
85
- deps = [
85
+ ts_deps = [
86
86
  ...
87
87
  "./components:bundle",
88
88
  # "./extensions:bundle", # Removed
package/.gitmodules CHANGED
@@ -1,7 +1,3 @@
1
- [submodule "test/ai_evals/eval_data"]
2
- path = test/ai_evals/eval_data
3
- url = https://chrome-internal.googlesource.com/devtools/chrome-devtools-evals
4
- gclient-condition = checkout_ai_evals == True
5
1
  [submodule "third_party/clang-format/script"]
6
2
  path = third_party/clang-format/script
7
3
  url = https://chromium.googlesource.com/external/github.com/llvm/llvm-project/clang/tools/clang-format
package/AUTHORS CHANGED
@@ -35,6 +35,7 @@ Conner Turner <cturner@zyme.xyz>
35
35
  Daniel bellfield <dnlbellfield@gmail.com>
36
36
  Danny Eldridge <me@heardanieljames.com>
37
37
  Derek Li <the.derekli@gmail.com>
38
+ Dmitry Kryaklin <dmkryak@gmail.com>
38
39
  Douglas Chiang <douglasdothnc@gmail.com>
39
40
  Dragonish <no.web.developer@outlook.com>
40
41
  Eden Wang <nedenwang@gmail.com>
@@ -79,6 +80,7 @@ Michael Rienstra <mrienstra@gmail.com>
79
80
  Mostafa Aboalkasim <mostafa.aboalkasim.offical@gmail.com>
80
81
  Muhammad Mahad <mahadtxt@gmail.com>
81
82
  Naoto Ono <onoto1998@gmail.com>
83
+ Navoda Munasinha <navoda.munasinha@codimite.com>
82
84
  Nourhan Hasan <nourhan.m.hasan@gmail.com>
83
85
  Paras Awasthi <awasthiparas6@gmail.com>
84
86
  Paul Fisher <paul@pfish.zone>
@@ -121,6 +123,7 @@ Yoichiro Hibara <hibarayoichiro871@gmail.com>
121
123
  Yoni Feigelson <yfeigelson@gmail.com>
122
124
  Young Min Kim <y@ylem.kim>
123
125
  Yuan Zhuang <joann.yuanzhuang@gmail.com>
126
+ Zuyao Chen <zuyaocat@gmail.com>
124
127
  # Please DO NOT APPEND here. See comments at the top of the file.
125
128
  # END individuals section.
126
129
 
@@ -23,6 +23,7 @@
23
23
  "preserveConstEnums": true,
24
24
  "composite": true,
25
25
  "declaration": true,
26
+ "isolatedDeclarations": true,
26
27
 
27
28
  "sourceMap": true,
28
29
  "inlineSources": true
@@ -43,17 +43,12 @@ npm run build -- -t Debug
43
43
  will build in `out/Debug` instead of `out/Default`. If the directory doesn't exist,
44
44
  it'll automatically create and initialize it.
45
45
 
46
- You can disable type checking (via TypeScript) by using the `devtools_skip_typecheck`
47
- argument in your GN configuration. This uses [esbuild](https://esbuild.github.io/)
48
- instead of `tsc` to compile the TypeScript files and generally results in much
49
- shorter build times.
50
-
51
- Additionally, we now bundle files together by default in all builds, which has
52
- a build time cost. If you want an even fast fast build, you might want to opt
53
- out of bundling by setting `devtools_bundle` to `false`
46
+ We bundle files together by default in all builds, which has a build time cost.
47
+ If you want a faster build, you can opt out of bundling by setting `devtools_bundle`
48
+ to `false`:
54
49
 
55
50
  ```bash
56
- gn gen out/Fast --args="devtools_skip_typecheck=true devtools_bundle=false"
51
+ gn gen out/Fast --args="devtools_bundle=false"
57
52
  ```
58
53
 
59
54
  and use `npm run build -- -t Fast` to build this target.
@@ -0,0 +1,23 @@
1
+ <svg width="40" height="40" viewBox="0 0 40 40" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <g filter="url(#filter0_dd_6727_40653)">
3
+ <path d="M30 18C30 12.4772 25.5228 8 20 8C14.4772 8 10 12.4772 10 18V27.2308C10 27.6556 10.3444 28 10.7692 28H20C25.5228 28 30 23.5228 30 18Z" fill="white"/>
4
+ <path d="M20 7C13.9249 7 9 11.9249 9 18V27.2305C9 28.2076 9.79241 29 10.7695 29H20C26.0751 29 31 24.0751 31 18C31 11.9249 26.0751 7 20 7Z" stroke="#0B57D0" stroke-width="2"/>
5
+ </g>
6
+ <defs>
7
+ <filter id="filter0_dd_6727_40653" x="0" y="0" width="40" height="40" filterUnits="userSpaceOnUse" color-interpolation-filters="sRGB">
8
+ <feFlood flood-opacity="0" result="BackgroundImageFix"/>
9
+ <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
10
+ <feMorphology radius="2" operator="dilate" in="SourceAlpha" result="effect1_dropShadow_6727_40653"/>
11
+ <feOffset dy="2"/>
12
+ <feGaussianBlur stdDeviation="3"/>
13
+ <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"/>
14
+ <feBlend mode="normal" in2="BackgroundImageFix" result="effect1_dropShadow_6727_40653"/>
15
+ <feColorMatrix in="SourceAlpha" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0" result="hardAlpha"/>
16
+ <feOffset dy="1"/>
17
+ <feGaussianBlur stdDeviation="1"/>
18
+ <feColorMatrix type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.3 0"/>
19
+ <feBlend mode="normal" in2="effect1_dropShadow_6727_40653" result="effect2_dropShadow_6727_40653"/>
20
+ <feBlend mode="normal" in="SourceGraphic" in2="effect2_dropShadow_6727_40653" result="shape"/>
21
+ </filter>
22
+ </defs>
23
+ </svg>
@@ -550,7 +550,7 @@
550
550
  this._waitForTargets(1, callback.bind(this));
551
551
 
552
552
  function callback() {
553
- ProtocolClient.test.deprecatedRunAfterPendingDispatches(this.releaseControl.bind(this));
553
+ setTimeout(this.releaseControl.bind(this), 0);
554
554
  }
555
555
  };
556
556
 
@@ -254,6 +254,11 @@
254
254
  */
255
255
  --combobox-dropdown-arrow: var(--image-file-arrow-drop-down-light);
256
256
 
257
+ /**
258
+ * Comment mode cursor.
259
+ */
260
+ --comment-cursor: var(--image-file-comment-mode-cursor) 10 28, auto;
261
+
257
262
  &.theme-with-dark-background {
258
263
  --color-primary-old: rgb(138 180 248);
259
264
  --color-primary-variant: rgb(102 157 246);
@@ -274,9 +274,9 @@ export class ColorConverter {
274
274
  const xyzInput = new Vector3([x, y, z]);
275
275
  const lmsIntermediate = XYZ_TO_LMS_MATRIX.multiply(xyzInput);
276
276
 
277
- lmsIntermediate.values[0] = Math.pow(lmsIntermediate.values[0], 1.0 / 3.0);
278
- lmsIntermediate.values[1] = Math.pow(lmsIntermediate.values[1], 1.0 / 3.0);
279
- lmsIntermediate.values[2] = Math.pow(lmsIntermediate.values[2], 1.0 / 3.0);
277
+ lmsIntermediate.values[0] = Math.cbrt(lmsIntermediate.values[0]);
278
+ lmsIntermediate.values[1] = Math.cbrt(lmsIntermediate.values[1]);
279
+ lmsIntermediate.values[2] = Math.cbrt(lmsIntermediate.values[2]);
280
280
 
281
281
  const labOutput = LMS_TO_OKLAB_MATRIX.multiply(lmsIntermediate);
282
282
  return [labOutput.values[0], labOutput.values[1], labOutput.values[2]];
@@ -265,6 +265,31 @@ export class UserMetrics {
265
265
  InspectorFrontendHostInstance.recordPerformanceHistogram('DevTools.Insights.ShortTeaserGenerationTime',
266
266
  timeInMilliseconds);
267
267
  }
268
+
269
+ changeRecorded(count: number): void {
270
+ InspectorFrontendHostInstance.recordCountHistogram('DevTools.Comments.ChangeRecorded', count, 1, 100, 50);
271
+ }
272
+
273
+ changeSharedWithAgent(count: number): void {
274
+ InspectorFrontendHostInstance.recordCountHistogram('DevTools.Comments.ChangeSharedWithAgent', count, 1, 100, 50);
275
+ }
276
+
277
+ commentCreated(count: number): void {
278
+ InspectorFrontendHostInstance.recordCountHistogram('DevTools.Comments.CommentCreated', count, 1, 100, 50);
279
+ }
280
+
281
+ commentResolved(resolver: CommentResolver, count: number): void {
282
+ InspectorFrontendHostInstance.recordCountHistogram(`DevTools.Comments.CommentResolvedBy${resolver}`, count, 1, 100,
283
+ 50);
284
+ }
285
+
286
+ commentSharedWithAgent(count: number): void {
287
+ InspectorFrontendHostInstance.recordCountHistogram('DevTools.Comments.CommentSharedWithAgent', count, 1, 100, 50);
288
+ }
289
+
290
+ commentSize(characters: number): void {
291
+ InspectorFrontendHostInstance.recordCountHistogram('DevTools.Comments.CommentSize', characters, 1, 100_000, 50);
292
+ }
268
293
  }
269
294
 
270
295
  /**
@@ -493,3 +518,5 @@ export function resendRequestType(resourceType: Common.ResourceType.ResourceType
493
518
  const key = resendRequestTypeMap.get(resourceType);
494
519
  return (key ? ResendRequestType[key] : undefined) ?? ResendRequestType.OTHER;
495
520
  }
521
+
522
+ export type CommentResolver = 'Agent'|'User';
@@ -0,0 +1,43 @@
1
+ // Copyright 2026 The Chromium Authors
2
+ // Use of this source code is governed by a BSD-style license that can be
3
+ // found in the LICENSE file.
4
+
5
+ export class Size {
6
+ width: number;
7
+ height: number;
8
+ constructor(width: number, height: number) {
9
+ this.width = width;
10
+ this.height = height;
11
+ }
12
+
13
+ clipTo(size?: Size|null): Size {
14
+ if (!size) {
15
+ return this;
16
+ }
17
+ return new Size(Math.min(this.width, size.width), Math.min(this.height, size.height));
18
+ }
19
+
20
+ scale(scale: number): Size {
21
+ return new Size(this.width * scale, this.height * scale);
22
+ }
23
+
24
+ isEqual(size: Size|null): boolean {
25
+ return size !== null && this.width === size.width && this.height === size.height;
26
+ }
27
+
28
+ widthToMax(size: number|Size): Size {
29
+ return new Size(Math.max(this.width, (typeof size === 'number' ? size : size.width)), this.height);
30
+ }
31
+
32
+ addWidth(size: number|Size): Size {
33
+ return new Size(this.width + (typeof size === 'number' ? size : size.width), this.height);
34
+ }
35
+
36
+ heightToMax(size: number|Size): Size {
37
+ return new Size(this.width, Math.max(this.height, (typeof size === 'number' ? size : size.height)));
38
+ }
39
+
40
+ addHeight(size: number|Size): Size {
41
+ return new Size(this.width, this.height + (typeof size === 'number' ? size : size.height));
42
+ }
43
+ }
@@ -19,6 +19,7 @@ import * as TypeScriptUtilities from './TypescriptUtilities.js';
19
19
  import * as UIString from './UIString.js';
20
20
  import * as UserVisibleError from './UserVisibleError.js';
21
21
 
22
+ export {Size} from './Size.js';
22
23
  /* `assertNotNullOrUndefined` also need to be exposed, as TypeScript does
23
24
  * not allow `asserts` functions to be used with qualified access (e.g.
24
25
  * `Platform.TypeScriptUtilities.assertNotNullOrUndefined` causes a compile
@@ -25,21 +25,15 @@ interface CallbackWithDebugInfo {
25
25
 
26
26
  type Callback = (error: MessageError|null, arg1: Object|null) => void;
27
27
 
28
- const LongPollingMethods = new Set<string>(['CSS.takeComputedStyleUpdates']);
29
-
30
28
  export class DevToolsCDPConnection implements CDPConnection {
31
29
  readonly #transport: ConnectionTransport;
32
30
  #lastMessageId = 1;
33
- #pendingResponsesCount = 0;
34
- readonly #pendingLongPollingMessageIds = new Set<number>();
35
- #pendingScripts: Array<() => void> = [];
36
31
  readonly #callbacks = new Map<number, CallbackWithDebugInfo>();
37
32
  readonly #observers = new Set<CDPConnectionObserver>();
38
33
 
39
34
  constructor(transport: ConnectionTransport) {
40
35
  this.#transport = transport;
41
36
 
42
- test.deprecatedRunAfterPendingDispatches = this.deprecatedRunAfterPendingDispatches.bind(this);
43
37
  test.sendRawMessage = this.sendRawMessageForTesting.bind(this);
44
38
 
45
39
  this.#transport.setOnMessage(this.onMessage.bind(this));
@@ -81,11 +75,6 @@ export class DevToolsCDPConnection implements CDPConnection {
81
75
  test.onMessageSent({domain, method, params: (paramsObject as Object), id: messageId, sessionId});
82
76
  }
83
77
 
84
- ++this.#pendingResponsesCount;
85
- if (LongPollingMethods.has(method)) {
86
- this.#pendingLongPollingMessageIds.add(messageId);
87
- }
88
-
89
78
  return new Promise(resolve => {
90
79
  this.#callbacks.set(messageId, {resolve, method, sessionId});
91
80
  this.#transport.sendRawMessage(JSON.stringify(messageObject));
@@ -147,45 +136,10 @@ export class DevToolsCDPConnection implements CDPConnection {
147
136
  }
148
137
 
149
138
  callback.resolve(messageObject);
150
- --this.#pendingResponsesCount;
151
- this.#pendingLongPollingMessageIds.delete(messageObject.id);
152
-
153
- if (this.#pendingScripts.length && !this.hasOutstandingNonLongPollingRequests()) {
154
- this.deprecatedRunAfterPendingDispatches();
155
- }
156
139
  } else if ('method' in messageObject) {
157
140
  this.#observers.forEach(observer => observer.onEvent(messageObject));
158
141
  } else {
159
142
  InspectorBackend.reportProtocolError('Protocol Error: the message without method', messageObject);
160
143
  }
161
144
  }
162
-
163
- private hasOutstandingNonLongPollingRequests(): boolean {
164
- return this.#pendingResponsesCount - this.#pendingLongPollingMessageIds.size > 0;
165
- }
166
-
167
- private deprecatedRunAfterPendingDispatches(script?: (() => void)): void {
168
- if (script) {
169
- this.#pendingScripts.push(script);
170
- }
171
-
172
- // Execute all promises.
173
- setTimeout(() => {
174
- if (!this.hasOutstandingNonLongPollingRequests()) {
175
- this.executeAfterPendingDispatches();
176
- } else {
177
- this.deprecatedRunAfterPendingDispatches();
178
- }
179
- }, 0);
180
- }
181
-
182
- private executeAfterPendingDispatches(): void {
183
- if (!this.hasOutstandingNonLongPollingRequests()) {
184
- const scripts = this.#pendingScripts;
185
- this.#pendingScripts = [];
186
- for (let id = 0; id < scripts.length; ++id) {
187
- scripts[id]();
188
- }
189
- }
190
- }
191
145
  }
@@ -153,12 +153,6 @@ export const test = {
153
153
  */
154
154
  dumpProtocol: null as ((arg0: string) => void) | null,
155
155
 
156
- /**
157
- * Runs a function when no protocol activity is present.
158
- * ProtocolClient.test.deprecatedRunAfterPendingDispatches(() => console.log('done'))
159
- */
160
- deprecatedRunAfterPendingDispatches: null as ((arg0: () => void) => void) | null,
161
-
162
156
  /**
163
157
  * Sends a raw message over main connection.
164
158
  * ProtocolClient.test.sendRawMessage('Page.enable', {}, console.log)
@@ -181,6 +175,12 @@ export const test = {
181
175
  * Set to get notified about any messages received over protocol.
182
176
  */
183
177
  onMessageReceived: null as ((message: Object) => void) | null,
178
+
179
+ /**
180
+ * Runs a function when no protocol activity is present.
181
+ * ProtocolClient.test.deprecatedRunAfterPendingDispatches(() => console.log('done'))
182
+ */
183
+ deprecatedRunAfterPendingDispatches: null as ((arg0: () => void) => void) | null,
184
184
  };
185
185
 
186
186
  export class SessionRouter implements CDPConnectionObserver {
@@ -352,7 +352,7 @@ export class AccessibilityModel extends SDKModel<EventTypes> implements Protocol
352
352
  Promise<AccessibilityNode[]> {
353
353
  const parent = this.#axIdToAXNode.get(nodeId);
354
354
  if (!parent) {
355
- throw new Error('Cannot request children before parent');
355
+ return [];
356
356
  }
357
357
  if (!parent.hasUnloadedChildren()) {
358
358
  return parent.children();
@@ -370,7 +370,7 @@ export class AccessibilityModel extends SDKModel<EventTypes> implements Protocol
370
370
  this.#pendingChildRequests.delete(nodeId);
371
371
  }
372
372
  }
373
- return parent.children();
373
+ return this.#axIdToAXNode.get(nodeId)?.children() ?? [];
374
374
  }
375
375
 
376
376
  async requestAndLoadSubTreeToNode(node: DOMNode): Promise<AccessibilityNode[]|null> {
@@ -0,0 +1,32 @@
1
+ // Copyright 2026 The Chromium Authors
2
+ // Use of this source code is governed by a BSD-style license that can be
3
+ // found in the LICENSE file.
4
+
5
+ import type * as Protocol from '../../generated/protocol.js';
6
+ import type * as Platform from '../platform/platform.js';
7
+
8
+ import type {CSSModel} from './CSSModel.js';
9
+ import type {CSSStyleSheetHeader} from './CSSStyleSheetHeader.js';
10
+
11
+ export class CSSLocation {
12
+ readonly #cssModel: CSSModel;
13
+ styleSheetId: Protocol.DOM.StyleSheetId;
14
+ url: Platform.DevToolsPath.UrlString;
15
+ lineNumber: number;
16
+ columnNumber: number;
17
+ constructor(header: CSSStyleSheetHeader, lineNumber: number, columnNumber?: number) {
18
+ this.#cssModel = header.cssModel();
19
+ this.styleSheetId = header.id;
20
+ this.url = header.resourceURL();
21
+ this.lineNumber = lineNumber;
22
+ this.columnNumber = columnNumber || 0;
23
+ }
24
+
25
+ cssModel(): CSSModel {
26
+ return this.#cssModel;
27
+ }
28
+
29
+ header(): CSSStyleSheetHeader|null {
30
+ return this.#cssModel.styleSheetHeaderForId(this.styleSheetId);
31
+ }
32
+ }
@@ -34,6 +34,7 @@ import {
34
34
  localEvalCSS,
35
35
  MathFunctionMatcher,
36
36
  PositionAnchorMatcher,
37
+ PositionAreaMatcher,
37
38
  PositionTryMatcher,
38
39
  RelativeColorChannelMatcher,
39
40
  ShadowMatcher,
@@ -1068,6 +1069,7 @@ export class CSSMatchedStyles {
1068
1069
  new AnchorFunctionMatcher(),
1069
1070
  new PositionAnchorMatcher(),
1070
1071
  new FlexGridGridLanesMatcher(),
1072
+ new PositionAreaMatcher(),
1071
1073
  new PositionTryMatcher(),
1072
1074
  new LengthMatcher(),
1073
1075
  new MathFunctionMatcher(),
@@ -11,6 +11,7 @@ import * as Root from '../root/root.js';
11
11
  import * as TextUtils from '../text_utils/text_utils.js';
12
12
 
13
13
  import {CSSFontFace} from './CSSFontFace.js';
14
+ import {CSSLocation} from './CSSLocation.js';
14
15
  import {CSSMatchedStyles} from './CSSMatchedStyles.js';
15
16
  import {CSSMedia} from './CSSMedia.js';
16
17
  import {cssMetadata} from './CSSMetadata.js';
@@ -1052,28 +1053,7 @@ export class Edit {
1052
1053
  }
1053
1054
  }
1054
1055
 
1055
- export class CSSLocation {
1056
- readonly #cssModel: CSSModel;
1057
- styleSheetId: Protocol.DOM.StyleSheetId;
1058
- url: Platform.DevToolsPath.UrlString;
1059
- lineNumber: number;
1060
- columnNumber: number;
1061
- constructor(header: CSSStyleSheetHeader, lineNumber: number, columnNumber?: number) {
1062
- this.#cssModel = header.cssModel();
1063
- this.styleSheetId = header.id;
1064
- this.url = header.resourceURL();
1065
- this.lineNumber = lineNumber;
1066
- this.columnNumber = columnNumber || 0;
1067
- }
1068
-
1069
- cssModel(): CSSModel {
1070
- return this.#cssModel;
1071
- }
1072
-
1073
- header(): CSSStyleSheetHeader|null {
1074
- return this.#cssModel.styleSheetHeaderForId(this.styleSheetId);
1075
- }
1076
- }
1056
+ export {CSSLocation};
1077
1057
 
1078
1058
  class CSSDispatcher implements ProtocolProxyApi.CSSDispatcher {
1079
1059
  readonly #cssModel: CSSModel;
@@ -1508,3 +1508,32 @@ export class EnvFunctionMatcher extends EnvFunctionMatcherBase {
1508
1508
  return new EnvFunctionMatch(matching.ast.text(node), node, varName, value ?? fallbackValue ?? null, Boolean(value));
1509
1509
  }
1510
1510
  }
1511
+
1512
+ export class PositionAreaMatch implements Match {
1513
+ constructor(readonly text: string, readonly node: CodeMirror.SyntaxNode) {
1514
+ }
1515
+ }
1516
+
1517
+ const PositionAreaMatcherBase: MatcherClass<PositionAreaMatch> = matcherBase(PositionAreaMatch);
1518
+ // clang-format off
1519
+ export class PositionAreaMatcher extends PositionAreaMatcherBase {
1520
+ // clang-format on
1521
+ override accepts(propertyName: string): boolean {
1522
+ return propertyName === 'position-area' || propertyName === 'inset-area';
1523
+ }
1524
+
1525
+ override matches(node: CodeMirror.SyntaxNode, matching: BottomUpTreeMatching): PositionAreaMatch|null {
1526
+ if (node.name !== 'Declaration') {
1527
+ return null;
1528
+ }
1529
+ const valueNodes = ASTUtils.siblings(ASTUtils.declValue(node));
1530
+ if (valueNodes.length === 0) {
1531
+ return null;
1532
+ }
1533
+ const valueText = matching.getComputedTextRange(valueNodes[0], valueNodes[valueNodes.length - 1]);
1534
+ if (CSSMetadata.isCSSWideKeyword(valueText)) {
1535
+ return null;
1536
+ }
1537
+ return new PositionAreaMatch(valueText, node);
1538
+ }
1539
+ }
@@ -5,7 +5,8 @@
5
5
  import type * as Protocol from '../../generated/protocol.js';
6
6
  import type * as TextUtils from '../text_utils/text_utils.js';
7
7
 
8
- import {CSSLocation, type CSSModel, type Edit} from './CSSModel.js';
8
+ import {CSSLocation} from './CSSLocation.js';
9
+ import type {CSSModel, Edit} from './CSSModel.js';
9
10
  import type {CSSStyleSheetHeader} from './CSSStyleSheetHeader.js';
10
11
 
11
12
  type CSSQueryPayload =
@@ -231,6 +231,35 @@ export class CSSStyleRule extends CSSRule {
231
231
 
232
232
  super.rebase(edit);
233
233
  }
234
+
235
+ constructResolvedSelector(nestingIndex?: number): string|undefined {
236
+ const nestingSelectors = this.nestingSelectors;
237
+ if (!nestingSelectors) {
238
+ return nestingIndex === undefined ? this.selectorText() : undefined;
239
+ }
240
+
241
+ if (nestingIndex !== undefined && (nestingIndex < 0 || nestingIndex >= nestingSelectors.length)) {
242
+ return undefined;
243
+ }
244
+
245
+ const selectorText = nestingIndex !== undefined ? nestingSelectors[nestingIndex] : this.selectorText();
246
+
247
+ const parentIndex = nestingIndex !== undefined ? nestingIndex + 1 : 0;
248
+ const parentSelector = this.constructResolvedSelector(parentIndex);
249
+
250
+ if (!parentSelector) {
251
+ return selectorText;
252
+ }
253
+
254
+ // Strip pseudo-elements (e.g. ::before) because pseudo-elements are invalid inside CSS :is(...).
255
+ const sanitizedParent = parentSelector.replace(/::[a-zA-Z-]+/g, '').trim();
256
+
257
+ if (selectorText.includes('&')) {
258
+ return selectorText.replaceAll('&', `:is(${sanitizedParent})`);
259
+ }
260
+
261
+ return `:is(${sanitizedParent}) ${selectorText.trim()}`;
262
+ }
234
263
  }
235
264
 
236
265
  export class CSSPropertyRule extends CSSRule {
@@ -1076,17 +1076,19 @@ export class DOMNode extends Common.ObjectWrapper.ObjectWrapper<DOMNodeEventType
1076
1076
  });
1077
1077
  }
1078
1078
 
1079
- duplicate(): void {
1079
+ async duplicate(): Promise<{error: string | null, node: DOMNode|null}> {
1080
1080
  if (this.isInShadowTree()) {
1081
- return;
1081
+ return {error: 'Cannot duplicate node in shadow tree', node: null};
1082
1082
  }
1083
1083
 
1084
1084
  const parentNode = this.parentNode ? this.parentNode : this;
1085
1085
  if (parentNode.nodeName() === '#document') {
1086
- return;
1086
+ return {error: 'Parent node is document', node: null};
1087
1087
  }
1088
1088
 
1089
- this.copyTo(parentNode, this.nextSibling);
1089
+ return await new Promise(resolve => {
1090
+ this.copyTo(parentNode, this.nextSibling, (error, node) => resolve({error, node}));
1091
+ });
1090
1092
  }
1091
1093
 
1092
1094
  /**
@@ -2564,7 +2566,8 @@ export class DOMNodeSnapshot extends DOMNode {
2564
2566
  _callback?: ((arg0: string|null, arg1: DOMNode|null) => void)|undefined): void {
2565
2567
  }
2566
2568
 
2567
- override duplicate(): void {
2569
+ override duplicate(): Promise<{error: string | null, node: DOMNode|null}> {
2570
+ return Promise.resolve({error: null, node: null});
2568
2571
  }
2569
2572
 
2570
2573
  override canInspectNode(): boolean {
@@ -2616,7 +2619,8 @@ export class DOMDocumentSnapshot extends DOMDocument {
2616
2619
  _callback?: ((arg0: string|null, arg1: DOMNode|null) => void)|undefined): void {
2617
2620
  }
2618
2621
 
2619
- override duplicate(): void {
2622
+ override duplicate(): Promise<{error: string | null, node: DOMNode|null}> {
2623
+ return Promise.resolve({error: null, node: null});
2620
2624
  }
2621
2625
 
2622
2626
  override canInspectNode(): boolean {
@@ -1473,8 +1473,12 @@ export class Scope implements ScopeChainEntry {
1473
1473
  return undefined;
1474
1474
  }
1475
1475
 
1476
+ empty(): boolean {
1477
+ return Boolean(this.#payload.empty);
1478
+ }
1479
+
1476
1480
  extraProperties(): RemoteObjectProperty[] {
1477
- if (this.#ordinal !== 0 || this.#type !== Protocol.Debugger.ScopeType.Local || this.#callFrame.script.isWasm()) {
1481
+ if (this !== this.#callFrame.localScope() || this.#callFrame.script.isWasm()) {
1478
1482
  return [];
1479
1483
  }
1480
1484
 
@@ -1014,6 +1014,8 @@ export class NetworkDispatcher implements ProtocolProxyApi.NetworkDispatcher {
1014
1014
  }
1015
1015
  requestToManagerMap.set(networkRequest, this.#manager);
1016
1016
  }
1017
+ networkRequest.setCacheDisabled(
1018
+ this.#manager.target().targetManager().settings.resolve(cacheDisabledSettingDescriptor).get());
1017
1019
  networkRequest.hasNetworkData = true;
1018
1020
  this.updateNetworkRequestWithRequest(networkRequest, request);
1019
1021
  networkRequest.setIssueTime(timestamp, wallTime);