chrome-devtools-frontend 1.0.1571007 → 1.0.1572937
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.
- package/agents/prompts/README.md +18 -0
- package/agents/prompts/devtools-imports.md +47 -0
- package/agents/prompts/verification.md +27 -0
- package/front_end/Images/geminiInDevTools.png +0 -0
- package/front_end/Images/geminiInDevTools_2x.png +0 -0
- package/front_end/Images/src/database-off.svg +1 -0
- package/front_end/Images/src/lock-person.svg +1 -1
- package/front_end/core/common/Debouncer.ts +10 -1
- package/front_end/core/common/SettingRegistration.ts +1 -1
- package/front_end/core/host/AidaClient.ts +8 -0
- package/front_end/core/host/InspectorFrontendHostAPI.ts +0 -6
- package/front_end/core/host/UserMetrics.ts +1 -31
- package/front_end/core/root/ExperimentNames.ts +30 -0
- package/front_end/core/root/Runtime.ts +47 -48
- package/front_end/core/root/root.ts +2 -0
- package/front_end/core/sdk/CSSModel.ts +36 -13
- package/front_end/core/sdk/CSSProperty.ts +1 -1
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +9 -0
- package/front_end/core/sdk/CookieModel.ts +2 -1
- package/front_end/core/sdk/DOMModel.ts +1 -1
- package/front_end/core/sdk/DebuggerModel.ts +1 -1
- package/front_end/core/sdk/OverlayModel.ts +3 -2
- package/front_end/core/sdk/SourceMap.ts +1 -1
- package/front_end/devtools_compatibility.js +0 -6
- package/front_end/entrypoints/main/MainImpl.ts +44 -24
- package/front_end/entrypoints/main/main-meta.ts +1 -1
- package/front_end/generated/SupportedCSSProperties.js +6 -14
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +0 -180
- package/front_end/models/ai_assistance/ai_assistance.ts +0 -2
- package/front_end/models/breakpoints/BreakpointManager.ts +3 -3
- package/front_end/models/issues_manager/ContrastCheckTrigger.ts +2 -2
- package/front_end/models/javascript_metadata/NativeFunctions.js +8 -0
- package/front_end/models/source_map_scopes/NamesResolver.ts +1 -1
- package/front_end/models/trace/EventsSerializer.ts +5 -1
- package/front_end/models/trace/ModelImpl.ts +0 -4
- package/front_end/models/trace/types/TraceEvents.ts +4 -0
- package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +1 -1
- package/front_end/panels/accessibility/AccessibilitySidebarView.ts +1 -1
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +8 -63
- package/front_end/panels/ai_assistance/PatchWidget.ts +10 -15
- package/front_end/panels/ai_assistance/SelectWorkspaceDialog.ts +5 -4
- package/front_end/panels/ai_assistance/aiAssistancePanel.css +0 -16
- package/front_end/panels/ai_assistance/ai_assistance.ts +0 -1
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +3 -2
- package/front_end/panels/ai_assistance/components/ChatView.ts +123 -108
- package/front_end/panels/ai_assistance/components/PerformanceAgentMarkdownRenderer.ts +1 -145
- package/front_end/panels/application/DeviceBoundSessionsModel.ts +23 -1
- package/front_end/panels/application/DeviceBoundSessionsTreeElement.ts +23 -0
- package/front_end/panels/application/FrameDetailsView.ts +12 -10
- package/front_end/panels/application/components/BackForwardCacheView.ts +6 -8
- package/front_end/panels/application/components/BounceTrackingMitigationsView.ts +4 -3
- package/front_end/panels/application/components/ProtocolHandlersView.ts +5 -6
- package/front_end/panels/application/components/ReportsGrid.ts +9 -9
- package/front_end/panels/application/components/SharedStorageAccessGrid.ts +5 -4
- package/front_end/panels/application/components/TrustTokensView.ts +4 -6
- package/front_end/panels/application/preloading/PreloadingView.ts +9 -8
- package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +237 -230
- package/front_end/panels/application/preloading/components/PreloadingGrid.ts +3 -2
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +6 -10
- package/front_end/panels/application/resourcesSidebar.css +8 -0
- package/front_end/panels/autofill/AutofillView.ts +4 -3
- package/front_end/panels/common/AiCodeCompletionSummaryToolbar.ts +3 -5
- package/front_end/panels/common/AiCodeCompletionTeaser.ts +5 -5
- package/front_end/panels/common/AiCodeGenerationTeaser.ts +35 -4
- package/front_end/panels/common/BadgeNotification.ts +17 -14
- package/front_end/panels/common/GdpSignUpDialog.ts +5 -6
- package/front_end/panels/common/GeminiRebrandPromoDialog.ts +192 -0
- package/front_end/panels/common/aiCodeGenerationTeaser.css +16 -1
- package/front_end/panels/common/common.ts +1 -0
- package/front_end/panels/common/geminiRebrandPromoDialog.css +47 -0
- package/front_end/panels/console/ConsoleInsightTeaser.ts +10 -11
- package/front_end/panels/console/ErrorStackParser.ts +11 -16
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewModel.ts +1 -1
- package/front_end/panels/elements/ComputedStyleModel.ts +16 -65
- package/front_end/panels/elements/ComputedStyleWidget.ts +3 -3
- package/front_end/panels/elements/ElementsPanel.ts +35 -5
- package/front_end/panels/elements/ElementsSidebarPane.ts +1 -1
- package/front_end/panels/elements/ElementsTreeOutline.ts +1 -1
- package/front_end/panels/elements/PlatformFontsWidget.ts +1 -1
- package/front_end/panels/elements/StylePropertiesSection.ts +16 -8
- package/front_end/panels/elements/StylePropertyTreeElement.ts +67 -32
- package/front_end/panels/elements/StylesSidebarPane.ts +28 -11
- package/front_end/panels/elements/components/CSSHintDetailsView.ts +3 -2
- package/front_end/panels/elements/components/CSSPropertyDocsView.ts +3 -2
- package/front_end/panels/elements/elements-meta.ts +1 -1
- package/front_end/panels/emulation/DeviceModeWrapper.ts +101 -62
- package/front_end/panels/explain/components/ConsoleInsight.ts +27 -23
- package/front_end/panels/explain/components/consoleInsight.css +1 -1
- package/front_end/panels/issues/IssueView.ts +6 -6
- package/front_end/panels/network/RequestConditionsDrawer.ts +4 -3
- package/front_end/panels/network/RequestCookiesView.ts +3 -4
- package/front_end/panels/network/RequestTimingView.ts +6 -10
- package/front_end/panels/network/components/HeaderSectionRow.ts +3 -2
- package/front_end/panels/network/components/RequestHeaderSection.ts +3 -1
- package/front_end/panels/network/components/RequestHeadersView.css +2 -2
- package/front_end/panels/network/components/RequestHeadersView.ts +7 -6
- package/front_end/panels/profiler/HeapProfileView.ts +3 -3
- package/front_end/panels/profiler/HeapSnapshotView.ts +2 -2
- package/front_end/panels/profiler/profiler-meta.ts +3 -3
- package/front_end/panels/protocol_monitor/protocol_monitor-meta.ts +1 -1
- package/front_end/panels/recorder/RecorderController.ts +7 -13
- package/front_end/panels/recorder/components/CreateRecordingView.ts +6 -6
- package/front_end/panels/recorder/components/RecordingView.ts +0 -38
- package/front_end/panels/recorder/components/ReplaySection.ts +0 -14
- package/front_end/panels/recorder/components/StepEditor.ts +2 -40
- package/front_end/panels/recorder/recorderController.css +4 -4
- package/front_end/panels/security/CookieControlsView.ts +2 -2
- package/front_end/panels/security/CookieReportView.ts +21 -21
- package/front_end/panels/security/cookieControlsView.css +1 -1
- package/front_end/panels/security/cookieReportView.css +1 -1
- package/front_end/panels/settings/AISettingsTab.ts +13 -15
- package/front_end/panels/settings/components/SyncSection.ts +4 -3
- package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +4 -12
- package/front_end/panels/settings/settings-meta.ts +1 -1
- package/front_end/panels/sources/BreakpointEditDialog.ts +4 -3
- package/front_end/panels/sources/CallStackSidebarPane.ts +4 -1
- package/front_end/panels/sources/FilteredUISourceCodeListProvider.ts +1 -1
- package/front_end/panels/sources/NavigatorView.ts +4 -4
- package/front_end/panels/sources/SourcesPanel.ts +7 -4
- package/front_end/panels/sources/components/HeadersView.ts +2 -2
- package/front_end/panels/timeline/CompatibilityTracksAppender.ts +3 -2
- package/front_end/panels/timeline/ThreadAppender.ts +2 -1
- package/front_end/panels/timeline/TimelineController.ts +4 -3
- package/front_end/panels/timeline/TimelinePanel.ts +7 -4
- package/front_end/panels/timeline/TimelineUIUtils.ts +2 -2
- package/front_end/panels/timeline/components/ExportTraceOptions.ts +4 -4
- package/front_end/panels/timeline/components/FieldSettingsDialog.ts +13 -6
- package/front_end/panels/timeline/components/LiveMetricsView.ts +13 -9
- package/front_end/panels/timeline/components/exportTraceOptions.css +1 -1
- package/front_end/panels/timeline/components/fieldSettingsDialog.css +1 -1
- package/front_end/panels/timeline/components/insights/BaseInsightComponent.ts +2 -19
- package/front_end/panels/timeline/components/insights/InsightRenderer.ts +3 -4
- package/front_end/panels/timeline/components/insights/baseInsightComponent.css +0 -5
- package/front_end/panels/timeline/components/liveMetricsView.css +1 -1
- package/front_end/panels/whats_new/ReleaseNoteView.ts +4 -3
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/ui/components/buttons/button.css +4 -0
- package/front_end/ui/components/markdown_view/CodeBlock.ts +3 -6
- package/front_end/ui/components/markdown_view/MarkdownLink.ts +3 -4
- package/front_end/ui/components/panel_feedback/PanelFeedback.ts +3 -4
- package/front_end/ui/components/panel_feedback/PreviewToggle.ts +10 -7
- package/front_end/ui/components/panel_feedback/panelFeedback.css +2 -2
- package/front_end/ui/components/panel_feedback/previewToggle.css +2 -2
- package/front_end/ui/components/text_editor/AiCodeGenerationParser.ts +27 -8
- package/front_end/ui/components/text_editor/AiCodeGenerationProvider.ts +36 -6
- package/front_end/ui/kit/link/Link.ts +1 -14
- package/front_end/ui/legacy/ActionRegistration.ts +1 -1
- package/front_end/ui/legacy/ContextMenu.ts +2 -2
- package/front_end/ui/legacy/EmptyWidget.ts +3 -3
- package/front_end/ui/legacy/LinkContextMenuProvider.ts +42 -0
- package/front_end/ui/legacy/ViewRegistration.ts +1 -1
- package/front_end/ui/legacy/XLink.ts +0 -27
- package/front_end/ui/legacy/components/color_picker/ContrastDetails.ts +1 -1
- package/front_end/ui/legacy/components/color_picker/ContrastOverlay.ts +5 -4
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +2 -2
- package/front_end/ui/legacy/components/perf_ui/perf_ui-meta.ts +1 -1
- package/front_end/ui/legacy/inspectorCommon.css +2 -1
- package/front_end/ui/legacy/legacy.ts +3 -1
- package/front_end/ui/visual_logging/KnownContextValues.ts +4 -1
- package/front_end/ui/visual_logging/LoggingDriver.ts +3 -0
- package/package.json +1 -1
- package/front_end/models/ai_assistance/ArtifactsManager.ts +0 -67
- package/front_end/panels/ai_assistance/components/ArtifactsViewer.ts +0 -183
- package/front_end/panels/ai_assistance/components/CollapsibleAssistanceContentWidget.ts +0 -89
- package/front_end/panels/ai_assistance/components/PerformanceAgentFlameChart.ts +0 -133
- package/front_end/panels/ai_assistance/components/artifactsViewer.css +0 -15
- package/front_end/panels/ai_assistance/components/collapsibleAssistanceContentWidget.css +0 -32
|
@@ -534,8 +534,9 @@ export class OverlayModel extends SDKModel<EventTypes> implements ProtocolProxyA
|
|
|
534
534
|
gridHighlightConfig: {},
|
|
535
535
|
flexContainerHighlightConfig: {},
|
|
536
536
|
flexItemHighlightConfig: {},
|
|
537
|
-
contrastAlgorithm: Root.Runtime.experiments.isEnabled(
|
|
538
|
-
|
|
537
|
+
contrastAlgorithm: Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.APCA) ?
|
|
538
|
+
Protocol.Overlay.ContrastAlgorithm.Apca :
|
|
539
|
+
Protocol.Overlay.ContrastAlgorithm.Aa,
|
|
539
540
|
};
|
|
540
541
|
|
|
541
542
|
if (mode === 'all' || mode === 'content') {
|
|
@@ -578,7 +578,7 @@ export class SourceMap {
|
|
|
578
578
|
lineNumber, columnNumber, sourceIndex, sourceURL, sourceLineNumber, sourceColumnNumber, names[nameIndex]));
|
|
579
579
|
}
|
|
580
580
|
|
|
581
|
-
if (Root.Runtime.experiments.isEnabled(Root.
|
|
581
|
+
if (Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.USE_SOURCE_MAP_SCOPES)) {
|
|
582
582
|
if (!this.#scopesInfo) {
|
|
583
583
|
this.#scopesInfo = new SourceMapScopesInfo(this, {scopes: [], ranges: []});
|
|
584
584
|
}
|
|
@@ -435,13 +435,7 @@
|
|
|
435
435
|
LighthouseModeRun: 'DevTools.LighthouseModeRun',
|
|
436
436
|
LighthouseCategoryUsed: 'DevTools.LighthouseCategoryUsed',
|
|
437
437
|
PanelShown: 'DevTools.PanelShown',
|
|
438
|
-
RecordingAssertion: 'DevTools.RecordingAssertion',
|
|
439
|
-
RecordingCodeToggled: 'DevTools.RecordingCodeToggled',
|
|
440
|
-
RecordingCopiedToClipboard: 'DevTools.RecordingCopiedToClipboard',
|
|
441
|
-
RecordingEdited: 'DevTools.RecordingEdited',
|
|
442
|
-
RecordingExported: 'DevTools.RecordingExported',
|
|
443
438
|
RecordingReplayFinished: 'DevTools.RecordingReplayFinished',
|
|
444
|
-
RecordingReplaySpeed: 'DevTools.RecordingReplaySpeed',
|
|
445
439
|
RecordingReplayStarted: 'DevTools.RecordingReplayStarted',
|
|
446
440
|
RecordingToggled: 'DevTools.RecordingToggled',
|
|
447
441
|
SourcesPanelFileDebugged: 'DevTools.SourcesPanelFileDebugged',
|
|
@@ -329,67 +329,83 @@ export class MainImpl {
|
|
|
329
329
|
}
|
|
330
330
|
|
|
331
331
|
#initializeExperiments(): void {
|
|
332
|
-
Root.Runtime.experiments.register('capture-node-creation-stacks', 'Capture node creation stacks');
|
|
333
|
-
Root.Runtime.experiments.register('live-heap-profile', 'Live heap profile');
|
|
334
332
|
Root.Runtime.experiments.register(
|
|
335
|
-
|
|
333
|
+
Root.ExperimentNames.ExperimentName.CAPTURE_NODE_CREATION_STACKS, 'Capture node creation stacks');
|
|
334
|
+
Root.Runtime.experiments.register(Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE, 'Live heap profile');
|
|
335
|
+
Root.Runtime.experiments.register(
|
|
336
|
+
Root.ExperimentNames.ExperimentName.PROTOCOL_MONITOR, 'Protocol Monitor',
|
|
336
337
|
'https://developer.chrome.com/blog/new-in-devtools-92/#protocol-monitor');
|
|
337
|
-
Root.Runtime.experiments.register('sampling-heap-profiler-timeline', 'Sampling heap profiler timeline');
|
|
338
338
|
Root.Runtime.experiments.register(
|
|
339
|
-
|
|
339
|
+
Root.ExperimentNames.ExperimentName.SAMPLING_HEAP_PROFILER_TIMELINE, 'Sampling heap profiler timeline');
|
|
340
|
+
Root.Runtime.experiments.register(
|
|
341
|
+
Root.ExperimentNames.ExperimentName.SHOW_OPTION_TO_EXPOSE_INTERNALS_IN_HEAP_SNAPSHOT,
|
|
342
|
+
'Show option to expose internals in heap snapshots');
|
|
340
343
|
|
|
341
344
|
// Timeline
|
|
342
|
-
Root.Runtime.experiments.register('timeline-invalidation-tracking', 'Performance panel: invalidation tracking');
|
|
343
|
-
Root.Runtime.experiments.register('timeline-show-all-events', 'Performance panel: show all events');
|
|
344
|
-
Root.Runtime.experiments.register('timeline-v8-runtime-call-stats', 'Performance panel: V8 runtime call stats');
|
|
345
345
|
Root.Runtime.experiments.register(
|
|
346
|
-
Root.
|
|
346
|
+
Root.ExperimentNames.ExperimentName.TIMELINE_INVALIDATION_TRACKING, 'Performance panel: invalidation tracking');
|
|
347
|
+
Root.Runtime.experiments.register(
|
|
348
|
+
Root.ExperimentNames.ExperimentName.TIMELINE_SHOW_ALL_EVENTS, 'Performance panel: show all events');
|
|
349
|
+
Root.Runtime.experiments.register(
|
|
350
|
+
Root.ExperimentNames.ExperimentName.TIMELINE_V8_RUNTIME_CALL_STATS, 'Performance panel: V8 runtime call stats');
|
|
351
|
+
Root.Runtime.experiments.register(
|
|
352
|
+
Root.ExperimentNames.ExperimentName.TIMELINE_DEBUG_MODE,
|
|
353
|
+
'Performance panel: debug mode (trace event details, etc)');
|
|
347
354
|
|
|
348
355
|
// Debugging
|
|
349
|
-
Root.Runtime.experiments.register(
|
|
350
|
-
|
|
356
|
+
Root.Runtime.experiments.register(
|
|
357
|
+
Root.ExperimentNames.ExperimentName.INSTRUMENTATION_BREAKPOINTS, 'Instrumentation breakpoints');
|
|
358
|
+
Root.Runtime.experiments.register(
|
|
359
|
+
Root.ExperimentNames.ExperimentName.USE_SOURCE_MAP_SCOPES, 'Use scope information from source maps');
|
|
351
360
|
|
|
352
361
|
// Advanced Perceptual Contrast Algorithm.
|
|
353
362
|
Root.Runtime.experiments.register(
|
|
354
|
-
|
|
363
|
+
Root.ExperimentNames.ExperimentName.APCA,
|
|
364
|
+
'Advanced Perceptual Contrast Algorithm (APCA) replacing previous contrast ratio and AA/AAA guidelines',
|
|
355
365
|
'https://developer.chrome.com/blog/new-in-devtools-89/#apca');
|
|
356
366
|
|
|
357
367
|
// Full Accessibility Tree
|
|
358
368
|
Root.Runtime.experiments.register(
|
|
359
|
-
|
|
369
|
+
Root.ExperimentNames.ExperimentName.FULL_ACCESSIBILITY_TREE,
|
|
370
|
+
'Full accessibility tree view in the Elements panel',
|
|
360
371
|
'https://developer.chrome.com/blog/new-in-devtools-90/#accessibility-tree',
|
|
361
372
|
'https://g.co/devtools/a11y-tree-feedback');
|
|
362
373
|
|
|
363
374
|
// Font Editor
|
|
364
375
|
Root.Runtime.experiments.register(
|
|
365
|
-
|
|
376
|
+
Root.ExperimentNames.ExperimentName.FONT_EDITOR, 'New font editor in the Styles tab',
|
|
366
377
|
'https://developer.chrome.com/blog/new-in-devtools-89/#font');
|
|
367
378
|
|
|
368
379
|
// Contrast issues reported via the Issues panel.
|
|
369
380
|
Root.Runtime.experiments.register(
|
|
370
|
-
|
|
381
|
+
Root.ExperimentNames.ExperimentName.CONTRAST_ISSUES, 'Automatic contrast issue reporting via the Issues panel',
|
|
371
382
|
'https://developer.chrome.com/blog/new-in-devtools-90/#low-contrast');
|
|
372
383
|
|
|
373
384
|
// New cookie features.
|
|
374
|
-
Root.Runtime.experiments.register(
|
|
385
|
+
Root.Runtime.experiments.register(
|
|
386
|
+
Root.ExperimentNames.ExperimentName.EXPERIMENTAL_COOKIE_FEATURES, 'Experimental cookie features');
|
|
375
387
|
|
|
376
388
|
// Change grouping of sources panel to use Authored/Deployed trees
|
|
377
389
|
Root.Runtime.experiments.register(
|
|
378
|
-
Root.
|
|
379
|
-
'
|
|
390
|
+
Root.ExperimentNames.ExperimentName.AUTHORED_DEPLOYED_GROUPING,
|
|
391
|
+
'Group sources into authored and deployed trees', 'https://goo.gle/authored-deployed',
|
|
392
|
+
'https://goo.gle/authored-deployed-feedback');
|
|
380
393
|
|
|
381
394
|
// Hide third party code (as determined by ignore lists or source maps)
|
|
382
395
|
Root.Runtime.experiments.register(
|
|
383
|
-
Root.
|
|
396
|
+
Root.ExperimentNames.ExperimentName.JUST_MY_CODE, 'Hide ignore-listed code in Sources tree view');
|
|
384
397
|
|
|
385
398
|
Root.Runtime.experiments.register(
|
|
386
|
-
Root.
|
|
399
|
+
Root.ExperimentNames.ExperimentName.TIMELINE_SHOW_POST_MESSAGE_EVENTS,
|
|
387
400
|
'Performance panel: show postMessage dispatch and handling flows',
|
|
388
401
|
);
|
|
389
402
|
|
|
390
403
|
Root.Runtime.experiments.enableExperimentsByDefault([
|
|
391
|
-
Root.
|
|
392
|
-
|
|
404
|
+
Root.ExperimentNames.ExperimentName.FULL_ACCESSIBILITY_TREE,
|
|
405
|
+
Root.ExperimentNames.ExperimentName.USE_SOURCE_MAP_SCOPES,
|
|
406
|
+
...(Root.Runtime.Runtime.queryParam('isChromeForTesting') ?
|
|
407
|
+
[Root.ExperimentNames.ExperimentName.PROTOCOL_MONITOR] :
|
|
408
|
+
[]),
|
|
393
409
|
]);
|
|
394
410
|
|
|
395
411
|
Root.Runtime.experiments.cleanUpStaleExperiments();
|
|
@@ -402,7 +418,7 @@ export class MainImpl {
|
|
|
402
418
|
if (Host.InspectorFrontendHost.isUnderTest()) {
|
|
403
419
|
const testParam = Root.Runtime.Runtime.queryParam('test');
|
|
404
420
|
if (testParam?.includes('live-line-level-heap-profile.js')) {
|
|
405
|
-
Root.Runtime.experiments.enableForTest(
|
|
421
|
+
Root.Runtime.experiments.enableForTest(Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE);
|
|
406
422
|
}
|
|
407
423
|
}
|
|
408
424
|
|
|
@@ -565,6 +581,10 @@ export class MainImpl {
|
|
|
565
581
|
AiAssistanceModel.ConversationHandler.ConversationHandlerEvents.EXTERNAL_CONVERSATION_STARTED,
|
|
566
582
|
event => void VisualLogging.logFunctionCall(`start-conversation-${event.data}`, 'external'));
|
|
567
583
|
|
|
584
|
+
if (Root.Runtime.hostConfig.devToolsGeminiRebranding?.enabled) {
|
|
585
|
+
await PanelCommon.GeminiRebrandPromoDialog.maybeShow();
|
|
586
|
+
}
|
|
587
|
+
|
|
568
588
|
MainImpl.timeEnd('Main._createAppUI');
|
|
569
589
|
|
|
570
590
|
const appProvider = Common.AppProvider.getRegisteredAppProviders()[0];
|
|
@@ -672,7 +692,7 @@ export class MainImpl {
|
|
|
672
692
|
const runnable = await lateInitializationLoader();
|
|
673
693
|
return await runnable.run();
|
|
674
694
|
});
|
|
675
|
-
if (Root.Runtime.experiments.isEnabled(
|
|
695
|
+
if (Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.LIVE_HEAP_PROFILE)) {
|
|
676
696
|
const PerfUI = await import('../../ui/legacy/components/perf_ui/perf_ui.js');
|
|
677
697
|
const setting = 'memory-live-heap-profile';
|
|
678
698
|
if (Common.Settings.Settings.instance().moduleSetting(setting).get()) {
|
|
@@ -730,14 +730,13 @@ export const generatedProperties = [
|
|
|
730
730
|
"text-emphasis-color",
|
|
731
731
|
"text-emphasis-position",
|
|
732
732
|
"text-emphasis-style",
|
|
733
|
-
"text-
|
|
733
|
+
"text-fit",
|
|
734
734
|
"text-indent",
|
|
735
735
|
"text-justify",
|
|
736
736
|
"text-orientation",
|
|
737
737
|
"text-overflow",
|
|
738
738
|
"text-rendering",
|
|
739
739
|
"text-shadow",
|
|
740
|
-
"text-shrink",
|
|
741
740
|
"text-size-adjust",
|
|
742
741
|
"text-spacing-trim",
|
|
743
742
|
"text-transform",
|
|
@@ -1794,8 +1793,7 @@ export const generatedProperties = [
|
|
|
1794
1793
|
"keywords": [
|
|
1795
1794
|
"all",
|
|
1796
1795
|
"around",
|
|
1797
|
-
"between"
|
|
1798
|
-
"none"
|
|
1796
|
+
"between"
|
|
1799
1797
|
],
|
|
1800
1798
|
"name": "column-rule-visibility-items"
|
|
1801
1799
|
},
|
|
@@ -3826,8 +3824,7 @@ export const generatedProperties = [
|
|
|
3826
3824
|
"keywords": [
|
|
3827
3825
|
"all",
|
|
3828
3826
|
"around",
|
|
3829
|
-
"between"
|
|
3830
|
-
"none"
|
|
3827
|
+
"between"
|
|
3831
3828
|
],
|
|
3832
3829
|
"name": "row-rule-visibility-items"
|
|
3833
3830
|
},
|
|
@@ -4440,7 +4437,7 @@ export const generatedProperties = [
|
|
|
4440
4437
|
"name": "text-emphasis-style"
|
|
4441
4438
|
},
|
|
4442
4439
|
{
|
|
4443
|
-
"name": "text-
|
|
4440
|
+
"name": "text-fit"
|
|
4444
4441
|
},
|
|
4445
4442
|
{
|
|
4446
4443
|
"inherited": true,
|
|
@@ -4489,9 +4486,6 @@ export const generatedProperties = [
|
|
|
4489
4486
|
],
|
|
4490
4487
|
"name": "text-shadow"
|
|
4491
4488
|
},
|
|
4492
|
-
{
|
|
4493
|
-
"name": "text-shrink"
|
|
4494
|
-
},
|
|
4495
4489
|
{
|
|
4496
4490
|
"inherited": true,
|
|
4497
4491
|
"keywords": [
|
|
@@ -5525,8 +5519,7 @@ export const generatedPropertyValues = {
|
|
|
5525
5519
|
"values": [
|
|
5526
5520
|
"all",
|
|
5527
5521
|
"around",
|
|
5528
|
-
"between"
|
|
5529
|
-
"none"
|
|
5522
|
+
"between"
|
|
5530
5523
|
]
|
|
5531
5524
|
},
|
|
5532
5525
|
"column-rule-width": {
|
|
@@ -6649,8 +6642,7 @@ export const generatedPropertyValues = {
|
|
|
6649
6642
|
"values": [
|
|
6650
6643
|
"all",
|
|
6651
6644
|
"around",
|
|
6652
|
-
"between"
|
|
6653
|
-
"none"
|
|
6645
|
+
"between"
|
|
6654
6646
|
]
|
|
6655
6647
|
},
|
|
6656
6648
|
"row-rule-width": {
|
|
@@ -10,10 +10,8 @@ import * as Root from '../../../core/root/root.js';
|
|
|
10
10
|
import * as SDK from '../../../core/sdk/sdk.js';
|
|
11
11
|
import * as Tracing from '../../../services/tracing/tracing.js';
|
|
12
12
|
import * as Annotations from '../../annotations/annotations.js';
|
|
13
|
-
import * as Logs from '../../logs/logs.js';
|
|
14
13
|
import * as SourceMapScopes from '../../source_map_scopes/source_map_scopes.js';
|
|
15
14
|
import * as Trace from '../../trace/trace.js';
|
|
16
|
-
import {ArtifactsManager} from '../ArtifactsManager.js';
|
|
17
15
|
import {
|
|
18
16
|
PerformanceInsightFormatter,
|
|
19
17
|
} from '../data_formatters/PerformanceInsightFormatter.js';
|
|
@@ -69,77 +67,6 @@ const greenDevAdditionalAnnotationsGuidelines = `
|
|
|
69
67
|
- The annotationMessage should be descriptive and relevant to why the element or network request is being highlighted.
|
|
70
68
|
`;
|
|
71
69
|
|
|
72
|
-
const getGreenDevAdditionalWidgetGuidelines = (): string => {
|
|
73
|
-
// GreenDev is experimenting with multiple ways to display widget:
|
|
74
|
-
// if widgetsFromFunctionCalls is true, then we use function calls to add widgets
|
|
75
|
-
// otherwise we use ai-insight tags
|
|
76
|
-
const widgetsFromFunctionCalls = true;
|
|
77
|
-
|
|
78
|
-
if (widgetsFromFunctionCalls) {
|
|
79
|
-
return `
|
|
80
|
-
- CRITICAL: You have access to a function for adding rich, interactive widgets to your response: \`addWidget\`.
|
|
81
|
-
You MUST use this function whenever you refer to a corresponding entity.
|
|
82
|
-
|
|
83
|
-
- **\`addWidget({widget: {type: 'insight', insightType: '...'}})\`**:
|
|
84
|
-
- **When to use**: Call this function every time you mention a specific performance insight (e.g., LCP, INP, CLS culprits).
|
|
85
|
-
- **Purpose**: It embeds an interactive widget that provides a detailed breakdown and visualization of the insight.
|
|
86
|
-
- **Example**: If you are explaining the causes of a poor LCP score, you MUST also call \`addWidget({widget: {type: 'insight', insightType: 'LCPBreakdown'}})\`.
|
|
87
|
-
|
|
88
|
-
- **\`addWidget({widget: {type: 'network-request', eventKey: '...'}})\`**:
|
|
89
|
-
- **When to use**: Call this function whenever you discuss a specific network request.
|
|
90
|
-
- **Purpose**: It adds a widget displaying the full details of the network request, such as its timing, headers, and priority.
|
|
91
|
-
- **Critical**: The eventKey should be the trace event key (only the number, no letters prefix or -) of that script's network request.
|
|
92
|
-
- **Example**: If you identify a render-blocking script, you MUST also call \`addWidget({widget: {type: 'network-request', eventKey: '...'}})\`.
|
|
93
|
-
|
|
94
|
-
- **\`addWidget({widget: {type: 'flamechart', start: ..., end: ...}})\`**:
|
|
95
|
-
- **When to use**: Call this function to highlight a specific time range within the trace, especially when discussing long tasks, specific events, or periods of high activity.
|
|
96
|
-
- **Purpose**: It embeds a focused flame chart visualization for the given time range (in microseconds).
|
|
97
|
-
- **Example**: If you find a long task that is blocking the main thread, you MUST also call \`addWidget({widget: {type: 'flamechart', start: 123456, end: 789012}})\`.
|
|
98
|
-
|
|
99
|
-
- **General Rules**:
|
|
100
|
-
- You MUST call this function as soon as you identify the entity you are discussing.
|
|
101
|
-
- Do NOT add more than one widget for the same insight, network request, or time range to avoid redundancy.
|
|
102
|
-
- If you have already shown a widget for any specific insight, network request, or time range, do not show it again.
|
|
103
|
-
`;
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
return `
|
|
107
|
-
- **Visualizing Insights**: When discussing the breakdown of specific metrics or a performance problem,
|
|
108
|
-
you must render the appropriate Insight Overview component. Use these tags on a new line within your response:
|
|
109
|
-
- For LCP breakdown: <ai-insight value="LCPBreakdown">
|
|
110
|
-
- For INP breakdown: <ai-insight value="INPBreakdown">
|
|
111
|
-
- For CLS culprits: <ai-insight value="CLSCulprits">
|
|
112
|
-
- For third parties: <ai-insight value="ThirdParties">
|
|
113
|
-
- For document latency: <ai-insight value="DocumentLatency">
|
|
114
|
-
- For DOM size: <ai-insight value="DOMSize">
|
|
115
|
-
- For duplicate JavaScript: <ai-insight value="DuplicatedJavaScript">
|
|
116
|
-
- For font display: <ai-insight value="FontDisplay">
|
|
117
|
-
- For forced reflow: <ai-insight value="ForcedReflow">
|
|
118
|
-
- For image delivery: <ai-insight value="ImageDelivery">
|
|
119
|
-
- For LCP discovery: <ai-insight value="LCPDiscovery">
|
|
120
|
-
- For legacy JavaScript: <ai-insight value="LegacyJavaScript">
|
|
121
|
-
- For network dependency tree: <ai-insight value="NetworkDependencyTree">
|
|
122
|
-
- For render blocking: <ai-insight value="RenderBlocking">
|
|
123
|
-
- For slow CSS selector: <ai-insight value="SlowCSSSelector">
|
|
124
|
-
- For viewport: <ai-insight value="Viewport">
|
|
125
|
-
- For modern HTTP: <ai-insight value="ModernHTTP">
|
|
126
|
-
- For cache: <ai-insight value="Cache">
|
|
127
|
-
- Do not place the <ai-insight> tag inside markdown code blocks (backticks). Output the tag directly as raw text.
|
|
128
|
-
- **Visualizing Network Request Details**: When discussing a specific network request, represent its details in a structured widget for improved readability and focus.
|
|
129
|
-
- Use this tag on a new line within your response, replacing \`EVENT_KEY\` (only the number, no letters prefix or -) with the actual trace event key:
|
|
130
|
-
- For network event details: <network-request-widget value="EVENT_KEY">
|
|
131
|
-
- **Visualizing Flamechart**: When discussing an interesting part of the trace, represent its details in a structured widget for improved readability and focus.
|
|
132
|
-
- Use this tag on a new line within your response, replacing "MIN_MICROSECONDS" and "MAX_MICROSECONDS" with the actual start and end times in microseconds:
|
|
133
|
-
- For a flame chart of a specific time range: <flame-chart-widget start="MIN_MICROSECONDS" end="MAX_MICROSECONDS">
|
|
134
|
-
- CRITICAL: MIN_MICROSECONDS and MAX_MICROSECONDS must be within the flamechart bounds and in microseconds.
|
|
135
|
-
- When you mention a specific performance event like LCP, INP, or a long task, you MUST also include a flamechart widget focused on the exact time range of that event.
|
|
136
|
-
- This provides essential visual context to your explanation.
|
|
137
|
-
- CRITICAL: Avoid Redundancy - When using insight or network request widgets, do not repeat details in the text response.
|
|
138
|
-
- For example, for LCP, the phases like Time to First Byte will be part of the insight widget, so you must not state them in the text. This applies to other insights and network request timings.
|
|
139
|
-
- Do not display any of the same widgets more than once. For example, if you have already displayed a network request widget for a specific event, do not display it again in the same response.
|
|
140
|
-
`;
|
|
141
|
-
};
|
|
142
|
-
|
|
143
70
|
/**
|
|
144
71
|
* Preamble clocks in at ~1341 tokens.
|
|
145
72
|
* The prose is around 4.5 chars per token.
|
|
@@ -148,7 +75,6 @@ you must render the appropriate Insight Overview component. Use these tags on a
|
|
|
148
75
|
* Check token length in https://aistudio.google.com/
|
|
149
76
|
*/
|
|
150
77
|
const buildPreamble = (): string => {
|
|
151
|
-
const greenDevEnabled = Boolean(Root.Runtime.hostConfig.devToolsGreenDevUi?.enabled);
|
|
152
78
|
const annotationsEnabled = Annotations.AnnotationRepository.annotationsEnabled();
|
|
153
79
|
return `You are an assistant, expert in web performance and highly skilled with Chrome DevTools.
|
|
154
80
|
|
|
@@ -203,7 +129,6 @@ Note: if the user asks a specific question about the trace (such as "What is my
|
|
|
203
129
|
- Be direct and to the point. Avoid unnecessary introductory phrases or filler content. Focus on delivering actionable advice efficiently.
|
|
204
130
|
|
|
205
131
|
${annotationsEnabled ? greenDevAdditionalAnnotationsGuidelines : ''}
|
|
206
|
-
${greenDevEnabled ? getGreenDevAdditionalWidgetGuidelines() : ''}
|
|
207
132
|
|
|
208
133
|
## Strict Constraints
|
|
209
134
|
|
|
@@ -1248,111 +1173,6 @@ export class PerformanceAgent extends AiAgent<AgentFocus> {
|
|
|
1248
1173
|
},
|
|
1249
1174
|
});
|
|
1250
1175
|
}
|
|
1251
|
-
|
|
1252
|
-
if (Root.Runtime.hostConfig.devToolsGreenDevUi?.enabled) {
|
|
1253
|
-
this.declareFunction<
|
|
1254
|
-
{
|
|
1255
|
-
type: 'insight' | 'network-request' | 'flamechart',
|
|
1256
|
-
insightType?: Trace.Insights.Types.InsightKeys,
|
|
1257
|
-
eventKey?: number,
|
|
1258
|
-
start?: number,
|
|
1259
|
-
end?: number,
|
|
1260
|
-
},
|
|
1261
|
-
object|{error: string}>('addWidget', {
|
|
1262
|
-
description:
|
|
1263
|
-
'Adds an insight widget to the response. When mentioning an insight, call this function to also display an appropriate widget. Use this as much as possible to provide a better user experience.',
|
|
1264
|
-
parameters: {
|
|
1265
|
-
type: Host.AidaClient.ParametersTypes.OBJECT,
|
|
1266
|
-
description: '',
|
|
1267
|
-
nullable: false,
|
|
1268
|
-
properties: {
|
|
1269
|
-
type: {
|
|
1270
|
-
type: Host.AidaClient.ParametersTypes.STRING,
|
|
1271
|
-
description: 'The type of the widget to add. Possible values: insight, network-request, flamechart',
|
|
1272
|
-
nullable: false,
|
|
1273
|
-
},
|
|
1274
|
-
insightType: {
|
|
1275
|
-
type: Host.AidaClient.ParametersTypes.STRING,
|
|
1276
|
-
description: 'The type of the insight widget. Include for insight widgets.',
|
|
1277
|
-
nullable: true,
|
|
1278
|
-
},
|
|
1279
|
-
eventKey: {
|
|
1280
|
-
type: Host.AidaClient.ParametersTypes.STRING,
|
|
1281
|
-
description: 'The event key for the network request widget. Include for network request widgets.',
|
|
1282
|
-
nullable: true,
|
|
1283
|
-
},
|
|
1284
|
-
start: {
|
|
1285
|
-
type: Host.AidaClient.ParametersTypes.INTEGER,
|
|
1286
|
-
description: 'The start time for the flame chart widget. Include for flame chart widgets.',
|
|
1287
|
-
nullable: true,
|
|
1288
|
-
},
|
|
1289
|
-
end: {
|
|
1290
|
-
type: Host.AidaClient.ParametersTypes.INTEGER,
|
|
1291
|
-
description: 'The end time for the flame chart widget. Include for flame chart widgets.',
|
|
1292
|
-
nullable: true,
|
|
1293
|
-
},
|
|
1294
|
-
},
|
|
1295
|
-
required: ['type']
|
|
1296
|
-
},
|
|
1297
|
-
handler: async params => {
|
|
1298
|
-
switch (params.type) {
|
|
1299
|
-
case 'insight':
|
|
1300
|
-
if (!params.insightType) {
|
|
1301
|
-
return {error: 'Missing insightType for insight widget'};
|
|
1302
|
-
}
|
|
1303
|
-
ArtifactsManager.instance().addArtifact({type: 'insight', insightType: params.insightType});
|
|
1304
|
-
return {result: {success: true}};
|
|
1305
|
-
case 'network-request': {
|
|
1306
|
-
if (!params.eventKey) {
|
|
1307
|
-
return {error: 'Missing eventKey for network-request widget'};
|
|
1308
|
-
}
|
|
1309
|
-
const rawTraceEvent =
|
|
1310
|
-
Trace.Helpers.SyntheticEvents.SyntheticEventsManager.getActiveManager().getRawTraceEvents().at(
|
|
1311
|
-
Number(params.eventKey));
|
|
1312
|
-
// Get the trace event object if it is available.
|
|
1313
|
-
// If the trace is uploaded, we need to use the synthetic event.
|
|
1314
|
-
if (rawTraceEvent && Trace.Types.Events.isSyntheticNetworkRequest(rawTraceEvent)) {
|
|
1315
|
-
const rawTraceEventId = rawTraceEvent?.args?.data?.requestId;
|
|
1316
|
-
const rawTraceEventUrl = rawTraceEvent?.args?.data?.url;
|
|
1317
|
-
const networkRequest = rawTraceEvent ? Logs.NetworkLog.NetworkLog.instance()
|
|
1318
|
-
.requestsForId(rawTraceEventId)
|
|
1319
|
-
.find(r => r.url() === rawTraceEventUrl) :
|
|
1320
|
-
null;
|
|
1321
|
-
if (networkRequest) {
|
|
1322
|
-
ArtifactsManager.instance().addArtifact({type: 'network-request', request: networkRequest});
|
|
1323
|
-
return {result: {success: true}};
|
|
1324
|
-
}
|
|
1325
|
-
}
|
|
1326
|
-
|
|
1327
|
-
const syntheticRequest = Trace.Helpers.SyntheticEvents.SyntheticEventsManager.getActiveManager()
|
|
1328
|
-
.syntheticEventForRawEventIndex(Number(params.eventKey));
|
|
1329
|
-
|
|
1330
|
-
if (syntheticRequest && Trace.Types.Events.isSyntheticNetworkRequest(syntheticRequest)) {
|
|
1331
|
-
ArtifactsManager.instance().addArtifact({
|
|
1332
|
-
type: 'network-request',
|
|
1333
|
-
request: syntheticRequest,
|
|
1334
|
-
});
|
|
1335
|
-
return {result: {success: true}};
|
|
1336
|
-
}
|
|
1337
|
-
|
|
1338
|
-
return {result: {error: 'Could not find network request'}};
|
|
1339
|
-
}
|
|
1340
|
-
case 'flamechart':
|
|
1341
|
-
if (params.start === undefined || params.end === undefined) {
|
|
1342
|
-
return {error: 'Missing start or end for flamechart widget'};
|
|
1343
|
-
}
|
|
1344
|
-
ArtifactsManager.instance().addArtifact({
|
|
1345
|
-
type: 'flamechart',
|
|
1346
|
-
start: Trace.Types.Timing.Micro(params.start),
|
|
1347
|
-
end: Trace.Types.Timing.Micro(params.end),
|
|
1348
|
-
});
|
|
1349
|
-
return {result: {success: true}};
|
|
1350
|
-
default:
|
|
1351
|
-
return {error: 'Invalid widget type'};
|
|
1352
|
-
}
|
|
1353
|
-
},
|
|
1354
|
-
});
|
|
1355
|
-
}
|
|
1356
1176
|
}
|
|
1357
1177
|
|
|
1358
1178
|
async addElementAnnotation(elementId: string, annotationMessage: string):
|
|
@@ -13,7 +13,6 @@ import * as StylingAgent from './agents/StylingAgent.js';
|
|
|
13
13
|
import * as AiConversation from './AiConversation.js';
|
|
14
14
|
import * as AiHistoryStorage from './AiHistoryStorage.js';
|
|
15
15
|
import * as AiUtils from './AiUtils.js';
|
|
16
|
-
import * as ArtifactsManager from './ArtifactsManager.js';
|
|
17
16
|
import * as BuiltInAi from './BuiltInAi.js';
|
|
18
17
|
import * as ChangeManager from './ChangeManager.js';
|
|
19
18
|
import * as ConversationHandler from './ConversationHandler.js';
|
|
@@ -39,7 +38,6 @@ export {
|
|
|
39
38
|
AiHistoryStorage,
|
|
40
39
|
AIQueries,
|
|
41
40
|
AiUtils,
|
|
42
|
-
ArtifactsManager,
|
|
43
41
|
BuiltInAi,
|
|
44
42
|
ChangeManager,
|
|
45
43
|
ConversationHandler,
|
|
@@ -91,7 +91,7 @@ export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper<EventT
|
|
|
91
91
|
}
|
|
92
92
|
|
|
93
93
|
modelAdded(debuggerModel: SDK.DebuggerModel.DebuggerModel): void {
|
|
94
|
-
if (Root.Runtime.experiments.isEnabled(Root.
|
|
94
|
+
if (Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.INSTRUMENTATION_BREAKPOINTS)) {
|
|
95
95
|
debuggerModel.setSynchronizeBreakpointsCallback(this.restoreBreakpointsForScript.bind(this));
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -128,7 +128,7 @@ export class BreakpointManager extends Common.ObjectWrapper.ObjectWrapper<EventT
|
|
|
128
128
|
// This method explicitly awaits the source map (if necessary) and the uiSourceCodes
|
|
129
129
|
// required to set all breakpoints that are related to this script.
|
|
130
130
|
async restoreBreakpointsForScript(script: SDK.Script.Script): Promise<void> {
|
|
131
|
-
if (!Root.Runtime.experiments.isEnabled(Root.
|
|
131
|
+
if (!Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.INSTRUMENTATION_BREAKPOINTS)) {
|
|
132
132
|
return;
|
|
133
133
|
}
|
|
134
134
|
if (!script.sourceURL) {
|
|
@@ -1006,7 +1006,7 @@ export class ModelBreakpoint {
|
|
|
1006
1006
|
};
|
|
1007
1007
|
}));
|
|
1008
1008
|
newState = positions.slice(0); // Create a copy
|
|
1009
|
-
} else if (!Root.Runtime.experiments.isEnabled(Root.
|
|
1009
|
+
} else if (!Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.INSTRUMENTATION_BREAKPOINTS)) {
|
|
1010
1010
|
// Use this fallback if we do not have instrumentation breakpoints enabled yet. This currently makes
|
|
1011
1011
|
// sure that v8 knows about the breakpoint and is able to restore it whenever the script is parsed.
|
|
1012
1012
|
const lastResolvedState = this.#breakpoint.getLastResolvedState();
|
|
@@ -45,7 +45,7 @@ export class ContrastCheckTrigger {
|
|
|
45
45
|
}
|
|
46
46
|
|
|
47
47
|
#checkContrast(resourceTreeModel: SDK.ResourceTreeModel.ResourceTreeModel): void {
|
|
48
|
-
if (!Root.Runtime.experiments.isEnabled(
|
|
48
|
+
if (!Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.CONTRAST_ISSUES)) {
|
|
49
49
|
return;
|
|
50
50
|
}
|
|
51
51
|
void resourceTreeModel.target().auditsAgent().invoke_checkContrast({});
|
|
@@ -60,7 +60,7 @@ export class ContrastCheckTrigger {
|
|
|
60
60
|
|
|
61
61
|
async #frameAdded(event: Common.EventTarget.EventTargetEvent<SDK.ResourceTreeModel.ResourceTreeFrame>):
|
|
62
62
|
Promise<void> {
|
|
63
|
-
if (!Root.Runtime.experiments.isEnabled(
|
|
63
|
+
if (!Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.CONTRAST_ISSUES)) {
|
|
64
64
|
return;
|
|
65
65
|
}
|
|
66
66
|
const frame = event.data;
|
|
@@ -6594,6 +6594,14 @@ export const NativeFunctions = [
|
|
|
6594
6594
|
name: "setHTML",
|
|
6595
6595
|
signatures: [["html","?options"]]
|
|
6596
6596
|
},
|
|
6597
|
+
{
|
|
6598
|
+
name: "streamAppendHTMLUnsafe",
|
|
6599
|
+
signatures: [["?options"]]
|
|
6600
|
+
},
|
|
6601
|
+
{
|
|
6602
|
+
name: "streamHTMLUnsafe",
|
|
6603
|
+
signatures: [["?options"]]
|
|
6604
|
+
},
|
|
6597
6605
|
{
|
|
6598
6606
|
name: "scrollIntoViewIfNeeded",
|
|
6599
6607
|
signatures: [["?centerIfNeeded"]]
|
|
@@ -371,7 +371,7 @@ export const resolveScopeChain =
|
|
|
371
371
|
return scopeChain;
|
|
372
372
|
}
|
|
373
373
|
|
|
374
|
-
scopeChain = Root.Runtime.experiments.isEnabled(Root.
|
|
374
|
+
scopeChain = Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.USE_SOURCE_MAP_SCOPES) ?
|
|
375
375
|
callFrame.script.sourceMap()?.resolveScopeChain(callFrame) :
|
|
376
376
|
null;
|
|
377
377
|
if (scopeChain) {
|
|
@@ -19,11 +19,15 @@ export class EventsSerializer {
|
|
|
19
19
|
return `${Types.File.EventKeyType.LEGACY_TIMELINE_FRAME}-${event.index}`;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
+
if (Types.Events.isJSSample(event)) {
|
|
23
|
+
return null;
|
|
24
|
+
}
|
|
25
|
+
|
|
22
26
|
const rawEvents = Helpers.SyntheticEvents.SyntheticEventsManager.getActiveManager().getRawTraceEvents();
|
|
23
27
|
const isSynthetic = Types.Events.isSyntheticBased(event);
|
|
24
28
|
const index = rawEvents.indexOf(isSynthetic ? event.rawSourceEvent : event);
|
|
25
29
|
if (index === -1) {
|
|
26
|
-
|
|
30
|
+
return null;
|
|
27
31
|
}
|
|
28
32
|
|
|
29
33
|
const key: Types.File.SyntheticEventKey|Types.File.RawEventKey = Types.Events.isSyntheticBased(event) ?
|
|
@@ -10,10 +10,6 @@ import type * as Insights from './insights/insights.js';
|
|
|
10
10
|
import {TraceParseProgressEvent, TraceProcessor} from './Processor.js';
|
|
11
11
|
import * as Types from './types/types.js';
|
|
12
12
|
|
|
13
|
-
// Note: this model is implemented in a way that can support multiple trace
|
|
14
|
-
// processors. Currently there is only one implemented, but you will see
|
|
15
|
-
// references to "processors" plural because it can easily be extended in the future.
|
|
16
|
-
|
|
17
13
|
/**
|
|
18
14
|
* The Model is responsible for parsing arrays of raw trace events and storing the
|
|
19
15
|
* resulting data. It can store multiple traces at once, and can return the data for
|
|
@@ -1832,6 +1832,10 @@ export interface SyntheticJSSample extends Event {
|
|
|
1832
1832
|
ph: Phase.INSTANT;
|
|
1833
1833
|
}
|
|
1834
1834
|
|
|
1835
|
+
export function isJSSample(event: Event): event is SyntheticJSSample {
|
|
1836
|
+
return event.name === Name.JS_SAMPLE;
|
|
1837
|
+
}
|
|
1838
|
+
|
|
1835
1839
|
export function isSyntheticInteraction(event: Event): event is SyntheticInteractionPair {
|
|
1836
1840
|
return Boolean(
|
|
1837
1841
|
'interactionId' in event && event.args?.data && 'beginEvent' in event.args.data && 'endEvent' in event.args.data);
|
|
@@ -77,7 +77,7 @@ export class AXBreadcrumbsPane extends AccessibilitySubPane {
|
|
|
77
77
|
const previewToggle = new Feedback.PreviewToggle.PreviewToggle();
|
|
78
78
|
previewToggle.setAttribute('jslog', `${VisualLogging.toggle('full-accessibility-tree')}`);
|
|
79
79
|
const name = i18nString(UIStrings.fullTreeExperimentName);
|
|
80
|
-
const experiment = Root.
|
|
80
|
+
const experiment = Root.ExperimentNames.ExperimentName.FULL_ACCESSIBILITY_TREE;
|
|
81
81
|
const onChangeCallback: (checked: boolean) => void = checked => {
|
|
82
82
|
Host.userMetrics.experimentChanged(experiment, checked);
|
|
83
83
|
UI.InspectorView.InspectorView.instance().displayReloadRequiredWarning(i18nString(UIStrings.reloadRequired));
|
|
@@ -95,7 +95,7 @@ export class AccessibilitySidebarView extends UI.Widget.VBox {
|
|
|
95
95
|
if (!accessibilityModel) {
|
|
96
96
|
return;
|
|
97
97
|
}
|
|
98
|
-
if (!Root.Runtime.experiments.isEnabled(
|
|
98
|
+
if (!Root.Runtime.experiments.isEnabled(Root.ExperimentNames.ExperimentName.FULL_ACCESSIBILITY_TREE)) {
|
|
99
99
|
accessibilityModel.clear();
|
|
100
100
|
}
|
|
101
101
|
await accessibilityModel.requestPartialAXTree(node);
|