chrome-devtools-frontend 1.0.1522585 → 1.0.1525561

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 (357) 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/policy/slow-close.md +22 -19
  9. package/docs/ui_engineering.md +22 -0
  10. package/front_end/Tests.js +1 -1
  11. package/front_end/core/common/Color.ts +13 -9
  12. package/front_end/core/common/ColorConverter.ts +9 -7
  13. package/front_end/core/common/Gzip.ts +1 -1
  14. package/front_end/core/common/MapWithDefault.ts +5 -3
  15. package/front_end/core/common/ResourceType.ts +0 -12
  16. package/front_end/core/common/ReturnToPanel.ts +6 -4
  17. package/front_end/core/common/Trie.ts +4 -2
  18. package/front_end/core/host/AidaClient.ts +3 -3
  19. package/front_end/core/host/GdpClient.ts +7 -5
  20. package/front_end/core/host/InspectorFrontendHostAPI.ts +7 -5
  21. package/front_end/core/host/Platform.ts +5 -3
  22. package/front_end/core/host/UserMetrics.ts +6 -4
  23. package/front_end/core/platform/ArrayUtilities.ts +1 -1
  24. package/front_end/core/platform/StringUtilities.ts +34 -31
  25. package/front_end/core/root/Runtime.ts +1 -1
  26. package/front_end/core/sdk/CSSMetadata.ts +6 -4
  27. package/front_end/core/sdk/CSSPropertyParser.ts +17 -13
  28. package/front_end/core/sdk/CSSPropertyParserMatchers.ts +19 -13
  29. package/front_end/core/sdk/ChildTargetManager.ts +35 -0
  30. package/front_end/core/sdk/DOMModel.ts +1 -1
  31. package/front_end/core/sdk/EventBreakpointsModel.ts +4 -2
  32. package/front_end/core/sdk/HttpReasonPhraseStrings.ts +4 -2
  33. package/front_end/core/sdk/NetworkManager.ts +8 -48
  34. package/front_end/core/sdk/NetworkRequest.ts +0 -28
  35. package/front_end/core/sdk/PageResourceLoader.ts +1 -1
  36. package/front_end/core/sdk/PreloadingModel.ts +22 -18
  37. package/front_end/core/sdk/RehydratingConnection.ts +1 -1
  38. package/front_end/core/sdk/RehydratingObject.ts +1 -1
  39. package/front_end/core/sdk/RemoteObject.ts +1 -1
  40. package/front_end/core/sdk/ResourceTreeModel.ts +2 -0
  41. package/front_end/{models/source_map_scopes → core/sdk}/ScopeTreeCache.ts +8 -7
  42. package/front_end/core/sdk/ScreenCaptureModel.ts +24 -20
  43. package/front_end/core/sdk/Target.ts +7 -1
  44. package/front_end/core/sdk/TraceObject.ts +2 -2
  45. package/front_end/core/sdk/sdk.ts +2 -0
  46. package/front_end/entrypoints/formatter_worker/FormatterActions.ts +7 -0
  47. package/front_end/entrypoints/formatter_worker/ScopeParser.ts +15 -12
  48. package/front_end/entrypoints/formatter_worker/Substitute.ts +6 -4
  49. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +24 -16
  50. package/front_end/entrypoints/inspector_main/OutermostTargetSelector.ts +2 -1
  51. package/front_end/entrypoints/main/MainImpl.ts +6 -4
  52. package/front_end/generated/InspectorBackendCommands.js +2 -2
  53. package/front_end/generated/protocol-mapping.d.ts +3 -2
  54. package/front_end/generated/protocol-proxy-api.d.ts +3 -1
  55. package/front_end/generated/protocol.ts +7 -1
  56. package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +55 -14
  57. package/front_end/models/ai_assistance/agents/StylingAgent.ts +83 -222
  58. package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +23 -0
  59. package/front_end/models/ai_assistance/performance/AIContext.ts +19 -4
  60. package/front_end/models/ai_code_completion/AiCodeCompletion.ts +4 -2
  61. package/front_end/models/autofill_manager/AutofillManager.ts +4 -2
  62. package/front_end/models/cpu_profile/CPUProfileDataModel.ts +1 -1
  63. package/front_end/models/crux-manager/CrUXManager.ts +1 -1
  64. package/front_end/models/extensions/HostUrlPattern.ts +13 -5
  65. package/front_end/models/formatter/FormatterWorkerPool.ts +1 -1
  66. package/front_end/models/issues_manager/CookieDeprecationMetadataIssue.ts +1 -1
  67. package/front_end/models/issues_manager/CookieIssue.ts +2 -2
  68. package/front_end/models/issues_manager/MarkdownIssueDescription.ts +1 -1
  69. package/front_end/models/issues_manager/SharedDictionaryIssue.ts +20 -0
  70. package/front_end/models/issues_manager/descriptions/sharedDictionaryWriteErrorInvalidTTLField.md +1 -0
  71. package/front_end/models/issues_manager/descriptions/sharedDictionaryWriteErrorNonIntegerTTLField.md +1 -0
  72. package/front_end/models/javascript_metadata/NativeFunctions.js +8 -0
  73. package/front_end/models/network_time_calculator/Calculator.ts +4 -2
  74. package/front_end/models/network_time_calculator/RequestTimeRanges.ts +6 -4
  75. package/front_end/models/source_map_scopes/NamesResolver.ts +8 -8
  76. package/front_end/models/source_map_scopes/source_map_scopes.ts +0 -2
  77. package/front_end/models/text_utils/ContentProvider.ts +6 -4
  78. package/front_end/models/trace/extras/TraceTree.ts +1 -1
  79. package/front_end/models/trace/handlers/FramesHandler.ts +7 -5
  80. package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +13 -7
  81. package/front_end/models/trace/handlers/MetaHandler.ts +16 -14
  82. package/front_end/models/trace/handlers/NetworkRequestsHandler.ts +20 -8
  83. package/front_end/models/trace/handlers/helpers.ts +1 -1
  84. package/front_end/models/trace/handlers/types.ts +23 -19
  85. package/front_end/models/trace/helpers/Timing.ts +4 -2
  86. package/front_end/models/trace/helpers/Trace.ts +8 -4
  87. package/front_end/models/trace/insights/DocumentLatency.ts +1 -1
  88. package/front_end/models/trace/insights/INPBreakdown.ts +13 -2
  89. package/front_end/models/trace/insights/LCPBreakdown.ts +14 -2
  90. package/front_end/models/trace/insights/NetworkDependencyTree.ts +2 -2
  91. package/front_end/models/trace/types/File.ts +12 -8
  92. package/front_end/models/trace/types/Timing.ts +1 -1
  93. package/front_end/models/trace/types/TraceEvents.ts +37 -23
  94. package/front_end/models/trace_source_maps_resolver/SourceMapsResolver.ts +1 -1
  95. package/front_end/panels/ai_assistance/components/MarkdownRendererWithCodeBlock.ts +12 -10
  96. package/front_end/panels/application/KeyValueStorageItemsView.ts +31 -33
  97. package/front_end/panels/application/components/InterestGroupAccessGrid.ts +6 -11
  98. package/front_end/panels/application/components/OriginTrialTreeView.ts +7 -5
  99. package/front_end/panels/application/components/PermissionsPolicySection.ts +1 -0
  100. package/front_end/panels/application/components/ReportsGrid.ts +4 -10
  101. package/front_end/panels/application/components/SharedStorageAccessGrid.ts +5 -13
  102. package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +1 -1
  103. package/front_end/panels/application/preloading/components/PreloadingGrid.ts +3 -7
  104. package/front_end/panels/application/preloading/components/PreloadingString.ts +2 -2
  105. package/front_end/panels/application/preloading/components/RuleSetGrid.ts +3 -10
  106. package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +4 -2
  107. package/front_end/panels/browser_debugger/browser_debugger-meta.ts +7 -5
  108. package/front_end/panels/changes/ChangesSidebar.ts +105 -96
  109. package/front_end/panels/changes/ChangesView.ts +69 -69
  110. package/front_end/panels/changes/CombinedDiffView.ts +1 -1
  111. package/front_end/panels/changes/changesSidebar.css +3 -0
  112. package/front_end/panels/changes/changesView.css +4 -0
  113. package/front_end/panels/console/ConsoleView.ts +2 -2
  114. package/front_end/panels/developer_resources/DeveloperResourcesListView.ts +22 -35
  115. package/front_end/panels/elements/ComputedStyleWidget.ts +1 -1
  116. package/front_end/panels/elements/ElementStatePaneWidget.ts +12 -0
  117. package/front_end/panels/elements/ElementsTreeElement.ts +9 -5
  118. package/front_end/panels/elements/ElementsTreeOutline.ts +11 -8
  119. package/front_end/panels/elements/PropertyRenderer.ts +19 -15
  120. package/front_end/panels/elements/StylePropertyTreeElement.ts +6 -4
  121. package/front_end/panels/elements/StylesSidebarPane.ts +2 -2
  122. package/front_end/panels/elements/components/AccessibilityTreeNode.ts +4 -2
  123. package/front_end/panels/elements/components/AdornerManager.ts +5 -3
  124. package/front_end/panels/lighthouse/LighthouseController.ts +5 -0
  125. package/front_end/panels/linear_memory_inspector/LinearMemoryInspectorPane.ts +43 -46
  126. package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +260 -157
  127. package/front_end/panels/linear_memory_inspector/components/linearMemoryInspector.css +28 -21
  128. package/front_end/panels/media/PlayerPropertiesView.ts +1 -1
  129. package/front_end/panels/network/NetworkDataGridNode.ts +2 -44
  130. package/front_end/panels/network/NetworkLogView.ts +6 -4
  131. package/front_end/panels/network/RequestPreviewView.ts +0 -7
  132. package/front_end/panels/network/components/RequestHeadersView.ts +0 -6
  133. package/front_end/panels/network/components/components.ts +0 -2
  134. package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +1 -1
  135. package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +4 -2
  136. package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +12 -19
  137. package/front_end/panels/search/SearchResultsPane.ts +2 -3
  138. package/front_end/panels/security/IPProtectionView.ts +1 -1
  139. package/front_end/panels/settings/emulation/components/userAgentClientHintsForm.css +4 -0
  140. package/front_end/panels/settings/emulation/utils/StructuredHeaders.ts +45 -37
  141. package/front_end/panels/sources/BreakpointsViewUtils.ts +11 -9
  142. package/front_end/panels/sources/DebuggerPlugin.ts +8 -4
  143. package/front_end/panels/sources/SourcesPanel.ts +1 -1
  144. package/front_end/panels/sources/UISourceCodeFrame.ts +1 -1
  145. package/front_end/panels/timeline/CompatibilityTracksAppender.ts +4 -2
  146. package/front_end/panels/timeline/CountersGraph.ts +12 -5
  147. package/front_end/panels/timeline/EasterEgg.d.ts +5 -3
  148. package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +8 -6
  149. package/front_end/panels/timeline/ModificationsManager.ts +5 -3
  150. package/front_end/panels/timeline/ThreadAppender.ts +7 -5
  151. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +10 -8
  152. package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +1 -1
  153. package/front_end/panels/timeline/TimelinePanel.ts +10 -8
  154. package/front_end/panels/timeline/TimelineSelection.ts +4 -2
  155. package/front_end/panels/timeline/TimelineUIUtils.ts +5 -3
  156. package/front_end/panels/timeline/components/BreadcrumbsUI.ts +6 -4
  157. package/front_end/panels/timeline/components/Utils.ts +1 -1
  158. package/front_end/panels/timeline/overlays/OverlaysImpl.ts +5 -3
  159. package/front_end/panels/timeline/utils/Helpers.ts +1 -1
  160. package/front_end/panels/utils/utils.ts +1 -7
  161. package/front_end/services/trace_bounds/TraceBounds.ts +4 -2
  162. package/front_end/services/tracing/PerformanceTracing.ts +1 -1
  163. package/front_end/third_party/chromium/README.chromium +1 -1
  164. package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
  165. package/front_end/third_party/codemirror.next/chunk/codemirror.js.map +1 -1
  166. package/front_end/third_party/codemirror.next/chunk/php.js +1 -1
  167. package/front_end/third_party/codemirror.next/chunk/php.js.map +1 -1
  168. package/front_end/third_party/codemirror.next/package.json +3 -2
  169. package/front_end/third_party/puppeteer/README.chromium +2 -2
  170. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.d.ts +8 -10
  171. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.d.ts.map +1 -1
  172. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.js +8 -10
  173. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Dialog.js.map +1 -1
  174. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts +28 -30
  175. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts.map +1 -1
  176. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js +27 -29
  177. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js.map +1 -1
  178. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.d.ts +34 -38
  179. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.d.ts.map +1 -1
  180. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js +34 -38
  181. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Frame.js.map +1 -1
  182. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts +8 -1
  183. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  184. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js +12 -14
  185. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/HTTPRequest.js.map +1 -1
  186. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts +92 -108
  187. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts.map +1 -1
  188. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js +33 -39
  189. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js.map +1 -1
  190. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.d.ts.map +1 -1
  191. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js +5 -3
  192. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Browser.js.map +1 -1
  193. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.d.ts.map +1 -1
  194. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js +1 -1
  195. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Frame.js.map +1 -1
  196. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.d.ts +4 -2
  197. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.d.ts.map +1 -1
  198. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.js +14 -5
  199. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/HTTPRequest.js.map +1 -1
  200. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts +1 -0
  201. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts.map +1 -1
  202. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js +12 -6
  203. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js.map +1 -1
  204. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.d.ts.map +1 -1
  205. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js +24 -2
  206. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js.map +1 -1
  207. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Realm.d.ts +2 -2
  208. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.d.ts +1 -0
  209. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.d.ts.map +1 -1
  210. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.js +3 -0
  211. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/HTTPRequest.js.map +1 -1
  212. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts +13 -22
  213. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  214. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.js +13 -22
  215. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/PredefinedNetworkConditions.js.map +1 -1
  216. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.d.ts +6 -8
  217. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.d.ts.map +1 -1
  218. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.js +6 -8
  219. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Device.js.map +1 -1
  220. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.d.ts +1 -1
  221. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.js +1 -1
  222. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts +1 -1
  223. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts +1 -1
  224. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  225. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js +6 -3
  226. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js.map +1 -1
  227. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.d.ts +5 -7
  228. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.d.ts.map +1 -1
  229. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.js +5 -7
  230. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PuppeteerNode.js.map +1 -1
  231. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.d.ts +3 -3
  232. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +3 -3
  233. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js.map +1 -1
  234. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts +2 -2
  235. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +188 -224
  236. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +140 -166
  237. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.d.ts +8 -10
  238. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.d.ts.map +1 -1
  239. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.js +8 -10
  240. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Dialog.js.map +1 -1
  241. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts +28 -30
  242. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts.map +1 -1
  243. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js +27 -29
  244. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js.map +1 -1
  245. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.d.ts +34 -38
  246. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.d.ts.map +1 -1
  247. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js +34 -38
  248. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Frame.js.map +1 -1
  249. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts +8 -1
  250. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.d.ts.map +1 -1
  251. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.js +12 -14
  252. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/HTTPRequest.js.map +1 -1
  253. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts +92 -108
  254. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts.map +1 -1
  255. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js +33 -39
  256. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js.map +1 -1
  257. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.d.ts.map +1 -1
  258. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js +5 -3
  259. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Browser.js.map +1 -1
  260. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.d.ts.map +1 -1
  261. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js +1 -1
  262. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Frame.js.map +1 -1
  263. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.d.ts +4 -2
  264. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.d.ts.map +1 -1
  265. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.js +15 -6
  266. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/HTTPRequest.js.map +1 -1
  267. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts +1 -0
  268. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts.map +1 -1
  269. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js +12 -6
  270. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js.map +1 -1
  271. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.d.ts.map +1 -1
  272. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js +24 -2
  273. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js.map +1 -1
  274. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.d.ts +1 -0
  275. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.d.ts.map +1 -1
  276. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.js +3 -0
  277. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/HTTPRequest.js.map +1 -1
  278. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts +13 -22
  279. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.d.ts.map +1 -1
  280. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.js +13 -22
  281. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/PredefinedNetworkConditions.js.map +1 -1
  282. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.d.ts +6 -8
  283. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.d.ts.map +1 -1
  284. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.js +6 -8
  285. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Device.js.map +1 -1
  286. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.d.ts +1 -1
  287. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.js +1 -1
  288. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts +1 -1
  289. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  290. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js +6 -3
  291. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js.map +1 -1
  292. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.d.ts +5 -7
  293. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.d.ts.map +1 -1
  294. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.js +5 -7
  295. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PuppeteerNode.js.map +1 -1
  296. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.d.ts +3 -3
  297. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +3 -3
  298. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js.map +1 -1
  299. package/front_end/third_party/puppeteer/package/lib/types.d.ts +188 -224
  300. package/front_end/third_party/puppeteer/package/package.json +3 -3
  301. package/front_end/third_party/puppeteer/package/src/api/Dialog.ts +8 -10
  302. package/front_end/third_party/puppeteer/package/src/api/ElementHandle.ts +27 -29
  303. package/front_end/third_party/puppeteer/package/src/api/Frame.ts +34 -38
  304. package/front_end/third_party/puppeteer/package/src/api/HTTPRequest.ts +17 -14
  305. package/front_end/third_party/puppeteer/package/src/api/Page.ts +92 -108
  306. package/front_end/third_party/puppeteer/package/src/bidi/Browser.ts +5 -3
  307. package/front_end/third_party/puppeteer/package/src/bidi/Frame.ts +5 -1
  308. package/front_end/third_party/puppeteer/package/src/bidi/HTTPRequest.ts +28 -3
  309. package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +16 -7
  310. package/front_end/third_party/puppeteer/package/src/bidi/core/Browser.ts +28 -2
  311. package/front_end/third_party/puppeteer/package/src/cdp/HTTPRequest.ts +4 -0
  312. package/front_end/third_party/puppeteer/package/src/cdp/PredefinedNetworkConditions.ts +13 -22
  313. package/front_end/third_party/puppeteer/package/src/common/Device.ts +6 -8
  314. package/front_end/third_party/puppeteer/package/src/generated/version.ts +1 -1
  315. package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +6 -3
  316. package/front_end/third_party/puppeteer/package/src/node/PuppeteerNode.ts +5 -7
  317. package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
  318. package/front_end/ui/components/chrome_link/ChromeLink.ts +4 -2
  319. package/front_end/ui/components/dialogs/Dialog.ts +13 -9
  320. package/front_end/ui/components/docs/linear_memory_inspector/basic.ts +21 -9
  321. package/front_end/ui/components/highlighting/HighlightElement.ts +77 -0
  322. package/front_end/ui/components/highlighting/HighlightManager.ts +58 -1
  323. package/front_end/ui/components/highlighting/highlighting.ts +2 -0
  324. package/front_end/ui/components/markdown_view/MarkdownImagesMap.ts +5 -3
  325. package/front_end/ui/components/markdown_view/MarkdownLinksMap.ts +5 -3
  326. package/front_end/ui/components/menus/SelectMenu.ts +6 -4
  327. package/front_end/ui/components/survey_link/SurveyLink.ts +4 -2
  328. package/front_end/ui/components/text_editor/config.ts +10 -6
  329. package/front_end/ui/components/text_editor/javascript.ts +8 -4
  330. package/front_end/ui/components/tooltips/Tooltip.ts +22 -5
  331. package/front_end/ui/legacy/ForwardedInputEventHandler.ts +4 -2
  332. package/front_end/ui/legacy/GlassPane.ts +1 -1
  333. package/front_end/ui/legacy/SettingsUI.ts +1 -5
  334. package/front_end/ui/legacy/Treeoutline.ts +12 -33
  335. package/front_end/ui/legacy/UIUtils.ts +19 -1
  336. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +12 -10
  337. package/front_end/ui/legacy/components/cookie_table/CookiesTable.ts +30 -32
  338. package/front_end/ui/legacy/components/data_grid/DataGrid.ts +1 -1
  339. package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +25 -25
  340. package/front_end/ui/legacy/components/data_grid/dataGrid.css +5 -0
  341. package/front_end/ui/legacy/components/inline_editor/AnimationTimingModel.ts +4 -2
  342. package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +4 -2
  343. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +8 -6
  344. package/front_end/ui/legacy/components/perf_ui/PieChart.ts +6 -4
  345. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +3 -3
  346. package/front_end/ui/legacy/components/source_frame/StreamingContentHexView.ts +18 -20
  347. package/front_end/ui/legacy/components/source_frame/XMLView.ts +22 -16
  348. package/front_end/ui/legacy/components/source_frame/xmlView.css +0 -2
  349. package/front_end/ui/legacy/components/utils/Linkifier.ts +6 -4
  350. package/front_end/ui/visual_logging/Debugging.ts +10 -6
  351. package/front_end/ui/visual_logging/KnownContextValues.ts +1 -3
  352. package/inspector_overlay/common.ts +5 -3
  353. package/inspector_overlay/highlight_grid_common.ts +1 -1
  354. package/package.json +1 -1
  355. package/front_end/Images/src/bundle.svg +0 -3
  356. package/front_end/panels/network/components/WebBundleInfoView.css +0 -27
  357. package/front_end/panels/network/components/WebBundleInfoView.ts +0 -95
@@ -2512,10 +2512,12 @@ export class NetworkLogView extends Common.ObjectWrapper.eventMixin<EventTypes,
2512
2512
  str.replace(/[`\$"]/g, '`$&').replace(/[^\x20-\x7E]/g, char => '$([char]' + char.charCodeAt(0) + ')') + '"';
2513
2513
  }
2514
2514
 
2515
- // Generate a WebRequestSession object with the UserAgent and Cookie header values.
2516
- // This is used to pass the user-agent and cookie headers to Invoke-WebRequest because the Invoke-WebRequest
2517
- // command does not allow setting these headers through the -Headers parameter. See docs at:
2518
- // https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/invoke-webrequest?view=powershell-7.1#parameters
2515
+ /**
2516
+ * Generate a WebRequestSession object with the UserAgent and Cookie header values.
2517
+ * This is used to pass the user-agent and cookie headers to Invoke-WebRequest because the Invoke-WebRequest
2518
+ * command does not allow setting these headers through the -Headers parameter. See docs at:
2519
+ * https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/invoke-webrequest?view=powershell-7.1#parameters
2520
+ **/
2519
2521
  function generatePowerShellSession(request: SDK.NetworkRequest.NetworkRequest): string|null {
2520
2522
  const requestHeaders = request.requestHeaders();
2521
2523
  const props = [];
@@ -8,12 +8,10 @@ import '../../ui/legacy/legacy.js';
8
8
  import * as i18n from '../../core/i18n/i18n.js';
9
9
  import type * as SDK from '../../core/sdk/sdk.js';
10
10
  import * as TextUtils from '../../models/text_utils/text_utils.js';
11
- import * as LegacyWrapper from '../../ui/components/legacy_wrapper/legacy_wrapper.js';
12
11
  import * as SourceFrame from '../../ui/legacy/components/source_frame/source_frame.js';
13
12
  import * as UI from '../../ui/legacy/legacy.js';
14
13
  import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
15
14
 
16
- import * as NetworkComponents from './components/components.js';
17
15
  import {RequestHTMLView} from './RequestHTMLView.js';
18
16
  import {SignedExchangeInfoView} from './SignedExchangeInfoView.js';
19
17
 
@@ -90,11 +88,6 @@ export class RequestPreviewView extends UI.Widget.VBox {
90
88
  return new SignedExchangeInfoView(this.request);
91
89
  }
92
90
 
93
- if (this.request.webBundleInfo()) {
94
- return LegacyWrapper.LegacyWrapper.legacyWrapper(
95
- UI.Widget.VBox, new NetworkComponents.WebBundleInfoView.WebBundleInfoView(this.request));
96
- }
97
-
98
91
  const htmlErrorPreview = await this.htmlPreview();
99
92
  if (htmlErrorPreview) {
100
93
  return htmlErrorPreview;
@@ -58,10 +58,6 @@ const UIStrings = {
58
58
  * @description Text in Request Headers View of the Network panel
59
59
  */
60
60
  fromSignedexchange: '(from signed-exchange)',
61
- /**
62
- * @description Text in Request Headers View of the Network panel
63
- */
64
- fromWebBundle: '(from Web Bundle)',
65
61
  /**
66
62
  * @description Section header for a list of the main aspects of a http request
67
63
  */
@@ -450,8 +446,6 @@ export class RequestHeadersView extends LegacyWrapper.LegacyWrapper.WrappableCom
450
446
  comment = i18nString(UIStrings.fromServiceWorker);
451
447
  } else if (this.#request.redirectSourceSignedExchangeInfoHasNoErrors()) {
452
448
  comment = i18nString(UIStrings.fromSignedexchange);
453
- } else if (this.#request.webBundleInnerRequestInfo()) {
454
- comment = i18nString(UIStrings.fromWebBundle);
455
449
  } else if (this.#request.fromPrefetchCache()) {
456
450
  comment = i18nString(UIStrings.fromPrefetchCache);
457
451
  } else if (this.#request.cached()) {
@@ -9,7 +9,6 @@ import * as RequestHeaderSection from './RequestHeaderSection.js';
9
9
  import * as RequestHeadersView from './RequestHeadersView.js';
10
10
  import * as RequestTrustTokensView from './RequestTrustTokensView.js';
11
11
  import * as ResponseHeaderSection from './ResponseHeaderSection.js';
12
- import * as WebBundleInfoView from './WebBundleInfoView.js';
13
12
 
14
13
  export {
15
14
  DirectSocketConnectionView,
@@ -19,5 +18,4 @@ export {
19
18
  RequestHeadersView,
20
19
  RequestTrustTokensView,
21
20
  ResponseHeaderSection,
22
- WebBundleInfoView,
23
21
  };
@@ -734,7 +734,7 @@ export class HeapSnapshotRetainmentDataGrid extends HeapSnapshotContainmentDataG
734
734
  }
735
735
  }
736
736
 
737
- // TODO(crbug.com/1228674): Remove this enum, it is only used in web tests.
737
+ /** TODO(crbug.com/1228674): Remove this enum, it is only used in web tests. **/
738
738
  export enum HeapSnapshotRetainmentDataGridEvents {
739
739
  /* eslint-disable @typescript-eslint/naming-convention -- Used by web_tests. */
740
740
  ExpandRetainersComplete = 'ExpandRetainersComplete',
@@ -1084,6 +1084,8 @@ export class HeapSnapshotConstructorNode extends HeapSnapshotGridNode {
1084
1084
  readonly retainedSize: number;
1085
1085
  readonly classKey: string;
1086
1086
 
1087
+ #numberFormatter = new Intl.NumberFormat(i18n.DevToolsLocale.DevToolsLocale.instance().locale);
1088
+
1087
1089
  constructor(
1088
1090
  dataGrid: HeapSnapshotConstructorsDataGrid, classKey: string,
1089
1091
  aggregate: HeapSnapshotModel.HeapSnapshotModel.Aggregate,
@@ -1102,7 +1104,7 @@ export class HeapSnapshotConstructorNode extends HeapSnapshotGridNode {
1102
1104
  const shallowSizePercent = this.shallowSize / snapshot.totalSize * 100.0;
1103
1105
  this.data = {
1104
1106
  object: this.nameInternal,
1105
- count: Platform.NumberUtilities.withThousandsSeparator(this.count),
1107
+ count: this.#numberFormatter.format(this.count),
1106
1108
  distance: this.toUIDistance(this.distance),
1107
1109
  shallowSize: i18n.ByteUtilities.formatBytesToKb(this.shallowSize),
1108
1110
  retainedSize: i18n.ByteUtilities.formatBytesToKb(this.retainedSize),
@@ -1143,7 +1145,7 @@ export class HeapSnapshotConstructorNode extends HeapSnapshotGridNode {
1143
1145
  override createCell(columnId: string): HTMLElement {
1144
1146
  const cell = columnId === 'object' ? super.createCell(columnId) : this.createValueCell(columnId);
1145
1147
  if (columnId === 'object' && this.count > 1) {
1146
- cell.appendChild(UI.Fragment.html`<span class="objects-count">×${this.count}</span>`);
1148
+ cell.appendChild(UI.Fragment.html`<span class="objects-count">×${this.data.count}</span>`);
1147
1149
  }
1148
1150
  return cell;
1149
1151
  }
@@ -177,8 +177,8 @@ export interface ViewInput {
177
177
  onClear: () => void;
178
178
  onSave: () => void;
179
179
  onSplitChange: (onlyMain: boolean) => void;
180
- onSelect: (e: CustomEvent<HTMLElement|null>) => void;
181
- onContextMenu: (e: CustomEvent<{menu: UI.ContextMenu.ContextMenu, element: HTMLElement}>) => void;
180
+ onSelect: (e: Message|undefined) => void;
181
+ onContextMenu: (message: Message, menu: UI.ContextMenu.ContextMenu) => void;
182
182
  onFilterChanged: (filter: string) => void;
183
183
  onCommandChange: (command: string) => void;
184
184
  onCommandSubmitted: (input: string) => void;
@@ -230,7 +230,7 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
230
230
  list="filter-suggestions"
231
231
  style="flex-grow: 1"
232
232
  value=${input.filter}
233
- @change=${(e: Event) => input.onFilterChanged((e.target as HTMLInputElement).value)}>
233
+ @change=${(e: CustomEvent<string>) => input.onFilterChanged(e.detail)}>
234
234
  <datalist id="filter-suggestions">
235
235
  ${input.filterKeys.map(key => html`
236
236
  <option value=${key + ':'}></option>
@@ -243,8 +243,6 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
243
243
  <devtools-data-grid
244
244
  striped
245
245
  slot="main"
246
- @select=${input.onSelect}
247
- @contextmenu=${input.onContextMenu}
248
246
  .filters=${input.parseFilter(input.filter)}>
249
247
  <table>
250
248
  <tr>
@@ -275,8 +273,9 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
275
273
  </tr>
276
274
  ${
277
275
  input.messages.map(
278
- (message, index) => html`
279
- <tr data-index=${index}
276
+ message => html`
277
+ <tr @select=${() => input.onSelect(message)}
278
+ @contextmenu=${(e: CustomEvent<UI.ContextMenu.ContextMenu>) => input.onContextMenu(message, e.detail)}
280
279
  style="--override-data-grid-row-background-color: var(--sys-color-surface3)">
281
280
  ${'id' in message ? html`
282
281
  <td title="sent">
@@ -331,8 +330,8 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
331
330
  list="command-input-suggestions"
332
331
  placeholder=${i18nString(UIStrings.sendRawCDPCommand)}
333
332
  title=${i18nString(UIStrings.sendRawCDPCommandExplanation)}
334
- @change=${(e: Event) => input.onCommandChange((e.target as HTMLInputElement).value)}
335
- @submit=${(e: Event) => input.onCommandSubmitted((e.target as HTMLInputElement).value)}>
333
+ @change=${(e: CustomEvent<string>) => input.onCommandChange(e.detail)}
334
+ @submit=${(e: CustomEvent<string>) => input.onCommandSubmitted(e.detail)}>
336
335
  <datalist id="command-input-suggestions">
337
336
  ${input.commandSuggestions.map(c => html`<option value=${c}></option>`)}
338
337
  </datalist>
@@ -439,17 +438,11 @@ export class ProtocolMonitorImpl extends UI.Panel.Panel {
439
438
  onSave: () => {
440
439
  void this.saveAsFile();
441
440
  },
442
- onSelect: (e: CustomEvent<HTMLElement|null>) => {
443
- const index = parseInt(e.detail?.dataset?.index ?? '', 10);
444
- this.#selectedMessage = !isNaN(index) ? this.#messages[index] : undefined;
441
+ onSelect: (message: Message|undefined) => {
442
+ this.#selectedMessage = message;
445
443
  this.requestUpdate();
446
444
  },
447
- onContextMenu: (e: CustomEvent<{menu: UI.ContextMenu.ContextMenu, element: HTMLElement}>) => {
448
- const message = this.#messages[parseInt(e.detail?.element?.dataset?.index || '', 10)];
449
- if (message) {
450
- this.#populateContextMenu(e.detail.menu, message);
451
- }
452
- },
445
+ onContextMenu: this.#populateContextMenu.bind(this),
453
446
  onCommandChange: (command: string) => {
454
447
  this.#command = command;
455
448
  },
@@ -481,7 +474,7 @@ export class ProtocolMonitorImpl extends UI.Panel.Panel {
481
474
  this.#view(viewInput, viewOutput, this.contentElement);
482
475
  }
483
476
 
484
- #populateContextMenu(menu: UI.ContextMenu.ContextMenu, message: Message): void {
477
+ #populateContextMenu(message: Message, menu: UI.ContextMenu.ContextMenu): void {
485
478
  /**
486
479
  * You can click the "Edit and resend" item in the context menu to be
487
480
  * taken to the CDP editor with the filled with the selected command.
@@ -107,8 +107,6 @@ const renderSearchMatches =
107
107
  return html`
108
108
  ${visibleMatches.map(({lineContent, matchRanges, resultLabel}, i) => html`
109
109
  <li role="treeitem" class="search-match" @click=${() => onSelectMatch(searchResult, i)}
110
- ${UI.TreeOutline.TreeSearch.highlight(matchRanges.map(range =>
111
- ({offset: range.offset + `${resultLabel}`.length, length: range.length})), undefined)}
112
110
  @keydown=${(event: KeyboardEvent) => {
113
111
  if (event.key === 'Enter') {
114
112
  onSelectMatch(searchResult, i);
@@ -123,7 +121,8 @@ const renderSearchMatches =
123
121
  ? i18nString(UIStrings.lineS, {PH1: resultLabel}) : resultLabel}>
124
122
  ${resultLabel}
125
123
  </span>
126
- <span class="search-match-content" aria-label="${lineContent} line">
124
+ <span class="search-match-content" aria-label="${lineContent} line"
125
+ ${UI.TreeOutline.TreeSearch.highlight(matchRanges, undefined)}>
127
126
  ${lineContent}
128
127
  </span>
129
128
  </button>
@@ -122,7 +122,7 @@ const allStatusStrings = [
122
122
  const INCOGNITO_EXPLANATION_URL = 'https://support.google.com/chrome/answer/95464?hl=en&co=GENIE.Platform%3DDesktop' as
123
123
  Platform.DevToolsPath.UrlString;
124
124
 
125
- // A simplified representation of a network request for mock data.
125
+ /** A simplified representation of a network request for mock data. **/
126
126
  interface MockNetworkRequest {
127
127
  requestId: string;
128
128
  url: string;
@@ -86,6 +86,10 @@ hr.section-separator {
86
86
  height: 18px;
87
87
  }
88
88
 
89
+ .input-field::placeholder {
90
+ color: var(--sys-color-on-surface-subtle);
91
+ }
92
+
89
93
  .input-field:focus {
90
94
  border: 1px solid var(--sys-color-state-focus-ring);
91
95
  outline-width: 0;
@@ -65,8 +65,10 @@ export interface Boolean {
65
65
  value: boolean;
66
66
  }
67
67
 
68
- // bare-item = sf-integer / sf-decimal / sf-string / sf-token
69
- // / sf-binary / sf-boolean
68
+ /**
69
+ * bare-item = sf-integer / sf-decimal / sf-string / sf-token
70
+ * / sf-binary / sf-boolean
71
+ **/
70
72
  export type BareItem = Integer|Decimal|String|Token|Binary|Boolean;
71
73
 
72
74
  export interface ParamName {
@@ -74,39 +76,43 @@ export interface ParamName {
74
76
  value: string;
75
77
  }
76
78
 
77
- // parameter = param-name [ "=" param-value ]
78
- // param-value = bare-item
79
+ /**
80
+ * parameter = param-name [ "=" param-value ]
81
+ * param-value = bare-item
82
+ **/
79
83
  export interface Parameter {
80
84
  kind: ResultKind.PARAMETER;
81
85
  name: ParamName;
82
86
  value: BareItem;
83
87
  }
84
88
 
85
- // parameters = *( ";" *SP parameter )
89
+ /** parameters = *( ";" *SP parameter ) **/
86
90
  export interface Parameters {
87
91
  kind: ResultKind.PARAMETERS;
88
92
  items: Parameter[];
89
93
  }
90
94
 
91
- // sf-item = bare-item parameters
95
+ /** sf-item = bare-item parameters **/
92
96
  export interface Item {
93
97
  kind: ResultKind.ITEM;
94
98
  value: BareItem;
95
99
  parameters: Parameters;
96
100
  }
97
101
 
98
- // inner-list = "(" *SP [ sf-item *( 1*SP sf-item ) *SP ] ")"
99
- // parameters
102
+ /**
103
+ * inner-list = "(" *SP [ sf-item *( 1*SP sf-item ) *SP ] ")"
104
+ * parameters
105
+ **/
100
106
  export interface InnerList {
101
107
  kind: ResultKind.INNER_LIST;
102
108
  items: Item[];
103
109
  parameters: Parameters;
104
110
  }
105
111
 
106
- // list-member = sf-item / inner-list
112
+ /** list-member = sf-item / inner-list **/
107
113
  export type ListMember = Item|InnerList;
108
114
 
109
- // sf-list = list-member *( OWS "," OWS list-member )
115
+ /** sf-list = list-member *( OWS "," OWS list-member ) **/
110
116
  export interface List {
111
117
  kind: ResultKind.LIST;
112
118
  items: ListMember[];
@@ -149,9 +155,11 @@ const CHAR_TILDE: number = '~'.charCodeAt(0);
149
155
  const CHAR_MIN_ASCII_PRINTABLE = 0x20;
150
156
  const CHAR_MAX_ASCII_PRINTABLE = 0x7e;
151
157
 
152
- // Note: structured headers operates over ASCII, not unicode, so these are
153
- // all indeed supposed to return false on things outside 32-127 range regardless
154
- // of them being other kinds of digits or letters.
158
+ /**
159
+ * Note: structured headers operates over ASCII, not unicode, so these are
160
+ * all indeed supposed to return false on things outside 32-127 range regardless
161
+ * of them being other kinds of digits or letters.
162
+ **/
155
163
  function isDigit(charCode: number|undefined): boolean {
156
164
  // DIGIT = %x30-39 ; 0-9 (from RFC 5234)
157
165
  if (charCode === undefined) {
@@ -262,7 +270,7 @@ function makeError(): Error {
262
270
  return {kind: ResultKind.ERROR};
263
271
  }
264
272
 
265
- // 4.2.1. Parsing a list
273
+ /** 4.2.1. Parsing a list **/
266
274
  function parseListInternal(input: Input): List|Error {
267
275
  const result: List = {kind: ResultKind.LIST, items: []};
268
276
 
@@ -291,7 +299,7 @@ function parseListInternal(input: Input): List|Error {
291
299
  return result; // this case corresponds to an empty list.
292
300
  }
293
301
 
294
- // 4.2.1.1. Parsing an Item or Inner List
302
+ /** 4.2.1.1. Parsing an Item or Inner List **/
295
303
  function parseItemOrInnerList(input: Input): ListMember|Error {
296
304
  if (input.peek() === '(') {
297
305
  return parseInnerList(input);
@@ -299,7 +307,7 @@ function parseItemOrInnerList(input: Input): ListMember|Error {
299
307
  return parseItemInternal(input);
300
308
  }
301
309
 
302
- // 4.2.1.2. Parsing an Inner List
310
+ /** 4.2.1.2. Parsing an Inner List **/
303
311
  function parseInnerList(input: Input): InnerList|Error {
304
312
  if (input.peek() !== '(') {
305
313
  return makeError();
@@ -335,7 +343,7 @@ function parseInnerList(input: Input): InnerList|Error {
335
343
  return makeError();
336
344
  }
337
345
 
338
- // 4.2.3. Parsing an Item
346
+ /** 4.2.3. Parsing an Item **/
339
347
  function parseItemInternal(input: Input): Item|Error {
340
348
  const bareItem: BareItem|Error = parseBareItem(input);
341
349
  if (bareItem.kind === ResultKind.ERROR) {
@@ -348,7 +356,7 @@ function parseItemInternal(input: Input): Item|Error {
348
356
  return {kind: ResultKind.ITEM, value: bareItem, parameters: params};
349
357
  }
350
358
 
351
- // 4.2.3.1. Parsing a Bare Item
359
+ /** 4.2.3.1. Parsing a Bare Item **/
352
360
  function parseBareItem(input: Input): BareItem|Error {
353
361
  const upcoming = input.peekCharCode();
354
362
  if (upcoming === CHAR_MINUS || isDigit(upcoming)) {
@@ -369,7 +377,7 @@ function parseBareItem(input: Input): BareItem|Error {
369
377
  return makeError();
370
378
  }
371
379
 
372
- // 4.2.3.2. Parsing Parameters
380
+ /** 4.2.3.2. Parsing Parameters **/
373
381
  function parseParameters(input: Input): Parameters|Error {
374
382
  // The main noteworthy thing here is handling of duplicates and ordering:
375
383
  //
@@ -413,7 +421,7 @@ function parseParameters(input: Input): Parameters|Error {
413
421
  return {kind: ResultKind.PARAMETERS, items: [...items.values()]};
414
422
  }
415
423
 
416
- // 4.2.3.3. Parsing a Key
424
+ /** 4.2.3.3. Parsing a Key **/
417
425
  function parseKey(input: Input): ParamName|Error {
418
426
  let outputString = '';
419
427
  const first = input.peekCharCode();
@@ -434,7 +442,7 @@ function parseKey(input: Input): ParamName|Error {
434
442
  return {kind: ResultKind.PARAM_NAME, value: outputString};
435
443
  }
436
444
 
437
- // 4.2.4. Parsing an Integer or Decimal
445
+ /** 4.2.4. Parsing an Integer or Decimal **/
438
446
  function parseIntegerOrDecimal(input: Input): Integer|Decimal|Error {
439
447
  let resultKind = ResultKind.INTEGER;
440
448
  let sign = 1;
@@ -486,7 +494,7 @@ function parseIntegerOrDecimal(input: Input): Integer|Decimal|Error {
486
494
  return {kind: ResultKind.DECIMAL, value: sign * Number.parseFloat(inputNumber)};
487
495
  }
488
496
 
489
- // 4.2.5. Parsing a String
497
+ /** 4.2.5. Parsing a String **/
490
498
  function parseString(input: Input): String|Error {
491
499
  let outputString = '';
492
500
  if (input.peek() !== '"') {
@@ -524,7 +532,7 @@ function parseString(input: Input): String|Error {
524
532
  return makeError();
525
533
  }
526
534
 
527
- // 4.2.6. Parsing a Token
535
+ /** 4.2.6. Parsing a Token **/
528
536
  function parseToken(input: Input): Token|Error {
529
537
  const first = input.peekCharCode();
530
538
  if (first !== CHAR_STAR && !isAlpha(first)) {
@@ -542,7 +550,7 @@ function parseToken(input: Input): Token|Error {
542
550
  return {kind: ResultKind.TOKEN, value: outputString};
543
551
  }
544
552
 
545
- // 4.2.7. Parsing a Byte Sequence
553
+ /** 4.2.7. Parsing a Byte Sequence **/
546
554
  function parseByteSequence(input: Input): Binary|Error {
547
555
  let outputString = '';
548
556
  if (input.peek() !== ':') {
@@ -571,7 +579,7 @@ function parseByteSequence(input: Input): Binary|Error {
571
579
  return makeError();
572
580
  }
573
581
 
574
- // 4.2.8. Parsing a Boolean
582
+ /** 4.2.8. Parsing a Boolean **/
575
583
  function parseBoolean(input: Input): Boolean|Error {
576
584
  if (input.peek() !== '?') {
577
585
  return makeError();
@@ -602,7 +610,7 @@ export function parseList(input: string): List|Error {
602
610
  return parseListInternal(new Input(input));
603
611
  }
604
612
 
605
- // 4.1.3. Serializing an Item
613
+ /** 4.1.3. Serializing an Item **/
606
614
  export function serializeItem(input: Item): SerializationResult|Error {
607
615
  const bareItemVal = serializeBareItem(input.value);
608
616
  if (bareItemVal.kind === ResultKind.ERROR) {
@@ -615,7 +623,7 @@ export function serializeItem(input: Item): SerializationResult|Error {
615
623
  return {kind: ResultKind.SERIALIZATION_RESULT, value: bareItemVal.value + paramVal.value};
616
624
  }
617
625
 
618
- // 4.1.1. Serializing a List
626
+ /** 4.1.1. Serializing a List **/
619
627
  export function serializeList(input: List): SerializationResult|Error {
620
628
  const outputPieces: string[] = [];
621
629
  for (let i = 0; i < input.items.length; ++i) {
@@ -638,7 +646,7 @@ export function serializeList(input: List): SerializationResult|Error {
638
646
  return {kind: ResultKind.SERIALIZATION_RESULT, value: output};
639
647
  }
640
648
 
641
- // 4.1.1.1. Serializing an Inner List
649
+ /** 4.1.1.1. Serializing an Inner List **/
642
650
  function serializeInnerList(input: InnerList): SerializationResult|Error {
643
651
  const outputPieces: string[] = [];
644
652
  for (let i = 0; i < input.items.length; ++i) {
@@ -657,7 +665,7 @@ function serializeInnerList(input: InnerList): SerializationResult|Error {
657
665
  return {kind: ResultKind.SERIALIZATION_RESULT, value: output};
658
666
  }
659
667
 
660
- // 4.1.1.2. Serializing Parameters
668
+ /** 4.1.1.2. Serializing Parameters **/
661
669
  function serializeParameters(input: Parameters): SerializationResult|Error {
662
670
  let output = '';
663
671
  for (const item of input.items) {
@@ -680,7 +688,7 @@ function serializeParameters(input: Parameters): SerializationResult|Error {
680
688
  return {kind: ResultKind.SERIALIZATION_RESULT, value: output};
681
689
  }
682
690
 
683
- // 4.1.1.3. Serializing a Key
691
+ /** 4.1.1.3. Serializing a Key **/
684
692
  function serializeKey(input: ParamName): SerializationResult|Error {
685
693
  if (input.value.length === 0) {
686
694
  return makeError();
@@ -701,7 +709,7 @@ function serializeKey(input: ParamName): SerializationResult|Error {
701
709
  return {kind: ResultKind.SERIALIZATION_RESULT, value: input.value};
702
710
  }
703
711
 
704
- // 4.1.3.1. Serializing a Bare Item
712
+ /** 4.1.3.1. Serializing a Bare Item **/
705
713
  function serializeBareItem(input: BareItem): SerializationResult|Error {
706
714
  if (input.kind === ResultKind.INTEGER) {
707
715
  return serializeInteger(input);
@@ -724,7 +732,7 @@ function serializeBareItem(input: BareItem): SerializationResult|Error {
724
732
  return makeError();
725
733
  }
726
734
 
727
- // 4.1.4. Serializing an Integer
735
+ /** 4.1.4. Serializing an Integer **/
728
736
  function serializeInteger(input: Integer): SerializationResult|Error {
729
737
  if (input.value < -999999999999999 || input.value > 999999999999999 || !Number.isInteger(input.value)) {
730
738
  return makeError();
@@ -732,12 +740,12 @@ function serializeInteger(input: Integer): SerializationResult|Error {
732
740
  return {kind: ResultKind.SERIALIZATION_RESULT, value: input.value.toString(10)};
733
741
  }
734
742
 
735
- // 4.1.5. Serializing a Decimal
743
+ /** 4.1.5. Serializing a Decimal **/
736
744
  function serializeDecimal(_input: Decimal): SerializationResult|Error {
737
745
  throw new Error('Unimplemented');
738
746
  }
739
747
 
740
- // 4.1.6. Serializing a String
748
+ /** 4.1.6. Serializing a String **/
741
749
  function serializeString(input: String): SerializationResult|Error {
742
750
  // Only printable ASCII strings are supported by the spec.
743
751
  for (let i = 0; i < input.value.length; ++i) {
@@ -759,7 +767,7 @@ function serializeString(input: String): SerializationResult|Error {
759
767
  return {kind: ResultKind.SERIALIZATION_RESULT, value: output};
760
768
  }
761
769
 
762
- // 4.1.7. Serializing a Token
770
+ /** 4.1.7. Serializing a Token **/
763
771
  function serializeToken(input: Token): SerializationResult|Error {
764
772
  if (input.value.length === 0) {
765
773
  return makeError();
@@ -779,12 +787,12 @@ function serializeToken(input: Token): SerializationResult|Error {
779
787
  return {kind: ResultKind.SERIALIZATION_RESULT, value: input.value};
780
788
  }
781
789
 
782
- // 4.1.8. Serializing a Byte Sequence
790
+ /** 4.1.8. Serializing a Byte Sequence **/
783
791
  function serializeByteSequence(_input: Binary): SerializationResult|Error {
784
792
  throw new Error('Unimplemented');
785
793
  }
786
794
 
787
- // 4.1.9. Serializing a Boolean
795
+ /** 4.1.9. Serializing a Boolean **/
788
796
  function serializeBoolean(input: Boolean): SerializationResult|Error {
789
797
  return {kind: ResultKind.SERIALIZATION_RESULT, value: input.value ? '?1' : '?0'};
790
798
  }
@@ -234,15 +234,17 @@ function findDifferentiatingPath(url: string[], allUrls: string[][], startIndex:
234
234
  return differentiatingPath;
235
235
  }
236
236
 
237
- // This function tries to find a subpath (if available) that we can use to differentiate
238
- // urls that have the same file name.
239
- // It does so by 1. removing common suffixes, 2. taking segments of the path (from right to left) until the path is
240
- // unique.
241
- //
242
- // Example:
243
- //
244
- // Paths: 'http://www.google.com/src/a/index.js', 'http://www.google.com/src2/a/index.js'
245
- // Output: 'src/…/', 'src2/…/'
237
+ /**
238
+ * This function tries to find a subpath (if available) that we can use to differentiate
239
+ * urls that have the same file name.
240
+ * It does so by 1. removing common suffixes, 2. taking segments of the path (from right to left) until the path is
241
+ * unique.
242
+ *
243
+ * Example:
244
+ *
245
+ * Paths: 'http://www.google.com/src/a/index.js', 'http://www.google.com/src2/a/index.js'
246
+ * Output: 'src/…/', 'src2/…/'
247
+ **/
246
248
  function populateDifferentiatingPathMap(
247
249
  urls: Platform.DevToolsPath.UrlString[], urlToDifferentiator: Map<Platform.DevToolsPath.UrlString, string>): void {
248
250
  const splitReversedUrls = urls.map(url => {
@@ -1765,8 +1765,10 @@ export class BreakpointLocationRevealer implements
1765
1765
  }
1766
1766
  }
1767
1767
 
1768
- // Enumerate non-breakable lines (lines without a known corresponding
1769
- // position in the UISource).
1768
+ /**
1769
+ * Enumerate non-breakable lines (lines without a known corresponding
1770
+ * position in the UISource).
1771
+ **/
1770
1772
  async function computeNonBreakableLines(
1771
1773
  state: CodeMirror.EditorState, transformer: SourceFrame.SourceFrame.Transformer,
1772
1774
  sourceCode: Workspace.UISourceCode.UISourceCode): Promise<readonly number[]> {
@@ -2043,8 +2045,10 @@ export function getVariableNamesByLine(
2043
2045
  toPos = editorState.doc.lineAt(toPos).from;
2044
2046
  const tree = CodeMirror.syntaxTree(editorState);
2045
2047
 
2046
- // Sibling scope is a scope that does not contain the current position.
2047
- // We will exclude variables that are defined (and used in those scopes (since we are currently outside of their lifetime).
2048
+ /**
2049
+ * Sibling scope is a scope that does not contain the current position.
2050
+ * We will exclude variables that are defined (and used in those scopes (since we are currently outside of their lifetime).
2051
+ **/
2048
2052
  function isSiblingScopeNode(node: {name: string, from: number, to: number}): boolean {
2049
2053
  return isScopeNode(node.name) && (node.to < currentPos || currentPos < node.from);
2050
2054
  }
@@ -632,7 +632,7 @@ export class SourcesPanel extends UI.Panel.Panel implements
632
632
 
633
633
  private addExperimentMenuItem(
634
634
  menuSection: UI.ContextMenu.Section, experiment: string, menuItem: Common.UIString.LocalizedString): void {
635
- // menu handler
635
+ /** menu handler **/
636
636
  function toggleExperiment(): void {
637
637
  const checked = Root.Runtime.experiments.isEnabled(experiment);
638
638
  Root.Runtime.experiments.setEnabled(experiment, !checked);
@@ -663,7 +663,7 @@ const setRowMessages = CodeMirror.StateEffect.define<RowMessages>();
663
663
 
664
664
  const underlineMark = CodeMirror.Decoration.mark({class: 'cm-waveUnderline'});
665
665
 
666
- // The widget shown at the end of a message annotation.
666
+ /** The widget shown at the end of a message annotation. **/
667
667
  class MessageWidget extends CodeMirror.WidgetType {
668
668
  constructor(readonly messages: RowMessage[]) {
669
669
  super();
@@ -150,8 +150,10 @@ export const TrackNames = [
150
150
  'Extension',
151
151
  'ServerTimings',
152
152
  ] as const;
153
- // Network track will use TrackAppender interface, but it won't be shown in Main flamechart.
154
- // So manually add it to TrackAppenderName.
153
+ /**
154
+ * Network track will use TrackAppender interface, but it won't be shown in Main flamechart.
155
+ * So manually add it to TrackAppenderName.
156
+ **/
155
157
  export type TrackAppenderName = typeof TrackNames[number]|'Network';
156
158
 
157
159
  export type DrawOverride = PerfUI.FlameChart.DrawOverride;