chrome-devtools-frontend 1.0.1675430 → 1.0.1678416
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/AUTHORS +1 -0
- package/WATCHLISTS +0 -4
- package/front_end/core/common/EventTarget.ts +0 -5
- package/front_end/core/common/Settings.ts +0 -66
- package/front_end/core/host/InspectorFrontendHostAPI.ts +1 -0
- package/front_end/core/host/UserMetrics.ts +5 -0
- package/front_end/core/root/Runtime.ts +5 -5
- package/front_end/core/sdk/CSSMetadata.ts +5 -9
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +16 -34
- package/front_end/core/sdk/DebuggerModel.ts +92 -57
- package/front_end/core/sdk/EmulationModel.ts +2 -1
- package/front_end/core/sdk/NetworkManager.ts +16 -2
- package/front_end/core/sdk/OverlayModel.ts +19 -9
- package/front_end/core/sdk/OverlayPersistentHighlighter.ts +10 -4
- package/front_end/core/sdk/ResourceTreeModel.ts +20 -1
- package/front_end/core/sdk/SDKSettings.ts +117 -0
- package/front_end/core/sdk/Script.ts +9 -53
- package/front_end/core/sdk/sdk-meta.ts +0 -431
- package/front_end/devtools_compatibility.js +1 -0
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +213 -23
- package/front_end/entrypoints/inspector_main/InspectorMain.ts +6 -5
- package/front_end/entrypoints/inspector_main/RenderingOptions.ts +14 -15
- package/front_end/entrypoints/inspector_main/inspector_main-meta.ts +157 -0
- package/front_end/entrypoints/main/MainImpl.ts +32 -0
- package/front_end/entrypoints/shell/shell.ts +0 -1
- package/front_end/foundation/Universe.ts +8 -0
- package/front_end/generated/InspectorBackendCommands.ts +8 -8
- package/front_end/generated/SupportedCSSProperties.ts +53 -4
- package/front_end/generated/protocol-mapping.d.ts +27 -21
- package/front_end/generated/protocol-proxy-api.d.ts +22 -17
- package/front_end/generated/protocol.ts +43 -18
- package/front_end/models/ai_assistance/AiAgent2.ts +47 -2
- package/front_end/models/ai_assistance/AiConversation.ts +22 -5
- package/front_end/models/ai_assistance/README.md +52 -26
- package/front_end/models/ai_assistance/agents/AiAgent.ts +54 -8
- package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +1 -1
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +7 -194
- package/front_end/models/ai_assistance/agents/StorageAgent.ts +21 -87
- package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +2 -1
- package/front_end/models/ai_assistance/ai_assistance.ts +24 -0
- package/front_end/models/ai_assistance/contexts/PerformanceTraceContext.ts +124 -0
- package/front_end/models/ai_assistance/contexts/StorageContext.ts +100 -0
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +69 -1
- package/front_end/models/ai_assistance/skills/README.md +63 -1
- package/front_end/models/ai_assistance/skills/Skill.ts +1 -1
- package/front_end/models/ai_assistance/skills/SkillRegistry.ts +4 -0
- package/front_end/models/ai_assistance/skills/accessibility.md +7 -0
- package/front_end/models/ai_assistance/skills/performance.md +15 -1
- package/front_end/models/ai_assistance/skills/sources.md +16 -0
- package/front_end/models/ai_assistance/skills/storage.md +31 -0
- package/front_end/models/ai_assistance/tools/GetDetailedCallTree.ts +107 -0
- package/front_end/models/ai_assistance/tools/GetFunctionCode.ts +122 -0
- package/front_end/models/ai_assistance/tools/GetResourceContent.ts +127 -0
- package/front_end/models/ai_assistance/tools/GetSourceContent.ts +101 -0
- package/front_end/models/ai_assistance/tools/GetTraceEventByKey.ts +83 -0
- package/front_end/models/ai_assistance/tools/GetTraceMainThreadSummary.ts +106 -0
- package/front_end/models/ai_assistance/tools/GetTraceNetworkSummary.ts +104 -0
- package/front_end/models/ai_assistance/tools/ListPageOrigins.ts +95 -0
- package/front_end/models/ai_assistance/tools/ListSources.ts +116 -0
- package/front_end/models/ai_assistance/tools/RunLighthouse.ts +89 -0
- package/front_end/models/ai_assistance/tools/SelectTraceEventByKey.ts +90 -0
- package/front_end/models/ai_assistance/tools/Tool.ts +26 -1
- package/front_end/models/ai_assistance/tools/ToolRegistry.ts +22 -0
- package/front_end/models/bindings/CSSWorkspaceBinding.ts +4 -0
- package/front_end/models/bindings/CompilerScriptMapping.ts +4 -0
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +8 -0
- package/front_end/models/bindings/ResourceScriptMapping.ts +3 -201
- package/front_end/models/bindings/SASSSourceMapping.ts +6 -0
- package/front_end/models/breakpoints/BreakpointManager.ts +2 -49
- package/front_end/models/comment_manager/CommentManager.ts +141 -0
- package/front_end/models/comment_manager/comment_manager.ts +9 -0
- package/front_end/models/heap_snapshot/HeapSnapshotModel.ts +27 -0
- package/front_end/models/heap_snapshot/HeapSnapshotProxy.ts +10 -2
- package/front_end/models/issues_manager/descriptions/connectionAllowlistEmbeddingRequirementNotSatisfied.md +26 -0
- package/front_end/models/issues_manager/descriptions/connectionAllowlistIFrameAttributeLoosensEmbeddingRequirement.md +19 -0
- package/front_end/models/issues_manager/descriptions/connectionAllowlistInvalidAllowConnectionAllowlistFrom.md +21 -0
- package/front_end/models/javascript_metadata/NativeFunctions.js +6 -6
- package/front_end/models/persistence/IsolatedFileSystem.ts +7 -8
- package/front_end/models/persistence/IsolatedFileSystemManager.ts +2 -2
- package/front_end/models/persistence/PlatformFileSystem.ts +1 -1
- package/front_end/models/persistence/persistence-meta.ts +9 -9
- package/front_end/models/trace/types/TraceEvents.ts +36 -0
- package/front_end/panels/accessibility/ARIAAttributesView.ts +3 -3
- package/front_end/panels/accessibility/AccessibilityAnnouncementRecordingView.ts +25 -0
- package/front_end/panels/accessibility/AccessibilityNodeView.ts +36 -36
- package/front_end/panels/accessibility/AccessibilitySidebarView.ts +9 -0
- package/front_end/panels/accessibility/AccessibilityStrings.ts +168 -168
- package/front_end/panels/accessibility/SourceOrderView.ts +7 -7
- package/front_end/panels/accessibility/accessibility-meta.ts +2 -2
- package/front_end/panels/accessibility/accessibility.ts +2 -0
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +5 -5
- package/front_end/panels/ai_assistance/components/AIv2MarkdownRenderer.ts +2 -3
- package/front_end/panels/ai_assistance/components/ChatInput.ts +2 -2
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +92 -12
- package/front_end/panels/ai_assistance/components/chatMessage.css +6 -0
- package/front_end/panels/application/ApplicationPanelSidebar.ts +10 -4
- package/front_end/panels/application/IndexedDBViews.ts +65 -63
- package/front_end/panels/application/StorageView.ts +116 -45
- package/front_end/panels/application/WebMCPView.ts +16 -7
- package/front_end/panels/application/application-meta.ts +11 -0
- package/front_end/panels/application/components/AdsView.ts +1 -1
- package/front_end/panels/common/AiCodeCompletionSummaryToolbar.ts +5 -5
- package/front_end/panels/common/BadgeNotification.ts +8 -8
- package/front_end/panels/common/ExtensionPanel.ts +9 -8
- package/front_end/panels/common/ExtensionServer.ts +21 -1
- package/front_end/panels/common/GdpSignUpDialog.ts +16 -16
- package/front_end/panels/common/GeminiRebrandPromoDialog.ts +5 -6
- package/front_end/panels/common/PersistenceUtils.ts +2 -2
- package/front_end/panels/common/common.ts +0 -97
- package/front_end/panels/console/ConsoleInsightTeaser.ts +2 -2
- package/front_end/panels/console/ConsolePanel.ts +4 -0
- package/front_end/panels/console/ConsolePinPane.ts +2 -2
- package/front_end/panels/console/ConsolePrompt.ts +12 -0
- package/front_end/panels/console/ConsoleView.ts +31 -20
- package/front_end/panels/console/ConsoleViewMessage.ts +37 -13
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewModel.ts +1 -1
- package/front_end/panels/elements/ElementStatePaneWidget.ts +2 -1
- package/front_end/panels/elements/ElementsTreeElement.ts +455 -372
- package/front_end/panels/elements/LayoutPane.ts +2 -8
- package/front_end/panels/elements/StylePropertyTreeElement.ts +16 -15
- package/front_end/panels/elements/elements-meta.ts +152 -10
- package/front_end/panels/elements/elements.ts +0 -2
- package/front_end/panels/emulation/DeviceModeView.ts +9 -1
- package/front_end/panels/event_listeners/EventListenersView.ts +8 -4
- package/front_end/panels/issues/AffectedTrackingSitesView.ts +25 -14
- package/front_end/panels/lighthouse/LighthouseController.ts +3 -2
- package/front_end/panels/media/PlayerMessagesView.ts +149 -68
- package/front_end/panels/network/BinaryResourceView.ts +134 -81
- package/front_end/panels/network/EventSourceMessagesView.ts +10 -10
- package/front_end/panels/network/FetchHeaderCommenting.ts +291 -0
- package/front_end/panels/network/NetworkConfigView.ts +10 -10
- package/front_end/panels/network/NetworkDataGridNode.ts +14 -14
- package/front_end/panels/network/NetworkItemView.ts +27 -28
- package/front_end/panels/network/NetworkLogView.ts +137 -38
- package/front_end/panels/network/NetworkLogViewColumns.ts +35 -35
- package/front_end/panels/network/NetworkManageCustomHeadersView.ts +1 -1
- package/front_end/panels/network/NetworkPanel.ts +2 -2
- package/front_end/panels/network/RequestConditionsDrawer.ts +5 -5
- package/front_end/panels/network/RequestCookiesView.ts +4 -4
- package/front_end/panels/network/RequestHeadersView.ts +5 -5
- package/front_end/panels/network/RequestPayloadView.ts +4 -3
- package/front_end/panels/network/RequestTimingView.ts +8 -8
- package/front_end/panels/network/ResourceChunkView.ts +1 -1
- package/front_end/panels/network/ResourceDirectSocketChunkView.ts +1 -1
- package/front_end/panels/network/ResourceWebSocketFrameView.ts +16 -16
- package/front_end/panels/network/binaryResourceView.css +14 -12
- package/front_end/panels/network/components/DirectSocketConnectionView.ts +2 -2
- package/front_end/panels/network/components/HeaderSectionRow.ts +1 -1
- package/front_end/panels/network/components/RequestTrustTokensView.ts +2 -2
- package/front_end/panels/network/network-meta.ts +1 -1
- package/front_end/panels/network/network.ts +2 -0
- package/front_end/panels/profiler/HeapDetachedElementsDataGrid.ts +0 -1
- package/front_end/panels/profiler/HeapSnapshotView.ts +0 -2
- package/front_end/panels/profiler/heapProfiler.css +0 -9
- package/front_end/panels/recorder/RecorderPanel.ts +2 -3
- package/front_end/panels/screencast/ScreencastView.ts +148 -138
- package/front_end/panels/sources/AiCodeCompletionPlugin.ts +2 -2
- package/front_end/panels/sources/BreakpointsView.ts +2 -2
- package/front_end/panels/sources/DebuggerPlugin.ts +10 -59
- package/front_end/panels/sources/NavigatorView.ts +2 -1
- package/front_end/panels/sources/ScopeChainSidebarPane.ts +1 -1
- package/front_end/panels/sources/SourcesPanel.ts +23 -73
- package/front_end/panels/sources/SourcesView.ts +248 -157
- package/front_end/panels/sources/TabbedEditorContainer.ts +118 -23
- package/front_end/panels/sources/UISourceCodeFrame.ts +5 -9
- package/front_end/panels/sources/WatchExpressionsSidebarPane.ts +4 -2
- package/front_end/panels/sources/sources-meta.ts +52 -0
- package/front_end/panels/timeline/TimelineController.ts +36 -64
- package/front_end/panels/timeline/TimelinePanel.ts +11 -8
- package/front_end/panels/timeline/TimelineUIUtils.ts +5 -2
- package/front_end/panels/timeline/overlays/components/EntryLabelOverlay.ts +2 -2
- package/front_end/panels/timeline/timelinePanel.css +0 -10
- package/front_end/panels/utils/utils.ts +7 -7
- package/front_end/services/tracing/PerformanceTracing.ts +5 -17
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/codemirror.js.map +1 -1
- package/front_end/third_party/codemirror.next/package.json +2 -2
- package/front_end/third_party/codemirror.next/rebuild.sh +4 -1
- package/front_end/ui/comments/CommentAnchorResolver.ts +430 -35
- package/front_end/ui/comments/CommentOverlayManager.ts +635 -0
- package/front_end/ui/comments/CommentsOverlayWidget.ts +134 -0
- package/front_end/ui/comments/comments.ts +4 -0
- package/front_end/ui/comments/commentsOverlay.css +49 -0
- package/front_end/{panels/common → ui/components/dialogs}/FreDialog.ts +6 -6
- package/front_end/ui/components/dialogs/TypeToAllowDialog.ts +96 -0
- package/front_end/ui/components/dialogs/dialogs.ts +4 -0
- package/front_end/ui/components/settings/SettingCheckbox.ts +3 -3
- package/front_end/{panels/common → ui/components/text_editor}/AiCodeCompletionDisclaimer.ts +13 -13
- package/front_end/ui/components/text_editor/AiCodeCompletionProvider.ts +7 -6
- package/front_end/{panels/common → ui/components/text_editor}/AiCodeCompletionTeaser.ts +43 -46
- package/front_end/ui/components/text_editor/AiCodeGenerationProvider.ts +22 -26
- package/front_end/{panels/common → ui/components/text_editor}/AiCodeGenerationTeaser.ts +10 -10
- package/front_end/{panels/common → ui/components/text_editor}/AiCodeGenerationUpgradeDialog.ts +5 -5
- package/front_end/ui/components/text_editor/text_editor.ts +4 -0
- package/front_end/ui/legacy/Toolbar.ts +1 -1
- package/front_end/ui/legacy/UIUtils.ts +0 -56
- package/front_end/ui/legacy/View.ts +10 -4
- package/front_end/ui/legacy/Widget.ts +10 -1
- package/front_end/ui/legacy/components/color_picker/ContrastDetails.ts +2 -1
- package/front_end/ui/legacy/components/color_picker/ContrastOverlay.ts +5 -4
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +11 -3
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +507 -209
- package/front_end/ui/legacy/components/object_ui/objectPropertiesSection.css +5 -0
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +11 -16
- package/front_end/ui/legacy/components/settings_ui/SettingsUI.ts +5 -12
- package/front_end/ui/legacy/components/source_frame/BinaryResourceViewFactory.ts +38 -20
- package/front_end/ui/legacy/components/source_frame/JSONView.ts +12 -2
- package/front_end/ui/legacy/components/source_frame/ResourceSourceFrame.ts +3 -3
- package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +37 -6
- package/front_end/ui/legacy/components/source_frame/StreamingContentHexView.ts +22 -4
- package/front_end/ui/settings/SettingUIRegistration.ts +55 -6
- package/front_end/ui/visual_logging/KnownContextValues.ts +3 -0
- package/mcp/mcp.ts +6 -1
- package/package.json +6 -6
- package/front_end/Images/toolbarResizerVertical.png +0 -0
- package/front_end/emulated_devices/MotoG4-landscape.svg +0 -155
- package/front_end/emulated_devices/MotoG4-portrait.svg +0 -155
- package/front_end/emulated_devices/Nexus5X-landscape.svg +0 -19
- package/front_end/emulated_devices/Nexus5X-portrait.svg +0 -19
- package/front_end/emulated_devices/Nexus6P-landscape.svg +0 -50
- package/front_end/emulated_devices/Nexus6P-portrait.svg +0 -54
- package/front_end/emulated_devices/google-nest-hub-horizontal.png +0 -0
- package/front_end/emulated_devices/google-nest-hub-max-horizontal.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-default-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-default-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-keyboard-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-keyboard-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-navigation-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-horizontal-navigation-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-default-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-default-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-keyboard-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-keyboard-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-navigation-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5-vertical-navigation-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-default-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-default-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-keyboard-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-keyboard-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-navigation-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-horizontal-navigation-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-default-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-default-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-keyboard-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-keyboard-2x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-navigation-1x.png +0 -0
- package/front_end/emulated_devices/google-nexus-5x-vertical-navigation-2x.png +0 -0
- package/front_end/emulated_devices/iPad-landscape.svg +0 -73
- package/front_end/emulated_devices/iPad-portrait.svg +0 -76
- package/front_end/emulated_devices/iPhone5-landscape.svg +0 -99
- package/front_end/emulated_devices/iPhone5-portrait.svg +0 -83
- package/front_end/emulated_devices/iPhone6-landscape.svg +0 -111
- package/front_end/emulated_devices/iPhone6-portrait.svg +0 -116
- package/front_end/emulated_devices/iPhone6Plus-landscape.svg +0 -118
- package/front_end/emulated_devices/iPhone6Plus-portrait.svg +0 -116
- package/front_end/emulated_devices/optimized/MotoG4-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/MotoG4-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/Nexus5X-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/Nexus5X-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/Nexus6P-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/Nexus6P-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/README.md +0 -9
- package/front_end/emulated_devices/optimized/google-nest-hub-horizontal.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nest-hub-max-horizontal.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-default-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-default-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-keyboard-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-keyboard-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-navigation-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-horizontal-navigation-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-default-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-default-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-keyboard-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-keyboard-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-navigation-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5-vertical-navigation-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-default-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-default-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-keyboard-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-keyboard-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-navigation-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-horizontal-navigation-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-default-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-default-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-keyboard-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-keyboard-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-navigation-1x.avif +0 -0
- package/front_end/emulated_devices/optimized/google-nexus-5x-vertical-navigation-2x.avif +0 -0
- package/front_end/emulated_devices/optimized/iPad-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/iPad-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone5-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone5-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone6-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone6-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone6Plus-landscape.avif +0 -0
- package/front_end/emulated_devices/optimized/iPhone6Plus-portrait.avif +0 -0
- package/front_end/emulated_devices/optimized/optimized_images.gni +0 -53
- package/front_end/models/ai_assistance/agents/README.md +0 -136
- package/front_end/panels/elements/ElementsTreeOutlineRenderer.ts +0 -89
- package/front_end/ui/legacy/components/object_ui/object_ui-meta.ts +0 -27
- /package/front_end/{panels/common → ui/components/dialogs}/freDialog.css +0 -0
- /package/front_end/{panels/common/common.css → ui/components/dialogs/typeToAllowDialog.css} +0 -0
- /package/front_end/{panels/common → ui/components/text_editor}/aiCodeCompletionDisclaimer.css +0 -0
- /package/front_end/{panels/common → ui/components/text_editor}/aiCodeCompletionTeaser.css +0 -0
- /package/front_end/{panels/common → ui/components/text_editor}/aiCodeGenerationTeaser.css +0 -0
- /package/front_end/{panels/common → ui/components/text_editor}/aiCodeGenerationUpgradeDialog.css +0 -0
|
@@ -14,12 +14,12 @@ import {html, type LitTemplate} from '../../ui/lit/lit.js';
|
|
|
14
14
|
|
|
15
15
|
const UIStrings = {
|
|
16
16
|
/**
|
|
17
|
-
* @description
|
|
17
|
+
* @description Tooltip text indicating that a file is linked to a source map.
|
|
18
18
|
* @example {example.url} PH1
|
|
19
19
|
*/
|
|
20
20
|
linkedToSourceMapS: 'Linked to source map: {PH1}',
|
|
21
21
|
/**
|
|
22
|
-
* @description
|
|
22
|
+
* @description Tooltip text indicating that a file is linked to another file.
|
|
23
23
|
* @example {example.url} PH1
|
|
24
24
|
*/
|
|
25
25
|
linkedToS: 'Linked to {PH1}',
|
|
@@ -2,105 +2,8 @@
|
|
|
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
|
-
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
6
|
-
|
|
7
|
-
import * as Host from '../../core/host/host.js';
|
|
8
|
-
import * as i18n from '../../core/i18n/i18n.js';
|
|
9
|
-
import type * as Platform from '../../core/platform/platform.js';
|
|
10
|
-
import * as Geometry from '../../models/geometry/geometry.js';
|
|
11
|
-
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
12
|
-
import * as UI from '../../ui/legacy/legacy.js';
|
|
13
|
-
|
|
14
|
-
import commonStyles from './common.css.js';
|
|
15
|
-
|
|
16
|
-
const UIStrings = {
|
|
17
|
-
/**
|
|
18
|
-
* @description Text for the cancel button in the dialog.
|
|
19
|
-
*/
|
|
20
|
-
cancel: 'Cancel',
|
|
21
|
-
/**
|
|
22
|
-
* @description Text for the allow button in the "type to allow" dialog.
|
|
23
|
-
*/
|
|
24
|
-
allow: 'Allow',
|
|
25
|
-
} as const;
|
|
26
|
-
|
|
27
|
-
const str_ = i18n.i18n.registerUIStrings('panels/common/common.ts', UIStrings);
|
|
28
|
-
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
29
|
-
|
|
30
|
-
export class TypeToAllowDialog {
|
|
31
|
-
static async show(options: {
|
|
32
|
-
jslogContext: {
|
|
33
|
-
dialog: string,
|
|
34
|
-
input: string,
|
|
35
|
-
},
|
|
36
|
-
header: Platform.UIString.LocalizedString,
|
|
37
|
-
message: Platform.UIString.LocalizedString,
|
|
38
|
-
typePhrase: Platform.UIString.LocalizedString,
|
|
39
|
-
inputPlaceholder: Platform.UIString.LocalizedString,
|
|
40
|
-
}): Promise<boolean> {
|
|
41
|
-
const dialog = new UI.Dialog.Dialog(options.jslogContext.dialog);
|
|
42
|
-
dialog.setMaxContentSize(new Geometry.Size(504, 340));
|
|
43
|
-
dialog.setSizeBehavior(UI.GlassPane.SizeBehavior.SET_EXACT_WIDTH_MAX_HEIGHT);
|
|
44
|
-
dialog.setDimmed(true);
|
|
45
|
-
const shadowRoot = UI.UIUtils.createShadowRootWithCoreStyles(dialog.contentElement, {cssFile: commonStyles});
|
|
46
|
-
const content = shadowRoot.createChild('div', 'type-to-allow-dialog');
|
|
47
|
-
|
|
48
|
-
const result = await new Promise<boolean>(resolve => {
|
|
49
|
-
const header = content.createChild('div', 'header');
|
|
50
|
-
header.createChild('div', 'title').textContent = options.header;
|
|
51
|
-
|
|
52
|
-
const closeButton = header.createChild('dt-close-button', 'dialog-close-button');
|
|
53
|
-
closeButton.setTabbable(true);
|
|
54
|
-
self.onInvokeElement(closeButton, event => {
|
|
55
|
-
dialog.hide();
|
|
56
|
-
event.consume(true);
|
|
57
|
-
resolve(false);
|
|
58
|
-
});
|
|
59
|
-
closeButton.setSize(Buttons.Button.Size.SMALL);
|
|
60
|
-
|
|
61
|
-
content.createChild('div', 'message').textContent = options.message;
|
|
62
|
-
|
|
63
|
-
const input = UI.UIUtils.createInput('text-input', 'text', options.jslogContext.input);
|
|
64
|
-
input.placeholder = options.inputPlaceholder;
|
|
65
|
-
content.appendChild(input);
|
|
66
|
-
|
|
67
|
-
const buttonsBar = content.createChild('div', 'button');
|
|
68
|
-
const cancelButton =
|
|
69
|
-
UI.UIUtils.createTextButton(i18nString(UIStrings.cancel), () => resolve(false), {jslogContext: 'cancel'});
|
|
70
|
-
|
|
71
|
-
const allowButton = UI.UIUtils.createTextButton(i18nString(UIStrings.allow), () => {
|
|
72
|
-
resolve(input.value === options.typePhrase || input.value === `'${options.typePhrase}'`);
|
|
73
|
-
}, {jslogContext: 'confirm', variant: Buttons.Button.Variant.PRIMARY});
|
|
74
|
-
allowButton.disabled = true;
|
|
75
|
-
|
|
76
|
-
buttonsBar.appendChild(allowButton);
|
|
77
|
-
buttonsBar.appendChild(cancelButton);
|
|
78
|
-
|
|
79
|
-
input.addEventListener('input', () => {
|
|
80
|
-
allowButton.disabled = !Boolean(input.value);
|
|
81
|
-
}, false);
|
|
82
|
-
input.addEventListener('paste', e => e.preventDefault());
|
|
83
|
-
input.addEventListener('drop', e => e.preventDefault());
|
|
84
|
-
|
|
85
|
-
dialog.setOutsideClickCallback(event => {
|
|
86
|
-
event.consume();
|
|
87
|
-
resolve(false);
|
|
88
|
-
});
|
|
89
|
-
dialog.show();
|
|
90
|
-
Host.userMetrics.actionTaken(Host.UserMetrics.Action.SelfXssWarningDialogShown);
|
|
91
|
-
});
|
|
92
|
-
dialog.hide();
|
|
93
|
-
return result;
|
|
94
|
-
}
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
export {AiCodeCompletionTeaser} from './AiCodeCompletionTeaser.js';
|
|
98
|
-
export * as AiCodeGenerationTeaser from './AiCodeGenerationTeaser.js';
|
|
99
|
-
export {AiCodeGenerationUpgradeDialog} from './AiCodeGenerationUpgradeDialog.js';
|
|
100
|
-
export {FreDialog} from './FreDialog.js';
|
|
101
5
|
export {GdpSignUpDialog} from './GdpSignUpDialog.js';
|
|
102
6
|
export {GeminiRebrandPromoDialog} from './GeminiRebrandPromoDialog.js';
|
|
103
|
-
export {AiCodeCompletionDisclaimer, type DisclaimerTextVariant} from './AiCodeCompletionDisclaimer.js';
|
|
104
7
|
export * as AiCodeCompletionSummaryToolbar from './AiCodeCompletionSummaryToolbar.js';
|
|
105
8
|
export * from './BadgeNotification.js';
|
|
106
9
|
export * as CPUThrottlingOption from './CPUThrottlingOption.js';
|
|
@@ -12,11 +12,11 @@ import * as Root from '../../core/root/root.js';
|
|
|
12
12
|
import * as Protocol from '../../generated/protocol.js';
|
|
13
13
|
import * as AiAssistanceModel from '../../models/ai_assistance/ai_assistance.js';
|
|
14
14
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
15
|
+
import * as Dialogs from '../../ui/components/dialogs/dialogs.js';
|
|
15
16
|
import type * as Tooltips from '../../ui/components/tooltips/tooltips.js';
|
|
16
17
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
17
18
|
import * as Lit from '../../ui/lit/lit.js';
|
|
18
19
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
19
|
-
import * as PanelCommon from '../common/common.js';
|
|
20
20
|
|
|
21
21
|
import consoleInsightTeaserStyles from './consoleInsightTeaser.css.js';
|
|
22
22
|
import {ConsoleViewMessage} from './ConsoleViewMessage.js';
|
|
@@ -500,7 +500,7 @@ export class ConsoleInsightTeaser extends UI.Widget.Widget {
|
|
|
500
500
|
const noLogging = Root.Runtime.hostConfig.aidaAvailability?.enterprisePolicyValue ===
|
|
501
501
|
Root.Runtime.GenAiEnterprisePolicyValue.ALLOW_WITHOUT_LOGGING;
|
|
502
502
|
const iconName = AiAssistanceModel.AiUtils.getIconName();
|
|
503
|
-
const result = await
|
|
503
|
+
const result = await Dialogs.FreDialog.FreDialog.show({
|
|
504
504
|
header: {iconName, text: lockedString(UIStringsNotTranslate.freDisclaimerHeader)},
|
|
505
505
|
reminderItems: [
|
|
506
506
|
{
|
|
@@ -131,6 +131,10 @@ export class WrapperView extends UI.Widget.VBox {
|
|
|
131
131
|
showViewInWrapper(): void {
|
|
132
132
|
this.view.show(this.element);
|
|
133
133
|
}
|
|
134
|
+
|
|
135
|
+
insertIntoPrompt(text: string): void {
|
|
136
|
+
this.view.insertIntoPrompt(text);
|
|
137
|
+
}
|
|
134
138
|
}
|
|
135
139
|
|
|
136
140
|
export class ConsoleRevealer implements Common.Revealer.Revealer<Common.Console.Console> {
|
|
@@ -10,6 +10,7 @@ import * as Root from '../../core/root/root.js';
|
|
|
10
10
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
11
11
|
import * as CodeMirror from '../../third_party/codemirror.next/codemirror.next.js';
|
|
12
12
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
13
|
+
import * as Dialogs from '../../ui/components/dialogs/dialogs.js';
|
|
13
14
|
import * as TextEditor from '../../ui/components/text_editor/text_editor.js';
|
|
14
15
|
import * as ObjectUI from '../../ui/legacy/components/object_ui/object_ui.js';
|
|
15
16
|
// eslint-disable-next-line @devtools/es-modules-import
|
|
@@ -17,7 +18,6 @@ import objectValueStyles from '../../ui/legacy/components/object_ui/objectValue.
|
|
|
17
18
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
18
19
|
import {Directives, html, type LitTemplate, nothing, render} from '../../ui/lit/lit.js';
|
|
19
20
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
20
|
-
import * as PanelCommon from '../common/common.js';
|
|
21
21
|
|
|
22
22
|
import consolePinPaneStyles from './consolePinPane.css.js';
|
|
23
23
|
|
|
@@ -437,7 +437,7 @@ export class ConsolePinPresenter extends UI.Widget.Widget {
|
|
|
437
437
|
}
|
|
438
438
|
|
|
439
439
|
async #showSelfXssWarning(): Promise<void> {
|
|
440
|
-
const allowPasting = await
|
|
440
|
+
const allowPasting = await Dialogs.TypeToAllowDialog.TypeToAllowDialog.show({
|
|
441
441
|
jslogContext: {
|
|
442
442
|
dialog: 'self-xss-warning',
|
|
443
443
|
input: 'allow-pasting',
|
|
@@ -276,6 +276,18 @@ export class ConsolePrompt extends Common.ObjectWrapper.eventMixin<EventTypes, t
|
|
|
276
276
|
});
|
|
277
277
|
}
|
|
278
278
|
|
|
279
|
+
/**
|
|
280
|
+
* Replaces the full prompt content with the given text, places the caret
|
|
281
|
+
* at the end, and scrolls the editor into view.
|
|
282
|
+
*/
|
|
283
|
+
insertText(text: string): void {
|
|
284
|
+
this.editor.dispatch({
|
|
285
|
+
changes: {from: 0, to: this.editor.state.doc.length, insert: text},
|
|
286
|
+
selection: {anchor: text.length},
|
|
287
|
+
scrollIntoView: true,
|
|
288
|
+
});
|
|
289
|
+
}
|
|
290
|
+
|
|
279
291
|
text(): string {
|
|
280
292
|
return this.editor.state.doc.toString();
|
|
281
293
|
}
|
|
@@ -58,6 +58,7 @@ import objectValueStyles from '../../ui/legacy/components/object_ui/objectValue.
|
|
|
58
58
|
import * as SettingsUI from '../../ui/legacy/components/settings_ui/settings_ui.js';
|
|
59
59
|
import * as Components from '../../ui/legacy/components/utils/utils.js';
|
|
60
60
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
61
|
+
import * as SettingUIRegistration from '../../ui/settings/settings.js';
|
|
61
62
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
62
63
|
import {AiCodeCompletionSummaryToolbar} from '../common/common.js';
|
|
63
64
|
|
|
@@ -498,30 +499,30 @@ export class ConsoleView extends UI.Widget.VBox implements
|
|
|
498
499
|
settingsPane.append(
|
|
499
500
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
500
501
|
i18nString(UIStrings.networkMessages), this.filter.networkMessagesSetting,
|
|
501
|
-
this.filter.networkMessagesSetting.
|
|
502
|
+
SettingUIRegistration.SettingUIRegistration.resolve(this.filter.networkMessagesSetting.descriptor()).title),
|
|
503
|
+
SettingsUI.SettingsUI.createSettingCheckbox(i18nString(UIStrings.logXMLHttpRequests),
|
|
504
|
+
monitoringXHREnabledSetting),
|
|
505
|
+
SettingsUI.SettingsUI.createSettingCheckbox(i18nString(UIStrings.preserveLog), preserveConsoleLogSetting,
|
|
506
|
+
i18nString(UIStrings.doNotClearLogOnPageReload)),
|
|
502
507
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
503
|
-
|
|
508
|
+
SettingUIRegistration.SettingUIRegistration.resolve(consoleEagerEvalSetting.descriptor()).title,
|
|
509
|
+
consoleEagerEvalSetting, i18nString(UIStrings.eagerlyEvaluateTextInThePrompt)),
|
|
510
|
+
SettingsUI.SettingsUI.createSettingCheckbox(i18nString(UIStrings.selectedContextOnly),
|
|
511
|
+
this.filter.filterByExecutionContextSetting,
|
|
512
|
+
i18nString(UIStrings.onlyShowMessagesFromTheCurrentContext)),
|
|
504
513
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
505
|
-
|
|
506
|
-
|
|
514
|
+
SettingUIRegistration.SettingUIRegistration.resolve(this.consoleHistoryAutocompleteSetting.descriptor())
|
|
515
|
+
.title,
|
|
516
|
+
this.consoleHistoryAutocompleteSetting, i18nString(UIStrings.autocompleteFromHistory)),
|
|
507
517
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
508
|
-
|
|
509
|
-
i18nString(UIStrings.
|
|
518
|
+
SettingUIRegistration.SettingUIRegistration.resolve(this.groupSimilarSetting.descriptor()).title,
|
|
519
|
+
this.groupSimilarSetting, i18nString(UIStrings.groupSimilarMessagesInConsole)),
|
|
510
520
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
511
|
-
|
|
512
|
-
i18nString(UIStrings.
|
|
521
|
+
SettingUIRegistration.SettingUIRegistration.resolve(userActivationEvalSetting.descriptor()).title,
|
|
522
|
+
userActivationEvalSetting, i18nString(UIStrings.treatEvaluationAsUserActivation)),
|
|
513
523
|
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
514
|
-
this.
|
|
515
|
-
i18nString(UIStrings.
|
|
516
|
-
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
517
|
-
this.groupSimilarSetting.title(), this.groupSimilarSetting,
|
|
518
|
-
i18nString(UIStrings.groupSimilarMessagesInConsole)),
|
|
519
|
-
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
520
|
-
userActivationEvalSetting.title(), userActivationEvalSetting,
|
|
521
|
-
i18nString(UIStrings.treatEvaluationAsUserActivation)),
|
|
522
|
-
SettingsUI.SettingsUI.createSettingCheckbox(
|
|
523
|
-
this.showCorsErrorsSetting.title(), this.showCorsErrorsSetting,
|
|
524
|
-
i18nString(UIStrings.showCorsErrorsInConsole)),
|
|
524
|
+
SettingUIRegistration.SettingUIRegistration.resolve(this.showCorsErrorsSetting.descriptor()).title,
|
|
525
|
+
this.showCorsErrorsSetting, i18nString(UIStrings.showCorsErrorsInConsole)),
|
|
525
526
|
);
|
|
526
527
|
|
|
527
528
|
if (!this.showSettingsPaneSetting.get()) {
|
|
@@ -919,6 +920,16 @@ export class ConsoleView extends UI.Widget.VBox implements
|
|
|
919
920
|
}
|
|
920
921
|
}
|
|
921
922
|
|
|
923
|
+
/**
|
|
924
|
+
* Inserts text into the console prompt (replacing any existing content)
|
|
925
|
+
* and focuses the prompt. Used by cross-panel features such as
|
|
926
|
+
* "Edit and resend as fetch".
|
|
927
|
+
*/
|
|
928
|
+
insertIntoPrompt(text: string): void {
|
|
929
|
+
this.prompt.insertText(text);
|
|
930
|
+
this.focusPrompt();
|
|
931
|
+
}
|
|
932
|
+
|
|
922
933
|
override restoreScrollPositions(): void {
|
|
923
934
|
if (this.viewport.stickToBottom()) {
|
|
924
935
|
this.immediatelyScrollToBottom();
|
|
@@ -1340,7 +1351,7 @@ export class ConsoleView extends UI.Widget.VBox implements
|
|
|
1340
1351
|
|
|
1341
1352
|
if (consoleMessage) {
|
|
1342
1353
|
const request = Logs.NetworkLog.NetworkLog.requestForConsoleMessage(consoleMessage);
|
|
1343
|
-
if (request && SDK.NetworkManager.NetworkManager.canResendRequest(request)) {
|
|
1354
|
+
if (request && SDK.NetworkManager.NetworkManager.canResendRequest(request, true)) {
|
|
1344
1355
|
contextMenu.debugSection().appendItem(i18nString(UIStrings.resend),
|
|
1345
1356
|
SDK.NetworkManager.NetworkManager.replayRequest.bind(null, request),
|
|
1346
1357
|
{jslogContext: 'resend'});
|
|
@@ -59,6 +59,7 @@ import * as Components from '../../ui/legacy/components/utils/utils.js';
|
|
|
59
59
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
60
60
|
import {type LitTemplate, nothing, render} from '../../ui/lit/lit.js';
|
|
61
61
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
62
|
+
import * as Elements from '../elements/elements.js';
|
|
62
63
|
|
|
63
64
|
import {format, updateStyle} from './ConsoleFormat.js';
|
|
64
65
|
import {ConsoleInsightTeaser} from './ConsoleInsightTeaser.js';
|
|
@@ -627,6 +628,19 @@ export class ConsoleViewMessage implements ConsoleViewportElement {
|
|
|
627
628
|
UI.UIUtils.createTextChild(anchorWrapperElement, ' ');
|
|
628
629
|
return anchorWrapperElement;
|
|
629
630
|
}
|
|
631
|
+
|
|
632
|
+
// No source location anchor exists, but there may still be affected resource links to display.
|
|
633
|
+
const affectedResourceElements = this.createAffectedResourceLinks();
|
|
634
|
+
if (affectedResourceElements.length) {
|
|
635
|
+
const anchorWrapperElement = document.createElement('span');
|
|
636
|
+
anchorWrapperElement.classList.add('console-message-anchor');
|
|
637
|
+
for (const element of affectedResourceElements) {
|
|
638
|
+
anchorWrapperElement.append(element);
|
|
639
|
+
}
|
|
640
|
+
UI.UIUtils.createTextChild(anchorWrapperElement, ' ');
|
|
641
|
+
return anchorWrapperElement;
|
|
642
|
+
}
|
|
643
|
+
|
|
630
644
|
return null;
|
|
631
645
|
}
|
|
632
646
|
|
|
@@ -970,23 +984,33 @@ export class ConsoleViewMessage implements ConsoleViewportElement {
|
|
|
970
984
|
if (!domModel) {
|
|
971
985
|
return result;
|
|
972
986
|
}
|
|
973
|
-
void domModel.pushObjectAsNodeToFrontend(remoteObject).then(
|
|
987
|
+
void domModel.pushObjectAsNodeToFrontend(remoteObject).then((node: SDK.DOMModel.DOMNode|null) => {
|
|
974
988
|
if (!node) {
|
|
975
989
|
result.appendChild(this.formatParameterAsObject(remoteObject, false));
|
|
976
990
|
return;
|
|
977
991
|
}
|
|
978
|
-
const
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
992
|
+
const treeOutline = new Elements.ElementsTreeOutline.ElementsTreeOutline(
|
|
993
|
+
/* omitRootDOMNode: */ false, /* selectEnabled: */ true, /* hideGutter: */ true);
|
|
994
|
+
treeOutline.rootDOMNode = node;
|
|
995
|
+
treeOutline.deindentSingleNode();
|
|
996
|
+
treeOutline.setVisible(true);
|
|
997
|
+
// @ts-expect-error used in console_test_runner
|
|
998
|
+
treeOutline.element.treeElementForTest = treeOutline.firstChild();
|
|
999
|
+
treeOutline.setShowSelectionOnKeyboardFocus(/* show: */ true, /* preventTabOrder: */ true);
|
|
1000
|
+
|
|
1001
|
+
this.selectableChildren.push({
|
|
1002
|
+
element: treeOutline.element,
|
|
1003
|
+
forceSelect: treeOutline.forceSelect.bind(treeOutline),
|
|
1004
|
+
});
|
|
1005
|
+
// FIXME: this should not be needed once ConsoleViewMessage is rendering
|
|
1006
|
+
// declaratively and the tree outline auto-resizes itself.
|
|
1007
|
+
const dispatchDimensionChange = (): void => {
|
|
1008
|
+
this.messageResized({data: treeOutline.element});
|
|
1009
|
+
};
|
|
1010
|
+
treeOutline.addEventListener(UI.TreeOutline.Events.ElementAttached, dispatchDimensionChange);
|
|
1011
|
+
treeOutline.addEventListener(UI.TreeOutline.Events.ElementExpanded, dispatchDimensionChange);
|
|
1012
|
+
treeOutline.addEventListener(UI.TreeOutline.Events.ElementCollapsed, dispatchDimensionChange);
|
|
1013
|
+
result.appendChild(treeOutline.element);
|
|
990
1014
|
this.formattedParameterAsNodeForTest();
|
|
991
1015
|
});
|
|
992
1016
|
|
|
@@ -482,7 +482,7 @@ function renderContrastIssue(key: string, issues: ContrastIssue[]): TemplateResu
|
|
|
482
482
|
const color = (minContrastIssue.textColor.asString(Common.Color.Format.HEXA));
|
|
483
483
|
const backgroundColor = (minContrastIssue.backgroundColor.asString(Common.Color.Format.HEXA));
|
|
484
484
|
|
|
485
|
-
const showAPCA = Common.Settings.Settings.instance().
|
|
485
|
+
const showAPCA = Common.Settings.Settings.instance().resolve(SDK.SDKSettings.apcaSettingDescriptor).get();
|
|
486
486
|
|
|
487
487
|
const title = i18nString(UIStrings.textColorSOverSBackgroundResults, {
|
|
488
488
|
PH1: color,
|
|
@@ -1040,7 +1040,7 @@ function renderContrastRatio(data: PopulateNodesEventNodeTypes): TemplateResult
|
|
|
1040
1040
|
if (!('contrastRatio' in data)) {
|
|
1041
1041
|
throw new Error('Contrast ratio entry is missing a contrast ratio.');
|
|
1042
1042
|
}
|
|
1043
|
-
const showAPCA = Common.Settings.Settings.instance().
|
|
1043
|
+
const showAPCA = Common.Settings.Settings.instance().resolve(SDK.SDKSettings.apcaSettingDescriptor).get();
|
|
1044
1044
|
const contrastRatio = Platform.NumberUtilities.floor(data.contrastRatio, 2);
|
|
1045
1045
|
const contrastRatioString = showAPCA ? contrastRatio + '%' : contrastRatio;
|
|
1046
1046
|
const border = getBorderString(data.backgroundColor);
|
|
@@ -266,7 +266,7 @@ export class CSSOverviewModel extends SDK.SDKModel.SDKModel<void> {
|
|
|
266
266
|
const formattedTextColor = formatColor(blendedTextColor);
|
|
267
267
|
const formattedBackgroundColor = formatColor(blendedBackgroundColor.asLegacyColor());
|
|
268
268
|
const key = `${formattedTextColor}_${formattedBackgroundColor}`;
|
|
269
|
-
if (Common.Settings.Settings.instance().
|
|
269
|
+
if (Common.Settings.Settings.instance().resolve(SDK.SDKSettings.apcaSettingDescriptor).get()) {
|
|
270
270
|
const contrastRatio = contrastInfo.contrastRatioAPCA();
|
|
271
271
|
const threshold = contrastInfo.contrastRatioAPCAThreshold();
|
|
272
272
|
const passes = contrastRatio && threshold ? Math.abs(contrastRatio) >= threshold : false;
|
|
@@ -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 Common from '../../core/common/common.js';
|
|
5
6
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
6
7
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
7
8
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
@@ -106,7 +107,7 @@ export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
106
107
|
jslog=${VisualLogging.pane('element-states')}>
|
|
107
108
|
<div class="page-state-checkbox">
|
|
108
109
|
<devtools-checkbox class="small" title=${i18nString(UIStrings.emulatesAFocusedPage)}
|
|
109
|
-
${bindToSetting(
|
|
110
|
+
${bindToSetting(Common.Settings.Settings.instance().resolve(SDK.SDKSettings.emulatePageFocusSettingDescriptor))}>${
|
|
110
111
|
i18nString(UIStrings.emulateFocusedPage)}</devtools-checkbox>
|
|
111
112
|
<devtools-button
|
|
112
113
|
@click=${() => UIHelpers.openInNewTab('https://developer.chrome.com/docs/devtools/rendering/apply-effects#emulate_a_focused_page')}
|