chrome-devtools-frontend 1.0.1684555 → 1.0.1690116
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/skills/gerrit-cli/SKILL.md +29 -8
- package/.agents/skills/gerrit-cli/references/commands.md +51 -18
- package/.agents/skills/gerrit-cli/references/workflows.md +6 -6
- package/.agents/skills/gerrit-cli/scripts/import_upstream.py +43 -70
- package/config/typescript/tsconfig.base.json +1 -0
- package/config/typescript/tsconfig.eslint.json +9 -0
- package/docs/contributing/issues.md +1 -1
- package/docs/styleguide/ux/writing.md +2 -2
- package/eslint.config.mjs +26 -12
- package/front_end/core/common/Base64.ts +1 -1
- package/front_end/core/common/Color.ts +28 -6
- package/front_end/core/common/ColorConverter.ts +12 -0
- package/front_end/core/common/Console.ts +2 -1
- package/front_end/core/common/Object.ts +10 -4
- package/front_end/core/common/ResourceType.ts +12 -13
- package/front_end/core/common/Revealer.ts +1 -1
- package/front_end/core/common/Settings.ts +2 -2
- package/front_end/core/common/TextDictionary.ts +2 -2
- package/front_end/core/common/Throttler.ts +1 -1
- package/front_end/core/host/InspectorFrontendHostAPI.ts +2 -2
- package/front_end/core/host/UserMetrics.ts +51 -37
- package/front_end/core/host/host.ts +1 -1
- package/front_end/core/i18n/collect-ui-strings.js +5 -5
- package/front_end/core/i18n/generate-locales-js.js +1 -1
- package/front_end/core/i18n/i18n.ts +6 -0
- package/front_end/core/i18n/i18nImpl.ts +1 -1
- package/front_end/core/platform/HostRuntime.ts +3 -3
- package/front_end/core/platform/KeyboardUtilities.ts +1 -1
- package/front_end/core/protocol_client/InspectorBackend.ts +7 -6
- package/front_end/core/root/Runtime.ts +4 -7
- package/front_end/core/sdk/AnimationModel.ts +1 -1
- package/front_end/core/sdk/CPUThrottlingManager.ts +198 -0
- package/front_end/core/sdk/CSSMetadata.ts +9 -6
- package/front_end/core/sdk/CSSPropertyParser.ts +5 -3
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +90 -59
- package/front_end/core/sdk/ConsoleModel.ts +1 -1
- package/front_end/core/sdk/DOMModel.ts +49 -14
- package/front_end/core/sdk/DebuggerModel.ts +1 -1
- package/front_end/core/sdk/EmulationModel.ts +23 -0
- package/front_end/core/sdk/LayerTreeBase.ts +1 -1
- package/front_end/core/sdk/NetworkManager.ts +1 -1
- package/front_end/core/sdk/README.md +40 -0
- package/front_end/core/sdk/RehydratingConnection.ts +1 -1
- package/front_end/core/sdk/RemoteObject.ts +1 -1
- package/front_end/core/sdk/ResourceTreeModel.ts +2 -2
- package/front_end/core/sdk/SDKModel.ts +1 -1
- package/front_end/core/sdk/SDKSettings.ts +15 -0
- package/front_end/core/sdk/Script.ts +1 -1
- package/front_end/core/sdk/SecurityOrigin.ts +158 -0
- package/front_end/core/sdk/ServiceWorkerManager.ts +75 -17
- package/front_end/core/sdk/Target.ts +1 -5
- package/front_end/core/sdk/sdk.ts +2 -0
- package/front_end/core/text_utils/ContentData.ts +1 -1
- package/front_end/entrypoints/formatter_worker/FormattedContentBuilder.ts +3 -1
- package/front_end/entrypoints/formatter_worker/FormatterWorker.ts +1 -1
- package/front_end/entrypoints/formatter_worker/ScopeParser.ts +2 -2
- package/front_end/entrypoints/formatter_worker/Substitute.ts +1 -1
- package/front_end/entrypoints/formatter_worker/formatter_worker-entrypoint.ts +1 -1
- package/front_end/entrypoints/inspector_main/InspectorMain.ts +1 -1
- package/front_end/entrypoints/inspector_main/OutermostTargetSelector.ts +1 -1
- package/front_end/entrypoints/inspector_main/nodeIcon.css +1 -1
- package/front_end/entrypoints/inspector_main/outermostTargetSelector.css +3 -3
- package/front_end/entrypoints/inspector_main/renderingOptions.css +3 -3
- package/front_end/entrypoints/js_app/js_app.ts +25 -9
- package/front_end/entrypoints/node_app/app/nodeConnectionsPanel.css +5 -5
- package/front_end/entrypoints/node_app/node_app.ts +1 -1
- package/front_end/generated/ARIAProperties.ts +39 -1
- package/front_end/generated/InspectorBackendCommands.ts +2 -1
- package/front_end/generated/SupportedCSSProperties.ts +60 -119
- package/front_end/generated/protocol-mapping.d.ts +9 -0
- package/front_end/generated/protocol-proxy-api.d.ts +7 -0
- package/front_end/generated/protocol.ts +12 -2
- package/front_end/models/ai_assistance/AiAgent2.ts +13 -7
- package/front_end/models/ai_assistance/AiConversation.ts +8 -17
- package/front_end/models/ai_assistance/AiHistoryStorage.ts +2 -2
- package/front_end/models/ai_assistance/AiUtils.ts +16 -10
- package/front_end/models/ai_assistance/EvaluateAction.ts +1 -1
- package/front_end/models/ai_assistance/README.md +1 -1
- package/front_end/models/ai_assistance/agents/AccessibilityAgent.ts +8 -13
- package/front_end/models/ai_assistance/agents/AiAgent.ts +29 -6
- package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +4 -3
- package/front_end/models/ai_assistance/agents/FileAgent.ts +2 -2
- package/front_end/models/ai_assistance/agents/NetworkAgent.ts +2 -2
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +1 -1
- package/front_end/models/ai_assistance/agents/StorageAgent.ts +7 -5
- package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +2 -2
- package/front_end/models/ai_assistance/agents/StylingAgent.ts +8 -7
- package/front_end/models/ai_assistance/ai_assistance.ts +8 -0
- package/front_end/models/ai_assistance/contexts/AccessibilityContext.ts +16 -1
- package/front_end/models/ai_assistance/contexts/FileContext.ts +6 -0
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +150 -325
- package/front_end/models/ai_assistance/injected.ts +3 -3
- package/front_end/models/ai_assistance/performance/AIContext.ts +1 -1
- package/front_end/models/ai_assistance/skills/README.md +1 -1
- package/front_end/models/ai_assistance/skills/accessibility.md +19 -10
- package/front_end/models/ai_assistance/skills/network.md +13 -7
- package/front_end/models/ai_assistance/skills/performance.md +22 -16
- package/front_end/models/ai_assistance/skills/sources.md +13 -7
- package/front_end/models/ai_assistance/skills/storage.md +19 -18
- package/front_end/models/ai_assistance/skills/styling.md +30 -37
- package/front_end/models/ai_assistance/tools/CookieUtils.ts +120 -0
- package/front_end/models/ai_assistance/tools/DOMStorageUtils.ts +53 -4
- package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +8 -32
- package/front_end/models/ai_assistance/tools/GetCookieValues.ts +146 -0
- package/front_end/models/ai_assistance/tools/GetDetailedCallTree.ts +11 -9
- package/front_end/models/ai_assistance/tools/GetElementAccessibilityDetails.ts +17 -5
- package/front_end/models/ai_assistance/tools/GetFunctionCode.ts +12 -11
- package/front_end/models/ai_assistance/tools/GetInsightDetails.ts +11 -11
- package/front_end/models/ai_assistance/tools/GetLighthouseAudits.ts +3 -2
- package/front_end/models/ai_assistance/tools/GetNetworkRequestDetails.ts +3 -3
- package/front_end/models/ai_assistance/tools/GetResourceContent.ts +12 -12
- package/front_end/models/ai_assistance/tools/GetSourceContent.ts +3 -2
- package/front_end/models/ai_assistance/tools/GetStorageBreakdown.ts +132 -0
- package/front_end/models/ai_assistance/tools/GetStorageValues.ts +17 -4
- package/front_end/models/ai_assistance/tools/GetStyles.ts +3 -3
- package/front_end/models/ai_assistance/tools/GetTraceEventByKey.ts +9 -8
- package/front_end/models/ai_assistance/tools/GetTraceMainThreadSummary.ts +13 -14
- package/front_end/models/ai_assistance/tools/GetTraceNetworkSummary.ts +12 -10
- package/front_end/models/ai_assistance/tools/ListCookies.ts +93 -0
- package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +15 -6
- package/front_end/models/ai_assistance/tools/ListPageOrigins.ts +3 -3
- package/front_end/models/ai_assistance/tools/ListSources.ts +5 -3
- package/front_end/models/ai_assistance/tools/ListStorageKeys.ts +16 -4
- package/front_end/models/ai_assistance/tools/RecordPerformanceTrace.ts +3 -2
- package/front_end/models/ai_assistance/tools/ResolveDevtoolsNodePath.ts +4 -3
- package/front_end/models/ai_assistance/tools/RunLighthouse.ts +9 -9
- package/front_end/models/ai_assistance/tools/SelectTraceEventByKey.ts +9 -8
- package/front_end/models/ai_assistance/tools/Tool.ts +21 -11
- package/front_end/models/ai_assistance/tools/ToolRegistry.ts +41 -8
- package/front_end/models/badges/AiExplorerBadge.ts +3 -3
- package/front_end/models/badges/CodeWhispererBadge.ts +2 -2
- package/front_end/models/badges/DOMDetectiveBadge.ts +3 -3
- package/front_end/models/badges/SpeedsterBadge.ts +3 -3
- package/front_end/models/badges/StarterBadge.ts +4 -4
- package/front_end/models/bindings/CompilerScriptMapping.ts +11 -2
- package/front_end/models/bindings/ContentProviderBasedProject.ts +3 -2
- package/front_end/models/breakpoints/BreakpointManager.ts +1 -1
- package/front_end/models/emulation/EmulatedDevices.ts +2 -2
- package/front_end/models/formatter/FormatterWorkerPool.ts +2 -2
- package/front_end/models/formatter/ScriptFormatter.ts +1 -2
- package/front_end/models/geometry/GeometryImpl.ts +2 -2
- package/front_end/models/heap_snapshot/HeapSnapshotModel.ts +1 -1
- package/front_end/models/heap_snapshot/HeapSnapshotProxy.ts +3 -2
- package/front_end/models/issues_manager/ContentSecurityPolicyIssue.ts +5 -5
- package/front_end/models/issues_manager/GenericIssue.ts +18 -18
- package/front_end/models/issues_manager/StylesheetLoadingIssue.ts +1 -1
- package/front_end/models/javascript_metadata/{NativeFunctions.js → NativeFunctions.ts} +26 -10
- package/front_end/models/live-metrics/LiveMetrics.ts +9 -3
- package/front_end/models/live-metrics/web-vitals-injected/spec/spec.ts +58 -6
- package/front_end/models/live-metrics/web-vitals-injected/web-vitals-injected.ts +2 -62
- package/front_end/models/network_time_calculator/RequestTimeRanges.ts +2 -2
- package/front_end/models/persistence/AutomaticFileSystemWorkspaceBinding.ts +5 -0
- package/front_end/models/persistence/IsolatedFileSystem.ts +1 -1
- package/front_end/models/persistence/NetworkPersistenceManager.ts +35 -6
- package/front_end/models/stack_trace/StackTraceImpl.ts +2 -2
- package/front_end/models/trace/LanternComputationData.ts +2 -3
- package/front_end/models/trace/extras/StackTraceForEvent.ts +3 -2
- package/front_end/models/trace/extras/ThirdParties.ts +9 -9
- package/front_end/models/trace/handlers/AsyncJSCallsHandler.ts +7 -4
- package/front_end/models/trace/handlers/FramesHandler.ts +3 -3
- package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +2 -2
- package/front_end/models/trace/handlers/SamplesHandler.ts +4 -2
- package/front_end/models/trace/handlers/UserInteractionsHandler.ts +1 -1
- package/front_end/models/trace/handlers/WarningsHandler.ts +2 -2
- package/front_end/models/trace/helpers/Network.ts +3 -3
- package/front_end/models/trace/helpers/Trace.ts +1 -1
- package/front_end/models/trace/insights/CLSCulprits.ts +1 -1
- package/front_end/models/trace/insights/Cache.ts +1 -1
- package/front_end/models/trace/insights/CharacterSet.ts +1 -1
- package/front_end/models/trace/insights/DOMSize.ts +1 -1
- package/front_end/models/trace/insights/DocumentLatency.ts +1 -1
- package/front_end/models/trace/insights/DuplicatedJavaScript.ts +1 -1
- package/front_end/models/trace/insights/FontDisplay.ts +1 -1
- package/front_end/models/trace/insights/ForcedReflow.ts +1 -1
- package/front_end/models/trace/insights/INPBreakdown.ts +1 -1
- package/front_end/models/trace/insights/ImageDelivery.ts +1 -1
- package/front_end/models/trace/insights/LCPBreakdown.ts +1 -1
- package/front_end/models/trace/insights/LCPDiscovery.ts +1 -1
- package/front_end/models/trace/insights/LegacyJavaScript.ts +1 -1
- package/front_end/models/trace/insights/ModernHTTP.ts +1 -1
- package/front_end/models/trace/insights/NetworkDependencyTree.ts +1 -1
- package/front_end/models/trace/insights/RenderBlocking.ts +3 -4
- package/front_end/models/trace/insights/SlowCSSSelector.ts +1 -1
- package/front_end/models/trace/insights/ThirdParties.ts +3 -3
- package/front_end/models/trace/insights/Viewport.ts +1 -1
- package/front_end/models/trace/lantern/simulation/Constants.ts +34 -2
- package/front_end/models/trace/lantern/simulation/DNSCache.ts +1 -1
- package/front_end/models/trace/types/TraceEvents.ts +8 -3
- package/front_end/models/trace_source_maps_resolver/SourceMapsResolver.ts +2 -1
- package/front_end/models/workspace/WorkspaceImpl.ts +18 -2
- package/front_end/panels/accessibility/ARIAAttributesView.ts +1 -1
- package/front_end/panels/accessibility/AccessibilityAnnouncementRecordingView.ts +686 -2
- package/front_end/panels/accessibility/AccessibilityNodeView.ts +1 -2
- package/front_end/panels/accessibility/AccessibilityStrings.ts +7 -3
- package/front_end/panels/accessibility/accessibilityNode.css +4 -4
- package/front_end/panels/accessibility/accessibilityProperties.css +1 -1
- package/front_end/panels/accessibility/accessibilitySidebarView.css +2 -2
- package/front_end/panels/accessibility/axBreadcrumbs.css +13 -13
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +14 -14
- package/front_end/panels/ai_assistance/ExternalHandler.ts +1 -1
- package/front_end/panels/ai_assistance/aiAssistancePanel.css +1 -1
- package/front_end/panels/ai_assistance/components/AIv2MarkdownRenderer.ts +2 -2
- package/front_end/panels/ai_assistance/components/AccessibilityAgentMarkdownRenderer.ts +1 -3
- package/front_end/panels/ai_assistance/components/ChatInput.ts +3 -2
- package/front_end/panels/ai_assistance/components/ChatView.ts +1 -1
- package/front_end/panels/ai_assistance/components/DisabledWidget.ts +1 -1
- package/front_end/panels/ai_assistance/components/ExploreWidget.ts +1 -1
- package/front_end/panels/ai_assistance/components/chatInput.css +12 -12
- package/front_end/panels/ai_assistance/components/chatMessage.css +16 -16
- package/front_end/panels/ai_assistance/components/chatView.css +2 -2
- package/front_end/panels/ai_assistance/components/exploreWidget.css +1 -1
- package/front_end/panels/ai_assistance/components/exportForAgentsDialog.css +4 -0
- package/front_end/panels/ai_assistance/components/walkthroughView.css +6 -6
- package/front_end/panels/animation/AnimationGroupPreviewUI.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/animation/animationTimeline.css +62 -62
- package/front_end/panels/application/AppManifestView.ts +6 -2
- package/front_end/panels/application/ApplicationPanelSidebar.ts +8 -5
- package/front_end/panels/application/BackgroundServiceView.ts +290 -252
- package/front_end/panels/application/BounceTrackingMitigationsTreeElement.ts +1 -1
- package/front_end/panels/application/FrameDetailsView.ts +1 -1
- package/front_end/panels/application/IndexedDBViews.ts +3 -2
- package/front_end/panels/application/ReportingApiTreeElement.ts +1 -1
- package/front_end/panels/application/ReportingApiView.ts +2 -2
- package/front_end/panels/application/ServiceWorkerUpdateCycleView.ts +1 -1
- package/front_end/panels/application/ServiceWorkersView.ts +1 -1
- package/front_end/panels/application/StorageBucketsTreeElement.ts +1 -1
- package/front_end/panels/application/StorageItemsToolbar.ts +6 -2
- package/front_end/panels/application/StorageView.ts +9 -8
- package/front_end/panels/application/TrustTokensTreeElement.ts +1 -1
- package/front_end/panels/application/WebMCPView.ts +17 -8
- package/front_end/panels/application/appManifestView.css +5 -5
- package/front_end/panels/application/backgroundServiceView.css +18 -2
- package/front_end/panels/application/components/AdsView.ts +100 -4
- package/front_end/panels/application/components/BounceTrackingMitigationsView.ts +1 -1
- package/front_end/panels/application/components/CrashReportContextGrid.ts +1 -1
- package/front_end/panels/application/components/EndpointsGrid.ts +1 -1
- package/front_end/panels/application/components/ReportsGrid.ts +1 -1
- package/front_end/panels/application/components/TrustTokensView.ts +1 -1
- package/front_end/panels/application/components/adsView.css +8 -5
- package/front_end/panels/application/components/backForwardCacheView.css +5 -5
- package/front_end/panels/application/components/bounceTrackingMitigationsView.css +1 -1
- package/front_end/panels/application/components/endpointsGrid.css +1 -1
- package/front_end/panels/application/components/permissionsPolicySection.css +1 -1
- package/front_end/panels/application/components/protocolHandlersView.css +6 -6
- package/front_end/panels/application/components/reportsGrid.css +1 -1
- package/front_end/panels/application/components/serviceWorkerRouterView.css +4 -4
- package/front_end/panels/application/components/trustTokensView.css +7 -7
- package/front_end/panels/application/cookieItemsView.css +3 -3
- package/front_end/panels/application/deviceBoundSessionsView.css +3 -3
- package/front_end/panels/application/frameDetailsReportView.css +11 -11
- package/front_end/panels/application/indexedDBViews.css +7 -7
- package/front_end/panels/application/originTrialTokenRows.css +2 -2
- package/front_end/panels/application/originTrialTreeView.css +3 -3
- package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +1 -1
- package/front_end/panels/application/preloading/components/PreloadingGrid.ts +1 -1
- package/front_end/panels/application/preloading/components/RuleSetDetailsView.css +2 -2
- package/front_end/panels/application/preloading/components/RuleSetGrid.ts +7 -2
- package/front_end/panels/application/preloading/components/preloadingDetailsReportView.css +1 -1
- package/front_end/panels/application/preloading/components/preloadingDisabledInfobar.css +2 -2
- package/front_end/panels/application/preloading/components/preloadingGrid.css +2 -2
- package/front_end/panels/application/preloading/components/usedPreloadingView.css +7 -7
- package/front_end/panels/application/preloading/preloadingView.css +1 -1
- package/front_end/panels/application/preloading/preloadingViewDropDown.css +3 -3
- package/front_end/panels/application/serviceWorkerCacheViews.css +5 -5
- package/front_end/panels/application/serviceWorkerUpdateCycleView.css +14 -12
- package/front_end/panels/application/serviceWorkersView.css +15 -16
- package/front_end/panels/application/storageView.css +5 -5
- package/front_end/panels/application/webMCPView.css +9 -9
- package/front_end/panels/autofill/AutofillView.ts +2 -2
- package/front_end/panels/autofill/autofillView.css +4 -4
- package/front_end/panels/browser_debugger/CategorizedBreakpointsSidebarPane.ts +2 -3
- package/front_end/panels/browser_debugger/DOMBreakpointsSidebarPane.ts +1 -1
- package/front_end/panels/browser_debugger/categorizedBreakpointsSidebarPane.css +4 -4
- package/front_end/panels/browser_debugger/domBreakpointsSidebarPane.css +5 -3
- package/front_end/panels/browser_debugger/xhrBreakpointsSidebarPane.css +4 -4
- package/front_end/panels/changes/ChangesSidebar.ts +56 -15
- package/front_end/panels/changes/ChangesView.ts +1 -1
- package/front_end/panels/changes/changesSidebar.css +1 -1
- package/front_end/panels/changes/changesView.css +1 -1
- package/front_end/panels/changes/combinedDiffView.css +1 -1
- package/front_end/panels/common/CPUThrottlingOption.ts +5 -10
- package/front_end/panels/common/badgeNotification.css +2 -2
- package/front_end/panels/common/domLinkifier.css +1 -1
- package/front_end/panels/common/gdpSignUpDialog.css +3 -3
- package/front_end/panels/common/geminiRebrandPromoDialog.css +1 -1
- package/front_end/panels/console/ConsolePrompt.ts +12 -5
- package/front_end/panels/console/ConsoleSidebar.ts +6 -2
- package/front_end/panels/console/ConsoleView.ts +6 -3
- package/front_end/panels/console/ConsoleViewMessage.ts +3 -1
- package/front_end/panels/console/console-meta.ts +5 -24
- package/front_end/panels/console/consoleContextSelector.css +2 -2
- package/front_end/panels/console/consolePinPane.css +9 -9
- package/front_end/panels/console/consolePrompt.css +5 -5
- package/front_end/panels/console/consoleView.css +39 -39
- package/front_end/panels/coverage/coverageListView.css +2 -2
- package/front_end/panels/css_overview/cssOverviewCompletedView.css +34 -34
- package/front_end/panels/css_overview/cssOverviewProcessingView.css +5 -5
- package/front_end/panels/css_overview/cssOverviewSidebarPanel.css +1 -1
- package/front_end/panels/css_overview/cssOverviewStartView.css +17 -17
- package/front_end/panels/elements/AdoptedStyleSheetTreeElement.ts +209 -62
- package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +4 -4
- package/front_end/panels/elements/DOMTreeContextMenu.ts +59 -54
- package/front_end/panels/elements/ElementsPanel.ts +1 -1
- package/front_end/panels/elements/ElementsTreeElement.ts +142 -94
- package/front_end/panels/elements/ElementsTreeOutline.ts +2132 -472
- package/front_end/panels/elements/PropertyRenderer.ts +22 -15
- package/front_end/panels/elements/ShortcutTreeElement.ts +6 -3
- package/front_end/panels/elements/StandaloneStylesContainer.ts +6 -2
- package/front_end/panels/elements/StylePropertiesSection.ts +65 -8
- package/front_end/panels/elements/StylePropertyTreeElement.ts +81 -26
- package/front_end/panels/elements/StylesSidebarPane.ts +149 -10
- package/front_end/panels/elements/classesPaneWidget.css +6 -6
- package/front_end/panels/elements/components/stylePropertyEditor.css +7 -7
- package/front_end/panels/elements/computedStyleWidget.css +1 -1
- package/front_end/panels/elements/elementStatePaneWidget.css +8 -8
- package/front_end/panels/elements/elements-meta.ts +14 -0
- package/front_end/panels/elements/elementsPanel.css +4 -4
- package/front_end/panels/elements/elementsTreeOutline.css +226 -38
- package/front_end/panels/elements/layersWidget.css +4 -4
- package/front_end/panels/elements/layoutPane.css +18 -18
- package/front_end/panels/elements/metricsSidebarPane.css +11 -11
- package/front_end/panels/elements/platformFontsWidget.css +5 -5
- package/front_end/panels/elements/propertiesWidget.css +2 -2
- package/front_end/panels/elements/stylePropertiesTreeOutline.css +20 -20
- package/front_end/panels/elements/stylesSidebarPane.css +37 -20
- package/front_end/panels/emulation/DeviceModeView.ts +6 -1
- package/front_end/panels/emulation/InspectedPagePlaceholder.ts +6 -2
- package/front_end/panels/emulation/deviceModeView.css +49 -49
- package/front_end/panels/emulation/mediaQueryInspector.css +18 -18
- package/front_end/panels/event_listeners/eventListenersView.css +1 -1
- package/front_end/panels/explain/components/consoleInsight.css +29 -29
- package/front_end/panels/issues/components/elementsPanelLink.css +2 -2
- package/front_end/panels/issues/components/hideIssuesMenu.css +1 -1
- package/front_end/panels/issues/issuesPane.css +2 -2
- package/front_end/panels/issues/issuesTree.css +50 -50
- package/front_end/panels/layer_viewer/LayerDetailsView.ts +6 -2
- package/front_end/panels/layer_viewer/LayerTreeOutline.ts +7 -2
- package/front_end/panels/layer_viewer/Layers3DView.ts +17 -11
- package/front_end/panels/layer_viewer/PaintProfilerView.ts +6 -2
- package/front_end/panels/layer_viewer/layerDetailsView.css +1 -1
- package/front_end/panels/layer_viewer/layerTreeOutline.css +2 -2
- package/front_end/panels/layer_viewer/layers3DView.css +1 -1
- package/front_end/panels/layer_viewer/paintProfiler.css +1 -1
- package/front_end/panels/lighthouse/LighthouseReportSelector.ts +2 -2
- package/front_end/panels/lighthouse/lighthousePanel.css +5 -5
- package/front_end/panels/lighthouse/lighthouseStartView.css +13 -13
- package/front_end/panels/linear_memory_inspector/LinearMemoryInspectorPane.ts +6 -2
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +6 -2
- package/front_end/panels/media/playerListView.css +9 -9
- package/front_end/panels/media/playerMessagesView.css +8 -8
- package/front_end/panels/media/playerPropertiesView.css +6 -6
- package/front_end/panels/mobile_throttling/NetworkPanelIndicator.ts +1 -1
- package/front_end/panels/mobile_throttling/NetworkThrottlingSelector.ts +6 -2
- package/front_end/panels/mobile_throttling/ThrottlingManager.ts +25 -54
- package/front_end/panels/mobile_throttling/throttlingSettingsTab.css +9 -9
- package/front_end/panels/network/NetworkDataGridNode.ts +1 -0
- package/front_end/panels/network/NetworkLogView.ts +8 -3
- package/front_end/panels/network/NetworkPanel.ts +9 -4
- package/front_end/panels/network/RequestConditionsDrawer.ts +12 -12
- package/front_end/panels/network/RequestPayloadView.ts +78 -26
- package/front_end/panels/network/binaryResourceView.css +1 -1
- package/front_end/panels/network/components/EditableSpan.css +3 -3
- package/front_end/panels/network/components/HeaderSectionRow.css +14 -14
- package/front_end/panels/network/components/RequestHeaderSection.css +7 -7
- package/front_end/panels/network/components/RequestHeadersView.css +23 -18
- package/front_end/panels/network/components/RequestTrustTokensView.css +1 -1
- package/front_end/panels/network/network-meta.ts +9 -9
- package/front_end/panels/network/networkConfigView.css +11 -11
- package/front_end/panels/network/networkLogView.css +39 -35
- package/front_end/panels/network/networkManageCustomHeadersView.css +1 -1
- package/front_end/panels/network/networkPanel.css +7 -7
- package/front_end/panels/network/networkTimingTable.css +13 -13
- package/front_end/panels/network/requestConditionsDrawer.css +4 -4
- package/front_end/panels/network/requestCookiesView.css +5 -5
- package/front_end/panels/network/requestDeviceBoundSessionsView.css +1 -1
- package/front_end/panels/network/requestHTMLView.css +1 -1
- package/front_end/panels/network/requestHeadersTree.css +19 -19
- package/front_end/panels/network/requestInitiatorView.css +1 -1
- package/front_end/panels/network/requestInitiatorViewTree.css +5 -3
- package/front_end/panels/network/requestPayloadTree.css +5 -5
- package/front_end/panels/network/requestPayloadView.css +1 -1
- package/front_end/panels/network/resourceChunkView.css +3 -3
- package/front_end/panels/network/signedExchangeInfoTree.css +6 -6
- package/front_end/panels/performance_monitor/performanceMonitor.css +3 -3
- package/front_end/panels/profiler/HeapDetachedElementsView.ts +7 -2
- package/front_end/panels/profiler/HeapProfileView.ts +7 -2
- package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +8 -4
- package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +8 -4
- package/front_end/panels/profiler/HeapSnapshotView.ts +15 -6
- package/front_end/panels/profiler/HeapTimelineOverview.ts +6 -2
- package/front_end/panels/profiler/ProfileFlameChartDataProvider.ts +12 -5
- package/front_end/panels/profiler/ProfileLauncherView.ts +6 -2
- package/front_end/panels/profiler/heapProfiler.css +15 -15
- package/front_end/panels/profiler/profileLauncherView.css +10 -10
- package/front_end/panels/profiler/profilesPanel.css +8 -9
- package/front_end/panels/profiler/profilesSidebarTree.css +13 -13
- package/front_end/panels/protocol_monitor/JSONEditor.css +2 -2
- package/front_end/panels/protocol_monitor/JSONEditor.ts +6 -1
- package/front_end/panels/protocol_monitor/protocolMonitor.css +2 -2
- package/front_end/panels/recorder/RecordingView.ts +1 -1
- package/front_end/panels/recorder/StepEditor.ts +86 -7
- package/front_end/panels/recorder/TimelineSection.ts +2 -1
- package/front_end/panels/recorder/createRecordingView.css +17 -17
- package/front_end/panels/recorder/extensionView.css +5 -5
- package/front_end/panels/recorder/injected/RecordingClient.ts +1 -1
- package/front_end/panels/recorder/models/SchemaUtils.ts +2 -2
- package/front_end/panels/recorder/models/ScreenshotStorage.ts +1 -1
- package/front_end/panels/recorder/recorderPanel.css +7 -7
- package/front_end/panels/recorder/recordingListView.css +12 -12
- package/front_end/panels/recorder/recordingView.css +47 -47
- package/front_end/panels/recorder/stepEditor.css +2 -2
- package/front_end/panels/recorder/stepView.css +20 -20
- package/front_end/panels/recorder/timelineSection.css +9 -9
- package/front_end/panels/screencast/screencastView.css +12 -12
- package/front_end/panels/search/searchResultsPane.css +10 -10
- package/front_end/panels/search/searchView.css +9 -9
- package/front_end/panels/security/SecurityPanel.ts +84 -54
- package/front_end/panels/security/mainView.css +26 -26
- package/front_end/panels/security/originView.css +15 -15
- package/front_end/panels/sensors/locationsSettingsTab.css +6 -6
- package/front_end/panels/sensors/sensors.css +28 -28
- package/front_end/panels/settings/components/syncSection.css +5 -5
- package/front_end/panels/settings/emulation/components/userAgentClientHintsForm.css +13 -13
- package/front_end/panels/settings/emulation/devicesSettingsTab.css +16 -16
- package/front_end/panels/settings/frameworkIgnoreListSettingsTab.css +2 -2
- package/front_end/panels/settings/keybindsSettingsTab.css +2 -2
- package/front_end/panels/settings/settingsScreen.css +5 -5
- package/front_end/panels/sources/SourcesView.ts +7 -2
- package/front_end/panels/sources/TabbedEditorContainer.ts +6 -2
- package/front_end/panels/sources/UISourceCodeFrame.ts +11 -4
- package/front_end/panels/sources/breakpointEditDialog.css +9 -9
- package/front_end/panels/sources/breakpointsView.css +25 -25
- package/front_end/panels/sources/callStackSidebarPane.css +10 -10
- package/front_end/panels/sources/components/HeadersView.css +6 -6
- package/front_end/panels/sources/debuggerPausedMessage.css +4 -4
- package/front_end/panels/sources/dialog.css +2 -2
- package/front_end/panels/sources/navigatorTree.css +2 -2
- package/front_end/panels/sources/navigatorView.css +2 -2
- package/front_end/panels/sources/scopeChainSidebarPane.css +1 -1
- package/front_end/panels/sources/sourcesNavigator.css +1 -1
- package/front_end/panels/sources/sourcesPanel.css +2 -2
- package/front_end/panels/sources/sourcesView.css +1 -1
- package/front_end/panels/sources/threadsSidebarPane.css +5 -5
- package/front_end/panels/sources/watchExpressionsSidebarPane.css +8 -8
- package/front_end/panels/timeline/AnimationsTrackAppender.ts +1 -1
- package/front_end/panels/timeline/AnnotationHelpers.ts +9 -9
- package/front_end/panels/timeline/CountersGraph.ts +8 -8
- package/front_end/panels/timeline/EventsTimelineTreeView.ts +3 -3
- package/front_end/panels/timeline/ExtensionTrackAppender.ts +1 -1
- package/front_end/panels/timeline/GPUTrackAppender.ts +1 -1
- package/front_end/panels/timeline/InteractionsTrackAppender.ts +1 -1
- package/front_end/panels/timeline/IsolateSelector.ts +2 -2
- package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +3 -3
- package/front_end/panels/timeline/NetworkTrackAppender.ts +1 -1
- package/front_end/panels/timeline/StatusDialog.ts +5 -6
- package/front_end/panels/timeline/ThirdPartyTreeView.ts +4 -4
- package/front_end/panels/timeline/ThreadAppender.ts +12 -14
- package/front_end/panels/timeline/TimelineController.ts +5 -8
- package/front_end/panels/timeline/TimelineDetailsView.ts +22 -30
- package/front_end/panels/timeline/TimelineEventOverview.ts +4 -4
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +17 -17
- package/front_end/panels/timeline/TimelineFlameChartView.ts +11 -8
- package/front_end/panels/timeline/TimelineHistoryManager.ts +8 -8
- package/front_end/panels/timeline/TimelineLoader.ts +1 -1
- package/front_end/panels/timeline/TimelineMiniMap.ts +10 -5
- package/front_end/panels/timeline/TimelinePanel.ts +57 -59
- package/front_end/panels/timeline/TimelineSelectorStatsView.ts +27 -27
- package/front_end/panels/timeline/TimelineTreeView.ts +46 -44
- package/front_end/panels/timeline/TimelineUIUtils.ts +142 -116
- package/front_end/panels/timeline/TimingsTrackAppender.ts +1 -1
- package/front_end/panels/timeline/TrackConfigBanner.ts +4 -4
- package/front_end/panels/timeline/UIDevtoolsUtils.ts +15 -15
- package/front_end/panels/timeline/components/LiveMetricsView.ts +1 -1
- package/front_end/panels/timeline/components/breadcrumbsUI.css +3 -3
- package/front_end/panels/timeline/components/exportTraceOptions.css +1 -1
- package/front_end/panels/timeline/components/fieldSettingsDialog.css +13 -13
- package/front_end/panels/timeline/components/ignoreListSetting.css +3 -3
- package/front_end/panels/timeline/components/insights/Table.ts +1 -1
- package/front_end/panels/timeline/components/liveMetricsView.css +39 -39
- package/front_end/panels/timeline/components/metricCard.css +20 -20
- package/front_end/panels/timeline/components/networkRequestDetails.css +9 -9
- package/front_end/panels/timeline/components/networkRequestTooltip.css +14 -14
- package/front_end/panels/timeline/components/networkTrackWidget.css +2 -2
- package/front_end/panels/timeline/components/originMap.css +4 -4
- package/front_end/panels/timeline/components/relatedInsightChips.css +1 -1
- package/front_end/panels/timeline/components/sidebarAnnotationsTab.css +4 -4
- package/front_end/panels/timeline/components/sidebarInsightsTab.css +5 -5
- package/front_end/panels/timeline/components/sidebarSingleInsightSet.css +1 -1
- package/front_end/panels/timeline/components/timelineSummary.css +4 -4
- package/front_end/panels/timeline/enable-easter-egg.js +1 -1
- package/front_end/panels/timeline/overlays/OverlaysImpl.ts +4 -4
- package/front_end/panels/timeline/overlays/components/EntriesLinkOverlay.ts +1 -1
- package/front_end/panels/timeline/overlays/components/EntryLabelOverlay.ts +6 -6
- package/front_end/panels/timeline/overlays/components/TimeRangeOverlay.ts +1 -1
- package/front_end/panels/timeline/thirdPartyTreeView.css +5 -5
- package/front_end/panels/timeline/timeline-meta.ts +30 -36
- package/front_end/panels/timeline/timelineDetailsView.css +11 -11
- package/front_end/panels/timeline/timelineFlameChartView.css +10 -10
- package/front_end/panels/timeline/timelineFlamechartPopover.css +5 -5
- package/front_end/panels/timeline/timelineHistoryManager.css +7 -7
- package/front_end/panels/timeline/timelinePaintProfiler.css +2 -2
- package/front_end/panels/timeline/timelinePanel.css +20 -20
- package/front_end/panels/timeline/timelineTreeView.css +8 -8
- package/front_end/panels/timeline/utils/IgnoreList.ts +4 -4
- package/front_end/panels/webauthn/webauthnPane.css +6 -6
- package/front_end/panels/whats_new/ReleaseNoteText.ts +2 -2
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/i18n/i18n-impl.ts +1 -1
- package/front_end/third_party/puppeteer/README.chromium +2 -2
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +15 -1
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +42 -8
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Frame.d.ts +4 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Frame.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Frame.js +15 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Frame.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/WebMCP.d.ts +14 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/WebMCP.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/WebMCP.js +23 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/WebMCP.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/generated/injected.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/generated/injected.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/generated/injected.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/generated/injected.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/injected/Poller.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/injected/Poller.js +77 -6
- package/front_end/third_party/puppeteer/package/lib/puppeteer/injected/Poller.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.d.ts +3 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.js +3 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/types.d.ts +15 -1
- package/front_end/third_party/puppeteer/package/package.json +2 -2
- package/front_end/third_party/puppeteer/package/src/cdp/Frame.ts +16 -2
- package/front_end/third_party/puppeteer/package/src/cdp/WebMCP.ts +36 -1
- package/front_end/third_party/puppeteer/package/src/generated/injected.ts +1 -1
- package/front_end/third_party/puppeteer/package/src/injected/Poller.ts +86 -6
- package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
- package/front_end/third_party/puppeteer/package/src/util/version.ts +1 -1
- package/front_end/third_party/web-vitals/README.chromium +2 -2
- package/front_end/third_party/web-vitals/package/README.md +22 -7
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.js +6 -2
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.d.ts +2 -2
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.js +30 -3
- package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.d.ts +14 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.js +19 -13
- package/front_end/third_party/web-vitals/package/dist/modules/lib/bindReporter.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/doubleRAF.js +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.d.ts +3 -3
- package/front_end/third_party/web-vitals/package/dist/modules/lib/softNavs.js +3 -1
- package/front_end/third_party/web-vitals/package/dist/modules/types/lcp.d.ts +15 -1
- package/front_end/third_party/web-vitals/package/package.json +1 -2
- package/front_end/third_party/web-vitals/package/src/attribution/onINP.ts +9 -2
- package/front_end/third_party/web-vitals/package/src/attribution/onLCP.ts +36 -5
- package/front_end/third_party/web-vitals/package/src/lib/InteractionManager.ts +21 -15
- package/front_end/third_party/web-vitals/package/src/lib/doubleRAF.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/lib/softNavs.ts +4 -1
- package/front_end/third_party/web-vitals/package/src/types/lcp.ts +16 -1
- package/front_end/third_party/web-vitals/rebuild.sh +3 -3
- package/front_end/ui/comments/CommentAnchorResolver.ts +26 -6
- package/front_end/ui/comments/CommentOverlayManager.ts +9 -1
- package/front_end/ui/comments/commentsOverlay.css +6 -5
- package/front_end/ui/components/adorners/Adorner.ts +1 -1
- package/front_end/ui/components/adorners/adorner.css +6 -6
- package/front_end/ui/components/buttons/Button.docs.ts +1 -1
- package/front_end/ui/components/buttons/FloatingButton.ts +1 -1
- package/front_end/ui/components/buttons/button.css +30 -9
- package/front_end/ui/components/buttons/floatingButton.css +2 -2
- package/front_end/ui/components/buttons/textButton.css +12 -12
- package/front_end/ui/components/dialogs/Dialog.ts +1 -1
- package/front_end/ui/components/dialogs/dialog.css +1 -1
- package/front_end/ui/components/diff_view/diffView.css +3 -3
- package/front_end/ui/components/expandable_list/expandableList.css +9 -9
- package/front_end/ui/components/highlighting/HighlightElement.ts +1 -1
- package/front_end/ui/components/highlighting/HighlightManager.ts +4 -0
- package/front_end/ui/components/icon_button/iconButton.css +2 -2
- package/front_end/ui/components/input/checkbox.css +8 -8
- package/front_end/ui/components/input/textInput.css +3 -3
- package/front_end/ui/components/issue_counter/issueLinkIcon.css +2 -2
- package/front_end/ui/components/linkifier/linkifierImpl.css +1 -1
- package/front_end/ui/components/markdown_view/MarkdownImagesMap.ts +1 -1
- package/front_end/ui/components/markdown_view/MarkdownLinksMap.ts +1 -1
- package/front_end/ui/components/markdown_view/codeBlock.css +2 -2
- package/front_end/ui/components/markdown_view/markdownView.css +7 -7
- package/front_end/ui/components/menus/menuGroup.css +2 -2
- package/front_end/ui/components/menus/menuItem.css +2 -2
- package/front_end/ui/components/menus/selectMenu.css +2 -2
- package/front_end/ui/components/menus/selectMenuButton.css +4 -4
- package/front_end/ui/components/panel_feedback/panelFeedback.css +15 -15
- package/front_end/ui/components/panel_feedback/previewToggle.css +2 -2
- package/front_end/ui/components/panel_introduction_steps/panelIntroductionSteps.css +7 -7
- package/front_end/ui/components/report_view/ReportView.docs.ts +1 -1
- package/front_end/ui/components/report_view/report.css +3 -3
- package/front_end/ui/components/report_view/reportSectionDivider.css +1 -1
- package/front_end/ui/components/report_view/reportValue.css +1 -1
- package/front_end/ui/components/request_link_icon/requestLinkIcon.css +2 -2
- package/front_end/ui/components/settings/settingCheckbox.css +6 -6
- package/front_end/ui/components/snackbars/Snackbars.docs.ts +1 -1
- package/front_end/ui/components/spinners/Spinner.ts +1 -1
- package/front_end/ui/components/spinners/Spinners.docs.ts +1 -1
- package/front_end/ui/components/suggestion_input/SuggestionInput.ts +1 -2
- package/front_end/ui/components/switch/Switch.docs.ts +1 -1
- package/front_end/ui/components/text_editor/AiCodeCompletionProvider.ts +10 -8
- package/front_end/ui/components/text_editor/AiCodeGenerationProvider.ts +2 -1
- package/front_end/ui/components/text_editor/ExecutionPositionHighlighter.ts +2 -2
- package/front_end/ui/components/text_editor/TextEditor.ts +22 -1
- package/front_end/ui/components/text_editor/config.ts +125 -100
- package/front_end/ui/components/text_editor/cursor_tooltip.ts +1 -1
- package/front_end/ui/components/text_editor/theme.ts +1 -1
- package/front_end/ui/components/tooltips/Tooltip.docs.ts +1 -1
- package/front_end/ui/components/tooltips/Tooltip.ts +1 -1
- package/front_end/ui/components/tree_outline/TreeOutlineUtils.ts +4 -1
- package/front_end/ui/kit/cards/Card.ts +1 -1
- package/front_end/ui/kit/icons/Icon.ts +1 -1
- package/front_end/ui/kit/icons/icon.css +4 -4
- package/front_end/ui/kit/link/Link.docs.ts +1 -1
- package/front_end/ui/kit/link/Link.ts +1 -1
- package/front_end/ui/kit/link/link.css +1 -1
- package/front_end/ui/legacy/ActionRegistration.ts +23 -23
- package/front_end/ui/legacy/ContextMenu.docs.ts +1 -1
- package/front_end/ui/legacy/Dialog.ts +11 -3
- package/front_end/ui/legacy/DockController.ts +3 -3
- package/front_end/ui/legacy/EmptyWidget.ts +13 -34
- package/front_end/ui/legacy/FilterBar.ts +10 -5
- package/front_end/ui/legacy/Infobar.ts +2 -2
- package/front_end/ui/legacy/InspectorDrawerView.ts +6 -6
- package/front_end/ui/legacy/InspectorView.ts +19 -26
- package/front_end/ui/legacy/ListWidget.ts +7 -7
- package/front_end/ui/legacy/PlusButton.ts +1 -3
- package/front_end/ui/legacy/RadioButton.docs.ts +1 -1
- package/front_end/ui/legacy/RemoteDebuggingTerminatedScreen.ts +6 -6
- package/front_end/ui/legacy/SearchableView.ts +16 -16
- package/front_end/ui/legacy/SelectMenu.docs.ts +1 -1
- package/front_end/ui/legacy/Slider.docs.ts +1 -1
- package/front_end/ui/legacy/SoftContextMenu.ts +8 -8
- package/front_end/ui/legacy/SoftDropDown.ts +1 -1
- package/front_end/ui/legacy/SplitWidget.ts +5 -1
- package/front_end/ui/legacy/SuggestBox.ts +2 -2
- package/front_end/ui/legacy/TabbedPane.ts +15 -11
- package/front_end/ui/legacy/TargetCrashedScreen.ts +2 -2
- package/front_end/ui/legacy/Toolbar.ts +5 -5
- package/front_end/ui/legacy/Treeoutline.ts +1 -1
- package/front_end/ui/legacy/UIUtils.ts +80 -20
- package/front_end/ui/legacy/ViewManager.ts +1 -1
- package/front_end/ui/legacy/ViewRegistration.ts +7 -7
- package/front_end/ui/legacy/Widget.ts +5 -5
- package/front_end/ui/legacy/checkboxTextLabel.css +3 -3
- package/front_end/ui/legacy/components/color_picker/ColorFormatSpec.ts +16 -0
- package/front_end/ui/legacy/components/color_picker/FormatPickerContextMenu.ts +1 -0
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +6 -1
- package/front_end/ui/legacy/components/color_picker/spectrum.css +90 -90
- package/front_end/ui/legacy/components/cookie_table/cookiesTable.css +1 -1
- package/front_end/ui/legacy/components/data_grid/DataGrid.ts +26 -28
- package/front_end/ui/legacy/components/data_grid/ShowMoreDataGridNode.ts +3 -7
- package/front_end/ui/legacy/components/data_grid/ViewportDataGrid.ts +6 -2
- package/front_end/ui/legacy/components/inline_editor/BezierEditor.ts +6 -1
- package/front_end/ui/legacy/components/inline_editor/CSSShadowEditor.ts +6 -2
- package/front_end/ui/legacy/components/inline_editor/bezierEditor.css +13 -13
- package/front_end/ui/legacy/components/inline_editor/colorSwatch.css +7 -7
- package/front_end/ui/legacy/components/inline_editor/cssAngleEditor.css +5 -5
- package/front_end/ui/legacy/components/inline_editor/cssShadowEditor.css +18 -18
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +104 -86
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +8 -6
- package/front_end/ui/legacy/components/object_ui/objectPopover.css +4 -4
- package/front_end/ui/legacy/components/object_ui/objectPropertiesSection.css +8 -6
- package/front_end/ui/legacy/components/perf_ui/ChartViewport.ts +28 -11
- package/front_end/ui/legacy/components/perf_ui/FilmStripView.ts +6 -1
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +6 -2
- package/front_end/ui/legacy/components/perf_ui/TimelineOverviewPane.ts +8 -8
- package/front_end/ui/legacy/components/perf_ui/chartViewport.css +4 -4
- package/front_end/ui/legacy/components/perf_ui/filmStripView.css +6 -6
- package/front_end/ui/legacy/components/perf_ui/flameChart.css +7 -7
- package/front_end/ui/legacy/components/perf_ui/overviewGrid.css +11 -11
- package/front_end/ui/legacy/components/perf_ui/pieChart.css +6 -6
- package/front_end/ui/legacy/components/perf_ui/timelineGrid.css +5 -5
- package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +8 -3
- package/front_end/ui/legacy/components/quick_open/QuickOpen.ts +6 -1
- package/front_end/ui/legacy/components/quick_open/filteredListWidget.css +3 -3
- package/front_end/ui/legacy/components/source_frame/ResourceSourceFrame.ts +1 -1
- package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +7 -2
- package/front_end/ui/legacy/components/source_frame/imageView.css +1 -1
- package/front_end/ui/legacy/components/source_frame/jsonView.css +1 -1
- package/front_end/ui/legacy/components/source_frame/resourceSourceFrame.css +1 -1
- package/front_end/ui/legacy/components/source_frame/xmlTree.css +3 -3
- package/front_end/ui/legacy/components/utils/imagePreview.css +1 -1
- package/front_end/ui/legacy/components/utils/jsUtils.css +10 -10
- package/front_end/ui/legacy/dropTarget.css +2 -2
- package/front_end/ui/legacy/emptyWidget.css +6 -0
- package/front_end/ui/legacy/filter.css +19 -19
- package/front_end/ui/legacy/infobar.css +2 -2
- package/front_end/ui/legacy/inspectorCommon.css +67 -67
- package/front_end/ui/legacy/inspectorDrawerTabbedPane.css +1 -1
- package/front_end/ui/legacy/listWidget.css +5 -5
- package/front_end/ui/legacy/progressIndicator.css +4 -4
- package/front_end/ui/legacy/reportView.css +7 -7
- package/front_end/ui/legacy/searchableView.css +5 -5
- package/front_end/ui/legacy/smallBubble.css +3 -3
- package/front_end/ui/legacy/softContextMenu.css +4 -4
- package/front_end/ui/legacy/softDropDownButton.css +1 -1
- package/front_end/ui/legacy/splitWidget.css +9 -31
- package/front_end/ui/legacy/suggestBox.css +4 -4
- package/front_end/ui/legacy/tabbedPane.css +17 -17
- package/front_end/ui/legacy/textPrompt.css +2 -2
- package/front_end/ui/legacy/toolbar.css +4 -4
- package/front_end/ui/legacy/treeoutline.css +14 -14
- package/front_end/ui/legacy/viewContainers.css +6 -6
- package/front_end/ui/settings/ConsoleSettings.ts +34 -0
- package/front_end/ui/visual_logging/KnownContextValues.ts +12 -0
- package/inspector_overlay/common.ts +12 -12
- package/inspector_overlay/css_grid_label_helpers.ts +16 -17
- package/inspector_overlay/drag_resize_handler.ts +2 -2
- package/inspector_overlay/highlight_common.ts +11 -13
- package/inspector_overlay/highlight_container_query.ts +2 -2
- package/inspector_overlay/highlight_flex_common.ts +6 -7
- package/inspector_overlay/highlight_grid_common.ts +3 -3
- package/inspector_overlay/highlight_isolated_element.ts +12 -3
- package/inspector_overlay/highlight_scroll_snap.ts +2 -2
- package/inspector_overlay/loadCSS.rollup.js +0 -1
- package/inspector_overlay/testing/InspectorOverlayHelpers.ts +13 -13
- package/inspector_overlay/tool_green_dev_anchors.ts +3 -3
- package/inspector_overlay/tool_highlight.ts +9 -9
- package/inspector_overlay/tool_paused.ts +4 -4
- package/inspector_overlay/tool_persistent.ts +11 -11
- package/inspector_overlay/tool_screenshot.ts +7 -7
- package/inspector_overlay/tool_source_order.ts +4 -4
- package/inspector_overlay/tool_viewport_size.ts +3 -3
- package/inspector_overlay/tool_window_controls.ts +4 -4
- package/mcp/mcp.ts +1 -0
- package/package.json +3 -3
- package/front_end/generated/protocol-tsconfig.json +0 -10
- package/front_end/panels/js_timeline/DIR_METADATA +0 -3
- package/front_end/panels/js_timeline/js_timeline-meta.ts +0 -193
- package/front_end/panels/js_timeline/js_timeline.ts +0 -1
- /package/front_end/entrypoints/{formatter_worker/FormatterActions.ts → formatter_actions/formatter_actions.ts} +0 -0
|
@@ -20,6 +20,7 @@ import {type ExecuteJsAgentOptions, executeJsCode} from './agents/ExecuteJavascr
|
|
|
20
20
|
import {ChangeManager} from './ChangeManager.js';
|
|
21
21
|
import {AccessibilityContext} from './contexts/AccessibilityContext.js';
|
|
22
22
|
import {DOMNodeContext} from './contexts/DOMNodeContext.js';
|
|
23
|
+
import {PerformanceTraceContext} from './contexts/PerformanceTraceContext.js';
|
|
23
24
|
import {debugLog} from './debug.js';
|
|
24
25
|
import {ExtensionScope} from './ExtensionScope.js';
|
|
25
26
|
import type {Skill, SkillName} from './skills/Skill.js';
|
|
@@ -48,7 +49,7 @@ Your role is to help web developers debug, analyze, and optimize web application
|
|
|
48
49
|
# Workflow
|
|
49
50
|
1. **Analyze**: Understand the user's intent, the context provided, and what they are trying to achieve.
|
|
50
51
|
2. **Investigate**: Proactively use your learned skills and tools to gather live data. Do not make assumptions or guess without sufficient evidence.
|
|
51
|
-
3. **
|
|
52
|
+
3. **Diagnose**: Explore multiple potential explanations and solutions. Distinguish between the primary root cause and contributing factors.
|
|
52
53
|
4. **Respond**: Provide a structured, clear, and actionable response.
|
|
53
54
|
|
|
54
55
|
# Response Structure
|
|
@@ -58,9 +59,14 @@ If the user asks a question that requires an investigation or debugging, use thi
|
|
|
58
59
|
* **Suggestion(s)**: List actionable solution suggestion(s) in order of impact.
|
|
59
60
|
- Example: "**Suggestion**: [Suggestion]" or "**Suggestions**:" followed by a bulleted list.
|
|
60
61
|
|
|
62
|
+
# Follow-up Suggestions
|
|
63
|
+
* Output a list of suggested follow-up queries or actions for the user at the very end of your response.
|
|
64
|
+
* The format MUST be SUGGESTIONS: ["suggestion 1", "suggestion 2"] on its own single line.
|
|
65
|
+
* Ensure suggestions are relevant, concise, and helpful next steps for the user.
|
|
66
|
+
|
|
61
67
|
# Constraints
|
|
62
68
|
* **CRITICAL**: You are a web development assistant. NEVER provide answers to questions of unrelated topics (such as legal advice, financial advice, personal opinions, medical advice, religion, race, politics, sexuality, gender, or any other non-web-development topics). If asked about these, respond with: "Sorry, I can't answer that. I'm best at questions about web development and debugging."
|
|
63
|
-
* **CRITICAL**: Do not write
|
|
69
|
+
* **CRITICAL**: Do not write standalone scripts (such as Python or bash) or arbitrary code to interact with the environment. The only way to execute code in the inspected page is via the 'executeJavaScript' tool.
|
|
64
70
|
* **CRITICAL**: Do not expose raw, internal system identifiers (such as database IDs, internal node paths, or event keys) directly to the user. Use descriptive names instead.`;
|
|
65
71
|
|
|
66
72
|
export interface AiAgent2Options extends ExecuteJsAgentOptions {
|
|
@@ -70,9 +76,9 @@ export interface AiAgent2Options extends ExecuteJsAgentOptions {
|
|
|
70
76
|
|
|
71
77
|
export class AiAgent2 extends AiAgent<unknown> {
|
|
72
78
|
// TODO: The static preamble is a placeholder and will eventually live server-side.
|
|
73
|
-
readonly preamble = preamble;
|
|
74
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_DEVTOOLS_V2_AGENT;
|
|
75
|
-
readonly userTier = 'TESTERS';
|
|
79
|
+
readonly preamble: string = preamble;
|
|
80
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_DEVTOOLS_V2_AGENT;
|
|
81
|
+
readonly userTier: string = 'TESTERS';
|
|
76
82
|
|
|
77
83
|
#changes: ChangeManager;
|
|
78
84
|
#execJs: typeof executeJsCode;
|
|
@@ -128,7 +134,7 @@ export class AiAgent2 extends AiAgent<unknown> {
|
|
|
128
134
|
this.#declaredTools.add('learnSkills');
|
|
129
135
|
this.declareFunction<{skills: SkillName[]}>('learnSkills', {
|
|
130
136
|
description: () => {
|
|
131
|
-
const unloadedSkills = Object.keys(
|
|
137
|
+
const unloadedSkills = Object.keys(this.getSkills()).filter(name => !this.#activeSkills.has(name as SkillName));
|
|
132
138
|
return `Loads the specified skills to gain access to their specialized tools. Call this ONLY for skills listed under Available skills that are not yet loaded. Do not call this for skills that are already loaded. Available skills that are not yet loaded: ${
|
|
133
139
|
unloadedSkills.join(', ')}.`;
|
|
134
140
|
},
|
|
@@ -273,7 +279,6 @@ User query: ${enhancedQuery}`;
|
|
|
273
279
|
displayInfoFromArgs: tool.displayInfoFromArgs,
|
|
274
280
|
handler: (args, options) => {
|
|
275
281
|
const context: AllToolsCapabilities = {
|
|
276
|
-
conversationContext: this.context ?? null,
|
|
277
282
|
changeManager: this.#changes,
|
|
278
283
|
createExtensionScope: this.#createExtensionScope.bind(this),
|
|
279
284
|
execJs: this.#execJs,
|
|
@@ -283,6 +288,7 @@ User query: ${enhancedQuery}`;
|
|
|
283
288
|
getEstablishedOrigin: () => this.#getConversationOrigin(),
|
|
284
289
|
getLighthouseReport: () => (this.context instanceof AccessibilityContext ? this.context.getItem() : null),
|
|
285
290
|
runLighthouse: async overrides => await (this.#lighthouseRecording?.(overrides) ?? null),
|
|
291
|
+
getPerformanceTraceContext: () => (this.context instanceof PerformanceTraceContext ? this.context : null),
|
|
286
292
|
performanceRecordAndReload: this.#performanceRecordAndReload,
|
|
287
293
|
disableLogging: () => {
|
|
288
294
|
this.disableServerSideLogging();
|
|
@@ -31,6 +31,7 @@ import {StorageAgent} from './agents/StorageAgent.js';
|
|
|
31
31
|
import {StylingAgent} from './agents/StylingAgent.js';
|
|
32
32
|
import {AiAgent2} from './AiAgent2.js';
|
|
33
33
|
import {AiHistoryStorage, ConversationType, type SerializedConversation} from './AiHistoryStorage.js';
|
|
34
|
+
import {isContextSelectionEnabled} from './AiUtils.js';
|
|
34
35
|
import type {ChangeManager} from './ChangeManager.js';
|
|
35
36
|
import {AccessibilityContext} from './contexts/AccessibilityContext.js';
|
|
36
37
|
import {DOMNodeContext} from './contexts/DOMNodeContext.js';
|
|
@@ -106,7 +107,7 @@ export class AiConversation {
|
|
|
106
107
|
|
|
107
108
|
#aidaClient: Host.AidaClient.AidaClient;
|
|
108
109
|
#changeManager: ChangeManager|undefined;
|
|
109
|
-
#origin?: string;
|
|
110
|
+
#origin?: string|SDK.SecurityOrigin.SecurityOrigin;
|
|
110
111
|
#navigationOccurredDuringRun = false;
|
|
111
112
|
|
|
112
113
|
#contexts: Array<ConversationContext<unknown>> = [];
|
|
@@ -180,7 +181,7 @@ export class AiConversation {
|
|
|
180
181
|
return this.history.length === 0;
|
|
181
182
|
}
|
|
182
183
|
|
|
183
|
-
#setOriginIfEmpty(newOrigin: string|undefined): void {
|
|
184
|
+
#setOriginIfEmpty(newOrigin: string|SDK.SecurityOrigin.SecurityOrigin|undefined): void {
|
|
184
185
|
if (!this.#origin) {
|
|
185
186
|
this.#origin = newOrigin;
|
|
186
187
|
}
|
|
@@ -189,7 +190,7 @@ export class AiConversation {
|
|
|
189
190
|
setContext(updateContext: ConversationContext<unknown>|null): void {
|
|
190
191
|
if (!updateContext) {
|
|
191
192
|
this.#contexts = [];
|
|
192
|
-
if (
|
|
193
|
+
if (isContextSelectionEnabled()) {
|
|
193
194
|
this.#updateAgent(ConversationType.NONE);
|
|
194
195
|
}
|
|
195
196
|
|
|
@@ -198,7 +199,7 @@ export class AiConversation {
|
|
|
198
199
|
|
|
199
200
|
this.#contexts = [updateContext];
|
|
200
201
|
|
|
201
|
-
if (
|
|
202
|
+
if (isContextSelectionEnabled()) {
|
|
202
203
|
if (updateContext instanceof FileContext) {
|
|
203
204
|
this.#updateAgent(ConversationType.FILE);
|
|
204
205
|
} else if (updateContext instanceof DOMNodeContext) {
|
|
@@ -543,7 +544,7 @@ export class AiConversation {
|
|
|
543
544
|
}
|
|
544
545
|
|
|
545
546
|
get origin(): string|undefined {
|
|
546
|
-
return this.#origin;
|
|
547
|
+
return this.#origin instanceof SDK.SecurityOrigin.SecurityOrigin ? this.#origin.siteId() : this.#origin;
|
|
547
548
|
}
|
|
548
549
|
|
|
549
550
|
get type(): ConversationType {
|
|
@@ -555,11 +556,11 @@ export class AiConversation {
|
|
|
555
556
|
return {blocked: true};
|
|
556
557
|
}
|
|
557
558
|
if (this.#origin) {
|
|
558
|
-
return {origin: this
|
|
559
|
+
return {origin: this.origin};
|
|
559
560
|
}
|
|
560
561
|
this.#origin = getPrimaryPageOrigin(this.#targetManager);
|
|
561
562
|
|
|
562
|
-
return {origin: this
|
|
563
|
+
return {origin: this.origin};
|
|
563
564
|
};
|
|
564
565
|
}
|
|
565
566
|
|
|
@@ -573,16 +574,6 @@ function isAiAssistanceServerSideLoggingAllowed(): boolean {
|
|
|
573
574
|
return !Root.Runtime.hostConfig.aidaAvailability?.disallowLogging;
|
|
574
575
|
}
|
|
575
576
|
|
|
576
|
-
/**
|
|
577
|
-
* Returns true if context changes should dynamically update the conversation's
|
|
578
|
-
* agent/type state. Enabled for both the legacy V1 selection agent and the
|
|
579
|
-
* unified V2 architecture.
|
|
580
|
-
*/
|
|
581
|
-
function isAiAssistanceContextSelectionEnabled(): boolean {
|
|
582
|
-
return Boolean(Root.Runtime.hostConfig.devToolsAiAssistanceContextSelectionAgent?.enabled) ||
|
|
583
|
-
Boolean(Root.Runtime.hostConfig.devToolsAiV2Architecture?.enabled);
|
|
584
|
-
}
|
|
585
|
-
|
|
586
577
|
function getPrimaryPageOrigin(
|
|
587
578
|
targetManager: SDK.TargetManager.TargetManager,
|
|
588
579
|
): Platform.DevToolsPath.UrlString|undefined {
|
|
@@ -37,7 +37,7 @@ export interface SerializedImage {
|
|
|
37
37
|
const DEFAULT_MAX_STORAGE_SIZE = 50 * 1024 * 1024;
|
|
38
38
|
export const MAX_RECENT_PROMPTS_COUNT = 20;
|
|
39
39
|
export const MAX_CONVERSATIONS_COUNT = 50;
|
|
40
|
-
export const RECENT_PROMPTS_SIZE_LIMIT = 100 * 1024;
|
|
40
|
+
export const RECENT_PROMPTS_SIZE_LIMIT: number = 100 * 1024;
|
|
41
41
|
|
|
42
42
|
export const enum Events {
|
|
43
43
|
HISTORY_DELETED = 'AiHistoryDeleted',
|
|
@@ -57,7 +57,7 @@ export class AiHistoryStorage extends Common.ObjectWrapper.ObjectWrapper<EventTy
|
|
|
57
57
|
constructor(
|
|
58
58
|
// eslint-disable-next-line @devtools/no-instance-of-migrated-singletons
|
|
59
59
|
settings: Common.Settings.Settings = Common.Settings.Settings.instance(),
|
|
60
|
-
maxStorageSize = DEFAULT_MAX_STORAGE_SIZE,
|
|
60
|
+
maxStorageSize: number = DEFAULT_MAX_STORAGE_SIZE,
|
|
61
61
|
) {
|
|
62
62
|
super();
|
|
63
63
|
this.#historySetting = settings.createSetting('ai-assistance-history-entries', []);
|
|
@@ -5,7 +5,6 @@
|
|
|
5
5
|
import * as Common from '../../core/common/common.js';
|
|
6
6
|
import * as Host from '../../core/host/host.js';
|
|
7
7
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
8
|
-
import type * as Platform from '../../core/platform/platform.js';
|
|
9
8
|
import * as Root from '../../core/root/root.js';
|
|
10
9
|
|
|
11
10
|
import {debugLog} from './debug.js';
|
|
@@ -123,6 +122,22 @@ export function isGeminiBranding(): boolean {
|
|
|
123
122
|
return !!Root.Runtime.hostConfig.devToolsGeminiRebranding?.enabled;
|
|
124
123
|
}
|
|
125
124
|
|
|
125
|
+
/**
|
|
126
|
+
* Returns true if context selection / dynamic context switching is enabled.
|
|
127
|
+
*
|
|
128
|
+
* In the legacy V1 architecture, this corresponds to the `ContextSelectionAgent`,
|
|
129
|
+
* which dynamically routes conversations and allows changing the active context.
|
|
130
|
+
* In the unified V2 architecture (`AiAgent2`), dynamic context selection is natively
|
|
131
|
+
* supported across the single agent instance.
|
|
132
|
+
*
|
|
133
|
+
* This bridge function checks either flag during the transition phase and can be
|
|
134
|
+
* removed in the future when V2 ships permanently and the V1 architecture is removed.
|
|
135
|
+
*/
|
|
136
|
+
export function isContextSelectionEnabled(): boolean {
|
|
137
|
+
return Boolean(Root.Runtime.hostConfig.devToolsAiAssistanceContextSelectionAgent?.enabled) ||
|
|
138
|
+
Boolean(Root.Runtime.hostConfig.devToolsAiV2Architecture?.enabled);
|
|
139
|
+
}
|
|
140
|
+
|
|
126
141
|
/**
|
|
127
142
|
* Preconditions determined entirely on the DevTools frontend side (e.g. Incognito
|
|
128
143
|
* mode or age restrictions) that prevent AI assistance features from running.
|
|
@@ -171,15 +186,6 @@ export function getIconName(): string {
|
|
|
171
186
|
return isGeminiBranding() ? 'spark' : 'smart-assistant';
|
|
172
187
|
}
|
|
173
188
|
|
|
174
|
-
export function isSameOrigin(url1: Platform.DevToolsPath.UrlString, url2: Platform.DevToolsPath.UrlString): boolean {
|
|
175
|
-
if (url1.startsWith('data:') || url2.startsWith('data:')) {
|
|
176
|
-
return url1 === url2;
|
|
177
|
-
}
|
|
178
|
-
const origin1 = Common.ParsedURL.ParsedURL.extractOrigin(url1);
|
|
179
|
-
const origin2 = Common.ParsedURL.ParsedURL.extractOrigin(url2);
|
|
180
|
-
return origin1 !== '' && origin1 === origin2;
|
|
181
|
-
}
|
|
182
|
-
|
|
183
189
|
export interface OneShotPromptRequest {
|
|
184
190
|
aidaClient: Host.AidaClient.AidaClient;
|
|
185
191
|
preamble: string;
|
|
@@ -108,7 +108,7 @@ export class EvaluateAction {
|
|
|
108
108
|
returnByValue: false,
|
|
109
109
|
allowUnsafeEvalBlockedByCSP: false,
|
|
110
110
|
throwOnSideEffect,
|
|
111
|
-
userGesture:
|
|
111
|
+
userGesture: false,
|
|
112
112
|
awaitPromise: true,
|
|
113
113
|
arguments: args.map(remoteObject => {
|
|
114
114
|
return {objectId: remoteObject.objectId};
|
|
@@ -127,7 +127,7 @@ npm start -- --browser=canary
|
|
|
127
127
|
or
|
|
128
128
|
|
|
129
129
|
```
|
|
130
|
-
/Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary --custom-devtools-frontend=file://$(realpath out/
|
|
130
|
+
/Applications/Google\ Chrome\ Canary.app/Contents/MacOS/Google\ Chrome\ Canary --custom-devtools-frontend=file://$(realpath out/Default/gen/front_end)
|
|
131
131
|
```
|
|
132
132
|
|
|
133
133
|
### Enable debug logs
|
|
@@ -4,11 +4,9 @@
|
|
|
4
4
|
|
|
5
5
|
import * as Host from '../../../core/host/host.js';
|
|
6
6
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
7
|
-
import type * as Platform from '../../../core/platform/platform.js';
|
|
8
7
|
import * as Root from '../../../core/root/root.js';
|
|
9
8
|
import * as SDK from '../../../core/sdk/sdk.js';
|
|
10
9
|
import type * as LHModel from '../../lighthouse/lighthouse.js';
|
|
11
|
-
import {isSameOrigin} from '../AiUtils.js';
|
|
12
10
|
import {ChangeManager} from '../ChangeManager.js';
|
|
13
11
|
import {LighthouseFormatter} from '../data_formatters/LighthouseFormatter.js';
|
|
14
12
|
import {debugLog} from '../debug.js';
|
|
@@ -85,8 +83,8 @@ If the user asks a question that requires an investigation of a problem, use thi
|
|
|
85
83
|
* instance for a new conversation.
|
|
86
84
|
*/
|
|
87
85
|
export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON> {
|
|
88
|
-
readonly preamble = preamble;
|
|
89
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_ACCESSIBILITY_AGENT;
|
|
86
|
+
readonly preamble: string = preamble;
|
|
87
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_ACCESSIBILITY_AGENT;
|
|
90
88
|
readonly #lighthouseRecording?:
|
|
91
89
|
(overrides?: LHModel.RunTypes.RunOverrides) => Promise<LHModel.ReporterTypes.ReportJSON|null>;
|
|
92
90
|
|
|
@@ -155,11 +153,15 @@ export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON
|
|
|
155
153
|
return;
|
|
156
154
|
}
|
|
157
155
|
|
|
158
|
-
const details = await
|
|
156
|
+
const [details, widgets] = await Promise.all([
|
|
157
|
+
lhr.getUserFacingDetails(),
|
|
158
|
+
lhr.getWidgets(),
|
|
159
|
+
]);
|
|
159
160
|
if (details) {
|
|
160
161
|
yield {
|
|
161
162
|
type: ResponseType.CONTEXT,
|
|
162
163
|
details,
|
|
164
|
+
widgets,
|
|
163
165
|
};
|
|
164
166
|
}
|
|
165
167
|
}
|
|
@@ -183,13 +185,7 @@ export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON
|
|
|
183
185
|
}
|
|
184
186
|
|
|
185
187
|
const mainDocument = domModel.existingDocument();
|
|
186
|
-
if (!mainDocument) {
|
|
187
|
-
return null;
|
|
188
|
-
}
|
|
189
|
-
const mainDocumentURL = mainDocument.documentURL;
|
|
190
|
-
const nodeDocumentURL = node.ownerDocument?.documentURL ?? '' as Platform.DevToolsPath.UrlString;
|
|
191
|
-
|
|
192
|
-
if (!isSameOrigin(mainDocumentURL, nodeDocumentURL)) {
|
|
188
|
+
if (!mainDocument || !mainDocument.securityOrigin().isSameOriginWith(node.securityOrigin())) {
|
|
193
189
|
return null;
|
|
194
190
|
}
|
|
195
191
|
|
|
@@ -253,7 +249,6 @@ export class AccessibilityAgent extends AiAgent<LHModel.ReporterTypes.ReportJSON
|
|
|
253
249
|
return await executeJsTool.handler(
|
|
254
250
|
args,
|
|
255
251
|
{
|
|
256
|
-
conversationContext: this.context ?? null,
|
|
257
252
|
changeManager: this.#changes,
|
|
258
253
|
createExtensionScope: this.#createExtensionScope.bind(this),
|
|
259
254
|
execJs: this.#execJs,
|
|
@@ -205,7 +205,7 @@ export abstract class ConversationContext<T> {
|
|
|
205
205
|
return true;
|
|
206
206
|
}
|
|
207
207
|
|
|
208
|
-
getOrigin(): string {
|
|
208
|
+
getOrigin(): string|SDK.SecurityOrigin.SecurityOrigin {
|
|
209
209
|
return extractContextOrigin(this.getURL());
|
|
210
210
|
}
|
|
211
211
|
|
|
@@ -221,15 +221,31 @@ export abstract class ConversationContext<T> {
|
|
|
221
221
|
* @param establishedOrigin The origin that the current conversation is locked to.
|
|
222
222
|
* If undefined, the conversation has not yet been locked to an origin.
|
|
223
223
|
*/
|
|
224
|
-
isOriginAllowed(establishedOrigin: string|undefined): boolean {
|
|
224
|
+
isOriginAllowed(establishedOrigin: string|SDK.SecurityOrigin.SecurityOrigin|undefined): boolean {
|
|
225
225
|
const origin = this.getOrigin();
|
|
226
|
+
|
|
227
|
+
if (origin instanceof SDK.SecurityOrigin.SecurityOrigin) {
|
|
228
|
+
if (origin.isOpaque()) {
|
|
229
|
+
return false;
|
|
230
|
+
}
|
|
231
|
+
if (!establishedOrigin) {
|
|
232
|
+
return true;
|
|
233
|
+
}
|
|
234
|
+
const established = establishedOrigin instanceof SDK.SecurityOrigin.SecurityOrigin ?
|
|
235
|
+
establishedOrigin :
|
|
236
|
+
SDK.SecurityOrigin.SecurityOrigin.create(establishedOrigin);
|
|
237
|
+
return origin.isSameOriginWith(established);
|
|
238
|
+
}
|
|
239
|
+
|
|
226
240
|
// If no origin is established yet, this context will be the one to lock the conversation.
|
|
227
241
|
// Opaque origins are never allowed to be used as context.
|
|
228
242
|
if (!establishedOrigin) {
|
|
229
243
|
return !isOpaqueOrigin(origin);
|
|
230
244
|
}
|
|
231
245
|
// Only allow data that matches the origin the conversation is already locked to.
|
|
232
|
-
|
|
246
|
+
const establishedString =
|
|
247
|
+
establishedOrigin instanceof SDK.SecurityOrigin.SecurityOrigin ? establishedOrigin.siteId() : establishedOrigin;
|
|
248
|
+
return areOriginsEquivalent(origin, establishedString);
|
|
233
249
|
}
|
|
234
250
|
|
|
235
251
|
/**
|
|
@@ -1035,9 +1051,11 @@ export abstract class AiAgent<T> {
|
|
|
1035
1051
|
sideEffectConfirmationPromiseWithResolvers.resolve(false);
|
|
1036
1052
|
}
|
|
1037
1053
|
|
|
1038
|
-
|
|
1054
|
+
const onAbort = (): void => {
|
|
1039
1055
|
sideEffectConfirmationPromiseWithResolvers.resolve(false);
|
|
1040
|
-
}
|
|
1056
|
+
};
|
|
1057
|
+
|
|
1058
|
+
options?.signal?.addEventListener('abort', onAbort, {once: true});
|
|
1041
1059
|
|
|
1042
1060
|
yield {
|
|
1043
1061
|
type: ResponseType.SIDE_EFFECT,
|
|
@@ -1045,7 +1063,12 @@ export abstract class AiAgent<T> {
|
|
|
1045
1063
|
description: result.description,
|
|
1046
1064
|
};
|
|
1047
1065
|
|
|
1048
|
-
|
|
1066
|
+
let approvedRun = false;
|
|
1067
|
+
try {
|
|
1068
|
+
approvedRun = await sideEffectConfirmationPromiseWithResolvers.promise;
|
|
1069
|
+
} finally {
|
|
1070
|
+
options?.signal?.removeEventListener('abort', onAbort);
|
|
1071
|
+
}
|
|
1049
1072
|
if (!approvedRun) {
|
|
1050
1073
|
yield {
|
|
1051
1074
|
type: ResponseType.ACTION,
|
|
@@ -88,8 +88,8 @@ export interface ContextSelectionAgentOptions extends AgentOptions {
|
|
|
88
88
|
* instance for a new conversation.
|
|
89
89
|
*/
|
|
90
90
|
export class ContextSelectionAgent extends AiAgent<never> {
|
|
91
|
-
readonly preamble = preamble;
|
|
92
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_CONTEXT_SELECTION_AGENT;
|
|
91
|
+
readonly preamble: string = preamble;
|
|
92
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_CONTEXT_SELECTION_AGENT;
|
|
93
93
|
get userTier(): string|undefined {
|
|
94
94
|
// TODO: Make this depend on variable.
|
|
95
95
|
return Root.Runtime.hostConfig.devToolsFreestyler?.userTier;
|
|
@@ -550,7 +550,8 @@ export class ContextSelectionAgent extends AiAgent<never> {
|
|
|
550
550
|
}
|
|
551
551
|
|
|
552
552
|
static lastSourceId = 0;
|
|
553
|
-
static uiSourceCodeId
|
|
553
|
+
static uiSourceCodeId: WeakMap<Workspace.UISourceCode.UISourceCode, number> =
|
|
554
|
+
new WeakMap<Workspace.UISourceCode.UISourceCode, number>();
|
|
554
555
|
/**
|
|
555
556
|
* This is a heuristic algorithm that gets all the source files coming from the
|
|
556
557
|
* network and assigns unique ids to be linked from the LLM Markdown response.
|
|
@@ -78,8 +78,8 @@ MDN Web Docs: JavaScript Functions: https://developer.mozilla.org/en-US/docs/Web
|
|
|
78
78
|
* instance for a new conversation.
|
|
79
79
|
*/
|
|
80
80
|
export class FileAgent extends AiAgent<Workspace.UISourceCode.UISourceCode> {
|
|
81
|
-
readonly preamble = preamble;
|
|
82
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_FILE_AGENT;
|
|
81
|
+
readonly preamble: string = preamble;
|
|
82
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_FILE_AGENT;
|
|
83
83
|
get userTier(): string|undefined {
|
|
84
84
|
return Root.Runtime.hostConfig.devToolsAiAssistanceFileAgent?.userTier;
|
|
85
85
|
}
|
|
@@ -71,8 +71,8 @@ This request aims to retrieve a list of products matching the search query "lapt
|
|
|
71
71
|
* instance for a new conversation.
|
|
72
72
|
*/
|
|
73
73
|
export class NetworkAgent extends AiAgent<SDK.NetworkRequest.NetworkRequest> {
|
|
74
|
-
readonly preamble = preamble;
|
|
75
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_NETWORK_AGENT;
|
|
74
|
+
readonly preamble: string = preamble;
|
|
75
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_NETWORK_AGENT;
|
|
76
76
|
get userTier(): string|undefined {
|
|
77
77
|
return Root.Runtime.hostConfig.devToolsAiAssistanceNetworkAgent?.userTier;
|
|
78
78
|
}
|
|
@@ -209,7 +209,7 @@ export interface PerformanceAgentOptions extends AgentOptions {
|
|
|
209
209
|
* instance for a new conversation.
|
|
210
210
|
*/
|
|
211
211
|
export class PerformanceAgent extends AiAgent<AgentFocus> {
|
|
212
|
-
readonly preamble = preamble;
|
|
212
|
+
readonly preamble: string = preamble;
|
|
213
213
|
readonly #tracker: Tracing.FreshRecording.Tracker;
|
|
214
214
|
readonly #networkLog: Logs.NetworkLog.NetworkLog;
|
|
215
215
|
|
|
@@ -79,7 +79,9 @@ const MAX_TARGET_ORIGINS = 100;
|
|
|
79
79
|
|
|
80
80
|
function resolveTargetOrigins(context?: ConversationContext<StorageItem>, origins?: string[]): string[] {
|
|
81
81
|
const primaryOrigin = context?.getOrigin();
|
|
82
|
-
const
|
|
82
|
+
const primaryString =
|
|
83
|
+
primaryOrigin instanceof SDK.SecurityOrigin.SecurityOrigin ? primaryOrigin.siteId() : primaryOrigin;
|
|
84
|
+
const rawList = (origins && origins.length > 0) ? origins : (primaryString ? [primaryString] : []);
|
|
83
85
|
const uniqueOrigins = Array.from(new Set(rawList));
|
|
84
86
|
return uniqueOrigins.slice(0, MAX_TARGET_ORIGINS);
|
|
85
87
|
}
|
|
@@ -102,8 +104,8 @@ interface CookieDetails {
|
|
|
102
104
|
}
|
|
103
105
|
|
|
104
106
|
export class StorageAgent extends AiAgent<StorageItem> {
|
|
105
|
-
readonly preamble = preamble;
|
|
106
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_STORAGE_AGENT;
|
|
107
|
+
readonly preamble: string = preamble;
|
|
108
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_STORAGE_AGENT;
|
|
107
109
|
|
|
108
110
|
get userTier(): string|undefined {
|
|
109
111
|
return Root.Runtime.hostConfig.devToolsFreestyler?.userTier;
|
|
@@ -660,8 +662,8 @@ export class StorageAgent extends AiAgent<StorageItem> {
|
|
|
660
662
|
* @param storageKey Optional. If specified, resolves only the partition exactly matching this unique key, bypassing origin comparison.
|
|
661
663
|
*/
|
|
662
664
|
|
|
663
|
-
export async function getCookiesForDomain(
|
|
664
|
-
|
|
665
|
+
export async function getCookiesForDomain(target: SDK.Target.Target,
|
|
666
|
+
origin: string): Promise<SDK.Cookie.Cookie[]|null> {
|
|
665
667
|
const cookieModel = target.model(SDK.CookieModel.CookieModel);
|
|
666
668
|
if (!cookieModel) {
|
|
667
669
|
return null;
|
|
@@ -31,7 +31,7 @@ Content:
|
|
|
31
31
|
"function_declarations": [
|
|
32
32
|
{
|
|
33
33
|
"name": "getStyles",
|
|
34
|
-
"description": "
|
|
34
|
+
"description": "Retrieves computed and authored CSS styles for one or more elements by their backend node IDs (uids).\n\n**CRITICAL** An element uid is a number, not a selector.\n**CRITICAL** Use selectors to refer to elements in the text output. Do not use uids.\n**CRITICAL** Always provide the explanation argument to explain what and why you query.\n**CRITICAL** You MUST provide a specific list of CSS property names. Do not use generic values like \"all\" or \"*\".",
|
|
35
35
|
"parameters": {
|
|
36
36
|
"type": 6,
|
|
37
37
|
"description": "",
|
|
@@ -78,7 +78,7 @@ Content:
|
|
|
78
78
|
"properties": {
|
|
79
79
|
"code": {
|
|
80
80
|
"type": 1,
|
|
81
|
-
"description": "JavaScript code snippet to run on the inspected page. Make sure the code is formatted for readability.\n\n# Instructions\n\n* To return data, define a top-level `data` variable and populate it with data you want to get. Only JSON-serializable objects can be assigned to `data`.\n*
|
|
81
|
+
"description": "JavaScript code snippet to run on the inspected page. Make sure the code is formatted for readability.\n\n# Instructions\n\n* To return data, define a top-level `data` variable and populate it with data you want to get. Only JSON-serializable objects can be assigned to `data`.\n* $0 refers to the currently selected DOM node (or document body if none selected).\n* **CRITICAL** Never assume a selector for the elements unless you verified your knowledge.\n* **CRITICAL** Variables from previous function calls are not available in subsequent calls.\n* **CRITICAL** Keep code concise (max 40 lines and 2,500 characters). Split complex logic into multiple steps.\n* **CRITICAL** Network requests (e.g., fetch, XMLHttpRequest) are disabled and cannot be made.\n\nFor example, to query DOM elements:\n\n```\nconst data = {\n title: document.title,\n elementText: $0?.textContent?.trim(),\n childCount: $0?.children.length,\n};\n```\n"
|
|
82
82
|
},
|
|
83
83
|
"explanation": {
|
|
84
84
|
"type": 1,
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import * as Host from '../../../core/host/host.js';
|
|
6
6
|
import * as Root from '../../../core/root/root.js';
|
|
7
|
-
import
|
|
7
|
+
import * as SDK from '../../../core/sdk/sdk.js';
|
|
8
8
|
import {ChangeManager} from '../ChangeManager.js';
|
|
9
9
|
import {ExtensionScope} from '../ExtensionScope.js';
|
|
10
10
|
import {AI_ASSISTANCE_CSS_CLASS_NAME} from '../injected.js';
|
|
@@ -94,15 +94,15 @@ const MULTIMODAL_ENHANCEMENT_PROMPTS: Record<MultimodalInputType, string> = {
|
|
|
94
94
|
[MultimodalInputType.UPLOADED_IMAGE]: promptForUploadedImage + considerationsForMultimodalInputEvaluation,
|
|
95
95
|
};
|
|
96
96
|
|
|
97
|
-
export const AI_ASSISTANCE_FILTER_REGEX = `\\.${AI_ASSISTANCE_CSS_CLASS_NAME}-.*&`;
|
|
97
|
+
export const AI_ASSISTANCE_FILTER_REGEX: string = `\\.${AI_ASSISTANCE_CSS_CLASS_NAME}-.*&`;
|
|
98
98
|
|
|
99
99
|
/**
|
|
100
100
|
* One agent instance handles one conversation. Create a new agent
|
|
101
101
|
* instance for a new conversation.
|
|
102
102
|
*/
|
|
103
103
|
export class StylingAgent extends AiAgent<SDK.DOMModel.DOMNode> {
|
|
104
|
-
readonly preamble = preamble;
|
|
105
|
-
readonly clientFeature = Host.AidaClient.ClientFeature.CHROME_STYLING_AGENT;
|
|
104
|
+
readonly preamble: string = preamble;
|
|
105
|
+
readonly clientFeature: Host.AidaClient.ClientFeature = Host.AidaClient.ClientFeature.CHROME_STYLING_AGENT;
|
|
106
106
|
get userTier(): string|undefined {
|
|
107
107
|
return Root.Runtime.hostConfig.devToolsFreestyler?.userTier;
|
|
108
108
|
}
|
|
@@ -153,9 +153,11 @@ export class StylingAgent extends AiAgent<SDK.DOMModel.DOMNode> {
|
|
|
153
153
|
return {error: 'Error: Could not find the currently selected element.'};
|
|
154
154
|
}
|
|
155
155
|
return await getStylesTool.handler(args, {
|
|
156
|
-
conversationContext: context,
|
|
157
156
|
getTarget: () => this.targetManager.primaryPageTarget() ?? context.getItem().domModel().target(),
|
|
158
|
-
getEstablishedOrigin: () =>
|
|
157
|
+
getEstablishedOrigin: () => {
|
|
158
|
+
const origin = context.getOrigin();
|
|
159
|
+
return origin instanceof SDK.SecurityOrigin.SecurityOrigin ? origin.siteId() : origin;
|
|
160
|
+
},
|
|
159
161
|
});
|
|
160
162
|
},
|
|
161
163
|
});
|
|
@@ -171,7 +173,6 @@ export class StylingAgent extends AiAgent<SDK.DOMModel.DOMNode> {
|
|
|
171
173
|
handler: (args, options) => executeJsTool.handler(
|
|
172
174
|
args,
|
|
173
175
|
{
|
|
174
|
-
conversationContext: this.context ?? null,
|
|
175
176
|
changeManager: this.#changes,
|
|
176
177
|
createExtensionScope: this.#createExtensionScope.bind(this),
|
|
177
178
|
execJs: this.#execJs,
|
|
@@ -41,8 +41,10 @@ import * as PerformanceAnnotations from './PerformanceAnnotations.js';
|
|
|
41
41
|
import * as Skill from './skills/Skill.js';
|
|
42
42
|
import * as SkillRegistry from './skills/SkillRegistry.js';
|
|
43
43
|
import * as StorageItem from './StorageItem.js';
|
|
44
|
+
import * as CookieUtils from './tools/CookieUtils.js';
|
|
44
45
|
import * as DOMStorageUtils from './tools/DOMStorageUtils.js';
|
|
45
46
|
import * as ExecuteJavaScript from './tools/ExecuteJavaScript.js';
|
|
47
|
+
import * as GetCookieValues from './tools/GetCookieValues.js';
|
|
46
48
|
import * as GetDetailedCallTree from './tools/GetDetailedCallTree.js';
|
|
47
49
|
import * as GetElementAccessibilityDetails from './tools/GetElementAccessibilityDetails.js';
|
|
48
50
|
import * as GetFunctionCode from './tools/GetFunctionCode.js';
|
|
@@ -51,11 +53,13 @@ import * as GetLighthouseAudits from './tools/GetLighthouseAudits.js';
|
|
|
51
53
|
import * as GetNetworkRequestDetails from './tools/GetNetworkRequestDetails.js';
|
|
52
54
|
import * as GetResourceContent from './tools/GetResourceContent.js';
|
|
53
55
|
import * as GetSourceContent from './tools/GetSourceContent.js';
|
|
56
|
+
import * as GetStorageBreakdown from './tools/GetStorageBreakdown.js';
|
|
54
57
|
import * as GetStorageValues from './tools/GetStorageValues.js';
|
|
55
58
|
import * as GetStyles from './tools/GetStyles.js';
|
|
56
59
|
import * as GetTraceEventByKey from './tools/GetTraceEventByKey.js';
|
|
57
60
|
import * as GetTraceMainThreadSummary from './tools/GetTraceMainThreadSummary.js';
|
|
58
61
|
import * as GetTraceNetworkSummary from './tools/GetTraceNetworkSummary.js';
|
|
62
|
+
import * as ListCookies from './tools/ListCookies.js';
|
|
59
63
|
import * as ListNetworkRequests from './tools/ListNetworkRequests.js';
|
|
60
64
|
import * as ListPageOrigins from './tools/ListPageOrigins.js';
|
|
61
65
|
import * as ListSources from './tools/ListSources.js';
|
|
@@ -84,6 +88,7 @@ export {
|
|
|
84
88
|
ChangeManager,
|
|
85
89
|
ContextSelectionAgent,
|
|
86
90
|
ConversationSummary,
|
|
91
|
+
CookieUtils,
|
|
87
92
|
Debug,
|
|
88
93
|
DOMNodeContext,
|
|
89
94
|
DOMStorageUtils,
|
|
@@ -93,6 +98,7 @@ export {
|
|
|
93
98
|
FileAgent,
|
|
94
99
|
FileContext,
|
|
95
100
|
FileFormatter,
|
|
101
|
+
GetCookieValues,
|
|
96
102
|
GetDetailedCallTree,
|
|
97
103
|
GetElementAccessibilityDetails,
|
|
98
104
|
GetFunctionCode,
|
|
@@ -101,6 +107,7 @@ export {
|
|
|
101
107
|
GetNetworkRequestDetails,
|
|
102
108
|
GetResourceContent,
|
|
103
109
|
GetSourceContent,
|
|
110
|
+
GetStorageBreakdown,
|
|
104
111
|
GetStorageValues,
|
|
105
112
|
GetStyles,
|
|
106
113
|
GetTraceEventByKey,
|
|
@@ -108,6 +115,7 @@ export {
|
|
|
108
115
|
GetTraceNetworkSummary,
|
|
109
116
|
Injected,
|
|
110
117
|
LighthouseFormatter,
|
|
118
|
+
ListCookies,
|
|
111
119
|
ListNetworkRequests,
|
|
112
120
|
ListPageOrigins,
|
|
113
121
|
ListSources,
|
|
@@ -3,7 +3,11 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
5
|
import type * as LHModel from '../../lighthouse/lighthouse.js';
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
type AiWidget,
|
|
8
|
+
type ContextDetail,
|
|
9
|
+
ConversationContext,
|
|
10
|
+
} from '../agents/AiAgent.js';
|
|
7
11
|
import {LighthouseFormatter} from '../data_formatters/LighthouseFormatter.js';
|
|
8
12
|
|
|
9
13
|
export class AccessibilityContext extends ConversationContext<LHModel.ReporterTypes.ReportJSON> {
|
|
@@ -60,4 +64,15 @@ export class AccessibilityContext extends ConversationContext<LHModel.ReporterTy
|
|
|
60
64
|
},
|
|
61
65
|
];
|
|
62
66
|
}
|
|
67
|
+
|
|
68
|
+
override async getWidgets(): Promise<AiWidget[]> {
|
|
69
|
+
return [
|
|
70
|
+
{
|
|
71
|
+
name: 'LIGHTHOUSE_REPORT',
|
|
72
|
+
data: {
|
|
73
|
+
report: this.#lh,
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
];
|
|
77
|
+
}
|
|
63
78
|
}
|
|
@@ -2,6 +2,7 @@
|
|
|
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 type * as SDK from '../../../core/sdk/sdk.js';
|
|
5
6
|
import type * as Bindings from '../../bindings/bindings.js';
|
|
6
7
|
import type * as Workspace from '../../workspace/workspace.js';
|
|
7
8
|
import {type ContextDetail, ConversationContext} from '../agents/AiAgent.js';
|
|
@@ -18,6 +19,11 @@ export class FileContext extends ConversationContext<Workspace.UISourceCode.UISo
|
|
|
18
19
|
this.#debuggerWorkspaceBinding = debuggerWorkspaceBinding;
|
|
19
20
|
}
|
|
20
21
|
|
|
22
|
+
override getOrigin(): string|SDK.SecurityOrigin.SecurityOrigin {
|
|
23
|
+
const fallbackOrigin = super.getOrigin();
|
|
24
|
+
return this.#file.project()?.securityOrigin?.() ?? fallbackOrigin;
|
|
25
|
+
}
|
|
26
|
+
|
|
21
27
|
override getURL(): string {
|
|
22
28
|
return this.#file.url();
|
|
23
29
|
}
|