chrome-devtools-frontend 1.0.1526203 → 1.0.1528866

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 (328) hide show
  1. package/docs/ui_engineering.md +159 -0
  2. package/eslint.config.mjs +6 -1
  3. package/front_end/core/i18n/i18nImpl.ts +5 -0
  4. package/front_end/core/protocol_client/protocol_client.ts +1 -1
  5. package/front_end/core/root/Runtime.ts +28 -4
  6. package/front_end/core/sdk/CSSMatchedStyles.ts +50 -7
  7. package/front_end/core/sdk/CSSRule.ts +35 -6
  8. package/front_end/core/sdk/ChildTargetManager.ts +2 -0
  9. package/front_end/core/sdk/Connections.ts +2 -1
  10. package/front_end/core/sdk/DOMModel.ts +4 -0
  11. package/front_end/core/sdk/DebuggerModel.ts +5 -1
  12. package/front_end/core/sdk/NetworkManager.ts +214 -31
  13. package/front_end/core/sdk/PreloadingModel.ts +82 -17
  14. package/front_end/core/sdk/RehydratingConnection.snapshot.txt +1 -1
  15. package/front_end/core/sdk/RehydratingConnection.ts +29 -4
  16. package/front_end/core/sdk/ScopeTreeCache.ts +8 -3
  17. package/front_end/core/sdk/SourceMap.ts +37 -11
  18. package/front_end/core/sdk/SourceMapManager.ts +13 -2
  19. package/front_end/core/sdk/SourceMapScopesInfo.ts +17 -0
  20. package/front_end/core/sdk/TargetManager.ts +0 -22
  21. package/front_end/core/sdk/TraceObject.ts +8 -7
  22. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +81 -0
  23. package/front_end/entrypoints/inspector_main/InspectorMain.ts +3 -1
  24. package/front_end/entrypoints/main/GlobalAiButton.ts +1 -0
  25. package/front_end/entrypoints/main/MainImpl.ts +20 -25
  26. package/front_end/generated/InspectorBackendCommands.js +4 -3
  27. package/front_end/generated/protocol-mapping.d.ts +3 -1
  28. package/front_end/generated/protocol-proxy-api.d.ts +3 -1
  29. package/front_end/generated/protocol.ts +17 -3
  30. package/front_end/models/ai_assistance/BuiltInAi.ts +111 -0
  31. package/front_end/models/ai_assistance/ai_assistance.ts +53 -24
  32. package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.snapshot.txt +105 -0
  33. package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.ts +6 -1
  34. package/front_end/models/extensions/ExtensionView.ts +3 -0
  35. package/front_end/models/javascript_metadata/NativeFunctions.js +23 -27
  36. package/front_end/models/live-metrics/web-vitals-injected/web-vitals-injected.ts +31 -29
  37. package/front_end/models/persistence/EditFileSystemView.ts +1 -0
  38. package/front_end/models/source_map_scopes/NamesResolver.ts +5 -11
  39. package/front_end/models/stack_trace/Trie.ts +9 -0
  40. package/front_end/models/trace/lantern/types/Lantern.ts +1 -1
  41. package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +1 -0
  42. package/front_end/panels/accessibility/AccessibilitySidebarView.ts +1 -0
  43. package/front_end/panels/ai_assistance/AiAssistancePanel.ts +120 -113
  44. package/front_end/panels/ai_assistance/PatchWidget.ts +9 -8
  45. package/front_end/panels/ai_assistance/SelectWorkspaceDialog.ts +2 -0
  46. package/front_end/panels/ai_assistance/components/ChatView.ts +29 -29
  47. package/front_end/panels/ai_assistance/components/UserActionRow.ts +1 -0
  48. package/front_end/panels/animation/AnimationTimeline.ts +1 -0
  49. package/front_end/panels/application/CookieItemsView.ts +1 -0
  50. package/front_end/panels/application/KeyValueStorageItemsView.ts +1 -0
  51. package/front_end/panels/application/ServiceWorkerCacheViews.ts +2 -0
  52. package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +11 -5
  53. package/front_end/panels/application/preloading/components/PreloadingMismatchedHeadersGrid.ts +2 -2
  54. package/front_end/panels/application/preloading/components/PreloadingString.ts +7 -5
  55. package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +22 -10
  56. package/front_end/panels/changes/CombinedDiffView.ts +1 -0
  57. package/front_end/panels/console/ConsoleInsightTeaser.ts +106 -0
  58. package/front_end/panels/console/ConsolePanel.ts +2 -0
  59. package/front_end/panels/console/ConsolePrompt.ts +12 -2
  60. package/front_end/panels/console/ConsoleSidebar.ts +1 -1
  61. package/front_end/panels/console/ConsoleView.ts +12 -0
  62. package/front_end/panels/console/ConsoleViewMessage.ts +27 -0
  63. package/front_end/panels/{explain → console}/PromptBuilder.ts +12 -7
  64. package/front_end/panels/console/console.ts +6 -0
  65. package/front_end/panels/console/consoleInsightTeaser.css +55 -0
  66. package/front_end/panels/coverage/CoverageListView.ts +141 -277
  67. package/front_end/panels/coverage/CoverageView.ts +330 -324
  68. package/front_end/panels/coverage/coverageView.css +17 -0
  69. package/front_end/panels/elements/ComputedStyleWidget.ts +1 -0
  70. package/front_end/panels/elements/LayoutPane.ts +1 -0
  71. package/front_end/panels/elements/NodeStackTraceWidget.ts +1 -0
  72. package/front_end/panels/elements/StylePropertyTreeElement.ts +5 -1
  73. package/front_end/panels/elements/stylePropertiesTreeOutline.css +17 -0
  74. package/front_end/panels/emulation/DeviceModeView.ts +2 -0
  75. package/front_end/panels/explain/ActionDelegate.ts +1 -2
  76. package/front_end/panels/explain/components/ConsoleInsight.ts +14 -12
  77. package/front_end/panels/explain/explain.ts +0 -1
  78. package/front_end/panels/js_timeline/js_timeline-meta.ts +1 -1
  79. package/front_end/panels/layer_viewer/Layers3DView.ts +2 -0
  80. package/front_end/panels/lighthouse/LighthouseReportSelector.ts +1 -0
  81. package/front_end/panels/linear_memory_inspector/LinearMemoryInspectorPane.ts +12 -19
  82. package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +27 -43
  83. package/front_end/panels/media/MainView.ts +1 -0
  84. package/front_end/panels/media/TickingFlameChart.ts +2 -0
  85. package/front_end/panels/network/BlockedURLsPane.ts +111 -85
  86. package/front_end/panels/network/EventSourceMessagesView.ts +1 -0
  87. package/front_end/panels/network/NetworkItemView.ts +1 -0
  88. package/front_end/panels/network/NetworkLogView.ts +9 -7
  89. package/front_end/panels/network/NetworkOverview.ts +1 -0
  90. package/front_end/panels/network/RequestCookiesView.ts +1 -0
  91. package/front_end/panels/network/RequestHTMLView.ts +1 -0
  92. package/front_end/panels/network/RequestInitiatorView.ts +1 -0
  93. package/front_end/panels/network/RequestPayloadView.ts +1 -0
  94. package/front_end/panels/network/RequestPreviewView.ts +1 -0
  95. package/front_end/panels/network/RequestResponseView.ts +2 -1
  96. package/front_end/panels/network/RequestTimingView.ts +2 -0
  97. package/front_end/panels/network/ResourceDirectSocketChunkView.ts +1 -0
  98. package/front_end/panels/network/ResourceWebSocketFrameView.ts +1 -0
  99. package/front_end/panels/network/components/RequestHeadersView.ts +2 -0
  100. package/front_end/panels/network/components/RequestTrustTokensView.ts +2 -0
  101. package/front_end/panels/performance_monitor/PerformanceMonitor.ts +2 -0
  102. package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +2 -0
  103. package/front_end/panels/profiler/HeapSnapshotView.ts +7 -0
  104. package/front_end/panels/profiler/IsolateSelector.ts +1 -0
  105. package/front_end/panels/profiler/LiveHeapProfileView.ts +1 -0
  106. package/front_end/panels/profiler/ProfileView.ts +1 -0
  107. package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +1 -0
  108. package/front_end/panels/recorder/RecorderPanel.ts +2 -0
  109. package/front_end/panels/screencast/ScreencastView.ts +1 -0
  110. package/front_end/panels/search/SearchView.ts +1 -0
  111. package/front_end/panels/settings/AISettingsTab.ts +3 -3
  112. package/front_end/panels/settings/WorkspaceSettingsTab.ts +2 -0
  113. package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +2 -2
  114. package/front_end/panels/sources/AiCodeCompletionPlugin.ts +12 -0
  115. package/front_end/panels/sources/BreakpointsView.ts +1 -0
  116. package/front_end/panels/sources/DebuggerPlugin.ts +1 -0
  117. package/front_end/panels/sources/UISourceCodeFrame.ts +17 -2
  118. package/front_end/panels/timeline/README.md +2 -2
  119. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +1 -1
  120. package/front_end/panels/timeline/TimelineFlameChartView.ts +4 -3
  121. package/front_end/panels/timeline/TimelineLayersView.ts +1 -0
  122. package/front_end/panels/timeline/TimelinePaintProfilerView.ts +114 -37
  123. package/front_end/panels/timeline/TimelinePanel.ts +43 -62
  124. package/front_end/panels/timeline/TimelineTreeView.ts +1 -0
  125. package/front_end/panels/timeline/components/LiveMetricsView.ts +4 -8
  126. package/front_end/panels/timeline/components/Sidebar.ts +2 -0
  127. package/front_end/panels/timeline/components/SidebarSingleInsightSet.ts +1 -1
  128. package/front_end/panels/timeline/components/insights/BaseInsightComponent.ts +7 -7
  129. package/front_end/panels/timeline/overlays/OverlaysImpl.ts +1 -1
  130. package/front_end/panels/timeline/overlays/components/EntryLabelOverlay.ts +4 -4
  131. package/front_end/panels/web_audio/WebAudioView.ts +1 -0
  132. package/front_end/third_party/chromium/README.chromium +1 -1
  133. package/front_end/third_party/lighthouse/README.chromium +2 -2
  134. package/front_end/third_party/lighthouse/lighthouse-dt-bundle.js +1530 -2426
  135. package/front_end/third_party/lighthouse/locales/ar-XB.json +107 -455
  136. package/front_end/third_party/lighthouse/locales/ar.json +107 -455
  137. package/front_end/third_party/lighthouse/locales/bg.json +96 -444
  138. package/front_end/third_party/lighthouse/locales/ca.json +96 -444
  139. package/front_end/third_party/lighthouse/locales/cs.json +96 -444
  140. package/front_end/third_party/lighthouse/locales/da.json +96 -444
  141. package/front_end/third_party/lighthouse/locales/de.json +96 -444
  142. package/front_end/third_party/lighthouse/locales/el.json +96 -444
  143. package/front_end/third_party/lighthouse/locales/en-GB.json +96 -444
  144. package/front_end/third_party/lighthouse/locales/en-US.json +116 -467
  145. package/front_end/third_party/lighthouse/locales/en-XA.json +93 -441
  146. package/front_end/third_party/lighthouse/locales/en-XL.json +116 -467
  147. package/front_end/third_party/lighthouse/locales/es-419.json +96 -444
  148. package/front_end/third_party/lighthouse/locales/es.json +96 -444
  149. package/front_end/third_party/lighthouse/locales/fi.json +96 -444
  150. package/front_end/third_party/lighthouse/locales/fil.json +96 -444
  151. package/front_end/third_party/lighthouse/locales/fr.json +96 -444
  152. package/front_end/third_party/lighthouse/locales/he.json +118 -466
  153. package/front_end/third_party/lighthouse/locales/hi.json +96 -444
  154. package/front_end/third_party/lighthouse/locales/hr.json +100 -448
  155. package/front_end/third_party/lighthouse/locales/hu.json +96 -444
  156. package/front_end/third_party/lighthouse/locales/id.json +96 -444
  157. package/front_end/third_party/lighthouse/locales/it.json +96 -444
  158. package/front_end/third_party/lighthouse/locales/ja.json +96 -444
  159. package/front_end/third_party/lighthouse/locales/ko.json +97 -445
  160. package/front_end/third_party/lighthouse/locales/lt.json +96 -444
  161. package/front_end/third_party/lighthouse/locales/lv.json +97 -445
  162. package/front_end/third_party/lighthouse/locales/nl.json +96 -444
  163. package/front_end/third_party/lighthouse/locales/no.json +96 -444
  164. package/front_end/third_party/lighthouse/locales/pl.json +96 -444
  165. package/front_end/third_party/lighthouse/locales/pt-PT.json +96 -444
  166. package/front_end/third_party/lighthouse/locales/pt.json +97 -445
  167. package/front_end/third_party/lighthouse/locales/ro.json +97 -445
  168. package/front_end/third_party/lighthouse/locales/ru.json +96 -444
  169. package/front_end/third_party/lighthouse/locales/sk.json +96 -444
  170. package/front_end/third_party/lighthouse/locales/sl.json +96 -444
  171. package/front_end/third_party/lighthouse/locales/sr-Latn.json +96 -444
  172. package/front_end/third_party/lighthouse/locales/sr.json +96 -444
  173. package/front_end/third_party/lighthouse/locales/sv.json +96 -444
  174. package/front_end/third_party/lighthouse/locales/ta.json +96 -444
  175. package/front_end/third_party/lighthouse/locales/te.json +97 -445
  176. package/front_end/third_party/lighthouse/locales/th.json +96 -444
  177. package/front_end/third_party/lighthouse/locales/tr.json +96 -444
  178. package/front_end/third_party/lighthouse/locales/uk.json +96 -444
  179. package/front_end/third_party/lighthouse/locales/vi.json +96 -444
  180. package/front_end/third_party/lighthouse/locales/zh-HK.json +96 -444
  181. package/front_end/third_party/lighthouse/locales/zh-TW.json +97 -445
  182. package/front_end/third_party/lighthouse/locales/zh.json +96 -444
  183. package/front_end/third_party/lighthouse/report/bundle.d.ts +8 -14
  184. package/front_end/third_party/lighthouse/report/bundle.js +10 -49
  185. package/front_end/third_party/lighthouse/report-assets/report-generator.mjs +1 -1
  186. package/front_end/third_party/web-vitals/README.chromium +5 -8
  187. package/front_end/third_party/web-vitals/package/README.md +191 -152
  188. package/front_end/third_party/web-vitals/package/dist/modules/attribution/index.d.ts +0 -1
  189. package/front_end/third_party/web-vitals/package/dist/modules/attribution/index.js +0 -1
  190. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onCLS.d.ts +2 -2
  191. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onCLS.js +45 -26
  192. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFCP.d.ts +2 -2
  193. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFCP.js +3 -3
  194. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.d.ts +10 -10
  195. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.js +307 -206
  196. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.d.ts +2 -2
  197. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.js +69 -49
  198. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onTTFB.d.ts +2 -2
  199. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onTTFB.js +2 -2
  200. package/front_end/third_party/web-vitals/package/dist/modules/index.d.ts +0 -1
  201. package/front_end/third_party/web-vitals/package/dist/modules/index.js +0 -1
  202. package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.d.ts +33 -0
  203. package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.js +111 -0
  204. package/front_end/third_party/web-vitals/package/dist/modules/lib/LCPEntryManager.d.ts +4 -0
  205. package/front_end/third_party/web-vitals/package/dist/modules/{attribution/deprecated.js → lib/LCPEntryManager.js} +6 -7
  206. package/front_end/third_party/web-vitals/package/dist/modules/lib/LayoutShiftManager.d.ts +6 -0
  207. package/front_end/third_party/web-vitals/package/dist/modules/lib/LayoutShiftManager.js +44 -0
  208. package/front_end/third_party/web-vitals/package/dist/modules/lib/bindReporter.js +1 -1
  209. package/front_end/third_party/web-vitals/package/dist/modules/lib/generateUniqueID.js +1 -1
  210. package/front_end/third_party/web-vitals/package/dist/modules/lib/getActivationStart.js +1 -1
  211. package/front_end/third_party/web-vitals/package/dist/modules/lib/getNavigationEntry.js +5 -7
  212. package/front_end/third_party/web-vitals/package/dist/modules/lib/getSelector.d.ts +1 -1
  213. package/front_end/third_party/web-vitals/package/dist/modules/lib/getSelector.js +9 -12
  214. package/front_end/third_party/web-vitals/package/dist/modules/lib/getVisibilityWatcher.d.ts +1 -0
  215. package/front_end/third_party/web-vitals/package/dist/modules/lib/getVisibilityWatcher.js +52 -33
  216. package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.d.ts +0 -2
  217. package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.js +2 -2
  218. package/front_end/third_party/web-vitals/package/dist/modules/lib/initUnique.d.ts +6 -0
  219. package/front_end/third_party/web-vitals/package/dist/modules/{deprecated.js → lib/initUnique.js} +11 -4
  220. package/front_end/third_party/web-vitals/package/dist/modules/lib/observe.js +3 -6
  221. package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/interactionCountPolyfill.js +6 -6
  222. package/front_end/third_party/web-vitals/package/dist/modules/lib/{whenIdle.d.ts → whenIdleOrHidden.d.ts} +1 -1
  223. package/front_end/third_party/web-vitals/package/dist/modules/lib/{whenIdle.js → whenIdleOrHidden.js} +10 -8
  224. package/front_end/third_party/web-vitals/package/dist/modules/onCLS.js +17 -35
  225. package/front_end/third_party/web-vitals/package/dist/modules/onFCP.js +3 -5
  226. package/front_end/third_party/web-vitals/package/dist/modules/onINP.d.ts +9 -7
  227. package/front_end/third_party/web-vitals/package/dist/modules/onINP.js +27 -19
  228. package/front_end/third_party/web-vitals/package/dist/modules/onLCP.js +33 -26
  229. package/front_end/third_party/web-vitals/package/dist/modules/onTTFB.js +2 -4
  230. package/front_end/third_party/web-vitals/package/dist/modules/types/base.d.ts +6 -5
  231. package/front_end/third_party/web-vitals/package/dist/modules/types/cls.d.ts +5 -3
  232. package/front_end/third_party/web-vitals/package/dist/modules/types/inp.d.ts +80 -33
  233. package/front_end/third_party/web-vitals/package/dist/modules/types/lcp.d.ts +6 -2
  234. package/front_end/third_party/web-vitals/package/dist/modules/types.d.ts +28 -4
  235. package/front_end/third_party/web-vitals/package/dist/modules/types.js +0 -1
  236. package/front_end/third_party/web-vitals/package/package.json +4 -10
  237. package/front_end/third_party/web-vitals/package/src/attribution/index.ts +0 -1
  238. package/front_end/third_party/web-vitals/package/src/attribution/onCLS.ts +58 -33
  239. package/front_end/third_party/web-vitals/package/src/attribution/onFCP.ts +4 -4
  240. package/front_end/third_party/web-vitals/package/src/attribution/onINP.ts +382 -258
  241. package/front_end/third_party/web-vitals/package/src/attribution/onLCP.ts +96 -69
  242. package/front_end/third_party/web-vitals/package/src/attribution/onTTFB.ts +3 -3
  243. package/front_end/third_party/web-vitals/package/src/index.ts +0 -1
  244. package/front_end/third_party/web-vitals/package/src/lib/InteractionManager.ts +146 -0
  245. package/front_end/third_party/web-vitals/package/src/{attribution/deprecated.ts → lib/LCPEntryManager.ts} +6 -9
  246. package/front_end/third_party/web-vitals/package/src/lib/LayoutShiftManager.ts +50 -0
  247. package/front_end/third_party/web-vitals/package/src/lib/bindReporter.ts +1 -1
  248. package/front_end/third_party/web-vitals/package/src/lib/generateUniqueID.ts +1 -1
  249. package/front_end/third_party/web-vitals/package/src/lib/getActivationStart.ts +1 -1
  250. package/front_end/third_party/web-vitals/package/src/lib/getNavigationEntry.ts +5 -8
  251. package/front_end/third_party/web-vitals/package/src/lib/getSelector.ts +12 -12
  252. package/front_end/third_party/web-vitals/package/src/lib/getVisibilityWatcher.ts +57 -35
  253. package/front_end/third_party/web-vitals/package/src/lib/initMetric.ts +2 -2
  254. package/front_end/third_party/web-vitals/package/src/{deprecated.ts → lib/initUnique.ts} +14 -8
  255. package/front_end/third_party/web-vitals/package/src/lib/observe.ts +3 -11
  256. package/front_end/third_party/web-vitals/package/src/lib/polyfills/interactionCountPolyfill.ts +12 -6
  257. package/front_end/third_party/web-vitals/package/src/lib/{whenIdle.ts → whenIdleOrHidden.ts} +10 -8
  258. package/front_end/third_party/web-vitals/package/src/onCLS.ts +17 -38
  259. package/front_end/third_party/web-vitals/package/src/onFCP.ts +3 -6
  260. package/front_end/third_party/web-vitals/package/src/onINP.ts +33 -28
  261. package/front_end/third_party/web-vitals/package/src/onLCP.ts +36 -29
  262. package/front_end/third_party/web-vitals/package/src/onTTFB.ts +2 -5
  263. package/front_end/third_party/web-vitals/package/src/types/base.ts +5 -5
  264. package/front_end/third_party/web-vitals/package/src/types/cls.ts +5 -3
  265. package/front_end/third_party/web-vitals/package/src/types/inp.ts +88 -33
  266. package/front_end/third_party/web-vitals/package/src/types/lcp.ts +6 -2
  267. package/front_end/third_party/web-vitals/package/src/types.ts +47 -4
  268. package/front_end/third_party/web-vitals/patches/0001-Add-onEachInteraction-to-onINP-options.patch +75 -0
  269. package/front_end/third_party/web-vitals/rebuild.sh +32 -18
  270. package/front_end/third_party/web-vitals/web-vitals-tsconfig.json +5 -10
  271. package/front_end/third_party/web-vitals/web-vitals.ts +0 -2
  272. package/front_end/ui/components/buttons/Button.ts +1 -1
  273. package/front_end/ui/components/docs/console_insight/basic.ts +3 -2
  274. package/front_end/ui/components/legacy_wrapper/LegacyWrapper.ts +2 -0
  275. package/front_end/ui/components/text_editor/TextEditor.ts +0 -2
  276. package/front_end/ui/legacy/EmptyWidget.ts +11 -1
  277. package/front_end/ui/legacy/InspectorView.ts +2 -0
  278. package/front_end/ui/legacy/SplitWidget.ts +2 -0
  279. package/front_end/ui/legacy/TabbedPane.ts +1 -0
  280. package/front_end/ui/legacy/TargetCrashedScreen.ts +1 -0
  281. package/front_end/ui/legacy/Toolbar.ts +25 -4
  282. package/front_end/ui/legacy/UIUtils.ts +28 -13
  283. package/front_end/ui/legacy/ViewManager.ts +1 -0
  284. package/front_end/ui/legacy/Widget.ts +5 -0
  285. package/front_end/ui/legacy/components/color_picker/FormatPickerContextMenu.ts +7 -20
  286. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +2 -0
  287. package/front_end/ui/legacy/components/cookie_table/CookiesTable.ts +1 -0
  288. package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +1 -1
  289. package/front_end/ui/legacy/components/inline_editor/BezierEditor.ts +1 -0
  290. package/front_end/ui/legacy/components/perf_ui/ChartViewport.ts +1 -0
  291. package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +1 -0
  292. package/front_end/ui/legacy/components/source_frame/FontView.ts +1 -0
  293. package/front_end/ui/legacy/components/source_frame/ImageView.ts +1 -0
  294. package/front_end/ui/legacy/components/source_frame/JSONView.ts +1 -0
  295. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +1 -0
  296. package/front_end/ui/legacy/components/source_frame/StreamingContentHexView.ts +9 -8
  297. package/front_end/ui/visual_logging/KnownContextValues.ts +17 -0
  298. package/mcp/README.md +7 -0
  299. package/mcp/mcp.ts +8 -0
  300. package/package.json +1 -1
  301. package/front_end/models/live-metrics/web-vitals-injected/OnEachInteraction.ts +0 -34
  302. package/front_end/third_party/web-vitals/package/attribution.d.ts +0 -16
  303. package/front_end/third_party/web-vitals/package/attribution.js +0 -18
  304. package/front_end/third_party/web-vitals/package/dist/modules/attribution/deprecated.d.ts +0 -7
  305. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFID.d.ts +0 -11
  306. package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFID.js +0 -46
  307. package/front_end/third_party/web-vitals/package/dist/modules/deprecated.d.ts +0 -5
  308. package/front_end/third_party/web-vitals/package/dist/modules/lib/interactions.d.ts +0 -31
  309. package/front_end/third_party/web-vitals/package/dist/modules/lib/interactions.js +0 -107
  310. package/front_end/third_party/web-vitals/package/dist/modules/lib/onHidden.d.ts +0 -1
  311. package/front_end/third_party/web-vitals/package/dist/modules/lib/onHidden.js +0 -22
  312. package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/firstInputPolyfill.d.ts +0 -7
  313. package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/firstInputPolyfill.js +0 -147
  314. package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/getFirstHiddenTimePolyfill.d.ts +0 -1
  315. package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/getFirstHiddenTimePolyfill.js +0 -25
  316. package/front_end/third_party/web-vitals/package/dist/modules/onFID.d.ts +0 -13
  317. package/front_end/third_party/web-vitals/package/dist/modules/onFID.js +0 -70
  318. package/front_end/third_party/web-vitals/package/dist/modules/types/fid.d.ts +0 -46
  319. package/front_end/third_party/web-vitals/package/dist/modules/types/fid.js +0 -16
  320. package/front_end/third_party/web-vitals/package/src/attribution/onFID.ts +0 -62
  321. package/front_end/third_party/web-vitals/package/src/lib/interactions.ts +0 -139
  322. package/front_end/third_party/web-vitals/package/src/lib/onHidden.ts +0 -23
  323. package/front_end/third_party/web-vitals/package/src/lib/polyfills/firstInputPolyfill.ts +0 -174
  324. package/front_end/third_party/web-vitals/package/src/onFID.ts +0 -105
  325. package/front_end/third_party/web-vitals/package/src/types/fid.ts +0 -65
  326. package/front_end/ui/components/text_editor/textEditor.css +0 -18
  327. package/front_end/ui/legacy/inlineButton.css +0 -22
  328. /package/front_end/entrypoints/{rehydrated_devtools_app/rehydrated_devtools_app.ts → trace_app/trace_app.ts} +0 -0
@@ -5,12 +5,10 @@
5
5
  import * as WebVitals from '../../../third_party/web-vitals/web-vitals.js';
6
6
  import type * as Trace from '../../trace/trace.js';
7
7
 
8
- import * as OnEachInteraction from './OnEachInteraction.js';
9
8
  import * as OnEachLayoutShift from './OnEachLayoutShift.js';
10
9
  import * as Spec from './spec/spec.js';
11
10
 
12
11
  const {onLCP, onCLS, onINP} = WebVitals.Attribution;
13
- const {onEachInteraction} = OnEachInteraction;
14
12
  const {onEachLayoutShift} = OnEachLayoutShift;
15
13
 
16
14
  declare const window: Window&{
@@ -184,30 +182,7 @@ function initialize(): void {
184
182
  sendEventToDevTools(event);
185
183
  }, {reportAllChanges: true});
186
184
 
187
- onINP(metric => {
188
- // TODO(b/376777343): Remove this line when `interactionTargetElement` is removed from web-vitals.js
189
- // The `metric` emitted in this callback is stored within web-vitals.js closures.
190
- // This can lead to `interactionTargetElement` persisting in memory after it has been removed.
191
- // We don't use `interactionTargetElement` here, and `onEachInteraction` will interaction
192
- // elements separately so it is safe to remove here and prevent memory leaks.
193
- metric.attribution.interactionTargetElement = undefined;
194
-
195
- const event: Spec.InpChangeEvent = {
196
- name: 'INP',
197
- value: metric.value as Trace.Types.Timing.Milli,
198
- phases: {
199
- inputDelay: metric.attribution.inputDelay as Trace.Types.Timing.Milli,
200
- processingDuration: metric.attribution.processingDuration as Trace.Types.Timing.Milli,
201
- presentationDelay: metric.attribution.presentationDelay as Trace.Types.Timing.Milli,
202
- },
203
- startTime: metric.entries[0].startTime,
204
- entryGroupId: metric.entries[0].interactionId as Spec.InteractionEntryGroupId,
205
- interactionType: metric.attribution.interactionType,
206
- };
207
- sendEventToDevTools(event);
208
- }, {reportAllChanges: true, durationThreshold: 0});
209
-
210
- onEachInteraction(interaction => {
185
+ function onEachInteraction(interaction: WebVitals.INPMetricWithAttribution): void {
211
186
  // Multiple `InteractionEntry` events can be emitted for the same `uniqueInteractionId`
212
187
  // However, it is easier to combine these entries in the DevTools client rather than in
213
188
  // this injected code.
@@ -228,11 +203,38 @@ function initialize(): void {
228
203
  longAnimationFrameEntries: limitScripts(
229
204
  interaction.attribution.longAnimationFrameEntries.slice(-Spec.LOAF_LIMIT).map(loaf => loaf.toJSON())),
230
205
  };
231
- const node = interaction.attribution.interactionTargetElement;
232
- if (node) {
233
- event.nodeIndex = establishNodeIndex(node);
206
+ const target = interaction.attribution.interactionTarget;
207
+ if (target) {
208
+ event.nodeIndex = Number(target);
234
209
  }
235
210
  sendEventToDevTools(event);
211
+ }
212
+
213
+ onINP(metric => {
214
+ const event: Spec.InpChangeEvent = {
215
+ name: 'INP',
216
+ value: metric.value as Trace.Types.Timing.Milli,
217
+ phases: {
218
+ inputDelay: metric.attribution.inputDelay as Trace.Types.Timing.Milli,
219
+ processingDuration: metric.attribution.processingDuration as Trace.Types.Timing.Milli,
220
+ presentationDelay: metric.attribution.presentationDelay as Trace.Types.Timing.Milli,
221
+ },
222
+ startTime: metric.entries[0].startTime,
223
+ entryGroupId: metric.entries[0].interactionId as Spec.InteractionEntryGroupId,
224
+ interactionType: metric.attribution.interactionType,
225
+ };
226
+ sendEventToDevTools(event);
227
+ }, {
228
+ reportAllChanges: true,
229
+ durationThreshold: 0,
230
+ onEachInteraction,
231
+ generateTarget(el) {
232
+ if (el) {
233
+ return String(establishNodeIndex(el));
234
+ }
235
+
236
+ return undefined;
237
+ },
236
238
  });
237
239
 
238
240
  onEachLayoutShift(layoutShift => {
@@ -125,6 +125,7 @@ export class EditFileSystemView extends UI.Widget.VBox {
125
125
  }
126
126
 
127
127
  override wasShown(): void {
128
+ super.wasShown();
128
129
  this.#resyncExcludedFolderPaths();
129
130
  this.requestUpdate();
130
131
  }
@@ -3,6 +3,7 @@
3
3
  // found in the LICENSE file.
4
4
 
5
5
  import * as Common from '../../core/common/common.js';
6
+ import * as Root from '../../core/root/root.js';
6
7
  import * as SDK from '../../core/sdk/sdk.js';
7
8
  import * as Protocol from '../../generated/protocol.js';
8
9
  import * as Bindings from '../bindings/bindings.js';
@@ -48,16 +49,7 @@ scopeTree:
48
49
  return null;
49
50
  }
50
51
 
51
- const text = await getTextFor(script);
52
- if (!text) {
53
- return null;
54
- }
55
-
56
- const scopeTree = await SDK.ScopeTreeCache.scopeTreeForScript(script);
57
- if (!scopeTree) {
58
- return null;
59
- }
60
- return {scopeTree, text};
52
+ return await SDK.ScopeTreeCache.scopeTreeForScript(script);
61
53
  };
62
54
 
63
55
  /**
@@ -379,7 +371,9 @@ export const resolveScopeChain =
379
371
  return scopeChain;
380
372
  }
381
373
 
382
- scopeChain = callFrame.script.sourceMap()?.resolveScopeChain(callFrame);
374
+ scopeChain = Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.USE_SOURCE_MAP_SCOPES) ?
375
+ callFrame.script.sourceMap()?.resolveScopeChain(callFrame) :
376
+ null;
383
377
  if (scopeChain) {
384
378
  return scopeChain;
385
379
  }
@@ -17,6 +17,15 @@ export interface RawFrame {
17
17
  readonly columnNumber: number;
18
18
  }
19
19
 
20
+ /**
21
+ * @returns whether the frame is a V8 builtin frame e.g. Array.map. Builtin frames
22
+ * have neither source position nor script or URL. They only have a name.
23
+ */
24
+ export function isBuiltinFrame(rawFrame: RawFrame): boolean {
25
+ return rawFrame.lineNumber === -1 && rawFrame.columnNumber === -1 && !Boolean(rawFrame.scriptId) &&
26
+ !Boolean(rawFrame.url);
27
+ }
28
+
20
29
  interface FrameNodeBase<ChildT, ParentT> {
21
30
  readonly parent: ParentT;
22
31
  readonly children: ChildT[];
@@ -50,7 +50,7 @@ export interface Trace {
50
50
  }
51
51
  export type ResourcePriority = ('VeryLow'|'Low'|'Medium'|'High'|'VeryHigh');
52
52
  export type ResourceType = keyof typeof NetworkRequestTypes;
53
- type InitiatorType = ('parser'|'script'|'preload'|'SignedExchange'|'preflight'|'other');
53
+ type InitiatorType = ('parser'|'script'|'preload'|'SignedExchange'|'preflight'|'FedCM'|'other');
54
54
  export type ResourceTiming = Protocol.Network.ResourceTiming;
55
55
  export interface CallStack {
56
56
  callFrames: Array<{
@@ -188,6 +188,7 @@ export class AXBreadcrumbsPane extends AccessibilitySubPane {
188
188
  }
189
189
 
190
190
  override willHide(): void {
191
+ super.willHide();
191
192
  this.setPreselectedBreadcrumb(null);
192
193
  }
193
194
 
@@ -122,6 +122,7 @@ export class AccessibilitySidebarView extends UI.ThrottledWidget.ThrottledWidget
122
122
  }
123
123
 
124
124
  override willHide(): void {
125
+ super.willHide();
125
126
  SDK.TargetManager.TargetManager.instance().removeModelListener(
126
127
  SDK.DOMModel.DOMModel, SDK.DOMModel.Events.AttrModified, this.onNodeChange, this);
127
128
  SDK.TargetManager.TargetManager.instance().removeModelListener(