chrome-devtools-frontend 1.0.1362775 → 1.0.1367881
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/.eslintrc.js +1 -0
- package/.stylelintrc.json +2 -1
- package/config/gni/devtools_grd_files.gni +14 -2
- package/config/gni/devtools_image_files.gni +2 -1
- package/docs/contributing/issues.md +15 -0
- package/extensions/cxx_debugging/src/ExtensionOptions.ts +0 -1
- package/extensions/cxx_debugging/third_party/llvm/README.chromium +1 -1
- package/front_end/.eslintrc.js +0 -5
- package/front_end/Images/src/button-magic.svg +3 -0
- package/front_end/Images/src/performance-panel-delete-annotation.svg +32 -0
- package/front_end/Images/src/performance-panel-diagram.svg +19 -14
- package/front_end/Images/src/performance-panel-entry-label.svg +9 -16
- package/front_end/Images/src/performance-panel-time-range.svg +2 -8
- package/front_end/core/common/AppProvider.ts +1 -1
- package/front_end/core/common/Object.ts +2 -7
- package/front_end/core/common/SettingRegistration.ts +1 -1
- package/front_end/core/common/Settings.ts +1 -1
- package/front_end/core/host/AidaClient.ts +7 -1
- package/front_end/core/host/InspectorFrontendHost.ts +1 -1
- package/front_end/core/host/ResourceLoader.ts +1 -1
- package/front_end/core/host/UserMetrics.ts +14 -2
- package/front_end/core/i18n/time-utilities.ts +7 -1
- package/front_end/core/platform/ArrayUtilities.ts +1 -0
- package/front_end/core/platform/DevToolsPath.ts +1 -1
- package/front_end/core/platform/Timing.ts +1 -1
- package/front_end/core/platform/UIString.ts +1 -1
- package/front_end/core/platform/UserVisibleError.ts +1 -1
- package/front_end/core/root/Runtime.ts +11 -2
- package/front_end/core/sdk/AccessibilityModel.ts +3 -4
- package/front_end/core/sdk/CPUProfilerModel.ts +3 -4
- package/front_end/core/sdk/CSSContainerQuery.ts +3 -3
- package/front_end/core/sdk/CSSLayer.ts +2 -2
- package/front_end/core/sdk/CSSMatchedStyles.test.ts +1 -0
- package/front_end/core/sdk/CSSMatchedStyles.ts +10 -2
- package/front_end/core/sdk/CSSMedia.ts +2 -2
- package/front_end/core/sdk/CSSMetadata.ts +21 -0
- package/front_end/core/sdk/CSSModel.ts +1 -0
- package/front_end/core/sdk/CSSProperty.ts +2 -2
- package/front_end/core/sdk/CSSQuery.ts +2 -2
- package/front_end/core/sdk/CSSRule.ts +2 -2
- package/front_end/core/sdk/CSSScope.ts +2 -2
- package/front_end/core/sdk/CSSStyleDeclaration.ts +3 -3
- package/front_end/core/sdk/CSSStyleSheetHeader.ts +4 -4
- package/front_end/core/sdk/CSSSupports.ts +2 -2
- package/front_end/core/sdk/CookieModel.ts +1 -1
- package/front_end/core/sdk/DOMDebuggerModel.ts +1 -1
- package/front_end/core/sdk/DebuggerModel.ts +9 -3
- package/front_end/core/sdk/EnhancedTracesParser.test.ts +1 -5
- package/front_end/core/sdk/EnhancedTracesParser.ts +2 -6
- package/front_end/core/sdk/EventBreakpointsModel.ts +1 -2
- package/front_end/core/sdk/FrameAssociated.ts +1 -1
- package/front_end/core/sdk/FrameManager.ts +9 -7
- package/front_end/core/sdk/HeapProfilerModel.ts +3 -4
- package/front_end/core/sdk/IsolateManager.ts +2 -3
- package/front_end/core/sdk/LayerTreeBase.ts +2 -2
- package/front_end/core/sdk/NetworkManager.ts +1 -1
- package/front_end/core/sdk/OverlayModel.ts +2 -2
- package/front_end/core/sdk/OverlayPersistentHighlighter.ts +1 -1
- package/front_end/core/sdk/PageLoad.ts +1 -1
- package/front_end/core/sdk/PageResourceLoader.ts +1 -1
- package/front_end/core/sdk/RemoteObject.ts +3 -3
- package/front_end/core/sdk/Resource.ts +2 -2
- package/front_end/core/sdk/ResourceTreeModel.ts +1 -1
- package/front_end/core/sdk/SDKModel.ts +1 -1
- package/front_end/core/sdk/Script.ts +5 -5
- package/front_end/core/sdk/ServiceWorkerCacheModel.ts +5 -7
- package/front_end/core/sdk/SourceMap.ts +1 -1
- package/front_end/core/sdk/SourceMapManager.ts +1 -1
- package/front_end/core/sdk/SourceMapScopeChainEntry.ts +2 -2
- package/front_end/core/sdk/SourceMapScopesInfo.ts +2 -2
- package/front_end/core/sdk/Target.ts +3 -2
- package/front_end/core/sdk/TargetManager.ts +4 -1
- package/front_end/core/sdk/WebAuthnModel.ts +20 -0
- package/front_end/core/sdk/sdk-meta.ts +7 -0
- package/front_end/devtools_compatibility.js +3 -3
- package/front_end/entrypoints/formatter_worker/CSSFormatter.ts +1 -1
- package/front_end/entrypoints/formatter_worker/HTMLFormatter.ts +1 -1
- package/front_end/entrypoints/formatter_worker/IdentityFormatter.ts +1 -1
- package/front_end/entrypoints/formatter_worker/JSONFormatter.ts +1 -1
- package/front_end/entrypoints/formatter_worker/JavaScriptFormatter.ts +1 -1
- package/front_end/entrypoints/heap_snapshot_worker/AllocationProfile.ts +1 -1
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +12 -12
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotLoader.ts +1 -1
- package/front_end/entrypoints/main/MainImpl.ts +11 -1
- package/front_end/generated/InspectorBackendCommands.js +5 -3
- package/front_end/generated/SupportedCSSProperties.js +20 -14
- package/front_end/generated/protocol-mapping.d.ts +10 -0
- package/front_end/generated/protocol-proxy-api.d.ts +12 -0
- package/front_end/generated/protocol.ts +32 -1
- package/front_end/legacy_test_runner/sdk_test_runner/sdk_test_runner.js +4 -2
- package/front_end/models/bindings/CSSWorkspaceBinding.ts +2 -2
- package/front_end/models/bindings/CompilerScriptMapping.ts +1 -2
- package/front_end/models/bindings/DebuggerLanguagePlugins.test.ts +1 -1
- package/front_end/models/bindings/DebuggerLanguagePlugins.ts +2 -2
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +1 -1
- package/front_end/models/bindings/DefaultScriptMapping.ts +1 -1
- package/front_end/models/bindings/IgnoreListManager.test.ts +49 -12
- package/front_end/models/bindings/IgnoreListManager.ts +79 -5
- package/front_end/models/bindings/ResourceMapping.ts +1 -1
- package/front_end/models/bindings/StylesSourceMapping.ts +11 -6
- package/front_end/models/breakpoints/BreakpointManager.test.ts +1 -1
- package/front_end/models/extensions/ExtensionPanel.ts +1 -1
- package/front_end/models/extensions/ExtensionServer.test.ts +1 -1
- package/front_end/models/extensions/ExtensionServer.ts +1 -1
- package/front_end/models/extensions/ExtensionView.ts +1 -1
- package/front_end/models/extensions/LanguageExtensionEndpoint.ts +1 -1
- package/front_end/models/extensions/RecorderPluginManager.ts +1 -1
- package/front_end/models/har/Importer.ts +1 -1
- package/front_end/models/issues_manager/AttributionReportingIssue.ts +1 -1
- package/front_end/models/issues_manager/BounceTrackingIssue.ts +1 -2
- package/front_end/models/issues_manager/CookieDeprecationMetadataIssue.ts +1 -1
- package/front_end/models/issues_manager/CorsIssue.ts +1 -1
- package/front_end/models/issues_manager/HeavyAdIssue.ts +1 -1
- package/front_end/models/issues_manager/Issue.ts +1 -1
- package/front_end/models/issues_manager/IssueResolver.ts +2 -2
- package/front_end/models/issues_manager/IssuesManager.ts +1 -1
- package/front_end/models/issues_manager/LowTextContrastIssue.ts +1 -1
- package/front_end/models/issues_manager/MixedContentIssue.ts +1 -1
- package/front_end/models/issues_manager/PropertyRuleIssue.ts +1 -1
- package/front_end/models/issues_manager/QuirksModeIssue.ts +1 -1
- package/front_end/models/issues_manager/RelatedIssue.ts +1 -1
- package/front_end/models/issues_manager/SharedArrayBufferIssue.ts +3 -3
- package/front_end/models/issues_manager/SourceFrameIssuesManager.ts +1 -1
- package/front_end/models/issues_manager/StylesheetLoadingIssue.ts +1 -1
- package/front_end/models/javascript_metadata/NativeFunctions.js +69 -61
- package/front_end/models/live-metrics/LiveMetrics.ts +41 -34
- package/front_end/models/live-metrics/web-vitals-injected/spec/spec.ts +1 -1
- package/front_end/models/persistence/EditFileSystemView.ts +1 -1
- package/front_end/models/persistence/FileSystemWorkspaceBinding.ts +2 -3
- package/front_end/models/persistence/IsolatedFileSystemManager.ts +2 -3
- package/front_end/models/persistence/WorkspaceSettingsTab.ts +2 -2
- package/front_end/models/text_utils/ContentProvider.ts +3 -3
- package/front_end/models/text_utils/StaticContentProvider.ts +1 -5
- package/front_end/models/text_utils/TextUtils.ts +1 -1
- package/front_end/models/text_utils/WasmDisassembly.ts +1 -1
- package/front_end/models/timeline_model/TimelineProfileTree.test.ts +21 -21
- package/front_end/models/timeline_model/TimelineProfileTree.ts +1 -1
- package/front_end/models/trace/ModelImpl.test.ts +1 -1
- package/front_end/models/trace/ModelImpl.ts +10 -27
- package/front_end/models/trace/Processor.test.ts +16 -15
- package/front_end/models/trace/Processor.ts +33 -9
- package/front_end/models/trace/extras/FilmStrip.ts +2 -2
- package/front_end/models/trace/handlers/LayoutShiftsHandler.test.ts +2 -2
- package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +10 -1
- package/front_end/models/trace/handlers/MetaHandler.ts +4 -0
- package/front_end/models/trace/handlers/PageLoadMetricsHandler.ts +1 -1
- package/front_end/models/trace/handlers/RendererHandler.test.ts +1 -1
- package/front_end/models/trace/handlers/SamplesHandler.test.ts +2 -2
- package/front_end/models/trace/handlers/ScreenshotsHandler.test.ts +5 -4
- package/front_end/models/trace/handlers/ScreenshotsHandler.ts +7 -5
- package/front_end/models/trace/handlers/Threads.ts +2 -2
- package/front_end/models/trace/handlers/WarningsHandler.ts +1 -1
- package/front_end/models/trace/helpers/Network.ts +20 -2
- package/front_end/models/trace/helpers/SyntheticEvents.test.ts +1 -1
- package/front_end/models/trace/helpers/Trace.test.ts +34 -3
- package/front_end/models/trace/helpers/Trace.ts +12 -0
- package/front_end/models/trace/helpers/TreeHelpers.test.ts +52 -0
- package/front_end/models/trace/helpers/TreeHelpers.ts +80 -1
- package/front_end/models/trace/insights/Common.ts +1 -1
- package/front_end/models/trace/insights/CumulativeLayoutShift.test.ts +24 -2
- package/front_end/models/trace/insights/CumulativeLayoutShift.ts +102 -27
- package/front_end/models/trace/insights/DocumentLatency.test.ts +22 -11
- package/front_end/models/trace/insights/DocumentLatency.ts +9 -6
- package/front_end/models/trace/insights/FontDisplay.ts +5 -1
- package/front_end/models/trace/insights/InteractionToNextPaint.ts +4 -3
- package/front_end/models/trace/insights/LargestContentfulPaint.test.ts +9 -1
- package/front_end/models/trace/insights/LargestContentfulPaint.ts +26 -6
- package/front_end/models/trace/insights/RenderBlocking.test.ts +10 -16
- package/front_end/models/trace/insights/RenderBlocking.ts +6 -4
- package/front_end/models/trace/insights/SlowCSSSelector.ts +3 -1
- package/front_end/models/trace/insights/ThirdPartyWeb.ts +15 -2
- package/front_end/models/trace/insights/Viewport.ts +1 -0
- package/front_end/models/trace/insights/types.ts +14 -11
- package/front_end/models/trace/lantern/graph/BaseNode.ts +2 -2
- package/front_end/models/trace/lantern/graph/PageDependencyGraph.ts +4 -3
- package/front_end/models/trace/lantern/simulation/TCPConnection.ts +1 -1
- package/front_end/models/trace/lantern/testing/MetricTestUtils.ts +1 -1
- package/front_end/models/trace/root-causes/LayoutShift.ts +3 -20
- package/front_end/models/trace/types/Extensions.ts +3 -7
- package/front_end/models/trace/types/File.ts +2 -8
- package/front_end/models/trace/types/TraceEvents.ts +10 -4
- package/front_end/models/workspace/UISourceCode.test.ts +3 -3
- package/front_end/models/workspace/WorkspaceImpl.ts +1 -1
- package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +1 -1
- package/front_end/panels/animation/AnimationGroupPreviewUI.ts +1 -1
- package/front_end/panels/animation/AnimationModel.ts +1 -1
- package/front_end/panels/animation/AnimationTimeline.ts +1 -1
- package/front_end/panels/animation/AnimationUI.ts +1 -1
- package/front_end/panels/application/ApplicationPanelSidebar.test.ts +90 -0
- package/front_end/panels/application/ApplicationPanelSidebar.ts +123 -20
- package/front_end/panels/application/ApplicationPanelTreeElement.ts +1 -1
- package/front_end/panels/application/BackForwardCacheTreeElement.ts +1 -1
- package/front_end/panels/application/BounceTrackingMitigationsTreeElement.ts +1 -1
- package/front_end/panels/application/DOMStorageItemsView.ts +4 -2
- package/front_end/panels/application/ExtensionStorageItemsView.test.ts +89 -0
- package/front_end/panels/application/ExtensionStorageItemsView.ts +219 -0
- package/front_end/panels/application/ExtensionStorageModel.test.ts +12 -0
- package/front_end/panels/application/ExtensionStorageModel.ts +56 -13
- package/front_end/panels/application/IndexedDBViews.ts +14 -19
- package/front_end/panels/application/InterestGroupTreeElement.ts +1 -1
- package/front_end/panels/application/PreloadingTreeElement.ts +1 -1
- package/front_end/panels/application/ReportingApiTreeElement.ts +1 -1
- package/front_end/panels/application/ResourcesPanel.ts +18 -1
- package/front_end/panels/application/ServiceWorkerCacheTreeElement.ts +1 -1
- package/front_end/panels/application/SharedStorageListTreeElement.ts +1 -1
- package/front_end/panels/application/SharedStorageTreeElement.ts +2 -2
- package/front_end/panels/application/StorageBucketsTreeElement.ts +1 -1
- package/front_end/panels/application/TrustTokensTreeElement.ts +1 -1
- package/front_end/panels/application/application.ts +2 -0
- package/front_end/panels/application/components/BackForwardCacheView.ts +76 -72
- package/front_end/panels/application/components/BounceTrackingMitigationsView.ts +32 -29
- package/front_end/panels/application/components/EndpointsGrid.ts +5 -4
- package/front_end/panels/application/components/FrameDetailsView.ts +110 -127
- package/front_end/panels/application/components/InterestGroupAccessGrid.ts +11 -11
- package/front_end/panels/application/components/OriginTrialTreeView.ts +36 -34
- package/front_end/panels/application/components/PermissionsPolicySection.ts +31 -33
- package/front_end/panels/application/components/ProtocolHandlersView.ts +15 -14
- package/front_end/panels/application/components/ReportsGrid.ts +11 -9
- package/front_end/panels/application/components/ServiceWorkerRouterView.ts +0 -1
- package/front_end/panels/application/components/SharedStorageAccessGrid.ts +11 -11
- package/front_end/panels/application/components/SharedStorageMetadataView.ts +16 -14
- package/front_end/panels/application/components/StackTrace.ts +18 -17
- package/front_end/panels/application/components/StorageMetadataView.ts +19 -18
- package/front_end/panels/application/components/TrustTokensView.ts +17 -16
- package/front_end/panels/application/preloading/PreloadingView.ts +14 -11
- package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +7 -6
- package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +42 -45
- package/front_end/panels/application/preloading/components/PreloadingDisabledInfobar.ts +13 -11
- package/front_end/panels/application/preloading/components/PreloadingGrid.ts +11 -9
- package/front_end/panels/application/preloading/components/PreloadingMismatchedHeadersGrid.ts +5 -4
- package/front_end/panels/application/preloading/components/PreloadingString.ts +2 -0
- package/front_end/panels/application/preloading/components/RuleSetDetailsView.ts +10 -8
- package/front_end/panels/application/preloading/components/RuleSetGrid.ts +20 -16
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +50 -57
- package/front_end/panels/application/resourcesSidebar.css +0 -3
- package/front_end/panels/autofill/AutofillView.ts +19 -14
- package/front_end/panels/console/ConsoleFilter.ts +1 -1
- package/front_end/panels/console/ConsoleSidebar.ts +1 -1
- package/front_end/panels/console/ConsoleViewMessage.ts +2 -2
- package/front_end/panels/console/consoleView.css +4 -3
- package/front_end/panels/coverage/CoverageDecorationManager.ts +1 -1
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +1 -1
- package/front_end/panels/css_overview/CSSOverviewController.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewModel.ts +2 -3
- package/front_end/panels/css_overview/CSSOverviewPanel.ts +5 -7
- package/front_end/panels/css_overview/components/CSSOverviewStartView.ts +12 -10
- package/front_end/panels/elements/AccessibilityTreeUtils.ts +9 -4
- package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +3 -3
- package/front_end/panels/elements/ComputedStyleWidget.ts +6 -4
- package/front_end/panels/elements/ElementsPanel.ts +7 -6
- package/front_end/panels/elements/ElementsTreeElement.ts +35 -0
- package/front_end/panels/elements/ElementsTreeOutline.ts +1 -1
- package/front_end/panels/elements/PropertyMatchers.test.ts +57 -0
- package/front_end/panels/elements/PropertyMatchers.ts +78 -1
- package/front_end/panels/elements/StyleEditorWidget.ts +2 -2
- package/front_end/panels/elements/StylePropertiesSection.test.ts +1 -0
- package/front_end/panels/elements/StylePropertyHighlighter.test.ts +1 -0
- package/front_end/panels/elements/StylePropertyHighlighter.ts +2 -2
- package/front_end/panels/elements/StylePropertyTreeElement.test.ts +36 -3
- package/front_end/panels/elements/StylePropertyTreeElement.ts +72 -26
- package/front_end/panels/elements/StylesSidebarPane.test.ts +2 -0
- package/front_end/panels/elements/TopLayerContainer.ts +1 -2
- package/front_end/panels/elements/components/AccessibilityTreeNode.ts +8 -7
- package/front_end/panels/elements/components/AdornerSettingsPane.ts +3 -4
- package/front_end/panels/elements/components/AnchorFunctionLinkSwatch.ts +8 -7
- 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/components/CSSQuery.ts +0 -1
- package/front_end/panels/elements/components/CSSVariableValueView.ts +1 -3
- package/front_end/panels/elements/components/ComputedStyleProperty.ts +0 -1
- package/front_end/panels/elements/components/ComputedStyleTrace.ts +0 -1
- package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +15 -11
- package/front_end/panels/elements/components/ElementsBreadcrumbsUtils.ts +1 -1
- package/front_end/panels/elements/components/ElementsTreeExpandButton.ts +6 -4
- package/front_end/panels/elements/components/LayoutPane.ts +8 -7
- package/front_end/panels/elements/components/QueryContainer.test.ts +2 -3
- package/front_end/panels/elements/components/QueryContainer.ts +10 -9
- package/front_end/panels/elements/components/StylePropertyEditor.ts +4 -4
- package/front_end/panels/elements/components/computedStyleProperty.css +2 -1
- package/front_end/panels/elements/components/cssPropertyDocsView.css +3 -2
- package/front_end/panels/elements/elementsTreeOutline.css +17 -0
- package/front_end/panels/elements/stylesSidebarPane.css +2 -2
- package/front_end/panels/emulation/DeviceModeWrapper.ts +1 -1
- package/front_end/panels/emulation/components/DeviceSizeInputElement.ts +3 -1
- package/front_end/panels/explain/components/ConsoleInsight.ts +47 -46
- package/front_end/panels/explain/components/consoleInsight.css +0 -9
- package/front_end/panels/freestyler/AiAgent.ts +8 -2
- package/front_end/panels/freestyler/DrJonesFileAgent.test.ts +201 -0
- package/front_end/panels/freestyler/DrJonesFileAgent.ts +196 -0
- package/front_end/panels/freestyler/DrJonesNetworkAgent.test.ts +1 -1
- package/front_end/panels/freestyler/DrJonesNetworkAgent.ts +34 -31
- package/front_end/panels/freestyler/DrJonesPerformanceAgent.test.ts +195 -0
- package/front_end/panels/freestyler/DrJonesPerformanceAgent.ts +193 -0
- package/front_end/panels/freestyler/FreestylerAgent.test.ts +177 -12
- package/front_end/panels/freestyler/FreestylerAgent.ts +83 -8
- package/front_end/panels/freestyler/FreestylerEvaluateAction.test.ts +21 -1
- package/front_end/panels/freestyler/FreestylerEvaluateAction.ts +3 -0
- package/front_end/panels/freestyler/FreestylerPanel.test.ts +16 -2
- package/front_end/panels/freestyler/FreestylerPanel.ts +126 -15
- package/front_end/panels/freestyler/components/FreestylerChatUi.test.ts +21 -2
- package/front_end/panels/freestyler/components/FreestylerChatUi.ts +294 -145
- package/front_end/panels/freestyler/components/ProvideFeedback.ts +16 -13
- package/front_end/panels/freestyler/components/freestylerChatUi.css +78 -26
- package/front_end/panels/freestyler/freestyler-meta.ts +64 -9
- package/front_end/panels/freestyler/freestyler.ts +2 -0
- package/front_end/panels/issues/AffectedResourcesView.ts +2 -2
- package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +5 -4
- package/front_end/panels/issues/CorsIssueDetailsView.ts +6 -6
- package/front_end/panels/issues/GenericIssueDetailsView.ts +3 -3
- package/front_end/panels/issues/IssueView.ts +2 -2
- package/front_end/panels/issues/components/ElementsPanelLink.ts +3 -1
- package/front_end/panels/issues/components/HideIssuesMenu.ts +6 -5
- package/front_end/panels/lighthouse/LighthouseController.ts +2 -2
- package/front_end/panels/lighthouse/LighthousePanel.ts +1 -1
- package/front_end/panels/lighthouse/LighthouseReportRenderer.ts +2 -6
- package/front_end/panels/lighthouse/LighthouseStartView.ts +1 -1
- package/front_end/panels/lighthouse/LighthouseStatusView.ts +1 -1
- package/front_end/panels/lighthouse/LighthouseTimespanView.ts +1 -1
- package/front_end/panels/linear_memory_inspector/LinearMemoryInspectorPane.ts +8 -2
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryHighlightChipList.ts +6 -6
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.test.ts +11 -0
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +26 -31
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryNavigator.ts +5 -5
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryValueInterpreter.ts +11 -14
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryViewer.ts +1 -3
- package/front_end/panels/linear_memory_inspector/components/ValueInterpreterDisplay.ts +5 -4
- package/front_end/panels/linear_memory_inspector/components/ValueInterpreterSettings.ts +0 -1
- package/front_end/panels/media/EventDisplayTable.ts +1 -1
- package/front_end/panels/media/EventTimelineView.ts +1 -1
- package/front_end/panels/media/PlayerDetailView.ts +3 -3
- package/front_end/panels/media/PlayerListView.ts +2 -2
- package/front_end/panels/mobile_throttling/ThrottlingManager.ts +23 -29
- package/front_end/panels/network/NetworkConfigView.ts +1 -2
- package/front_end/panels/network/NetworkDataGridNode.ts +4 -153
- package/front_end/panels/network/NetworkFrameGrouper.ts +1 -1
- package/front_end/panels/network/NetworkItemView.ts +1 -1
- package/front_end/panels/network/NetworkLogView.ts +1 -1
- package/front_end/panels/network/NetworkLogViewColumns.ts +4 -6
- package/front_end/panels/network/NetworkWaterfallColumn.ts +5 -8
- package/front_end/panels/network/RequestBinaryResponseView.test.ts +69 -0
- package/front_end/panels/network/RequestBinaryResponseView.ts +67 -0
- package/front_end/panels/network/RequestResponseView.test.ts +28 -1
- package/front_end/panels/network/RequestResponseView.ts +14 -7
- package/front_end/panels/network/components/EditableSpan.ts +0 -1
- package/front_end/panels/network/components/HeaderSectionRow.test.ts +1 -1
- package/front_end/panels/network/components/HeaderSectionRow.ts +22 -21
- package/front_end/panels/network/components/RequestHeaderSection.ts +7 -7
- package/front_end/panels/network/components/RequestHeadersView.ts +25 -26
- package/front_end/panels/network/components/RequestTrustTokensView.ts +32 -35
- package/front_end/panels/network/components/ResponseHeaderSection.ts +8 -10
- package/front_end/panels/network/components/WebBundleInfoView.ts +13 -11
- package/front_end/panels/network/network.ts +2 -0
- package/front_end/panels/network/networkConfigView.css +12 -5
- package/front_end/panels/network/networkLogView.css +4 -15
- package/front_end/panels/network/requestHTMLView.css +1 -0
- package/front_end/panels/profiler/BottomUpProfileDataGrid.ts +3 -3
- package/front_end/panels/profiler/HeapProfileView.ts +1 -1
- package/front_end/panels/profiler/HeapProfilerPanel.ts +2 -2
- package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +3 -3
- package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +3 -3
- package/front_end/panels/profiler/HeapSnapshotProxy.ts +1 -1
- package/front_end/panels/profiler/ProfileLauncherView.ts +3 -3
- package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +4 -2
- package/front_end/panels/protocol_monitor/components/JSONEditor.ts +22 -15
- package/front_end/panels/protocol_monitor/components/Toolbar.ts +4 -4
- package/front_end/panels/recorder/RecorderController.ts +39 -43
- package/front_end/panels/recorder/components/ControlButton.ts +1 -1
- package/front_end/panels/recorder/components/CreateRecordingView.ts +15 -15
- package/front_end/panels/recorder/components/ExtensionView.ts +9 -8
- package/front_end/panels/recorder/components/RecordingListView.ts +15 -13
- package/front_end/panels/recorder/components/RecordingView.ts +92 -84
- package/front_end/panels/recorder/components/ReplaySection.ts +6 -6
- package/front_end/panels/recorder/components/SelectButton.ts +21 -20
- package/front_end/panels/recorder/components/StartView.ts +14 -18
- package/front_end/panels/recorder/components/StepEditor.ts +3 -3
- package/front_end/panels/recorder/components/StepView.ts +20 -20
- package/front_end/panels/recorder/components/TimelineSection.ts +3 -2
- package/front_end/panels/recorder/converters/ExtensionConverter.ts +2 -2
- package/front_end/panels/recorder/converters/JSONConverter.ts +1 -1
- package/front_end/panels/recorder/converters/LighthouseConverter.ts +1 -1
- package/front_end/panels/recorder/converters/PuppeteerConverter.ts +1 -1
- package/front_end/panels/recorder/converters/PuppeteerReplayConverter.ts +1 -1
- package/front_end/panels/recorder/injected/RecordingClient.ts +7 -10
- package/front_end/panels/recorder/injected/SelectorComputer.ts +5 -5
- package/front_end/panels/recorder/injected/SelectorPicker.ts +2 -2
- package/front_end/panels/recorder/injected/Step.ts +1 -1
- package/front_end/panels/recorder/injected/injected.ts +1 -1
- package/front_end/panels/recorder/injected/selectors/ARIASelector.ts +1 -1
- package/front_end/panels/recorder/injected/selectors/PierceSelector.ts +6 -7
- package/front_end/panels/recorder/injected/selectors/TextSelector.ts +3 -5
- package/front_end/panels/recorder/injected/util.ts +1 -1
- package/front_end/panels/recorder/models/RecordingPlayer.ts +1 -1
- package/front_end/panels/recorder/models/RecordingSettings.ts +1 -4
- package/front_end/panels/recorder/models/RecordingStorage.ts +1 -1
- package/front_end/panels/recorder/models/SDKUtils.ts +3 -2
- package/front_end/panels/recorder/models/ScreenshotUtils.ts +1 -1
- package/front_end/panels/recorder/models/Section.ts +2 -2
- package/front_end/panels/search/SearchResultsPane.ts +1 -2
- package/front_end/panels/search/SearchView.ts +1 -1
- package/front_end/panels/security/OriginTreeElement.ts +1 -1
- package/front_end/panels/security/SecurityAndPrivacyPanelSidebar.ts +1 -1
- package/front_end/panels/security/SecurityPanelSidebarTreeElement.ts +1 -1
- package/front_end/panels/sensors/SensorsView.ts +16 -0
- package/front_end/panels/sensors/sensors.css +16 -0
- package/front_end/panels/settings/AISettingsTab.test.ts +41 -11
- package/front_end/panels/settings/AISettingsTab.ts +103 -58
- package/front_end/panels/settings/FrameworkIgnoreListSettingsTab.ts +9 -0
- package/front_end/panels/settings/SettingsScreen.ts +1 -1
- package/front_end/panels/settings/components/SyncSection.ts +18 -13
- package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +33 -30
- package/front_end/panels/settings/settings-meta.ts +2 -2
- package/front_end/panels/sources/DebuggerPlugin.ts +1 -1
- package/front_end/panels/sources/EditingLocationHistoryManager.ts +2 -2
- package/front_end/panels/sources/GoToLineQuickOpen.ts +1 -1
- package/front_end/panels/sources/InplaceFormatterEditorAction.ts +1 -1
- package/front_end/panels/sources/OutlineQuickOpen.ts +1 -1
- package/front_end/panels/sources/SourcesNavigator.test.ts +1 -0
- package/front_end/panels/sources/SourcesPanel.ts +7 -0
- package/front_end/panels/sources/TabbedEditorContainer.ts +1 -1
- package/front_end/panels/sources/UISourceCodeFrame.ts +1 -1
- package/front_end/panels/sources/components/BreakpointsView.ts +25 -26
- package/front_end/panels/sources/components/HeadersView.ts +17 -15
- package/front_end/panels/timeline/AnimationsTrackAppender.ts +18 -3
- package/front_end/panels/timeline/AnnotationHelpers.ts +1 -1
- package/front_end/panels/timeline/AppenderUtils.ts +1 -1
- package/front_end/panels/timeline/CompatibilityTracksAppender.ts +27 -10
- package/front_end/panels/timeline/CountersGraph.ts +1 -1
- package/front_end/panels/timeline/EntriesFilter.test.ts +68 -0
- package/front_end/panels/timeline/EntriesFilter.ts +13 -0
- package/front_end/panels/timeline/EventsTimelineTreeView.ts +1 -1
- package/front_end/panels/timeline/InteractionsTrackAppender.ts +10 -0
- package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +135 -1
- package/front_end/panels/timeline/ModificationsManager.test.ts +160 -0
- package/front_end/panels/timeline/ModificationsManager.ts +31 -0
- package/front_end/panels/timeline/TimelineDetailsView.test.ts +4 -2
- package/front_end/panels/timeline/TimelineDetailsView.ts +34 -12
- package/front_end/panels/timeline/TimelineEventOverview.ts +1 -0
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.test.ts +53 -0
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +50 -20
- package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.test.ts +57 -0
- package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +18 -0
- package/front_end/panels/timeline/TimelineFlameChartView.ts +90 -29
- package/front_end/panels/timeline/TimelineHistoryManager.ts +3 -1
- package/front_end/panels/timeline/TimelineLoader.ts +1 -1
- package/front_end/panels/timeline/TimelinePanel.ts +49 -37
- package/front_end/panels/timeline/TimelineSelectorStatsView.ts +16 -12
- package/front_end/panels/timeline/TimelineTreeView.test.ts +9 -9
- package/front_end/panels/timeline/TimelineTreeView.ts +1 -1
- package/front_end/panels/timeline/TimelineUIUtils.ts +116 -41
- package/front_end/panels/timeline/TimingsTrackAppender.ts +1 -1
- package/front_end/panels/timeline/components/BreadcrumbsUI.ts +2 -3
- package/front_end/panels/timeline/components/CPUThrottlingSelector.ts +8 -7
- package/front_end/panels/timeline/components/FieldSettingsDialog.ts +28 -27
- package/front_end/panels/timeline/components/InteractionBreakdown.ts +3 -2
- package/front_end/panels/timeline/components/LayoutShiftDetails.test.ts +13 -11
- package/front_end/panels/timeline/components/LayoutShiftDetails.ts +217 -87
- package/front_end/panels/timeline/components/LiveMetricsView.test.ts +194 -69
- package/front_end/panels/timeline/components/LiveMetricsView.ts +327 -141
- package/front_end/panels/timeline/components/MetricCard.test.ts +8 -8
- package/front_end/panels/timeline/components/MetricCard.ts +6 -4
- package/front_end/panels/timeline/components/MetricCompareStrings.ts +1 -1
- package/front_end/panels/timeline/components/NetworkRequestDetails.ts +16 -13
- package/front_end/panels/timeline/components/NetworkRequestTooltip.ts +12 -10
- package/front_end/panels/timeline/components/NetworkThrottlingSelector.test.ts +35 -2
- package/front_end/panels/timeline/components/NetworkThrottlingSelector.ts +30 -13
- package/front_end/panels/timeline/components/RelatedInsightChips.test.ts +74 -0
- package/front_end/panels/timeline/components/RelatedInsightChips.ts +92 -0
- package/front_end/panels/timeline/components/Sidebar.test.ts +74 -0
- package/front_end/panels/timeline/components/Sidebar.ts +32 -13
- package/front_end/panels/timeline/components/SidebarAnnotationsTab.test.ts +66 -0
- package/front_end/panels/timeline/components/SidebarAnnotationsTab.ts +108 -39
- package/front_end/panels/timeline/components/SidebarInsightsTab.test.ts +11 -1
- package/front_end/panels/timeline/components/SidebarInsightsTab.ts +70 -37
- package/front_end/panels/timeline/components/SidebarSingleInsightSet.test.ts +59 -1
- package/front_end/panels/timeline/components/SidebarSingleInsightSet.ts +90 -34
- package/front_end/panels/timeline/components/Utils.test.ts +65 -0
- package/front_end/panels/timeline/components/Utils.ts +117 -0
- package/front_end/panels/timeline/components/components.ts +2 -0
- package/front_end/panels/timeline/components/insights/CLSCulprits.ts +67 -53
- package/front_end/panels/timeline/components/insights/DocumentLatency.ts +98 -14
- package/front_end/panels/timeline/components/insights/EventRef.ts +92 -0
- package/front_end/panels/timeline/components/insights/FontDisplay.ts +24 -13
- package/front_end/panels/timeline/components/insights/Helpers.ts +48 -43
- package/front_end/panels/timeline/components/insights/InteractionToNextPaint.ts +20 -18
- package/front_end/panels/timeline/components/insights/LCPDiscovery.ts +93 -48
- package/front_end/panels/timeline/components/insights/LCPPhases.ts +28 -9
- package/front_end/panels/timeline/components/insights/NodeLink.ts +3 -1
- package/front_end/panels/timeline/components/insights/RenderBlocking.ts +33 -25
- package/front_end/panels/timeline/components/insights/SidebarInsight.ts +92 -15
- package/front_end/panels/timeline/components/insights/SlowCSSSelector.ts +26 -39
- package/front_end/panels/timeline/components/insights/Table.ts +12 -9
- package/front_end/panels/timeline/components/insights/ThirdParties.ts +20 -12
- package/front_end/panels/timeline/components/insights/Viewport.ts +23 -20
- package/front_end/panels/timeline/components/insights/insights.ts +2 -0
- package/front_end/panels/timeline/components/insights/sidebarInsight.css +54 -9
- package/front_end/panels/timeline/components/insights/table.css +9 -1
- package/front_end/panels/timeline/components/layoutShiftDetails.css +22 -20
- package/front_end/panels/timeline/components/liveMetricsView.css +46 -16
- package/front_end/panels/timeline/components/networkRequestDetails.css +2 -1
- package/front_end/panels/timeline/components/relatedInsightChips.css +45 -0
- package/front_end/panels/timeline/components/sidebarInsightsTab.css +24 -6
- package/front_end/panels/timeline/components/sidebarSingleInsightSet.css +18 -4
- package/front_end/panels/timeline/extensions/ExtensionUI.ts +4 -1
- package/front_end/panels/timeline/fixtures/traces/basic.json.gz +0 -0
- package/front_end/panels/timeline/fixtures/traces/many-redirects.json.gz +0 -0
- package/front_end/panels/timeline/fixtures/traces/missing-url.json.gz +0 -0
- package/front_end/panels/timeline/overlays/OverlaysImpl.test.ts +40 -51
- package/front_end/panels/timeline/overlays/OverlaysImpl.ts +87 -39
- package/front_end/panels/timeline/overlays/components/EntriesLinkOverlay.ts +13 -11
- package/front_end/panels/timeline/overlays/components/EntryLabelOverlay.ts +24 -32
- package/front_end/panels/timeline/overlays/components/TimeRangeOverlay.ts +23 -24
- package/front_end/panels/timeline/overlays/components/TimespanBreakdownOverlay.test.ts +42 -0
- package/front_end/panels/timeline/overlays/components/TimespanBreakdownOverlay.ts +25 -19
- package/front_end/panels/timeline/overlays/components/entryLabelOverlay.css +0 -14
- package/front_end/panels/timeline/overlays/components/timeRangeOverlay.css +16 -13
- package/front_end/panels/timeline/overlays/components/timespanBreakdownOverlay.css +59 -20
- package/front_end/panels/timeline/timelineFlameChartView.css +3 -2
- package/front_end/panels/timeline/timelineFlamechartPopover.css +19 -0
- package/front_end/panels/timeline/timelineHistoryManager.css +4 -0
- package/front_end/panels/timeline/timelinePanel.css +2 -10
- package/front_end/panels/timeline/track_appenders/LayoutShiftsTrackAppender.test.ts +7 -7
- package/front_end/panels/timeline/track_appenders/TimingsTrackAppender.test.ts +1 -1
- package/front_end/panels/timeline/utils/Helpers.test.ts +38 -0
- package/front_end/panels/timeline/utils/Helpers.ts +94 -0
- package/front_end/panels/timeline/utils/ImageCache.test.ts +106 -0
- package/front_end/panels/timeline/utils/ImageCache.ts +55 -0
- package/front_end/panels/timeline/utils/SourceMapsResolver.test.ts +13 -1
- package/front_end/panels/timeline/utils/SourceMapsResolver.ts +11 -2
- package/front_end/panels/timeline/utils/utils.ts +4 -0
- package/front_end/panels/utils/utils.ts +1 -1
- package/front_end/panels/web_audio/graph_visualizer/EdgeView.ts +1 -1
- package/front_end/panels/web_audio/graph_visualizer/GraphView.ts +3 -9
- package/front_end/panels/webauthn/WebauthnPane.test.ts +75 -4
- package/front_end/panels/webauthn/WebauthnPane.ts +24 -3
- package/front_end/testing/EnvironmentHelpers.ts +19 -4
- package/front_end/testing/ExtensionHelpers.ts +1 -1
- package/front_end/testing/LanguagePluginHelpers.ts +1 -1
- package/front_end/testing/MockConnection.ts +1 -1
- package/front_end/testing/MockIssuesManager.ts +1 -1
- package/front_end/testing/MockScopeChain.ts +1 -1
- package/front_end/testing/MutationHelpers.test.ts +6 -8
- package/front_end/testing/TraceHelpers.ts +3 -1
- package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/codemirror.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/java.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/java.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/sass.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/sass.js.map +1 -1
- package/front_end/third_party/codemirror.next/codemirror.next.d.ts +11 -3
- package/front_end/third_party/codemirror.next/package.json +5 -5
- package/front_end/third_party/i18n/localized-string-set.ts +1 -1
- package/front_end/third_party/puppeteer/README.chromium +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Browser.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/BrowserContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/BrowserContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts +9 -9
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js +84 -84
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ElementHandle.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Browser.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Navigation.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Navigation.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Realm.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Realm.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Request.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Request.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Session.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/Session.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/UserContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/UserContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/UserPrompt.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/bidi/core/UserPrompt.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Accessibility.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Accessibility.js +7 -4
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Accessibility.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ElementHandle.js +2 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/ExecutionContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Frame.d.ts +2 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Frame.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Frame.js +17 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/Frame.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/IsolatedWorld.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/cdp/IsolatedWorld.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/util.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/injected.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/injected.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/injected.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/injected.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/generated/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/PQuerySelector.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/PQuerySelector.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/injected/injected.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ScreenRecorder.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/ScreenRecorder.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/util/Mutex.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +2 -1
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +114 -97
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Browser.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/BrowserContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/BrowserContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts +9 -9
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js +82 -83
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ElementHandle.js +2 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Browser.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Navigation.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Navigation.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Realm.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Realm.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Request.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Request.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Session.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/Session.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/UserContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/UserContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/UserPrompt.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/bidi/core/UserPrompt.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Accessibility.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Accessibility.js +7 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Accessibility.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ElementHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ElementHandle.js +3 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ElementHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/ExecutionContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Frame.d.ts +2 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Frame.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Frame.js +17 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/Frame.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/IsolatedWorld.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/cdp/IsolatedWorld.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/util.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/injected.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/injected.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/injected.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/injected.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/generated/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/PQuerySelector.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/injected/PQuerySelector.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ScreenRecorder.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/ScreenRecorder.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/types.d.ts +2 -1
- package/front_end/third_party/puppeteer/package/package.json +2 -2
- package/front_end/third_party/puppeteer/package/src/api/Browser.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/api/BrowserContext.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/api/ElementHandle.ts +89 -89
- package/front_end/third_party/puppeteer/package/src/api/Page.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/ElementHandle.ts +6 -2
- package/front_end/third_party/puppeteer/package/src/bidi/core/Browser.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/BrowsingContext.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/Navigation.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/Realm.ts +2 -2
- package/front_end/third_party/puppeteer/package/src/bidi/core/Request.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/Session.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/UserContext.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/bidi/core/UserPrompt.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/cdp/Accessibility.ts +9 -5
- package/front_end/third_party/puppeteer/package/src/cdp/ElementHandle.ts +7 -3
- package/front_end/third_party/puppeteer/package/src/cdp/ExecutionContext.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/cdp/Frame.ts +22 -1
- package/front_end/third_party/puppeteer/package/src/cdp/IsolatedWorld.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/common/QueryHandler.ts +1 -3
- package/front_end/third_party/puppeteer/package/src/common/util.ts +2 -1
- package/front_end/third_party/puppeteer/package/src/generated/injected.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/generated/version.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/injected/PQuerySelector.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/node/ScreenRecorder.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/revisions.ts +2 -2
- package/front_end/third_party/puppeteer/puppeteer.ts +1 -1
- package/front_end/ui/components/buttons/Button.ts +18 -17
- package/front_end/ui/components/buttons/button.css +0 -4
- package/front_end/ui/components/cards/Card.test.ts +66 -0
- package/front_end/ui/components/cards/Card.ts +57 -0
- package/front_end/ui/components/cards/card.css +32 -0
- package/front_end/ui/components/cards/cards.ts +9 -0
- package/front_end/ui/components/chrome_link/ChromeLink.test.ts +5 -3
- package/front_end/ui/components/chrome_link/ChromeLink.ts +3 -1
- package/front_end/ui/components/data_grid/DataGrid.test.ts +3 -1
- package/front_end/ui/components/data_grid/DataGrid.ts +25 -23
- package/front_end/ui/components/data_grid/DataGridContextMenuUtils.ts +2 -2
- package/front_end/ui/components/data_grid/DataGridController.ts +9 -5
- package/front_end/ui/components/data_grid/DataGridEvents.ts +1 -1
- package/front_end/ui/components/data_grid/DataGridRenderers.ts +7 -4
- package/front_end/ui/components/dialogs/Dialog.ts +4 -2
- package/front_end/ui/components/dialogs/IconDialog.ts +9 -7
- package/front_end/ui/components/dialogs/ShortcutDialog.ts +10 -8
- package/front_end/ui/components/diff_view/DiffView.ts +9 -8
- package/front_end/ui/components/docs/create_breadcrumbs.ts +3 -1
- package/front_end/ui/components/docs/expandable_list/basic.ts +4 -2
- package/front_end/ui/components/docs/floating_button/basic.html +26 -0
- package/front_end/ui/components/docs/floating_button/basic.ts +20 -0
- package/front_end/ui/components/docs/freestyler/basic.ts +5 -0
- package/front_end/ui/components/docs/freestyler/empty_state.ts +5 -0
- package/front_end/ui/components/docs/icon_dialog/basic.ts +5 -3
- package/front_end/ui/components/docs/panel_introduction_steps/basic.ts +7 -4
- package/front_end/ui/components/docs/performance_panel/flamechart.html +4 -0
- package/front_end/ui/components/docs/performance_panel/flamechart.ts +45 -0
- package/front_end/ui/components/docs/recorder_select_button/basic.ts +21 -18
- package/front_end/ui/components/docs/report/basic.ts +19 -23
- package/front_end/ui/components/docs/theme_colors/basic.ts +4 -2
- package/front_end/ui/components/docs/tree_outline/custom-renderers.ts +4 -2
- package/front_end/ui/components/expandable_list/ExpandableList.test.ts +5 -3
- package/front_end/ui/components/expandable_list/ExpandableList.ts +6 -4
- package/front_end/ui/components/floating_button/FloatingButton.ts +51 -0
- package/front_end/ui/components/floating_button/floatingButton.css +63 -0
- package/front_end/ui/components/floating_button/floating_button.ts +7 -0
- package/front_end/ui/components/helpers/helpers.test.ts +18 -14
- package/front_end/ui/components/icon_button/Icon.ts +2 -2
- package/front_end/ui/components/icon_button/IconButton.ts +15 -10
- package/front_end/ui/components/issue_counter/IssueCounter.ts +5 -1
- package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +7 -4
- package/front_end/ui/components/legacy_wrapper/LegacyWrapper.ts +0 -1
- package/front_end/ui/components/linkifier/LinkifierImpl.ts +3 -1
- package/front_end/ui/components/markdown_view/CodeBlock.test.ts +7 -7
- package/front_end/ui/components/markdown_view/CodeBlock.ts +33 -41
- package/front_end/ui/components/markdown_view/MarkdownImage.ts +12 -9
- package/front_end/ui/components/markdown_view/MarkdownLink.ts +3 -1
- package/front_end/ui/components/markdown_view/MarkdownView.test.ts +51 -3
- package/front_end/ui/components/markdown_view/MarkdownView.ts +39 -22
- package/front_end/ui/components/markdown_view/codeBlock.css +6 -28
- package/front_end/ui/components/markdown_view/markdownLink.css +1 -1
- package/front_end/ui/components/markdown_view/markdownView.css +4 -0
- package/front_end/ui/components/menus/Menu.ts +7 -5
- package/front_end/ui/components/menus/SelectMenu.test.ts +3 -1
- package/front_end/ui/components/menus/SelectMenu.ts +17 -15
- package/front_end/ui/components/panel_feedback/FeedbackButton.ts +5 -3
- package/front_end/ui/components/panel_feedback/PanelFeedback.ts +8 -4
- package/front_end/ui/components/panel_feedback/PreviewToggle.ts +6 -4
- package/front_end/ui/components/panel_introduction_steps/PanelIntroductionSteps.ts +3 -1
- package/front_end/ui/components/report_view/ReportView.test.ts +5 -3
- package/front_end/ui/components/report_view/ReportView.ts +9 -7
- package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +8 -5
- package/front_end/ui/components/settings/SettingCheckbox.ts +14 -12
- package/front_end/ui/components/settings/SettingDeprecationWarning.ts +7 -4
- package/front_end/ui/components/spinners/Spinner.ts +3 -1
- package/front_end/ui/components/split_view/SplitView.ts +3 -1
- package/front_end/ui/components/srgb_overlay/SrgbOverlay.ts +3 -1
- package/front_end/ui/components/suggestion_input/SuggestionInput.ts +3 -2
- package/front_end/ui/components/survey_link/SurveyLink.ts +7 -3
- package/front_end/ui/components/switch/SwitchImpl.ts +3 -1
- package/front_end/ui/components/text_editor/TextEditorHistory.ts +2 -2
- package/front_end/ui/components/text_prompt/TextPrompt.ts +3 -1
- package/front_end/ui/components/tree_outline/TreeOutline.test.ts +8 -6
- package/front_end/ui/components/tree_outline/TreeOutline.ts +9 -8
- package/front_end/ui/components/two_states_counter/TwoStatesCounter.ts +5 -3
- package/front_end/ui/legacy/Context.ts +1 -1
- package/front_end/ui/legacy/Dialog.ts +2 -2
- package/front_end/ui/legacy/DockController.ts +2 -2
- package/front_end/ui/legacy/FilterBar.ts +1 -1
- package/front_end/ui/legacy/FilterSuggestionBuilder.ts +1 -1
- package/front_end/ui/legacy/GlassPane.ts +1 -1
- package/front_end/ui/legacy/Infobar.ts +1 -1
- package/front_end/ui/legacy/InspectorView.ts +5 -5
- package/front_end/ui/legacy/Panel.ts +1 -1
- package/front_end/ui/legacy/ShortcutRegistry.ts +1 -1
- package/front_end/ui/legacy/SplitWidget.test.ts +33 -1
- package/front_end/ui/legacy/SplitWidget.ts +62 -7
- package/front_end/ui/legacy/TabbedPane.ts +24 -0
- package/front_end/ui/legacy/Toolbar.test.ts +39 -0
- package/front_end/ui/legacy/Toolbar.ts +16 -17
- package/front_end/ui/legacy/UIUtils.ts +1 -1
- package/front_end/ui/legacy/View.ts +2 -2
- package/front_end/ui/legacy/ViewManager.ts +3 -2
- package/front_end/ui/legacy/ViewRegistration.ts +2 -2
- package/front_end/ui/legacy/Widget.ts +62 -14
- package/front_end/ui/legacy/XElement.ts +0 -1
- package/front_end/ui/legacy/XLink.test.ts +3 -1
- package/front_end/ui/legacy/XLink.ts +6 -4
- package/front_end/ui/legacy/checkboxTextLabel.css +4 -0
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +1 -1
- package/front_end/ui/legacy/components/data_grid/DataGridWithPreview.ts +21 -10
- package/front_end/ui/legacy/components/inline_editor/AnimationTimingUI.ts +1 -1
- package/front_end/ui/legacy/components/inline_editor/CSSAngle.ts +10 -7
- package/front_end/ui/legacy/components/inline_editor/ColorMixSwatch.ts +3 -1
- package/front_end/ui/legacy/components/inline_editor/ColorSwatch.ts +3 -1
- package/front_end/ui/legacy/components/inline_editor/LinkSwatch.ts +9 -9
- package/front_end/ui/legacy/components/inline_editor/Swatches.ts +5 -4
- package/front_end/ui/legacy/components/perf_ui/BrickBreaker.ts +2 -2
- package/front_end/ui/legacy/components/perf_ui/FilmStripView.test.ts +9 -9
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +49 -13
- package/front_end/ui/legacy/components/perf_ui/PieChart.ts +1 -0
- package/front_end/ui/legacy/components/perf_ui/TimelineOverviewCalculator.ts +1 -1
- package/front_end/ui/legacy/inspectorCommon.css +0 -1
- package/front_end/ui/legacy/themeColors.css +10 -0
- package/front_end/ui/legacy/toolbar.css +4 -0
- package/front_end/ui/legacy/treeoutline.css +0 -3
- package/front_end/ui/lit-html/static.test.ts +8 -8
- package/front_end/ui/visual_logging/Debugging.ts +1 -1
- package/front_end/ui/visual_logging/KnownContextValues.ts +32 -3
- package/front_end/ui/visual_logging/LoggingDriver.ts +1 -1
- package/front_end/ui/visual_logging/LoggingEvents.ts +28 -28
- package/front_end/ui/visual_logging/LoggingState.ts +1 -1
- package/front_end/ui/visual_logging/NonDomState.ts +2 -2
- package/front_end/ui/visual_logging/visual_logging.ts +3 -1
- package/inspector_overlay/css_grid_label_helpers.test.ts +103 -0
- package/inspector_overlay/css_grid_label_helpers.ts +63 -12
- package/inspector_overlay/highlight_common.ts +2 -2
- package/inspector_overlay/highlight_container_query.ts +1 -2
- package/inspector_overlay/highlight_flex_common.test.ts +1 -1
- package/inspector_overlay/highlight_flex_common.ts +2 -3
- package/inspector_overlay/highlight_grid_common.ts +10 -4
- package/inspector_overlay/highlight_isolated_element.ts +1 -1
- package/inspector_overlay/highlight_scroll_snap.ts +1 -2
- package/inspector_overlay/testing/InspectorOverlayHelpers.ts +1 -1
- package/inspector_overlay/tool_highlight.ts +4 -8
- package/package.json +4 -3
- package/scripts/devtools_paths.js +9 -2
- package/scripts/eslint_rules/lib/avoid_assert_equal.js +34 -7
- package/scripts/eslint_rules/lib/html_tagged_template.js +55 -0
- package/scripts/eslint_rules/lib/inline_type_imports.js +22 -23
- package/scripts/eslint_rules/tests/avoid_assert_equal_test.js +61 -2
- package/scripts/eslint_rules/tests/html_tagged_template_test.js +96 -0
- package/scripts/eslint_rules/tests/inline_type_imports_test.js +5 -25
- package/scripts/freestyler/eval/index.js +83 -47
- package/scripts/protocol_typescript/protocol_dts_generator.ts +1 -1
- package/scripts/stylelint_rules/lib/use_theme_colors.js +2 -1
- package/scripts/stylelint_rules/tests/use_theme_colors_test.js +16 -0
- package/front_end/Images/src/spark.svg +0 -3
- package/front_end/panels/timeline/components/insights/lcpDiscovery.css +0 -13
- package/scripts/eslint_rules/lib/ban_literal_devtools_component_tag_names.js +0 -40
- package/scripts/eslint_rules/lib/check_component_naming.js +0 -214
- package/scripts/eslint_rules/tests/ban_literal_devtools_component_tag_names_test.js +0 -38
- package/scripts/eslint_rules/tests/check_component_naming_test.js +0 -246
@@ -2,16 +2,20 @@
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
3
3
|
// found in the LICENSE file.
|
4
4
|
|
5
|
+
import '../../../ui/components/spinners/spinners.js';
|
6
|
+
import './ProvideFeedback.js';
|
7
|
+
|
5
8
|
import * as Common from '../../../core/common/common.js';
|
6
9
|
import * as Host from '../../../core/host/host.js';
|
7
10
|
import * as i18n from '../../../core/i18n/i18n.js';
|
8
11
|
import type * as Platform from '../../../core/platform/platform.js';
|
9
12
|
import type * as SDK from '../../../core/sdk/sdk.js';
|
13
|
+
import * as Trace from '../../../models/trace/trace.js';
|
14
|
+
import type * as Workspace from '../../../models/workspace/workspace.js';
|
10
15
|
import * as Marked from '../../../third_party/marked/marked.js';
|
11
16
|
import * as Buttons from '../../../ui/components/buttons/buttons.js';
|
12
|
-
import * as IconButton from '../../../ui/components/icon_button/icon_button.js';
|
17
|
+
import type * as IconButton from '../../../ui/components/icon_button/icon_button.js';
|
13
18
|
import * as MarkdownView from '../../../ui/components/markdown_view/markdown_view.js';
|
14
|
-
import * as Spinners from '../../../ui/components/spinners/spinners.js';
|
15
19
|
import * as UI from '../../../ui/legacy/legacy.js';
|
16
20
|
import * as LitHtml from '../../../ui/lit-html/lit-html.js';
|
17
21
|
import * as VisualLogging from '../../../ui/visual_logging/visual_logging.js';
|
@@ -19,7 +23,9 @@ import {PanelUtils} from '../../utils/utils.js';
|
|
19
23
|
import {type ContextDetail, ErrorType} from '../AiAgent.js';
|
20
24
|
|
21
25
|
import freestylerChatUiStyles from './freestylerChatUi.css.js';
|
22
|
-
import
|
26
|
+
import type {ProvideFeedbackProps} from './ProvideFeedback.js';
|
27
|
+
|
28
|
+
const {html, Directives: {ifDefined}} = LitHtml;
|
23
29
|
|
24
30
|
const UIStrings = {
|
25
31
|
/**
|
@@ -52,6 +58,10 @@ const UIStrings = {
|
|
52
58
|
*@example {AI assistance in Settings} PH1
|
53
59
|
*/
|
54
60
|
turnOnForStylesAndRequests: 'Turn on {PH1} to get help with styles and network requests',
|
61
|
+
/**
|
62
|
+
*@description The footer disclaimer that links to more information about the AI feature.
|
63
|
+
*/
|
64
|
+
learnAbout: 'Learn about AI in DevTools',
|
55
65
|
};
|
56
66
|
|
57
67
|
/*
|
@@ -68,6 +78,16 @@ const UIStringsNotTranslate = {
|
|
68
78
|
*/
|
69
79
|
inputDisclaimerForDrJonesNetworkAgent:
|
70
80
|
'Chat messages and the selected network request are sent to Google and may be seen by human reviewers to improve this feature. This is an experimental AI feature and won’t always get it right.',
|
81
|
+
/**
|
82
|
+
*@description Disclaimer text right after the chat input.
|
83
|
+
*/
|
84
|
+
inputDisclaimerForDrJonesFileAgent:
|
85
|
+
'Chat messages and the selected file are sent to Google and may be seen by human reviewers to improve this feature. This is an experimental AI feature and won\'t always get it right.',
|
86
|
+
/**
|
87
|
+
*@description Disclaimer text right after the chat input.
|
88
|
+
*/
|
89
|
+
inputDisclaimerForDrJonesPerformanceAgent:
|
90
|
+
'Chat messages and the selected call stack are sent to Google and may be seen by human reviewers to improve this feature. This is an experimental AI feature and won\'t always get it right.',
|
71
91
|
/**
|
72
92
|
*@description Placeholder text for the chat UI input.
|
73
93
|
*/
|
@@ -76,6 +96,14 @@ const UIStringsNotTranslate = {
|
|
76
96
|
*@description Placeholder text for the chat UI input.
|
77
97
|
*/
|
78
98
|
inputPlaceholderForDrJonesNetworkAgent: 'Ask a question about the selected network request',
|
99
|
+
/**
|
100
|
+
*@description Placeholder text for the chat UI input.
|
101
|
+
*/
|
102
|
+
inputPlaceholderForDrJonesFileAgent: 'Ask a question about the selected file',
|
103
|
+
/**
|
104
|
+
*@description Placeholder text for the chat UI input.
|
105
|
+
*/
|
106
|
+
inputPlaceholderForDrJonesPerformanceAgent: 'Ask a question about the selected stack trace',
|
79
107
|
/**
|
80
108
|
*@description Title for the send icon button.
|
81
109
|
*/
|
@@ -121,14 +149,6 @@ const UIStringsNotTranslate = {
|
|
121
149
|
* @description Button text that cancels code execution that may affect the page.
|
122
150
|
*/
|
123
151
|
negativeSideEffectConfirmation: 'Cancel',
|
124
|
-
/**
|
125
|
-
*@description Link text for redirecting to feedback form
|
126
|
-
*/
|
127
|
-
feedbackLink: 'Send feedback',
|
128
|
-
/**
|
129
|
-
*@description Button text for "Fix this issue" button
|
130
|
-
*/
|
131
|
-
fixThisIssue: 'Fix this issue',
|
132
152
|
/**
|
133
153
|
*@description The generic name of the AI agent (do not translate)
|
134
154
|
*/
|
@@ -158,42 +178,36 @@ const UIStringsNotTranslate = {
|
|
158
178
|
*/
|
159
179
|
dataReturned: 'Data returned',
|
160
180
|
/**
|
161
|
-
*@description
|
181
|
+
*@description Aria label for the check mark icon to be read by screen reader
|
162
182
|
*/
|
163
|
-
|
183
|
+
completed: 'Completed',
|
164
184
|
/**
|
165
|
-
|
185
|
+
*@description Aria label for the loading icon to be read by screen reader
|
166
186
|
*/
|
167
|
-
|
187
|
+
inProgress: 'In progress',
|
168
188
|
/**
|
169
|
-
|
189
|
+
*@description Aria label for the cancel icon to be read by screen reader
|
170
190
|
*/
|
171
|
-
|
191
|
+
canceled: 'Canceled',
|
172
192
|
};
|
173
193
|
|
174
194
|
const str_ = i18n.i18n.registerUIStrings('panels/freestyler/components/FreestylerChatUi.ts', UIStrings);
|
175
195
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
176
196
|
const lockedString = i18n.i18n.lockedString;
|
177
197
|
|
178
|
-
function getInputPlaceholderString(
|
179
|
-
aidaAvailability: Host.AidaClient.AidaAccessPreconditions, agentType: AgentType,
|
180
|
-
state: State): Platform.UIString.LocalizedString {
|
198
|
+
function getInputPlaceholderString(agentType: AgentType, state: State): Platform.UIString.LocalizedString {
|
181
199
|
if (state === State.CONSENT_VIEW) {
|
182
200
|
return i18nString(UIStrings.followTheSteps);
|
183
201
|
}
|
184
|
-
switch (
|
185
|
-
case
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
case Host.AidaClient.AidaAccessPreconditions.SYNC_IS_PAUSED:
|
194
|
-
return i18nString(UIStrings.notLoggedIn);
|
195
|
-
case Host.AidaClient.AidaAccessPreconditions.NO_INTERNET:
|
196
|
-
return i18nString(UIStrings.offline);
|
202
|
+
switch (agentType) {
|
203
|
+
case AgentType.FREESTYLER:
|
204
|
+
return lockedString(UIStringsNotTranslate.inputPlaceholderForFreestylerAgent);
|
205
|
+
case AgentType.DRJONES_FILE:
|
206
|
+
return lockedString(UIStringsNotTranslate.inputPlaceholderForDrJonesFileAgent);
|
207
|
+
case AgentType.DRJONES_NETWORK_REQUEST:
|
208
|
+
return lockedString(UIStringsNotTranslate.inputPlaceholderForDrJonesNetworkAgent);
|
209
|
+
case AgentType.DRJONES_PERFORMANCE:
|
210
|
+
return lockedString(UIStringsNotTranslate.inputPlaceholderForDrJonesPerformanceAgent);
|
197
211
|
}
|
198
212
|
}
|
199
213
|
|
@@ -205,7 +219,7 @@ export interface Step {
|
|
205
219
|
output?: string;
|
206
220
|
canceled?: boolean;
|
207
221
|
sideEffect?: ConfirmSideEffectDialog;
|
208
|
-
contextDetails?: ContextDetail[];
|
222
|
+
contextDetails?: [ContextDetail, ...ContextDetail[]];
|
209
223
|
}
|
210
224
|
|
211
225
|
interface ConfirmSideEffectDialog {
|
@@ -239,7 +253,9 @@ export const enum State {
|
|
239
253
|
|
240
254
|
export const enum AgentType {
|
241
255
|
FREESTYLER = 'freestyler',
|
256
|
+
DRJONES_FILE = 'drjones-file',
|
242
257
|
DRJONES_NETWORK_REQUEST = 'drjones-network-request',
|
258
|
+
DRJONES_PERFORMANCE = 'drjones-performance',
|
243
259
|
}
|
244
260
|
|
245
261
|
export interface Props {
|
@@ -248,12 +264,15 @@ export interface Props {
|
|
248
264
|
onFeedbackSubmit: (rpcId: number, rate: Host.AidaClient.Rating, feedback?: string) => void;
|
249
265
|
onCancelClick: () => void;
|
250
266
|
onSelectedNetworkRequestClick: () => void | Promise<void>;
|
267
|
+
onSelectedFileRequestClick: () => void | Promise<void>;
|
251
268
|
inspectElementToggled: boolean;
|
252
269
|
state: State;
|
253
270
|
aidaAvailability: Host.AidaClient.AidaAccessPreconditions;
|
254
271
|
messages: ChatMessage[];
|
255
272
|
selectedElement: SDK.DOMModel.DOMNode|null;
|
273
|
+
selectedFile: Workspace.UISourceCode.UISourceCode|null;
|
256
274
|
selectedNetworkRequest: SDK.NetworkRequest.NetworkRequest|null;
|
275
|
+
selectedStackTrace: Trace.Helpers.TreeHelpers.TraceEntryNodeForAI|null;
|
257
276
|
isLoading: boolean;
|
258
277
|
canShowFeedbackForm: boolean;
|
259
278
|
userInfo: Pick<Host.InspectorFrontendHostAPI.SyncInformation, 'accountImage'|'accountFullName'>;
|
@@ -271,7 +290,7 @@ export interface Props {
|
|
271
290
|
// }
|
272
291
|
// ```
|
273
292
|
class MarkdownRendererWithCodeBlock extends MarkdownView.MarkdownView.MarkdownInsightRenderer {
|
274
|
-
override templateForToken(token: Marked.Marked.
|
293
|
+
override templateForToken(token: Marked.Marked.MarkedToken): LitHtml.TemplateResult|null {
|
275
294
|
if (token.type === 'code') {
|
276
295
|
const lines = (token.text as string).split('\n');
|
277
296
|
if (lines[0]?.trim() === 'css') {
|
@@ -353,10 +372,15 @@ export class FreestylerChatUi extends HTMLElement {
|
|
353
372
|
return Boolean(step.sideEffect);
|
354
373
|
});
|
355
374
|
});
|
375
|
+
|
356
376
|
const isInputDisabledCheckForFreestylerAgent = !Boolean(this.#props.selectedElement) || showsSideEffects;
|
357
377
|
const isInputDisabledCheckForDrJonesNetworkAgent = !Boolean(this.#props.selectedNetworkRequest);
|
378
|
+
const isInputDisabledCheckForDrJonesFileAgent =
|
379
|
+
!Boolean(this.#props.selectedFile) || !this.#props.selectedFile?.contentType().isTextType();
|
380
|
+
|
358
381
|
return (this.#props.agentType === AgentType.FREESTYLER && isInputDisabledCheckForFreestylerAgent) ||
|
359
382
|
(this.#props.agentType === AgentType.DRJONES_NETWORK_REQUEST && isInputDisabledCheckForDrJonesNetworkAgent) ||
|
383
|
+
(this.#props.agentType === AgentType.DRJONES_FILE && isInputDisabledCheckForDrJonesFileAgent) ||
|
360
384
|
!isAidaAvailable || isConsentView;
|
361
385
|
};
|
362
386
|
|
@@ -411,14 +435,14 @@ export class FreestylerChatUi extends HTMLElement {
|
|
411
435
|
|
412
436
|
#renderRateButtons(rpcId: number): LitHtml.TemplateResult {
|
413
437
|
// clang-format off
|
414
|
-
return
|
438
|
+
return html`<devtools-provide-feedback
|
415
439
|
.props=${{
|
416
440
|
onFeedbackSubmit: (rating, feedback) => {
|
417
441
|
this.#props.onFeedbackSubmit(rpcId, rating, feedback);
|
418
442
|
},
|
419
443
|
canShowFeedbackForm: this.#props.canShowFeedbackForm,
|
420
444
|
} as ProvideFeedbackProps}
|
421
|
-
|
445
|
+
></devtools-provide-feedback>`;
|
422
446
|
// clang-format on
|
423
447
|
}
|
424
448
|
|
@@ -437,75 +461,88 @@ export class FreestylerChatUi extends HTMLElement {
|
|
437
461
|
// The tokens were not parsed correctly or
|
438
462
|
// one of the tokens are not supported, so we
|
439
463
|
// continue to render this as text.
|
440
|
-
return
|
464
|
+
return html`${text}`;
|
441
465
|
}
|
442
466
|
|
443
467
|
// clang-format off
|
444
|
-
return
|
468
|
+
return html`<devtools-markdown-view
|
445
469
|
.data=${{tokens, renderer: this.#markdownRenderer} as MarkdownView.MarkdownView.MarkdownViewData}>
|
446
|
-
|
470
|
+
</devtools-markdown-view>`;
|
447
471
|
// clang-format on
|
448
472
|
}
|
449
473
|
|
450
474
|
#renderTitle(step: Step): LitHtml.LitTemplate {
|
451
|
-
const paused = step.sideEffect ?
|
452
|
-
|
453
|
-
LitHtml.nothing;
|
475
|
+
const paused = step.sideEffect ? html`<span class="paused">${lockedString(UIStringsNotTranslate.paused)}: </span>` :
|
476
|
+
LitHtml.nothing;
|
454
477
|
const actionTitle = step.title ?? `${lockedString(UIStringsNotTranslate.investigating)}…`;
|
455
478
|
|
456
|
-
return
|
479
|
+
return html`<span class="title">${paused}${actionTitle}</span>`;
|
457
480
|
}
|
458
481
|
|
459
|
-
#
|
460
|
-
|
461
|
-
|
462
|
-
|
482
|
+
#renderStepCode(step: Step): LitHtml.LitTemplate {
|
483
|
+
if (!step.code && !step.output) {
|
484
|
+
return LitHtml.nothing;
|
485
|
+
}
|
486
|
+
|
463
487
|
// If there is no "output" yet, it means we didn't execute the code yet (e.g. maybe it is still waiting for confirmation from the user)
|
464
488
|
// thus we show "Code to execute" text rather than "Code executed" text on the heading of the code block.
|
465
489
|
const codeHeadingText = (step.output && !step.canceled) ? lockedString(UIStringsNotTranslate.codeExecuted) :
|
466
490
|
lockedString(UIStringsNotTranslate.codeToExecute);
|
491
|
+
|
467
492
|
// If there is output, we don't show notice on this code block and instead show
|
468
493
|
// it in the data returned code block.
|
469
494
|
// clang-format off
|
470
|
-
const code = step.code ?
|
471
|
-
|
495
|
+
const code = step.code ? html`<div class="action-result">
|
496
|
+
<devtools-code-block
|
472
497
|
.code=${step.code.trim()}
|
473
498
|
.codeLang=${'js'}
|
474
499
|
.displayNotice=${!Boolean(step.output)}
|
475
500
|
.header=${codeHeadingText}
|
476
501
|
.showCopyButton=${true}
|
477
|
-
|
478
|
-
</div>` :
|
479
|
-
|
480
|
-
|
502
|
+
></devtools-code-block>
|
503
|
+
</div>` :
|
504
|
+
LitHtml.nothing;
|
505
|
+
const output = step.output ? html`<div class="js-code-output">
|
506
|
+
<devtools-code-block
|
481
507
|
.code=${step.output}
|
482
508
|
.codeLang=${'js'}
|
483
509
|
.displayNotice=${true}
|
484
510
|
.header=${lockedString(UIStringsNotTranslate.dataReturned)}
|
485
511
|
.showCopyButton=${false}
|
486
|
-
|
487
|
-
</div>` :
|
488
|
-
|
489
|
-
|
512
|
+
></devtools-code-block>
|
513
|
+
</div>` :
|
514
|
+
LitHtml.nothing;
|
515
|
+
|
516
|
+
return html`<div class="step-code">${code}${output}</div>`;
|
517
|
+
// clang-format on
|
518
|
+
}
|
519
|
+
|
520
|
+
#renderStepDetails(step: Step, options: {isLast: boolean}): LitHtml.LitTemplate {
|
521
|
+
const sideEffects =
|
522
|
+
options.isLast && step.sideEffect ? this.#renderSideEffectConfirmationUi(step) : LitHtml.nothing;
|
523
|
+
const thought = step.thought ? html`<p>${this.#renderTextAsMarkdown(step.thought)}</p>` : LitHtml.nothing;
|
524
|
+
|
525
|
+
// clang-format off
|
526
|
+
const contextDetails = step.contextDetails ?
|
527
|
+
html`${LitHtml.Directives.repeat(
|
490
528
|
step.contextDetails,
|
491
529
|
contextDetail => {
|
492
|
-
return
|
493
|
-
|
530
|
+
return html`<div class="context-details">
|
531
|
+
<devtools-code-block
|
494
532
|
.code=${contextDetail.text}
|
495
|
-
.codeLang=${'
|
533
|
+
.codeLang=${contextDetail.codeLang || ''}
|
496
534
|
.displayNotice=${false}
|
497
535
|
.header=${contextDetail.title}
|
498
536
|
.showCopyButton=${true}
|
499
|
-
|
537
|
+
></devtools-code-block>
|
500
538
|
</div>`;
|
501
539
|
},
|
502
540
|
)}` : LitHtml.nothing;
|
503
541
|
|
504
|
-
return
|
542
|
+
return html`<div class="step-details">
|
505
543
|
${thought}
|
506
|
-
${
|
544
|
+
${this.#renderStepCode(step)}
|
507
545
|
${sideEffects}
|
508
|
-
${output}
|
509
546
|
${contextDetails}
|
510
547
|
</div>`;
|
511
548
|
// clang-format on
|
@@ -513,31 +550,38 @@ export class FreestylerChatUi extends HTMLElement {
|
|
513
550
|
|
514
551
|
#renderStepBadge(step: Step, options: {isLast: boolean}): LitHtml.LitTemplate {
|
515
552
|
if (this.#props.isLoading && options.isLast && !step.sideEffect) {
|
516
|
-
return
|
553
|
+
return html`<devtools-spinner></devtools-spinner>`;
|
517
554
|
}
|
518
555
|
|
519
556
|
let iconName: string = 'checkmark';
|
557
|
+
let ariaLabel: string|undefined = lockedString(UIStringsNotTranslate.completed);
|
558
|
+
let role: 'button'|undefined = 'button';
|
520
559
|
if (options.isLast && step.sideEffect) {
|
560
|
+
role = undefined;
|
561
|
+
ariaLabel = undefined;
|
521
562
|
iconName = 'pause-circle';
|
522
563
|
} else if (step.canceled) {
|
564
|
+
ariaLabel = lockedString(UIStringsNotTranslate.canceled);
|
523
565
|
iconName = 'cross';
|
524
566
|
}
|
525
567
|
|
526
|
-
return
|
568
|
+
return html`<devtools-icon
|
527
569
|
class="indicator"
|
570
|
+
role=${ifDefined(role)}
|
571
|
+
aria-label=${ifDefined(ariaLabel)}
|
528
572
|
.name=${iconName}
|
529
|
-
|
573
|
+
></devtools-icon>`;
|
530
574
|
}
|
531
575
|
|
532
576
|
#renderStep(step: Step, options: {isLast: boolean}): LitHtml.LitTemplate {
|
533
577
|
const stepClasses = LitHtml.Directives.classMap({
|
534
578
|
step: true,
|
535
|
-
empty: !step.thought && !step.code,
|
579
|
+
empty: !step.thought && !step.code && !step.contextDetails,
|
536
580
|
paused: Boolean(step.sideEffect),
|
537
581
|
canceled: Boolean(step.canceled),
|
538
582
|
});
|
539
583
|
// clang-format off
|
540
|
-
return
|
584
|
+
return html`
|
541
585
|
<details class=${stepClasses}
|
542
586
|
jslog=${VisualLogging.section('step')}
|
543
587
|
.open=${Boolean(step.sideEffect)}>
|
@@ -545,10 +589,10 @@ export class FreestylerChatUi extends HTMLElement {
|
|
545
589
|
<div class="summary">
|
546
590
|
${this.#renderStepBadge(step, options)}
|
547
591
|
${this.#renderTitle(step)}
|
548
|
-
|
592
|
+
<devtools-icon
|
549
593
|
class="arrow"
|
550
594
|
.name=${'chevron-down'}
|
551
|
-
|
595
|
+
></devtools-icon>
|
552
596
|
</div>
|
553
597
|
</summary>
|
554
598
|
${this.#renderStepDetails(step, {
|
@@ -565,13 +609,13 @@ export class FreestylerChatUi extends HTMLElement {
|
|
565
609
|
const sideEffectAction = step.sideEffect.onAnswer;
|
566
610
|
|
567
611
|
// clang-format off
|
568
|
-
return
|
612
|
+
return html`<div
|
569
613
|
class="side-effect-confirmation"
|
570
614
|
jslog=${VisualLogging.section('side-effect-confirmation')}
|
571
615
|
>
|
572
616
|
<p>${lockedString(UIStringsNotTranslate.sideEffectConfirmationDescription)}</p>
|
573
617
|
<div class="side-effect-buttons-container">
|
574
|
-
|
618
|
+
<devtools-button
|
575
619
|
.data=${
|
576
620
|
{
|
577
621
|
variant: Buttons.Button.Variant.OUTLINED,
|
@@ -581,8 +625,8 @@ export class FreestylerChatUi extends HTMLElement {
|
|
581
625
|
@click=${() => sideEffectAction(false)}
|
582
626
|
>${lockedString(
|
583
627
|
UIStringsNotTranslate.negativeSideEffectConfirmation,
|
584
|
-
)}
|
585
|
-
|
628
|
+
)}</devtools-button>
|
629
|
+
<devtools-button
|
586
630
|
.data=${
|
587
631
|
{
|
588
632
|
variant: Buttons.Button.Variant.PRIMARY,
|
@@ -593,7 +637,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
593
637
|
@click=${() => sideEffectAction(true)}
|
594
638
|
>${
|
595
639
|
lockedString(UIStringsNotTranslate.positiveSideEffectConfirmation)
|
596
|
-
}
|
640
|
+
}</devtools-button>
|
597
641
|
</div>
|
598
642
|
</div>`;
|
599
643
|
// clang-format on
|
@@ -610,11 +654,11 @@ export class FreestylerChatUi extends HTMLElement {
|
|
610
654
|
errorMessage = UIStringsNotTranslate.maxStepsError;
|
611
655
|
break;
|
612
656
|
case ErrorType.ABORT:
|
613
|
-
return
|
657
|
+
return html`<p class="aborted" jslog=${VisualLogging.section('aborted')}>${
|
614
658
|
lockedString(UIStringsNotTranslate.stoppedResponse)}</p>`;
|
615
659
|
}
|
616
660
|
|
617
|
-
return
|
661
|
+
return html`<p class="error" jslog=${VisualLogging.section('error')}>${lockedString(errorMessage)}</p>`;
|
618
662
|
}
|
619
663
|
|
620
664
|
return LitHtml.nothing;
|
@@ -624,12 +668,12 @@ export class FreestylerChatUi extends HTMLElement {
|
|
624
668
|
if (message.entity === ChatMessageEntity.USER) {
|
625
669
|
const name = this.#props.userInfo.accountFullName || lockedString(UIStringsNotTranslate.you);
|
626
670
|
const image = this.#props.userInfo.accountImage ?
|
627
|
-
|
628
|
-
|
671
|
+
html`<img src="data:image/png;base64, ${this.#props.userInfo.accountImage}" alt="Account avatar" />` :
|
672
|
+
html`<devtools-icon
|
629
673
|
.name=${'profile'}
|
630
|
-
|
674
|
+
></devtools-icon>`;
|
631
675
|
// clang-format off
|
632
|
-
return
|
676
|
+
return html`<section
|
633
677
|
class="chat-message query"
|
634
678
|
jslog=${VisualLogging.section('question')}
|
635
679
|
>
|
@@ -647,12 +691,12 @@ export class FreestylerChatUi extends HTMLElement {
|
|
647
691
|
const shouldShowSuggestions =
|
648
692
|
(isLast && !this.#props.isLoading && message.suggestions && message.suggestions?.length > 0);
|
649
693
|
// clang-format off
|
650
|
-
return
|
694
|
+
return html`
|
651
695
|
<section class="chat-message answer" jslog=${VisualLogging.section('answer')}>
|
652
696
|
<div class="message-info">
|
653
|
-
|
697
|
+
<devtools-icon
|
654
698
|
name="smart-assistant"
|
655
|
-
|
699
|
+
></devtools-icon>
|
656
700
|
<div class="message-name">
|
657
701
|
<h2>${lockedString(UIStringsNotTranslate.ai)}</h2>
|
658
702
|
</div>
|
@@ -668,7 +712,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
668
712
|
)}
|
669
713
|
${
|
670
714
|
message.answer
|
671
|
-
?
|
715
|
+
? html`<p>${this.#renderTextAsMarkdown(message.answer)}</p>`
|
672
716
|
: LitHtml.nothing
|
673
717
|
}
|
674
718
|
${this.#renderError(message)}
|
@@ -679,14 +723,15 @@ export class FreestylerChatUi extends HTMLElement {
|
|
679
723
|
: LitHtml.nothing
|
680
724
|
}
|
681
725
|
${shouldShowSuggestions ?
|
682
|
-
|
683
|
-
${message.suggestions?.map(suggestion =>
|
726
|
+
html`<div class="suggestions">
|
727
|
+
${message.suggestions?.map(suggestion => html`<devtools-button
|
684
728
|
.data=${{
|
685
729
|
variant: Buttons.Button.Variant.OUTLINED,
|
686
|
-
|
730
|
+
title: suggestion,
|
731
|
+
jslogContext: 'suggestion',
|
687
732
|
} as Buttons.Button.ButtonData}
|
688
733
|
@click=${() => this.#handleSuggestionClick(suggestion)}
|
689
|
-
>${suggestion}
|
734
|
+
>${suggestion}</devtools-button>`)}
|
690
735
|
</div>` : LitHtml.nothing}
|
691
736
|
</div>
|
692
737
|
</section>
|
@@ -698,9 +743,33 @@ export class FreestylerChatUi extends HTMLElement {
|
|
698
743
|
switch (this.#props.agentType) {
|
699
744
|
case AgentType.FREESTYLER:
|
700
745
|
return this.#renderSelectAnElement();
|
746
|
+
case AgentType.DRJONES_FILE:
|
747
|
+
return this.#renderSelectedFileName();
|
701
748
|
case AgentType.DRJONES_NETWORK_REQUEST:
|
702
749
|
return this.#renderSelectedNetworkRequest();
|
750
|
+
case AgentType.DRJONES_PERFORMANCE:
|
751
|
+
return this.#renderSelectedTask();
|
752
|
+
}
|
753
|
+
}
|
754
|
+
|
755
|
+
#renderSelectedFileName(): LitHtml.TemplateResult {
|
756
|
+
const resourceClass = LitHtml.Directives.classMap({
|
757
|
+
'not-selected': !this.#props.selectedFile,
|
758
|
+
'resource-link': true,
|
759
|
+
});
|
760
|
+
|
761
|
+
if (!this.#props.selectedFile) {
|
762
|
+
return html`${LitHtml.nothing}`;
|
703
763
|
}
|
764
|
+
|
765
|
+
// TODO(b/371947238): Add icon
|
766
|
+
// clang-format off
|
767
|
+
return html`<div class="select-element">
|
768
|
+
<div role=button class=${resourceClass}
|
769
|
+
@click=${this.#props.onSelectedFileRequestClick}>
|
770
|
+
${this.#props.selectedFile?.displayName()}
|
771
|
+
</div></div>`;
|
772
|
+
// clang-format on
|
704
773
|
}
|
705
774
|
|
706
775
|
#renderSelectedNetworkRequest = (): LitHtml.TemplateResult => {
|
@@ -710,13 +779,13 @@ export class FreestylerChatUi extends HTMLElement {
|
|
710
779
|
});
|
711
780
|
|
712
781
|
if (!this.#props.selectedNetworkRequest) {
|
713
|
-
return
|
782
|
+
return html`${LitHtml.nothing}`;
|
714
783
|
}
|
715
784
|
|
716
785
|
const icon = PanelUtils.getIconForNetworkRequest(this.#props.selectedNetworkRequest);
|
717
786
|
// clang-format off
|
718
|
-
return
|
719
|
-
<div class=${resourceClass}
|
787
|
+
return html`<div class="select-element">
|
788
|
+
<div role=button class=${resourceClass}
|
720
789
|
@click=${this.#props.onSelectedNetworkRequestClick}>
|
721
790
|
${icon}${this.#props.selectedNetworkRequest?.name()}
|
722
791
|
</div></div>`;
|
@@ -730,9 +799,9 @@ export class FreestylerChatUi extends HTMLElement {
|
|
730
799
|
});
|
731
800
|
|
732
801
|
// clang-format off
|
733
|
-
return
|
802
|
+
return html`
|
734
803
|
<div class="select-element">
|
735
|
-
|
804
|
+
<devtools-button
|
736
805
|
.data=${{
|
737
806
|
variant: Buttons.Button.Variant.ICON_TOGGLE,
|
738
807
|
size: Buttons.Button.Size.REGULAR,
|
@@ -744,13 +813,13 @@ export class FreestylerChatUi extends HTMLElement {
|
|
744
813
|
jslogContext: 'select-element',
|
745
814
|
} as Buttons.Button.ButtonData}
|
746
815
|
@click=${this.#props.onInspectElementClick}
|
747
|
-
|
816
|
+
></devtools-button>
|
748
817
|
<div class=${resourceClass}>${
|
749
818
|
this.#props.selectedElement
|
750
819
|
? LitHtml.Directives.until(
|
751
820
|
Common.Linkifier.Linkifier.linkify(this.#props.selectedElement),
|
752
821
|
)
|
753
|
-
:
|
822
|
+
: html`<span>${
|
754
823
|
lockedString(UIStringsNotTranslate.noElementSelected)
|
755
824
|
}</span>`
|
756
825
|
}</div>
|
@@ -758,10 +827,48 @@ export class FreestylerChatUi extends HTMLElement {
|
|
758
827
|
// clang-format on
|
759
828
|
};
|
760
829
|
|
830
|
+
#renderSelectedTask = (): LitHtml.TemplateResult => {
|
831
|
+
const resourceClass = LitHtml.Directives.classMap({
|
832
|
+
'not-selected': !this.#props.selectedStackTrace,
|
833
|
+
'resource-task': true,
|
834
|
+
});
|
835
|
+
|
836
|
+
if (!this.#props.selectedStackTrace) {
|
837
|
+
return html`${LitHtml.nothing}`;
|
838
|
+
}
|
839
|
+
|
840
|
+
const selectedNode = Trace.Helpers.TreeHelpers.TraceEntryNodeForAI.getSelectedNodeForTraceEntryTreeForAI(
|
841
|
+
this.#props.selectedStackTrace);
|
842
|
+
|
843
|
+
if (!selectedNode) {
|
844
|
+
return html`${LitHtml.nothing}`;
|
845
|
+
}
|
846
|
+
|
847
|
+
let displayName = selectedNode.type;
|
848
|
+
if (selectedNode.type === 'ProfileCall' && selectedNode.function) {
|
849
|
+
displayName = selectedNode.function;
|
850
|
+
}
|
851
|
+
|
852
|
+
const iconData = {
|
853
|
+
iconName: 'performance',
|
854
|
+
color: 'var(--sys-color-on-surface-subtle)',
|
855
|
+
};
|
856
|
+
const icon = PanelUtils.createIconElement(iconData, 'Performance');
|
857
|
+
icon.classList.add('icon');
|
858
|
+
|
859
|
+
// TODO(b/371118936): Make the div clickable
|
860
|
+
// clang-format off
|
861
|
+
return html`<div class="select-element">
|
862
|
+
<div class=${resourceClass}>
|
863
|
+
${icon}${displayName}
|
864
|
+
</div></div>`;
|
865
|
+
// clang-format on
|
866
|
+
};
|
867
|
+
|
761
868
|
#renderMessages = (): LitHtml.TemplateResult => {
|
762
869
|
// clang-format off
|
763
|
-
return
|
764
|
-
<
|
870
|
+
return html`
|
871
|
+
<div class="messages-scroll-container" @scroll=${this.#handleScroll}>
|
765
872
|
<div class="messages-container">
|
766
873
|
${this.#props.messages.map((message, _, array) =>
|
767
874
|
this.#renderChatMessage(message, {
|
@@ -769,7 +876,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
769
876
|
}),
|
770
877
|
)}
|
771
878
|
</div>
|
772
|
-
</
|
879
|
+
</div>
|
773
880
|
`;
|
774
881
|
// clang-format on
|
775
882
|
};
|
@@ -778,18 +885,18 @@ export class FreestylerChatUi extends HTMLElement {
|
|
778
885
|
const suggestions = this.#getSuggestions();
|
779
886
|
|
780
887
|
// clang-format off
|
781
|
-
return
|
888
|
+
return html`<div class="empty-state-container messages-scroll-container">
|
782
889
|
<div class="header">
|
783
890
|
<div class="icon">
|
784
|
-
|
891
|
+
<devtools-icon
|
785
892
|
name="smart-assistant"
|
786
|
-
|
893
|
+
></devtools-icon>
|
787
894
|
</div>
|
788
|
-
<
|
895
|
+
<h1>${lockedString(UIStringsNotTranslate.emptyStateText)}</h1>
|
789
896
|
</div>
|
790
897
|
<div class="suggestions">
|
791
898
|
${suggestions.map(suggestion => {
|
792
|
-
return
|
899
|
+
return html`<devtools-button
|
793
900
|
class="suggestion"
|
794
901
|
@click=${() => this.#handleSuggestionClick(suggestion)}
|
795
902
|
.data=${
|
@@ -801,7 +908,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
801
908
|
disabled: this.#isTextInputDisabled(),
|
802
909
|
} as Buttons.Button.ButtonData
|
803
910
|
}
|
804
|
-
>${suggestion}
|
911
|
+
>${suggestion}</devtools-button>`;
|
805
912
|
})}
|
806
913
|
</div>
|
807
914
|
</div>`;
|
@@ -816,25 +923,33 @@ export class FreestylerChatUi extends HTMLElement {
|
|
816
923
|
'Why does this element overlap another?',
|
817
924
|
'How do I center this element?',
|
818
925
|
];
|
926
|
+
case AgentType.DRJONES_FILE:
|
927
|
+
return [
|
928
|
+
'What are the key functions in this file and what are they doing?',
|
929
|
+
];
|
819
930
|
case AgentType.DRJONES_NETWORK_REQUEST:
|
820
931
|
return [
|
821
932
|
'Why is this network request taking longer to complete?',
|
822
933
|
];
|
934
|
+
case AgentType.DRJONES_PERFORMANCE:
|
935
|
+
return [
|
936
|
+
'Is this item on the critical rendering path?',
|
937
|
+
];
|
823
938
|
}
|
824
939
|
};
|
825
940
|
|
826
941
|
#renderChatInput = (): LitHtml.TemplateResult => {
|
827
942
|
// clang-format off
|
828
|
-
return
|
943
|
+
return html`
|
829
944
|
<div class="chat-input-container">
|
830
945
|
<textarea class="chat-input"
|
831
946
|
.disabled=${this.#isTextInputDisabled()}
|
832
947
|
wrap="hard"
|
833
948
|
@keydown=${this.#handleTextAreaKeyDown}
|
834
|
-
placeholder=${getInputPlaceholderString(this.#props.
|
949
|
+
placeholder=${getInputPlaceholderString(this.#props.agentType, this.#props.state)}
|
835
950
|
jslog=${VisualLogging.textField('query').track({ keydown: 'Enter' })}></textarea>
|
836
951
|
${this.#props.isLoading
|
837
|
-
?
|
952
|
+
? html`<devtools-button
|
838
953
|
class="chat-input-button"
|
839
954
|
aria-label=${lockedString(UIStringsNotTranslate.cancelButtonTitle)}
|
840
955
|
@click=${this.#handleCancel}
|
@@ -848,8 +963,8 @@ export class FreestylerChatUi extends HTMLElement {
|
|
848
963
|
jslogContext: 'stop',
|
849
964
|
} as Buttons.Button.ButtonData
|
850
965
|
}
|
851
|
-
|
852
|
-
:
|
966
|
+
></devtools-button>`
|
967
|
+
: html`<devtools-button
|
853
968
|
class="chat-input-button"
|
854
969
|
aria-label=${lockedString(UIStringsNotTranslate.sendButtonTitle)}
|
855
970
|
.data=${
|
@@ -863,7 +978,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
863
978
|
jslogContext: 'send',
|
864
979
|
} as Buttons.Button.ButtonData
|
865
980
|
}
|
866
|
-
|
981
|
+
></devtools-button>`}
|
867
982
|
</div>`;
|
868
983
|
// clang-format on
|
869
984
|
};
|
@@ -875,12 +990,16 @@ export class FreestylerChatUi extends HTMLElement {
|
|
875
990
|
switch (this.#props.agentType) {
|
876
991
|
case AgentType.FREESTYLER:
|
877
992
|
return lockedString(UIStringsNotTranslate.inputDisclaimerForFreestylerAgent);
|
993
|
+
case AgentType.DRJONES_FILE:
|
994
|
+
return lockedString(UIStringsNotTranslate.inputDisclaimerForDrJonesFileAgent);
|
878
995
|
case AgentType.DRJONES_NETWORK_REQUEST:
|
879
996
|
return lockedString(UIStringsNotTranslate.inputDisclaimerForDrJonesNetworkAgent);
|
997
|
+
case AgentType.DRJONES_PERFORMANCE:
|
998
|
+
return lockedString(UIStringsNotTranslate.inputDisclaimerForDrJonesPerformanceAgent);
|
880
999
|
}
|
881
1000
|
};
|
882
1001
|
|
883
|
-
#
|
1002
|
+
#getConsentViewContents(): LitHtml.TemplateResult {
|
884
1003
|
const settingsLink = document.createElement('button');
|
885
1004
|
settingsLink.textContent = i18nString(UIStrings.settingsLink);
|
886
1005
|
settingsLink.classList.add('link');
|
@@ -890,23 +1009,42 @@ export class FreestylerChatUi extends HTMLElement {
|
|
890
1009
|
});
|
891
1010
|
settingsLink.setAttribute('jslog', `${VisualLogging.action('open-ai-settings').track({click: true})}`);
|
892
1011
|
const config = Common.Settings.Settings.instance().getHostConfig();
|
1012
|
+
return html`${
|
1013
|
+
config.devToolsExplainThisResourceDogfood?.enabled ?
|
1014
|
+
i18n.i18n.getFormatLocalizedString(str_, UIStrings.turnOnForStylesAndRequests, {PH1: settingsLink}) :
|
1015
|
+
i18n.i18n.getFormatLocalizedString(str_, UIStrings.turnOnForStyles, {PH1: settingsLink})}`;
|
1016
|
+
}
|
1017
|
+
|
1018
|
+
#getUnavailableAidaAvailabilityContents(
|
1019
|
+
aidaAvailability:
|
1020
|
+
Exclude<Host.AidaClient.AidaAccessPreconditions, Host.AidaClient.AidaAccessPreconditions.AVAILABLE>):
|
1021
|
+
LitHtml.TemplateResult {
|
1022
|
+
switch (aidaAvailability) {
|
1023
|
+
case Host.AidaClient.AidaAccessPreconditions.NO_ACCOUNT_EMAIL:
|
1024
|
+
case Host.AidaClient.AidaAccessPreconditions.SYNC_IS_PAUSED: {
|
1025
|
+
return html`${i18nString(UIStrings.notLoggedIn)}`;
|
1026
|
+
}
|
1027
|
+
case Host.AidaClient.AidaAccessPreconditions.NO_INTERNET: {
|
1028
|
+
return html`${i18nString(UIStrings.offline)}`;
|
1029
|
+
}
|
1030
|
+
}
|
1031
|
+
}
|
893
1032
|
|
1033
|
+
#renderDisabledState(contents: LitHtml.TemplateResult): LitHtml.TemplateResult {
|
894
1034
|
// clang-format off
|
895
|
-
return
|
896
|
-
<div class="empty-state-container">
|
897
|
-
<div class="
|
898
|
-
<div class="
|
899
|
-
|
1035
|
+
return html`
|
1036
|
+
<div class="empty-state-container messages-scroll-container">
|
1037
|
+
<div class="disabled-view">
|
1038
|
+
<div class="disabled-view-icon-container">
|
1039
|
+
<devtools-icon .data=${{
|
900
1040
|
iconName: 'smart-assistant',
|
901
1041
|
width: 'var(--sys-size-8)',
|
902
1042
|
height: 'var(--sys-size-8)',
|
903
1043
|
} as IconButton.Icon.IconData}>
|
1044
|
+
</devtools-icon>
|
904
1045
|
</div>
|
905
1046
|
<div>
|
906
|
-
${
|
907
|
-
i18n.i18n.getFormatLocalizedString(str_, UIStrings.turnOnForStylesAndRequests, {PH1: settingsLink}) :
|
908
|
-
i18n.i18n.getFormatLocalizedString(str_, UIStrings.turnOnForStyles, {PH1: settingsLink})
|
909
|
-
}
|
1047
|
+
${contents}
|
910
1048
|
</div>
|
911
1049
|
</div>
|
912
1050
|
</div>
|
@@ -914,32 +1052,43 @@ export class FreestylerChatUi extends HTMLElement {
|
|
914
1052
|
// clang-format on
|
915
1053
|
}
|
916
1054
|
|
1055
|
+
#renderMainContents(): LitHtml.TemplateResult {
|
1056
|
+
if (this.#props.state === State.CONSENT_VIEW) {
|
1057
|
+
return this.#renderDisabledState(this.#getConsentViewContents());
|
1058
|
+
}
|
1059
|
+
|
1060
|
+
if (this.#props.aidaAvailability !== Host.AidaClient.AidaAccessPreconditions.AVAILABLE) {
|
1061
|
+
return this.#renderDisabledState(this.#getUnavailableAidaAvailabilityContents(this.#props.aidaAvailability));
|
1062
|
+
}
|
1063
|
+
|
1064
|
+
if (this.#props.messages.length > 0) {
|
1065
|
+
return this.#renderMessages();
|
1066
|
+
}
|
1067
|
+
|
1068
|
+
return this.#renderEmptyState();
|
1069
|
+
}
|
1070
|
+
|
917
1071
|
#render(): void {
|
918
1072
|
// clang-format off
|
919
|
-
LitHtml.render(
|
1073
|
+
LitHtml.render(html`
|
920
1074
|
<div class="chat-ui">
|
921
|
-
|
922
|
-
this.#
|
923
|
-
|
924
|
-
|
925
|
-
|
926
|
-
|
927
|
-
|
928
|
-
|
929
|
-
${this.#props.state !== State.CONSENT_VIEW ? LitHtml.html`
|
930
|
-
<div class="input-header">
|
931
|
-
<div class="header-link-container">
|
932
|
-
${this.#renderSelection()}
|
1075
|
+
<main>
|
1076
|
+
${this.#renderMainContents()}
|
1077
|
+
<form class="input-form" @submit=${this.#handleSubmit}>
|
1078
|
+
${this.#props.state !== State.CONSENT_VIEW ? html`
|
1079
|
+
<div class="input-header">
|
1080
|
+
<div class="header-link-container">
|
1081
|
+
${this.#renderSelection()}
|
1082
|
+
</div>
|
933
1083
|
</div>
|
934
|
-
|
935
|
-
|
936
|
-
|
937
|
-
</
|
1084
|
+
` : LitHtml.nothing}
|
1085
|
+
${this.#renderChatInput()}
|
1086
|
+
</form>
|
1087
|
+
</main>
|
938
1088
|
<footer class="disclaimer">
|
939
|
-
<p class="disclaimer-text"
|
940
|
-
this.#getDisclaimerText()
|
941
|
-
|
942
|
-
href="#"
|
1089
|
+
<p class="disclaimer-text">
|
1090
|
+
${this.#getDisclaimerText()}
|
1091
|
+
<x-link
|
943
1092
|
class="link"
|
944
1093
|
jslog=${VisualLogging.link('open-ai-settings').track({
|
945
1094
|
click: true,
|
@@ -950,7 +1099,7 @@ export class FreestylerChatUi extends HTMLElement {
|
|
950
1099
|
'chrome-ai',
|
951
1100
|
);
|
952
1101
|
}}
|
953
|
-
>${
|
1102
|
+
>${i18nString(UIStrings.learnAbout)}</x-link>
|
954
1103
|
</p>
|
955
1104
|
</footer>
|
956
1105
|
</div>
|