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
package/AUTHORS
CHANGED
|
@@ -112,6 +112,7 @@ Varun Varada <varuncvarada@gmail.com>
|
|
|
112
112
|
Vishwa Kalubowila <vishwa.kalubowila@codimite.com>
|
|
113
113
|
Vitali Zaidman <vzaidman@gmail.com>
|
|
114
114
|
Will Hernandez <w.hernandez.code@gmail.com>
|
|
115
|
+
Yao Wu <ywu16212@gmail.com>
|
|
115
116
|
Yeol Park <peary2@gmail.com>
|
|
116
117
|
Yisi(一丝) <yiorsi@gmail.com>
|
|
117
118
|
Yoichiro Hibara <hibarayoichiro871@gmail.com>
|
package/WATCHLISTS
CHANGED
|
@@ -13,9 +13,6 @@
|
|
|
13
13
|
'all': {
|
|
14
14
|
'filepath': '.',
|
|
15
15
|
},
|
|
16
|
-
'chromedriver': {
|
|
17
|
-
'filepath': 'front_end/emulated_devices/',
|
|
18
|
-
},
|
|
19
16
|
'lighthouse': {
|
|
20
17
|
'filepath': '[Ll]ighthouse',
|
|
21
18
|
},
|
|
@@ -26,7 +23,6 @@
|
|
|
26
23
|
|
|
27
24
|
'WATCHLISTS': {
|
|
28
25
|
'all': ['devtools-reviews+devtools@chromium.org'],
|
|
29
|
-
'chromedriver': [],
|
|
30
26
|
'lighthouse': ['lighthouse-eng+devtools-cl@google.com'],
|
|
31
27
|
'third_party': ['devtools-reviews+third_party@chromium.org'],
|
|
32
28
|
},
|
|
@@ -40,11 +40,6 @@ export interface EventTarget<Events> {
|
|
|
40
40
|
...[eventData]: EventPayloadToRestParameters<Events, T>): void;
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
export function fireEvent(name: string, detail: unknown = {}, target: HTMLElement|Window = window): void {
|
|
44
|
-
const evt = new CustomEvent(name, {bubbles: true, cancelable: true, detail});
|
|
45
|
-
target.dispatchEvent(evt);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
43
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
49
44
|
export interface EventTargetEvent<T, Events = any> {
|
|
50
45
|
data: T;
|
|
@@ -10,7 +10,6 @@ import type {EventDescriptor, EventTargetEvent, GenericEvents} from './EventTarg
|
|
|
10
10
|
import {ObjectWrapper} from './Object.js';
|
|
11
11
|
import {
|
|
12
12
|
getLocalizedSettingsCategory,
|
|
13
|
-
type LearnMore,
|
|
14
13
|
maybeRemoveSettingExtension,
|
|
15
14
|
type RegExpSettingItem,
|
|
16
15
|
registerSettingExtension,
|
|
@@ -518,13 +517,6 @@ export class Setting<V> {
|
|
|
518
517
|
this.eventSupport.removeEventListener(this.name, listener, thisObject);
|
|
519
518
|
}
|
|
520
519
|
|
|
521
|
-
title(): Platform.UIString.LocalizedString {
|
|
522
|
-
if (this.#registration?.title) {
|
|
523
|
-
return this.#registration.title();
|
|
524
|
-
}
|
|
525
|
-
return '' as Platform.UIString.LocalizedString;
|
|
526
|
-
}
|
|
527
|
-
|
|
528
520
|
setRequiresUserAction(requiresUserAction: boolean): void {
|
|
529
521
|
this.#requiresUserAction = requiresUserAction;
|
|
530
522
|
}
|
|
@@ -624,57 +616,6 @@ export class Setting<V> {
|
|
|
624
616
|
return this.#type ?? this.#registration?.settingType ?? null;
|
|
625
617
|
}
|
|
626
618
|
|
|
627
|
-
options(): SimpleSettingOption[] {
|
|
628
|
-
if (this.#registration && this.#registration.options) {
|
|
629
|
-
return this.#registration.options.map(opt => {
|
|
630
|
-
const {value, title, text, raw} = opt;
|
|
631
|
-
return {
|
|
632
|
-
value,
|
|
633
|
-
title: title(),
|
|
634
|
-
text: typeof text === 'function' ? text() : text,
|
|
635
|
-
raw,
|
|
636
|
-
};
|
|
637
|
-
});
|
|
638
|
-
}
|
|
639
|
-
return [];
|
|
640
|
-
}
|
|
641
|
-
|
|
642
|
-
reloadRequired(): boolean|null {
|
|
643
|
-
if (this.#registration) {
|
|
644
|
-
return this.#registration.reloadRequired || null;
|
|
645
|
-
}
|
|
646
|
-
return null;
|
|
647
|
-
}
|
|
648
|
-
|
|
649
|
-
category(): SettingCategory|null {
|
|
650
|
-
if (this.#registration) {
|
|
651
|
-
return this.#registration.category || null;
|
|
652
|
-
}
|
|
653
|
-
return null;
|
|
654
|
-
}
|
|
655
|
-
|
|
656
|
-
tags(): string|null {
|
|
657
|
-
if (this.#registration && this.#registration.tags) {
|
|
658
|
-
// Get localized keys and separate by null character to prevent fuzzy matching from matching across them.
|
|
659
|
-
return this.#registration.tags.map(tag => tag()).join('\0');
|
|
660
|
-
}
|
|
661
|
-
return null;
|
|
662
|
-
}
|
|
663
|
-
|
|
664
|
-
order(): number|null {
|
|
665
|
-
if (this.#registration) {
|
|
666
|
-
return this.#registration.order || null;
|
|
667
|
-
}
|
|
668
|
-
return null;
|
|
669
|
-
}
|
|
670
|
-
|
|
671
|
-
/**
|
|
672
|
-
* See {@link LearnMore} for more info
|
|
673
|
-
*/
|
|
674
|
-
learnMore(): LearnMore|null {
|
|
675
|
-
return this.#registration?.learnMore ?? null;
|
|
676
|
-
}
|
|
677
|
-
|
|
678
619
|
private printSettingsSavingError(message: string, value: string): void {
|
|
679
620
|
const errorMessage =
|
|
680
621
|
'Error saving setting with name: ' + this.name + ', value length: ' + value.length + '. Error: ' + message;
|
|
@@ -766,10 +707,3 @@ export {
|
|
|
766
707
|
SettingRegistration,
|
|
767
708
|
SettingType,
|
|
768
709
|
};
|
|
769
|
-
|
|
770
|
-
export interface SimpleSettingOption {
|
|
771
|
-
value: string|boolean;
|
|
772
|
-
title: string;
|
|
773
|
-
text?: string;
|
|
774
|
-
raw?: boolean;
|
|
775
|
-
}
|
|
@@ -557,5 +557,6 @@ export const enum EnumeratedHistogram {
|
|
|
557
557
|
SwatchActivated = 'DevTools.SwatchActivated',
|
|
558
558
|
BuiltInAiAvailability = 'DevTools.BuiltInAiAvailability',
|
|
559
559
|
ResendRequest = 'DevTools.ResendRequest',
|
|
560
|
+
EditResendRequest = 'DevTools.EditResendRequest',
|
|
560
561
|
// LINT.ThenChange(/front_end/devtools_compatibility.js:EnumeratedHistogram)
|
|
561
562
|
}
|
|
@@ -36,6 +36,11 @@ export class UserMetrics {
|
|
|
36
36
|
ResendRequestType.MAX_VALUE);
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
+
editResendRequest(type: ResendRequestType): void {
|
|
40
|
+
InspectorFrontendHostInstance.recordEnumeratedHistogram(EnumeratedHistogram.EditResendRequest, type,
|
|
41
|
+
ResendRequestType.MAX_VALUE);
|
|
42
|
+
}
|
|
43
|
+
|
|
39
44
|
keybindSetSettingChanged(keybindSet: string): void {
|
|
40
45
|
const value = KeybindSetSettings[keybindSet as keyof typeof KeybindSetSettings] || 0;
|
|
41
46
|
InspectorFrontendHostInstance.recordEnumeratedHistogram(EnumeratedHistogram.KeybindSetSettingChanged, value,
|
|
@@ -484,10 +484,6 @@ interface GdpProfilesAvailability {
|
|
|
484
484
|
enterprisePolicyValue: GdpProfilesEnterprisePolicyValue;
|
|
485
485
|
}
|
|
486
486
|
|
|
487
|
-
interface LiveEdit {
|
|
488
|
-
enabled: boolean;
|
|
489
|
-
}
|
|
490
|
-
|
|
491
487
|
interface ExtensionsOnChromeUrls {
|
|
492
488
|
enabled: boolean;
|
|
493
489
|
}
|
|
@@ -544,6 +540,10 @@ interface HostConfigDevToolsComments {
|
|
|
544
540
|
enabled: boolean;
|
|
545
541
|
}
|
|
546
542
|
|
|
543
|
+
interface DevToolsAriaLiveRecording {
|
|
544
|
+
enabled: boolean;
|
|
545
|
+
}
|
|
546
|
+
|
|
547
547
|
/**
|
|
548
548
|
* The host configuration that we expect from the DevTools back-end.
|
|
549
549
|
*
|
|
@@ -588,7 +588,6 @@ export type HostConfig = Platform.TypeScriptUtilities.RecursivePartial<{
|
|
|
588
588
|
devToolsGlobalAiButton: GlobalAiButton,
|
|
589
589
|
devToolsGdpProfiles: GdpProfiles,
|
|
590
590
|
devToolsGdpProfilesAvailability: GdpProfilesAvailability,
|
|
591
|
-
devToolsLiveEdit: LiveEdit,
|
|
592
591
|
devToolsFlexibleLayout: DevToolsFlexibleLayout,
|
|
593
592
|
deviceBoundSessionsDebugging: DeviceBoundSessionsDebugging,
|
|
594
593
|
devToolsEnableDurableMessages: DevToolsEnableDurableMessages,
|
|
@@ -600,6 +599,7 @@ export type HostConfig = Platform.TypeScriptUtilities.RecursivePartial<{
|
|
|
600
599
|
devToolsAdsPanel: DevToolsAdsPanel,
|
|
601
600
|
devToolsUseGcaApi: UseGcaApi,
|
|
602
601
|
devToolsPlusButton: DevToolsPlusButton,
|
|
602
|
+
devToolsAriaLiveRecording: DevToolsAriaLiveRecording,
|
|
603
603
|
devToolsInstrumentationBreakpoints: DevToolsInstrumentationBreakpoints,
|
|
604
604
|
extensionsOnChromeUrls: ExtensionsOnChromeUrls,
|
|
605
605
|
devToolsComments: HostConfigDevToolsComments,
|
|
@@ -64,9 +64,6 @@ export class CSSMetadata {
|
|
|
64
64
|
if (Boolean(runtimeFlagStatus) && runtimeFlagStatus !== 'stable') {
|
|
65
65
|
continue;
|
|
66
66
|
}
|
|
67
|
-
if (!CSS.supports(propertyName, 'initial')) {
|
|
68
|
-
continue;
|
|
69
|
-
}
|
|
70
67
|
this.#values.push(propertyName);
|
|
71
68
|
|
|
72
69
|
if (property.inherited) {
|
|
@@ -113,7 +110,7 @@ export class CSSMetadata {
|
|
|
113
110
|
for (const propertyName of this.#longhands.keys()) {
|
|
114
111
|
// skip "all" because it is a CSS-wide keyword
|
|
115
112
|
// skip shorthands that are defined in generatedPropertyValues because they have their own value sets
|
|
116
|
-
if (propertyName === 'all' ||
|
|
113
|
+
if (propertyName === 'all' || propertyName in SupportedCSSProperties.generatedPropertyValues) {
|
|
117
114
|
continue;
|
|
118
115
|
}
|
|
119
116
|
const longhands = this.#longhands.get(propertyName);
|
|
@@ -121,6 +118,10 @@ export class CSSMetadata {
|
|
|
121
118
|
continue;
|
|
122
119
|
}
|
|
123
120
|
const values = new Array<string>();
|
|
121
|
+
const propertyValueSet = propertyValueSets.get(propertyName);
|
|
122
|
+
if (propertyValueSet) {
|
|
123
|
+
values.push(...propertyValueSet);
|
|
124
|
+
}
|
|
124
125
|
for (const longhand of longhands) {
|
|
125
126
|
const longhandValues = propertyValueSets.get(longhand);
|
|
126
127
|
if (!longhandValues) {
|
|
@@ -143,11 +144,6 @@ export class CSSMetadata {
|
|
|
143
144
|
}
|
|
144
145
|
}
|
|
145
146
|
}
|
|
146
|
-
for (const commonKeyword of CommonKeywords) {
|
|
147
|
-
if (!values.has(commonKeyword) && CSS.supports(propertyName, commonKeyword)) {
|
|
148
|
-
values.add(commonKeyword);
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
147
|
|
|
152
148
|
this.#propertyValues.set(propertyName, [...values]);
|
|
153
149
|
}
|
|
@@ -156,42 +156,22 @@ export class VariableNameMatcher extends matcherBase(VariableNameMatch) {
|
|
|
156
156
|
}
|
|
157
157
|
|
|
158
158
|
override matches(node: CodeMirror.SyntaxNode, matching: BottomUpTreeMatching): VariableNameMatch|null {
|
|
159
|
-
if (node.
|
|
160
|
-
// TODO(b/484268589): The result shouldn't be KeywordQuery, but currently
|
|
161
|
-
// sometimes Lezer parses it that way. Fix this when Lezer is fixed.
|
|
159
|
+
if (!node.parent) {
|
|
162
160
|
return null;
|
|
163
161
|
}
|
|
164
|
-
|
|
165
|
-
if (
|
|
162
|
+
// TODO(b/484268589): When the misspelling is removed from Lezer we can remove that case.
|
|
163
|
+
if (node.name !== 'FeatureName' && node.name !== 'PropertyName' && node.name !== 'ProperyName') {
|
|
166
164
|
return null;
|
|
167
165
|
}
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
let foundStyleCall: CodeMirror.SyntaxNode|null = null;
|
|
171
|
-
while (cur) {
|
|
172
|
-
if (cur.name === 'CallExpression') {
|
|
173
|
-
return null;
|
|
174
|
-
}
|
|
175
|
-
if (cur.name === 'CallQuery') {
|
|
176
|
-
const callee = cur.getChild('QueryCallee');
|
|
177
|
-
if (callee && matching.ast.text(callee) === 'style') {
|
|
178
|
-
foundStyleCall = cur;
|
|
179
|
-
break;
|
|
180
|
-
}
|
|
181
|
-
return null;
|
|
182
|
-
}
|
|
183
|
-
cur = cur.parent;
|
|
166
|
+
if (node.parent.name !== 'StyleFeature' && node.parent.name !== 'StyleRange') {
|
|
167
|
+
return null;
|
|
184
168
|
}
|
|
185
|
-
|
|
186
|
-
if (!
|
|
169
|
+
const rawText = matching.ast.text(node);
|
|
170
|
+
if (!rawText.startsWith('--')) {
|
|
187
171
|
return null;
|
|
188
172
|
}
|
|
189
173
|
|
|
190
|
-
|
|
191
|
-
// includes the > in the token with --foo. We need to strip it.
|
|
192
|
-
const text = node.name === 'KeywordQuery' ? rawText.split(/\s|[>!=<:]/)[0] : rawText;
|
|
193
|
-
|
|
194
|
-
return new VariableNameMatch(node, text, this.matchedStyles, this.style);
|
|
174
|
+
return new VariableNameMatch(node, rawText, this.matchedStyles, this.style);
|
|
195
175
|
}
|
|
196
176
|
}
|
|
197
177
|
|
|
@@ -476,13 +456,14 @@ export class ColorMixMatcher extends matcherBase(ColorMixMatch) {
|
|
|
476
456
|
return null;
|
|
477
457
|
}
|
|
478
458
|
const computedValueArgs = ASTUtils.callArgs(value);
|
|
479
|
-
if (computedValueArgs.length !== 3) {
|
|
459
|
+
if (computedValueArgs.length !== 2 && computedValueArgs.length !== 3) {
|
|
480
460
|
return null;
|
|
481
461
|
}
|
|
482
462
|
|
|
483
|
-
const [space, color1, color2] = computedValueArgs;
|
|
484
|
-
// Verify that all arguments are there, and that
|
|
485
|
-
if (space.length
|
|
463
|
+
const [space, color1, color2] = computedValueArgs.length === 3 ? computedValueArgs : [[], ...computedValueArgs];
|
|
464
|
+
// Verify that all arguments are there, and that an optional interpolation method starts with a literal `in`.
|
|
465
|
+
if ((space.length > 0 &&
|
|
466
|
+
(space.length < 2 || computedValueTree.text(ASTUtils.stripComments(space).next().value) !== 'in')) ||
|
|
486
467
|
color1.length < 1 || color2.length < 1) {
|
|
487
468
|
return null;
|
|
488
469
|
}
|
|
@@ -503,10 +484,11 @@ export class ColorMixMatcher extends matcherBase(ColorMixMatch) {
|
|
|
503
484
|
}
|
|
504
485
|
|
|
505
486
|
const args = ASTUtils.callArgs(node);
|
|
506
|
-
if (args.length !==
|
|
487
|
+
if (args.length !== computedValueArgs.length) {
|
|
507
488
|
return null;
|
|
508
489
|
}
|
|
509
|
-
|
|
490
|
+
const [authoredSpace, authoredColor1, authoredColor2] = args.length === 3 ? args : [[], ...args];
|
|
491
|
+
return new ColorMixMatch(matching.ast.text(node), node, authoredSpace, authoredColor1, authoredColor2);
|
|
510
492
|
}
|
|
511
493
|
}
|
|
512
494
|
|
|
@@ -16,9 +16,12 @@ import {type EvaluationOptions, type EvaluationResult, type ExecutionContext, Ru
|
|
|
16
16
|
import {Script} from './Script.js';
|
|
17
17
|
import {SDKModel} from './SDKModel.js';
|
|
18
18
|
import {
|
|
19
|
+
breakpointsActiveSettingDescriptor,
|
|
20
|
+
disableAsyncStackTracesSettingDescriptor,
|
|
19
21
|
jsSourceMapsEnabledSettingDescriptor,
|
|
20
22
|
pauseOnCaughtExceptionSettingDescriptor,
|
|
21
23
|
pauseOnExceptionEnabledSettingDescriptor,
|
|
24
|
+
pauseOnUncaughtExceptionSettingDescriptor,
|
|
22
25
|
} from './SDKSettings.js';
|
|
23
26
|
import {SourceMap} from './SourceMap.js';
|
|
24
27
|
import {SourceMapManager} from './SourceMapManager.js';
|
|
@@ -137,6 +140,12 @@ export const WASM_SYMBOLS_PRIORITY = [
|
|
|
137
140
|
Protocol.Debugger.DebugSymbolsType.SourceMap,
|
|
138
141
|
];
|
|
139
142
|
|
|
143
|
+
export const skipAllPausesSettingDescriptor: Common.Settings.SettingDescriptor<boolean> = {
|
|
144
|
+
name: 'skip-all-pauses',
|
|
145
|
+
type: Common.Settings.SettingType.BOOLEAN,
|
|
146
|
+
defaultValue: false,
|
|
147
|
+
};
|
|
148
|
+
|
|
140
149
|
export class DebuggerModel extends SDKModel<EventTypes> {
|
|
141
150
|
readonly agent: ProtocolProxyApi.DebuggerApi;
|
|
142
151
|
#runtimeModel: RuntimeModel;
|
|
@@ -149,6 +158,13 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
149
158
|
#selectedCallFrame: CallFrame|null = null;
|
|
150
159
|
#debuggerEnabled = false;
|
|
151
160
|
#debuggerId: string|null = null;
|
|
161
|
+
readonly #pauseOnExceptionEnabledSetting: Common.Settings.Setting<boolean>;
|
|
162
|
+
readonly #pauseOnCaughtExceptionSetting: Common.Settings.Setting<boolean>;
|
|
163
|
+
readonly #pauseOnUncaughtExceptionSetting: Common.Settings.Setting<boolean>;
|
|
164
|
+
readonly #disableAsyncStackTracesSetting: Common.Settings.Setting<boolean>;
|
|
165
|
+
readonly #breakpointsActiveSetting: Common.Settings.Setting<boolean>;
|
|
166
|
+
readonly #jsSourceMapsEnabledSetting: Common.Settings.Setting<boolean>;
|
|
167
|
+
readonly #skipAllPausesSetting: Common.Settings.Setting<boolean>;
|
|
152
168
|
#skipAllPausesTimeout?: ReturnType<typeof setTimeout>;
|
|
153
169
|
#beforePausedCallback: ((arg0: DebuggerPausedDetails, stepOver: Location|null) => Promise<boolean>)|null = null;
|
|
154
170
|
#computeAutoStepRangesCallback: ((arg0: StepMode, arg1: CallFrame) => Promise<Array<{
|
|
@@ -179,22 +195,27 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
179
195
|
compiledURL, sourceMappingURL, payload, target.targetManager().getConsole(), script));
|
|
180
196
|
|
|
181
197
|
const settings = this.target().targetManager().settings;
|
|
182
|
-
settings.resolve(pauseOnExceptionEnabledSettingDescriptor)
|
|
183
|
-
|
|
184
|
-
settings.resolve(pauseOnCaughtExceptionSettingDescriptor)
|
|
185
|
-
|
|
186
|
-
settings.
|
|
187
|
-
|
|
188
|
-
settings.
|
|
198
|
+
this.#pauseOnExceptionEnabledSetting = settings.resolve(pauseOnExceptionEnabledSettingDescriptor);
|
|
199
|
+
this.#pauseOnExceptionEnabledSetting.addChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
200
|
+
this.#pauseOnCaughtExceptionSetting = settings.resolve(pauseOnCaughtExceptionSettingDescriptor);
|
|
201
|
+
this.#pauseOnCaughtExceptionSetting.addChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
202
|
+
this.#pauseOnUncaughtExceptionSetting = settings.resolve(pauseOnUncaughtExceptionSettingDescriptor);
|
|
203
|
+
this.#pauseOnUncaughtExceptionSetting.addChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
204
|
+
this.#disableAsyncStackTracesSetting = settings.resolve(disableAsyncStackTracesSettingDescriptor);
|
|
205
|
+
this.#disableAsyncStackTracesSetting.addChangeListener(this.asyncStackTracesStateChanged, this);
|
|
206
|
+
this.#breakpointsActiveSetting = settings.resolve(breakpointsActiveSettingDescriptor);
|
|
207
|
+
this.#breakpointsActiveSetting.addChangeListener(this.breakpointsActiveChanged, this);
|
|
208
|
+
this.#skipAllPausesSetting = settings.resolve(skipAllPausesSettingDescriptor);
|
|
209
|
+
this.#skipAllPausesSetting.addChangeListener(this.skipAllPausesChanged, this);
|
|
210
|
+
|
|
211
|
+
this.#jsSourceMapsEnabledSetting = settings.resolve(jsSourceMapsEnabledSettingDescriptor);
|
|
212
|
+
this.#jsSourceMapsEnabledSetting.addChangeListener(this.jsSourceMapsStateChanged, this);
|
|
213
|
+
this.#sourceMapManager.setEnabled(this.#jsSourceMapsEnabledSetting.get());
|
|
189
214
|
|
|
190
215
|
if (!target.suspended()) {
|
|
191
216
|
void this.enableDebugger();
|
|
192
217
|
}
|
|
193
218
|
|
|
194
|
-
this.#sourceMapManager.setEnabled(settings.resolve(jsSourceMapsEnabledSettingDescriptor).get());
|
|
195
|
-
settings.resolve(jsSourceMapsEnabledSettingDescriptor)
|
|
196
|
-
.addChangeListener(event => this.#sourceMapManager.setEnabled((event.data as boolean)));
|
|
197
|
-
|
|
198
219
|
const resourceTreeModel = (target.model(ResourceTreeModel) as ResourceTreeModel);
|
|
199
220
|
if (resourceTreeModel) {
|
|
200
221
|
resourceTreeModel.addEventListener(ResourceTreeModelEvents.FrameNavigated, this.onFrameNavigated, this);
|
|
@@ -256,6 +277,11 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
256
277
|
}
|
|
257
278
|
this.#debuggerEnabled = true;
|
|
258
279
|
|
|
280
|
+
let skipAllPausesPromise: Promise<Protocol.ProtocolResponseWithError>|undefined;
|
|
281
|
+
if (this.#skipAllPausesSetting.get()) {
|
|
282
|
+
skipAllPausesPromise = this.agent.invoke_setSkipAllPauses({skip: true});
|
|
283
|
+
}
|
|
284
|
+
|
|
259
285
|
// Set a limit for the total size of collected script sources retained by debugger.
|
|
260
286
|
// 10MB for remote frontends, 100MB for others.
|
|
261
287
|
const isRemoteFrontend = Root.Runtime.Runtime.queryParam('remoteFrontend') || Root.Runtime.Runtime.queryParam('ws');
|
|
@@ -269,12 +295,11 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
269
295
|
}
|
|
270
296
|
this.pauseOnExceptionStateChanged();
|
|
271
297
|
void this.asyncStackTracesStateChanged();
|
|
272
|
-
|
|
273
|
-
if (!settings.moduleSetting('breakpoints-active').get()) {
|
|
298
|
+
if (!this.#breakpointsActiveSetting.get()) {
|
|
274
299
|
this.breakpointsActiveChanged();
|
|
275
300
|
}
|
|
276
301
|
this.dispatchEventToListeners(Events.DebuggerWasEnabled, this);
|
|
277
|
-
const [enableResult] = await Promise.all([enablePromise, instrumentationPromise]);
|
|
302
|
+
const [enableResult] = await Promise.all([enablePromise, instrumentationPromise, skipAllPausesPromise]);
|
|
278
303
|
this.registerDebugger(enableResult);
|
|
279
304
|
}
|
|
280
305
|
|
|
@@ -344,12 +369,24 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
344
369
|
}
|
|
345
370
|
|
|
346
371
|
private skipAllPauses(skip: boolean): void {
|
|
372
|
+
if (this.#skipAllPausesSetting.get()) {
|
|
373
|
+
return;
|
|
374
|
+
}
|
|
347
375
|
clearTimeout(this.#skipAllPausesTimeout);
|
|
348
376
|
|
|
349
377
|
void this.agent.invoke_setSkipAllPauses({skip});
|
|
350
378
|
}
|
|
351
379
|
|
|
380
|
+
private skipAllPausesChanged(): void {
|
|
381
|
+
const skip = this.#skipAllPausesSetting.get();
|
|
382
|
+
clearTimeout(this.#skipAllPausesTimeout);
|
|
383
|
+
void this.agent.invoke_setSkipAllPauses({skip});
|
|
384
|
+
}
|
|
385
|
+
|
|
352
386
|
skipAllPausesUntilReloadOrTimeout(timeout: number): void {
|
|
387
|
+
if (this.#skipAllPausesSetting.get()) {
|
|
388
|
+
return;
|
|
389
|
+
}
|
|
353
390
|
clearTimeout(this.#skipAllPausesTimeout);
|
|
354
391
|
|
|
355
392
|
void this.agent.invoke_setSkipAllPauses({skip: true});
|
|
@@ -360,12 +397,15 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
360
397
|
);
|
|
361
398
|
}
|
|
362
399
|
|
|
400
|
+
private jsSourceMapsStateChanged(): void {
|
|
401
|
+
this.#sourceMapManager.setEnabled(this.#jsSourceMapsEnabledSetting.get());
|
|
402
|
+
}
|
|
403
|
+
|
|
363
404
|
private pauseOnExceptionStateChanged(): void {
|
|
364
|
-
const
|
|
365
|
-
const pauseOnCaughtEnabled = settings.resolve(pauseOnCaughtExceptionSettingDescriptor).get();
|
|
405
|
+
const pauseOnCaughtEnabled = this.#pauseOnCaughtExceptionSetting.get();
|
|
366
406
|
let state: Protocol.Debugger.SetPauseOnExceptionsRequestState;
|
|
367
407
|
|
|
368
|
-
const pauseOnUncaughtEnabled =
|
|
408
|
+
const pauseOnUncaughtEnabled = this.#pauseOnUncaughtExceptionSetting.get();
|
|
369
409
|
if (pauseOnCaughtEnabled && pauseOnUncaughtEnabled) {
|
|
370
410
|
state = Protocol.Debugger.SetPauseOnExceptionsRequestState.All;
|
|
371
411
|
} else if (pauseOnCaughtEnabled) {
|
|
@@ -380,15 +420,13 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
380
420
|
|
|
381
421
|
private asyncStackTracesStateChanged(): Promise<Protocol.ProtocolResponseWithError> {
|
|
382
422
|
const maxAsyncStackChainDepth = 32;
|
|
383
|
-
const
|
|
384
|
-
const enabled = !settings.moduleSetting('disable-async-stack-traces').get() && this.#debuggerEnabled;
|
|
423
|
+
const enabled = !this.#disableAsyncStackTracesSetting.get() && this.#debuggerEnabled;
|
|
385
424
|
const maxDepth = enabled ? maxAsyncStackChainDepth : 0;
|
|
386
425
|
return this.agent.invoke_setAsyncCallStackDepth({maxDepth});
|
|
387
426
|
}
|
|
388
427
|
|
|
389
428
|
private breakpointsActiveChanged(): void {
|
|
390
|
-
|
|
391
|
-
void this.agent.invoke_setBreakpointsActive({active: settings.moduleSetting('breakpoints-active').get()});
|
|
429
|
+
void this.agent.invoke_setBreakpointsActive({active: this.#breakpointsActiveSetting.get()});
|
|
392
430
|
}
|
|
393
431
|
|
|
394
432
|
setComputeAutoStepRangesCallback(callback: ((arg0: StepMode, arg1: CallFrame) => Promise<LocationRange[]>)|null):
|
|
@@ -622,6 +660,11 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
622
660
|
return;
|
|
623
661
|
}
|
|
624
662
|
|
|
663
|
+
if (this.#skipAllPausesSetting.get()) {
|
|
664
|
+
this.resume();
|
|
665
|
+
return;
|
|
666
|
+
}
|
|
667
|
+
|
|
625
668
|
const pausedDetails =
|
|
626
669
|
new DebuggerPausedDetails(this, callFrames, reason, auxData, breakpointIds, asyncStackTrace, asyncStackTraceId);
|
|
627
670
|
|
|
@@ -639,8 +682,6 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
639
682
|
} else {
|
|
640
683
|
void this.stepInto();
|
|
641
684
|
}
|
|
642
|
-
} else {
|
|
643
|
-
Common.EventTarget.fireEvent('DevTools.DebuggerPaused');
|
|
644
685
|
}
|
|
645
686
|
}
|
|
646
687
|
|
|
@@ -649,16 +690,16 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
649
690
|
this.dispatchEventToListeners(Events.DebuggerResumed, this);
|
|
650
691
|
}
|
|
651
692
|
|
|
652
|
-
parsedScriptSource(
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
693
|
+
parsedScriptSource(scriptId: Protocol.Runtime.ScriptId, sourceURL: Platform.DevToolsPath.UrlString, startLine: number,
|
|
694
|
+
startColumn: number, endLine: number, endColumn: number,
|
|
695
|
+
// TODO(crbug.com/1172300) Ignored during the jsdoc to ts migration
|
|
696
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
697
|
+
executionContextId: number, hash: string, executionContextAuxData: any,
|
|
698
|
+
sourceMapURL: string|undefined, hasSourceURLComment: boolean, hasSyntaxError: boolean,
|
|
699
|
+
length: number, isModule: boolean|null, originStackTrace: Protocol.Runtime.StackTrace|null,
|
|
700
|
+
codeOffset: number|null, scriptLanguage: string|null,
|
|
701
|
+
debugSymbols: Protocol.Debugger.DebugSymbols[]|null,
|
|
702
|
+
embedderName: Platform.DevToolsPath.UrlString|null, buildId: string|null): Script {
|
|
662
703
|
const knownScript = this.#scripts.get(scriptId);
|
|
663
704
|
if (knownScript) {
|
|
664
705
|
return knownScript;
|
|
@@ -670,10 +711,9 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
670
711
|
|
|
671
712
|
const selectedDebugSymbol =
|
|
672
713
|
DebuggerModel.selectSymbolSource(debugSymbols, this.target().targetManager().getConsole());
|
|
673
|
-
const script = new Script(
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
scriptLanguage, selectedDebugSymbol, embedderName, buildId);
|
|
714
|
+
const script = new Script(this, scriptId, sourceURL, startLine, startColumn, endLine, endColumn, executionContextId,
|
|
715
|
+
hash, isContentScript, sourceMapURL, hasSourceURLComment, length, isModule,
|
|
716
|
+
originStackTrace, codeOffset, scriptLanguage, selectedDebugSymbol, embedderName, buildId);
|
|
677
717
|
this.registerScript(script);
|
|
678
718
|
this.dispatchEventToListeners(Events.ParsedScriptSource, script);
|
|
679
719
|
|
|
@@ -873,12 +913,13 @@ export class DebuggerModel extends SDKModel<EventTypes> {
|
|
|
873
913
|
if (this.#debuggerId) {
|
|
874
914
|
debuggerIdToModel.delete(this.#debuggerId);
|
|
875
915
|
}
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
916
|
+
this.#pauseOnExceptionEnabledSetting.removeChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
917
|
+
this.#pauseOnCaughtExceptionSetting.removeChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
918
|
+
this.#skipAllPausesSetting.removeChangeListener(this.skipAllPausesChanged, this);
|
|
919
|
+
this.#pauseOnUncaughtExceptionSetting.removeChangeListener(this.pauseOnExceptionStateChanged, this);
|
|
920
|
+
this.#disableAsyncStackTracesSetting.removeChangeListener(this.asyncStackTracesStateChanged, this);
|
|
921
|
+
this.#breakpointsActiveSetting.removeChangeListener(this.breakpointsActiveChanged, this);
|
|
922
|
+
this.#jsSourceMapsEnabledSetting.removeChangeListener(this.jsSourceMapsStateChanged, this);
|
|
882
923
|
}
|
|
883
924
|
|
|
884
925
|
override async suspendModel(): Promise<void> {
|
|
@@ -972,7 +1013,6 @@ export enum Events {
|
|
|
972
1013
|
GlobalObjectCleared = 'GlobalObjectCleared',
|
|
973
1014
|
CallFrameSelected = 'CallFrameSelected',
|
|
974
1015
|
DebuggerIsReadyToPause = 'DebuggerIsReadyToPause',
|
|
975
|
-
ScriptSourceWasEdited = 'ScriptSourceWasEdited',
|
|
976
1016
|
/* eslint-enable @typescript-eslint/naming-convention */
|
|
977
1017
|
}
|
|
978
1018
|
|
|
@@ -987,10 +1027,6 @@ export interface EventTypes {
|
|
|
987
1027
|
[Events.CallFrameSelected]: DebuggerModel;
|
|
988
1028
|
[Events.DebuggerIsReadyToPause]: DebuggerModel;
|
|
989
1029
|
[Events.DebugInfoAttached]: Script;
|
|
990
|
-
[Events.ScriptSourceWasEdited]: {
|
|
991
|
-
script: Script,
|
|
992
|
-
status: Protocol.Debugger.SetScriptSourceResponseStatus,
|
|
993
|
-
};
|
|
994
1030
|
}
|
|
995
1031
|
|
|
996
1032
|
class DebuggerDispatcher implements ProtocolProxyApi.DebuggerDispatcher {
|
|
@@ -1026,7 +1062,6 @@ class DebuggerDispatcher implements ProtocolProxyApi.DebuggerDispatcher {
|
|
|
1026
1062
|
executionContextId,
|
|
1027
1063
|
hash,
|
|
1028
1064
|
executionContextAuxData,
|
|
1029
|
-
isLiveEdit,
|
|
1030
1065
|
sourceMapURL,
|
|
1031
1066
|
hasSourceURL,
|
|
1032
1067
|
length,
|
|
@@ -1043,9 +1078,9 @@ class DebuggerDispatcher implements ProtocolProxyApi.DebuggerDispatcher {
|
|
|
1043
1078
|
}
|
|
1044
1079
|
this.#debuggerModel.parsedScriptSource(
|
|
1045
1080
|
scriptId, url as Platform.DevToolsPath.UrlString, startLine, startColumn, endLine, endColumn,
|
|
1046
|
-
executionContextId, hash, executionContextAuxData,
|
|
1047
|
-
|
|
1048
|
-
|
|
1081
|
+
executionContextId, hash, executionContextAuxData, sourceMapURL, Boolean(hasSourceURL), false, length || 0,
|
|
1082
|
+
isModule || null, stackTrace || null, codeOffset || null, scriptLanguage || null, debugSymbols || null,
|
|
1083
|
+
embedderName as Platform.DevToolsPath.UrlString || null, buildId || null);
|
|
1049
1084
|
}
|
|
1050
1085
|
|
|
1051
1086
|
scriptFailedToParse({
|
|
@@ -1071,11 +1106,11 @@ class DebuggerDispatcher implements ProtocolProxyApi.DebuggerDispatcher {
|
|
|
1071
1106
|
if (!this.#debuggerModel.debuggerEnabled()) {
|
|
1072
1107
|
return;
|
|
1073
1108
|
}
|
|
1074
|
-
this.#debuggerModel.parsedScriptSource(
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1109
|
+
this.#debuggerModel.parsedScriptSource(scriptId, url as Platform.DevToolsPath.UrlString, startLine, startColumn,
|
|
1110
|
+
endLine, endColumn, executionContextId, hash, executionContextAuxData,
|
|
1111
|
+
sourceMapURL, Boolean(hasSourceURL), true, length || 0, isModule || null,
|
|
1112
|
+
stackTrace || null, codeOffset || null, scriptLanguage || null, null,
|
|
1113
|
+
embedderName as Platform.DevToolsPath.UrlString || null, buildId || null);
|
|
1079
1114
|
}
|
|
1080
1115
|
|
|
1081
1116
|
breakpointResolved({breakpointId, location}: Protocol.Debugger.BreakpointResolvedEvent): void {
|
|
@@ -9,6 +9,7 @@ import {CSSModel} from './CSSModel.js';
|
|
|
9
9
|
import type {MultitargetNetworkManager} from './NetworkManager.js';
|
|
10
10
|
import {Events, OverlayModel} from './OverlayModel.js';
|
|
11
11
|
import {SDKModel} from './SDKModel.js';
|
|
12
|
+
import {javaScriptDisabledSettingDescriptor} from './SDKSettings.js';
|
|
12
13
|
import {Capability, type Target} from './Target.js';
|
|
13
14
|
|
|
14
15
|
export const enum DataSaverOverride {
|
|
@@ -52,7 +53,7 @@ export class EmulationModel extends SDKModel<EmulationModelEventTypes> implement
|
|
|
52
53
|
}
|
|
53
54
|
|
|
54
55
|
const settings = this.target().targetManager().settings;
|
|
55
|
-
const disableJavascriptSetting = settings.
|
|
56
|
+
const disableJavascriptSetting = settings.resolve(javaScriptDisabledSettingDescriptor);
|
|
56
57
|
disableJavascriptSetting.addChangeListener(
|
|
57
58
|
async () =>
|
|
58
59
|
await this.#emulationAgent.invoke_setScriptExecutionDisabled({value: disableJavascriptSetting.get()}));
|