chrome-devtools-frontend 1.0.950850 → 1.0.952284

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 (379) hide show
  1. package/config/gni/devtools_grd_files.gni +3 -3
  2. package/extension-api/ExtensionAPI.d.ts +1 -1
  3. package/front_end/.eslintrc.js +6 -0
  4. package/front_end/Tests.js +10 -0
  5. package/front_end/core/common/App.ts +0 -3
  6. package/front_end/core/common/AppProvider.ts +0 -3
  7. package/front_end/core/common/JavaScriptMetaData.ts +0 -3
  8. package/front_end/core/common/QueryParamHandler.ts +0 -3
  9. package/front_end/core/common/Runnable.ts +0 -3
  10. package/front_end/core/common/SimpleHistoryManager.ts +0 -3
  11. package/front_end/core/i18n/locales/en-US.json +183 -183
  12. package/front_end/core/i18n/locales/en-XL.json +183 -183
  13. package/front_end/core/sdk/CSSRule.ts +1 -1
  14. package/front_end/core/sdk/DOMModel.ts +12 -37
  15. package/front_end/core/sdk/OverlayModel.ts +18 -34
  16. package/front_end/core/sdk/OverlayPersistentHighlighter.ts +0 -12
  17. package/front_end/core/sdk/RuntimeModel.ts +0 -1
  18. package/front_end/core/sdk/SourceMap.ts +1 -1
  19. package/front_end/core/sdk/TracingManager.ts +0 -3
  20. package/front_end/entrypoints/formatter_worker/AcornTokenizer.ts +36 -36
  21. package/front_end/entrypoints/formatter_worker/CSSFormatter.ts +53 -53
  22. package/front_end/entrypoints/formatter_worker/ESTreeWalker.ts +11 -11
  23. package/front_end/entrypoints/formatter_worker/FormattedContentBuilder.ts +43 -43
  24. package/front_end/entrypoints/formatter_worker/HTMLFormatter.ts +106 -105
  25. package/front_end/entrypoints/formatter_worker/JavaScriptFormatter.ts +26 -26
  26. package/front_end/entrypoints/heap_snapshot_worker/AllocationProfile.ts +51 -56
  27. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +201 -204
  28. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotLoader.ts +84 -83
  29. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotWorkerDispatcher.ts +16 -16
  30. package/front_end/entrypoints/inspector_main/InspectorMain.ts +21 -21
  31. package/front_end/entrypoints/main/ExecutionContextSelector.ts +30 -30
  32. package/front_end/entrypoints/main/MainImpl.ts +12 -12
  33. package/front_end/entrypoints/node_app/NodeConnectionsPanel.ts +33 -33
  34. package/front_end/entrypoints/node_app/NodeMain.ts +35 -35
  35. package/front_end/generated/InspectorBackendCommands.js +5 -1
  36. package/front_end/generated/protocol.d.ts +16 -0
  37. package/front_end/models/bindings/CSSWorkspaceBinding.ts +0 -3
  38. package/front_end/models/bindings/DebuggerLanguagePlugins.ts +1 -2
  39. package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +1 -4
  40. package/front_end/models/bindings/FileUtils.ts +0 -4
  41. package/front_end/models/bindings/IgnoreListManager.ts +1 -2
  42. package/front_end/models/bindings/NetworkProject.ts +1 -2
  43. package/front_end/models/extensions/ExtensionAPI.ts +2 -2
  44. package/front_end/models/extensions/ExtensionTraceProvider.ts +0 -3
  45. package/front_end/models/issues_manager/ContentSecurityPolicyIssue.ts +6 -6
  46. package/front_end/models/issues_manager/ContrastCheckTrigger.ts +15 -15
  47. package/front_end/models/issues_manager/CorsIssue.ts +9 -9
  48. package/front_end/models/issues_manager/CrossOriginEmbedderPolicyIssue.ts +5 -5
  49. package/front_end/models/issues_manager/DeprecationIssue.ts +7 -7
  50. package/front_end/models/issues_manager/GenericIssue.ts +5 -5
  51. package/front_end/models/issues_manager/HeavyAdIssue.ts +5 -5
  52. package/front_end/models/issues_manager/Issue.ts +10 -10
  53. package/front_end/models/issues_manager/IssueResolver.ts +11 -10
  54. package/front_end/models/issues_manager/IssuesManager.ts +56 -56
  55. package/front_end/models/issues_manager/LowTextContrastIssue.ts +4 -4
  56. package/front_end/models/issues_manager/MixedContentIssue.ts +7 -7
  57. package/front_end/models/issues_manager/NavigatorUserAgentIssue.ts +7 -7
  58. package/front_end/models/issues_manager/QuirksModeIssue.ts +4 -4
  59. package/front_end/models/issues_manager/SameSiteCookieIssue.ts +17 -18
  60. package/front_end/models/issues_manager/SharedArrayBufferIssue.ts +5 -5
  61. package/front_end/models/issues_manager/SourceFrameIssuesManager.ts +32 -31
  62. package/front_end/models/issues_manager/TrustedWebActivityIssue.ts +5 -5
  63. package/front_end/models/issues_manager/WasmCrossOriginModuleSharingIssue.ts +5 -5
  64. package/front_end/models/timeline_model/TimelineModel.ts +1 -1
  65. package/front_end/models/timeline_model/TracingLayerTree.ts +0 -1
  66. package/front_end/panels/accessibility/ARIAMetadata.ts +0 -1
  67. package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +2 -2
  68. package/front_end/panels/accessibility/AccessibilityNodeView.ts +1 -2
  69. package/front_end/panels/animation/AnimationTimeline.ts +0 -1
  70. package/front_end/panels/application/ApplicationPanelCacheSection.ts +3 -4
  71. package/front_end/panels/application/ServiceWorkerUpdateCycleView.ts +0 -2
  72. package/front_end/panels/application/StorageView.ts +2 -6
  73. package/front_end/panels/application/{BackForwardCacheStrings.ts → components/BackForwardCacheStrings.ts} +2 -2
  74. package/front_end/panels/application/{BackForwardCacheView.ts → components/BackForwardCacheView.ts} +96 -62
  75. package/front_end/panels/application/components/EndpointsGrid.ts +12 -12
  76. package/front_end/panels/application/components/FrameDetailsView.ts +108 -110
  77. package/front_end/panels/application/components/OriginTrialTreeView.ts +45 -45
  78. package/front_end/panels/application/components/PermissionsPolicySection.ts +19 -19
  79. package/front_end/panels/application/components/ReportsGrid.ts +30 -30
  80. package/front_end/panels/application/components/StackTrace.ts +48 -47
  81. package/front_end/panels/application/components/TrustTokensView.ts +31 -31
  82. package/front_end/panels/application/{backForwardCacheView.css → components/backForwardCacheView.css} +9 -0
  83. package/front_end/panels/application/components/components.ts +2 -0
  84. package/front_end/panels/console/ConsoleViewMessage.ts +1 -25
  85. package/front_end/panels/console/consoleView.css +5 -0
  86. package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +41 -52
  87. package/front_end/panels/css_overview/CSSOverviewController.ts +2 -2
  88. package/front_end/panels/css_overview/CSSOverviewPanel.ts +18 -27
  89. package/front_end/panels/css_overview/CSSOverviewProcessingView.ts +2 -2
  90. package/front_end/panels/css_overview/CSSOverviewSidebarPanel.ts +6 -6
  91. package/front_end/panels/css_overview/components/CSSOverviewStartView.ts +4 -4
  92. package/front_end/panels/elements/ComputedStyleModel.ts +2 -2
  93. package/front_end/panels/elements/ElementsPanel.ts +1 -5
  94. package/front_end/panels/elements/ElementsTreeElement.ts +2 -6
  95. package/front_end/panels/elements/ElementsTreeOutline.ts +2 -2
  96. package/front_end/panels/elements/StylesSidebarPane.ts +1 -1
  97. package/front_end/panels/elements/components/AccessibilityTreeNode.ts +17 -17
  98. package/front_end/panels/elements/components/AdornerManager.ts +21 -21
  99. package/front_end/panels/elements/components/AdornerSettingsPane.ts +14 -14
  100. package/front_end/panels/elements/components/CSSQuery.ts +16 -16
  101. package/front_end/panels/elements/components/ComputedStyleProperty.ts +14 -14
  102. package/front_end/panels/elements/components/ComputedStyleTrace.ts +15 -15
  103. package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +78 -78
  104. package/front_end/panels/elements/components/ElementsPanelLink.ts +16 -16
  105. package/front_end/panels/elements/components/LayoutPane.ts +47 -47
  106. package/front_end/panels/elements/components/NodeText.ts +18 -18
  107. package/front_end/panels/elements/components/QueryContainer.ts +40 -40
  108. package/front_end/panels/elements/components/StylePropertyEditor.ts +18 -18
  109. package/front_end/panels/emulation/components/DeviceSizeInputElement.ts +4 -4
  110. package/front_end/panels/event_listeners/EventListenersUtils.ts +2 -1
  111. package/front_end/panels/issues/AffectedBlockedByResponseView.ts +4 -4
  112. package/front_end/panels/issues/AffectedCookiesView.ts +4 -5
  113. package/front_end/panels/issues/AffectedDirectivesView.ts +19 -19
  114. package/front_end/panels/issues/AffectedDocumentsInQuirksModeView.ts +7 -8
  115. package/front_end/panels/issues/AffectedElementsView.ts +4 -4
  116. package/front_end/panels/issues/AffectedElementsWithLowContrastView.ts +7 -8
  117. package/front_end/panels/issues/AffectedHeavyAdView.ts +8 -8
  118. package/front_end/panels/issues/AffectedResourcesView.ts +25 -26
  119. package/front_end/panels/issues/AffectedSharedArrayBufferIssueDetailsView.ts +8 -8
  120. package/front_end/panels/issues/AffectedSourcesView.ts +4 -4
  121. package/front_end/panels/issues/AffectedTrustedWebActivityIssueDetailsView.ts +4 -4
  122. package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +17 -17
  123. package/front_end/panels/issues/CSPViolationsListView.ts +22 -23
  124. package/front_end/panels/issues/CSPViolationsView.ts +17 -17
  125. package/front_end/panels/issues/ComboBoxOfCheckBoxes.ts +13 -13
  126. package/front_end/panels/issues/CorsIssueDetailsView.ts +23 -23
  127. package/front_end/panels/issues/GenericIssueDetailsView.ts +4 -4
  128. package/front_end/panels/issues/HiddenIssuesRow.ts +7 -7
  129. package/front_end/panels/issues/IssueAggregator.ts +95 -95
  130. package/front_end/panels/issues/IssueKindView.ts +14 -14
  131. package/front_end/panels/issues/IssueView.ts +98 -98
  132. package/front_end/panels/issues/IssuesPane.ts +102 -102
  133. package/front_end/panels/issues/WasmCrossOriginModuleSharingAffectedResourcesView.ts +5 -5
  134. package/front_end/panels/issues/components/HideIssuesMenu.ts +10 -10
  135. package/front_end/panels/layer_viewer/Layers3DView.ts +3 -9
  136. package/front_end/panels/lighthouse/LighthouseController.ts +4 -5
  137. package/front_end/panels/media/PlayerListView.ts +160 -97
  138. package/front_end/panels/media/PlayerMessagesView.ts +1 -0
  139. package/front_end/panels/media/TickingFlameChart.ts +1 -2
  140. package/front_end/panels/media/playerListView.css +58 -0
  141. package/front_end/panels/network/NetworkLogView.ts +2 -6
  142. package/front_end/panels/network/NetworkLogViewColumns.ts +1 -1
  143. package/front_end/panels/network/NetworkWaterfallColumn.ts +2 -4
  144. package/front_end/panels/network/components/RequestTrustTokensView.ts +40 -40
  145. package/front_end/panels/network/components/WebBundleInfoView.ts +9 -9
  146. package/front_end/panels/performance_monitor/PerformanceMonitor.ts +6 -12
  147. package/front_end/panels/profiler/HeapProfileView.ts +1 -1
  148. package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +0 -1
  149. package/front_end/panels/profiler/HeapSnapshotView.ts +1 -2
  150. package/front_end/panels/profiler/heapProfiler.css +1 -1
  151. package/front_end/panels/search/SearchConfig.ts +0 -6
  152. package/front_end/panels/security/SecurityModel.ts +2 -4
  153. package/front_end/panels/security/SecurityPanel.ts +2 -2
  154. package/front_end/panels/settings/KeybindsSettingsTab.ts +4 -0
  155. package/front_end/panels/settings/components/SyncSection.ts +14 -14
  156. package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +96 -96
  157. package/front_end/panels/settings/settingsScreen.css +8 -3
  158. package/front_end/panels/sources/BreakpointEditDialog.ts +4 -3
  159. package/front_end/panels/sources/FilteredUISourceCodeListProvider.ts +2 -2
  160. package/front_end/panels/sources/NavigatorView.ts +4 -10
  161. package/front_end/panels/sources/ScopeChainSidebarPane.ts +2 -3
  162. package/front_end/panels/sources/SourceMapNamesResolver.ts +3 -3
  163. package/front_end/panels/sources/SourcesPanel.ts +1 -3
  164. package/front_end/panels/sources/SourcesView.ts +0 -3
  165. package/front_end/panels/sources/TabbedEditorContainer.ts +1 -4
  166. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +2 -5
  167. package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +0 -1
  168. package/front_end/panels/timeline/TimelineFlameChartView.ts +0 -1
  169. package/front_end/panels/timeline/TimelineLoader.ts +0 -3
  170. package/front_end/panels/timeline/TimelinePanel.ts +2 -3
  171. package/front_end/panels/timeline/TimelineUIUtils.ts +1 -1
  172. package/front_end/panels/timeline/components/WebVitalsLane.ts +77 -76
  173. package/front_end/panels/timeline/components/WebVitalsTimeline.ts +133 -133
  174. package/front_end/panels/timeline/components/WebVitalsTooltip.ts +9 -9
  175. package/front_end/panels/webauthn/WebauthnPane.ts +203 -205
  176. package/front_end/third_party/codemirror.next/bundle.ts +3 -3
  177. package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
  178. package/front_end/third_party/codemirror.next/chunk/markdown.js +2 -1
  179. package/front_end/third_party/codemirror.next/codemirror.next.d.ts +10 -1
  180. package/front_end/third_party/codemirror.next/codemirror.next.js +2 -1
  181. package/front_end/third_party/codemirror.next/package.json +3 -3
  182. package/front_end/third_party/puppeteer/package/README.md +11 -11
  183. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api-docs-entry.d.ts +4 -5
  184. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/AriaQueryHandler.js +2 -2
  185. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/AriaQueryHandler.js.map +1 -1
  186. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Browser.d.ts +4 -6
  187. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/BrowserConnector.d.ts +1 -2
  188. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Connection.d.ts +1 -4
  189. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Coverage.d.ts +1 -4
  190. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.d.ts +9 -7
  191. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.d.ts.map +1 -1
  192. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.js +21 -12
  193. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.js.map +1 -1
  194. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Dialog.d.ts +1 -3
  195. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/EvalTypes.d.ts +1 -2
  196. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/ExecutionContext.d.ts +3 -5
  197. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FileChooser.d.ts +1 -3
  198. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.d.ts +8 -10
  199. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.js +3 -3
  200. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.js.map +1 -1
  201. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.d.ts +50 -11
  202. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.d.ts.map +1 -1
  203. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.js +70 -33
  204. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.js.map +1 -1
  205. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.d.ts +12 -5
  206. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.d.ts.map +1 -1
  207. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.js +25 -5
  208. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.js.map +1 -1
  209. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Input.d.ts +2 -4
  210. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.d.ts +39 -6
  211. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.d.ts.map +1 -1
  212. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.js +36 -0
  213. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.js.map +1 -1
  214. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.d.ts +3 -4
  215. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.d.ts.map +1 -1
  216. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.js +2 -1
  217. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.js.map +1 -1
  218. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.d.ts +46 -0
  219. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.d.ts.map +1 -0
  220. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.js +124 -0
  221. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.js.map +1 -0
  222. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.d.ts +27 -10
  223. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.d.ts.map +1 -1
  224. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.js +144 -74
  225. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.js.map +1 -1
  226. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Puppeteer.d.ts +5 -6
  227. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.d.ts +1 -2
  228. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Target.d.ts +4 -6
  229. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/WebWorker.d.ts +3 -5
  230. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.d.ts +4 -5
  231. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.d.ts.map +1 -1
  232. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.js +43 -17
  233. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.js.map +1 -1
  234. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/LaunchOptions.d.ts +1 -1
  235. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.d.ts +1 -3
  236. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.d.ts.map +1 -1
  237. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.js +101 -34
  238. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.js.map +1 -1
  239. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/NodeWebSocketTransport.d.ts +1 -3
  240. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PipeTransport.d.ts +1 -2
  241. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Puppeteer.d.ts +5 -7
  242. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +1 -1
  243. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api-docs-entry.d.ts +4 -5
  244. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/AriaQueryHandler.js +2 -2
  245. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/AriaQueryHandler.js.map +1 -1
  246. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Browser.d.ts +4 -6
  247. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Browser.js +2 -3
  248. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/BrowserConnector.d.ts +1 -2
  249. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/BrowserConnector.js +3 -5
  250. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Connection.d.ts +1 -4
  251. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Coverage.d.ts +1 -4
  252. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Coverage.js +1 -2
  253. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.d.ts +9 -7
  254. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.d.ts.map +1 -1
  255. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.js +24 -17
  256. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.js.map +1 -1
  257. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Dialog.d.ts +1 -3
  258. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/EvalTypes.d.ts +1 -2
  259. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/ExecutionContext.d.ts +3 -5
  260. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FileChooser.d.ts +1 -3
  261. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.d.ts +8 -10
  262. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.js +7 -8
  263. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.js.map +1 -1
  264. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.d.ts +50 -11
  265. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.d.ts.map +1 -1
  266. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.js +70 -34
  267. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.js.map +1 -1
  268. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.d.ts +12 -5
  269. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.d.ts.map +1 -1
  270. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.js +26 -7
  271. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.js.map +1 -1
  272. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Input.d.ts +2 -4
  273. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.d.ts +39 -6
  274. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.d.ts.map +1 -1
  275. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.js +38 -4
  276. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.js.map +1 -1
  277. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.d.ts +3 -4
  278. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.d.ts.map +1 -1
  279. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.js +4 -4
  280. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.js.map +1 -1
  281. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.d.ts +46 -0
  282. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.d.ts.map +1 -0
  283. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.js +120 -0
  284. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.js.map +1 -0
  285. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.d.ts +27 -10
  286. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.d.ts.map +1 -1
  287. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.js +144 -75
  288. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.js.map +1 -1
  289. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Page.js +12 -14
  290. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Puppeteer.d.ts +5 -6
  291. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Puppeteer.js +3 -4
  292. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.d.ts +1 -2
  293. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Target.d.ts +4 -6
  294. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/WebWorker.d.ts +3 -5
  295. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/WebWorker.js +1 -2
  296. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/helper.js +3 -5
  297. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/initialize-node.js +1 -3
  298. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserFetcher.js +10 -12
  299. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.d.ts +4 -5
  300. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.d.ts.map +1 -1
  301. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.js +43 -20
  302. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.js.map +1 -1
  303. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/LaunchOptions.d.ts +1 -1
  304. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.d.ts +1 -3
  305. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.d.ts.map +1 -1
  306. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.js +104 -40
  307. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.js.map +1 -1
  308. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/NodeWebSocketTransport.d.ts +1 -3
  309. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.d.ts +1 -2
  310. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.js +1 -2
  311. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Puppeteer.d.ts +5 -7
  312. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Puppeteer.js +1 -3
  313. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/install.js +3 -5
  314. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node-puppeteer-core.js +1 -2
  315. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node.js +1 -2
  316. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +1 -1
  317. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/web.js +1 -2
  318. package/front_end/third_party/puppeteer/package/lib/types.d.ts +173 -36
  319. package/front_end/third_party/puppeteer/package/package.json +3 -3
  320. package/front_end/ui/components/adorners/Adorner.ts +2 -2
  321. package/front_end/ui/components/buttons/Button.ts +9 -9
  322. package/front_end/ui/components/data_grid/DataGrid.ts +62 -62
  323. package/front_end/ui/components/data_grid/DataGridController.ts +22 -22
  324. package/front_end/ui/components/diff_view/DiffView.ts +6 -6
  325. package/front_end/ui/components/expandable_list/ExpandableList.ts +5 -5
  326. package/front_end/ui/components/icon_button/Icon.ts +4 -4
  327. package/front_end/ui/components/icon_button/IconButton.ts +4 -4
  328. package/front_end/ui/components/issue_counter/IssueCounter.ts +3 -3
  329. package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +11 -11
  330. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspector.ts +50 -50
  331. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorController.ts +6 -6
  332. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorPane.ts +4 -4
  333. package/front_end/ui/components/linear_memory_inspector/LinearMemoryNavigator.ts +12 -12
  334. package/front_end/ui/components/linear_memory_inspector/LinearMemoryValueInterpreter.ts +11 -11
  335. package/front_end/ui/components/linear_memory_inspector/LinearMemoryViewer.ts +40 -39
  336. package/front_end/ui/components/linear_memory_inspector/ValueInterpreterDisplay.ts +18 -18
  337. package/front_end/ui/components/linear_memory_inspector/ValueInterpreterSettings.ts +6 -6
  338. package/front_end/ui/components/linkifier/LinkifierImpl.ts +4 -4
  339. package/front_end/ui/components/markdown_view/MarkdownImage.ts +5 -5
  340. package/front_end/ui/components/markdown_view/MarkdownLink.ts +2 -2
  341. package/front_end/ui/components/markdown_view/MarkdownView.ts +4 -5
  342. package/front_end/ui/components/panel_feedback/FeedbackButton.ts +2 -2
  343. package/front_end/ui/components/panel_feedback/PanelFeedback.ts +2 -2
  344. package/front_end/ui/components/panel_feedback/PreviewToggle.ts +4 -4
  345. package/front_end/ui/components/render_coordinator/RenderCoordinator.ts +22 -22
  346. package/front_end/ui/components/report_view/ReportView.ts +16 -16
  347. package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +14 -14
  348. package/front_end/ui/components/settings/SettingCheckbox.ts +5 -5
  349. package/front_end/ui/components/survey_link/SurveyLink.ts +8 -8
  350. package/front_end/ui/components/text_editor/TextEditor.ts +9 -9
  351. package/front_end/ui/components/text_editor/cursor_tooltip.ts +7 -1
  352. package/front_end/ui/components/text_prompt/TextPrompt.ts +18 -18
  353. package/front_end/ui/components/tree_outline/TreeOutline.ts +69 -70
  354. package/front_end/ui/legacy/ContextFlavorListener.ts +0 -4
  355. package/front_end/ui/legacy/ContextMenu.ts +2 -3
  356. package/front_end/ui/legacy/InspectorView.ts +1 -1
  357. package/front_end/ui/legacy/ReportView.ts +3 -4
  358. package/front_end/ui/legacy/SearchableView.ts +1 -2
  359. package/front_end/ui/legacy/SplitWidget.ts +2 -3
  360. package/front_end/ui/legacy/SuggestBox.ts +0 -3
  361. package/front_end/ui/legacy/TextPrompt.ts +1 -1
  362. package/front_end/ui/legacy/UIUtils.ts +1 -1
  363. package/front_end/ui/legacy/XLink.ts +1 -1
  364. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +2 -2
  365. package/front_end/ui/legacy/components/data_grid/DataGrid.ts +9 -9
  366. package/front_end/ui/legacy/components/data_grid/dataGrid.css +7 -7
  367. package/front_end/ui/legacy/components/inline_editor/CSSShadowEditor.ts +1 -1
  368. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +1 -5
  369. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +0 -1
  370. package/front_end/ui/legacy/components/utils/Linkifier.ts +2 -2
  371. package/front_end/ui/legacy/themeColors.css +2 -0
  372. package/front_end/ui/legacy/theme_support/theme_support_impl.ts +24 -1
  373. package/inspector_overlay/main.ts +16 -2
  374. package/package.json +1 -1
  375. package/scripts/eslint_rules/lib/use_private_class_members.js +41 -0
  376. package/scripts/eslint_rules/tests/use_private_class_members_test.js +62 -0
  377. package/scripts/migration/class-fields/migrate.js +2 -3
  378. package/scripts/migration/class-fields/migrate.sh +1 -3
  379. package/scripts/migration/class-fields/package.json +1 -1
@@ -138,84 +138,84 @@ export function assertInstanceOf<T>(instance: any, constructor: Constructor<T>):
138
138
 
139
139
  export class WebVitalsTimeline extends HTMLElement {
140
140
  static readonly litTagName = LitHtml.literal`devtools-timeline-webvitals`;
141
- private readonly shadow = this.attachShadow({mode: 'open'});
142
- private mainFrameNavigations: readonly number[] = [];
143
- private startTime = 0;
144
- private duration = 1000;
145
- private maxDuration = 1000;
146
- private width = 0;
147
- private height = 0;
148
- private canvas: HTMLCanvasElement;
149
- private hoverLane: number|null = null;
150
-
151
- private fcpLane: WebVitalsEventLane;
152
- private lcpLane: WebVitalsEventLane;
153
- private layoutShiftsLane: WebVitalsEventLane;
154
- private longTasksLane: WebVitalsTimeboxLane;
155
-
156
- private context: CanvasRenderingContext2D;
157
- private animationFrame: number|null = null;
158
-
159
- private overlay: WebVitalsTooltip;
141
+ readonly #shadow = this.attachShadow({mode: 'open'});
142
+ #mainFrameNavigations: readonly number[] = [];
143
+ #startTime = 0;
144
+ #duration = 1000;
145
+ #maxDuration = 1000;
146
+ #width = 0;
147
+ #height = 0;
148
+ #canvas: HTMLCanvasElement;
149
+ #hoverLane: number|null = null;
150
+
151
+ #fcpLane: WebVitalsEventLane;
152
+ #lcpLane: WebVitalsEventLane;
153
+ #layoutShiftsLane: WebVitalsEventLane;
154
+ #longTasksLane: WebVitalsTimeboxLane;
155
+
156
+ #context: CanvasRenderingContext2D;
157
+ #animationFrame: number|null = null;
158
+
159
+ #overlay: WebVitalsTooltip;
160
160
 
161
161
  constructor() {
162
162
  super();
163
163
 
164
- this.canvas = document.createElement('canvas');
165
- this.canvas.style.width = '100%';
166
- this.canvas.style.height = `${Math.max(LINE_HEIGHT * NUMBER_OF_LANES, 120)}px`;
167
- this.shadow.appendChild(this.canvas);
168
- this.canvas.addEventListener('pointermove', this.handlePointerMove.bind(this));
169
- this.canvas.addEventListener('pointerout', this.handlePointerOut.bind(this));
170
- this.canvas.addEventListener('click', this.handleClick.bind(this));
164
+ this.#canvas = document.createElement('canvas');
165
+ this.#canvas.style.width = '100%';
166
+ this.#canvas.style.height = `${Math.max(LINE_HEIGHT * NUMBER_OF_LANES, 120)}px`;
167
+ this.#shadow.appendChild(this.#canvas);
168
+ this.#canvas.addEventListener('pointermove', this.#handlePointerMove.bind(this));
169
+ this.#canvas.addEventListener('pointerout', this.#handlePointerOut.bind(this));
170
+ this.#canvas.addEventListener('click', this.#handleClick.bind(this));
171
171
 
172
- const context = this.canvas.getContext('2d');
172
+ const context = this.#canvas.getContext('2d');
173
173
 
174
174
  assertInstanceOf(context, CanvasRenderingContext2D);
175
175
 
176
- this.context = context;
176
+ this.#context = context;
177
177
 
178
- this.fcpLane = new WebVitalsEventLane(
179
- this, i18nString(UIStrings.fcp), e => this.getMarkerTypeForFCPEvent(e), this.getFCPMarkerOverlay);
180
- this.lcpLane = new WebVitalsEventLane(
181
- this, i18nString(UIStrings.lcp), e => this.getMarkerTypeForLCPEvent(e), this.getLCPMarkerOverlay);
182
- this.layoutShiftsLane = new WebVitalsEventLane(this, i18nString(UIStrings.ls), _ => MarkerType.Bad);
183
- this.longTasksLane = new WebVitalsTimeboxLane(this, i18nString(UIStrings.longTasks), this.getLongTaskOverlay);
178
+ this.#fcpLane = new WebVitalsEventLane(
179
+ this, i18nString(UIStrings.fcp), e => this.#getMarkerTypeForFCPEvent(e), this.#getFCPMarkerOverlay);
180
+ this.#lcpLane = new WebVitalsEventLane(
181
+ this, i18nString(UIStrings.lcp), e => this.#getMarkerTypeForLCPEvent(e), this.#getLCPMarkerOverlay);
182
+ this.#layoutShiftsLane = new WebVitalsEventLane(this, i18nString(UIStrings.ls), _ => MarkerType.Bad);
183
+ this.#longTasksLane = new WebVitalsTimeboxLane(this, i18nString(UIStrings.longTasks), this.#getLongTaskOverlay);
184
184
 
185
- this.overlay = document.createElement('devtools-timeline-webvitals-tooltip');
186
- this.overlay.style.position = 'absolute';
187
- this.overlay.style.visibility = 'hidden';
185
+ this.#overlay = document.createElement('devtools-timeline-webvitals-tooltip');
186
+ this.#overlay.style.position = 'absolute';
187
+ this.#overlay.style.visibility = 'hidden';
188
188
 
189
- this.ownerDocument.body.appendChild(this.overlay);
189
+ this.ownerDocument.body.appendChild(this.#overlay);
190
190
  }
191
191
 
192
192
  set data(data: WebVitalsTimelineData) {
193
- this.startTime = data.startTime || this.startTime;
194
- this.duration = data.duration || this.duration;
195
- this.maxDuration = data.maxDuration || this.maxDuration;
196
- this.mainFrameNavigations = data.mainFrameNavigations || this.mainFrameNavigations;
193
+ this.#startTime = data.startTime || this.#startTime;
194
+ this.#duration = data.duration || this.#duration;
195
+ this.#maxDuration = data.maxDuration || this.#maxDuration;
196
+ this.#mainFrameNavigations = data.mainFrameNavigations || this.#mainFrameNavigations;
197
197
 
198
198
  if (data.fcps) {
199
- this.fcpLane.setEvents(data.fcps);
199
+ this.#fcpLane.setEvents(data.fcps);
200
200
  }
201
201
 
202
202
  if (data.lcps) {
203
- this.lcpLane.setEvents(data.lcps);
203
+ this.#lcpLane.setEvents(data.lcps);
204
204
  }
205
205
 
206
206
  if (data.layoutShifts) {
207
- this.layoutShiftsLane.setEvents(data.layoutShifts);
207
+ this.#layoutShiftsLane.setEvents(data.layoutShifts);
208
208
  }
209
209
 
210
210
  if (data.longTasks) {
211
- this.longTasksLane.setTimeboxes(data.longTasks);
211
+ this.#longTasksLane.setTimeboxes(data.longTasks);
212
212
  }
213
213
 
214
- this.scheduleRender();
214
+ this.#scheduleRender();
215
215
  }
216
216
 
217
217
  getContext(): CanvasRenderingContext2D {
218
- return this.context;
218
+ return this.#context;
219
219
  }
220
220
 
221
221
  getLineHeight(): number {
@@ -223,62 +223,62 @@ export class WebVitalsTimeline extends HTMLElement {
223
223
  }
224
224
 
225
225
  hideOverlay(): void {
226
- this.overlay.style.visibility = 'hidden';
226
+ this.#overlay.style.visibility = 'hidden';
227
227
  }
228
228
 
229
229
  showOverlay(content: LitHtml.TemplateResult): void {
230
- this.overlay.data = {content};
231
- this.overlay.style.visibility = 'visible';
230
+ this.#overlay.data = {content};
231
+ this.#overlay.style.visibility = 'visible';
232
232
  }
233
233
 
234
- private handlePointerMove(e: MouseEvent): void {
235
- this.updateOverlayPosition(e.clientX, e.clientY);
234
+ #handlePointerMove(e: MouseEvent): void {
235
+ this.#updateOverlayPosition(e.clientX, e.clientY);
236
236
 
237
237
  const x = e.offsetX, y = e.offsetY;
238
238
  const lane = Math.floor(y / LINE_HEIGHT);
239
239
 
240
- this.hoverLane = lane;
241
- this.fcpLane.handlePointerMove(this.hoverLane === 1 ? x : null);
242
- this.lcpLane.handlePointerMove(this.hoverLane === 2 ? x : null);
243
- this.layoutShiftsLane.handlePointerMove(this.hoverLane === 3 ? x : null);
244
- this.longTasksLane.handlePointerMove(this.hoverLane === 4 ? x : null);
240
+ this.#hoverLane = lane;
241
+ this.#fcpLane.handlePointerMove(this.#hoverLane === 1 ? x : null);
242
+ this.#lcpLane.handlePointerMove(this.#hoverLane === 2 ? x : null);
243
+ this.#layoutShiftsLane.handlePointerMove(this.#hoverLane === 3 ? x : null);
244
+ this.#longTasksLane.handlePointerMove(this.#hoverLane === 4 ? x : null);
245
245
 
246
- this.scheduleRender();
246
+ this.#scheduleRender();
247
247
  }
248
248
 
249
- private updateOverlayPosition(clientX: number, clientY: number): void {
249
+ #updateOverlayPosition(clientX: number, clientY: number): void {
250
250
  coordinator.read(() => {
251
251
  const bb1 = this.getBoundingClientRect();
252
- const bb2 = this.overlay.getBoundingClientRect();
252
+ const bb2 = this.#overlay.getBoundingClientRect();
253
253
 
254
254
  const x = clientX + 10 + bb2.width > bb1.x + bb1.width ? clientX - bb2.width - 10 : clientX + 10;
255
255
 
256
256
  coordinator.write(() => {
257
- this.overlay.style.top = `${clientY + 10}px`;
258
- this.overlay.style.left = `${x}px`;
257
+ this.#overlay.style.top = `${clientY + 10}px`;
258
+ this.#overlay.style.left = `${x}px`;
259
259
  });
260
260
  });
261
261
  }
262
262
 
263
- private handlePointerOut(_: MouseEvent): void {
264
- this.fcpLane.handlePointerMove(null);
265
- this.lcpLane.handlePointerMove(null);
266
- this.layoutShiftsLane.handlePointerMove(null);
267
- this.longTasksLane.handlePointerMove(null);
263
+ #handlePointerOut(_: MouseEvent): void {
264
+ this.#fcpLane.handlePointerMove(null);
265
+ this.#lcpLane.handlePointerMove(null);
266
+ this.#layoutShiftsLane.handlePointerMove(null);
267
+ this.#longTasksLane.handlePointerMove(null);
268
268
 
269
- this.scheduleRender();
269
+ this.#scheduleRender();
270
270
  }
271
271
 
272
- private handleClick(e: MouseEvent): void {
272
+ #handleClick(e: MouseEvent): void {
273
273
  const x = e.offsetX;
274
274
 
275
275
  this.focus();
276
- this.fcpLane.handleClick(this.hoverLane === 1 ? x : null);
277
- this.lcpLane.handleClick(this.hoverLane === 2 ? x : null);
278
- this.layoutShiftsLane.handleClick(this.hoverLane === 3 ? x : null);
279
- this.longTasksLane.handleClick(this.hoverLane === 4 ? x : null);
276
+ this.#fcpLane.handleClick(this.#hoverLane === 1 ? x : null);
277
+ this.#lcpLane.handleClick(this.#hoverLane === 2 ? x : null);
278
+ this.#layoutShiftsLane.handleClick(this.#hoverLane === 3 ? x : null);
279
+ this.#longTasksLane.handleClick(this.#hoverLane === 4 ? x : null);
280
280
 
281
- this.scheduleRender();
281
+ this.#scheduleRender();
282
282
  }
283
283
 
284
284
  /**
@@ -286,7 +286,7 @@ export class WebVitalsTimeline extends HTMLElement {
286
286
  * @param x
287
287
  */
288
288
  tX(x: number): number {
289
- return (x - this.startTime) / this.duration * this.width;
289
+ return (x - this.#startTime) / this.#duration * this.#width;
290
290
  }
291
291
 
292
292
  /**
@@ -294,21 +294,21 @@ export class WebVitalsTimeline extends HTMLElement {
294
294
  * @param duration
295
295
  */
296
296
  tD(duration: number): number {
297
- return duration / this.duration * this.width;
297
+ return duration / this.#duration * this.#width;
298
298
  }
299
299
 
300
300
  setSize(width: number, height: number): void {
301
301
  const scale = window.devicePixelRatio;
302
302
 
303
- this.width = width;
304
- this.height = Math.max(height, 120);
303
+ this.#width = width;
304
+ this.#height = Math.max(height, 120);
305
305
 
306
- this.canvas.width = Math.floor(this.width * scale);
307
- this.canvas.height = Math.floor(this.height * scale);
308
- this.context.scale(scale, scale);
306
+ this.#canvas.width = Math.floor(this.#width * scale);
307
+ this.#canvas.height = Math.floor(this.#height * scale);
308
+ this.#context.scale(scale, scale);
309
309
 
310
- this.style.width = this.width + 'px';
311
- this.style.height = this.height + 'px';
310
+ this.style.width = this.#width + 'px';
311
+ this.style.height = this.#height + 'px';
312
312
  this.render();
313
313
  }
314
314
 
@@ -316,7 +316,7 @@ export class WebVitalsTimeline extends HTMLElement {
316
316
  this.style.display = 'block';
317
317
  this.tabIndex = 0;
318
318
 
319
- const boundingClientRect = this.canvas.getBoundingClientRect();
319
+ const boundingClientRect = this.#canvas.getBoundingClientRect();
320
320
  const width = boundingClientRect.width;
321
321
  const height = boundingClientRect.height;
322
322
 
@@ -325,10 +325,10 @@ export class WebVitalsTimeline extends HTMLElement {
325
325
  }
326
326
 
327
327
  disconnectedCallback(): void {
328
- this.overlay.remove();
328
+ this.#overlay.remove();
329
329
  }
330
330
 
331
- private getMarkerTypeForFCPEvent(event: WebVitalsFCPEvent): MarkerType {
331
+ #getMarkerTypeForFCPEvent(event: WebVitalsFCPEvent): MarkerType {
332
332
  const t = this.getTimeSinceLastMainFrameNavigation(event.timestamp);
333
333
  if (t <= FCP_GOOD_TIMING) {
334
334
  return MarkerType.Good;
@@ -339,7 +339,7 @@ export class WebVitalsTimeline extends HTMLElement {
339
339
  return MarkerType.Bad;
340
340
  }
341
341
 
342
- private getMarkerTypeForLCPEvent(event: WebVitalsLCPEvent): MarkerType {
342
+ #getMarkerTypeForLCPEvent(event: WebVitalsLCPEvent): MarkerType {
343
343
  const t = this.getTimeSinceLastMainFrameNavigation(event.timestamp);
344
344
  if (t <= LCP_GOOD_TIMING) {
345
345
  return MarkerType.Good;
@@ -350,7 +350,7 @@ export class WebVitalsTimeline extends HTMLElement {
350
350
  return MarkerType.Bad;
351
351
  }
352
352
 
353
- private getFCPMarkerOverlay(): LitHtml.TemplateResult {
353
+ #getFCPMarkerOverlay(): LitHtml.TemplateResult {
354
354
  return LitHtml.html`
355
355
  <table class="table">
356
356
  <thead>
@@ -378,7 +378,7 @@ export class WebVitalsTimeline extends HTMLElement {
378
378
  `;
379
379
  }
380
380
 
381
- private getLCPMarkerOverlay(): LitHtml.TemplateResult {
381
+ #getLCPMarkerOverlay(): LitHtml.TemplateResult {
382
382
  return LitHtml.html`
383
383
  <table class="table">
384
384
  <thead>
@@ -406,7 +406,7 @@ export class WebVitalsTimeline extends HTMLElement {
406
406
  `;
407
407
  }
408
408
 
409
- private getLongTaskOverlay(timebox: Timebox): LitHtml.TemplateResult {
409
+ #getLongTaskOverlay(timebox: Timebox): LitHtml.TemplateResult {
410
410
  return LitHtml.html`
411
411
  <table class="table">
412
412
  <thead>
@@ -433,75 +433,75 @@ export class WebVitalsTimeline extends HTMLElement {
433
433
  `;
434
434
  }
435
435
 
436
- private renderMainFrameNavigations(markers: readonly number[]): void {
437
- this.context.save();
438
- this.context.strokeStyle = 'blue';
439
- this.context.beginPath();
436
+ #renderMainFrameNavigations(markers: readonly number[]): void {
437
+ this.#context.save();
438
+ this.#context.strokeStyle = 'blue';
439
+ this.#context.beginPath();
440
440
  for (const marker of markers) {
441
- this.context.moveTo(this.tX(marker), 0);
442
- this.context.lineTo(this.tX(marker), this.height);
441
+ this.#context.moveTo(this.tX(marker), 0);
442
+ this.#context.lineTo(this.tX(marker), this.#height);
443
443
  }
444
- this.context.stroke();
445
- this.context.restore();
444
+ this.#context.stroke();
445
+ this.#context.restore();
446
446
  }
447
447
 
448
448
  getTimeSinceLastMainFrameNavigation(time: number): number {
449
449
  let i = 0, prev = 0;
450
- while (i < this.mainFrameNavigations.length && this.mainFrameNavigations[i] <= time) {
451
- prev = this.mainFrameNavigations[i];
450
+ while (i < this.#mainFrameNavigations.length && this.#mainFrameNavigations[i] <= time) {
451
+ prev = this.#mainFrameNavigations[i];
452
452
  i++;
453
453
  }
454
454
  return time - prev;
455
455
  }
456
456
 
457
457
  render(): void {
458
- this.context.save();
459
- this.context.clearRect(0, 0, this.width, this.height);
458
+ this.#context.save();
459
+ this.#context.clearRect(0, 0, this.#width, this.#height);
460
460
 
461
- this.context.strokeStyle = '#dadce0';
461
+ this.#context.strokeStyle = '#dadce0';
462
462
 
463
463
  // Render the grid in the background.
464
- this.context.beginPath();
464
+ this.#context.beginPath();
465
465
  for (let i = 0; i < NUMBER_OF_LANES; i++) {
466
- this.context.moveTo(0, (i * LINE_HEIGHT) + 0.5);
467
- this.context.lineTo(this.width, (i * LINE_HEIGHT) + 0.5);
466
+ this.#context.moveTo(0, (i * LINE_HEIGHT) + 0.5);
467
+ this.#context.lineTo(this.#width, (i * LINE_HEIGHT) + 0.5);
468
468
  }
469
- this.context.moveTo(0, NUMBER_OF_LANES * LINE_HEIGHT - 0.5);
470
- this.context.lineTo(this.width, NUMBER_OF_LANES * LINE_HEIGHT - 0.5);
471
- this.context.stroke();
472
- this.context.restore();
469
+ this.#context.moveTo(0, NUMBER_OF_LANES * LINE_HEIGHT - 0.5);
470
+ this.#context.lineTo(this.#width, NUMBER_OF_LANES * LINE_HEIGHT - 0.5);
471
+ this.#context.stroke();
472
+ this.#context.restore();
473
473
 
474
474
  // Render the WebVitals label.
475
- this.context.save();
476
- this.context.font = '11px ' + Host.Platform.fontFamily();
477
- const text = this.context.measureText('Web Vitals');
475
+ this.#context.save();
476
+ this.#context.font = '11px ' + Host.Platform.fontFamily();
477
+ const text = this.#context.measureText('Web Vitals');
478
478
  const height = text.actualBoundingBoxAscent - text.actualBoundingBoxDescent;
479
- this.context.fillStyle = '#202124';
480
- this.context.fillText('Web Vitals', 6, 4 + height);
481
- this.context.restore();
479
+ this.#context.fillStyle = '#202124';
480
+ this.#context.fillText('Web Vitals', 6, 4 + height);
481
+ this.#context.restore();
482
482
 
483
483
  // Render all the lanes.
484
- this.context.save();
485
- this.context.translate(0, Number(LINE_HEIGHT));
486
- this.fcpLane.render();
487
- this.context.translate(0, Number(LINE_HEIGHT));
488
- this.lcpLane.render();
489
- this.context.translate(0, Number(LINE_HEIGHT));
490
- this.layoutShiftsLane.render();
491
- this.context.translate(0, Number(LINE_HEIGHT));
492
- this.longTasksLane.render();
493
- this.context.restore();
494
-
495
- this.renderMainFrameNavigations(this.mainFrameNavigations);
484
+ this.#context.save();
485
+ this.#context.translate(0, Number(LINE_HEIGHT));
486
+ this.#fcpLane.render();
487
+ this.#context.translate(0, Number(LINE_HEIGHT));
488
+ this.#lcpLane.render();
489
+ this.#context.translate(0, Number(LINE_HEIGHT));
490
+ this.#layoutShiftsLane.render();
491
+ this.#context.translate(0, Number(LINE_HEIGHT));
492
+ this.#longTasksLane.render();
493
+ this.#context.restore();
494
+
495
+ this.#renderMainFrameNavigations(this.#mainFrameNavigations);
496
496
  }
497
497
 
498
- private scheduleRender(): void {
499
- if (this.animationFrame) {
498
+ #scheduleRender(): void {
499
+ if (this.#animationFrame) {
500
500
  return;
501
501
  }
502
502
 
503
- this.animationFrame = window.requestAnimationFrame(() => {
504
- this.animationFrame = null;
503
+ this.#animationFrame = window.requestAnimationFrame(() => {
504
+ this.#animationFrame = null;
505
505
  this.render();
506
506
  });
507
507
  }
@@ -18,25 +18,25 @@ export interface WebVitalsTooltipData {
18
18
 
19
19
  export class WebVitalsTooltip extends HTMLElement {
20
20
  static readonly litTagName = LitHtml.literal`devtools-timeline-webvitals-tooltip`;
21
- private readonly shadow = this.attachShadow({mode: 'open'});
22
- private content: LitHtml.TemplateResult|null = null;
21
+ readonly #shadow = this.attachShadow({mode: 'open'});
22
+ #content: LitHtml.TemplateResult|null = null;
23
23
 
24
24
  set data(data: WebVitalsTooltipData) {
25
- this.content = data.content;
26
- this.render();
25
+ this.#content = data.content;
26
+ this.#render();
27
27
  }
28
28
 
29
29
  connectedCallback(): void {
30
- this.shadow.adoptedStyleSheets = [webVitalsTooltipStyles];
31
- this.render();
30
+ this.#shadow.adoptedStyleSheets = [webVitalsTooltipStyles];
31
+ this.#render();
32
32
  }
33
33
 
34
- private render(): void {
34
+ #render(): void {
35
35
  // clang-format off
36
36
  LitHtml.render(LitHtml.html`<div class="tooltip">
37
- ${this.content}
37
+ ${this.#content}
38
38
  </div>
39
- `, this.shadow, {host: this});
39
+ `, this.#shadow, {host: this});
40
40
  // clang-format off
41
41
  }
42
42
  }