chrome-devtools-frontend 1.0.1522585 → 1.0.1524741

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 (341) hide show
  1. package/AUTHORS +1 -0
  2. package/docs/README.md +1 -0
  3. package/docs/policy/README.md +1 -0
  4. package/docs/policy/console-policy.md +144 -0
  5. package/docs/policy/images/console-policy1.png +0 -0
  6. package/docs/policy/images/console-policy2.png +0 -0
  7. package/docs/policy/images/console-policy3.png +0 -0
  8. package/docs/ui_engineering.md +22 -0
  9. package/front_end/Tests.js +1 -1
  10. package/front_end/core/common/Color.ts +13 -9
  11. package/front_end/core/common/ColorConverter.ts +9 -7
  12. package/front_end/core/common/Gzip.ts +1 -1
  13. package/front_end/core/common/MapWithDefault.ts +5 -3
  14. package/front_end/core/common/ResourceType.ts +0 -12
  15. package/front_end/core/common/ReturnToPanel.ts +6 -4
  16. package/front_end/core/common/Trie.ts +4 -2
  17. package/front_end/core/host/AidaClient.ts +3 -3
  18. package/front_end/core/host/GdpClient.ts +7 -5
  19. package/front_end/core/host/InspectorFrontendHostAPI.ts +7 -5
  20. package/front_end/core/host/Platform.ts +5 -3
  21. package/front_end/core/host/UserMetrics.ts +6 -4
  22. package/front_end/core/platform/ArrayUtilities.ts +1 -1
  23. package/front_end/core/platform/StringUtilities.ts +34 -31
  24. package/front_end/core/root/Runtime.ts +1 -1
  25. package/front_end/core/sdk/CSSMetadata.ts +6 -4
  26. package/front_end/core/sdk/CSSPropertyParser.ts +17 -13
  27. package/front_end/core/sdk/CSSPropertyParserMatchers.ts +19 -13
  28. package/front_end/core/sdk/ChildTargetManager.ts +35 -0
  29. package/front_end/core/sdk/DOMModel.ts +1 -1
  30. package/front_end/core/sdk/EventBreakpointsModel.ts +4 -2
  31. package/front_end/core/sdk/HttpReasonPhraseStrings.ts +4 -2
  32. package/front_end/core/sdk/NetworkManager.ts +8 -48
  33. package/front_end/core/sdk/NetworkRequest.ts +0 -28
  34. package/front_end/core/sdk/PageResourceLoader.ts +1 -1
  35. package/front_end/core/sdk/PreloadingModel.ts +22 -18
  36. package/front_end/core/sdk/RehydratingConnection.ts +1 -1
  37. package/front_end/core/sdk/RehydratingObject.ts +1 -1
  38. package/front_end/core/sdk/RemoteObject.ts +1 -1
  39. package/front_end/core/sdk/ResourceTreeModel.ts +2 -0
  40. package/front_end/core/sdk/ScreenCaptureModel.ts +24 -20
  41. package/front_end/core/sdk/Target.ts +7 -1
  42. package/front_end/core/sdk/TraceObject.ts +2 -2
  43. package/front_end/entrypoints/formatter_worker/Substitute.ts +6 -4
  44. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +24 -16
  45. package/front_end/entrypoints/inspector_main/OutermostTargetSelector.ts +2 -1
  46. package/front_end/entrypoints/main/MainImpl.ts +6 -4
  47. package/front_end/generated/InspectorBackendCommands.js +2 -2
  48. package/front_end/generated/protocol-mapping.d.ts +3 -2
  49. package/front_end/generated/protocol-proxy-api.d.ts +3 -1
  50. package/front_end/generated/protocol.ts +7 -1
  51. package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +55 -14
  52. package/front_end/models/ai_assistance/agents/StylingAgent.ts +83 -222
  53. package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +23 -0
  54. package/front_end/models/ai_assistance/performance/AIContext.ts +19 -4
  55. package/front_end/models/ai_code_completion/AiCodeCompletion.ts +4 -2
  56. package/front_end/models/autofill_manager/AutofillManager.ts +4 -2
  57. package/front_end/models/cpu_profile/CPUProfileDataModel.ts +1 -1
  58. package/front_end/models/crux-manager/CrUXManager.ts +1 -1
  59. package/front_end/models/extensions/HostUrlPattern.ts +13 -5
  60. package/front_end/models/issues_manager/CookieDeprecationMetadataIssue.ts +1 -1
  61. package/front_end/models/issues_manager/CookieIssue.ts +2 -2
  62. package/front_end/models/issues_manager/MarkdownIssueDescription.ts +1 -1
  63. package/front_end/models/issues_manager/SharedDictionaryIssue.ts +20 -0
  64. package/front_end/models/issues_manager/descriptions/sharedDictionaryWriteErrorInvalidTTLField.md +1 -0
  65. package/front_end/models/issues_manager/descriptions/sharedDictionaryWriteErrorNonIntegerTTLField.md +1 -0
  66. package/front_end/models/javascript_metadata/NativeFunctions.js +8 -0
  67. package/front_end/models/network_time_calculator/Calculator.ts +4 -2
  68. package/front_end/models/network_time_calculator/RequestTimeRanges.ts +6 -4
  69. package/front_end/models/source_map_scopes/NamesResolver.ts +7 -5
  70. package/front_end/models/text_utils/ContentProvider.ts +6 -4
  71. package/front_end/models/trace/extras/TraceTree.ts +1 -1
  72. package/front_end/models/trace/handlers/FramesHandler.ts +7 -5
  73. package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +13 -7
  74. package/front_end/models/trace/handlers/MetaHandler.ts +16 -14
  75. package/front_end/models/trace/handlers/NetworkRequestsHandler.ts +20 -8
  76. package/front_end/models/trace/handlers/helpers.ts +1 -1
  77. package/front_end/models/trace/handlers/types.ts +23 -19
  78. package/front_end/models/trace/helpers/Timing.ts +4 -2
  79. package/front_end/models/trace/helpers/Trace.ts +8 -4
  80. package/front_end/models/trace/insights/DocumentLatency.ts +1 -1
  81. package/front_end/models/trace/insights/INPBreakdown.ts +13 -2
  82. package/front_end/models/trace/insights/LCPBreakdown.ts +14 -2
  83. package/front_end/models/trace/insights/NetworkDependencyTree.ts +2 -2
  84. package/front_end/models/trace/types/File.ts +12 -8
  85. package/front_end/models/trace/types/Timing.ts +1 -1
  86. package/front_end/models/trace/types/TraceEvents.ts +37 -23
  87. package/front_end/models/trace_source_maps_resolver/SourceMapsResolver.ts +1 -1
  88. package/front_end/panels/ai_assistance/components/MarkdownRendererWithCodeBlock.ts +12 -10
  89. package/front_end/panels/application/KeyValueStorageItemsView.ts +31 -33
  90. package/front_end/panels/application/components/InterestGroupAccessGrid.ts +6 -11
  91. package/front_end/panels/application/components/OriginTrialTreeView.ts +7 -5
  92. package/front_end/panels/application/components/PermissionsPolicySection.ts +1 -0
  93. package/front_end/panels/application/components/ReportsGrid.ts +4 -10
  94. package/front_end/panels/application/components/SharedStorageAccessGrid.ts +5 -13
  95. package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +1 -1
  96. package/front_end/panels/application/preloading/components/PreloadingGrid.ts +3 -7
  97. package/front_end/panels/application/preloading/components/PreloadingString.ts +2 -2
  98. package/front_end/panels/application/preloading/components/RuleSetGrid.ts +3 -10
  99. package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +4 -2
  100. package/front_end/panels/browser_debugger/browser_debugger-meta.ts +7 -5
  101. package/front_end/panels/changes/ChangesSidebar.ts +97 -95
  102. package/front_end/panels/changes/changesSidebar.css +3 -0
  103. package/front_end/panels/console/ConsoleView.ts +2 -2
  104. package/front_end/panels/developer_resources/DeveloperResourcesListView.ts +22 -35
  105. package/front_end/panels/elements/ComputedStyleWidget.ts +1 -1
  106. package/front_end/panels/elements/ElementStatePaneWidget.ts +12 -0
  107. package/front_end/panels/elements/ElementsTreeElement.ts +9 -5
  108. package/front_end/panels/elements/ElementsTreeOutline.ts +11 -8
  109. package/front_end/panels/elements/PropertyRenderer.ts +19 -15
  110. package/front_end/panels/elements/StylePropertyTreeElement.ts +6 -4
  111. package/front_end/panels/elements/StylesSidebarPane.ts +2 -2
  112. package/front_end/panels/elements/components/AccessibilityTreeNode.ts +4 -2
  113. package/front_end/panels/elements/components/AdornerManager.ts +5 -3
  114. package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +6 -4
  115. package/front_end/panels/media/PlayerPropertiesView.ts +1 -1
  116. package/front_end/panels/network/NetworkDataGridNode.ts +2 -44
  117. package/front_end/panels/network/NetworkLogView.ts +6 -4
  118. package/front_end/panels/network/RequestPreviewView.ts +0 -7
  119. package/front_end/panels/network/components/RequestHeadersView.ts +0 -6
  120. package/front_end/panels/network/components/components.ts +0 -2
  121. package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +1 -1
  122. package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +4 -2
  123. package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +12 -19
  124. package/front_end/panels/search/SearchResultsPane.ts +2 -3
  125. package/front_end/panels/security/IPProtectionView.ts +1 -1
  126. package/front_end/panels/settings/emulation/components/userAgentClientHintsForm.css +4 -0
  127. package/front_end/panels/settings/emulation/utils/StructuredHeaders.ts +45 -37
  128. package/front_end/panels/sources/BreakpointsViewUtils.ts +11 -9
  129. package/front_end/panels/sources/DebuggerPlugin.ts +8 -4
  130. package/front_end/panels/sources/SourcesPanel.ts +1 -1
  131. package/front_end/panels/sources/UISourceCodeFrame.ts +1 -1
  132. package/front_end/panels/timeline/CompatibilityTracksAppender.ts +4 -2
  133. package/front_end/panels/timeline/CountersGraph.ts +12 -5
  134. package/front_end/panels/timeline/EasterEgg.d.ts +5 -3
  135. package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +8 -6
  136. package/front_end/panels/timeline/ModificationsManager.ts +5 -3
  137. package/front_end/panels/timeline/ThreadAppender.ts +7 -5
  138. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +10 -8
  139. package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +1 -1
  140. package/front_end/panels/timeline/TimelinePanel.ts +10 -8
  141. package/front_end/panels/timeline/TimelineSelection.ts +4 -2
  142. package/front_end/panels/timeline/TimelineUIUtils.ts +5 -3
  143. package/front_end/panels/timeline/components/BreadcrumbsUI.ts +6 -4
  144. package/front_end/panels/timeline/components/Utils.ts +1 -1
  145. package/front_end/panels/timeline/overlays/OverlaysImpl.ts +5 -3
  146. package/front_end/panels/timeline/utils/Helpers.ts +1 -1
  147. package/front_end/panels/utils/utils.ts +1 -7
  148. package/front_end/services/trace_bounds/TraceBounds.ts +4 -2
  149. package/front_end/services/tracing/PerformanceTracing.ts +1 -1
  150. package/front_end/third_party/chromium/README.chromium +1 -1
  151. package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
  152. package/front_end/third_party/codemirror.next/chunk/codemirror.js.map +1 -1
  153. package/front_end/third_party/codemirror.next/chunk/php.js +1 -1
  154. package/front_end/third_party/codemirror.next/chunk/php.js.map +1 -1
  155. package/front_end/third_party/codemirror.next/package.json +3 -2
  156. package/front_end/third_party/puppeteer/README.chromium +2 -2
  157. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.d.ts +8 -10
  158. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.d.ts.map +1 -1
  159. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.js +8 -10
  160. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.js.map +1 -1
  161. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts +28 -30
  162. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts.map +1 -1
  163. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js +27 -29
  164. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js.map +1 -1
  165. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.d.ts +34 -38
  166. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.d.ts.map +1 -1
  167. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js +34 -38
  168. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js.map +1 -1
  169. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts +8 -1
  170. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  171. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js +12 -14
  172. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js.map +1 -1
  173. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts +92 -108
  174. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts.map +1 -1
  175. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js +33 -39
  176. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js.map +1 -1
  177. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.d.ts.map +1 -1
  178. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js +5 -3
  179. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js.map +1 -1
  180. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.d.ts.map +1 -1
  181. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js +1 -1
  182. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js.map +1 -1
  183. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.d.ts +4 -2
  184. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.d.ts.map +1 -1
  185. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.js +14 -5
  186. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.js.map +1 -1
  187. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts +1 -0
  188. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts.map +1 -1
  189. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js +12 -6
  190. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js.map +1 -1
  191. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.d.ts.map +1 -1
  192. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js +24 -2
  193. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js.map +1 -1
  194. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Realm.d.ts +2 -2
  195. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.d.ts +1 -0
  196. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.d.ts.map +1 -1
  197. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.js +3 -0
  198. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.js.map +1 -1
  199. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts +13 -22
  200. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  201. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.js +13 -22
  202. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.js.map +1 -1
  203. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.d.ts +6 -8
  204. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.d.ts.map +1 -1
  205. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.js +6 -8
  206. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.js.map +1 -1
  207. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.d.ts +1 -1
  208. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.js +1 -1
  209. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts +1 -1
  210. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts +1 -1
  211. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  212. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js +6 -3
  213. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js.map +1 -1
  214. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.d.ts +5 -7
  215. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.d.ts.map +1 -1
  216. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.js +5 -7
  217. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.js.map +1 -1
  218. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.d.ts +3 -3
  219. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +3 -3
  220. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js.map +1 -1
  221. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts +2 -2
  222. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +188 -224
  223. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +140 -166
  224. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.d.ts +8 -10
  225. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.d.ts.map +1 -1
  226. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.js +8 -10
  227. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.js.map +1 -1
  228. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts +28 -30
  229. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts.map +1 -1
  230. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js +27 -29
  231. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js.map +1 -1
  232. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.d.ts +34 -38
  233. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.d.ts.map +1 -1
  234. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js +34 -38
  235. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js.map +1 -1
  236. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts +8 -1
  237. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  238. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.js +12 -14
  239. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.js.map +1 -1
  240. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts +92 -108
  241. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts.map +1 -1
  242. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js +33 -39
  243. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js.map +1 -1
  244. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.d.ts.map +1 -1
  245. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js +5 -3
  246. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js.map +1 -1
  247. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.d.ts.map +1 -1
  248. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js +1 -1
  249. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js.map +1 -1
  250. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.d.ts +4 -2
  251. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.d.ts.map +1 -1
  252. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.js +15 -6
  253. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.js.map +1 -1
  254. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts +1 -0
  255. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts.map +1 -1
  256. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js +12 -6
  257. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js.map +1 -1
  258. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.d.ts.map +1 -1
  259. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js +24 -2
  260. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js.map +1 -1
  261. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.d.ts +1 -0
  262. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.d.ts.map +1 -1
  263. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.js +3 -0
  264. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.js.map +1 -1
  265. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts +13 -22
  266. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  267. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.js +13 -22
  268. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.js.map +1 -1
  269. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.d.ts +6 -8
  270. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.d.ts.map +1 -1
  271. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.js +6 -8
  272. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.js.map +1 -1
  273. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.d.ts +1 -1
  274. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.js +1 -1
  275. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts +1 -1
  276. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  277. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js +6 -3
  278. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js.map +1 -1
  279. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.d.ts +5 -7
  280. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.d.ts.map +1 -1
  281. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.js +5 -7
  282. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.js.map +1 -1
  283. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.d.ts +3 -3
  284. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +3 -3
  285. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js.map +1 -1
  286. package/front_end/third_party/puppeteer/package/lib/types.d.ts +188 -224
  287. package/front_end/third_party/puppeteer/package/package.json +3 -3
  288. package/front_end/third_party/puppeteer/package/src/api/Dialog.ts +8 -10
  289. package/front_end/third_party/puppeteer/package/src/api/ElementHandle.ts +27 -29
  290. package/front_end/third_party/puppeteer/package/src/api/Frame.ts +34 -38
  291. package/front_end/third_party/puppeteer/package/src/api/HTTPRequest.ts +17 -14
  292. package/front_end/third_party/puppeteer/package/src/api/Page.ts +92 -108
  293. package/front_end/third_party/puppeteer/package/src/bidi/Browser.ts +5 -3
  294. package/front_end/third_party/puppeteer/package/src/bidi/Frame.ts +5 -1
  295. package/front_end/third_party/puppeteer/package/src/bidi/HTTPRequest.ts +28 -3
  296. package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +16 -7
  297. package/front_end/third_party/puppeteer/package/src/bidi/core/Browser.ts +28 -2
  298. package/front_end/third_party/puppeteer/package/src/cdp/HTTPRequest.ts +4 -0
  299. package/front_end/third_party/puppeteer/package/src/cdp/PredefinedNetworkConditions.ts +13 -22
  300. package/front_end/third_party/puppeteer/package/src/common/Device.ts +6 -8
  301. package/front_end/third_party/puppeteer/package/src/generated/version.ts +1 -1
  302. package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +6 -3
  303. package/front_end/third_party/puppeteer/package/src/node/PuppeteerNode.ts +5 -7
  304. package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
  305. package/front_end/ui/components/chrome_link/ChromeLink.ts +4 -2
  306. package/front_end/ui/components/dialogs/Dialog.ts +13 -9
  307. package/front_end/ui/components/highlighting/HighlightElement.ts +77 -0
  308. package/front_end/ui/components/highlighting/HighlightManager.ts +37 -0
  309. package/front_end/ui/components/highlighting/highlighting.ts +2 -0
  310. package/front_end/ui/components/markdown_view/MarkdownImagesMap.ts +5 -3
  311. package/front_end/ui/components/markdown_view/MarkdownLinksMap.ts +5 -3
  312. package/front_end/ui/components/menus/SelectMenu.ts +6 -4
  313. package/front_end/ui/components/survey_link/SurveyLink.ts +4 -2
  314. package/front_end/ui/components/text_editor/config.ts +10 -6
  315. package/front_end/ui/components/text_editor/javascript.ts +8 -4
  316. package/front_end/ui/legacy/ForwardedInputEventHandler.ts +4 -2
  317. package/front_end/ui/legacy/GlassPane.ts +1 -1
  318. package/front_end/ui/legacy/SettingsUI.ts +1 -5
  319. package/front_end/ui/legacy/Treeoutline.ts +12 -33
  320. package/front_end/ui/legacy/UIUtils.ts +19 -1
  321. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +12 -10
  322. package/front_end/ui/legacy/components/cookie_table/CookiesTable.ts +30 -32
  323. package/front_end/ui/legacy/components/data_grid/DataGrid.ts +1 -1
  324. package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +25 -25
  325. package/front_end/ui/legacy/components/data_grid/dataGrid.css +5 -0
  326. package/front_end/ui/legacy/components/inline_editor/AnimationTimingModel.ts +4 -2
  327. package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +4 -2
  328. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +8 -6
  329. package/front_end/ui/legacy/components/perf_ui/PieChart.ts +6 -4
  330. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +3 -3
  331. package/front_end/ui/legacy/components/source_frame/XMLView.ts +22 -16
  332. package/front_end/ui/legacy/components/source_frame/xmlView.css +0 -2
  333. package/front_end/ui/legacy/components/utils/Linkifier.ts +6 -4
  334. package/front_end/ui/visual_logging/Debugging.ts +10 -6
  335. package/front_end/ui/visual_logging/KnownContextValues.ts +1 -3
  336. package/inspector_overlay/common.ts +5 -3
  337. package/inspector_overlay/highlight_grid_common.ts +1 -1
  338. package/package.json +1 -1
  339. package/front_end/Images/src/bundle.svg +0 -3
  340. package/front_end/panels/network/components/WebBundleInfoView.css +0 -27
  341. package/front_end/panels/network/components/WebBundleInfoView.ts +0 -95
@@ -362,7 +362,7 @@ export const CubicBezierKeywordValues = new Map([
362
362
  ['ease-out', 'cubic-bezier(0, 0, 0.58, 1)'],
363
363
  ]);
364
364
 
365
- // CSS-wide keywords.
365
+ /** CSS-wide keywords. **/
366
366
  export const enum CSSWideKeyword {
367
367
  INHERIT = 'inherit',
368
368
  INITIAL = 'initial',
@@ -370,8 +370,10 @@ export const enum CSSWideKeyword {
370
370
  REVERT_LAYER = 'revert-layer',
371
371
  UNSET = 'unset',
372
372
  }
373
- // Spec: https://drafts.csswg.org/css-cascade/#defaulting-keywords
374
- // https://drafts.csswg.org/css-cascade-5/#revert-layer
373
+ /**
374
+ * Spec: https://drafts.csswg.org/css-cascade/#defaulting-keywords
375
+ * https://drafts.csswg.org/css-cascade-5/#revert-layer
376
+ **/
375
377
  export const CSSWideKeywords: CSSWideKeyword[] = [
376
378
  CSSWideKeyword.INHERIT,
377
379
  CSSWideKeyword.INITIAL,
@@ -380,7 +382,7 @@ export const CSSWideKeywords: CSSWideKeyword[] = [
380
382
  CSSWideKeyword.UNSET,
381
383
  ];
382
384
 
383
- // https://www.w3.org/TR/css-anchor-position-1/#typedef-try-size
385
+ /** https://www.w3.org/TR/css-anchor-position-1/#typedef-try-size **/
384
386
  export const enum PositionTryOrderKeyword {
385
387
  NORMAL = 'normal',
386
388
  MOST_HEIGHT = 'most-height',
@@ -309,11 +309,11 @@ class ComputedTextChunk {
309
309
  return this.#cachedComputedText;
310
310
  }
311
311
 
312
- // If the match is top-level, i.e. is an outermost subexpression in the property value, count the number of outermost
313
- // subexpressions after applying any potential substitutions.
312
+ // If the match is top-level, i.e. is an outermost sub-expression in the property value, count the number of outermost
313
+ // sub-expressions after applying any potential substitutions.
314
314
  get topLevelValueCount(): number {
315
315
  if (this.match.node.parent?.name !== 'Declaration') {
316
- // Not a top-level matchh.
316
+ // Not a top-level match.
317
317
  return 0;
318
318
  }
319
319
  const computedText = this.computedText;
@@ -332,12 +332,14 @@ class ComputedTextChunk {
332
332
  }
333
333
  }
334
334
 
335
- // This class constructs the "computed" text from the input property text, i.e., it will strip comments and substitute
336
- // var() functions if possible. It's intended for use during the bottom-up tree matching process. The original text is
337
- // not modified. Instead, computed text slices are produced on the fly. During bottom-up matching, the sequence of
338
- // top-level comments and var() matches will be recorded. This produces an ordered sequence of text pieces that need to
339
- // be substituted into the original text. When a computed text slice is requested, it is generated by piecing together
340
- // original and computed slices as required.
335
+ /**
336
+ * This class constructs the "computed" text from the input property text, i.e., it will strip comments and substitute
337
+ * var() functions if possible. It's intended for use during the bottom-up tree matching process. The original text is
338
+ * not modified. Instead, computed text slices are produced on the fly. During bottom-up matching, the sequence of
339
+ * top-level comments and var() matches will be recorded. This produces an ordered sequence of text pieces that need to
340
+ * be substituted into the original text. When a computed text slice is requested, it is generated by piecing together
341
+ * original and computed slices as required.
342
+ **/
341
343
  export class ComputedText {
342
344
  readonly #chunks: ComputedTextChunk[] = [];
343
345
  readonly text: string;
@@ -486,10 +488,12 @@ export class ComputedText {
486
488
  }
487
489
  }
488
490
 
489
- // This function determines whether concatenating two pieces of text requires any spacing inbetween. For example, there
490
- // shouldn't be any space between 'var' and '(', but there should be a space between '1px' and 'solid'. The node
491
- // sequences that make up the pieces of text may contain non-text nodes/trees. Any such element inbetween the texts is
492
- // ignored for the spacing requirement.
491
+ /**
492
+ * This function determines whether concatenating two pieces of text requires any spacing in between. For example, there
493
+ * shouldn't be any space between 'var' and '(', but there should be a space between '1px' and 'solid'. The node
494
+ * sequences that make up the pieces of text may contain non-text nodes/trees. Any such element in between the texts is
495
+ * ignored for the spacing requirement.
496
+ **/
493
497
  export function requiresSpace(a: string, b: string): boolean;
494
498
  export function requiresSpace(a: Node[], b: Node[]): boolean;
495
499
  export function requiresSpace(a: Node[]|string|undefined, b: Node[]|string|undefined): boolean {
@@ -178,13 +178,15 @@ function getCssEvaluationElement(): HTMLElement {
178
178
  return cssEvaluationElement;
179
179
  }
180
180
 
181
- // These functions use an element in the frontend to evaluate CSS. The advantage
182
- // of this is that it is synchronous and doesn't require a CDP method. The
183
- // disadvantage is it lacks context that would allow substitutions such as
184
- // `var()` and `calc()` to be resolved correctly, and if the user is doing
185
- // remote debugging there is a possibility that the CSS behavior is different
186
- // between the two browser versions. We use it for type checking after
187
- // substitutions (but not for actual evaluation) and for applying units.
181
+ /**
182
+ * These functions use an element in the frontend to evaluate CSS. The advantage
183
+ * of this is that it is synchronous and doesn't require a CDP method. The
184
+ * disadvantage is it lacks context that would allow substitutions such as
185
+ * `var()` and `calc()` to be resolved correctly, and if the user is doing
186
+ * remote debugging there is a possibility that the CSS behavior is different
187
+ * between the two browser versions. We use it for type checking after
188
+ * substitutions (but not for actual evaluation) and for applying units.
189
+ **/
188
190
  export function localEvalCSS(value: string, type: string): string|null {
189
191
  const element = getCssEvaluationElement();
190
192
  element.setAttribute('data-value', value);
@@ -192,9 +194,11 @@ export function localEvalCSS(value: string, type: string): string|null {
192
194
  return element.computedStyleMap().get('--evaluation')?.toString() ?? null;
193
195
  }
194
196
 
195
- // It is important to establish whether a type is valid, because if it is not,
196
- // the current behavior of blink is to ignore the fallback and parse as a
197
- // raw string, returning '' if the attribute is not set.
197
+ /**
198
+ * It is important to establish whether a type is valid, because if it is not,
199
+ * the current behavior of blink is to ignore the fallback and parse as a
200
+ * raw string, returning '' if the attribute is not set.
201
+ **/
198
202
  export function isValidCSSType(type: string): boolean {
199
203
  const element = getCssEvaluationElement();
200
204
  element.setAttribute('data-custom-expr', `attr(data-nonexistent ${type}, "good")`);
@@ -1133,8 +1137,10 @@ export class GridTemplateMatcher extends matcherBase(GridTemplateMatch) {
1133
1137
  // `needClosingLineNames` tracks if the current row can still consume an optional LineNames,
1134
1138
  // which will decide if we should start a new line or not when a LineNames is encountered.
1135
1139
  let needClosingLineNames = false;
1136
- // Gather row definitions of [<line-names>? <string> <track-size>? <line-names>?], which
1137
- // be rendered into separate lines.
1140
+ /**
1141
+ * Gather row definitions of [<line-names>? <string> <track-size>? <line-names>?], which
1142
+ * be rendered into separate lines.
1143
+ **/
1138
1144
  function parseNodes(nodes: CodeMirror.SyntaxNode[], varParsingMode = false): void {
1139
1145
  for (const curNode of nodes) {
1140
1146
  if (matching.getMatch(curNode) instanceof BaseVariableMatch) {
@@ -1247,7 +1253,7 @@ export class AnchorFunctionMatcher extends matcherBase(AnchorFunctionMatch) {
1247
1253
  }
1248
1254
  }
1249
1255
 
1250
- // For linking `position-anchor: --anchor-name`.
1256
+ /** For linking `position-anchor: --anchor-name`. **/
1251
1257
  export class PositionAnchorMatch implements Match {
1252
1258
  constructor(readonly text: string, readonly matching: BottomUpTreeMatching, readonly node: CodeMirror.SyntaxNode) {
1253
1259
  }
@@ -12,6 +12,8 @@ import type * as ProtocolClient from '../protocol_client/protocol_client.js';
12
12
  import {ParallelConnection} from './Connections.js';
13
13
  import {PrimaryPageChangeType, ResourceTreeModel} from './ResourceTreeModel.js';
14
14
  import {SDKModel} from './SDKModel.js';
15
+ import {SecurityOriginManager} from './SecurityOriginManager.js';
16
+ import {StorageKeyManager} from './StorageKeyManager.js';
15
17
  import {Capability, type Target, Type} from './Target.js';
16
18
  import {Events as TargetManagerEvents, TargetManager} from './TargetManager.js';
17
19
 
@@ -204,6 +206,39 @@ export class ChildTargetManager extends SDKModel<EventTypes> implements Protocol
204
206
  if (waitingForDebugger) {
205
207
  void target.runtimeAgent().invoke_runIfWaitingForDebugger();
206
208
  }
209
+
210
+ // For top-level workers (those not attached to a frame), we need to
211
+ // initialize their storage context manually. The `Capability.STORAGE` is
212
+ // only granted in `Target.ts` to workers that are not parented by a frame,
213
+ // which makes this check safe. Frame-associated workers have their storage
214
+ // managed by ResourceTreeModel.
215
+ if (type !== Type.FRAME && target.hasAllCapabilities(Capability.STORAGE)) {
216
+ await this.initializeStorage(target);
217
+ }
218
+ }
219
+
220
+ private async initializeStorage(target: Target): Promise<void> {
221
+ const storageAgent = target.storageAgent();
222
+ const response = await storageAgent.invoke_getStorageKey({});
223
+
224
+ const storageKey = response.storageKey;
225
+ if (response.getError() || !storageKey) {
226
+ console.error(`Failed to get storage key for target ${target.id()}: ${response.getError()}`);
227
+ return;
228
+ }
229
+
230
+ const storageKeyManager = target.model(StorageKeyManager);
231
+ if (storageKeyManager) {
232
+ storageKeyManager.setMainStorageKey(storageKey);
233
+ storageKeyManager.updateStorageKeys(new Set([storageKey]));
234
+ }
235
+
236
+ const securityOriginManager = target.model(SecurityOriginManager);
237
+ if (securityOriginManager) {
238
+ const origin = new URL(storageKey).origin;
239
+ securityOriginManager.setMainSecurityOrigin(origin, '');
240
+ securityOriginManager.updateSecurityOrigins(new Set([origin]));
241
+ }
207
242
  }
208
243
 
209
244
  detachedFromTarget({sessionId}: Protocol.Target.DetachedFromTargetEvent): void {
@@ -49,7 +49,7 @@ import {SDKModel} from './SDKModel.js';
49
49
  import {Capability, type Target} from './Target.js';
50
50
  import {TargetManager} from './TargetManager.js';
51
51
 
52
- // Keep this list in sync with https://w3c.github.io/aria/#state_prop_def
52
+ /** Keep this list in sync with https://w3c.github.io/aria/#state_prop_def **/
53
53
  export const ARIA_ATTRIBUTES = new Set<string>([
54
54
  'role',
55
55
  'aria-activedescendant',
@@ -51,8 +51,10 @@ export class EventBreakpointsModel extends SDKModel<void> {
51
51
  }
52
52
  }
53
53
 
54
- // This implementation (as opposed to similar class in DOMDebuggerModel) is for
55
- // instrumentation breakpoints in targets that run JS but do not have a DOM.
54
+ /**
55
+ * This implementation (as opposed to similar class in DOMDebuggerModel) is for
56
+ * instrumentation breakpoints in targets that run JS but do not have a DOM.
57
+ **/
56
58
  class EventListenerBreakpoint extends CategorizedBreakpoint {
57
59
  override setEnabled(enabled: boolean): void {
58
60
  if (this.enabled() === enabled) {
@@ -4,8 +4,10 @@
4
4
 
5
5
  import * as i18n from '../i18n/i18n.js';
6
6
 
7
- // Reason phrase sources
8
- // See https://www.rfc-editor.org/rfc/rfc9110.html#name-status-codes
7
+ /**
8
+ * Reason phrase sources
9
+ * See https://www.rfc-editor.org/rfc/rfc9110.html#name-status-codes
10
+ **/
9
11
  export function getStatusText(statusCode: number): string {
10
12
  const statusTextLookup: Record<number, string> = {
11
13
  100: 'Continue',
@@ -23,8 +23,6 @@ import {
23
23
  type IncludedCookieWithReason,
24
24
  type NameValue,
25
25
  NetworkRequest,
26
- type WebBundleInfo,
27
- type WebBundleInnerRequestInfo
28
26
  } from './NetworkRequest.js';
29
27
  import {SDKModel} from './SDKModel.js';
30
28
  import {Capability, type Target} from './Target.js';
@@ -1502,44 +1500,20 @@ export class NetworkDispatcher implements ProtocolProxyApi.NetworkDispatcher {
1502
1500
  request.setTrustTokenOperationDoneEvent(event);
1503
1501
  }
1504
1502
 
1505
- subresourceWebBundleMetadataReceived({requestId, urls}: Protocol.Network.SubresourceWebBundleMetadataReceivedEvent):
1506
- void {
1507
- const extraInfoBuilder = this.getExtraInfoBuilder(requestId);
1508
- extraInfoBuilder.setWebBundleInfo({resourceUrls: urls as Platform.DevToolsPath.UrlString[]});
1509
- const finalRequest = extraInfoBuilder.finalRequest();
1510
- if (finalRequest) {
1511
- this.updateNetworkRequest(finalRequest);
1512
- }
1503
+ subresourceWebBundleMetadataReceived(): void {
1504
+ // TODO: remove implementation after deleting this methods from definition in Network.pdl
1513
1505
  }
1514
1506
 
1515
- subresourceWebBundleMetadataError({requestId, errorMessage}: Protocol.Network.SubresourceWebBundleMetadataErrorEvent):
1516
- void {
1517
- const extraInfoBuilder = this.getExtraInfoBuilder(requestId);
1518
- extraInfoBuilder.setWebBundleInfo({errorMessage});
1519
- const finalRequest = extraInfoBuilder.finalRequest();
1520
- if (finalRequest) {
1521
- this.updateNetworkRequest(finalRequest);
1522
- }
1507
+ subresourceWebBundleMetadataError(): void {
1508
+ // TODO: remove implementation after deleting this methods from definition in Network.pdl
1523
1509
  }
1524
1510
 
1525
- subresourceWebBundleInnerResponseParsed({innerRequestId, bundleRequestId}:
1526
- Protocol.Network.SubresourceWebBundleInnerResponseParsedEvent): void {
1527
- const extraInfoBuilder = this.getExtraInfoBuilder(innerRequestId);
1528
- extraInfoBuilder.setWebBundleInnerRequestInfo({bundleRequestId});
1529
- const finalRequest = extraInfoBuilder.finalRequest();
1530
- if (finalRequest) {
1531
- this.updateNetworkRequest(finalRequest);
1532
- }
1511
+ subresourceWebBundleInnerResponseParsed(): void {
1512
+ // TODO: remove implementation after deleting this methods from definition in Network.pdl
1533
1513
  }
1534
1514
 
1535
- subresourceWebBundleInnerResponseError({innerRequestId, errorMessage}:
1536
- Protocol.Network.SubresourceWebBundleInnerResponseErrorEvent): void {
1537
- const extraInfoBuilder = this.getExtraInfoBuilder(innerRequestId);
1538
- extraInfoBuilder.setWebBundleInnerRequestInfo({errorMessage});
1539
- const finalRequest = extraInfoBuilder.finalRequest();
1540
- if (finalRequest) {
1541
- this.updateNetworkRequest(finalRequest);
1542
- }
1515
+ subresourceWebBundleInnerResponseError(): void {
1516
+ // TODO: remove implementation after deleting this methods from definition in Network.pdl
1543
1517
  }
1544
1518
 
1545
1519
  reportingApiReportAdded(data: Protocol.Network.ReportingApiReportAddedEvent): void {
@@ -2151,8 +2125,6 @@ class ExtraInfoBuilder {
2151
2125
  #responseExtraInfos: Array<ExtraResponseInfo|null> = [];
2152
2126
  #responseEarlyHintsHeaders: NameValue[] = [];
2153
2127
  #finished = false;
2154
- #webBundleInfo: WebBundleInfo|null = null;
2155
- #webBundleInnerRequestInfo: WebBundleInnerRequestInfo|null = null;
2156
2128
 
2157
2129
  addRequest(req: NetworkRequest): void {
2158
2130
  this.#requests.push(req);
@@ -2189,16 +2161,6 @@ class ExtraInfoBuilder {
2189
2161
  this.updateFinalRequest();
2190
2162
  }
2191
2163
 
2192
- setWebBundleInfo(info: WebBundleInfo): void {
2193
- this.#webBundleInfo = info;
2194
- this.updateFinalRequest();
2195
- }
2196
-
2197
- setWebBundleInnerRequestInfo(info: WebBundleInnerRequestInfo): void {
2198
- this.#webBundleInnerRequestInfo = info;
2199
- this.updateFinalRequest();
2200
- }
2201
-
2202
2164
  finished(): void {
2203
2165
  this.#finished = true;
2204
2166
  // We may have missed responseReceived event in case of failure.
@@ -2260,8 +2222,6 @@ class ExtraInfoBuilder {
2260
2222
  return;
2261
2223
  }
2262
2224
  const finalRequest = this.finalRequest();
2263
- finalRequest?.setWebBundleInfo(this.#webBundleInfo);
2264
- finalRequest?.setWebBundleInnerRequestInfo(this.#webBundleInnerRequestInfo);
2265
2225
  finalRequest?.setEarlyHintsHeaders(this.#responseEarlyHintsHeaders);
2266
2226
  }
2267
2227
  }
@@ -236,8 +236,6 @@ export class NetworkRequest extends Common.ObjectWrapper.ObjectWrapper<EventType
236
236
  #initialPriority: Protocol.Network.ResourcePriority|null = null;
237
237
  #currentPriority: Protocol.Network.ResourcePriority|null = null;
238
238
  #signedExchangeInfo: Protocol.Network.SignedExchangeInfo|null = null;
239
- #webBundleInfo: WebBundleInfo|null = null;
240
- #webBundleInnerRequestInfo: WebBundleInnerRequestInfo|null = null;
241
239
  #resourceType: Common.ResourceType.ResourceType = Common.ResourceType.resourceTypes.Other;
242
240
  #contentData: Promise<TextUtils.ContentData.ContentDataOrError>|null = null;
243
241
  #streamingContentData: Promise<TextUtils.StreamingContentData.StreamingContentDataOrError>|null = null;
@@ -1500,22 +1498,6 @@ export class NetworkRequest extends Common.ObjectWrapper.ObjectWrapper<EventType
1500
1498
  return this.#signedExchangeInfo;
1501
1499
  }
1502
1500
 
1503
- setWebBundleInfo(info: WebBundleInfo|null): void {
1504
- this.#webBundleInfo = info;
1505
- }
1506
-
1507
- webBundleInfo(): WebBundleInfo|null {
1508
- return this.#webBundleInfo;
1509
- }
1510
-
1511
- setWebBundleInnerRequestInfo(info: WebBundleInnerRequestInfo|null): void {
1512
- this.#webBundleInnerRequestInfo = info;
1513
- }
1514
-
1515
- webBundleInnerRequestInfo(): WebBundleInnerRequestInfo|null {
1516
- return this.#webBundleInnerRequestInfo;
1517
- }
1518
-
1519
1501
  async populateImageSource(image: HTMLImageElement): Promise<void> {
1520
1502
  const contentData = await this.requestContentData();
1521
1503
  if (TextUtils.ContentData.ContentData.isError(contentData)) {
@@ -2207,16 +2189,6 @@ export interface EarlyHintsInfo {
2207
2189
  responseHeaders: NameValue[];
2208
2190
  }
2209
2191
 
2210
- export interface WebBundleInfo {
2211
- resourceUrls?: Platform.DevToolsPath.UrlString[];
2212
- errorMessage?: string;
2213
- }
2214
-
2215
- export interface WebBundleInnerRequestInfo {
2216
- bundleRequestId?: string;
2217
- errorMessage?: string;
2218
- }
2219
-
2220
2192
  export type OverrideType = 'content'|'headers';
2221
2193
 
2222
2194
  export enum DirectSocketType {
@@ -59,7 +59,7 @@ export interface PageResource {
59
59
  duration: number|null;
60
60
  }
61
61
 
62
- // Used for revealing a resource.
62
+ /** Used for revealing a resource. **/
63
63
  export class ResourceKey {
64
64
  readonly key: string;
65
65
 
@@ -23,11 +23,13 @@ export interface WithId<I, V> {
23
23
  value: V;
24
24
  }
25
25
 
26
- // Holds preloading related information.
27
- //
28
- // - SpeculationRule rule sets
29
- // - Preloading attempts
30
- // - Relationship between rule sets and preloading attempts
26
+ /**
27
+ * Holds preloading related information.
28
+ *
29
+ * - SpeculationRule rule sets
30
+ * - Preloading attempts
31
+ * - Relationship between rule sets and preloading attempts
32
+ **/
31
33
  export class PreloadingModel extends SDKModel<EventTypes> {
32
34
  private agent: ProtocolProxyApi.PreloadApi;
33
35
  private loaderIds: Protocol.Network.LoaderId[] = [];
@@ -410,19 +412,21 @@ class RuleSetRegistry {
410
412
  }
411
413
  }
412
414
 
413
- // Protocol.Preload.PreloadingStatus|'NotTriggered'
414
- //
415
- // A renderer sends SpeculationCandidate to the browser process and the
416
- // browser process checks eligibilities, and starts PreloadingAttempt.
417
- //
418
- // In the frontend, "NotTriggered" is used to denote that a
419
- // PreloadingAttempt is waiting for at trigger event (eg:
420
- // mousedown/mouseover). All PreloadingAttempts will start off as
421
- // "NotTriggered", but "eager" preloading attempts (attempts not
422
- // actually waiting for any trigger) will be processed by the browser
423
- // immediately, and will not stay in this state for long.
424
- //
425
- // TODO(https://crbug.com/1384419): Add NotEligible.
415
+ /**
416
+ * Protocol.Preload.PreloadingStatus|'NotTriggered'
417
+ *
418
+ * A renderer sends SpeculationCandidate to the browser process and the
419
+ * browser process checks eligibilities, and starts PreloadingAttempt.
420
+ *
421
+ * In the frontend, "NotTriggered" is used to denote that a
422
+ * PreloadingAttempt is waiting for at trigger event (eg:
423
+ * mousedown/mouseover). All PreloadingAttempts will start off as
424
+ * "NotTriggered", but "eager" preloading attempts (attempts not
425
+ * actually waiting for any trigger) will be processed by the browser
426
+ * immediately, and will not stay in this state for long.
427
+ *
428
+ * TODO(https://crbug.com/1384419): Add NotEligible.
429
+ **/
426
430
  export const enum PreloadingStatus {
427
431
  NOT_TRIGGERED = 'NotTriggered',
428
432
  PENDING = 'Pending',
@@ -210,7 +210,7 @@ export class RehydratingConnection implements ProtocolClient.InspectorBackend.Co
210
210
  }
211
211
  }
212
212
 
213
- // Default rehydrating session with default responses.
213
+ /** Default rehydrating session with default responses. **/
214
214
  class RehydratingSessionBase {
215
215
  connection: RehydratingConnectionInterface|null = null;
216
216
 
@@ -4,7 +4,7 @@
4
4
 
5
5
  import type * as Protocol from '../../generated/protocol.js';
6
6
 
7
- // This object is emitted to ScriptParsed and also used in the RehydratingConnection
7
+ /** This object is emitted to ScriptParsed and also used in the RehydratingConnection **/
8
8
  export interface RehydratingScript extends Protocol.Debugger.ScriptParsedEvent {
9
9
  sourceText?: string;
10
10
  executionContextAuxData?: RehydratingExecutionContextAuxData;
@@ -9,7 +9,7 @@ import type {DOMPinnedWebIDLProp, DOMPinnedWebIDLType} from '../common/JavaScrip
9
9
  import type {DebuggerModel, FunctionDetails} from './DebuggerModel.js';
10
10
  import type {RuntimeModel} from './RuntimeModel.js';
11
11
 
12
- // This cannot be an interface due to "instanceof RemoteObject" checks in the code.
12
+ /** This cannot be an interface due to "instanceof RemoteObject" checks in the code. **/
13
13
  export abstract class RemoteObject {
14
14
  static fromLocalObject(value: unknown): RemoteObject {
15
15
  return new LocalJSONObject(value);
@@ -104,6 +104,8 @@ export class ResourceTreeModel extends SDKModel<EventTypes> {
104
104
  if (!this.framesInternal.has(frameId)) {
105
105
  return null;
106
106
  }
107
+
108
+ // TODO(crbug.com/445966299): Refactor to use `storageAgent().invoke_getStorageKey()` instead.
107
109
  const response = await this.storageAgent.invoke_getStorageKeyForFrame({frameId});
108
110
  if (response.getError() === 'Frame tree node for given frame not found') {
109
111
  return null;
@@ -15,8 +15,10 @@ export const enum ScreenshotMode {
15
15
  FULLPAGE = 'fullpage',
16
16
  }
17
17
 
18
- // This structure holds a specific `startScreencast` request's parameters
19
- // and its callbacks so that they can be re-started if needed.
18
+ /**
19
+ * This structure holds a specific `startScreencast` request's parameters
20
+ * and its callbacks so that they can be re-started if needed.
21
+ **/
20
22
  interface ScreencastOperation {
21
23
  id: number;
22
24
  request: {
@@ -35,24 +37,26 @@ interface ScreencastOperation {
35
37
  type ScreencastFrameCallback = ((arg0: Protocol.binary, arg1: Protocol.Page.ScreencastFrameMetadata) => void);
36
38
  type ScreencastVisibilityChangedCallback = ((arg0: boolean) => void);
37
39
 
38
- // Manages concurrent screencast requests by queuing and prioritizing.
39
- //
40
- // When startScreencast is invoked:
41
- // - If a screencast is currently active, the existing screencast's parameters and callbacks are
42
- // saved in the #screencastOperations array.
43
- // - The active screencast is then stopped.
44
- // - A new screencast is initiated using the parameters and callbacks from the current startScreencast call.
45
- //
46
- // When stopScreencast is invoked:
47
- // - The currently active screencast is stopped.
48
- // - The #screencastOperations is checked for interrupted screencast operations.
49
- // - If any operations are found, the latest one is started
50
- // using its saved parameters and callbacks.
51
- //
52
- // This ensures that:
53
- // - Only one screencast is active at a time.
54
- // - Interrupted screencasts are resumed after the current screencast is stopped.
55
- // This ensures animation previews, which use screencasting, don't disrupt ongoing remote debugging sessions. Without this mechanism, stopping a preview screencast would terminate the debugging screencast, freezing the ScreencastView.
40
+ /**
41
+ * Manages concurrent screencast requests by queuing and prioritizing.
42
+ *
43
+ * When startScreencast is invoked:
44
+ * - If a screencast is currently active, the existing screencast's parameters and callbacks are
45
+ * saved in the #screencastOperations array.
46
+ * - The active screencast is then stopped.
47
+ * - A new screencast is initiated using the parameters and callbacks from the current startScreencast call.
48
+ *
49
+ * When stopScreencast is invoked:
50
+ * - The currently active screencast is stopped.
51
+ * - The #screencastOperations is checked for interrupted screencast operations.
52
+ * - If any operations are found, the latest one is started
53
+ * using its saved parameters and callbacks.
54
+ *
55
+ * This ensures that:
56
+ * - Only one screencast is active at a time.
57
+ * - Interrupted screencasts are resumed after the current screencast is stopped.
58
+ * This ensures animation previews, which use screencasting, don't disrupt ongoing remote debugging sessions. Without this mechanism, stopping a preview screencast would terminate the debugging screencast, freezing the ScreencastView.
59
+ **/
56
60
  export class ScreenCaptureModel extends SDKModel<void> implements ProtocolProxyApi.PageDispatcher {
57
61
  readonly #agent: ProtocolProxyApi.PageApi;
58
62
  #nextScreencastOperationId = 1;
@@ -67,12 +67,15 @@ export class Target extends ProtocolClient.InspectorBackend.TargetBase {
67
67
  this.#capabilitiesMask = Capability.JS | Capability.LOG | Capability.NETWORK | Capability.TARGET |
68
68
  Capability.INSPECTOR | Capability.IO | Capability.EVENT_BREAKPOINTS;
69
69
  if (parentTarget?.type() !== Type.FRAME) {
70
- this.#capabilitiesMask |= Capability.BROWSER;
70
+ this.#capabilitiesMask |= Capability.BROWSER | Capability.STORAGE;
71
71
  }
72
72
  break;
73
73
  case Type.SHARED_WORKER:
74
74
  this.#capabilitiesMask = Capability.JS | Capability.LOG | Capability.NETWORK | Capability.TARGET |
75
75
  Capability.IO | Capability.MEDIA | Capability.INSPECTOR | Capability.EVENT_BREAKPOINTS;
76
+ if (parentTarget?.type() !== Type.FRAME) {
77
+ this.#capabilitiesMask |= Capability.STORAGE;
78
+ }
76
79
  break;
77
80
  case Type.SHARED_STORAGE_WORKLET:
78
81
  this.#capabilitiesMask = Capability.JS | Capability.LOG | Capability.INSPECTOR | Capability.EVENT_BREAKPOINTS;
@@ -80,6 +83,9 @@ export class Target extends ProtocolClient.InspectorBackend.TargetBase {
80
83
  case Type.Worker:
81
84
  this.#capabilitiesMask = Capability.JS | Capability.LOG | Capability.NETWORK | Capability.TARGET |
82
85
  Capability.IO | Capability.MEDIA | Capability.EMULATION | Capability.EVENT_BREAKPOINTS;
86
+ if (parentTarget?.type() !== Type.FRAME) {
87
+ this.#capabilitiesMask |= Capability.STORAGE;
88
+ }
83
89
  break;
84
90
  case Type.WORKLET:
85
91
  this.#capabilitiesMask = Capability.JS | Capability.LOG | Capability.EVENT_BREAKPOINTS | Capability.NETWORK;
@@ -10,7 +10,7 @@ import type {NetworkRequest} from './NetworkRequest.js';
10
10
  import {ResourceTreeModel} from './ResourceTreeModel.js';
11
11
  import type {SourceMapV3} from './SourceMap.js';
12
12
 
13
- // A thin wrapper class, mostly to enable instanceof-based revealing of traces to open in Timeline.
13
+ /** A thin wrapper class, mostly to enable instanceof-based revealing of traces to open in Timeline. **/
14
14
  export class TraceObject {
15
15
  readonly traceEvents: Protocol.Tracing.DataCollectedEvent['value'];
16
16
  readonly metadata: {sourceMaps?: Array<{sourceMapUrl: string, sourceMap: SourceMapV3, url: string}>};
@@ -24,7 +24,7 @@ export class TraceObject {
24
24
  }
25
25
  }
26
26
 
27
- // Another thin wrapper class to enable revealing individual trace events (aka entries) in Timeline panel.
27
+ /** Another thin wrapper class to enable revealing individual trace events (aka entries) in Timeline panel. **/
28
28
  export class RevealableEvent {
29
29
  // Only Trace.Types.Events.Event are passed in, but we can't depend on that type from SDK
30
30
  /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
@@ -20,10 +20,12 @@ interface Replacement {
20
20
  isShorthandAssignmentProperty: boolean;
21
21
  }
22
22
 
23
- // Given an |expression| and a mapping from names to new names, the |computeSubstitution|
24
- // function returns a list of replacements sorted by the offset. The function throws if
25
- // it cannot parse the expression or the substitution is impossible to perform (for example
26
- // if the substitution target is 'this' within a function, it would become bound there).
23
+ /**
24
+ * Given an |expression| and a mapping from names to new names, the |computeSubstitution|
25
+ * function returns a list of replacements sorted by the offset. The function throws if
26
+ * it cannot parse the expression or the substitution is impossible to perform (for example
27
+ * if the substitution target is 'this' within a function, it would become bound there).
28
+ **/
27
29
  function computeSubstitution(expression: string, nameMap: Map<string, string|null>): Replacement[] {
28
30
  // Parse the expression and find variables and scopes.
29
31
  const root = Acorn.parse(expression, {