chrome-devtools-frontend 1.0.1690116 → 1.0.1695017
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/devtools-model-management/SKILL.md +3 -3
- package/.agents/skills/foundation-test-migration/SKILL.md +2 -2
- package/.agents/skills/merging-devtools-module/SKILL.md +5 -5
- package/AUTHORS +3 -0
- package/config/typescript/tsconfig.base.json +1 -0
- package/docs/get_the_code.md +4 -9
- package/front_end/Images/src/comment-mode-cursor.svg +23 -0
- package/front_end/Tests.js +1 -1
- package/front_end/application_tokens.css +5 -0
- package/front_end/core/common/ColorConverter.ts +3 -3
- package/front_end/core/host/UserMetrics.ts +27 -0
- package/front_end/core/protocol_client/DevToolsCDPConnection.ts +0 -46
- package/front_end/core/protocol_client/InspectorBackend.ts +6 -6
- package/front_end/core/root/Runtime.ts +1 -0
- package/front_end/core/sdk/CSSLocation.ts +32 -0
- package/front_end/core/sdk/CSSModel.ts +2 -22
- package/front_end/core/sdk/CSSQuery.ts +2 -1
- package/front_end/core/sdk/CSSRule.ts +29 -0
- package/front_end/core/sdk/DebuggerModel.ts +5 -1
- package/front_end/core/sdk/NetworkManager.ts +2 -0
- package/front_end/core/sdk/NetworkRequest.ts +63 -4
- package/front_end/core/sdk/NetworkRequestAccess.ts +191 -0
- package/front_end/core/sdk/ResourceTreeModel.ts +72 -23
- package/front_end/core/sdk/SecurityOrigin.ts +97 -12
- package/front_end/core/sdk/Target.ts +18 -0
- package/front_end/core/sdk/sdk.ts +4 -0
- package/front_end/entrypoints/main/MainImpl.ts +8 -1
- package/front_end/foundation/Universe.ts +14 -11
- package/front_end/generated/Deprecation.ts +8 -0
- package/front_end/generated/InspectorBackendCommands.ts +9 -8
- package/front_end/generated/SupportedCSSProperties.ts +14 -4
- package/front_end/generated/protocol.ts +24 -0
- package/front_end/models/ai_assistance/AiAgent2.ts +46 -10
- package/front_end/models/ai_assistance/AiConversation.ts +35 -24
- package/front_end/models/ai_assistance/README.md +5 -3
- package/front_end/models/ai_assistance/agents/AccessibilityAgent.ts +1 -0
- package/front_end/models/ai_assistance/agents/AiAgent.ts +28 -34
- package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +13 -17
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +5 -3
- package/front_end/models/ai_assistance/agents/StorageAgent.ts +16 -10
- package/front_end/models/ai_assistance/agents/StylingAgent.ts +3 -4
- package/front_end/models/ai_assistance/ai_assistance.ts +0 -2
- package/front_end/models/ai_assistance/contexts/AccessibilityContext.ts +11 -2
- package/front_end/models/ai_assistance/contexts/DOMNodeContext.ts +17 -5
- package/front_end/models/ai_assistance/contexts/FileContext.ts +13 -6
- package/front_end/models/ai_assistance/contexts/PerformanceTraceContext.ts +52 -25
- package/front_end/models/ai_assistance/contexts/RequestContext.ts +18 -34
- package/front_end/models/ai_assistance/contexts/StorageContext.ts +14 -3
- package/front_end/models/ai_assistance/data_formatters/FileFormatter.ts +2 -5
- package/front_end/models/ai_assistance/data_formatters/NetworkRequestFormatter.ts +135 -58
- package/front_end/models/ai_assistance/tools/CookieUtils.ts +25 -35
- package/front_end/models/ai_assistance/tools/DOMStorageUtils.ts +6 -3
- package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +9 -2
- package/front_end/models/ai_assistance/tools/GetCookieValues.ts +1 -1
- package/front_end/models/ai_assistance/tools/GetElementAccessibilityDetails.ts +3 -2
- package/front_end/models/ai_assistance/tools/GetFunctionCode.ts +3 -5
- package/front_end/models/ai_assistance/tools/GetInsightDetails.ts +1 -1
- package/front_end/models/ai_assistance/tools/GetNetworkRequestDetails.ts +8 -11
- package/front_end/models/ai_assistance/tools/GetResourceContent.ts +2 -4
- package/front_end/models/ai_assistance/tools/GetSourceContent.ts +6 -13
- package/front_end/models/ai_assistance/tools/GetStorageBreakdown.ts +1 -1
- package/front_end/models/ai_assistance/tools/GetStorageValues.ts +9 -9
- package/front_end/models/ai_assistance/tools/GetStyles.ts +3 -2
- package/front_end/models/ai_assistance/tools/ListCookies.ts +1 -1
- package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +6 -14
- package/front_end/models/ai_assistance/tools/ListPageOrigins.ts +10 -15
- package/front_end/models/ai_assistance/tools/ListSources.ts +5 -7
- package/front_end/models/ai_assistance/tools/ListStorageKeys.ts +9 -9
- package/front_end/models/ai_assistance/tools/README.md +4 -2
- package/front_end/models/ai_assistance/tools/ResolveDevtoolsNodePath.ts +3 -2
- package/front_end/models/ai_assistance/tools/Tool.ts +27 -3
- package/front_end/models/comment_manager/CD4ABridge.ts +128 -0
- package/front_end/models/comment_manager/CommentManager.ts +50 -8
- package/front_end/models/comment_manager/comment_manager.ts +2 -0
- package/front_end/models/emulation/DeviceModeModel.ts +37 -47
- package/front_end/models/javascript_metadata/NativeFunctions.ts +9 -1
- package/front_end/models/live-metrics/web-vitals-injected/README.md +1 -1
- package/front_end/models/source_map_scopes/NamesResolver.ts +9 -7
- package/front_end/models/trace/ModelImpl.ts +2 -0
- package/front_end/models/trace/Processor.ts +6 -4
- package/front_end/models/trace/handlers/LayerTreeHandler.ts +3 -3
- package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +1 -1
- package/front_end/models/trace/helpers/SyntheticEvents.ts +23 -1
- package/front_end/models/trace/types/Configuration.ts +7 -0
- package/front_end/models/trace/types/TraceEvents.ts +20 -4
- package/front_end/panels/accessibility/ARIAAttributesView.ts +3 -0
- package/front_end/panels/accessibility/AccessibilityAnnouncementRecordingListView.ts +177 -0
- package/front_end/panels/accessibility/accessibility.ts +2 -0
- package/front_end/panels/accessibility/accessibilityAnnouncementRecordingListView.css +33 -0
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +25 -15
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +6 -35
- package/front_end/panels/ai_assistance/components/DisabledWidget.ts +4 -3
- package/front_end/panels/ai_assistance/components/chatMessage.css +3 -1
- package/front_end/panels/animation/AnimationTimeline.ts +1 -0
- package/front_end/panels/application/CrashReportContextView.ts +0 -1
- package/front_end/panels/application/FrameDetailsView.ts +5 -4
- package/front_end/panels/application/IndexedDBViews.ts +4 -4
- package/front_end/panels/application/components/BackForwardCacheView.ts +1 -1
- package/front_end/panels/application/components/EndpointsGrid.ts +2 -1
- package/front_end/panels/application/components/PermissionsPolicySection.ts +1 -1
- package/front_end/panels/application/components/ServiceWorkerRouterView.ts +1 -1
- package/front_end/panels/application/components/TrustTokensView.ts +1 -1
- package/front_end/panels/application/indexedDBViews.css +0 -14
- package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +2 -1
- package/front_end/panels/application/preloading/components/RuleSetDetailsView.ts +2 -1
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +1 -1
- package/front_end/panels/common/CPUThrottlingOption.ts +12 -6
- package/front_end/panels/common/DOMLinkifier.ts +1 -1
- package/front_end/panels/common/ExtensionView.ts +2 -1
- package/front_end/panels/console/ConsoleContextSelector.ts +12 -5
- package/front_end/panels/console/ConsolePinPane.ts +4 -2
- package/front_end/panels/console/ConsoleSidebar.ts +6 -2
- package/front_end/panels/console/ConsoleViewMessage.ts +12 -8
- package/front_end/panels/console/PromptBuilder.ts +1 -1
- package/front_end/panels/coverage/CoverageListView.ts +1 -1
- package/front_end/panels/coverage/CoverageModel.ts +6 -4
- package/front_end/panels/coverage/coverageView.css +8 -8
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +13 -14
- package/front_end/panels/css_overview/CSSOverviewPanel.ts +3 -3
- package/front_end/panels/css_overview/CSSOverviewProcessingView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewSidebarPanel.ts +3 -3
- package/front_end/panels/css_overview/CSSOverviewStartView.ts +3 -3
- package/front_end/panels/developer_resources/DeveloperResourcesListView.ts +1 -1
- package/front_end/panels/developer_resources/developerResourcesView.css +3 -3
- package/front_end/panels/elements/ComputedStyleWidget.ts +1 -1
- package/front_end/panels/elements/ElementsTreeElement.ts +43 -15
- package/front_end/panels/elements/ElementsTreeOutline.ts +185 -109
- package/front_end/panels/elements/MetricsSidebarPane.ts +1 -1
- package/front_end/panels/elements/PropertyNameCategories.ts +1 -1
- package/front_end/panels/elements/ShortcutTreeElement.ts +6 -1
- package/front_end/panels/elements/StandaloneStylesContainer.ts +1 -1
- package/front_end/panels/elements/StylePropertiesSection.ts +2 -35
- package/front_end/panels/elements/StylesSidebarPane.ts +3 -2
- package/front_end/panels/elements/components/CSSPropertyIconResolver.ts +5 -4
- package/front_end/panels/elements/components/StylePropertyEditor.ts +161 -148
- package/front_end/panels/elements/components/computedStyleProperty.css +5 -5
- package/front_end/panels/elements/components/computedStyleTrace.css +5 -5
- package/front_end/panels/elements/components/cssHintDetailsView.css +1 -1
- package/front_end/panels/elements/components/cssPropertyDocsView.css +3 -3
- package/front_end/panels/elements/components/cssVariableValueView.css +4 -4
- package/front_end/panels/elements/components/elementsBreadcrumbs.css +3 -3
- package/front_end/panels/elements/components/elementsTreeExpandButton.css +5 -5
- package/front_end/panels/elements/components/queryContainer.css +2 -2
- package/front_end/panels/elements/elementsTreeOutline.css +20 -4
- package/front_end/panels/emulation/MediaQueryInspector.ts +2 -1
- package/front_end/panels/event_listeners/eventListenersView.css +1 -1
- package/front_end/panels/issues/AffectedElementsView.ts +3 -0
- package/front_end/panels/issues/AffectedLazyLoadImagesView.ts +1 -1
- package/front_end/panels/issues/issues.ts +2 -0
- package/front_end/panels/layer_viewer/LayerDetailsView.ts +12 -10
- package/front_end/panels/layer_viewer/LayerTreeOutline.ts +1 -0
- package/front_end/panels/layer_viewer/Layers3DView.ts +13 -11
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryHighlightChipList.ts +1 -1
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspectorUtils.ts +2 -2
- package/front_end/panels/linear_memory_inspector/components/ValueInterpreterDisplayUtils.ts +1 -1
- package/front_end/panels/linear_memory_inspector/components/ValueInterpreterSettings.ts +1 -1
- package/front_end/panels/linear_memory_inspector/components/linearMemoryHighlightChipList.css +11 -11
- package/front_end/panels/linear_memory_inspector/components/linearMemoryInspector.css +2 -2
- package/front_end/panels/linear_memory_inspector/components/linearMemoryNavigator.css +1 -1
- package/front_end/panels/linear_memory_inspector/components/linearMemoryValueInterpreter.css +5 -5
- package/front_end/panels/linear_memory_inspector/components/linearMemoryViewer.css +6 -6
- package/front_end/panels/linear_memory_inspector/components/valueInterpreterDisplay.css +6 -6
- package/front_end/panels/linear_memory_inspector/components/valueInterpreterSettings.css +2 -2
- package/front_end/panels/media/PlayerPropertiesView.ts +1 -1
- package/front_end/panels/media/TickingFlameChart.ts +3 -2
- package/front_end/panels/mobile_throttling/NetworkThrottlingSelector.ts +2 -1
- package/front_end/panels/mobile_throttling/ThrottlingManager.ts +1 -1
- package/front_end/panels/mobile_throttling/ThrottlingPresets.ts +2 -1
- package/front_end/panels/network/NetworkDataGridNode.ts +11 -9
- package/front_end/panels/network/NetworkLogView.ts +4 -1
- package/front_end/panels/network/NetworkLogViewColumns.ts +5 -2
- package/front_end/panels/network/RequestConditionsDrawer.ts +2 -2
- package/front_end/panels/network/RequestHeadersView.ts +47 -11
- package/front_end/panels/network/RequestPayloadView.ts +1 -1
- package/front_end/panels/network/RequestResponseView.ts +1 -1
- package/front_end/panels/network/RequestTimingView.ts +1 -1
- package/front_end/panels/network/ShowMoreDetailsWidget.ts +1 -1
- package/front_end/panels/network/components/RequestHeadersView.css +12 -0
- package/front_end/panels/network/components/ResponseHeaderSection.ts +1 -1
- package/front_end/panels/performance_monitor/PerformanceMonitor.ts +3 -3
- package/front_end/panels/profiler/HeapProfileView.ts +1 -1
- package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +1 -1
- package/front_end/panels/protocol_monitor/JSONEditor.ts +1 -1
- package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +3 -3
- package/front_end/panels/recorder/RecordingListView.ts +0 -6
- package/front_end/panels/recorder/RecordingView.ts +0 -6
- package/front_end/panels/recorder/controlButton.css +10 -10
- package/front_end/panels/recorder/startView.css +1 -1
- package/front_end/panels/screencast/ScreencastView.ts +4 -2
- package/front_end/panels/search/SearchView.ts +1 -1
- package/front_end/panels/security/SecurityPanel.ts +46 -35
- package/front_end/panels/sources/BreakpointEditDialog.ts +1 -1
- package/front_end/panels/sources/CallStackSidebarPane.ts +1 -1
- package/front_end/panels/sources/DebuggerPausedMessage.ts +8 -6
- package/front_end/panels/sources/ProfilePlugin.ts +2 -1
- package/front_end/panels/sources/ScopeChainSidebarPane.ts +1 -1
- package/front_end/panels/timeline/IsolateSelector.ts +1 -1
- package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +1 -1
- package/front_end/panels/timeline/NetworkTrackAppender.ts +1 -1
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +1 -1
- package/front_end/panels/timeline/TimelineFlameChartView.ts +0 -32
- package/front_end/panels/timeline/TimelineHistoryManager.ts +1 -1
- package/front_end/panels/timeline/TimelinePaintProfilerView.ts +7 -3
- package/front_end/panels/timeline/TimelinePanel.ts +3 -20
- package/front_end/panels/timeline/TimelineTreeView.ts +1 -1
- package/front_end/panels/timeline/TimelineUIUtils.ts +4 -4
- package/front_end/panels/timeline/components/LayoutShiftDetails.ts +4 -3
- package/front_end/panels/timeline/components/LiveMetricsView.ts +1 -1
- package/front_end/panels/timeline/components/NetworkRequestDetails.ts +25 -24
- package/front_end/panels/timeline/components/RelatedInsightChips.ts +4 -3
- package/front_end/panels/timeline/components/Sidebar.ts +1 -1
- package/front_end/panels/timeline/components/SidebarAnnotationsTab.ts +4 -3
- package/front_end/panels/timeline/components/cwvMetrics.css +2 -2
- package/front_end/panels/timeline/components/insights/checklist.css +1 -1
- package/front_end/panels/timeline/components/insights/table.css +3 -3
- package/front_end/panels/timeline/overlays/components/entriesLinkOverlay.css +4 -4
- package/front_end/panels/timeline/overlays/components/entryLabelOverlay.css +4 -4
- package/front_end/panels/timeline/overlays/components/timeRangeOverlay.css +2 -2
- package/front_end/panels/timeline/overlays/components/timespanBreakdownOverlay.css +4 -4
- package/front_end/panels/timeline/timelinePanel.css +0 -74
- package/front_end/panels/timeline/utils/Helpers.ts +1 -1
- package/front_end/panels/timeline/utils/ImageCache.ts +5 -3
- package/front_end/panels/web_audio/WebAudioView.ts +3 -3
- package/front_end/panels/web_audio/webAudio.css +5 -5
- package/front_end/panels/webauthn/WebauthnPane.ts +5 -11
- package/front_end/third_party/acorn/acorn.ts +3 -3
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/chromium/ahem/ahem.d.ts +1 -0
- package/front_end/third_party/csp_evaluator/package/csp.ts +4 -4
- package/front_end/third_party/csp_evaluator/package/parser.ts +3 -1
- package/front_end/third_party/csp_evaluator/package/tsconfig.json +1 -0
- package/front_end/third_party/csp_evaluator/package/utils.ts +1 -1
- package/front_end/third_party/diff/DiffWrapper.ts +1 -8
- package/front_end/third_party/diff/diff_match_patch.d.ts +10 -0
- package/front_end/third_party/json5/json5.ts +2 -2
- 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 +183 -4
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +708 -122
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts +85 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.js +84 -11
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.d.ts +75 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.d.ts.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.js +102 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/ScreenRecording.js.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.d.ts +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.js +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/api.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.d.ts +6 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.js +7 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.d.ts +31 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.d.ts.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.js +138 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/ScreenRecording.js.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.d.ts +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.js +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/bidi.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.d.ts +6 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.js +23 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/core/BrowsingContext.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.d.ts +6 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.js +7 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.d.ts +31 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.d.ts.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.js +131 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/ScreenRecording.js.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.d.ts +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.js +1 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/cdp.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js +7 -4
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.d.ts +4 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.js +5 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserWebSocketTransport.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/ConnectOptions.d.ts +42 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/ConnectOptions.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.js +265 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Device.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.d.ts +4 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.js +24 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/BrowserLauncher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.d.ts +23 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.js +49 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/NodeWebSocketTransport.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/util/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/types.d.ts +183 -4
- package/front_end/third_party/puppeteer/package/package.json +4 -4
- package/front_end/third_party/puppeteer/package/src/api/Page.ts +143 -11
- package/front_end/third_party/puppeteer/package/src/api/ScreenRecording.ts +145 -0
- package/front_end/third_party/puppeteer/package/src/api/api.ts +1 -0
- package/front_end/third_party/puppeteer/package/src/bidi/Page.ts +11 -0
- package/front_end/third_party/puppeteer/package/src/bidi/ScreenRecording.ts +106 -0
- package/front_end/third_party/puppeteer/package/src/bidi/bidi.ts +1 -0
- package/front_end/third_party/puppeteer/package/src/bidi/core/BrowsingContext.ts +41 -0
- package/front_end/third_party/puppeteer/package/src/cdp/Page.ts +11 -0
- package/front_end/third_party/puppeteer/package/src/cdp/ScreenRecording.ts +101 -0
- package/front_end/third_party/puppeteer/package/src/cdp/cdp.ts +1 -0
- package/front_end/third_party/puppeteer/package/src/common/BrowserConnector.ts +17 -9
- package/front_end/third_party/puppeteer/package/src/common/BrowserWebSocketTransport.ts +4 -0
- package/front_end/third_party/puppeteer/package/src/common/ConnectOptions.ts +46 -0
- package/front_end/third_party/puppeteer/package/src/common/Device.ts +287 -1
- package/front_end/third_party/puppeteer/package/src/node/BrowserLauncher.ts +30 -1
- package/front_end/third_party/puppeteer/package/src/node/NodeWebSocketTransport.ts +73 -2
- 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/puppeteer/puppeteer-tsconfig.json +3 -0
- package/front_end/tsconfig.json +1 -2
- package/front_end/ui/comments/CommentAnchorResolver.ts +8 -3
- package/front_end/ui/comments/CommentOverlayManager.ts +53 -12
- package/front_end/ui/comments/CommentsOverlayWidget.ts +3 -3
- package/front_end/ui/comments/CommentsStatusBarPill.ts +96 -0
- package/front_end/ui/comments/comments-meta.ts +21 -0
- package/front_end/ui/comments/comments.ts +2 -0
- package/front_end/ui/comments/commentsOverlay.css +22 -3
- package/front_end/ui/components/buttons/floatingButton.css +25 -0
- package/front_end/ui/components/markdown_view/MarkdownView.ts +31 -1
- package/front_end/ui/components/srgb_overlay/SrgbOverlay.ts +1 -1
- package/front_end/ui/components/suggestion_input/SuggestionInput.ts +45 -25
- package/front_end/ui/kit/icons/Icon.ts +0 -1
- package/front_end/ui/kit/link/Link.ts +8 -1
- package/front_end/ui/legacy/ContextMenu.ts +2 -2
- package/front_end/ui/legacy/DropTarget.ts +6 -1
- package/front_end/ui/legacy/EmptyWidget.ts +1 -1
- package/front_end/ui/legacy/GlassPane.ts +1 -1
- package/front_end/ui/legacy/InspectorView.ts +17 -1
- package/front_end/ui/legacy/ShortcutRegistry.ts +2 -2
- package/front_end/ui/legacy/SplitWidget.ts +18 -3
- package/front_end/ui/legacy/StackedPane.ts +1 -1
- package/front_end/ui/legacy/StatusBar.ts +78 -0
- package/front_end/ui/legacy/TargetCrashedScreen.ts +1 -1
- package/front_end/ui/legacy/TextPrompt.ts +2 -1
- package/front_end/ui/legacy/Toolbar.ts +5 -1
- package/front_end/ui/legacy/Treeoutline.ts +91 -48
- package/front_end/ui/legacy/UIUtils.ts +8 -4
- package/front_end/ui/legacy/ViewManager.ts +1 -1
- package/front_end/ui/legacy/ViewRegistration.ts +1 -0
- package/front_end/ui/legacy/Widget.ts +1 -1
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +7 -1
- package/front_end/ui/legacy/components/data_grid/DataGrid.ts +1 -1
- package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +3 -2
- package/front_end/ui/legacy/components/data_grid/dataGrid.css +23 -23
- package/front_end/ui/legacy/components/inline_editor/AnimationTimingModel.ts +1 -1
- package/front_end/ui/legacy/components/inline_editor/BezierEditor.ts +48 -44
- package/front_end/ui/legacy/components/inline_editor/CSSAngleUtils.ts +1 -1
- package/front_end/ui/legacy/components/inline_editor/PositionAreaEditor.docs.ts +83 -0
- package/front_end/ui/legacy/components/inline_editor/PositionAreaEditor.ts +600 -0
- package/front_end/ui/legacy/components/inline_editor/animationNameSwatch.css +1 -1
- package/front_end/ui/legacy/components/inline_editor/colorMixSwatch.css +4 -4
- package/front_end/ui/legacy/components/inline_editor/cssAngleSwatch.css +3 -3
- package/front_end/ui/legacy/components/inline_editor/inline_editor.ts +2 -0
- package/front_end/ui/legacy/components/inline_editor/linkSwatch.css +1 -1
- package/front_end/ui/legacy/components/inline_editor/positionAreaEditor.css +154 -0
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +224 -127
- package/front_end/ui/legacy/components/object_ui/ObjectPopoverHelper.ts +10 -7
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +25 -106
- package/front_end/ui/legacy/components/object_ui/customPreviewComponent.css +7 -3
- package/front_end/ui/legacy/components/object_ui/objectPropertiesSection.css +1 -1
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +0 -66
- package/front_end/ui/legacy/components/perf_ui/perf_ui.ts +0 -2
- package/front_end/ui/legacy/components/perf_ui/pieChart.css +7 -5
- package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +8 -5
- package/front_end/ui/legacy/components/utils/JSPresentationUtils.ts +1 -1
- package/front_end/ui/legacy/components/utils/Linkifier.ts +5 -5
- package/front_end/ui/legacy/inspectorCommon.css +41 -6
- package/front_end/ui/legacy/legacy.ts +2 -0
- package/front_end/ui/legacy/statusBar.css +18 -0
- package/front_end/ui/visual_logging/Debugging.ts +2 -1
- package/front_end/ui/visual_logging/KnownContextValues.ts +3 -1
- package/front_end/ui/visual_logging/LoggingDriver.ts +3 -3
- package/front_end/ui/visual_logging/LoggingEvents.ts +5 -5
- package/front_end/ui/visual_logging/LoggingState.ts +1 -1
- package/front_end/ui/visual_logging/visual_logging.ts +67 -56
- package/inspector_overlay/main.ts +8 -8
- package/mcp/mcp.ts +5 -0
- package/package.json +2 -8
- package/front_end/Images/generate-css-vars.js +0 -52
- package/front_end/Images/rollup.config.mjs +0 -36
- package/front_end/models/ai_assistance/AiOrigins.ts +0 -107
- package/front_end/models/live-metrics/web-vitals-injected/rollup.config.mjs +0 -20
- package/front_end/panels/recorder/injected/rollup.config.mjs +0 -20
- package/front_end/panels/timeline/EasterEgg.d.ts +0 -6
- package/front_end/panels/timeline/easter-egg-tsconfig.json +0 -8
- package/front_end/panels/timeline/enable-easter-egg.js +0 -20
- package/front_end/third_party/acorn/acorn-tsconfig.json +0 -12
- package/front_end/third_party/acorn/estree-tsconfig.json +0 -8
- package/front_end/third_party/chromium/client-variations/client-variations-tsconfig.json +0 -8
- package/front_end/third_party/codemirror/codemirror-legacy-types-tsconfig.json +0 -8
- package/front_end/third_party/codemirror/codemirror-tsconfig.json +0 -15
- package/front_end/third_party/codemirror.next/bundle-tsconfig.json +0 -24
- package/front_end/third_party/intl-messageformat/intl-messageformat-tsconfig.json +0 -16
- package/front_end/third_party/json5/json5-tsconfig.json +0 -8
- package/front_end/third_party/legacy-javascript/legacy-javascript-tsconfig.json +0 -8
- package/front_end/third_party/lighthouse/lighthouse-tsconfig.json +0 -11
- package/front_end/third_party/lighthouse/report/bundle-tsconfig.json +0 -8
- package/front_end/third_party/lit/lit-tsconfig.json +0 -15
- package/front_end/third_party/marked/marked-tsconfig.json +0 -8
- package/front_end/third_party/puppeteer-replay/puppeteer-replay-tsconfig.json +0 -8
- package/front_end/third_party/third-party-web/third-party-web-tsconfig.json +0 -8
- package/front_end/third_party/wasmparser/wasmparser-tsconfig.json +0 -9
- package/front_end/third_party/web-vitals/web-vitals-tsconfig.json +0 -47
- package/front_end/ui/legacy/components/perf_ui/BrickBreaker.ts +0 -606
- package/inspector_overlay/loadCSS.rollup.js +0 -29
|
@@ -36,6 +36,7 @@ interface ViewInput {
|
|
|
36
36
|
attributeBeingEdited: SDK.DOMModel.Attribute|null;
|
|
37
37
|
attributes: SDK.DOMModel.Attribute[];
|
|
38
38
|
backendNodeId?: number;
|
|
39
|
+
targetId?: string;
|
|
39
40
|
}
|
|
40
41
|
|
|
41
42
|
type View = (input: ViewInput, output: object, target: HTMLElement|DocumentFragment) => void;
|
|
@@ -99,6 +100,7 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
99
100
|
attributes: {
|
|
100
101
|
jslog: `${VisualLogging.section('aria-attributes')}`,
|
|
101
102
|
...(input.backendNodeId ? {'data-backend-node-id': `${input.backendNodeId}`} : {}),
|
|
103
|
+
...(input.targetId ? {'data-target-id': `${input.targetId}`} : {}),
|
|
102
104
|
},
|
|
103
105
|
},
|
|
104
106
|
});
|
|
@@ -159,6 +161,7 @@ export class ARIAAttributesPane extends AccessibilitySubPane<ShadowRoot> {
|
|
|
159
161
|
onCancelEditing,
|
|
160
162
|
propertyCompletions,
|
|
161
163
|
backendNodeId: this.node()?.backendNodeId(),
|
|
164
|
+
targetId: this.node()?.domModel().target().id(),
|
|
162
165
|
};
|
|
163
166
|
this.#view(input, {}, this.contentElement);
|
|
164
167
|
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
// Copyright 2026 The Chromium Authors
|
|
2
|
+
// Use of this source code is governed by a BSD-style license that can be
|
|
3
|
+
// found in the LICENSE file.
|
|
4
|
+
|
|
5
|
+
import '../../ui/legacy/components/data_grid/data_grid.js';
|
|
6
|
+
|
|
7
|
+
import * as i18n from '../../core/i18n/i18n.js';
|
|
8
|
+
import * as UI from '../../ui/legacy/legacy.js';
|
|
9
|
+
import * as Lit from '../../ui/lit/lit.js';
|
|
10
|
+
|
|
11
|
+
import accessibilityAnnouncementRecordingListViewStyles from './accessibilityAnnouncementRecordingListView.css.js';
|
|
12
|
+
import {
|
|
13
|
+
type A11yAnnouncement,
|
|
14
|
+
AnnouncementApi,
|
|
15
|
+
} from './AccessibilityAnnouncementRecordingView.js';
|
|
16
|
+
|
|
17
|
+
const {html, render} = Lit;
|
|
18
|
+
|
|
19
|
+
const UIStrings = {
|
|
20
|
+
/**
|
|
21
|
+
* @description Column header for the announcement timestamp.
|
|
22
|
+
*/
|
|
23
|
+
time: 'Time',
|
|
24
|
+
/**
|
|
25
|
+
* @description Column header for the API type (DOM aria-live vs JS ariaNotify).
|
|
26
|
+
*/
|
|
27
|
+
api: 'API',
|
|
28
|
+
/**
|
|
29
|
+
* @description Column header for the politeness level (e.g. polite, assertive).
|
|
30
|
+
*/
|
|
31
|
+
politeness: 'Politeness',
|
|
32
|
+
/**
|
|
33
|
+
* @description Column header for the announcement message text.
|
|
34
|
+
*/
|
|
35
|
+
message: 'Message',
|
|
36
|
+
/**
|
|
37
|
+
* @description Value for DOM aria-live announcements in the API column.
|
|
38
|
+
*/
|
|
39
|
+
ariaLive: 'ARIA live',
|
|
40
|
+
/**
|
|
41
|
+
* @description Value for JS ariaNotify announcements in the API column.
|
|
42
|
+
*/
|
|
43
|
+
jsTriggered: 'JS-triggered',
|
|
44
|
+
/**
|
|
45
|
+
* @description Accessible title for the announcements data grid.
|
|
46
|
+
*/
|
|
47
|
+
ariaLiveRecordingList: 'Accessibility Announcements',
|
|
48
|
+
} as const;
|
|
49
|
+
const str_ =
|
|
50
|
+
i18n.i18n.registerUIStrings('panels/accessibility/AccessibilityAnnouncementRecordingListView.ts', UIStrings);
|
|
51
|
+
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
52
|
+
|
|
53
|
+
export interface ViewInput {
|
|
54
|
+
items: readonly A11yAnnouncement[];
|
|
55
|
+
selectedItem: A11yAnnouncement|null;
|
|
56
|
+
onSelect: (item: A11yAnnouncement) => void;
|
|
57
|
+
onDeselect: () => void;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
export type View = (input: ViewInput, output: undefined, target: HTMLElement) => void;
|
|
61
|
+
|
|
62
|
+
export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
63
|
+
// clang-format off
|
|
64
|
+
render(html`
|
|
65
|
+
<style>${accessibilityAnnouncementRecordingListViewStyles}</style>
|
|
66
|
+
<devtools-data-grid
|
|
67
|
+
name=${i18nString(UIStrings.ariaLiveRecordingList)}
|
|
68
|
+
striped
|
|
69
|
+
class="flex-auto"
|
|
70
|
+
@deselect=${input.onDeselect}>
|
|
71
|
+
<table>
|
|
72
|
+
<tr>
|
|
73
|
+
<th id="time" sortable fixed width="110px" align="right">
|
|
74
|
+
${i18nString(UIStrings.time)}
|
|
75
|
+
</th>
|
|
76
|
+
<th id="api" sortable fixed width="110px">
|
|
77
|
+
${i18nString(UIStrings.api)}
|
|
78
|
+
</th>
|
|
79
|
+
<th id="politeness" sortable fixed width="90px">
|
|
80
|
+
${i18nString(UIStrings.politeness)}
|
|
81
|
+
</th>
|
|
82
|
+
<th id="message" sortable width="300px">
|
|
83
|
+
${i18nString(UIStrings.message)}
|
|
84
|
+
</th>
|
|
85
|
+
</tr>
|
|
86
|
+
${input.items.map(item => {
|
|
87
|
+
const timeString = new Date(item.time).toLocaleTimeString(i18n.DevToolsLocale.DevToolsLocale.instance().locale);
|
|
88
|
+
const apiDisplay = item.api === AnnouncementApi.JS_TRIGGERED ?
|
|
89
|
+
i18nString(UIStrings.jsTriggered) :
|
|
90
|
+
i18nString(UIStrings.ariaLive);
|
|
91
|
+
|
|
92
|
+
return html`
|
|
93
|
+
<tr
|
|
94
|
+
?selected=${item === input.selectedItem}
|
|
95
|
+
@select=${() => input.onSelect(item)}>
|
|
96
|
+
<td data-value=${item.time}>
|
|
97
|
+
<span>${timeString}</span>
|
|
98
|
+
</td>
|
|
99
|
+
<td>${apiDisplay}</td>
|
|
100
|
+
<td>${item.politeness}</td>
|
|
101
|
+
<td title=${item.message}>
|
|
102
|
+
${item.message}
|
|
103
|
+
</td>
|
|
104
|
+
</tr>`;
|
|
105
|
+
})}
|
|
106
|
+
</table>
|
|
107
|
+
</devtools-data-grid>`,
|
|
108
|
+
target);
|
|
109
|
+
// clang-format on
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
export class AccessibilityAnnouncementRecordingListView extends UI.Widget.VBox {
|
|
113
|
+
#items: readonly A11yAnnouncement[] = [];
|
|
114
|
+
#selectedItem: A11yAnnouncement|null = null;
|
|
115
|
+
#onSelect: ((item: A11yAnnouncement|null) => void)|null = null;
|
|
116
|
+
readonly #view: View;
|
|
117
|
+
|
|
118
|
+
constructor(element?: HTMLElement, view: View = DEFAULT_VIEW) {
|
|
119
|
+
super(element, {useShadowDom: true});
|
|
120
|
+
this.#view = view;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
override wasShown(): void {
|
|
124
|
+
super.wasShown();
|
|
125
|
+
this.requestUpdate();
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
set items(items: readonly A11yAnnouncement[]) {
|
|
129
|
+
if (this.#items === items) {
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
this.#items = items;
|
|
133
|
+
this.requestUpdate();
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
get items(): readonly A11yAnnouncement[] {
|
|
137
|
+
return this.#items;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
set selectedItem(item: A11yAnnouncement|null) {
|
|
141
|
+
if (this.#selectedItem === item) {
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
144
|
+
this.#selectedItem = item;
|
|
145
|
+
this.requestUpdate();
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
get selectedItem(): A11yAnnouncement|null {
|
|
149
|
+
return this.#selectedItem;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
set onSelect(onSelect: (item: A11yAnnouncement|null) => void) {
|
|
153
|
+
this.#onSelect = onSelect;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
reset(): void {
|
|
157
|
+
this.#items = [];
|
|
158
|
+
this.#selectedItem = null;
|
|
159
|
+
this.requestUpdate();
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
override performUpdate(): void {
|
|
163
|
+
const input: ViewInput = {
|
|
164
|
+
items: this.#items,
|
|
165
|
+
selectedItem: this.#selectedItem,
|
|
166
|
+
onSelect: (item: A11yAnnouncement) => {
|
|
167
|
+
this.selectedItem = item;
|
|
168
|
+
this.#onSelect?.(item);
|
|
169
|
+
},
|
|
170
|
+
onDeselect: () => {
|
|
171
|
+
this.selectedItem = null;
|
|
172
|
+
this.#onSelect?.(null);
|
|
173
|
+
},
|
|
174
|
+
};
|
|
175
|
+
this.#view(input, undefined, this.contentElement);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
@@ -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 * as AccessibilityAnnouncementRecordingListView from './AccessibilityAnnouncementRecordingListView.js';
|
|
5
6
|
import * as AccessibilityAnnouncementRecordingView from './AccessibilityAnnouncementRecordingView.js';
|
|
6
7
|
import * as AccessibilityNodeView from './AccessibilityNodeView.js';
|
|
7
8
|
import * as AccessibilitySidebarView from './AccessibilitySidebarView.js';
|
|
@@ -11,6 +12,7 @@ import * as ARIAAttributesView from './ARIAAttributesView.js';
|
|
|
11
12
|
import * as ARIAMetadata from './ARIAMetadata.js';
|
|
12
13
|
|
|
13
14
|
export {
|
|
15
|
+
AccessibilityAnnouncementRecordingListView,
|
|
14
16
|
AccessibilityAnnouncementRecordingView,
|
|
15
17
|
AccessibilityNodeView,
|
|
16
18
|
AccessibilitySidebarView,
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright 2026 The Chromium Authors
|
|
3
|
+
* Use of this source code is governed by a BSD-style license that can be
|
|
4
|
+
* found in the LICENSE file.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:host {
|
|
8
|
+
font-family: inherit;
|
|
9
|
+
display: flex;
|
|
10
|
+
flex-direction: column;
|
|
11
|
+
flex: auto;
|
|
12
|
+
height: 100%;
|
|
13
|
+
min-height: 0;
|
|
14
|
+
overflow: hidden;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
@scope to (devtools-widget > *) {
|
|
18
|
+
:scope {
|
|
19
|
+
font-family: inherit;
|
|
20
|
+
display: flex;
|
|
21
|
+
flex-direction: column;
|
|
22
|
+
flex: auto;
|
|
23
|
+
height: 100%;
|
|
24
|
+
overflow: hidden;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
devtools-data-grid {
|
|
28
|
+
font-family: inherit;
|
|
29
|
+
flex: auto;
|
|
30
|
+
height: 100%;
|
|
31
|
+
border: none;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -626,11 +626,14 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
626
626
|
};
|
|
627
627
|
#textInputValue = '';
|
|
628
628
|
|
|
629
|
-
|
|
629
|
+
private view: View;
|
|
630
|
+
|
|
631
|
+
constructor(view: View|undefined = defaultView, {aidaClient, aidaAvailability}: {
|
|
630
632
|
aidaClient: Host.AidaClient.AidaClient,
|
|
631
633
|
aidaAvailability: Host.AidaClient.AidaAccessPreconditions,
|
|
632
634
|
}) {
|
|
633
635
|
super(AiAssistancePanel.panelName);
|
|
636
|
+
this.view = view;
|
|
634
637
|
this.registerRequiredCSS(aiAssistancePanelStyles);
|
|
635
638
|
this.#aiAssistanceEnabledSetting = this.#getAiAssistanceEnabledSetting();
|
|
636
639
|
|
|
@@ -730,8 +733,7 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
730
733
|
onTextSubmit: async (text: string, imageInput?: Host.AidaClient.Part,
|
|
731
734
|
multimodalInputType?: AiAssistanceModel.AiAgent.MultimodalInputType) => {
|
|
732
735
|
const submit = (): void => {
|
|
733
|
-
|
|
734
|
-
void this.#startConversation(text, imageInput, multimodalInputType);
|
|
736
|
+
void this.#submitQuery(text, imageInput, multimodalInputType);
|
|
735
737
|
};
|
|
736
738
|
|
|
737
739
|
const seenSetting = Common.Settings.Settings.instance().resolve(
|
|
@@ -1505,11 +1507,10 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1505
1507
|
return;
|
|
1506
1508
|
}
|
|
1507
1509
|
|
|
1508
|
-
Host.userMetrics.actionTaken(Host.UserMetrics.Action.AiAssistanceQuerySubmitted);
|
|
1509
1510
|
if (this.#conversation && this.#conversation.isBlockedByOrigin) {
|
|
1510
1511
|
this.#handleNewChatRequest();
|
|
1511
1512
|
}
|
|
1512
|
-
await this.#
|
|
1513
|
+
await this.#submitQuery(predefinedPrompt);
|
|
1513
1514
|
} else {
|
|
1514
1515
|
this.#viewOutput.chatView?.focusTextInput();
|
|
1515
1516
|
}
|
|
@@ -1589,7 +1590,7 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1589
1590
|
}
|
|
1590
1591
|
|
|
1591
1592
|
this.#updateConversationState(conversation);
|
|
1592
|
-
await this.#
|
|
1593
|
+
await this.#consumeResponseStream(conversation.history);
|
|
1593
1594
|
}
|
|
1594
1595
|
|
|
1595
1596
|
#handleNewChatRequest(): void {
|
|
@@ -1707,7 +1708,11 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1707
1708
|
}
|
|
1708
1709
|
}
|
|
1709
1710
|
|
|
1710
|
-
|
|
1711
|
+
/**
|
|
1712
|
+
* Submits a user query turn to the active conversation and streams the response.
|
|
1713
|
+
* Executes on every turn (both initial prompt and follow-up turns).
|
|
1714
|
+
*/
|
|
1715
|
+
async #submitQuery(
|
|
1711
1716
|
text: string,
|
|
1712
1717
|
imageInput?: Host.AidaClient.Part,
|
|
1713
1718
|
multimodalInputType?: AiAssistanceModel.AiAgent.MultimodalInputType,
|
|
@@ -1715,13 +1720,18 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1715
1720
|
if (!this.#conversation) {
|
|
1716
1721
|
return;
|
|
1717
1722
|
}
|
|
1718
|
-
// Cancel any previous in-flight
|
|
1723
|
+
// Cancel any previous in-flight query.
|
|
1719
1724
|
this.#cancel();
|
|
1725
|
+
Host.userMetrics.actionTaken(Host.UserMetrics.Action.AiAssistanceQuerySubmitted);
|
|
1720
1726
|
const signal = this.#runAbortController.signal;
|
|
1721
1727
|
|
|
1722
|
-
//
|
|
1728
|
+
// Initial conversation boundary (turn 1 only).
|
|
1723
1729
|
if (this.#conversation.isEmpty) {
|
|
1724
1730
|
Badges.UserBadges.instance().recordAction(Badges.BadgeAction.STARTED_AI_CONVERSATION);
|
|
1731
|
+
// Note: Prior to September 2026 (crrev.com/c/8366147), this event erroneously logged on every query
|
|
1732
|
+
// turn because this method was named #startConversation. It is now correctly
|
|
1733
|
+
// restricted to conversation initialization.
|
|
1734
|
+
void VisualLogging.logFunctionCall(`start-conversation-${this.#conversation.type}`, 'ui');
|
|
1725
1735
|
}
|
|
1726
1736
|
|
|
1727
1737
|
let multimodalInput: AiAssistanceModel.AiAgent.MultimodalInput|undefined;
|
|
@@ -1733,9 +1743,7 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1733
1743
|
};
|
|
1734
1744
|
}
|
|
1735
1745
|
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
await this.#doConversation(
|
|
1746
|
+
await this.#consumeResponseStream(
|
|
1739
1747
|
this.#conversation.run(
|
|
1740
1748
|
text,
|
|
1741
1749
|
{
|
|
@@ -1746,9 +1754,11 @@ export class AiAssistancePanel extends UI.Panel.Panel {
|
|
|
1746
1754
|
);
|
|
1747
1755
|
}
|
|
1748
1756
|
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1757
|
+
/**
|
|
1758
|
+
* Consumes response items (live generator or historic array) and drives UI updates.
|
|
1759
|
+
*/
|
|
1760
|
+
async #consumeResponseStream(items: Iterable<AiAssistanceModel.AiAgent.ResponseData, void, void>|
|
|
1761
|
+
AsyncIterable<AiAssistanceModel.AiAgent.ResponseData, void, void>): Promise<void> {
|
|
1752
1762
|
const release = await this.#mutex.acquire();
|
|
1753
1763
|
try {
|
|
1754
1764
|
let systemMessage: ModelChatMessage = {
|
|
@@ -19,10 +19,9 @@ import * as Trace from '../../../models/trace/trace.js';
|
|
|
19
19
|
import * as Workspace from '../../../models/workspace/workspace.js';
|
|
20
20
|
import * as PanelsCommon from '../../../panels/common/common.js';
|
|
21
21
|
import * as TraceBounds from '../../../services/trace_bounds/trace_bounds.js';
|
|
22
|
-
import * as Marked from '../../../third_party/marked/marked.js';
|
|
23
22
|
import * as Buttons from '../../../ui/components/buttons/buttons.js';
|
|
24
23
|
import * as Input from '../../../ui/components/input/input.js';
|
|
25
|
-
import
|
|
24
|
+
import * as MarkdownView from '../../../ui/components/markdown_view/markdown_view.js';
|
|
26
25
|
import * as Snackbars from '../../../ui/components/snackbars/snackbars.js';
|
|
27
26
|
import * as UIHelpers from '../../../ui/helpers/helpers.js';
|
|
28
27
|
import type * as PerfUI from '../../../ui/legacy/components/perf_ui/perf_ui.js';
|
|
@@ -614,7 +613,7 @@ export const DEFAULT_VIEW = (input: ChatMessageViewInput, output: ViewOutput, ta
|
|
|
614
613
|
<div class="user-query-wrapper">
|
|
615
614
|
<section class=${messageClasses} jslog=${VisualLogging.section('question')}>
|
|
616
615
|
${imageInput}
|
|
617
|
-
<div class="message-content">${renderTextAsMarkdown(message.text, input.markdownRenderer)}</div>
|
|
616
|
+
<div class="message-content">${MarkdownView.MarkdownView.renderTextAsMarkdown(message.text, input.markdownRenderer)}</div>
|
|
618
617
|
</section>
|
|
619
618
|
</div>
|
|
620
619
|
`, target);
|
|
@@ -643,7 +642,7 @@ export const DEFAULT_VIEW = (input: ChatMessageViewInput, output: ViewOutput, ta
|
|
|
643
642
|
(part, index) => {
|
|
644
643
|
const isLastPart = index === message.parts.length - 1;
|
|
645
644
|
if (part.type === 'answer') {
|
|
646
|
-
return html`<p>${renderTextAsMarkdown(part.text, input.markdownRenderer, { animate: !input.isReadOnly && input.isLoading && isLastPart && input.isLastMessage })}</p>`;
|
|
645
|
+
return html`<p>${MarkdownView.MarkdownView.renderTextAsMarkdown(part.text, input.markdownRenderer, { animate: !input.isReadOnly && input.isLoading && isLastPart && input.isLastMessage })}</p>`;
|
|
647
646
|
}
|
|
648
647
|
if (part.type === 'widget') {
|
|
649
648
|
return html`${Lit.Directives.until(renderWidgets(part.widgets, {wrapperClass: 'main-widgets-wrapper'}))}`;
|
|
@@ -662,36 +661,6 @@ export const DEFAULT_VIEW = (input: ChatMessageViewInput, output: ViewOutput, ta
|
|
|
662
661
|
|
|
663
662
|
export type View = typeof DEFAULT_VIEW;
|
|
664
663
|
|
|
665
|
-
function renderTextAsMarkdown(text: string, markdownRenderer: MarkdownView.MarkdownView.MarkdownLitRenderer,
|
|
666
|
-
{animate, ref: refFn}: {
|
|
667
|
-
animate?: boolean,
|
|
668
|
-
ref?: (element?: Element) => void,
|
|
669
|
-
} = {}): Lit.TemplateResult {
|
|
670
|
-
let tokens = [];
|
|
671
|
-
try {
|
|
672
|
-
tokens = Marked.Marked.lexer(text);
|
|
673
|
-
for (const token of tokens) {
|
|
674
|
-
// Try to render all the tokens to make sure that
|
|
675
|
-
// they all have a template defined for them. If there
|
|
676
|
-
// isn't any template defined for a token, we'll fallback
|
|
677
|
-
// to rendering the text as plain text instead of markdown.
|
|
678
|
-
markdownRenderer.renderToken(token);
|
|
679
|
-
}
|
|
680
|
-
} catch {
|
|
681
|
-
// The tokens were not parsed correctly or
|
|
682
|
-
// one of the tokens are not supported, so we
|
|
683
|
-
// continue to render this as text.
|
|
684
|
-
return html`${text}`;
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
// clang-format off
|
|
688
|
-
return html`<devtools-markdown-view
|
|
689
|
-
.data=${{tokens, renderer: markdownRenderer, animationEnabled: animate} as MarkdownView.MarkdownView.MarkdownViewData}
|
|
690
|
-
${refFn ? ref(refFn) : Lit.nothing}>
|
|
691
|
-
</devtools-markdown-view>`;
|
|
692
|
-
// clang-format on
|
|
693
|
-
}
|
|
694
|
-
|
|
695
664
|
export function titleForStep(step: Step): string {
|
|
696
665
|
return step.title ?? `${lockedString(UIStringsNotTranslate.investigating)}…`;
|
|
697
666
|
}
|
|
@@ -754,7 +723,9 @@ function renderStepDetails({
|
|
|
754
723
|
}): Lit.LitTemplate {
|
|
755
724
|
const sideEffects =
|
|
756
725
|
isLast && step.state.type === 'needs_approval' ? renderSideEffectConfirmationUi(step) : Lit.nothing;
|
|
757
|
-
const thought = step.thought ?
|
|
726
|
+
const thought = step.thought ?
|
|
727
|
+
html`<p>${MarkdownView.MarkdownView.renderTextAsMarkdown(step.thought, markdownRenderer)}</p>` :
|
|
728
|
+
Lit.nothing;
|
|
758
729
|
|
|
759
730
|
// clang-format off
|
|
760
731
|
const contextDetails = step.contextDetails ?
|
|
@@ -3,13 +3,14 @@
|
|
|
3
3
|
// Use of this source code is governed by a BSD-style license that can be
|
|
4
4
|
// found in the LICENSE file.
|
|
5
5
|
|
|
6
|
+
import '../../../ui/kit/kit.js';
|
|
7
|
+
|
|
6
8
|
import * as Host from '../../../core/host/host.js';
|
|
7
9
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
8
10
|
import * as Root from '../../../core/root/root.js';
|
|
9
11
|
import * as uiI18n from '../../../ui/i18n/i18n.js';
|
|
10
12
|
import * as UI from '../../../ui/legacy/legacy.js';
|
|
11
13
|
import {html, type LitTemplate, render} from '../../../ui/lit/lit.js';
|
|
12
|
-
import * as VisualLogging from '../../../ui/visual_logging/visual_logging.js';
|
|
13
14
|
|
|
14
15
|
import disabledWidgetStyles from './disabledWidget.css.js';
|
|
15
16
|
|
|
@@ -85,14 +86,14 @@ function renderConsentViewContents(
|
|
|
85
86
|
}
|
|
86
87
|
|
|
87
88
|
// eslint-disable-next-line @devtools/no-imperative-dom-api
|
|
88
|
-
const settingsLink = document.createElement('
|
|
89
|
+
const settingsLink = document.createElement('devtools-link');
|
|
89
90
|
settingsLink.textContent = i18nString(UIStrings.settingsLink);
|
|
90
91
|
settingsLink.classList.add('link');
|
|
91
92
|
UI.ARIAUtils.markAsLink(settingsLink);
|
|
92
93
|
settingsLink.addEventListener('click', () => {
|
|
93
94
|
void UI.ViewManager.ViewManager.instance().showView('chrome-ai');
|
|
94
95
|
});
|
|
95
|
-
settingsLink.
|
|
96
|
+
settingsLink.jslogContext = 'open-ai-settings';
|
|
96
97
|
|
|
97
98
|
let consentViewContents: HTMLSpanElement;
|
|
98
99
|
if (hostConfig.devToolsAiAssistancePerformanceAgent?.enabled) {
|
|
@@ -1213,6 +1213,7 @@ export class NodeUI {
|
|
|
1213
1213
|
return;
|
|
1214
1214
|
}
|
|
1215
1215
|
this.element.setAttribute('data-backend-node-id', String(node.backendNodeId()));
|
|
1216
|
+
this.element.setAttribute('data-target-id', node.domModel().target().id());
|
|
1216
1217
|
this.#node = node;
|
|
1217
1218
|
this.nodeChanged();
|
|
1218
1219
|
const link = PanelsCommon.DOMLinkifier.Linkifier.instance().linkify(node, {
|
|
@@ -351,7 +351,7 @@ function renderDocumentSection(input: FrameDetailsViewInput): LitTemplate {
|
|
|
351
351
|
</div>
|
|
352
352
|
</devtools-report-value>
|
|
353
353
|
${maybeRenderUnreachableURL(input.frame?.unreachableUrl())}
|
|
354
|
-
${maybeRenderOrigin(input.frame?.securityOrigin)}
|
|
354
|
+
${maybeRenderOrigin(input.frame?.securityOrigin())}
|
|
355
355
|
${renderOwnerElement(input.linkTargetDOMNode)}
|
|
356
356
|
${maybeRenderCreationStacktrace(input.creationStackTrace)}
|
|
357
357
|
${maybeRenderAdStatus(input.frame?.adFrameType(), input.frame?.adFrameStatus())}
|
|
@@ -414,12 +414,13 @@ function renderNetworkLinkForUnreachableURL(unreachableUrlString: Platform.DevTo
|
|
|
414
414
|
return nothing;
|
|
415
415
|
}
|
|
416
416
|
|
|
417
|
-
function maybeRenderOrigin(securityOrigin:
|
|
418
|
-
if (securityOrigin && securityOrigin
|
|
417
|
+
function maybeRenderOrigin(securityOrigin: SDK.SecurityOrigin.SecurityOrigin|undefined): LitTemplate {
|
|
418
|
+
if (securityOrigin && !securityOrigin.isOpaque()) {
|
|
419
|
+
const originString = securityOrigin.siteId();
|
|
419
420
|
return html`
|
|
420
421
|
<devtools-report-key>${i18nString(UIStrings.origin)}</devtools-report-key>
|
|
421
422
|
<devtools-report-value>
|
|
422
|
-
<div class="text-ellipsis" title=${
|
|
423
|
+
<div class="text-ellipsis" title=${originString}>${originString}</div>
|
|
423
424
|
</devtools-report-value>
|
|
424
425
|
`;
|
|
425
426
|
}
|
|
@@ -289,14 +289,14 @@ const populateContextMenu = (e: CustomEvent<UI.ContextMenu.ContextMenu>): void =
|
|
|
289
289
|
const renderDataGrid = (input: IndexedDBDataViewInput): LitTemplate => {
|
|
290
290
|
const keyPath = input.isIndex && input.index ? input.index.keyPath : input.objectStore.keyPath;
|
|
291
291
|
// clang-format off
|
|
292
|
-
return html`<devtools-data-grid striped style="flex: auto;" name=${i18nString(UIStrings.indexedDb)} .template=${html`
|
|
292
|
+
return html`<devtools-data-grid row-height="auto" striped style="flex: auto;" name=${i18nString(UIStrings.indexedDb)} .template=${html`
|
|
293
293
|
<style>${indexedDBViewsStyles}</style>
|
|
294
294
|
<table>
|
|
295
295
|
<tr>
|
|
296
296
|
<th id="number" fixed width="50px">#</th>
|
|
297
|
-
<th id="key">${renderKeyColumnHeader(i18nString(UIStrings.keyString), keyPath)}</th>
|
|
298
|
-
${input.isIndex ? html`<th id="primary-key">${renderKeyColumnHeader(i18nString(UIStrings.primaryKey), input.objectStore.keyPath)}</th>` : nothing}
|
|
299
|
-
<th id="value">${i18nString(UIStrings.valueString)}</th>
|
|
297
|
+
<th id="key" weight="2">${renderKeyColumnHeader(i18nString(UIStrings.keyString), keyPath)}</th>
|
|
298
|
+
${input.isIndex ? html`<th id="primary-key" weight="2">${renderKeyColumnHeader(i18nString(UIStrings.primaryKey), input.objectStore.keyPath)}</th>` : nothing}
|
|
299
|
+
<th id="value" weight="8">${i18nString(UIStrings.valueString)}</th>
|
|
300
300
|
</tr>
|
|
301
301
|
${repeat(input.entries, (_entry, index) => index, (entry, index) => {
|
|
302
302
|
return html`
|
|
@@ -460,7 +460,7 @@ export class BackForwardCacheView extends UI.Widget.Widget {
|
|
|
460
460
|
#historyIndex = 0;
|
|
461
461
|
#view: View;
|
|
462
462
|
|
|
463
|
-
constructor(view = DEFAULT_VIEW) {
|
|
463
|
+
constructor(view: View = DEFAULT_VIEW) {
|
|
464
464
|
super({useShadowDom: true, delegatesFocus: true});
|
|
465
465
|
this.#view = view;
|
|
466
466
|
}
|
|
@@ -71,7 +71,8 @@ export const DEFAULT_VIEW = (input: ViewInput, output: undefined, target: HTMLEl
|
|
|
71
71
|
type View = typeof DEFAULT_VIEW;
|
|
72
72
|
|
|
73
73
|
export class EndpointsGrid extends UI.Widget.Widget {
|
|
74
|
-
endpoints
|
|
74
|
+
endpoints: Map<string, Protocol.Network.ReportingApiEndpoint[]> =
|
|
75
|
+
new Map<string, Protocol.Network.ReportingApiEndpoint[]>();
|
|
75
76
|
#view: View;
|
|
76
77
|
|
|
77
78
|
constructor(element?: HTMLElement, view: View = DEFAULT_VIEW) {
|
|
@@ -218,7 +218,7 @@ export class PermissionsPolicySection extends UI.Widget.Widget {
|
|
|
218
218
|
#showDetails = false;
|
|
219
219
|
#view: View;
|
|
220
220
|
|
|
221
|
-
constructor(element?: HTMLElement, view = DEFAULT_VIEW) {
|
|
221
|
+
constructor(element?: HTMLElement, view: View = DEFAULT_VIEW) {
|
|
222
222
|
super(element, {useShadowDom: false});
|
|
223
223
|
this.#view = view;
|
|
224
224
|
}
|
|
@@ -45,7 +45,7 @@ export class ServiceWorkerRouterView extends UI.Widget.Widget {
|
|
|
45
45
|
#rules: SDK.ServiceWorkerManager.ServiceWorkerRouterRule[] = [];
|
|
46
46
|
#view: View;
|
|
47
47
|
|
|
48
|
-
constructor(element?: HTMLElement, view = DEFAULT_VIEW) {
|
|
48
|
+
constructor(element?: HTMLElement, view: View = DEFAULT_VIEW) {
|
|
49
49
|
super(element, {useShadowDom: true});
|
|
50
50
|
this.#view = view;
|
|
51
51
|
}
|
|
@@ -141,7 +141,7 @@ export class TrustTokensView extends UI.Widget.VBox {
|
|
|
141
141
|
#tokens: Protocol.Storage.TrustTokens[] = [];
|
|
142
142
|
#view: View;
|
|
143
143
|
|
|
144
|
-
constructor(element?: HTMLElement, view = DEFAULT_VIEW) {
|
|
144
|
+
constructor(element?: HTMLElement, view: View = DEFAULT_VIEW) {
|
|
145
145
|
super(element, {useShadowDom: true});
|
|
146
146
|
this.#view = view;
|
|
147
147
|
}
|
|
@@ -32,20 +32,6 @@
|
|
|
32
32
|
color: inherit;
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
:host-context(.indexed-db-data-view) .section,
|
|
36
|
-
:host-context(.indexed-db-data-view) .section > .header,
|
|
37
|
-
:host-context(.indexed-db-data-view) .section > .header .title {
|
|
38
|
-
margin: 0;
|
|
39
|
-
min-height: inherit;
|
|
40
|
-
line-height: inherit;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
:host-context(.indexed-db-data-view) .data-grid .data-container td .section .header .title {
|
|
44
|
-
white-space: nowrap;
|
|
45
|
-
text-overflow: ellipsis;
|
|
46
|
-
overflow: hidden;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
35
|
.indexed-db-key-path {
|
|
50
36
|
color: var(--sys-color-error);
|
|
51
37
|
white-space: pre-wrap;
|
|
@@ -443,7 +443,8 @@ export class PreloadingDetailsReportView extends UI.Widget.VBox {
|
|
|
443
443
|
#data: PreloadingDetailsReportViewData = null;
|
|
444
444
|
#view: typeof DEFAULT_VIEW;
|
|
445
445
|
|
|
446
|
-
constructor(element?: HTMLElement,
|
|
446
|
+
constructor(element?: HTMLElement,
|
|
447
|
+
view: (input: ViewInput, _output: undefined, target: HTMLElement) => void = DEFAULT_VIEW) {
|
|
447
448
|
super(element);
|
|
448
449
|
this.#view = view;
|
|
449
450
|
}
|
|
@@ -79,7 +79,8 @@ export class RuleSetDetailsView extends UI.Widget.VBox {
|
|
|
79
79
|
#ruleSet: RuleSet|null = null;
|
|
80
80
|
#shouldPrettyPrint = true;
|
|
81
81
|
|
|
82
|
-
constructor(element?: HTMLElement,
|
|
82
|
+
constructor(element?: HTMLElement,
|
|
83
|
+
view: (input: ViewInput|null, _output: object, target: HTMLElement) => void = DEFAULT_VIEW) {
|
|
83
84
|
super(element, {useShadowDom: true});
|
|
84
85
|
this.#view = view;
|
|
85
86
|
}
|
|
@@ -425,7 +425,7 @@ const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
425
425
|
export class UsedPreloadingView extends UI.Widget.VBox {
|
|
426
426
|
readonly #view: View;
|
|
427
427
|
|
|
428
|
-
constructor(view = DEFAULT_VIEW) {
|
|
428
|
+
constructor(view: View = DEFAULT_VIEW) {
|
|
429
429
|
super({useShadowDom: true});
|
|
430
430
|
this.#view = view;
|
|
431
431
|
}
|