chrome-devtools-frontend 1.0.1664496 → 1.0.1665921
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-testing-guidance/SKILL.md +48 -0
- package/.agents/skills/devtools-ux-writing-refactor/SKILL.md +3 -3
- package/.agents/skills/repro-flaky-tests/SKILL.md +2 -2
- package/.agents/skills/ui-eng-vision-local-lit-renderer/SKILL.md +7 -1
- package/.agents/skills/ui-eng-vision-widget-promoter/SKILL.md +2 -0
- package/.agents/skills/version-control/SKILL.md +4 -3
- package/docs/ui_engineering.md +89 -0
- package/eslint.config.mjs +9 -2
- package/front_end/Images/rollup.config.mjs +1 -1
- package/front_end/Tests.js +15 -16
- package/front_end/core/common/Gzip.ts +2 -2
- package/front_end/core/common/Settings.ts +4 -20
- package/front_end/core/common/Srcset.ts +1 -1
- package/front_end/core/common/VersionController.ts +1 -1
- package/front_end/core/host/AidaClient.ts +19 -4
- package/front_end/core/host/AidaGcaTranslation.ts +2 -2
- package/front_end/core/host/GcaClient.ts +2 -2
- package/front_end/core/host/GdpClient.ts +3 -3
- package/front_end/core/host/InspectorFrontendHostStub.ts +1 -1
- package/front_end/core/host/ResourceLoader.ts +15 -15
- package/front_end/core/protocol_client/DevToolsCDPConnection.ts +2 -2
- package/front_end/core/protocol_client/InspectorBackend.ts +1 -1
- package/front_end/core/root/Runtime.ts +0 -1
- package/front_end/core/sdk/CSSMatchedStyles.ts +78 -3
- package/front_end/core/sdk/CSSMetadata.ts +17 -12
- package/front_end/core/sdk/CSSProperty.ts +1 -1
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +2 -2
- package/front_end/core/sdk/CSSRule.ts +3 -3
- package/front_end/core/sdk/CSSStyleSheetHeader.ts +3 -3
- package/front_end/core/sdk/CompilerSourceMappingContentProvider.ts +1 -1
- package/front_end/core/sdk/Connections.ts +1 -1
- package/front_end/core/sdk/DebuggerModel.ts +13 -13
- package/front_end/core/sdk/NetworkManager.ts +19 -19
- package/front_end/core/sdk/NetworkRequest.ts +57 -57
- package/front_end/core/sdk/OverlayModel.ts +1 -1
- package/front_end/core/sdk/PageResourceLoader.ts +2 -2
- package/front_end/core/sdk/RehydratingConnection.ts +5 -5
- package/front_end/core/sdk/ScreenCaptureModel.ts +1 -1
- package/front_end/core/sdk/Script.ts +2 -2
- package/front_end/core/sdk/ServerTiming.ts +7 -7
- package/front_end/core/sdk/ServiceWorkerCacheModel.ts +1 -1
- package/front_end/core/sdk/ServiceWorkerManager.ts +11 -11
- package/front_end/core/sdk/SourceMapScopeChainEntry.ts +2 -2
- package/front_end/core/sdk/SourceMapScopesInfo.ts +1 -1
- package/front_end/core/sdk/StorageKeyManager.ts +1 -1
- package/front_end/core/sdk/sdk-meta.ts +98 -98
- package/front_end/devtools_compatibility.js +15 -13
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +4 -8
- package/front_end/entrypoints/main/MainImpl.ts +2 -3
- package/front_end/entrypoints/main/main-meta.ts +1 -16
- package/front_end/entrypoints/shell/shell.ts +1 -0
- package/front_end/entrypoints/trace_app/trace_app.ts +1 -0
- package/front_end/foundation/README.md +1 -1
- package/front_end/foundation/Universe.test.api.ts +73 -0
- package/front_end/foundation/Universe.ts +22 -0
- package/front_end/generated/InspectorBackendCommands.ts +2 -2
- package/front_end/generated/SupportedCSSProperties.js +1 -1
- package/front_end/generated/protocol.ts +19 -0
- package/front_end/models/ai_assistance/AiAgent2.ts +1 -1
- package/front_end/models/ai_assistance/AiConversation.ts +1 -1
- package/front_end/models/ai_assistance/BuiltInAi.ts +1 -1
- package/front_end/models/ai_assistance/ChangeManager.ts +0 -70
- package/front_end/models/ai_assistance/ExtensionScope.ts +2 -36
- package/front_end/models/ai_assistance/agents/AccessibilityAgent.ts +9 -9
- package/front_end/models/ai_assistance/agents/AiAgent.ts +10 -2
- package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +4 -4
- package/front_end/models/ai_assistance/agents/ExecuteJavascript.ts +1 -1
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +21 -21
- package/front_end/models/ai_assistance/agents/StorageAgent.ts +4 -4
- package/front_end/models/ai_assistance/agents/StylingAgent.ts +1 -1
- package/front_end/models/ai_assistance/ai_assistance.ts +0 -5
- package/front_end/models/ai_assistance/data_formatters/FileFormatter.ts +11 -4
- package/front_end/models/ai_assistance/data_formatters/NetworkRequestFormatter.ts +8 -2
- package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.ts +14 -11
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +2 -2
- package/front_end/models/ai_assistance/performance/AICallTree.ts +2 -2
- package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +1 -1
- package/front_end/models/ai_assistance/tools/GetNetworkRequestDetails.ts +9 -2
- package/front_end/models/ai_assistance/tools/GetStyles.ts +4 -4
- package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +2 -5
- package/front_end/models/ai_code_completion/AiCodeCompletion.ts +2 -2
- package/front_end/models/ai_code_generation/AiCodeGeneration.ts +2 -2
- package/front_end/models/badges/badges-meta.ts +27 -0
- package/front_end/models/bindings/CSSWorkspaceBinding.ts +4 -3
- package/front_end/models/bindings/ContentProviderBasedProject.ts +1 -1
- package/front_end/models/bindings/DebuggerLanguagePlugins.ts +6 -7
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +5 -4
- package/front_end/models/bindings/PresentationConsoleMessageHelper.ts +72 -29
- package/front_end/models/bindings/ResourceMapping.ts +38 -32
- package/front_end/models/bindings/ResourceScriptMapping.ts +5 -7
- package/front_end/models/breakpoints/BreakpointManager.ts +2 -1
- package/front_end/models/har/Writer.ts +2 -2
- package/front_end/models/issues_manager/ElementAccessibilityIssue.ts +1 -1
- package/front_end/models/issues_manager/GenericIssue.ts +1 -1
- package/front_end/models/issues_manager/IssuesManager.ts +14 -5
- package/front_end/models/issues_manager/PartitioningBlobURLIssue.ts +1 -1
- package/front_end/models/issues_manager/SRIMessageSignatureIssue.ts +2 -2
- package/front_end/models/issues_manager/SourceFrameIssuesManager.ts +13 -2
- package/front_end/models/issues_manager/issues_manager.ts +0 -2
- package/front_end/models/live-metrics/LiveMetrics.ts +22 -5
- package/front_end/models/live-metrics/web-vitals-injected/rollup.config.mjs +1 -1
- package/front_end/models/live-metrics/web-vitals-injected/spec/spec.ts +10 -4
- package/front_end/models/logs/logs-meta.ts +23 -16
- package/front_end/models/persistence/AutomaticFileSystemWorkspaceBinding.ts +2 -2
- package/front_end/models/persistence/IsolatedFileSystem.ts +1 -1
- package/front_end/models/persistence/IsolatedFileSystemManager.ts +1 -1
- package/front_end/models/source_map_scopes/NamesResolver.ts +104 -86
- package/front_end/models/source_map_scopes/ScopeChainModel.ts +6 -2
- package/front_end/models/stack_trace/StackTraceModel.ts +1 -1
- package/front_end/models/trace/handlers/ExtensionTraceDataHandler.ts +1 -1
- package/front_end/models/trace/handlers/UserTimingsHandler.ts +17 -6
- package/front_end/models/trace/helpers/SamplesIntegrator.ts +1 -1
- package/front_end/models/trace/helpers/Timing.ts +1 -1
- package/front_end/models/trace/insights/Common.ts +1 -1
- package/front_end/models/trace/insights/DocumentLatency.ts +3 -3
- package/front_end/models/trace/insights/LCPDiscovery.ts +1 -1
- package/front_end/models/trace/insights/ModernHTTP.ts +1 -1
- package/front_end/models/trace_source_maps_resolver/SourceMapsResolver.ts +2 -2
- package/front_end/models/workspace_diff/WorkspaceDiff.ts +14 -9
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +2 -15
- package/front_end/panels/ai_assistance/ai_assistance.ts +1 -2
- package/front_end/panels/ai_assistance/components/ChatInput.ts +23 -19
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +9 -18
- package/front_end/panels/ai_assistance/components/ChatView.ts +2 -35
- package/front_end/panels/ai_assistance/components/DisabledWidget.ts +1 -1
- package/front_end/panels/ai_assistance/components/ExploreWidget.ts +4 -4
- package/front_end/panels/ai_assistance/components/ImageResize.ts +74 -0
- package/front_end/panels/ai_assistance/components/WalkthroughView.ts +2 -2
- package/front_end/panels/animation/AnimationGroupPreviewUI.ts +28 -29
- package/front_end/panels/animation/AnimationTimeline.ts +3 -3
- package/front_end/panels/animation/animationTimeline.css +0 -2
- package/front_end/panels/application/AppManifestView.ts +1 -1
- package/front_end/panels/application/ApplicationPanelSidebar.ts +1 -1
- package/front_end/panels/application/CookieItemsView.ts +1 -1
- package/front_end/panels/application/CrashReportContextView.ts +3 -3
- package/front_end/panels/application/DeviceBoundSessionsModel.ts +1 -1
- package/front_end/panels/application/DeviceBoundSessionsTreeElement.ts +1 -1
- package/front_end/panels/application/DeviceBoundSessionsView.ts +1 -1
- package/front_end/panels/application/IndexedDBViews.ts +1 -1
- package/front_end/panels/application/KeyValueStorageItemsView.ts +1 -1
- package/front_end/panels/application/OriginTrialTreeView.ts +1 -1
- package/front_end/panels/application/ServiceWorkersView.ts +6 -6
- package/front_end/panels/application/StorageBucketsTreeElement.ts +1 -1
- package/front_end/panels/application/StorageItemsToolbar.ts +3 -3
- package/front_end/panels/application/WebMCPView.ts +7 -5
- package/front_end/panels/application/components/AdsView.ts +21 -6
- package/front_end/panels/application/components/BackForwardCacheView.ts +2 -2
- package/front_end/panels/application/components/ProtocolHandlersView.ts +1 -1
- package/front_end/panels/application/components/StorageMetadataView.ts +1 -1
- package/front_end/panels/application/preloading/components/MismatchedPreloadingGrid.ts +2 -2
- package/front_end/panels/application/preloading/components/PreloadingDetailsReportView.ts +2 -1
- package/front_end/panels/application/preloading/components/PreloadingString.ts +3 -3
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +2 -1
- package/front_end/panels/autofill/AutofillView.ts +1 -1
- package/front_end/panels/browser_debugger/DOMBreakpointsSidebarPane.ts +1 -1
- package/front_end/panels/browser_debugger/XHRBreakpointsSidebarPane.ts +2 -2
- package/front_end/panels/changes/ChangesSidebar.ts +2 -2
- package/front_end/panels/changes/ChangesView.ts +4 -5
- package/front_end/panels/changes/CombinedDiffView.ts +3 -3
- package/front_end/panels/changes/changes-meta.ts +2 -2
- package/front_end/panels/common/AiCodeCompletionTeaser.ts +1 -1
- package/front_end/panels/common/AiCodeGenerationTeaser.ts +3 -3
- package/front_end/panels/common/BadgeNotification.ts +8 -8
- package/front_end/panels/common/DOMLinkifier.ts +1 -1
- package/front_end/panels/common/GdpSignUpDialog.ts +2 -2
- package/front_end/panels/common/GeminiRebrandPromoDialog.ts +1 -1
- package/front_end/panels/common/aiCodeCompletionDisclaimer.css +0 -1
- package/front_end/panels/console/ConsoleInsightTeaser.ts +1 -1
- package/front_end/panels/console/ConsolePinPane.ts +3 -3
- package/front_end/panels/console/ConsolePrompt.ts +6 -4
- package/front_end/panels/console/ConsoleSidebar.ts +8 -10
- package/front_end/panels/console_counters/WarningErrorCounter.ts +10 -11
- package/front_end/panels/coverage/CoverageView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +3 -3
- package/front_end/panels/css_overview/CSSOverviewSidebarPanel.ts +1 -1
- package/front_end/panels/developer_resources/DeveloperResourcesView.ts +1 -1
- package/front_end/panels/elements/CSSRuleValidator.ts +1 -1
- package/front_end/panels/elements/ComputedStyleWidget.ts +3 -2
- package/front_end/panels/elements/ElementsTreeElement.ts +3 -3
- package/front_end/panels/elements/EventListenersWidget.ts +1 -3
- package/front_end/panels/elements/LayoutPane.ts +23 -13
- package/front_end/panels/elements/StandaloneStylesContainer.ts +7 -7
- package/front_end/panels/elements/StylePropertiesSection.ts +33 -5
- package/front_end/panels/elements/StylePropertyTreeElement.ts +5 -5
- package/front_end/panels/elements/StylesAiCodeCompletionProvider.ts +6 -6
- package/front_end/panels/elements/StylesSidebarPane.ts +4 -3
- package/front_end/panels/elements/elements-meta.ts +18 -2
- package/front_end/panels/emulation/DeviceModeToolbar.ts +100 -40
- package/front_end/panels/emulation/DeviceModeView.ts +5 -4
- package/front_end/panels/emulation/MediaQueryInspector.ts +35 -19
- package/front_end/panels/event_listeners/EventListenersView.ts +4 -4
- package/front_end/panels/explain/components/ConsoleInsight.ts +8 -9
- package/front_end/panels/explain/explain-meta.ts +3 -3
- package/front_end/panels/layer_viewer/LayerTreeOutline.ts +135 -167
- package/front_end/panels/layer_viewer/Layers3DView.ts +10 -23
- package/front_end/panels/layer_viewer/layer_viewer-meta.ts +27 -0
- package/front_end/panels/lighthouse/LighthouseController.ts +44 -55
- package/front_end/panels/lighthouse/LighthousePanel.ts +9 -9
- package/front_end/panels/lighthouse/LighthouseReportSelector.ts +2 -2
- package/front_end/panels/lighthouse/LighthouseStartView.ts +9 -12
- package/front_end/panels/lighthouse/LighthouseStatusView.ts +33 -33
- package/front_end/panels/lighthouse/RadioSetting.ts +1 -1
- package/front_end/panels/lighthouse/lighthouse-meta.ts +131 -1
- package/front_end/panels/media/EventDisplayTable.ts +67 -94
- package/front_end/panels/media/PlayerListView.ts +1 -1
- package/front_end/panels/media/eventDisplayTable.css +9 -4
- package/front_end/panels/mobile_throttling/NetworkThrottlingSelector.ts +5 -5
- package/front_end/panels/mobile_throttling/ThrottlingSettingsTab.ts +1 -1
- package/front_end/panels/network/EventSourceMessagesView.ts +98 -107
- package/front_end/panels/network/NetworkLogViewColumns.ts +1 -1
- package/front_end/panels/network/NetworkWaterfallColumn.ts +1 -1
- package/front_end/panels/network/RequestConditionsDrawer.ts +2 -2
- package/front_end/panels/network/RequestCookiesView.ts +2 -2
- package/front_end/panels/network/RequestHeadersView.ts +5 -5
- package/front_end/panels/network/RequestPayloadView.ts +4 -4
- package/front_end/panels/network/RequestTimingView.ts +2 -2
- package/front_end/panels/network/components/DirectSocketConnectionView.ts +1 -1
- package/front_end/panels/network/eventSourceMessagesView.css +12 -3
- package/front_end/panels/network/networkTimingTable.css +2 -2
- package/front_end/panels/performance_monitor/PerformanceMonitor.ts +1 -1
- package/front_end/panels/profiler/BottomUpProfileDataGrid.ts +25 -29
- package/front_end/panels/profiler/HeapProfileView.ts +308 -247
- package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +13 -3
- package/front_end/panels/profiler/HeapSnapshotView.ts +30 -10
- package/front_end/panels/profiler/HeapTimelineOverview.ts +5 -2
- package/front_end/panels/profiler/ProfileDataGrid.ts +128 -157
- package/front_end/panels/profiler/ProfileFlameChartDataProvider.ts +17 -5
- package/front_end/panels/profiler/ProfilesPanel.ts +2 -2
- package/front_end/panels/profiler/TopDownProfileDataGrid.ts +17 -21
- package/front_end/panels/profiler/profilesPanel.css +9 -13
- package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +2 -2
- package/front_end/panels/recorder/CreateRecordingView.ts +4 -4
- package/front_end/panels/recorder/RecorderPanel.ts +6 -6
- package/front_end/panels/recorder/RecordingView.ts +1 -1
- package/front_end/panels/recorder/ReplaySection.ts +1 -1
- package/front_end/panels/recorder/StepView.ts +1 -1
- package/front_end/panels/recorder/injected/rollup.config.mjs +1 -1
- package/front_end/panels/search/SearchView.ts +1 -1
- package/front_end/panels/security/SecurityPanel.ts +54 -41
- package/front_end/panels/sensors/LocationsSettingsTab.ts +246 -233
- package/front_end/panels/sensors/SensorsView.ts +1 -1
- package/front_end/panels/settings/AISettingsTab.ts +11 -10
- package/front_end/panels/settings/SettingsScreen.ts +29 -24
- package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +2 -2
- package/front_end/panels/sources/AiCodeCompletionPlugin.ts +5 -5
- package/front_end/panels/sources/BreakpointEditDialog.ts +2 -2
- package/front_end/panels/sources/BreakpointsView.ts +1 -1
- package/front_end/panels/sources/CallStackSidebarPane.ts +2 -2
- package/front_end/panels/sources/DebuggerPausedMessage.ts +2 -2
- package/front_end/panels/sources/DebuggerPlugin.ts +25 -22
- package/front_end/panels/sources/ScopeChainSidebarPane.ts +3 -1
- package/front_end/panels/sources/WatchExpressionsSidebarPane.ts +7 -5
- package/front_end/panels/sources/sources-meta.ts +1 -1
- package/front_end/panels/timeline/CountersGraph.ts +1 -2
- package/front_end/panels/timeline/ExtensionTrackAppender.ts +1 -1
- package/front_end/panels/timeline/TimelineDetailsView.ts +2 -2
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +2 -2
- package/front_end/panels/timeline/TimelineFlameChartView.ts +4 -4
- package/front_end/panels/timeline/TimelinePaintProfilerView.ts +1 -1
- package/front_end/panels/timeline/TimelinePanel.ts +53 -81
- package/front_end/panels/timeline/TimelineSelectorStatsView.ts +10 -3
- package/front_end/panels/timeline/TimelineUIUtils.ts +18 -4
- package/front_end/panels/timeline/TrackConfigBanner.ts +1 -1
- package/front_end/panels/timeline/components/ExportTraceOptions.ts +1 -1
- package/front_end/panels/timeline/components/LayoutShiftDetails.ts +8 -9
- package/front_end/panels/timeline/components/NetworkRequestTooltip.ts +1 -1
- package/front_end/panels/timeline/components/TimelineRangeSummaryView.ts +1 -1
- package/front_end/panels/timeline/components/insights/DuplicatedJavaScript.ts +2 -2
- package/front_end/panels/timeline/components/insights/LCPBreakdown.ts +1 -1
- package/front_end/panels/timeline/components/insights/LegacyJavaScript.ts +1 -1
- package/front_end/panels/timeline/components/insights/SlowCSSSelector.ts +2 -2
- package/front_end/panels/timeline/overlays/OverlaysImpl.ts +5 -0
- package/front_end/panels/timeline/overlays/components/TimespanBreakdownOverlay.ts +13 -8
- package/front_end/panels/timeline/overlays/components/timespanBreakdownOverlay.css +1 -0
- package/front_end/panels/timeline/timeline-meta.ts +169 -0
- package/front_end/panels/timeline/timelineFlameChartView.css +5 -0
- package/front_end/panels/webauthn/WebauthnPane.ts +1 -1
- package/front_end/panels/whats_new/ReleaseNoteText.ts +9 -9
- package/front_end/panels/whats_new/resources/WNDT.md +7 -8
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/web-vitals/README.chromium +2 -2
- package/front_end/third_party/web-vitals/package/README.md +120 -19
- package/front_end/third_party/web-vitals/package/attribution.d.ts +16 -0
- package/front_end/third_party/web-vitals/package/attribution.js +18 -0
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onCLS.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFCP.d.ts +1 -7
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onFCP.js +53 -32
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.d.ts +2 -2
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onINP.js +43 -12
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onLCP.js +21 -3
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onTTFB.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/attribution/onTTFB.js +30 -24
- package/front_end/third_party/web-vitals/package/dist/modules/lib/FCPEntryManager.d.ts +3 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/FCPEntryManager.js +18 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.d.ts +2 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/InteractionManager.js +18 -2
- package/front_end/third_party/web-vitals/package/dist/modules/lib/LCPEntryManager.d.ts +1 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/LCPEntryManager.js +1 -0
- 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/generateUniqueID.js +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/getLoadState.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/getLoadState.js +7 -7
- package/front_end/third_party/web-vitals/package/dist/modules/lib/getSelector.js +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/getVisibilityWatcher.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/getVisibilityWatcher.js +4 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.d.ts +7 -3
- package/front_end/third_party/web-vitals/package/dist/modules/lib/initMetric.js +20 -11
- package/front_end/third_party/web-vitals/package/dist/modules/lib/initUnique.js +8 -3
- package/front_end/third_party/web-vitals/package/dist/modules/lib/observe.d.ts +3 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/observe.js +19 -4
- package/front_end/third_party/web-vitals/package/dist/modules/lib/polyfills/interactionCountPolyfill.js +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/lib/softNavs.d.ts +3 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/softNavs.js +38 -0
- package/front_end/third_party/web-vitals/package/dist/modules/lib/whenIdleOrHidden.js +5 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onCLS.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onCLS.js +30 -11
- package/front_end/third_party/web-vitals/package/dist/modules/onFCP.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onFCP.js +36 -4
- package/front_end/third_party/web-vitals/package/dist/modules/onINP.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onINP.js +42 -22
- package/front_end/third_party/web-vitals/package/dist/modules/onLCP.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onLCP.js +109 -30
- package/front_end/third_party/web-vitals/package/dist/modules/onTTFB.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/onTTFB.js +25 -7
- package/front_end/third_party/web-vitals/package/dist/modules/types/base.d.ts +24 -1
- package/front_end/third_party/web-vitals/package/dist/modules/types/fcp.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/types/inp.d.ts +14 -6
- package/front_end/third_party/web-vitals/package/dist/modules/types/lcp.d.ts +1 -1
- package/front_end/third_party/web-vitals/package/dist/modules/types/ttfb.d.ts +2 -2
- package/front_end/third_party/web-vitals/package/dist/modules/types.d.ts +26 -4
- package/front_end/third_party/web-vitals/package/package.json +21 -22
- package/front_end/third_party/web-vitals/package/src/attribution/onCLS.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/attribution/onFCP.ts +62 -39
- package/front_end/third_party/web-vitals/package/src/attribution/onINP.ts +52 -15
- package/front_end/third_party/web-vitals/package/src/attribution/onLCP.ts +25 -7
- package/front_end/third_party/web-vitals/package/src/attribution/onTTFB.ts +43 -37
- package/front_end/third_party/web-vitals/package/src/lib/{polyfills/getFirstHiddenTimePolyfill.ts → FCPEntryManager.ts} +4 -14
- package/front_end/third_party/web-vitals/package/src/lib/InteractionManager.ts +22 -2
- package/front_end/third_party/web-vitals/package/src/lib/LCPEntryManager.ts +1 -0
- package/front_end/third_party/web-vitals/package/src/lib/bindReporter.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/lib/generateUniqueID.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/lib/getLoadState.ts +11 -12
- package/front_end/third_party/web-vitals/package/src/lib/getSelector.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/lib/getVisibilityWatcher.ts +4 -1
- package/front_end/third_party/web-vitals/package/src/lib/initMetric.ts +24 -11
- package/front_end/third_party/web-vitals/package/src/lib/initUnique.ts +12 -4
- package/front_end/third_party/web-vitals/package/src/lib/observe.ts +26 -5
- package/front_end/third_party/web-vitals/package/src/lib/polyfills/interactionCountPolyfill.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/lib/softNavs.ts +48 -0
- package/front_end/third_party/web-vitals/package/src/lib/whenIdleOrHidden.ts +12 -4
- package/front_end/third_party/web-vitals/package/src/onCLS.ts +75 -18
- package/front_end/third_party/web-vitals/package/src/onFCP.ts +66 -7
- package/front_end/third_party/web-vitals/package/src/onINP.ts +100 -39
- package/front_end/third_party/web-vitals/package/src/onLCP.ts +169 -34
- package/front_end/third_party/web-vitals/package/src/onTTFB.ts +50 -13
- package/front_end/third_party/web-vitals/package/src/types/base.ts +31 -10
- package/front_end/third_party/web-vitals/package/src/types/fcp.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/types/inp.ts +14 -6
- package/front_end/third_party/web-vitals/package/src/types/lcp.ts +1 -1
- package/front_end/third_party/web-vitals/package/src/types/ttfb.ts +2 -2
- package/front_end/third_party/web-vitals/package/src/types.ts +32 -9
- package/front_end/third_party/web-vitals/patches/0001-Add-onEachInteraction-to-onINP-options.patch +11 -11
- package/front_end/third_party/web-vitals/rebuild.sh +2 -2
- package/front_end/third_party/web-vitals/web-vitals-tsconfig.json +2 -0
- package/front_end/ui/components/buttons/Button.ts +16 -0
- package/front_end/ui/components/dialogs/Dialog.ts +1 -1
- package/front_end/ui/components/highlighting/HighlightManager.ts +6 -1
- package/front_end/ui/components/highlighting/highlighting.ts +1 -1
- package/front_end/ui/components/icon_button/FileSourceIcon.ts +1 -1
- package/front_end/ui/components/linkifier/LinkifierImpl.ts +1 -1
- package/front_end/ui/components/markdown_view/MarkdownLinksMap.ts +2 -2
- package/front_end/ui/components/settings/SettingCheckbox.ts +12 -7
- package/front_end/ui/components/text_editor/AiCodeCompletionProvider.ts +2 -2
- package/front_end/ui/components/text_editor/AiCodeGenerationProvider.ts +6 -6
- package/front_end/ui/components/text_editor/javascript.ts +3 -1
- package/front_end/ui/components/tooltips/Tooltip.ts +1 -1
- package/front_end/ui/legacy/ContextMenu.ts +12 -2
- package/front_end/ui/legacy/ListControl.ts +1 -1
- package/front_end/ui/legacy/SelectMenu.docs.ts +17 -19
- package/front_end/ui/legacy/Toolbar.ts +4 -1
- package/front_end/ui/legacy/Treeoutline.ts +1 -1
- package/front_end/ui/legacy/components/color_picker/spectrum.css +1 -2
- package/front_end/ui/legacy/components/data_grid/DataGrid.ts +1 -1
- package/front_end/ui/legacy/components/data_grid/DataGridElement.ts +50 -4
- package/front_end/ui/legacy/components/object_ui/JavaScriptREPL.ts +3 -1
- package/front_end/ui/legacy/components/perf_ui/ChartViewport.ts +4 -4
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +8 -7
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +14 -11
- package/front_end/ui/legacy/components/quick_open/QuickOpen.ts +1 -1
- package/front_end/ui/legacy/components/settings_ui/SettingsUI.ts +15 -5
- package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +4 -4
- package/front_end/ui/legacy/components/utils/Linkifier.ts +5 -1
- package/front_end/ui/lit/render.ts +1 -1
- package/front_end/ui/settings/SettingUIRegistration.ts +8 -3
- package/front_end/ui/visual_logging/KnownContextValues.ts +8 -0
- package/front_end/ui/visual_logging/LoggingEvents.ts +1 -1
- package/inspector_overlay/main.ts +1 -1
- package/mcp/mcp.ts +5 -4
- package/package.json +13 -13
- package/front_end/models/ai_assistance/AgentProject.ts +0 -261
- package/front_end/models/ai_assistance/agents/PatchAgent.ts +0 -306
- package/front_end/models/issues_manager/CheckFormsIssuesTrigger.ts +0 -45
- package/front_end/models/text_utils/text_utils.ts +0 -5
- package/front_end/panels/ai_assistance/PatchWidget.ts +0 -867
- package/front_end/panels/ai_assistance/SelectWorkspaceDialog.ts +0 -368
- package/front_end/panels/ai_assistance/selectWorkspaceDialog.css +0 -92
|
@@ -35,11 +35,11 @@ const UIStringsNotTranslate = {
|
|
|
35
35
|
/**
|
|
36
36
|
* @description Aria label for teaser to generate code.
|
|
37
37
|
*/
|
|
38
|
-
pressCtrlPeriodToLearnHowYourDataIsBeingUsed: 'Press ctrl . (
|
|
38
|
+
pressCtrlPeriodToLearnHowYourDataIsBeingUsed: 'Press ctrl . (period) to learn how your data is being used.',
|
|
39
39
|
/**
|
|
40
40
|
* @description Aria label for teaser to generate code in Mac.
|
|
41
41
|
*/
|
|
42
|
-
pressCmdPeriodToLearnHowYourDataIsBeingUsed: 'Press cmd . (
|
|
42
|
+
pressCmdPeriodToLearnHowYourDataIsBeingUsed: 'Press cmd . (period) to learn how your data is being used.',
|
|
43
43
|
/**
|
|
44
44
|
* @description Text for teaser when generating suggestion.
|
|
45
45
|
*/
|
|
@@ -314,7 +314,7 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
314
314
|
<div class="ai-code-generation-teaser">
|
|
315
315
|
${teaserLabel}
|
|
316
316
|
</div>
|
|
317
|
-
`, target
|
|
317
|
+
`, target,
|
|
318
318
|
);
|
|
319
319
|
// clang-format on
|
|
320
320
|
};
|
|
@@ -206,7 +206,7 @@ export class BadgeNotification extends UI.Widget.Widget {
|
|
|
206
206
|
PH1: badge.title,
|
|
207
207
|
PH2:
|
|
208
208
|
html`<devtools-link class="badge-link" href="https://developers.google.com/program" jslogcontext="program-link">${
|
|
209
|
-
lockedString('Google Developer Program')}</devtools-link
|
|
209
|
+
lockedString('Google Developer Program')}</devtools-link>`,
|
|
210
210
|
}),
|
|
211
211
|
jslogContext: badge.jslogContext,
|
|
212
212
|
actions: [
|
|
@@ -223,8 +223,8 @@ export class BadgeNotification extends UI.Widget.Widget {
|
|
|
223
223
|
onClick: () => {
|
|
224
224
|
this.detach();
|
|
225
225
|
revealBadgeSettings();
|
|
226
|
-
}
|
|
227
|
-
}
|
|
226
|
+
},
|
|
227
|
+
},
|
|
228
228
|
],
|
|
229
229
|
imageUri: badge.imageUri,
|
|
230
230
|
isStarterBadge: true,
|
|
@@ -236,7 +236,7 @@ export class BadgeNotification extends UI.Widget.Widget {
|
|
|
236
236
|
message: i18nFormatStringTemplate(UIStrings.starterBadgeAwardMessageNoGdpProfile, {
|
|
237
237
|
PH1: badge.title,
|
|
238
238
|
PH2: html`<devtools-link class="badge-link" href="https://developers.google.com/program" .jslogContext=${
|
|
239
|
-
'program-link'}>${lockedString('Google Developer Program')}</devtools-link
|
|
239
|
+
'program-link'}>${lockedString('Google Developer Program')}</devtools-link>`,
|
|
240
240
|
}),
|
|
241
241
|
jslogContext: badge.jslogContext,
|
|
242
242
|
actions: [
|
|
@@ -256,8 +256,8 @@ export class BadgeNotification extends UI.Widget.Widget {
|
|
|
256
256
|
// We want to consider cancelling from the starter badge as a "snooze" for starter badge.
|
|
257
257
|
onCancel: () => Badges.UserBadges.instance().snoozeStarterBadge(),
|
|
258
258
|
});
|
|
259
|
-
}
|
|
260
|
-
}
|
|
259
|
+
},
|
|
260
|
+
},
|
|
261
261
|
],
|
|
262
262
|
imageUri: badge.imageUri,
|
|
263
263
|
isStarterBadge: true,
|
|
@@ -282,8 +282,8 @@ export class BadgeNotification extends UI.Widget.Widget {
|
|
|
282
282
|
jslogContext: 'view-profile',
|
|
283
283
|
onClick: () => {
|
|
284
284
|
UIHelpers.openInNewTab(Host.GdpClient.GOOGLE_DEVELOPER_PROGRAM_PROFILE_LINK);
|
|
285
|
-
}
|
|
286
|
-
}
|
|
285
|
+
},
|
|
286
|
+
},
|
|
287
287
|
],
|
|
288
288
|
imageUri: badge.imageUri,
|
|
289
289
|
isStarterBadge: badge.isStarterBadge,
|
|
@@ -61,7 +61,7 @@ const DEFAULT_VIEW: View = (input, _output, target: HTMLElement) => {
|
|
|
61
61
|
<span class="monospace">
|
|
62
62
|
<button class="node-link text-button link-style ${classMap({
|
|
63
63
|
'dynamic-link': Boolean(input.dynamic),
|
|
64
|
-
disabled: Boolean(input.disabled)
|
|
64
|
+
disabled: Boolean(input.disabled),
|
|
65
65
|
})}"
|
|
66
66
|
aria-description=${ifDefined(input.ariaDescription)}
|
|
67
67
|
jslog=${VisualLogging.link('node').track({click: true, keydown: 'Enter'})}
|
|
@@ -90,7 +90,7 @@ const UIStrings = {
|
|
|
90
90
|
/**
|
|
91
91
|
* @description Error message shown in a snackbar when GDP sign up fails.
|
|
92
92
|
*/
|
|
93
|
-
signUpFailed: 'Your Google Developer Program profile couldn’t be created. Please try again later.'
|
|
93
|
+
signUpFailed: 'Your Google Developer Program profile couldn’t be created. Please try again later.',
|
|
94
94
|
} as const;
|
|
95
95
|
|
|
96
96
|
const str_ = i18n.i18n.registerUIStrings('panels/common/GdpSignUpDialog.ts', UIStrings);
|
|
@@ -183,7 +183,7 @@ export const DEFAULT_VIEW: View = (input, _output, target): void => {
|
|
|
183
183
|
</div>
|
|
184
184
|
</div>
|
|
185
185
|
`,
|
|
186
|
-
target
|
|
186
|
+
target,
|
|
187
187
|
);
|
|
188
188
|
// clang-format on
|
|
189
189
|
};
|
|
@@ -518,7 +518,7 @@ export class ConsoleInsightTeaser extends UI.Widget.Widget {
|
|
|
518
518
|
jslogcontext="explain.teaser.code-snippets-explainer"
|
|
519
519
|
>${lockedString(UIStringsNotTranslate.freDisclaimerTextUseWithCaution)}</devtools-link>`,
|
|
520
520
|
// clang-format on
|
|
521
|
-
}
|
|
521
|
+
},
|
|
522
522
|
],
|
|
523
523
|
onLearnMoreClick: () => {
|
|
524
524
|
void UI.ViewManager.ViewManager.instance().showView('chrome-ai');
|
|
@@ -67,7 +67,7 @@ const UIStrings = {
|
|
|
67
67
|
* @example {allow pasting} PH1
|
|
68
68
|
*/
|
|
69
69
|
doNotPaste:
|
|
70
|
-
'Don’t paste code you don’t understand or haven’t reviewed yourself into DevTools. This could allow attackers to steal your identity or take control of your computer. Type
|
|
70
|
+
'Don’t paste code you don’t understand or haven’t reviewed yourself into DevTools. This could allow attackers to steal your identity or take control of your computer. Type "{PH1}" below to allow pasting.',
|
|
71
71
|
/**
|
|
72
72
|
* @description Text a user needs to type in order to confirm that they are aware of the danger of pasting code into the DevTools Console.
|
|
73
73
|
*/
|
|
@@ -76,7 +76,7 @@ const UIStrings = {
|
|
|
76
76
|
* @description Input box placeholder which instructs the user to type 'allow pasting' into the input box. IMPORTANT: keep double quotes around PH1 and do not use single quotes.
|
|
77
77
|
* @example {allow pasting} PH1
|
|
78
78
|
*/
|
|
79
|
-
typeAllowPasting: 'Type
|
|
79
|
+
typeAllowPasting: 'Type "{PH1}"',
|
|
80
80
|
} as const;
|
|
81
81
|
const str_ = i18n.i18n.registerUIStrings('panels/console/ConsolePinPane.ts', UIStrings);
|
|
82
82
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
@@ -97,7 +97,7 @@ export const DEFAULT_PANE_VIEW = (input: PaneViewInput, _output: object, target:
|
|
|
97
97
|
pin,
|
|
98
98
|
focusOut: input.focusOut,
|
|
99
99
|
onRemove: () => input.onRemove(pin),
|
|
100
|
-
})
|
|
100
|
+
}),
|
|
101
101
|
)}
|
|
102
102
|
</div>`, target);
|
|
103
103
|
// clang-format on
|
|
@@ -9,6 +9,7 @@ import * as i18n from '../../core/i18n/i18n.js';
|
|
|
9
9
|
import * as Root from '../../core/root/root.js';
|
|
10
10
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
11
11
|
import * as Badges from '../../models/badges/badges.js';
|
|
12
|
+
import * as Bindings from '../../models/bindings/bindings.js';
|
|
12
13
|
import * as Formatter from '../../models/formatter/formatter.js';
|
|
13
14
|
import * as SourceMapScopes from '../../models/source_map_scopes/source_map_scopes.js';
|
|
14
15
|
import * as CodeMirror from '../../third_party/codemirror.next/codemirror.next.js';
|
|
@@ -33,7 +34,7 @@ const UIStrings = {
|
|
|
33
34
|
* @example {allow pasting} PH1
|
|
34
35
|
*/
|
|
35
36
|
selfXssWarning:
|
|
36
|
-
'Warning: Don’t paste code into the DevTools Console that you don’t understand or haven’t reviewed yourself. This could allow attackers to steal your identity or take control of your computer. Type
|
|
37
|
+
'Warning: Don’t paste code into the DevTools Console that you don’t understand or haven’t reviewed yourself. This could allow attackers to steal your identity or take control of your computer. Type "{PH1}" below and press Enter to allow pasting.',
|
|
37
38
|
/**
|
|
38
39
|
* @description Text a user needs to type in order to confirm that they are aware of the danger of pasting code into the DevTools Console.
|
|
39
40
|
*/
|
|
@@ -170,7 +171,7 @@ export class ConsolePrompt extends Common.ObjectWrapper.eventMixin<EventTypes, t
|
|
|
170
171
|
this.aiCodeCompletionProvider.editorInitialized(this.editor);
|
|
171
172
|
this.editor.editor.dispatch({
|
|
172
173
|
effects: TextEditor.AiCodeCompletionProvider.setAiCodeCompletionTeaserMode.of(
|
|
173
|
-
TextEditor.AiCodeCompletionProvider.AiCodeCompletionTeaserMode.ONLY_SHOW_ON_EMPTY)
|
|
174
|
+
TextEditor.AiCodeCompletionProvider.AiCodeCompletionTeaserMode.ONLY_SHOW_ON_EMPTY),
|
|
174
175
|
});
|
|
175
176
|
}
|
|
176
177
|
|
|
@@ -390,7 +391,7 @@ export class ConsolePrompt extends Common.ObjectWrapper.eventMixin<EventTypes, t
|
|
|
390
391
|
if (teaserMode !== TextEditor.AiCodeCompletionProvider.AiCodeCompletionTeaserMode.OFF) {
|
|
391
392
|
this.editor.editor.dispatch({
|
|
392
393
|
effects: TextEditor.AiCodeCompletionProvider.setAiCodeCompletionTeaserMode.of(
|
|
393
|
-
TextEditor.AiCodeCompletionProvider.AiCodeCompletionTeaserMode.OFF)
|
|
394
|
+
TextEditor.AiCodeCompletionProvider.AiCodeCompletionTeaserMode.OFF),
|
|
394
395
|
});
|
|
395
396
|
}
|
|
396
397
|
}
|
|
@@ -429,7 +430,8 @@ export class ConsolePrompt extends Common.ObjectWrapper.eventMixin<EventTypes, t
|
|
|
429
430
|
useCommandLineAPI: boolean): Promise<void> {
|
|
430
431
|
const callFrame = executionContext.debuggerModel.selectedCallFrame();
|
|
431
432
|
if (callFrame?.script.isJavaScript()) {
|
|
432
|
-
const nameMap = await SourceMapScopes.NamesResolver.allVariablesInCallFrame(
|
|
433
|
+
const nameMap = await SourceMapScopes.NamesResolver.allVariablesInCallFrame(
|
|
434
|
+
callFrame, Bindings.DebuggerWorkspaceBinding.DebuggerWorkspaceBinding.instance());
|
|
433
435
|
expression = await this.substituteNames(expression, nameMap);
|
|
434
436
|
}
|
|
435
437
|
|
|
@@ -78,16 +78,14 @@ interface ViewInput {
|
|
|
78
78
|
|
|
79
79
|
export type View = (input: ViewInput, output: object, target: HTMLElement|DocumentFragment) => void;
|
|
80
80
|
export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
81
|
-
render(
|
|
82
|
-
html`<devtools-tree
|
|
81
|
+
render(html`<devtools-tree
|
|
83
82
|
navigation-variant
|
|
84
83
|
hide-overflow
|
|
85
84
|
.template=${
|
|
86
|
-
|
|
85
|
+
html`
|
|
87
86
|
<ul role="tree">
|
|
88
87
|
${
|
|
89
|
-
|
|
90
|
-
group => html`
|
|
88
|
+
input.groups.map(group => html`
|
|
91
89
|
<li
|
|
92
90
|
role="treeitem"
|
|
93
91
|
@select=${() => input.onSelectionChanged(group.filter)}
|
|
@@ -95,11 +93,11 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
95
93
|
<style>${consoleSidebarStyles}</style>
|
|
96
94
|
<devtools-icon name=${GROUP_ICONS[group.name].icon}></devtools-icon>
|
|
97
95
|
${
|
|
98
|
-
|
|
99
|
-
|
|
96
|
+
/* eslint-disable-next-line @devtools/l10n-i18nString-call-only-with-uistrings */
|
|
97
|
+
i18nString(GROUP_ICONS[group.name].label, {
|
|
100
98
|
|
|
101
|
-
|
|
102
|
-
|
|
99
|
+
n: group.messageCount,
|
|
100
|
+
})}
|
|
103
101
|
${group.messageCount === 0 ? nothing : html`
|
|
104
102
|
<ul role="group">
|
|
105
103
|
${group.urlGroups.values().map(urlGroup => html`
|
|
@@ -115,7 +113,7 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
115
113
|
</li>`)}
|
|
116
114
|
</ul>`}
|
|
117
115
|
></devtools-tree>`,
|
|
118
|
-
|
|
116
|
+
target, {container: {attributes: {jslog: `${VisualLogging.pane('sidebar').track({resize: true})}`}}});
|
|
119
117
|
};
|
|
120
118
|
|
|
121
119
|
export class ConsoleFilterGroup {
|
|
@@ -89,28 +89,27 @@ const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
89
89
|
displayMode: IssueCounter.IssueCounter.DisplayMode.ONLY_MOST_IMPORTANT,
|
|
90
90
|
};
|
|
91
91
|
|
|
92
|
-
render(
|
|
93
|
-
html`<div class="status-buttons"
|
|
92
|
+
render(html`<div class="status-buttons"
|
|
94
93
|
>${
|
|
95
|
-
|
|
94
|
+
errors + warnings ? html`<icon-button
|
|
96
95
|
.data=${iconData}
|
|
97
96
|
title=${consoleTitle}
|
|
98
97
|
class=${'small'}
|
|
99
98
|
jslog=${VisualLogging.counter('console').track({
|
|
100
|
-
|
|
101
|
-
|
|
99
|
+
click: true,
|
|
100
|
+
})}
|
|
102
101
|
></icon-button>` :
|
|
103
|
-
|
|
104
|
-
|
|
102
|
+
nothing}${
|
|
103
|
+
issues ? html`<devtools-issue-counter
|
|
105
104
|
class=${'main-toolbar'}
|
|
106
105
|
title=${issuesTitle}
|
|
107
106
|
.data=${issueCounterData}
|
|
108
107
|
jslog=${VisualLogging.counter('issue').track({
|
|
109
|
-
|
|
110
|
-
|
|
108
|
+
click: true,
|
|
109
|
+
})}
|
|
111
110
|
></devtools-issue-counter>` :
|
|
112
|
-
|
|
113
|
-
|
|
111
|
+
nothing}</div>`,
|
|
112
|
+
target);
|
|
114
113
|
};
|
|
115
114
|
|
|
116
115
|
export class WarningErrorCounterWidget extends UI.Widget.Widget {
|
|
@@ -87,12 +87,12 @@ const UIStrings = {
|
|
|
87
87
|
* @description Message in Coverage View of the Coverage tab.
|
|
88
88
|
* @example {Reload page} PH1
|
|
89
89
|
*/
|
|
90
|
-
clickTheReloadButtonSToReloadAnd: 'Click the
|
|
90
|
+
clickTheReloadButtonSToReloadAnd: 'Click the "{PH1}" button to reload and start capturing coverage.',
|
|
91
91
|
/**
|
|
92
92
|
* @description Message in Coverage View of the Coverage tab.
|
|
93
93
|
* @example {Start recording} PH1
|
|
94
94
|
*/
|
|
95
|
-
clickTheRecordButtonSToStart: 'Click the
|
|
95
|
+
clickTheRecordButtonSToStart: 'Click the "{PH1}" button to start capturing coverage.',
|
|
96
96
|
/**
|
|
97
97
|
* @description Message in the Coverage View explaining that DevTools could not capture coverage.
|
|
98
98
|
*/
|
|
@@ -287,7 +287,7 @@ export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
287
287
|
{name: i18nString(UIStrings.colors), id: 'colors'},
|
|
288
288
|
{name: i18nString(UIStrings.fontInfo), id: 'font-info'},
|
|
289
289
|
{name: i18nString(UIStrings.unusedDeclarations), id: 'unused-declarations'},
|
|
290
|
-
{name: i18nString(UIStrings.mediaQueries), id: 'media-queries'}
|
|
290
|
+
{name: i18nString(UIStrings.mediaQueries), id: 'media-queries'},
|
|
291
291
|
],
|
|
292
292
|
selectedId: input.selectedSection,
|
|
293
293
|
onItemSelected: input.onSectionSelected,
|
|
@@ -575,7 +575,7 @@ export class CSSOverviewCompletedView extends UI.Widget.VBox {
|
|
|
575
575
|
#viewOutput: ViewOutput = {
|
|
576
576
|
revealSection: new Map(),
|
|
577
577
|
closeAllTabs: () => {},
|
|
578
|
-
addTab: (_id, _tabTitle, _view, _jslogContext) => {}
|
|
578
|
+
addTab: (_id, _tabTitle, _view, _jslogContext) => {},
|
|
579
579
|
};
|
|
580
580
|
|
|
581
581
|
constructor(element?: HTMLElement, view = DEFAULT_VIEW) {
|
|
@@ -852,7 +852,7 @@ export class CSSOverviewCompletedView extends UI.Widget.VBox {
|
|
|
852
852
|
font,
|
|
853
853
|
fontMetrics: fontMetricInfo.map(([label, values]) => {
|
|
854
854
|
return {label, values: this.#sortGroupBySize(values)};
|
|
855
|
-
})
|
|
855
|
+
}),
|
|
856
856
|
};
|
|
857
857
|
});
|
|
858
858
|
}
|
|
@@ -105,7 +105,7 @@ export class CSSOverviewSidebarPanel extends UI.Widget.VBox {
|
|
|
105
105
|
selectedId: this.#selectedId,
|
|
106
106
|
onReset: this.#onReset,
|
|
107
107
|
onItemClick: this.#onItemClick.bind(this),
|
|
108
|
-
onItemKeyDown: this.#onItemKeyDown.bind(this)
|
|
108
|
+
onItemKeyDown: this.#onItemKeyDown.bind(this),
|
|
109
109
|
};
|
|
110
110
|
this.#view(viewInput, {}, this.contentElement);
|
|
111
111
|
}
|
|
@@ -100,7 +100,7 @@ export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
100
100
|
items: input.items,
|
|
101
101
|
selectedItem: input.selectedItem,
|
|
102
102
|
onSelect: input.onSelect,
|
|
103
|
-
filters: input.filters
|
|
103
|
+
filters: input.filters,
|
|
104
104
|
})}
|
|
105
105
|
</div>
|
|
106
106
|
<div class="developer-resource-view-toolbar-summary">
|
|
@@ -72,7 +72,7 @@ const UIStrings = {
|
|
|
72
72
|
* @example {Arial} PH5
|
|
73
73
|
*/
|
|
74
74
|
fontVariationSettingsWarning:
|
|
75
|
-
'Value for setting
|
|
75
|
+
'Value for setting "{PH1}" {PH2} is outside the supported range [{PH3}, {PH4}] for font-family "{PH5}".',
|
|
76
76
|
/**
|
|
77
77
|
* @description The message shown in the Style pane when the user hovers over a property declaration that has no effect on flex or grid child items.
|
|
78
78
|
* @example {flex} CONTAINER_DISPLAY_NAME
|
|
@@ -95,8 +95,9 @@ const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
|
95
95
|
|
|
96
96
|
function matchProperty(name: string, value: string): SDK.CSSPropertyParser.BottomUpTreeMatching|null {
|
|
97
97
|
return SDK.CSSPropertyParser.matchDeclaration(name, value, [
|
|
98
|
-
new SDK.CSSPropertyParserMatchers.ColorMatcher(),
|
|
99
|
-
new SDK.CSSPropertyParserMatchers.
|
|
98
|
+
new SDK.CSSPropertyParserMatchers.ColorMatcher(),
|
|
99
|
+
new SDK.CSSPropertyParserMatchers.URLMatcher(),
|
|
100
|
+
new SDK.CSSPropertyParserMatchers.StringMatcher(),
|
|
100
101
|
]);
|
|
101
102
|
}
|
|
102
103
|
|
|
@@ -626,7 +626,7 @@ function renderTitle(
|
|
|
626
626
|
});
|
|
627
627
|
return html`"<span class="webkit-html-text-node" jslog=${VisualLogging.value('text-node').track({
|
|
628
628
|
change: true,
|
|
629
|
-
dblclick: true
|
|
629
|
+
dblclick: true,
|
|
630
630
|
})} ${animateOn(Boolean(updateRecord?.isCharDataModified()), DOM_UPDATE_ANIMATION_CLASS_NAME)} ${
|
|
631
631
|
renderTextNode}></span>"`;
|
|
632
632
|
}
|
|
@@ -752,7 +752,7 @@ function renderLinkifiedValue(value: string, node: SDK.DOMModel.DOMNode): Lit.Te
|
|
|
752
752
|
showColumnNumber: false,
|
|
753
753
|
onRef: link => {
|
|
754
754
|
ImagePreviewPopover.setImageUrl(link, rewrittenHref);
|
|
755
|
-
}
|
|
755
|
+
},
|
|
756
756
|
});
|
|
757
757
|
}
|
|
758
758
|
|
|
@@ -1293,7 +1293,7 @@ export class ElementsTreeElement extends UI.TreeOutline.TreeElement {
|
|
|
1293
1293
|
|
|
1294
1294
|
if (this.nodeInternal.retained && !this.isClosingTag()) {
|
|
1295
1295
|
this.setLeadingIcons([
|
|
1296
|
-
html`<devtools-icon class="extra-small" name="small-status-dot" style="color:var(--icon-error); vertical-align:middle"></devtools-icon
|
|
1296
|
+
html`<devtools-icon class="extra-small" name="small-status-dot" style="color:var(--icon-error); vertical-align:middle"></devtools-icon>`,
|
|
1297
1297
|
]);
|
|
1298
1298
|
this.listItemNode.classList.add('detached-elements-detached-node');
|
|
1299
1299
|
this.listItemNode.style.setProperty('display', '-webkit-box');
|
|
@@ -151,9 +151,7 @@ export class EventListenersWidget extends UI.Widget.VBox {
|
|
|
151
151
|
Common.Settings.Settings.instance().createSetting('event-listener-dispatch-filter-type', DispatchFilterBy.All);
|
|
152
152
|
this.dispatchFilterBySetting.addChangeListener(this.requestUpdate.bind(this));
|
|
153
153
|
|
|
154
|
-
this.showFrameworkListenersSetting =
|
|
155
|
-
Common.Settings.Settings.instance().createSetting('show-frameowkr-listeners', true);
|
|
156
|
-
this.showFrameworkListenersSetting.setTitle(i18nString(UIStrings.frameworkListeners));
|
|
154
|
+
this.showFrameworkListenersSetting = Common.Settings.Settings.instance().moduleSetting('show-frameowkr-listeners');
|
|
157
155
|
this.showFrameworkListenersSetting.addChangeListener(this.requestUpdate.bind(this));
|
|
158
156
|
|
|
159
157
|
UI.Context.Context.instance().addFlavorChangeListener(SDK.DOMModel.DOMNode, this.requestUpdate.bind(this));
|
|
@@ -11,6 +11,7 @@ import * as SDK from '../../core/sdk/sdk.js';
|
|
|
11
11
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
12
12
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
13
13
|
import * as Lit from '../../ui/lit/lit.js';
|
|
14
|
+
import * as SettingUIRegistration from '../../ui/settings/settings.js';
|
|
14
15
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
15
16
|
|
|
16
17
|
import layoutPaneStyles from './layoutPane.css.js';
|
|
@@ -246,7 +247,7 @@ const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
246
247
|
<devtools-node-text .data=${{
|
|
247
248
|
nodeId: element.domId,
|
|
248
249
|
nodeTitle: element.name,
|
|
249
|
-
nodeClasses: element.domClasses
|
|
250
|
+
nodeClasses: element.domClasses,
|
|
250
251
|
}}>
|
|
251
252
|
</devtools-node-text>
|
|
252
253
|
</span>
|
|
@@ -259,7 +260,7 @@ const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
259
260
|
jslog=${
|
|
260
261
|
VisualLogging.showStyleEditor('color')
|
|
261
262
|
.track({
|
|
262
|
-
click: true
|
|
263
|
+
click: true,
|
|
263
264
|
})}>
|
|
264
265
|
<input
|
|
265
266
|
@change=${(e: Event) => input.onColorChange(element, e)}
|
|
@@ -359,8 +360,8 @@ const DEFAULT_VIEW: View = (input, output, target) => {
|
|
|
359
360
|
</details>`
|
|
360
361
|
: ''}
|
|
361
362
|
</div>`,
|
|
362
|
-
|
|
363
|
-
|
|
363
|
+
// clang-format on
|
|
364
|
+
target);
|
|
364
365
|
};
|
|
365
366
|
|
|
366
367
|
type View = (input: ViewInput, output: object, element: HTMLElement) => void;
|
|
@@ -456,28 +457,37 @@ export class LayoutPane extends UI.Widget.Widget {
|
|
|
456
457
|
if (settingType !== Common.Settings.SettingType.BOOLEAN && settingType !== Common.Settings.SettingType.ENUM) {
|
|
457
458
|
throw new Error('A setting provided to LayoutSidebarPane does not have a supported setting type');
|
|
458
459
|
}
|
|
460
|
+
const uiDescriptor = SettingUIRegistration.SettingUIRegistration.maybeResolve(setting.descriptor());
|
|
459
461
|
const mappedSetting = {
|
|
460
462
|
type: settingType,
|
|
461
463
|
name: setting.name,
|
|
462
|
-
title: setting.title(),
|
|
464
|
+
title: uiDescriptor?.title?.() ?? setting.title(),
|
|
463
465
|
};
|
|
466
|
+
const options = uiDescriptor?.options?.map(opt => ({
|
|
467
|
+
value: opt.value,
|
|
468
|
+
title: opt.title(),
|
|
469
|
+
text: typeof opt.text === 'function' ? opt.text() : opt.text,
|
|
470
|
+
raw: opt.raw,
|
|
471
|
+
})) ??
|
|
472
|
+
setting.options();
|
|
473
|
+
|
|
464
474
|
if (typeof settingValue === 'boolean') {
|
|
465
475
|
settings.push({
|
|
466
476
|
...mappedSetting,
|
|
467
477
|
value: settingValue,
|
|
468
|
-
options:
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
478
|
+
options: options.map(opt => ({
|
|
479
|
+
...opt,
|
|
480
|
+
value: (opt.value as boolean),
|
|
481
|
+
})),
|
|
472
482
|
});
|
|
473
483
|
} else if (typeof settingValue === 'string') {
|
|
474
484
|
settings.push({
|
|
475
485
|
...mappedSetting,
|
|
476
486
|
value: settingValue,
|
|
477
|
-
options:
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
487
|
+
options: options.map(opt => ({
|
|
488
|
+
...opt,
|
|
489
|
+
value: (opt.value as string),
|
|
490
|
+
})),
|
|
481
491
|
});
|
|
482
492
|
}
|
|
483
493
|
}
|
|
@@ -26,18 +26,17 @@ interface ViewInput {
|
|
|
26
26
|
type View = (input: ViewInput, output_: undefined, target: HTMLElement) => void;
|
|
27
27
|
|
|
28
28
|
export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
29
|
-
render(
|
|
30
|
-
html`
|
|
29
|
+
render(html`
|
|
31
30
|
<style>${stylesSidebarPaneStyles}</style>
|
|
32
31
|
<div class="style-panes-wrapper" jslog=${VisualLogging.section('standalone-styles').track({
|
|
33
|
-
|
|
34
|
-
|
|
32
|
+
resize: true,
|
|
33
|
+
})}>
|
|
35
34
|
<div class="styles-pane">
|
|
36
35
|
${input.sections.map(section => section.element)}
|
|
37
36
|
</div>
|
|
38
37
|
</div>
|
|
39
38
|
`,
|
|
40
|
-
|
|
39
|
+
target);
|
|
41
40
|
};
|
|
42
41
|
|
|
43
42
|
export const enum Events {
|
|
@@ -130,8 +129,9 @@ export class StandaloneStylesContainer extends Common.ObjectWrapper.eventMixin<E
|
|
|
130
129
|
const parentNodeId = matchedStyles?.getParentLayoutNodeId();
|
|
131
130
|
|
|
132
131
|
const [parentStyles, computedStyles, extraStyles] = await Promise.all([
|
|
133
|
-
parentNodeId ? cssModel.getComputedStyle(parentNodeId) : null,
|
|
134
|
-
cssModel.
|
|
132
|
+
parentNodeId ? cssModel.getComputedStyle(parentNodeId) : null,
|
|
133
|
+
cssModel.getComputedStyle(node.id),
|
|
134
|
+
cssModel.getComputedStyleExtraFields(node.id),
|
|
135
135
|
]);
|
|
136
136
|
|
|
137
137
|
if (signal?.aborted) {
|
|
@@ -908,7 +908,7 @@ export class StylePropertiesSection {
|
|
|
908
908
|
ancestorRuleElement = this.createSupportsElement(rule.supports[supportsIndex++]);
|
|
909
909
|
break;
|
|
910
910
|
case Protocol.CSS.CSSRuleType.StyleRule:
|
|
911
|
-
ancestorRuleElement = this.createNestingElement(rule
|
|
911
|
+
ancestorRuleElement = this.createNestingElement(rule, nestingIndex++);
|
|
912
912
|
break;
|
|
913
913
|
case Protocol.CSS.CSSRuleType.StartingStyleRule:
|
|
914
914
|
ancestorRuleElement = this.createStartingStyleElement();
|
|
@@ -1124,10 +1124,31 @@ export class StylePropertiesSection {
|
|
|
1124
1124
|
return navigationElement;
|
|
1125
1125
|
}
|
|
1126
1126
|
|
|
1127
|
-
protected createNestingElement(
|
|
1127
|
+
protected createNestingElement(rule: SDK.CSSRule.CSSStyleRule, nestingIndex: number): HTMLElement|undefined {
|
|
1128
|
+
const nestingSelector = rule.nestingSelectors?.[nestingIndex];
|
|
1128
1129
|
if (!nestingSelector) {
|
|
1129
1130
|
return;
|
|
1130
1131
|
}
|
|
1132
|
+
|
|
1133
|
+
const parentRule = this.matchedStyles.findParentRule(rule, nestingIndex);
|
|
1134
|
+
if (parentRule) {
|
|
1135
|
+
const container = document.createElement('div');
|
|
1136
|
+
const matchingSelectorIndexes = this.matchedStyles.getMatchingSelectors(parentRule);
|
|
1137
|
+
const matchingSelectors = new Array(parentRule.selectors.length).fill(false) as boolean[];
|
|
1138
|
+
for (const matchingIndex of matchingSelectorIndexes) {
|
|
1139
|
+
matchingSelectors[matchingIndex] = true;
|
|
1140
|
+
}
|
|
1141
|
+
|
|
1142
|
+
const selectorElement = container.createChild('span', 'selector');
|
|
1143
|
+
const specificityContainer = container.createChild('span');
|
|
1144
|
+
this.renderSelectorsToElement(parentRule.selectors, matchingSelectors, this.elementToSelectorIndex,
|
|
1145
|
+
selectorElement, specificityContainer);
|
|
1146
|
+
|
|
1147
|
+
const openBrace = container.createChild('span', 'sidebar-pane-open-brace');
|
|
1148
|
+
openBrace.textContent = ' {';
|
|
1149
|
+
return container;
|
|
1150
|
+
}
|
|
1151
|
+
|
|
1131
1152
|
const nestingElement = document.createElement('div');
|
|
1132
1153
|
nestingElement.textContent = `${nestingSelector} {`;
|
|
1133
1154
|
return nestingElement;
|
|
@@ -1438,18 +1459,25 @@ export class StylePropertiesSection {
|
|
|
1438
1459
|
elementToSelectorIndex: WeakMap<Element, number>): void {
|
|
1439
1460
|
this.selectorElement.removeChildren();
|
|
1440
1461
|
this.#specificityTooltips.removeChildren();
|
|
1462
|
+
this.renderSelectorsToElement(selectors, matchingSelectors, elementToSelectorIndex, this.selectorElement,
|
|
1463
|
+
this.#specificityTooltips);
|
|
1464
|
+
}
|
|
1465
|
+
|
|
1466
|
+
private renderSelectorsToElement(selectors: Array<{text: string, specificity?: Protocol.CSS.Specificity}>,
|
|
1467
|
+
matchingSelectors: boolean[], elementToSelectorIndex: WeakMap<Element, number>,
|
|
1468
|
+
targetElement: Element, tooltipContainer: Element): void {
|
|
1441
1469
|
for (const [i, selector] of selectors.entries()) {
|
|
1442
1470
|
if (i > 0) {
|
|
1443
|
-
|
|
1471
|
+
targetElement.append(', ');
|
|
1444
1472
|
}
|
|
1445
1473
|
const specificityTooltipId = selector.specificity ? StylePropertiesSection.getNextSpecificityTooltipId() : null;
|
|
1446
|
-
const span =
|
|
1474
|
+
const span = targetElement.createChild('span', 'simple-selector');
|
|
1447
1475
|
span.classList.toggle('selector-matches', matchingSelectors[i]);
|
|
1448
1476
|
elementToSelectorIndex.set(span, i);
|
|
1449
1477
|
span.textContent = selectors[i].text;
|
|
1450
1478
|
if (specificityTooltipId && selector.specificity) {
|
|
1451
1479
|
span.setAttribute('aria-details', specificityTooltipId);
|
|
1452
|
-
const tooltip =
|
|
1480
|
+
const tooltip = tooltipContainer.appendChild(new Tooltips.Tooltip.Tooltip({
|
|
1453
1481
|
id: specificityTooltipId,
|
|
1454
1482
|
anchor: span,
|
|
1455
1483
|
variant: 'rich',
|