chrome-devtools-frontend 1.0.1739869 → 1.0.1742811

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 (272) hide show
  1. package/.agents/rules/ui-and-widgets/ui-accessibility-and-semantic-html.md +1 -1
  2. package/.agents/rules/ui-and-widgets/ui-css-scoping-and-flex-layout.md +44 -7
  3. package/.agents/rules/ui-and-widgets/ui-lit-declarative-templates-and-directives.md +1 -1
  4. package/.agents/rules/ui-and-widgets/ui-view-output-and-callback-contracts.md +2 -2
  5. package/.agents/rules/ui-and-widgets/ui-widget-dom-and-listener-lifecycle.md +1 -1
  6. package/.agents/skills/code-review/SKILL.md +23 -6
  7. package/.agents/skills/devtools-verification/SKILL.md +2 -1
  8. package/.agents/skills/migrate-chromium-test/SKILL.md +1 -0
  9. package/.agents/skills/ui-eng-vision-local-lit-renderer/SKILL.md +27 -11
  10. package/.agents/skills/ui-eng-vision-orchestrator/SKILL.md +41 -23
  11. package/.agents/skills/ui-eng-vision-test-scaffolder/SKILL.md +12 -7
  12. package/.agents/skills/ui-eng-vision-widget-promoter/SKILL.md +3 -0
  13. package/.agents/skills/ui-widgets/SKILL.md +22 -7
  14. package/.agents/skills/version-control/SKILL.md +10 -1
  15. package/.agents/skills/visual-regression-audit/SKILL.md +88 -0
  16. package/.gitallowed +2 -1
  17. package/.stylelintignore +1 -0
  18. package/.stylelintrc.json +2 -0
  19. package/AUTHORS +1 -0
  20. package/DIR_METADATA +2 -1
  21. package/PRESUBMIT_test.py +143 -0
  22. package/config/owner/INFRA_OWNERS +0 -1
  23. package/docs/contributing/infrastructure.md +2 -2
  24. package/docs/ui_engineering.md +14 -4
  25. package/eslint.config.mjs +1 -18
  26. package/front_end/application_tokens.css +0 -35
  27. package/front_end/core/host/AidaClient.ts +1 -1
  28. package/front_end/core/host/AidaClientTypes.ts +2 -0
  29. package/front_end/core/host/AidaErrors.ts +3 -3
  30. package/front_end/core/host/AidaGcaTranslation.ts +39 -0
  31. package/front_end/core/host/GcaClient.ts +32 -20
  32. package/front_end/core/host/GcaTypes.ts +4 -2
  33. package/front_end/core/host/InspectorFrontendHostAPI.ts +2 -0
  34. package/front_end/core/i18n/DevToolsLocale.ts +0 -1
  35. package/front_end/core/sdk/DebuggerModel.ts +25 -13
  36. package/front_end/core/sdk/PreloadingModel.ts +2 -2
  37. package/front_end/core/sdk/RehydratingConnection.ts +59 -30
  38. package/front_end/core/sdk/StorageKeyManager.ts +0 -1
  39. package/front_end/core/sdk/Target.ts +6 -0
  40. package/front_end/core/sdk/TargetManager.ts +10 -4
  41. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +12 -2
  42. package/front_end/entrypoints/inspector_main/OutermostTargetSelector.ts +159 -52
  43. package/front_end/entrypoints/inspector_main/outermostTargetSelector.css +77 -25
  44. package/front_end/entrypoints/main/MainImpl.ts +32 -15
  45. package/front_end/models/ai_assistance/AiAgent2.ts +95 -46
  46. package/front_end/models/ai_assistance/AiConversation.ts +1 -1
  47. package/front_end/models/ai_assistance/agents/AiAgent.ts +9 -2
  48. package/front_end/models/ai_assistance/agents/ExecuteJavascript.ts +3 -2
  49. package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +1 -1
  50. package/front_end/models/ai_assistance/data_formatters/FileFormatter.ts +1 -1
  51. package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +5 -4
  52. package/front_end/models/ai_assistance/performance/AICallTree.ts +7 -9
  53. package/front_end/models/ai_assistance/performance/AIQueries.ts +4 -8
  54. package/front_end/models/ai_assistance/skills/SkillRegistry.ts +11 -1
  55. package/front_end/models/ai_assistance/skills/lighthouse.md +1 -0
  56. package/front_end/models/ai_assistance/skills/network.md +3 -4
  57. package/front_end/models/ai_assistance/skills/sources.md +1 -2
  58. package/front_end/models/ai_assistance/skills/styling.md +3 -4
  59. package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +11 -3
  60. package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +84 -23
  61. package/front_end/models/ai_assistance/tools/ListSources.ts +41 -13
  62. package/front_end/models/badges/Badge.ts +0 -1
  63. package/front_end/models/bindings/ResourceMapping.ts +1 -1
  64. package/front_end/models/bindings/ResourceScriptMapping.ts +1 -1
  65. package/front_end/models/breakpoints/BreakpointManager.ts +2 -4
  66. package/front_end/models/breakpoints/RecurringPauseDetector.ts +140 -0
  67. package/front_end/models/breakpoints/breakpoints.ts +2 -1
  68. package/front_end/models/heap_snapshot/HeapSnapshotModel.ts +2 -2
  69. package/front_end/models/persistence/Automapping.ts +0 -1
  70. package/front_end/models/trace/Processor.ts +16 -7
  71. package/front_end/models/trace/README.md +17 -1
  72. package/front_end/models/trace/extras/ThirdParties.ts +4 -6
  73. package/front_end/models/trace/extras/TraceTree.ts +69 -72
  74. package/front_end/models/trace/handlers/MetaHandler.ts +3 -0
  75. package/front_end/models/trace/handlers/types.ts +15 -0
  76. package/front_end/models/trace/helpers/Trace.ts +5 -3
  77. package/front_end/models/trace/lantern/simulation/Simulator.ts +4 -1
  78. package/front_end/models/web_mcp/WebMCPModel.ts +19 -9
  79. package/front_end/panels/ai_assistance/AiAssistancePanel.ts +30 -3
  80. package/front_end/panels/ai_assistance/components/ChatMessage.ts +2 -4
  81. package/front_end/panels/ai_assistance/components/chatMessage.css +1 -22
  82. package/front_end/panels/ai_assistance/components/exploreWidget.css +1 -19
  83. package/front_end/panels/ai_assistance/components/optInChangeDialog.css +1 -1
  84. package/front_end/panels/ai_assistance/components/walkthroughView.css +0 -13
  85. package/front_end/panels/animation/AnimationGroupPreviewUI.ts +3 -2
  86. package/front_end/panels/animation/AnimationTimeline.ts +5 -3
  87. package/front_end/panels/animation/animationTimeline.css +10 -8
  88. package/front_end/panels/application/ApplicationPanelSidebar.ts +14 -11
  89. package/front_end/panels/application/ReportingApiView.ts +0 -1
  90. package/front_end/panels/application/SubAppsView.ts +0 -1
  91. package/front_end/panels/application/WebMCPTreeElement.ts +3 -6
  92. package/front_end/panels/application/WebMCPView.ts +30 -0
  93. package/front_end/panels/application/components/ReportsGrid.ts +0 -1
  94. package/front_end/panels/application/components/backForwardCacheView.css +0 -7
  95. package/front_end/panels/application/components/permissionsPolicySection.css +2 -2
  96. package/front_end/panels/application/components/protocolHandlersView.css +46 -39
  97. package/front_end/panels/application/components/trustTokensView.css +0 -4
  98. package/front_end/panels/application/cookieItemsView.css +0 -7
  99. package/front_end/panels/application/indexedDBViews.css +0 -6
  100. package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +0 -2
  101. package/front_end/panels/application/preloading/components/PreloadingString.ts +0 -1
  102. package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +4 -5
  103. package/front_end/panels/application/preloading/components/preloadingGrid.css +0 -9
  104. package/front_end/panels/application/serviceWorkerUpdateCycleView.css +2 -9
  105. package/front_end/panels/application/serviceWorkersView.css +5 -4
  106. package/front_end/panels/application/storageView.css +0 -5
  107. package/front_end/panels/application/webMCPView.css +17 -0
  108. package/front_end/panels/browser_debugger/ObjectEventListenersSidebarPane.ts +15 -20
  109. package/front_end/panels/changes/changesView.css +0 -5
  110. package/front_end/panels/common/ExtensionServer.ts +80 -10
  111. package/front_end/panels/console/ConsolePanel.ts +92 -18
  112. package/front_end/panels/console/consoleContextSelector.css +1 -8
  113. package/front_end/panels/console/consoleInsightTeaser.css +10 -17
  114. package/front_end/panels/console/consolePinPane.css +3 -1
  115. package/front_end/panels/console/consoleView.css +13 -17
  116. package/front_end/panels/coverage/coverageListView.css +0 -4
  117. package/front_end/panels/css_overview/cssOverviewCompletedView.css +0 -22
  118. package/front_end/panels/css_overview/cssOverviewStartView.css +0 -43
  119. package/front_end/panels/developer_resources/developerResourcesListView.css +0 -4
  120. package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +52 -45
  121. package/front_end/panels/elements/LayoutPane.ts +1 -3
  122. package/front_end/panels/elements/PropertiesWidget.ts +26 -8
  123. package/front_end/panels/elements/PropertyRenderer.ts +45 -21
  124. package/front_end/panels/elements/StandaloneStylesContainer.ts +6 -7
  125. package/front_end/panels/elements/StyleEditorWidget.ts +110 -63
  126. package/front_end/panels/elements/StylePropertiesSection.ts +14 -5
  127. package/front_end/panels/elements/StylePropertyTreeElement.ts +529 -518
  128. package/front_end/panels/elements/StylesContainer.ts +5 -6
  129. package/front_end/panels/elements/StylesSidebarPane.ts +12 -15
  130. package/front_end/panels/elements/components/CSSVariableValueView.ts +17 -4
  131. package/front_end/panels/elements/components/StylePropertyEditor.ts +178 -140
  132. package/front_end/panels/elements/components/cssQuery.css +1 -1
  133. package/front_end/panels/elements/components/stylePropertyEditor.css +60 -56
  134. package/front_end/panels/elements/layoutPane.css +2 -2
  135. package/front_end/panels/elements/metricsSidebarPane.css +6 -7
  136. package/front_end/panels/elements/platformFontsWidget.css +1 -1
  137. package/front_end/panels/elements/stylePropertiesTreeOutline.css +1 -6
  138. package/front_end/panels/elements/stylesSidebarPane.css +3 -4
  139. package/front_end/panels/emulation/deviceModeView.css +1 -1
  140. package/front_end/panels/event_listeners/EventListenersView.ts +9 -2
  141. package/front_end/panels/event_listeners/eventListenersView.css +1 -1
  142. package/front_end/panels/explain/components/consoleInsight.css +1 -2
  143. package/front_end/panels/issues/issuesTree.css +6 -43
  144. package/front_end/panels/layer_viewer/PaintProfilerView.ts +1 -1
  145. package/front_end/panels/layer_viewer/paintProfiler.css +4 -3
  146. package/front_end/panels/lighthouse/LighthouseReportSelector.ts +1 -6
  147. package/front_end/panels/lighthouse/lighthouseStartView.css +5 -16
  148. package/front_end/panels/linear_memory_inspector/components/LinearMemoryValueInterpreter.ts +0 -1
  149. package/front_end/panels/linear_memory_inspector/components/linearMemoryHighlightChipList.css +2 -2
  150. package/front_end/panels/linear_memory_inspector/components/linearMemoryViewer.css +2 -2
  151. package/front_end/panels/linear_memory_inspector/components/valueInterpreterSettings.css +1 -1
  152. package/front_end/panels/media/playerListView.css +1 -2
  153. package/front_end/panels/media/playerPropertiesView.css +1 -1
  154. package/front_end/panels/mobile_throttling/throttlingSettingsTab.css +2 -2
  155. package/front_end/panels/network/NetworkLogView.ts +594 -580
  156. package/front_end/panels/network/RequestCookiesView.ts +0 -1
  157. package/front_end/panels/network/networkConfigView.css +1 -2
  158. package/front_end/panels/network/networkLogView.css +363 -364
  159. package/front_end/panels/network/networkPanel.css +1 -5
  160. package/front_end/panels/network/networkTimingTable.css +1 -1
  161. package/front_end/panels/network/networkWaterfallColumn.css +1 -1
  162. package/front_end/panels/network/requestConditionsDrawer.css +0 -4
  163. package/front_end/panels/network/requestCookiesView.css +7 -1
  164. package/front_end/panels/network/requestPayloadTree.css +0 -4
  165. package/front_end/panels/profiler/HeapProfileView.ts +1 -3
  166. package/front_end/panels/profiler/HeapSnapshotView.ts +0 -7
  167. package/front_end/panels/recorder/RecorderPanel.ts +1 -1
  168. package/front_end/panels/recorder/RecordingView.ts +10 -10
  169. package/front_end/panels/recorder/StepView.ts +5 -4
  170. package/front_end/panels/recorder/createRecordingView.css +1 -1
  171. package/front_end/panels/recorder/recorderPanel.css +0 -8
  172. package/front_end/panels/recorder/recordingListView.css +4 -4
  173. package/front_end/panels/recorder/recordingView.css +12 -20
  174. package/front_end/panels/recorder/stepEditor.css +4 -4
  175. package/front_end/panels/recorder/stepView.css +31 -9
  176. package/front_end/panels/recorder/timelineSection.css +4 -0
  177. package/front_end/panels/screencast/ScreencastApp.ts +0 -1
  178. package/front_end/panels/security/mainView.css +1 -1
  179. package/front_end/panels/security/originView.css +2 -2
  180. package/front_end/panels/sensors/SensorsView.ts +273 -346
  181. package/front_end/panels/settings/BackendLinkingSettingsTab.ts +0 -1
  182. package/front_end/panels/settings/backendLinkingSettingsTab.css +7 -7
  183. package/front_end/panels/settings/components/syncSection.css +0 -1
  184. package/front_end/panels/settings/workspaceSettingsTab.css +0 -5
  185. package/front_end/panels/sources/CSSPlugin.ts +177 -98
  186. package/front_end/panels/sources/DebuggerPausedMessage.ts +100 -27
  187. package/front_end/panels/sources/NavigatorView.ts +926 -946
  188. package/front_end/panels/sources/SourcesPanel.ts +9 -2
  189. package/front_end/panels/sources/breakpointsView.css +6 -29
  190. package/front_end/panels/sources/components/HeadersView.css +2 -2
  191. package/front_end/panels/sources/debuggerPausedMessage.css +7 -0
  192. package/front_end/panels/sources/navigatorTree.css +7 -2
  193. package/front_end/panels/sources/sourcesNavigator.css +0 -9
  194. package/front_end/panels/sources/watchExpressionsSidebarPane.css +0 -10
  195. package/front_end/panels/timeline/CompatibilityTracksAppender.ts +3 -0
  196. package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +0 -10
  197. package/front_end/panels/timeline/ModificationsManager.ts +0 -1
  198. package/front_end/panels/timeline/ThreadAppender.ts +2 -6
  199. package/front_end/panels/timeline/TimelinePanel.ts +2 -2
  200. package/front_end/panels/timeline/TimelineTreeView.ts +38 -41
  201. package/front_end/panels/timeline/TimelineUIUtils.ts +8 -10
  202. package/front_end/panels/timeline/components/LayoutShiftDetails.ts +0 -2
  203. package/front_end/panels/timeline/components/fieldSettingsDialog.css +1 -6
  204. package/front_end/panels/timeline/components/insights/baseInsightComponent.css +0 -12
  205. package/front_end/panels/timeline/components/interactionBreakdown.css +1 -2
  206. package/front_end/panels/timeline/components/layoutShiftDetails.css +2 -9
  207. package/front_end/panels/timeline/components/liveMetricsView.css +0 -16
  208. package/front_end/panels/timeline/components/metricCard.css +1 -5
  209. package/front_end/panels/timeline/components/networkRequestDetails.css +3 -4
  210. package/front_end/panels/timeline/components/networkRequestTooltip.css +6 -4
  211. package/front_end/panels/timeline/components/sidebarAnnotationsTab.css +1 -1
  212. package/front_end/panels/timeline/components/sidebarInsightsTab.css +1 -2
  213. package/front_end/panels/timeline/timelineDetailsView.css +1 -12
  214. package/front_end/panels/timeline/timelineFlamechartPopover.css +0 -4
  215. package/front_end/panels/timeline/timelineMiniMap.css +1 -4
  216. package/front_end/panels/timeline/timelinePanel.css +0 -4
  217. package/front_end/panels/timeline/timelineStatusDialog.css +1 -1
  218. package/front_end/panels/timeline/timelineTreeView.css +0 -12
  219. package/front_end/panels/timeline/utils/EntryNodes.ts +1 -1
  220. package/front_end/panels/webauthn/webauthnPane.css +1 -7
  221. package/front_end/panels/whats_new/ReleaseNoteText.ts +1 -1
  222. package/front_end/third_party/chromium/README.chromium +1 -1
  223. package/front_end/ui/components/adorners/adorner.css +1 -1
  224. package/front_end/ui/components/buttons/button.css +0 -28
  225. package/front_end/ui/components/buttons/textButton.css +1 -45
  226. package/front_end/ui/components/input/checkbox.css +3 -3
  227. package/front_end/ui/components/issue_counter/issueLinkIcon.css +2 -2
  228. package/front_end/ui/components/menus/Menu.ts +14 -0
  229. package/front_end/ui/components/menus/menu.css +2 -14
  230. package/front_end/ui/components/menus/menuItem.css +0 -4
  231. package/front_end/ui/components/request_link_icon/requestLinkIcon.css +2 -2
  232. package/front_end/ui/components/survey_link/SurveyLink.ts +1 -1
  233. package/front_end/ui/components/survey_link/surveyLink.css +3 -3
  234. package/front_end/ui/components/switch/switch.css +3 -2
  235. package/front_end/ui/components/text_editor/theme.ts +1 -1
  236. package/front_end/ui/components/tooltips/Tooltip.ts +3 -3
  237. package/front_end/ui/components/tree_outline/treeOutline.css +0 -23
  238. package/front_end/ui/legacy/ContextMenu.ts +5 -5
  239. package/front_end/ui/legacy/SoftContextMenu.ts +24 -8
  240. package/front_end/ui/legacy/Toolbar.ts +1 -1
  241. package/front_end/ui/legacy/Treeoutline.ts +31 -78
  242. package/front_end/ui/legacy/UIUtils.ts +9 -17
  243. package/front_end/ui/legacy/checkboxTextLabel.css +2 -44
  244. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +39 -27
  245. package/front_end/ui/legacy/components/color_picker/spectrum.css +2 -10
  246. package/front_end/ui/legacy/components/data_grid/dataGrid.css +2 -6
  247. package/front_end/ui/legacy/components/inline_editor/BezierEditor.ts +34 -26
  248. package/front_end/ui/legacy/components/inline_editor/SwatchPopoverHelper.ts +1 -0
  249. package/front_end/ui/legacy/components/inline_editor/cssShadowEditor.css +1 -1
  250. package/front_end/ui/legacy/components/inline_editor/swatchPopover.css +1 -1
  251. package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +49 -1
  252. package/front_end/ui/legacy/components/object_ui/objectPopover.css +0 -4
  253. package/front_end/ui/legacy/components/perf_ui/chartViewport.css +1 -9
  254. package/front_end/ui/legacy/components/perf_ui/filmStripView.css +1 -1
  255. package/front_end/ui/legacy/components/perf_ui/overviewGrid.css +2 -1
  256. package/front_end/ui/legacy/components/quick_open/filteredListWidget.css +0 -5
  257. package/front_end/ui/legacy/components/settings_ui/SettingsUI.ts +6 -3
  258. package/front_end/ui/legacy/components/source_frame/JSONView.ts +95 -1
  259. package/front_end/ui/legacy/filter.css +1 -1
  260. package/front_end/ui/legacy/inspectorCommon.css +6 -28
  261. package/front_end/ui/legacy/inspectorDrawerTabbedPane.css +1 -1
  262. package/front_end/ui/legacy/listWidget.css +1 -1
  263. package/front_end/ui/legacy/progressIndicator.css +1 -1
  264. package/front_end/ui/legacy/tabbedPane.css +6 -2
  265. package/front_end/ui/visual_logging/KnownContextValues.ts +1 -0
  266. package/front_end/ui/visual_logging/LoggingDriver.ts +4 -0
  267. package/front_end/ui/visual_logging/visual_logging.ts +1 -1
  268. package/inspector_overlay/common.ts +0 -3
  269. package/inspector_overlay/main.ts +1 -3
  270. package/inspector_overlay/tool_source_order.css +0 -4
  271. package/package.json +1 -1
  272. package/front_end/generated/SupportedCSSProperties.ts +0 -9705
@@ -111,7 +111,7 @@
111
111
  }
112
112
 
113
113
  .network .network-overview {
114
- flex: 0 0 60px;
114
+ flex: 0 0 var(--sys-size-18);
115
115
  }
116
116
 
117
117
  .network-overview .resources-dividers-label-bar .resources-divider {
@@ -166,7 +166,3 @@
166
166
  background-color: canvas;
167
167
  }
168
168
  }
169
-
170
- devtools-request-headers {
171
- min-width: 360px;
172
- }
@@ -47,7 +47,7 @@ table.network-timing-table > tr:not(.network-timing-table-header, .network-timin
47
47
  }
48
48
 
49
49
  .network-timing-table col.labels {
50
- width: 156px;
50
+ width: var(--sys-size-23);
51
51
  }
52
52
 
53
53
  .network-timing-table col.duration {
@@ -26,7 +26,7 @@
26
26
  }
27
27
 
28
28
  .network-waterfall-v-scroll.small {
29
- margin-top: 27px;
29
+ margin-top: var(--sys-size-11);
30
30
  }
31
31
 
32
32
  .network-waterfall-v-scroll-content {
@@ -23,10 +23,6 @@
23
23
  overflow: hidden auto;
24
24
  }
25
25
 
26
- .no-blocked-urls > span {
27
- white-space: pre;
28
- }
29
-
30
26
  .blocked-url {
31
27
  display: flex;
32
28
  flex-direction: row;
@@ -15,8 +15,14 @@
15
15
  .request-cookies-view .request-cookies-title {
16
16
  font-size: var(--sys-typescale-body4-size);
17
17
  font-weight: bold;
18
- margin-right: 30px;
18
+ margin-right: var(--sys-size-12);
19
19
  color: var(--sys-color-on-surface);
20
+ vertical-align: middle;
21
+ }
22
+
23
+ .request-cookies-view devtools-checkbox {
24
+ font-size: var(--sys-typescale-body4-size);
25
+ vertical-align: middle;
20
26
  }
21
27
 
22
28
  .request-cookies-view .cookie-line {
@@ -91,10 +91,6 @@
91
91
  color: var(--sys-color-state-disabled);
92
92
  }
93
93
 
94
- .request-payload-show-more-button {
95
- margin: 0 var(--sys-size-3);
96
- }
97
-
98
94
  @media (forced-colors: active) {
99
95
  :host-context(.request-payload-tree) ol.tree-outline:not(.hide-selection-when-blurred) li.selected:focus {
100
96
  background: Highlight;
@@ -1079,9 +1079,7 @@ export class SamplingHeapProfileType extends SamplingHeapProfileTypeBase {
1079
1079
  }
1080
1080
 
1081
1081
  override get description(): string {
1082
- // TODO(l10n): Do not concatenate localized strings.
1083
- const formattedDescription = [i18nString(UIStrings.recordMemoryAllocations)];
1084
- return formattedDescription.join('\n');
1082
+ return i18nString(UIStrings.recordMemoryAllocations);
1085
1083
  }
1086
1084
 
1087
1085
  override hasTemporaryView(): boolean {
@@ -1742,13 +1742,6 @@ export class TrackingHeapSnapshotProfileType extends TrackingHeapSnapshotProfile
1742
1742
 
1743
1743
  // eslint-disable-next-line @typescript-eslint/naming-convention
1744
1744
  static override readonly TypeId = 'HEAP-RECORD';
1745
- // TODO(crbug.com/1228674): Remove event strings once they are no longer used in web tests.
1746
- // eslint-disable-next-line @typescript-eslint/naming-convention
1747
- static readonly HeapStatsUpdate = 'HeapStatsUpdate';
1748
- // eslint-disable-next-line @typescript-eslint/naming-convention
1749
- static readonly TrackingStarted = 'TrackingStarted';
1750
- // eslint-disable-next-line @typescript-eslint/naming-convention
1751
- static readonly TrackingStopped = 'TrackingStopped';
1752
1745
  }
1753
1746
 
1754
1747
  export const enum TrackingHeapSnapshotProfileTypeEvents {
@@ -1518,7 +1518,7 @@ export class RecorderPanel extends UI.Widget.VBox<DocumentFragment> {
1518
1518
  data,
1519
1519
  this.currentRecording.storageName,
1520
1520
  ));
1521
- this.#recordingView?.scrollToBottom();
1521
+ void this.#recordingView?.scrollToBottom();
1522
1522
 
1523
1523
  await takeScreenshot(this.currentRecording);
1524
1524
  });
@@ -212,7 +212,6 @@ function renderSettings({
212
212
  : i18nString(UIStrings.desktop)
213
213
  }</div>`,
214
214
  );
215
- environmentFragments.push(html`<div class="separator"></div>`);
216
215
  environmentFragments.push(
217
216
  html`<div>${settings.viewportSettings.width}×${
218
217
  settings.viewportSettings.height
@@ -262,7 +261,6 @@ function renderSettings({
262
261
  // clang-format on
263
262
  }
264
263
  // clang-format off
265
- replaySettingsFragments.push(html`<div class="separator"></div>`);
266
264
  replaySettingsFragments.push(
267
265
  html`<div>${i18nString(UIStrings.timeout, {
268
266
  value: settings.timeout || Models.RecordingPlayer.defaultTimeout,
@@ -397,7 +395,7 @@ function renderTimelineArea(input: ViewInput, output: ViewOutput): Lit.LitTempla
397
395
  sidebar-initial-size="300"
398
396
  show=${input.showCodeView ? 'both' : 'main'}
399
397
  >
400
- <div slot="main" role="region" aria-labelledby="recording-steps-heading">
398
+ <div slot="main" class="steps-pane" role="region" aria-labelledby="recording-steps-heading">
401
399
  ${renderSections(input)}
402
400
  </div>
403
401
  <div id="recording-code-pane" slot="sidebar" role="region" aria-labelledby="recording-code-heading"
@@ -584,8 +582,7 @@ function renderSections(input: ViewInput): Lit.LitTemplate {
584
582
  i === input.sections.length - 1 &&
585
583
  section.steps.length === 0,
586
584
  isAfterError: getPreviousState(i, -1) === State.ERROR,
587
- isSelected:
588
- input.selectedStep === (section.causingStep || null),
585
+ isSelected: section.causingStep !== undefined && input.selectedStep === section.causingStep,
589
586
  sectionIndex: i,
590
587
  isRecording: input.isRecording,
591
588
  isPlaying: input.replayState.isPlaying,
@@ -736,7 +733,6 @@ function renderHeader(input: ViewInput): Lit.LitTemplate {
736
733
  >
737
734
  ${i18nString(UIStrings.performancePanel)}
738
735
  </devtools-button>
739
- <div class="separator"></div>
740
736
  ${renderReplayOrAbortButton(input)}
741
737
  </div>`
742
738
  : Lit.nothing
@@ -1025,12 +1021,16 @@ export class RecordingView extends UI.Widget.Widget {
1025
1021
  document.removeEventListener('copy', this.#onCopyBound);
1026
1022
  }
1027
1023
 
1028
- scrollToBottom(): void {
1029
- const wrapper = this.contentElement?.querySelector('.sections');
1030
- if (!wrapper) {
1024
+ /**
1025
+ * Scrolls to the last step once all pending updates are rendered.
1026
+ */
1027
+ async scrollToBottom(): Promise<void> {
1028
+ await UI.Widget.Widget.allUpdatesComplete;
1029
+ const stepsPane = this.contentElement.querySelector('.steps-pane');
1030
+ if (!stepsPane) {
1031
1031
  return;
1032
1032
  }
1033
- wrapper.scrollTop = wrapper.scrollHeight;
1033
+ stepsPane.scrollTop = stepsPane.scrollHeight;
1034
1034
  }
1035
1035
 
1036
1036
  #getStepState(step: Models.Schema.Step): State {
@@ -18,7 +18,7 @@ import stepViewStyles from './stepView.css.js';
18
18
  import {TimelineSection} from './TimelineSection.js';
19
19
 
20
20
  const {html} = Lit;
21
- const {ifDefined} = Lit.Directives;
21
+ const {classMap, ifDefined} = Lit.Directives;
22
22
  const {widget} = UI.Widget;
23
23
 
24
24
  const UIStrings = {
@@ -370,7 +370,7 @@ export const DEFAULT_VIEW = (input: ViewInput, _output: ViewOutput, target: HTML
370
370
  input.onStepHover(stepOrSection);
371
371
  }
372
372
  }}
373
- class=${Lit.Directives.classMap(stepClasses)}>
373
+ class=${classMap(stepClasses)}>
374
374
  <svg slot="icon" width="24" height="24" class="icon"
375
375
  role=${input.step ? 'button' : 'presentation'}
376
376
  aria-label=${ifDefined(input.step ? breakpointTitle : undefined)}
@@ -428,7 +428,7 @@ export const DEFAULT_VIEW = (input: ViewInput, _output: ViewOutput, target: HTML
428
428
  onStepEdited: input.stepEdited,
429
429
  onAttributeRequested: input.onAttributeRequested,
430
430
  })}
431
- class=${input.isSelected ? 'is-selected' : ''}></devtools-widget>`
431
+ class=${classMap({'step-editor': true, 'is-selected': input.isSelected})}></devtools-widget>`
432
432
  }
433
433
  ${
434
434
  input.section?.causingStep &&
@@ -438,7 +438,8 @@ export const DEFAULT_VIEW = (input: ViewInput, _output: ViewOutput, target: HTML
438
438
  disabled: input.isPlaying,
439
439
  onStepEdited: input.stepEdited,
440
440
  onAttributeRequested: input.onAttributeRequested,
441
- })}></devtools-widget>`
441
+ })}
442
+ class="step-editor"></devtools-widget>`
442
443
  }
443
444
  </div>
444
445
  ${
@@ -82,7 +82,7 @@ h1 {
82
82
  .checkbox-container {
83
83
  display: flex;
84
84
  flex-flow: row wrap;
85
- gap: 10px;
85
+ gap: var(--sys-size-5);
86
86
  }
87
87
 
88
88
  input[type="checkbox"]:focus-visible {
@@ -18,10 +18,6 @@
18
18
 
19
19
  :host {
20
20
  overflow-x: auto;
21
- }
22
-
23
- :host,
24
- devtools-create-recording-view {
25
21
  display: flex;
26
22
  flex-direction: column;
27
23
  flex: 1;
@@ -112,10 +108,6 @@ devtools-menu {
112
108
  position: absolute;
113
109
  }
114
110
 
115
- devtools-recording-list-view {
116
- overflow: auto;
117
- }
118
-
119
111
  .error {
120
112
  color: var(--sys-color-error);
121
113
  border: var(--sys-size-1) solid var(--sys-color-error);
@@ -25,12 +25,12 @@
25
25
  justify-content: space-between;
26
26
  align-items: center;
27
27
  flex-wrap: wrap;
28
- gap: 10px;
28
+ gap: var(--sys-size-6);
29
29
  }
30
30
 
31
31
  h1 {
32
32
  font-size: var(--sys-typescale-body1-size);
33
- line-height: 19px;
33
+ line-height: var(--sys-typescale-body1-line-height);
34
34
  color: var(--sys-color-on-surface);
35
35
  font-weight: normal;
36
36
  }
@@ -43,13 +43,13 @@
43
43
  }
44
44
 
45
45
  .table {
46
- margin-top: 35px;
46
+ margin-top: var(--sys-size-13);
47
47
  }
48
48
 
49
49
  .title {
50
50
  font-size: var(--sys-typescale-body3-size);
51
51
  color: var(--sys-color-on-surface);
52
- margin-left: 10px;
52
+ margin-left: var(--sys-size-5);
53
53
  flex: 1;
54
54
  overflow-x: hidden;
55
55
  white-space: nowrap;
@@ -97,12 +97,6 @@
97
97
  margin-inline-start: calc(var(--timeline-section-inset-inline-start) + var(--sys-size-14));
98
98
  }
99
99
 
100
- .step .action {
101
- font-size: var(--sys-typescale-body3-size);
102
- line-height: var(--sys-typescale-body4-line-height);
103
- letter-spacing: 0.03em;
104
- }
105
-
106
100
  .recording {
107
101
  color: var(--sys-color-primary);
108
102
  font-style: italic;
@@ -231,10 +225,19 @@
231
225
  outline-offset: var(--sys-size-2);
232
226
  }
233
227
 
228
+ /*
229
+ * The settings and the actions are separated by column rules, which are only
230
+ * drawn between items on the same line, so that no separator is left
231
+ * dangling at the end of a line when they wrap.
232
+ * This relies on CSS gap decorations (column-rule on flex containers);
233
+ * browsers without them show no separators.
234
+ */
234
235
  .settings {
235
236
  margin-top: var(--sys-size-3);
236
237
  display: flex;
237
238
  flex-wrap: wrap;
239
+ column-gap: calc(2 * 5px + var(--sys-size-1));
240
+ column-rule: var(--sys-size-1) solid var(--sys-color-divider);
238
241
  font-size: var(--sys-typescale-body4-size);
239
242
  line-height: var(--sys-typescale-body2-line-height);
240
243
  letter-spacing: 0.03em;
@@ -243,26 +246,15 @@
243
246
 
244
247
  .settings.expanded {
245
248
  gap: 10px;
246
- }
247
-
248
- .settings .separator {
249
- width: var(--sys-size-1);
250
- height: var(--sys-size-9);
251
- background-color: var(--sys-color-divider);
252
- margin: 0 5px;
249
+ column-rule: none;
253
250
  }
254
251
 
255
252
  .actions {
256
253
  display: flex;
257
254
  align-items: center;
258
255
  flex-wrap: wrap;
259
- gap: var(--sys-size-6);
260
- }
261
-
262
- .actions .separator {
263
- width: var(--sys-size-1);
264
- height: var(--sys-size-11);
265
- background-color: var(--sys-color-divider);
256
+ gap: var(--sys-size-6) calc(2 * var(--sys-size-6) + var(--sys-size-1));
257
+ column-rule: var(--sys-size-1) solid var(--sys-color-divider);
266
258
  }
267
259
 
268
260
  .is-recording .header-title::before {
@@ -22,8 +22,8 @@
22
22
  font-family: var(--monospace-font-family);
23
23
  font-size: var(--monospace-font-size);
24
24
  align-items: center;
25
- line-height: 18px;
26
- margin-top: 3px;
25
+ line-height: var(--sys-typescale-body4-line-height);
26
+ margin-top: var(--sys-size-3);
27
27
  }
28
28
 
29
29
  .row devtools-button {
@@ -45,8 +45,8 @@
45
45
  }
46
46
 
47
47
  .inline-button {
48
- width: 18px;
49
- height: 18px;
48
+ width: var(--sys-size-8);
49
+ height: var(--sys-size-8);
50
50
  opacity: 0%;
51
51
  visibility: hidden;
52
52
  transition: opacity 200ms;
@@ -16,15 +16,15 @@
16
16
  }
17
17
 
18
18
  .title-container {
19
- /* Vertically center items with min-width: 0; */
20
19
  min-width: 0;
21
20
  font-size: var(--sys-size-7);
21
+ line-height: var(--sys-size-8);
22
22
  display: flex;
23
23
  flex-direction: row;
24
24
  gap: var(--sys-size-2);
25
25
  outline-offset: var(--sys-size-2);
26
26
  flex-grow: 1;
27
- align-items: center;
27
+ align-items: flex-start;
28
28
  /* Keeps the title aligned with the title of expandable steps. */
29
29
  padding-inline-start: var(--chevron-column-width);
30
30
  }
@@ -39,7 +39,7 @@
39
39
 
40
40
  .action {
41
41
  display: flex;
42
- align-items: center;
42
+ align-items: flex-start;
43
43
  }
44
44
 
45
45
  .title {
@@ -61,18 +61,31 @@
61
61
  opacity: 0%;
62
62
  fill: var(--sys-color-primary);
63
63
  stroke: #1a73e8; /* stylelint-disable-line plugin/use_theme_colors */
64
- transform: translate(-1.92px, -3px);
64
+ /* Shift 24x24 path (left stroke 2px, y-center 12px) by (-2px, -4px)
65
+ * to align with the 8px (--sys-size-5) .circle-icon center, .chevron, and first line of the title. */
66
+ transform: translate(
67
+ calc(-1 * var(--sys-size-2)),
68
+ calc(-1 * var(--sys-size-3))
69
+ );
65
70
  }
66
71
 
67
72
  .circle-icon {
68
73
  fill: var(--sys-color-primary);
69
74
  stroke: var(--sys-color-cdt-base-container);
70
75
  stroke-width: var(--sys-size-3);
71
- r: 5px;
76
+ r: var(--sys-size-4);
72
77
  cx: var(--sys-size-5);
73
78
  cy: var(--sys-size-5);
74
79
  }
75
80
 
81
+ .is-start-of-group:not(.is-first-section) .circle-icon {
82
+ /* 7px radius: the outer edge of the 2px (--sys-size-2) stroke touches the 16px icon box. */
83
+ r: calc(var(--sys-size-5) - var(--sys-size-1));
84
+ fill: var(--sys-color-cdt-base-container);
85
+ stroke: var(--sys-color-primary);
86
+ stroke-width: var(--sys-size-2);
87
+ }
88
+
76
89
  .step.is-success .circle-icon {
77
90
  fill: var(--sys-color-primary);
78
91
  stroke: var(--sys-color-primary);
@@ -96,11 +109,13 @@
96
109
 
97
110
  @keyframes rotate {
98
111
  0% {
99
- transform: translate(var(--sys-size-5), var(--sys-size-5)) rotate(0) translate(calc(-1 * var(--sys-size-5)), calc(-1 * var(--sys-size-5)));
112
+ transform: translate(var(--sys-size-5), var(--sys-size-5)) rotate(0)
113
+ translate(calc(-1 * var(--sys-size-5)), calc(-1 * var(--sys-size-5)));
100
114
  }
101
115
 
102
116
  100% {
103
- transform: translate(var(--sys-size-5), var(--sys-size-5)) rotate(360deg) translate(calc(-1 * var(--sys-size-5)), calc(-1 * var(--sys-size-5)));
117
+ transform: translate(var(--sys-size-5), var(--sys-size-5)) rotate(360deg)
118
+ translate(calc(-1 * var(--sys-size-5)), calc(-1 * var(--sys-size-5)));
104
119
  }
105
120
  }
106
121
 
@@ -148,9 +163,9 @@
148
163
 
149
164
  .chevron {
150
165
  flex-shrink: 0;
151
- /* Aligns the chevron with the first line of the title. */
166
+ /* Aligns the 14px (--sys-size-7) chevron with the 16px (--sys-size-8) first line and 8px (--sys-size-5) .circle-icon center. */
152
167
  align-self: flex-start;
153
- margin-block-start: var(--sys-size-4);
168
+ margin-block-start: var(--sys-size-1);
154
169
  width: var(--sys-size-7);
155
170
  height: var(--sys-size-7);
156
171
  transition: 200ms;
@@ -193,11 +208,18 @@
193
208
  text-overflow: ellipsis;
194
209
  }
195
210
 
211
+ .icon {
212
+ /* The 16px (--sys-size-8) circle icon is drawn in the top 16px of the 24x24 SVG. */
213
+ margin-block-end: calc(-1 * var(--sys-size-5));
214
+ }
215
+
196
216
  .step-actions {
197
217
  border: none;
198
218
  border-radius: 0;
199
219
  flex-shrink: 0;
200
220
  height: var(--sys-size-11);
221
+ /* Centers the 24px (--sys-size-11) button on the 16px (--sys-size-8) first line. */
222
+ margin-block: calc(-1 * var(--sys-size-3));
201
223
  }
202
224
 
203
225
  .step.has-breakpoint .circle-icon {
@@ -34,6 +34,10 @@
34
34
  padding-inline: var(--timeline-section-inset-inline-start, 0) var(--timeline-section-inset-inline-end, 0);
35
35
  }
36
36
 
37
+ .timeline-section.is-start-of-group:not(.is-first-section) {
38
+ --timeline-section-padding-block-start: var(--sys-size-8);
39
+ }
40
+
37
41
  .timeline-section.is-end-of-group {
38
42
  --timeline-section-padding-block-end: var(--sys-size-8);
39
43
  }
@@ -35,7 +35,6 @@ export type View = (input: ViewInput, output: ViewOutput, target: HTMLElement) =
35
35
  export const DEFAULT_VIEW: View = (input, _output, target) => {
36
36
  // clang-format off
37
37
  render(html`
38
- <style>${UI.inspectorCommonStyles}</style>
39
38
  <devtools-split-view
40
39
  direction="column"
41
40
  sidebar-position="second"
@@ -147,7 +147,7 @@
147
147
  }
148
148
 
149
149
  .security-explanation {
150
- padding: 11px;
150
+ padding: var(--sys-size-6);
151
151
  display: flex;
152
152
  white-space: nowrap;
153
153
  border: none;
@@ -12,7 +12,7 @@
12
12
 
13
13
  .title-section-header {
14
14
  padding-left: var(--sys-size-8);
15
- padding-bottom: 10px;
15
+ padding-bottom: var(--sys-size-6);
16
16
  font-size: var(--sys-typescale-body2-size);
17
17
  }
18
18
 
@@ -99,7 +99,7 @@
99
99
  }
100
100
 
101
101
  .details-toggle {
102
- margin-left: 126px;
102
+ margin-left: calc(var(--sys-size-21) + 1em); /* 128px label column + 1em right padding */
103
103
  }
104
104
 
105
105
  .details-table .empty-san {