chrome-devtools-frontend 1.0.1515446 → 1.0.1515988

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 (215) hide show
  1. package/docs/contributing/infrastructure.md +131 -82
  2. package/front_end/Tests.js +3 -29
  3. package/front_end/core/common/Progress.ts +73 -55
  4. package/front_end/core/host/UserMetrics.ts +0 -1
  5. package/front_end/core/protocol_client/InspectorBackend.ts +2 -0
  6. package/front_end/core/root/Runtime.ts +0 -1
  7. package/front_end/core/sdk/CSSMatchedStyles.ts +12 -10
  8. package/front_end/core/sdk/CSSModel.ts +1 -31
  9. package/front_end/core/sdk/CSSPropertyParserMatchers.ts +27 -7
  10. package/front_end/core/sdk/DebuggerModel.ts +1 -31
  11. package/front_end/core/sdk/EnhancedTracesParser.ts +81 -50
  12. package/front_end/core/sdk/NetworkManager.ts +1 -31
  13. package/front_end/core/sdk/NetworkRequest.ts +1 -31
  14. package/front_end/core/sdk/RehydratingConnection.snapshot.txt +1003 -0
  15. package/front_end/core/sdk/RehydratingConnection.ts +13 -18
  16. package/front_end/core/sdk/RehydratingObject.ts +8 -31
  17. package/front_end/core/sdk/RemoteObject.ts +1 -31
  18. package/front_end/core/sdk/ResourceTreeModel.ts +1 -31
  19. package/front_end/core/sdk/RuntimeModel.ts +1 -31
  20. package/front_end/core/sdk/ServiceWorkerManager.ts +1 -31
  21. package/front_end/core/sdk/SourceMap.ts +1 -31
  22. package/front_end/core/sdk/TraceObject.ts +8 -3
  23. package/front_end/entrypoints/main/MainImpl.ts +0 -2
  24. package/front_end/entrypoints/main/main-meta.ts +2 -2
  25. package/front_end/generated/InspectorBackendCommands.js +4 -4
  26. package/front_end/generated/SupportedCSSProperties.js +12 -0
  27. package/front_end/generated/protocol.ts +10 -1
  28. package/front_end/models/ai_assistance/AiHistoryStorage.ts +1 -3
  29. package/front_end/models/ai_assistance/ConversationHandler.ts +4 -6
  30. package/front_end/models/ai_assistance/agents/AiAgent.ts +4 -1
  31. package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +107 -72
  32. package/front_end/models/ai_assistance/agents/PerformanceAnnotationsAgent.ts +2 -2
  33. package/front_end/models/ai_assistance/agents/StylingAgent.ts +2 -2
  34. package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.snapshot.txt +178 -85
  35. package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.ts +308 -218
  36. package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +161 -97
  37. package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +78 -58
  38. package/front_end/models/ai_assistance/data_formatters/UnitFormatters.ts +10 -1
  39. package/front_end/models/ai_assistance/performance/AIContext.ts +19 -21
  40. package/front_end/models/ai_code_completion/AiCodeCompletion.ts +123 -55
  41. package/front_end/models/bindings/ContentProviderBasedProject.ts +6 -4
  42. package/front_end/models/breakpoints/BreakpointManager.ts +3 -3
  43. package/front_end/models/har/Writer.ts +11 -11
  44. package/front_end/models/javascript_metadata/NativeFunctions.js +7 -7
  45. package/front_end/models/persistence/FileSystemWorkspaceBinding.ts +3 -3
  46. package/front_end/models/persistence/IsolatedFileSystem.ts +4 -4
  47. package/front_end/models/persistence/IsolatedFileSystemManager.ts +7 -7
  48. package/front_end/models/persistence/PersistenceImpl.ts +8 -8
  49. package/front_end/models/persistence/PlatformFileSystem.ts +1 -1
  50. package/front_end/models/text_utils/TextUtils.ts +26 -0
  51. package/front_end/models/trace/ModelImpl.ts +2 -16
  52. package/front_end/models/trace/Processor.ts +14 -8
  53. package/front_end/models/trace/handlers/AuctionWorkletsHandler.ts +4 -4
  54. package/front_end/models/trace/handlers/FramesHandler.ts +2 -2
  55. package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +7 -10
  56. package/front_end/models/trace/handlers/MetaHandler.ts +11 -9
  57. package/front_end/models/trace/handlers/ScreenshotsHandler.ts +1 -1
  58. package/front_end/models/trace/handlers/ScriptsHandler.ts +5 -5
  59. package/front_end/models/trace/handlers/UserInteractionsHandler.ts +2 -14
  60. package/front_end/models/trace/handlers/UserTimingsHandler.ts +3 -4
  61. package/front_end/models/trace/insights/CLSCulprits.ts +1 -1
  62. package/front_end/models/trace/insights/DocumentLatency.ts +8 -7
  63. package/front_end/models/trace/insights/DuplicatedJavaScript.ts +1 -1
  64. package/front_end/models/trace/insights/INPBreakdown.ts +1 -1
  65. package/front_end/models/trace/insights/ImageDelivery.ts +1 -1
  66. package/front_end/models/trace/insights/LCPBreakdown.ts +1 -1
  67. package/front_end/models/trace/insights/LCPDiscovery.ts +1 -1
  68. package/front_end/models/trace/insights/ModernHTTP.ts +1 -1
  69. package/front_end/models/trace/insights/NetworkDependencyTree.ts +1 -1
  70. package/front_end/models/trace/insights/RenderBlocking.ts +1 -1
  71. package/front_end/models/trace/insights/types.ts +2 -0
  72. package/front_end/models/trace/types/Configuration.ts +12 -0
  73. package/front_end/models/trace/types/TraceEvents.ts +41 -64
  74. package/front_end/models/trace_source_maps_resolver/trace_source_maps_resolver.ts +1 -1
  75. package/front_end/panels/ai_assistance/AiAssistancePanel.ts +21 -99
  76. package/front_end/panels/application/ServiceWorkersView.ts +0 -1
  77. package/front_end/panels/application/components/BackForwardCacheStrings.ts +8 -2
  78. package/front_end/panels/browser_debugger/CategorizedBreakpointsSidebarPane.ts +2 -3
  79. package/front_end/panels/common/BadgeNotification.ts +10 -8
  80. package/front_end/panels/common/GdpSignUpDialog.ts +30 -14
  81. package/front_end/panels/common/gdpSignUpDialog.css +4 -0
  82. package/front_end/panels/console/ConsoleView.ts +23 -28
  83. package/front_end/panels/console/ConsoleViewport.ts +2 -2
  84. package/front_end/panels/console/consoleView.css +11 -1
  85. package/front_end/panels/coverage/CoverageView.ts +2 -2
  86. package/front_end/panels/elements/ElementsTreeOutline.ts +2 -2
  87. package/front_end/panels/elements/StyleEditorWidget.ts +8 -19
  88. package/front_end/panels/elements/StylePropertyTreeElement.ts +39 -25
  89. package/front_end/panels/elements/StylesSidebarPane.ts +2 -2
  90. package/front_end/panels/elements/stylePropertiesTreeOutline.css +4 -3
  91. package/front_end/panels/layer_viewer/Layers3DView.ts +2 -2
  92. package/front_end/panels/layers/LayerTreeModel.ts +3 -3
  93. package/front_end/panels/mobile_throttling/ThrottlingSettingsTab.ts +4 -4
  94. package/front_end/panels/network/NetworkLogView.ts +1 -1
  95. package/front_end/panels/network/NetworkLogViewColumns.ts +3 -3
  96. package/front_end/panels/network/NetworkSearchScope.ts +6 -6
  97. package/front_end/panels/search/SearchView.ts +220 -159
  98. package/front_end/panels/settings/components/SyncSection.ts +64 -10
  99. package/front_end/panels/settings/components/syncSection.css +6 -0
  100. package/front_end/panels/sources/AiCodeCompletionPlugin.ts +1 -4
  101. package/front_end/panels/sources/SourcesSearchScope.ts +4 -4
  102. package/front_end/panels/sources/TabbedEditorContainer.ts +5 -5
  103. package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +10 -5
  104. package/front_end/panels/timeline/TimelineFlameChartView.ts +18 -15
  105. package/front_end/panels/timeline/TimelinePanel.ts +41 -22
  106. package/front_end/panels/timeline/TracingLayerTree.ts +4 -5
  107. package/front_end/panels/timeline/components/ExportTraceOptions.ts +37 -22
  108. package/front_end/panels/timeline/components/insights/BaseInsightComponent.ts +17 -7
  109. package/front_end/panels/webauthn/WebauthnPane.ts +1 -1
  110. package/front_end/third_party/axe-core/README.chromium +1 -0
  111. package/front_end/third_party/chromium/README.chromium +1 -1
  112. package/front_end/third_party/codemirror/README.chromium +1 -0
  113. package/front_end/third_party/codemirror.next/README.chromium +1 -0
  114. package/front_end/third_party/csp_evaluator/README.chromium +1 -0
  115. package/front_end/third_party/diff/README.chromium +1 -0
  116. package/front_end/third_party/i18n/README.chromium +1 -0
  117. package/front_end/third_party/intl-messageformat/README.chromium +1 -0
  118. package/front_end/third_party/json5/README.chromium +1 -0
  119. package/front_end/third_party/legacy-javascript/README.chromium +1 -0
  120. package/front_end/third_party/lighthouse/README.chromium +1 -0
  121. package/front_end/third_party/lit/README.chromium +1 -0
  122. package/front_end/third_party/marked/README.chromium +1 -0
  123. package/front_end/third_party/puppeteer/README.chromium +2 -2
  124. package/front_end/third_party/puppeteer/package/README.md +6 -3
  125. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.d.ts +1 -1
  126. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts +11 -1
  127. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts.map +1 -1
  128. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js +2 -2
  129. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js.map +1 -1
  130. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts +5 -1
  131. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.d.ts.map +1 -1
  132. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js +30 -8
  133. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/Page.js.map +1 -1
  134. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
  135. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/BrowsingContext.js +1 -3
  136. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
  137. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Realm.d.ts +2 -2
  138. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.d.ts +1 -1
  139. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.d.ts.map +1 -1
  140. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.js +8 -2
  141. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/NetworkManager.js.map +1 -1
  142. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.d.ts +5 -1
  143. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.d.ts.map +1 -1
  144. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.js +8 -2
  145. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Page.js.map +1 -1
  146. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.d.ts +1 -1
  147. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.js +1 -1
  148. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts +1 -1
  149. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  150. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js +5 -0
  151. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserLauncher.js.map +1 -1
  152. package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts +2 -2
  153. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +12 -2
  154. package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +22 -8
  155. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.d.ts +1 -1
  156. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts +11 -1
  157. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts.map +1 -1
  158. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js +2 -2
  159. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js.map +1 -1
  160. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts +5 -1
  161. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.d.ts.map +1 -1
  162. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js +30 -8
  163. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/Page.js.map +1 -1
  164. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
  165. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/BrowsingContext.js +1 -3
  166. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
  167. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.d.ts +1 -1
  168. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.d.ts.map +1 -1
  169. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.js +8 -2
  170. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/NetworkManager.js.map +1 -1
  171. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.d.ts +5 -1
  172. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.d.ts.map +1 -1
  173. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.js +8 -2
  174. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Page.js.map +1 -1
  175. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.d.ts +1 -1
  176. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.js +1 -1
  177. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
  178. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js +5 -0
  179. package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserLauncher.js.map +1 -1
  180. package/front_end/third_party/puppeteer/package/lib/types.d.ts +12 -2
  181. package/front_end/third_party/puppeteer/package/package.json +4 -4
  182. package/front_end/third_party/puppeteer/package/src/api/Browser.ts +1 -1
  183. package/front_end/third_party/puppeteer/package/src/api/Page.ts +13 -2
  184. package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +50 -8
  185. package/front_end/third_party/puppeteer/package/src/bidi/core/BrowsingContext.ts +0 -1
  186. package/front_end/third_party/puppeteer/package/src/cdp/NetworkManager.ts +8 -1
  187. package/front_end/third_party/puppeteer/package/src/cdp/Page.ts +21 -5
  188. package/front_end/third_party/puppeteer/package/src/generated/version.ts +1 -1
  189. package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +12 -0
  190. package/front_end/third_party/puppeteer-replay/README.chromium +1 -0
  191. package/front_end/third_party/third-party-web/README.chromium +1 -0
  192. package/front_end/third_party/vscode.web-custom-data/README.chromium +1 -0
  193. package/front_end/third_party/wasmparser/README.chromium +1 -0
  194. package/front_end/third_party/web-vitals/README.chromium +1 -0
  195. package/front_end/ui/components/text_editor/config.ts +66 -16
  196. package/front_end/ui/components/tooltips/Tooltip.ts +17 -1
  197. package/front_end/ui/legacy/ContextMenu.ts +2 -2
  198. package/front_end/ui/legacy/GlassPane.ts +7 -3
  199. package/front_end/ui/legacy/ProgressIndicator.ts +33 -21
  200. package/front_end/ui/legacy/TabbedPane.ts +2 -2
  201. package/front_end/ui/legacy/Treeoutline.ts +10 -5
  202. package/front_end/ui/legacy/UIUtils.ts +42 -10
  203. package/front_end/ui/legacy/components/color_picker/Spectrum.ts +14 -14
  204. package/front_end/ui/legacy/components/data_grid/DataGrid.ts +6 -6
  205. package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +4 -2
  206. package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +3 -29
  207. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +14 -14
  208. package/front_end/ui/visual_logging/Debugging.ts +24 -12
  209. package/front_end/ui/visual_logging/KnownContextValues.ts +3 -0
  210. package/inspector_overlay/highlight_common.ts +1 -27
  211. package/inspector_overlay/highlight_grid_common.ts +1 -27
  212. package/inspector_overlay/tool_highlight.ts +1 -27
  213. package/inspector_overlay/tool_persistent.ts +1 -27
  214. package/inspector_overlay/tool_source_order.ts +1 -27
  215. package/package.json +3 -3
@@ -31,6 +31,81 @@ export class PerformanceTraceFormatter {
31
31
  return `{min: ${bounds.min}, max: ${bounds.max}}`;
32
32
  }
33
33
 
34
+ /**
35
+ * Fetching the Crux summary can error outside of DevTools, hence the
36
+ * try-catch around it here.
37
+ */
38
+ #getCruxTraceSummary(insightSet: Trace.Insights.Types.InsightSet|null): string[] {
39
+ if (insightSet === null) {
40
+ return [];
41
+ }
42
+ try {
43
+ const cruxScope = CrUXManager.CrUXManager.instance().getSelectedScope();
44
+ const parts: string[] = [];
45
+ const fieldMetrics =
46
+ Trace.Insights.Common.getFieldMetricsForInsightSet(insightSet, this.#parsedTrace.metadata, cruxScope);
47
+ const fieldLcp = fieldMetrics?.lcp;
48
+ const fieldInp = fieldMetrics?.inp;
49
+ const fieldCls = fieldMetrics?.cls;
50
+
51
+ if (fieldLcp || fieldInp || fieldCls) {
52
+ parts.push('Metrics (field / real users):');
53
+
54
+ const serializeFieldMetricTimingResult =
55
+ (fieldMetric: Trace.Insights.Common.CrUXFieldMetricTimingResult): string => {
56
+ return `${Math.round(fieldMetric.value / 1000)} ms (scope: ${fieldMetric.pageScope})`;
57
+ };
58
+
59
+ const serializeFieldMetricNumberResult =
60
+ (fieldMetric: Trace.Insights.Common.CrUXFieldMetricNumberResult): string => {
61
+ return `${fieldMetric.value.toFixed(2)} (scope: ${fieldMetric.pageScope})`;
62
+ };
63
+
64
+ if (fieldLcp) {
65
+ parts.push(` - LCP: ${serializeFieldMetricTimingResult(fieldLcp)}`);
66
+
67
+ const fieldLcpBreakdown = fieldMetrics?.lcpBreakdown;
68
+ if (fieldLcpBreakdown &&
69
+ (fieldLcpBreakdown.ttfb || fieldLcpBreakdown.loadDelay || fieldLcpBreakdown.loadDuration ||
70
+ fieldLcpBreakdown.renderDelay)) {
71
+ parts.push(' - LCP breakdown:');
72
+ if (fieldLcpBreakdown.ttfb) {
73
+ parts.push(` - TTFB: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.ttfb)}`);
74
+ }
75
+ if (fieldLcpBreakdown.loadDelay) {
76
+ parts.push(` - Load delay: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.loadDelay)}`);
77
+ }
78
+ if (fieldLcpBreakdown.loadDuration) {
79
+ parts.push(` - Load duration: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.loadDuration)}`);
80
+ }
81
+ if (fieldLcpBreakdown.renderDelay) {
82
+ parts.push(` - Render delay: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.renderDelay)}`);
83
+ }
84
+ }
85
+ }
86
+ if (fieldInp) {
87
+ parts.push(` - INP: ${serializeFieldMetricTimingResult(fieldInp)}`);
88
+ }
89
+ if (fieldCls) {
90
+ parts.push(` - CLS: ${serializeFieldMetricNumberResult(fieldCls)}`);
91
+ }
92
+
93
+ parts.push(
94
+ ' - The above data is from CrUX–Chrome User Experience Report. It\'s how the page performs for real users.');
95
+ parts.push(' - The values shown above are the p75 measure of all real Chrome users');
96
+ parts.push(' - The scope indicates if the data came from the entire origin, or a specific url');
97
+ parts.push(
98
+ ' - Lab metrics describe how this specific page load performed, while field metrics are an aggregation ' +
99
+ 'of results from real-world users. Best practice is to prioritize metrics that are bad in field data. ' +
100
+ 'Lab metrics may be better or worse than fields metrics depending on the developer\'s machine, network, or the ' +
101
+ 'actions performed while tracing.');
102
+ }
103
+ return parts;
104
+ } catch {
105
+ return [];
106
+ }
107
+ }
108
+
34
109
  formatTraceSummary(): string {
35
110
  const parsedTrace = this.#parsedTrace;
36
111
  const insightSet = this.#insightSet;
@@ -78,64 +153,9 @@ export class PerformanceTraceFormatter {
78
153
  parts.push('Metrics (lab / observed): n/a');
79
154
  }
80
155
 
81
- const fieldMetrics = insightSet &&
82
- Trace.Insights.Common.getFieldMetricsForInsightSet(
83
- insightSet, traceMetadata, CrUXManager.CrUXManager.instance().getSelectedScope());
84
- const fieldLcp = fieldMetrics?.lcp;
85
- const fieldInp = fieldMetrics?.inp;
86
- const fieldCls = fieldMetrics?.cls;
87
-
88
- if (fieldLcp || fieldInp || fieldCls) {
89
- parts.push('Metrics (field / real users):');
90
-
91
- const serializeFieldMetricTimingResult =
92
- (fieldMetric: Trace.Insights.Common.CrUXFieldMetricTimingResult): string => {
93
- return `${Math.round(fieldMetric.value / 1000)} ms (scope: ${fieldMetric.pageScope})`;
94
- };
95
-
96
- const serializeFieldMetricNumberResult =
97
- (fieldMetric: Trace.Insights.Common.CrUXFieldMetricNumberResult): string => {
98
- return `${fieldMetric.value.toFixed(2)} (scope: ${fieldMetric.pageScope})`;
99
- };
100
-
101
- if (fieldLcp) {
102
- parts.push(` - LCP: ${serializeFieldMetricTimingResult(fieldLcp)}`);
103
-
104
- const fieldLcpBreakdown = fieldMetrics?.lcpBreakdown;
105
- if (fieldLcpBreakdown &&
106
- (fieldLcpBreakdown.ttfb || fieldLcpBreakdown.loadDelay || fieldLcpBreakdown.loadDuration ||
107
- fieldLcpBreakdown.renderDelay)) {
108
- parts.push(' - LCP breakdown:');
109
- if (fieldLcpBreakdown.ttfb) {
110
- parts.push(` - TTFB: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.ttfb)}`);
111
- }
112
- if (fieldLcpBreakdown.loadDelay) {
113
- parts.push(` - Load delay: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.loadDelay)}`);
114
- }
115
- if (fieldLcpBreakdown.loadDuration) {
116
- parts.push(` - Load duration: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.loadDuration)}`);
117
- }
118
- if (fieldLcpBreakdown.renderDelay) {
119
- parts.push(` - Render delay: ${serializeFieldMetricTimingResult(fieldLcpBreakdown.renderDelay)}`);
120
- }
121
- }
122
- }
123
- if (fieldInp) {
124
- parts.push(` - INP: ${serializeFieldMetricTimingResult(fieldInp)}`);
125
- }
126
- if (fieldCls) {
127
- parts.push(` - CLS: ${serializeFieldMetricNumberResult(fieldCls)}`);
128
- }
129
-
130
- parts.push(
131
- ' - The above data is from CrUX–Chrome User Experience Report. It\'s how the page performs for real users.');
132
- parts.push(' - The values shown above are the p75 measure of all real Chrome users');
133
- parts.push(' - The scope indicates if the data came from the entire origin, or a specific url');
134
- parts.push(
135
- ' - Lab metrics describe how this specific page load performed, while field metrics are an aggregation ' +
136
- 'of results from real-world users. Best practice is to prioritize metrics that are bad in field data. ' +
137
- 'Lab metrics may be better or worse than fields metrics depending on the developer\'s machine, network, or the ' +
138
- 'actions performed while tracing.');
156
+ const cruxParts = insightSet && this.#getCruxTraceSummary(insightSet);
157
+ if (cruxParts?.length) {
158
+ parts.push(...cruxParts);
139
159
  } else {
140
160
  parts.push('Metrics (field / real users): n/a – no data for this page in CrUX');
141
161
  }
@@ -10,7 +10,7 @@ const defaultTimeFormatterOptions: Intl.NumberFormatOptions = {
10
10
  style: 'unit',
11
11
  unitDisplay: 'narrow',
12
12
  minimumFractionDigits: 0,
13
- maximumFractionDigits: 1,
13
+ maximumFractionDigits: 0,
14
14
  } as const;
15
15
 
16
16
  const defaultByteFormatterOptions: Intl.NumberFormatOptions = {
@@ -25,8 +25,14 @@ const timeFormatters = {
25
25
  ...defaultTimeFormatterOptions,
26
26
  unit: 'millisecond',
27
27
  }),
28
+ milliWithPrecision: new Intl.NumberFormat('en-US', {
29
+ ...defaultTimeFormatterOptions,
30
+ maximumFractionDigits: 1,
31
+ unit: 'millisecond',
32
+ }),
28
33
  second: new Intl.NumberFormat('en-US', {
29
34
  ...defaultTimeFormatterOptions,
35
+ maximumFractionDigits: 1,
30
36
  unit: 'second',
31
37
  }),
32
38
  micro: new Intl.NumberFormat('en-US', {
@@ -81,6 +87,9 @@ export function millis(x: number): string {
81
87
  if (numberIsTooLarge(x)) {
82
88
  return '-';
83
89
  }
90
+ if (x < 1) {
91
+ return formatAndEnsureSpace(timeFormatters.milliWithPrecision, x);
92
+ }
84
93
  return formatAndEnsureSpace(timeFormatters.milli, x);
85
94
  }
86
95
 
@@ -6,28 +6,13 @@ import * as Trace from '../../../models/trace/trace.js';
6
6
 
7
7
  import type {AICallTree} from './AICallTree.js';
8
8
 
9
- export interface AgentFocusDataFull {
10
- type: 'full';
9
+ export interface AgentFocusData {
11
10
  parsedTrace: Trace.TraceModel.ParsedTrace;
12
11
  insightSet: Trace.Insights.Types.InsightSet|null;
12
+ callTree: AICallTree|null;
13
+ insight: Trace.Insights.Types.InsightModel|null;
13
14
  }
14
15
 
15
- interface AgentFocusDataCallTree {
16
- type: 'call-tree';
17
- parsedTrace: Trace.TraceModel.ParsedTrace;
18
- insightSet: Trace.Insights.Types.InsightSet|null;
19
- callTree: AICallTree;
20
- }
21
-
22
- export interface AgentFocusDataInsight {
23
- type: 'insight';
24
- parsedTrace: Trace.TraceModel.ParsedTrace;
25
- insightSet: Trace.Insights.Types.InsightSet|null;
26
- insight: Trace.Insights.Types.InsightModel;
27
- }
28
-
29
- type AgentFocusData = AgentFocusDataCallTree|AgentFocusDataInsight|AgentFocusDataFull;
30
-
31
16
  function getFirstInsightSet(insights: Trace.Insights.Types.TraceInsightSets): Trace.Insights.Types.InsightSet|null {
32
17
  // Currently only support a single insight set. Pick the first one with a navigation.
33
18
  // TODO(cjamcl): we should just give the agent the entire insight set, and give
@@ -43,9 +28,10 @@ export class AgentFocus {
43
28
 
44
29
  const insightSet = getFirstInsightSet(parsedTrace.insights);
45
30
  return new AgentFocus({
46
- type: 'full',
47
31
  parsedTrace,
48
32
  insightSet,
33
+ callTree: null,
34
+ insight: null,
49
35
  });
50
36
  }
51
37
 
@@ -57,9 +43,9 @@ export class AgentFocus {
57
43
 
58
44
  const insightSet = getFirstInsightSet(parsedTrace.insights);
59
45
  return new AgentFocus({
60
- type: 'insight',
61
46
  parsedTrace,
62
47
  insightSet,
48
+ callTree: null,
63
49
  insight,
64
50
  });
65
51
  }
@@ -79,7 +65,7 @@ export class AgentFocus {
79
65
  getFirstInsightSet(insights);
80
66
  }
81
67
 
82
- return new AgentFocus({type: 'call-tree', parsedTrace: callTree.parsedTrace, insightSet, callTree});
68
+ return new AgentFocus({parsedTrace: callTree.parsedTrace, insightSet, callTree, insight: null});
83
69
  }
84
70
 
85
71
  #data: AgentFocusData;
@@ -91,6 +77,18 @@ export class AgentFocus {
91
77
  get data(): AgentFocusData {
92
78
  return this.#data;
93
79
  }
80
+
81
+ withInsight(insight: Trace.Insights.Types.InsightModel|null): AgentFocus {
82
+ const focus = new AgentFocus(this.#data);
83
+ focus.#data.insight = insight;
84
+ return focus;
85
+ }
86
+
87
+ withCallTree(callTree: AICallTree|null): AgentFocus {
88
+ const focus = new AgentFocus(this.#data);
89
+ focus.#data.callTree = callTree;
90
+ return focus;
91
+ }
94
92
  }
95
93
 
96
94
  export function getPerformanceAgentFocusFromModel(model: Trace.TraceModel.Model): AgentFocus|null {
@@ -202,70 +202,133 @@ export class AiCodeCompletion extends Common.ObjectWrapper.ObjectWrapper<EventTy
202
202
  };
203
203
  }
204
204
 
205
+ async #completeCodeCached(request: Host.AidaClient.CompletionRequest): Promise<{
206
+ response: Host.AidaClient.CompletionResponse | null,
207
+ fromCache: boolean,
208
+ }> {
209
+ const cachedResponse = this.#checkCachedRequestForResponse(request);
210
+ if (cachedResponse) {
211
+ return {response: cachedResponse, fromCache: true};
212
+ }
213
+
214
+ const response = await this.#aidaClient.completeCode(request);
215
+ if (!response) {
216
+ return {
217
+ response: null,
218
+ fromCache: false,
219
+ };
220
+ }
221
+
222
+ this.#updateCachedRequest(request, response);
223
+ return {
224
+ response,
225
+ fromCache: false,
226
+ };
227
+ }
228
+
229
+ #pickSampleFromResponse(response: Host.AidaClient.CompletionResponse): Host.AidaClient.GenerationSample|null {
230
+ if (!response.generatedSamples.length) {
231
+ return null;
232
+ }
233
+
234
+ // `currentHint` is the portion of a standard autocomplete suggestion that the user has not yet typed.
235
+ // For example, if the user types `document.queryS` and the autocomplete suggests `document.querySelector`,
236
+ // the `currentHint` is `elector`.
237
+ const currentHintInMenu = this.#editor.editor.plugin(TextEditor.Config.showCompletionHint)?.currentHint;
238
+ // TODO(ergunsh): We should not do this check here. Instead, the AI code suggestions should be provided
239
+ // as it is to the view plugin. The view plugin should choose which one to use based on the completion hint
240
+ // and selected completion.
241
+ if (!currentHintInMenu) {
242
+ return response.generatedSamples[0];
243
+ }
244
+
245
+ // TODO(ergunsh): This does not handle looking for `selectedCompletion`. The `currentHint` is `null`
246
+ // for the Sources panel case.
247
+ // Even though there is no match, we still return the first suggestion which will be displayed
248
+ // when the traditional autocomplete menu is closed.
249
+ return response.generatedSamples.find(sample => sample.generationString.startsWith(currentHintInMenu)) ??
250
+ response.generatedSamples[0];
251
+ }
252
+
253
+ async #generateSampleForRequest(request: Host.AidaClient.CompletionRequest, cursor: number): Promise<{
254
+ suggestionText: string,
255
+ sampleId: number,
256
+ fromCache: boolean,
257
+ citations: Host.AidaClient.Citation[],
258
+ rpcGlobalId?: Host.AidaClient.RpcGlobalId,
259
+ }|null> {
260
+ const {response, fromCache} = await this.#completeCodeCached(request);
261
+ debugLog('At cursor position', cursor, {request, response, fromCache});
262
+ if (!response) {
263
+ return null;
264
+ }
265
+
266
+ const suggestionSample = this.#pickSampleFromResponse(response);
267
+ if (!suggestionSample) {
268
+ return null;
269
+ }
270
+
271
+ const shouldBlock =
272
+ suggestionSample.attributionMetadata?.attributionAction === Host.AidaClient.RecitationAction.BLOCK;
273
+ if (shouldBlock) {
274
+ return null;
275
+ }
276
+
277
+ const suggestionText = this.#trimSuggestionOverlap(suggestionSample.generationString, request);
278
+ if (suggestionText.length === 0) {
279
+ return null;
280
+ }
281
+
282
+ return {
283
+ suggestionText,
284
+ sampleId: suggestionSample.sampleId,
285
+ fromCache,
286
+ citations: suggestionSample.attributionMetadata?.citations ?? [],
287
+ rpcGlobalId: response.metadata.rpcGlobalId,
288
+ };
289
+ }
290
+
205
291
  async #requestAidaSuggestion(request: Host.AidaClient.CompletionRequest, cursor: number): Promise<void> {
206
292
  const startTime = performance.now();
207
- let servedFromCache = false;
208
293
  this.dispatchEventToListeners(Events.REQUEST_TRIGGERED, {});
209
294
 
210
295
  try {
211
- let response = this.#checkCachedRequestForResponse(request);
212
- if (!response) {
213
- response = await this.#aidaClient.completeCode(request);
214
- if (response) {
215
- this.#updateCachedRequest(request, response);
216
- }
217
- } else {
218
- servedFromCache = true;
296
+ const sampleResponse = await this.#generateSampleForRequest(request, cursor);
297
+ if (!sampleResponse) {
298
+ this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {});
299
+ return;
219
300
  }
220
- debugLog('At cursor position', cursor, {request, response});
221
- if (response && response.generatedSamples.length > 0 && response.generatedSamples[0].generationString) {
222
- if (response.generatedSamples[0].attributionMetadata?.attributionAction ===
223
- Host.AidaClient.RecitationAction.BLOCK) {
224
- this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {});
225
- return;
226
- }
227
301
 
228
- // Use the suffix from the request to find and remove any overlap.
229
- let suggestionText = response.generatedSamples[0].generationString;
230
- if (request.suffix && request.suffix.length > 0) {
231
- suggestionText = this.#trimSuggestionOverlap(response.generatedSamples[0].generationString, request.suffix);
302
+ const {
303
+ suggestionText,
304
+ sampleId,
305
+ fromCache,
306
+ citations,
307
+ rpcGlobalId,
308
+ } = sampleResponse;
309
+ const remainingDelay = Math.max(DELAY_BEFORE_SHOWING_RESPONSE_MS - (performance.now() - startTime), 0);
310
+ this.#renderingTimeout = window.setTimeout(() => {
311
+ this.#editor.dispatch({
312
+ effects: TextEditor.Config.setAiAutoCompleteSuggestion.of({
313
+ text: suggestionText,
314
+ from: cursor,
315
+ rpcGlobalId,
316
+ sampleId,
317
+ })
318
+ });
319
+
320
+ if (fromCache) {
321
+ Host.userMetrics.actionTaken(Host.UserMetrics.Action.AiCodeCompletionResponseServedFromCache);
232
322
  }
233
- if (suggestionText.length === 0) {
234
- this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {});
235
- return;
323
+
324
+ if (rpcGlobalId) {
325
+ const latency = performance.now() - startTime;
326
+ this.#registerUserImpression(rpcGlobalId, sampleId, latency);
236
327
  }
237
328
 
238
- const remainderDelay = Math.max(DELAY_BEFORE_SHOWING_RESPONSE_MS - (performance.now() - startTime), 0);
239
- // Delays the rendering of the Code completion
240
- this.#renderingTimeout = window.setTimeout(() => {
241
- // We are not cancelling the previous responses even when there are more recent responses
242
- // from the LLM as:
243
- // In case the user kept typing characters that are prefix of the previous suggestion, it
244
- // is a valid suggestion and we should display it to the user.
245
- // In case the user typed a different character, the config for AI auto complete suggestion
246
- // will set the suggestion to null.
247
- this.#editor.dispatch({
248
- effects: TextEditor.Config.setAiAutoCompleteSuggestion.of({
249
- text: suggestionText,
250
- from: cursor,
251
- rpcGlobalId: response.metadata.rpcGlobalId,
252
- sampleId: response.generatedSamples[0].sampleId,
253
- })
254
- });
255
- if (servedFromCache) {
256
- Host.userMetrics.actionTaken(Host.UserMetrics.Action.AiCodeCompletionResponseServedFromCache);
257
- }
258
- debugLog('Suggestion dispatched to the editor', response.generatedSamples[0], 'at cursor position', cursor);
259
- if (response.metadata.rpcGlobalId) {
260
- const latency = performance.now() - startTime;
261
- this.#registerUserImpression(response.metadata.rpcGlobalId, response.generatedSamples[0].sampleId, latency);
262
- }
263
- const citations = response.generatedSamples[0].attributionMetadata?.citations;
264
- this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {citations});
265
- }, remainderDelay);
266
- } else {
267
- this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {});
268
- }
329
+ debugLog('Suggestion dispatched to the editor', suggestionText, 'at cursor position', cursor);
330
+ this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {citations});
331
+ }, remainingDelay);
269
332
  } catch (e) {
270
333
  debugLog('Error while fetching code completion suggestions from AIDA', e);
271
334
  this.dispatchEventToListeners(Events.RESPONSE_RECEIVED, {});
@@ -289,7 +352,12 @@ export class AiCodeCompletion extends Common.ObjectWrapper.ObjectWrapper<EventTy
289
352
  /**
290
353
  * Removes the end of a suggestion if it overlaps with the start of the suffix.
291
354
  */
292
- #trimSuggestionOverlap(generationString: string, suffix: string): string {
355
+ #trimSuggestionOverlap(generationString: string, request: Host.AidaClient.CompletionRequest): string {
356
+ const suffix = request.suffix;
357
+ if (!suffix) {
358
+ return generationString;
359
+ }
360
+
293
361
  // Iterate from the longest possible overlap down to the shortest
294
362
  for (let i = Math.min(generationString.length, suffix.length); i > 0; i--) {
295
363
  const overlapCandidate = suffix.substring(0, i);
@@ -126,9 +126,9 @@ export class ContentProviderBasedProject extends Workspace.Workspace.ProjectStor
126
126
  progress: Common.Progress.Progress):
127
127
  Promise<Map<Workspace.UISourceCode.UISourceCode, TextUtils.ContentProvider.SearchMatch[]|null>> {
128
128
  const result = new Map();
129
- progress.setTotalWork(filesMatchingFileQuery.length);
129
+ progress.totalWork = filesMatchingFileQuery.length;
130
130
  await Promise.all(filesMatchingFileQuery.map(searchInContent.bind(this)));
131
- progress.done();
131
+ progress.done = true;
132
132
  return result;
133
133
 
134
134
  async function searchInContent(
@@ -148,12 +148,14 @@ export class ContentProviderBasedProject extends Workspace.Workspace.ProjectStor
148
148
  if (allMatchesFound) {
149
149
  result.set(uiSourceCode, matches);
150
150
  }
151
- progress.incrementWorked(1);
151
+ ++progress.worked;
152
152
  }
153
153
  }
154
154
 
155
155
  override indexContent(progress: Common.Progress.Progress): void {
156
- queueMicrotask(progress.done.bind(progress));
156
+ queueMicrotask(() => {
157
+ progress.done = true;
158
+ });
157
159
  }
158
160
 
159
161
  addUISourceCodeWithProvider(
@@ -272,7 +272,7 @@ export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper<EventT
272
272
  if (!BreakpointManager.isValidPositionInScript(lineNumber, columnNumber, script)) {
273
273
  continue;
274
274
  }
275
- this.innerSetBreakpoint(
275
+ this.#setBreakpoint(
276
276
  uiSourceCode, lineNumber, columnNumber, breakpoint.condition, breakpoint.enabled, breakpoint.isLogpoint,
277
277
  BreakpointOrigin.OTHER);
278
278
  }
@@ -316,7 +316,7 @@ export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper<EventT
316
316
  const normalizedLocation = await this.debuggerWorkspaceBinding.normalizeUILocation(uiLocation);
317
317
  const breakpointLocation = BreakpointManager.breakpointLocationFromUiLocation(normalizedLocation);
318
318
 
319
- const breakpoint = this.innerSetBreakpoint(
319
+ const breakpoint = this.#setBreakpoint(
320
320
  normalizedLocation.uiSourceCode, breakpointLocation.lineNumber, breakpointLocation.columnNumber, condition,
321
321
  enabled, isLogpoint, origin);
322
322
 
@@ -333,7 +333,7 @@ export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper<EventT
333
333
  return primaryBreakpoint;
334
334
  }
335
335
 
336
- private innerSetBreakpoint(
336
+ #setBreakpoint(
337
337
  uiSourceCode: Workspace.UISourceCode.UISourceCode, lineNumber: number, columnNumber: number|undefined,
338
338
  condition: UserCondition, enabled: boolean, isLogpoint: boolean, origin: BreakpointOrigin): Breakpoint {
339
339
  const url = BreakpointManager.getScriptForInlineUiSourceCode(uiSourceCode)?.sourceURL ?? uiSourceCode.url();
@@ -59,7 +59,7 @@ export class Writer {
59
59
  const compositeProgress = new Common.Progress.CompositeProgress(progress);
60
60
 
61
61
  const content = await Writer.harStringForRequests(requests, options, compositeProgress);
62
- if (progress.isCanceled()) {
62
+ if (progress.canceled) {
63
63
  return;
64
64
  }
65
65
  await Writer.writeToStream(stream, compositeProgress, content);
@@ -69,8 +69,8 @@ export class Writer {
69
69
  requests: SDK.NetworkRequest.NetworkRequest[], options: BuildOptions,
70
70
  compositeProgress: Common.Progress.CompositeProgress): Promise<string> {
71
71
  const progress = compositeProgress.createSubProgress();
72
- progress.setTitle(i18nString(UIStrings.collectingContent));
73
- progress.setTotalWork(requests.length);
72
+ progress.title = i18nString(UIStrings.collectingContent);
73
+ progress.totalWork = requests.length;
74
74
 
75
75
  // Sort by issueTime because this is recorded as startedDateTime in HAR logs.
76
76
  requests.sort((reqA, reqB) => reqA.issueTime() - reqB.issueTime());
@@ -82,9 +82,9 @@ export class Writer {
82
82
  }
83
83
 
84
84
  await Promise.all(promises);
85
- progress.done();
85
+ progress.done = true;
86
86
 
87
- if (progress.isCanceled()) {
87
+ if (progress.canceled) {
88
88
  return '';
89
89
  }
90
90
  return JSON.stringify({log: harLog}, null, jsonIndent);
@@ -106,7 +106,7 @@ export class Writer {
106
106
  }
107
107
 
108
108
  function contentLoaded(entry: EntryDTO, contentDataOrError: TextUtils.ContentData.ContentDataOrError): void {
109
- progress.incrementWorked();
109
+ ++progress.worked;
110
110
  const contentData = TextUtils.ContentData.ContentData.asDeferredContent(contentDataOrError);
111
111
  let encoded: true|boolean = contentData.isEncoded;
112
112
  if (contentData.content !== null) {
@@ -127,14 +127,14 @@ export class Writer {
127
127
  stream: Common.StringOutputStream.OutputStream, compositeProgress: Common.Progress.CompositeProgress,
128
128
  fileContent: string): Promise<void> {
129
129
  const progress = compositeProgress.createSubProgress();
130
- progress.setTitle(i18nString(UIStrings.writingFile));
131
- progress.setTotalWork(fileContent.length);
132
- for (let i = 0; i < fileContent.length && !progress.isCanceled(); i += chunkSize) {
130
+ progress.title = i18nString(UIStrings.writingFile);
131
+ progress.totalWork = fileContent.length;
132
+ for (let i = 0; i < fileContent.length && !progress.canceled; i += chunkSize) {
133
133
  const chunk = fileContent.substr(i, chunkSize);
134
134
  await stream.write(chunk);
135
- progress.incrementWorked(chunk.length);
135
+ progress.worked += chunk.length;
136
136
  }
137
- progress.done();
137
+ progress.done = true;
138
138
  }
139
139
  }
140
140
 
@@ -6088,7 +6088,7 @@ export const NativeFunctions = [
6088
6088
  },
6089
6089
  {
6090
6090
  name: "addAnimation",
6091
- signatures: [["animation"]]
6091
+ signatures: [["animation","action","behavior"]]
6092
6092
  },
6093
6093
  {
6094
6094
  name: "removeAnimation",
@@ -6765,6 +6765,10 @@ export const NativeFunctions = [
6765
6765
  name: "DragEvent",
6766
6766
  signatures: [["type","?eventInitDict"]]
6767
6767
  },
6768
+ {
6769
+ name: "EmailVerifiedEvent",
6770
+ signatures: [["type","?eventInitDict"]]
6771
+ },
6768
6772
  {
6769
6773
  name: "ErrorEvent",
6770
6774
  signatures: [["type","?eventInitDict"]]
@@ -7605,7 +7609,7 @@ export const NativeFunctions = [
7605
7609
  signatures: [["element","x","y","?dwidth","?dheight"]]
7606
7610
  },
7607
7611
  {
7608
- name: "drawHTML",
7612
+ name: "drawElementImage",
7609
7613
  signatures: [["element","x","y","?dwidth","?dheight"]]
7610
7614
  },
7611
7615
  {
@@ -8420,10 +8424,6 @@ export const NativeFunctions = [
8420
8424
  name: "RTCRtpScriptTransform",
8421
8425
  signatures: [["worker","?options","?transfer"]]
8422
8426
  },
8423
- {
8424
- name: "sendRtp",
8425
- signatures: [["packet","options"]]
8426
- },
8427
8427
  {
8428
8428
  name: "setHeaderExtensionsToNegotiate",
8429
8429
  signatures: [["extensions"]]
@@ -8891,7 +8891,7 @@ export const NativeFunctions = [
8891
8891
  signatures: [["provokeMode"]]
8892
8892
  },
8893
8893
  {
8894
- name: "texHTML2D",
8894
+ name: "texElementImage2D",
8895
8895
  signatures: [["target","level","internalformat","format","type","element"]]
8896
8896
  },
8897
8897
  {
@@ -276,14 +276,14 @@ export class FileSystem extends Workspace.Workspace.ProjectStore {
276
276
  if (!queriesToRun.length) {
277
277
  queriesToRun.push('');
278
278
  }
279
- progress.setTotalWork(queriesToRun.length);
279
+ progress.totalWork = queriesToRun.length;
280
280
 
281
281
  for (const query of queriesToRun) {
282
282
  const files = await this.#fileSystem.searchInPath(searchConfig.isRegex() ? '' : query, progress);
283
283
  files.sort(Platform.StringUtilities.naturalOrderComparator);
284
284
  workingFileSet = Platform.ArrayUtilities.intersectOrdered(
285
285
  workingFileSet, files, Platform.StringUtilities.naturalOrderComparator);
286
- progress.incrementWorked(1);
286
+ ++progress.worked;
287
287
  }
288
288
 
289
289
  const result = new Map();
@@ -294,7 +294,7 @@ export class FileSystem extends Workspace.Workspace.ProjectStore {
294
294
  }
295
295
  }
296
296
 
297
- progress.done();
297
+ progress.done = true;
298
298
  return result;
299
299
  }
300
300