chrome-devtools-frontend 1.0.1669021 → 1.0.1672557
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/skills/fixing-skipped-tests/SKILL.md +6 -6
- package/.agents/skills/gerrit-cli/SKILL.md +4 -10
- package/.agents/skills/gerrit-cli/references/commands.md +45 -2
- package/.agents/skills/gerrit-cli/references/workflows.md +7 -0
- package/.agents/skills/gerrit-cli/scripts/import_upstream.py +34 -152
- package/config/typescript/tsconfig.eslint.json +1 -1
- package/docs/contributing/settings-experiments-features.md +2 -8
- package/docs/ecosystem/automatic_workspace_folders.md +0 -19
- package/eslint.config.mjs +5 -5
- package/front_end/core/common/Lazy.ts +3 -3
- package/front_end/core/common/SettingRegistration.ts +0 -7
- package/front_end/core/common/Settings.ts +0 -38
- package/front_end/core/host/UserMetrics.ts +187 -953
- package/front_end/core/host/UserMetricsEnums.ts +949 -0
- package/front_end/core/root/Runtime.ts +21 -138
- package/front_end/core/sdk/CSSMetadata.ts +70 -65
- package/front_end/core/sdk/CategorizedBreakpoint.ts +0 -1
- package/front_end/core/sdk/ChildTargetManager.ts +0 -2
- package/front_end/core/sdk/EmulationModel.ts +0 -2
- package/front_end/core/sdk/EventBreakpointsModel.ts +0 -4
- package/front_end/core/sdk/NetworkManager.ts +0 -3
- package/front_end/core/sdk/PageResourceLoader.ts +9 -9
- package/front_end/core/sdk/RehydratingConnection.ts +52 -4
- package/front_end/core/sdk/Target.ts +0 -4
- package/front_end/devtools_compatibility.js +886 -0
- package/front_end/entrypoints/inspector_main/RenderingOptions.ts +7 -6
- package/front_end/entrypoints/main/ExecutionContextSelector.ts +0 -1
- package/front_end/entrypoints/main/MainImpl.ts +18 -22
- package/front_end/foundation/Universe.ts +7 -2
- package/front_end/generated/InspectorBackendCommands.ts +3 -10
- package/front_end/generated/{SupportedCSSProperties.js → SupportedCSSProperties.ts} +16 -0
- package/front_end/generated/protocol-mapping.d.ts +0 -42
- package/front_end/generated/protocol-proxy-api.d.ts +0 -38
- package/front_end/generated/protocol.ts +9 -169
- package/front_end/models/ai_assistance/AiAgent2.ts +11 -3
- package/front_end/models/ai_assistance/AiConversation.ts +1 -0
- package/front_end/models/ai_assistance/AiHistoryStorage.ts +8 -5
- package/front_end/models/ai_assistance/AiSetting.ts +108 -0
- package/front_end/models/ai_assistance/AiUtils.ts +47 -0
- package/front_end/models/ai_assistance/ChangeManager.ts +1 -0
- package/front_end/models/ai_assistance/ExtensionScope.ts +3 -12
- package/front_end/models/ai_assistance/agents/AiAgent.ts +11 -18
- package/front_end/models/ai_assistance/agents/ContextSelectionAgent.ts +3 -0
- package/front_end/models/ai_assistance/agents/ExecuteJavascript.ts +42 -17
- package/front_end/models/ai_assistance/agents/PerformanceAgent.snapshot.txt +1 -1
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +3 -2
- package/front_end/models/ai_assistance/agents/StorageAgent.ts +253 -155
- package/front_end/models/ai_assistance/agents/StylingAgent.snapshot.txt +2 -2
- package/front_end/models/ai_assistance/ai_assistance.ts +4 -0
- package/front_end/models/ai_assistance/contexts/PerformanceTraceContext.ts +12 -6
- package/front_end/models/ai_assistance/data_formatters/FileFormatter.ts +3 -1
- package/front_end/models/ai_assistance/data_formatters/NetworkRequestFormatter.ts +1 -0
- package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.ts +4 -3
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +1 -1
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +1 -0
- package/front_end/models/ai_assistance/injected.ts +1 -0
- package/front_end/models/ai_assistance/performance/AICallTree.ts +1 -0
- package/front_end/models/ai_assistance/skills/Skill.ts +1 -1
- package/front_end/models/ai_assistance/skills/SkillRegistry.ts +2 -0
- package/front_end/models/ai_assistance/skills/performance.md +10 -0
- package/front_end/models/ai_assistance/tools/ExecuteJavaScript.ts +52 -5
- package/front_end/models/ai_assistance/tools/GetElementAccessibilityDetails.ts +4 -4
- package/front_end/models/ai_assistance/tools/GetLighthouseAudits.ts +4 -4
- package/front_end/models/ai_assistance/tools/GetNetworkRequestDetails.ts +5 -4
- package/front_end/models/ai_assistance/tools/GetStyles.ts +5 -4
- package/front_end/models/ai_assistance/tools/ListNetworkRequests.ts +5 -4
- package/front_end/models/ai_assistance/tools/README.md +1 -1
- package/front_end/models/ai_assistance/tools/RecordPerformanceTrace.ts +63 -0
- package/front_end/models/ai_assistance/tools/ResolveDevtoolsNodePath.ts +5 -5
- package/front_end/models/ai_assistance/tools/Tool.ts +118 -24
- package/front_end/models/ai_assistance/tools/ToolRegistry.ts +2 -0
- package/front_end/models/badges/UserBadges.ts +2 -0
- package/front_end/models/bindings/NetworkProject.ts +5 -0
- package/front_end/models/bindings/ResourceScriptMapping.ts +2 -0
- package/front_end/models/bindings/ResourceUtils.ts +3 -0
- package/front_end/models/crux-manager/CrUXManager.ts +1 -0
- package/front_end/models/emulation/DeviceModeModel.ts +140 -7
- package/front_end/models/emulation/EmulatedDevices.ts +246 -793
- package/front_end/models/issues_manager/IssuesManager.ts +10 -2
- package/front_end/models/live-metrics/LiveMetrics.ts +41 -9
- package/front_end/models/logs/LogManager.ts +8 -5
- package/front_end/models/logs/NetworkLog.ts +1 -0
- package/front_end/models/persistence/IsolatedFileSystemManager.ts +21 -3
- package/front_end/models/persistence/NetworkPersistenceManager.ts +6 -0
- package/front_end/models/project_settings/ProjectSettingsModel.ts +8 -12
- package/front_end/models/trace/Processor.ts +42 -10
- package/front_end/models/trace/handlers/LayoutShiftsHandler.ts +12 -19
- package/front_end/models/trace/handlers/MetaHandler.ts +38 -5
- package/front_end/models/trace/insights/CLSCulprits.ts +1 -2
- package/front_end/models/trace/insights/CharacterSet.ts +1 -1
- package/front_end/models/trace/insights/Common.ts +21 -2
- package/front_end/models/trace/insights/DocumentLatency.ts +1 -1
- package/front_end/models/trace/insights/LCPBreakdown.ts +7 -6
- package/front_end/models/trace/insights/LCPDiscovery.ts +1 -1
- package/front_end/models/trace/insights/ModernHTTP.ts +7 -3
- package/front_end/models/trace/insights/NetworkDependencyTree.ts +1 -1
- package/front_end/models/trace/insights/RenderBlocking.ts +1 -1
- package/front_end/models/trace/insights/ThirdParties.ts +5 -2
- package/front_end/models/trace/insights/types.ts +11 -6
- package/front_end/models/trace/types/Configuration.ts +5 -0
- package/front_end/models/trace_source_maps_resolver/SourceMapsResolver.ts +3 -1
- package/front_end/models/workspace/IgnoreListManager.ts +2 -0
- package/front_end/models/workspace/UISourceCode.ts +2 -0
- package/front_end/models/workspace_diff/WorkspaceDiff.ts +4 -0
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +22 -22
- package/front_end/panels/ai_assistance/ai_assistance-meta.ts +0 -7
- package/front_end/panels/ai_assistance/components/ChatInput.ts +4 -0
- package/front_end/panels/ai_assistance/components/ChatMessage.ts +79 -34
- package/front_end/panels/ai_assistance/components/WalkthroughView.ts +1 -2
- package/front_end/panels/ai_assistance/components/walkthroughView.css +1 -1
- package/front_end/panels/application/ApplicationPanelSidebar.ts +9 -106
- package/front_end/panels/application/ApplicationPanelTreeElement.ts +1 -1
- package/front_end/panels/application/application.ts +0 -10
- package/front_end/panels/application/components/components.ts +0 -4
- package/front_end/panels/browser_debugger/CategorizedBreakpointsSidebarPane.ts +0 -5
- package/front_end/panels/browser_debugger/EventListenerBreakpointsSidebarPane.ts +6 -12
- package/front_end/panels/browser_debugger/browser_debugger-meta.ts +5 -3
- package/front_end/panels/console/ConsoleFormat.ts +2 -62
- package/front_end/panels/console/ConsoleViewMessage.ts +14 -7
- package/front_end/panels/elements/ElementsTreeElement.ts +1 -2
- package/front_end/panels/emulation/AdvancedApp.ts +1 -2
- package/front_end/panels/emulation/DeviceModeToolbar.ts +83 -69
- package/front_end/panels/emulation/DeviceModeView.ts +4 -134
- package/front_end/panels/emulation/DeviceModeWrapper.ts +52 -69
- package/front_end/panels/emulation/MediaQueryInspector.ts +2 -2
- package/front_end/panels/emulation/emulation-meta.ts +12 -12
- package/front_end/panels/issues/IssuesPane.ts +3 -1
- package/front_end/panels/lighthouse/LighthouseController.ts +6 -0
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +17 -21
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryNavigator.ts +206 -126
- package/front_end/panels/linear_memory_inspector/components/linearMemoryInspector.css +1 -1
- package/front_end/panels/mobile_throttling/CalibrationController.ts +1 -1
- package/front_end/panels/mobile_throttling/MobileThrottlingSelector.ts +3 -3
- package/front_end/panels/mobile_throttling/NetworkPanelIndicator.ts +6 -6
- package/front_end/panels/mobile_throttling/NetworkThrottlingSelector.ts +14 -12
- package/front_end/panels/mobile_throttling/ThrottlingManager.ts +13 -13
- package/front_end/panels/mobile_throttling/ThrottlingPresets.ts +10 -10
- package/front_end/panels/mobile_throttling/ThrottlingSettingsTab.ts +28 -28
- package/front_end/panels/mobile_throttling/mobile_throttling-meta.ts +6 -6
- package/front_end/panels/network/RequestHeadersView.ts +1 -1
- package/front_end/panels/network/ResourceChunkView.ts +243 -144
- package/front_end/panels/network/ResourceDirectSocketChunkView.ts +52 -29
- package/front_end/panels/network/ResourceWebSocketFrameView.ts +21 -35
- package/front_end/panels/network/resourceChunkView.css +41 -36
- package/front_end/panels/profiler/HeapDetachedElementsDataGrid.ts +21 -12
- package/front_end/panels/profiler/profiler.ts +4 -0
- package/front_end/panels/recorder/RecorderPanel.ts +6 -14
- package/front_end/panels/sensors/LocationsSettingsTab.ts +7 -7
- package/front_end/panels/settings/AISettingsTab.ts +75 -31
- package/front_end/panels/settings/SettingsScreen.ts +8 -13
- package/front_end/panels/settings/components/SyncSection.ts +3 -4
- package/front_end/panels/settings/emulation/DevicesSettingsTab.ts +650 -18
- package/front_end/panels/settings/emulation/devicesSettingsTab.css +18 -0
- package/front_end/panels/settings/settings-meta.ts +0 -1
- package/front_end/panels/sources/CategorizedBreakpointL10n.ts +0 -2
- package/front_end/panels/sources/DebuggerPausedMessage.ts +11 -5
- package/front_end/panels/sources/DebuggerPlugin.ts +1 -1
- package/front_end/panels/sources/EditingLocationHistoryManager.ts +12 -9
- package/front_end/panels/sources/SourcesPanel.ts +19 -17
- package/front_end/panels/sources/SourcesView.ts +191 -96
- package/front_end/panels/sources/TabbedEditorContainer.ts +3 -4
- package/front_end/panels/sources/WatchExpressionsSidebarPane.ts +2 -5
- package/front_end/panels/timeline/TimelinePanel.ts +2 -0
- package/front_end/panels/timeline/TimelineUIUtils.ts +15 -0
- package/front_end/panels/timeline/components/CWVMetrics.ts +16 -3
- package/front_end/panels/timeline/components/cwvMetrics.css +4 -0
- package/front_end/panels/timeline/components/liveMetricsView.css +0 -17
- package/front_end/panels/timeline/components/metricValueStyles.css +17 -0
- package/front_end/panels/timeline/timeline-meta.ts +3 -5
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/codemirror.next/chunk/angular.js +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/chunk/cpp.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/cpp.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/java.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/java.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/legacy.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/less.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/less.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/markdown.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/markdown.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/php.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/php.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/python.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/python.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/sass.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/sass.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/svelte.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/svelte.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/vue.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/wast.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/wast.js.map +1 -1
- package/front_end/third_party/codemirror.next/chunk/xml.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/xml.js.map +1 -1
- package/front_end/third_party/codemirror.next/codemirror.next.d.ts +1332 -193
- package/front_end/third_party/codemirror.next/codemirror.next.js +1 -1
- package/front_end/third_party/codemirror.next/rebuild.sh +1 -1
- package/front_end/third_party/puppeteer/README.chromium +2 -2
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.d.ts +64 -15
- package/front_end/third_party/puppeteer/package/lib/es5-iife/puppeteer-core-browser.js +65 -16
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts +50 -7
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/api/Page.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/BidiOverCdp.d.ts +2 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/BidiOverCdp.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/BidiOverCdp.js +5 -5
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/BidiOverCdp.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Connection.d.ts +2 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Connection.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Connection.js +8 -6
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Connection.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Dialog.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Dialog.js +3 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/bidi/Dialog.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Browser.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Browser.js +16 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Browser.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Connection.d.ts +5 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Connection.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Connection.js +11 -6
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Connection.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Dialog.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Dialog.js +5 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/Dialog.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/NetworkManager.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/NetworkManager.js +10 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/cdp/NetworkManager.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js +4 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/BrowserConnector.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Debug.d.ts +27 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Debug.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Debug.js +12 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/Debug.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/util.d.ts +2 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/util.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/util.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/puppeteer/common/util.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ChromeLauncher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ChromeLauncher.js +2 -0
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ChromeLauncher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ScreenRecorder.d.ts +2 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ScreenRecorder.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ScreenRecorder.js +5 -4
- package/front_end/third_party/puppeteer/package/lib/puppeteer/node/ScreenRecorder.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.d.ts +3 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/revisions.js +3 -3
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/puppeteer/util/version.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/types.d.ts +64 -15
- package/front_end/third_party/puppeteer/package/package.json +2 -2
- package/front_end/third_party/puppeteer/package/src/api/Page.ts +50 -7
- package/front_end/third_party/puppeteer/package/src/bidi/BidiOverCdp.ts +9 -7
- package/front_end/third_party/puppeteer/package/src/bidi/Connection.ts +9 -6
- package/front_end/third_party/puppeteer/package/src/bidi/Dialog.ts +4 -0
- package/front_end/third_party/puppeteer/package/src/cdp/Browser.ts +24 -1
- package/front_end/third_party/puppeteer/package/src/cdp/Connection.ts +11 -6
- package/front_end/third_party/puppeteer/package/src/cdp/Dialog.ts +7 -0
- package/front_end/third_party/puppeteer/package/src/cdp/NetworkManager.ts +11 -0
- package/front_end/third_party/puppeteer/package/src/common/BrowserConnector.ts +7 -3
- package/front_end/third_party/puppeteer/package/src/common/Debug.ts +30 -5
- package/front_end/third_party/puppeteer/package/src/common/util.ts +2 -2
- package/front_end/third_party/puppeteer/package/src/node/ChromeLauncher.ts +2 -0
- package/front_end/third_party/puppeteer/package/src/node/ScreenRecorder.ts +6 -4
- package/front_end/third_party/puppeteer/package/src/revisions.ts +3 -3
- package/front_end/third_party/puppeteer/package/src/util/version.ts +1 -1
- package/front_end/tsconfig.compatibility.json +2 -1
- package/front_end/tsconfig.json +1 -1
- package/front_end/ui/components/icon_button/IconButton.ts +1 -1
- package/front_end/ui/components/issue_counter/IssueCounter.ts +1 -1
- package/front_end/ui/components/settings/SettingCheckbox.ts +4 -7
- package/front_end/ui/components/settings/settings.ts +1 -2
- package/front_end/ui/legacy/Treeoutline.ts +52 -30
- package/front_end/ui/legacy/components/object_ui/CSSStyleSanitizer.ts +74 -0
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +6 -1
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +47 -54
- package/front_end/ui/legacy/components/object_ui/object_ui.ts +2 -0
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +5 -27
- package/front_end/ui/legacy/components/settings_ui/SettingsUI.ts +10 -12
- package/front_end/ui/settings/SettingUIRegistration.ts +0 -8
- package/front_end/ui/visual_logging/KnownContextValues.ts +37 -0
- package/inspector_overlay/tsconfig.json +8 -2
- package/package.json +3 -2
- package/.agents/skills/gerrit-cli/scripts/gerrit_client_wrapper.py +0 -47
- package/front_end/core/sdk/CSSModel.test.api.ts +0 -102
- package/front_end/core/sdk/DOMModel.test.api.ts +0 -104
- package/front_end/foundation/Universe.test.api.ts +0 -73
- package/front_end/panels/application/SharedStorageEventsView.ts +0 -128
- package/front_end/panels/application/SharedStorageItemsView.ts +0 -179
- package/front_end/panels/application/SharedStorageListTreeElement.ts +0 -65
- package/front_end/panels/application/SharedStorageModel.ts +0 -249
- package/front_end/panels/application/SharedStorageTreeElement.ts +0 -40
- package/front_end/panels/application/components/SharedStorageAccessGrid.ts +0 -191
- package/front_end/panels/application/components/SharedStorageMetadataView.ts +0 -133
- package/front_end/panels/application/components/sharedStorageAccessGrid.css +0 -29
- package/front_end/panels/application/components/sharedStorageMetadataView.css +0 -29
- package/front_end/panels/application/sharedStorageEventsView.css +0 -9
- package/front_end/panels/network/OriginalResourceChunkView.ts +0 -340
- package/front_end/panels/network/originalResourceChunkView.css +0 -49
- package/front_end/ui/components/settings/SettingDeprecationWarning.ts +0 -47
- package/front_end/ui/components/settings/settingDeprecationWarning.css +0 -14
- /package/front_end/generated/{ARIAProperties.js → ARIAProperties.ts} +0 -0
|
@@ -1,109 +1,90 @@
|
|
|
1
1
|
// Copyright 2016 The Chromium Authors
|
|
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
|
-
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
5
4
|
|
|
6
5
|
import type * as Common from '../../core/common/common.js';
|
|
7
6
|
import * as Root from '../../core/root/root.js';
|
|
8
7
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
9
8
|
import type * as Protocol from '../../generated/protocol.js';
|
|
10
9
|
import * as EmulationModel from '../../models/emulation/emulation.js';
|
|
10
|
+
import * as Geometry from '../../models/geometry/geometry.js';
|
|
11
11
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
12
|
+
import {html, render} from '../../ui/lit/lit.js';
|
|
12
13
|
|
|
13
14
|
import {DeviceModeView} from './DeviceModeView.js';
|
|
14
|
-
import
|
|
15
|
+
import {InspectedPagePlaceholder} from './InspectedPagePlaceholder.js';
|
|
15
16
|
|
|
16
|
-
|
|
17
|
+
const {widget} = UI.Widget;
|
|
18
|
+
interface ViewInput {
|
|
19
|
+
showDeviceMode: boolean;
|
|
20
|
+
}
|
|
21
|
+
type View = (input: ViewInput, output: undefined, target: HTMLElement) => void;
|
|
22
|
+
export const DEFAULT_VIEW: View = (input, output, target) => {
|
|
23
|
+
// clang-format off
|
|
24
|
+
render(input.showDeviceMode ?
|
|
25
|
+
html`<devtools-widget ${widget(DeviceModeView)}>
|
|
26
|
+
${widget(() => InspectedPagePlaceholder.instance(), {minimumSize: new Geometry.Size(1, 1)})}
|
|
27
|
+
</devtools-widget>` :
|
|
28
|
+
widget(() => InspectedPagePlaceholder.instance(), {minimumSize: new Geometry.Size(150, 150)}),
|
|
29
|
+
target);
|
|
30
|
+
// clang-format on
|
|
31
|
+
};
|
|
17
32
|
|
|
18
33
|
export class DeviceModeWrapper extends UI.Widget.VBox {
|
|
19
|
-
private readonly inspectedPagePlaceholder: InspectedPagePlaceholder;
|
|
20
|
-
private deviceModeView: DeviceModeView|null;
|
|
21
34
|
private readonly toggleDeviceModeAction: UI.ActionRegistration.Action;
|
|
22
35
|
private showDeviceModeSetting: Common.Settings.Setting<boolean>;
|
|
36
|
+
readonly #view: View;
|
|
23
37
|
|
|
24
|
-
|
|
25
|
-
super();
|
|
26
|
-
this
|
|
27
|
-
this.deviceModeView = null;
|
|
38
|
+
constructor(element?: HTMLElement, view = DEFAULT_VIEW) {
|
|
39
|
+
super(element);
|
|
40
|
+
this.#view = view;
|
|
28
41
|
this.toggleDeviceModeAction = UI.ActionRegistry.ActionRegistry.instance().getAction('emulation.toggle-device-mode');
|
|
29
42
|
const model = EmulationModel.DeviceModeModel.DeviceModeModel.instance();
|
|
30
43
|
this.showDeviceModeSetting = model.enabledSetting();
|
|
31
44
|
this.showDeviceModeSetting.setRequiresUserAction(Boolean(Root.Runtime.Runtime.queryParam('hasOtherClients')));
|
|
32
|
-
this.showDeviceModeSetting.addChangeListener(this.
|
|
33
|
-
SDK.TargetManager.TargetManager.instance().addModelListener(
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
this.
|
|
45
|
+
this.showDeviceModeSetting.addChangeListener(this.requestUpdate.bind(this));
|
|
46
|
+
SDK.TargetManager.TargetManager.instance().addModelListener(SDK.OverlayModel.OverlayModel,
|
|
47
|
+
SDK.OverlayModel.Events.SCREENSHOT_REQUESTED,
|
|
48
|
+
this.screenshotRequestedFromOverlay, this);
|
|
49
|
+
this.requestUpdate();
|
|
37
50
|
}
|
|
38
51
|
|
|
39
|
-
static
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
const {forceNew, inspectedPagePlaceholder} = opts;
|
|
44
|
-
if (!deviceModeWrapperInstance || forceNew) {
|
|
45
|
-
if (!inspectedPagePlaceholder) {
|
|
46
|
-
throw new Error(
|
|
47
|
-
`Unable to create DeviceModeWrapper: inspectedPagePlaceholder must be provided: ${new Error().stack}`);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
deviceModeWrapperInstance = new DeviceModeWrapper(inspectedPagePlaceholder);
|
|
52
|
+
static #setNonEmulatedAvailableSize(): void {
|
|
53
|
+
const model = EmulationModel.DeviceModeModel.DeviceModeModel.instance();
|
|
54
|
+
if (model.type() !== EmulationModel.DeviceModeModel.Type.None) {
|
|
55
|
+
return;
|
|
51
56
|
}
|
|
52
57
|
|
|
53
|
-
|
|
58
|
+
const zoomFactor = UI.ZoomManager.ZoomManager.instance().zoomFactor();
|
|
59
|
+
const rect = InspectedPagePlaceholder.instance().element.getBoundingClientRect();
|
|
60
|
+
const availableSize =
|
|
61
|
+
new Geometry.Size(Math.max(rect.width * zoomFactor, 1), Math.max(rect.height * zoomFactor, 1));
|
|
62
|
+
model.setAvailableSize(availableSize, availableSize);
|
|
54
63
|
}
|
|
55
64
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
isDeviceModeOn(): boolean {
|
|
61
|
-
return this.showDeviceModeSetting.get();
|
|
62
|
-
}
|
|
65
|
+
static captureScreenshot(fullSize?: boolean, clip?: Protocol.Page.Viewport): boolean {
|
|
66
|
+
const model = EmulationModel.DeviceModeModel.DeviceModeModel.instance();
|
|
63
67
|
|
|
64
|
-
|
|
65
|
-
if (!this.deviceModeView) {
|
|
66
|
-
this.deviceModeView = new DeviceModeView();
|
|
67
|
-
}
|
|
68
|
-
this.deviceModeView.setNonEmulatedAvailableSize(this.inspectedPagePlaceholder.element);
|
|
68
|
+
this.#setNonEmulatedAvailableSize();
|
|
69
69
|
if (fullSize) {
|
|
70
|
-
void
|
|
70
|
+
void model.captureFullSizeScreenshot();
|
|
71
71
|
} else if (clip) {
|
|
72
|
-
void
|
|
72
|
+
void model.captureAreaScreenshot(clip);
|
|
73
73
|
} else {
|
|
74
|
-
void
|
|
74
|
+
void model.captureScreenshot();
|
|
75
75
|
}
|
|
76
76
|
return true;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
private screenshotRequestedFromOverlay(event: Common.EventTarget.EventTargetEvent<Protocol.Page.Viewport>): void {
|
|
80
80
|
const clip = event.data;
|
|
81
|
-
|
|
81
|
+
DeviceModeWrapper.captureScreenshot(false, clip);
|
|
82
82
|
}
|
|
83
83
|
|
|
84
|
-
|
|
84
|
+
override performUpdate(): void {
|
|
85
85
|
this.toggleDeviceModeAction.setToggled(this.showDeviceModeSetting.get());
|
|
86
86
|
|
|
87
|
-
|
|
88
|
-
if (!force && shouldShow === this.deviceModeView?.isShowing()) {
|
|
89
|
-
return;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
if (shouldShow) {
|
|
93
|
-
if (!this.deviceModeView) {
|
|
94
|
-
this.deviceModeView = new DeviceModeView();
|
|
95
|
-
}
|
|
96
|
-
this.deviceModeView.show(this.element);
|
|
97
|
-
this.inspectedPagePlaceholder.clearMinimumSize();
|
|
98
|
-
this.inspectedPagePlaceholder.show(this.deviceModeView.element);
|
|
99
|
-
} else {
|
|
100
|
-
if (this.deviceModeView) {
|
|
101
|
-
this.deviceModeView.exitHingeMode();
|
|
102
|
-
this.deviceModeView.detach();
|
|
103
|
-
}
|
|
104
|
-
this.inspectedPagePlaceholder.restoreMinimumSize();
|
|
105
|
-
this.inspectedPagePlaceholder.show(this.element);
|
|
106
|
-
}
|
|
87
|
+
this.#view({showDeviceMode: this.showDeviceModeSetting.get()}, undefined, this.contentElement);
|
|
107
88
|
}
|
|
108
89
|
}
|
|
109
90
|
|
|
@@ -111,7 +92,7 @@ export class ActionDelegate implements UI.ActionRegistration.ActionDelegate {
|
|
|
111
92
|
handleAction(context: UI.Context.Context, actionId: string): boolean {
|
|
112
93
|
switch (actionId) {
|
|
113
94
|
case 'emulation.capture-screenshot':
|
|
114
|
-
return DeviceModeWrapper.
|
|
95
|
+
return DeviceModeWrapper.captureScreenshot();
|
|
115
96
|
|
|
116
97
|
case 'emulation.capture-node-screenshot': {
|
|
117
98
|
const node = context.flavor(SDK.DOMModel.DOMNode);
|
|
@@ -170,18 +151,20 @@ export class ActionDelegate implements UI.ActionRegistration.ActionDelegate {
|
|
|
170
151
|
clip.y *= zoom;
|
|
171
152
|
clip.width *= zoom;
|
|
172
153
|
clip.height *= zoom;
|
|
173
|
-
DeviceModeWrapper.
|
|
154
|
+
DeviceModeWrapper.captureScreenshot(false, clip);
|
|
174
155
|
}
|
|
175
156
|
void captureClip();
|
|
176
157
|
return true;
|
|
177
158
|
}
|
|
178
159
|
|
|
179
160
|
case 'emulation.capture-full-height-screenshot':
|
|
180
|
-
return DeviceModeWrapper.
|
|
161
|
+
return DeviceModeWrapper.captureScreenshot(true);
|
|
181
162
|
|
|
182
|
-
case 'emulation.toggle-device-mode':
|
|
183
|
-
|
|
163
|
+
case 'emulation.toggle-device-mode': {
|
|
164
|
+
const model = EmulationModel.DeviceModeModel.DeviceModeModel.instance();
|
|
165
|
+
model.toggleDeviceMode();
|
|
184
166
|
return true;
|
|
167
|
+
}
|
|
185
168
|
}
|
|
186
169
|
return false;
|
|
187
170
|
}
|
|
@@ -16,8 +16,8 @@ import mediaQueryInspectorStyles from './mediaQueryInspector.css.js';
|
|
|
16
16
|
|
|
17
17
|
const UIStrings = {
|
|
18
18
|
/**
|
|
19
|
-
* @description A context menu item
|
|
20
|
-
* Takes the user to the source code where this media query
|
|
19
|
+
* @description A context menu item in the media query inspector of the device mode toolbar.
|
|
20
|
+
* Takes the user to the source code where this media query came from.
|
|
21
21
|
*/
|
|
22
22
|
revealInSourceCode: 'Reveal in source code',
|
|
23
23
|
} as const;
|
|
@@ -11,11 +11,11 @@ import type * as Emulation from './emulation.js';
|
|
|
11
11
|
|
|
12
12
|
const UIStrings = {
|
|
13
13
|
/**
|
|
14
|
-
* @description Title of an action in the emulation tool to toggle device mode
|
|
14
|
+
* @description Title of an action in the emulation tool to toggle device mode.
|
|
15
15
|
*/
|
|
16
16
|
toggleDeviceToolbar: 'Toggle device toolbar',
|
|
17
17
|
/**
|
|
18
|
-
* @description Title of an action in the emulation tool to capture screenshot
|
|
18
|
+
* @description Title of an action in the emulation tool to capture screenshot.
|
|
19
19
|
*/
|
|
20
20
|
captureScreenshot: 'Capture screenshot',
|
|
21
21
|
/**
|
|
@@ -25,38 +25,38 @@ const UIStrings = {
|
|
|
25
25
|
captureFullSizeScreenshot: 'Capture full size screenshot',
|
|
26
26
|
/**
|
|
27
27
|
* @description Title of an action in the emulation tool to capture a screenshot of just this node.
|
|
28
|
-
* Node refers to
|
|
28
|
+
* Node refers to an HTML element/node.
|
|
29
29
|
*/
|
|
30
30
|
captureNodeScreenshot: 'Capture node screenshot',
|
|
31
31
|
/**
|
|
32
|
-
* @description Command in the
|
|
33
|
-
* https://
|
|
32
|
+
* @description Command in the device mode toolbar to show media query boundaries in the UI.
|
|
33
|
+
* https://web.dev/learn/design/media-queries
|
|
34
34
|
*/
|
|
35
35
|
showMediaQueries: 'Show media queries',
|
|
36
36
|
/**
|
|
37
|
-
* @description A tag of
|
|
37
|
+
* @description A tag of mobile-related settings that can be searched in the command menu if the
|
|
38
38
|
* user doesn't know the exact name of the tool. Device refers to e.g. phone/tablet.
|
|
39
39
|
*/
|
|
40
40
|
device: 'device',
|
|
41
41
|
/**
|
|
42
|
-
* @description Command in the
|
|
43
|
-
* https://
|
|
42
|
+
* @description Command in the device mode toolbar to hide media query boundaries in the UI.
|
|
43
|
+
* https://web.dev/learn/design/media-queries
|
|
44
44
|
*/
|
|
45
45
|
hideMediaQueries: 'Hide media queries',
|
|
46
46
|
/**
|
|
47
47
|
* @description Command that shows measuring rulers next to the emulated device.
|
|
48
48
|
*/
|
|
49
|
-
showRulers: 'Show rulers in the
|
|
49
|
+
showRulers: 'Show rulers in the device mode toolbar',
|
|
50
50
|
/**
|
|
51
51
|
* @description Command that hides measuring rulers next to the emulated device.
|
|
52
52
|
*/
|
|
53
|
-
hideRulers: 'Hide rulers in the
|
|
53
|
+
hideRulers: 'Hide rulers in the device mode toolbar',
|
|
54
54
|
/**
|
|
55
|
-
* @description Command that shows a frame
|
|
55
|
+
* @description Command that shows a frame around the emulated device.
|
|
56
56
|
*/
|
|
57
57
|
showDeviceFrame: 'Show device frame',
|
|
58
58
|
/**
|
|
59
|
-
* @description Command that hides a frame
|
|
59
|
+
* @description Command that hides a frame around the emulated device.
|
|
60
60
|
*/
|
|
61
61
|
hideDeviceFrame: 'Hide device frame',
|
|
62
62
|
|
|
@@ -274,7 +274,9 @@ export class IssuesPane extends UI.Widget.VBox {
|
|
|
274
274
|
const issueCounter = new IssueCounter.IssueCounter.IssueCounter();
|
|
275
275
|
issueCounter.data = {
|
|
276
276
|
clickHandler: () => {
|
|
277
|
-
|
|
277
|
+
const summary = IssueCounter.IssueCounter.getIssueCountsEnumeration(
|
|
278
|
+
IssuesManager.IssuesManager.IssuesManager.instance(), false);
|
|
279
|
+
UI.ARIAUtils.LiveAnnouncer.alert(summary);
|
|
278
280
|
},
|
|
279
281
|
tooltipCallback: () => {
|
|
280
282
|
const issueEnumeration = IssueCounter.IssueCounter.getIssueCountsEnumeration(
|
|
@@ -10,6 +10,7 @@ import * as SDK from '../../core/sdk/sdk.js';
|
|
|
10
10
|
import * as Protocol from '../../generated/protocol.js';
|
|
11
11
|
import * as EmulationModel from '../../models/emulation/emulation.js';
|
|
12
12
|
import type * as LighthouseModel from '../../models/lighthouse/lighthouse.js';
|
|
13
|
+
import * as UI from '../../ui/legacy/legacy.js';
|
|
13
14
|
import * as Emulation from '../emulation/emulation.js';
|
|
14
15
|
|
|
15
16
|
import type {LighthouseRun as LighthouseRunType, ProtocolService} from './LighthouseProtocolService.js';
|
|
@@ -298,6 +299,11 @@ class LighthouseRun {
|
|
|
298
299
|
emulationModel.enabledSetting().set(true);
|
|
299
300
|
emulationModel.deviceOutlineSetting().set(true);
|
|
300
301
|
|
|
302
|
+
// The emulation model is currently coupled to the UI.
|
|
303
|
+
// We must wait for the device mode view to render so that it can
|
|
304
|
+
// initialize the model with the available spatial constraints.
|
|
305
|
+
await UI.Widget.Widget.allUpdatesComplete;
|
|
306
|
+
|
|
301
307
|
for (const device of EmulationModel.EmulatedDevices.EmulatedDevicesList.instance().standard()) {
|
|
302
308
|
if (device.title === 'Moto G Power') {
|
|
303
309
|
emulationModel.emulate(EmulationModel.DeviceModeModel.Type.Device, device, device.modes[0], 1);
|
|
@@ -13,11 +13,9 @@ import {LinearMemoryHighlightChipList} from './LinearMemoryHighlightChipList.js'
|
|
|
13
13
|
import linearMemoryInspectorStyles from './linearMemoryInspector.css.js';
|
|
14
14
|
import {formatAddress, parseAddress} from './LinearMemoryInspectorUtils.js';
|
|
15
15
|
import {
|
|
16
|
-
|
|
17
|
-
type HistoryNavigationEvent,
|
|
16
|
+
LinearMemoryNavigator,
|
|
18
17
|
Mode,
|
|
19
18
|
Navigation,
|
|
20
|
-
type PageNavigationEvent,
|
|
21
19
|
} from './LinearMemoryNavigator.js';
|
|
22
20
|
import {LinearMemoryValueInterpreter} from './LinearMemoryValueInterpreter.js';
|
|
23
21
|
import type {ByteSelectedEvent, ResizeEvent} from './LinearMemoryViewer.js';
|
|
@@ -117,9 +115,9 @@ export interface ViewInput {
|
|
|
117
115
|
canGoBackInHistory: boolean;
|
|
118
116
|
canGoForwardInHistory: boolean;
|
|
119
117
|
onRefreshRequest: () => void;
|
|
120
|
-
onAddressChange: (
|
|
121
|
-
onNavigatePage: (
|
|
122
|
-
onNavigateHistory: (
|
|
118
|
+
onAddressChange: (address: string, mode: Mode) => void;
|
|
119
|
+
onNavigatePage: (navigation: Navigation) => void;
|
|
120
|
+
onNavigateHistory: (navigation: Navigation) => boolean;
|
|
123
121
|
onJumpToAddress: (address: number) => void;
|
|
124
122
|
onDeleteMemoryHighlight: (info: HighlightInfo) => void;
|
|
125
123
|
onByteSelected: (e: ByteSelectedEvent) => void;
|
|
@@ -148,20 +146,19 @@ export const DEFAULT_VIEW = (input: ViewInput, _output: Record<string, unknown>,
|
|
|
148
146
|
render(html`
|
|
149
147
|
<style>${linearMemoryInspectorStyles}</style>
|
|
150
148
|
<div class="view">
|
|
151
|
-
<devtools-
|
|
152
|
-
|
|
153
|
-
{
|
|
149
|
+
<devtools-widget class="navigator-widget"
|
|
150
|
+
${widget(LinearMemoryNavigator, {
|
|
154
151
|
address: navigatorAddressToShow,
|
|
155
152
|
valid: navigatorAddressIsValid,
|
|
156
153
|
mode: input.currentNavigatorMode,
|
|
157
154
|
error: errorMsg,
|
|
158
155
|
canGoBackInHistory: input.canGoBackInHistory,
|
|
159
156
|
canGoForwardInHistory: input.canGoForwardInHistory,
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
157
|
+
onRefreshRequest: input.onRefreshRequest,
|
|
158
|
+
onAddressChange: input.onAddressChange,
|
|
159
|
+
onNavigatePage: input.onNavigatePage,
|
|
160
|
+
onNavigateHistory: input.onNavigateHistory,
|
|
161
|
+
})}></devtools-widget>
|
|
165
162
|
${widget(LinearMemoryHighlightChipList, {
|
|
166
163
|
highlightInfos: highlightedMemoryAreas,
|
|
167
164
|
focusedMemoryHighlight,
|
|
@@ -403,8 +400,7 @@ export class LinearMemoryInspector extends Common.ObjectWrapper.eventMixin<Event
|
|
|
403
400
|
void this.requestUpdate();
|
|
404
401
|
}
|
|
405
402
|
|
|
406
|
-
#onAddressChange(
|
|
407
|
-
const {address, mode} = e.data;
|
|
403
|
+
#onAddressChange(address: string, mode: Mode): void {
|
|
408
404
|
const isValid = isValidAddress(address, this.#outerMemoryLength);
|
|
409
405
|
const newAddress = parseAddress(address);
|
|
410
406
|
this.#currentNavigatorAddressLine = address;
|
|
@@ -444,13 +440,13 @@ export class LinearMemoryInspector extends Common.ObjectWrapper.eventMixin<Event
|
|
|
444
440
|
void this.requestUpdate();
|
|
445
441
|
}
|
|
446
442
|
|
|
447
|
-
#navigateHistory(
|
|
448
|
-
return
|
|
443
|
+
#navigateHistory(navigation: Navigation): boolean {
|
|
444
|
+
return navigation === Navigation.FORWARD ? this.#history.rollover() : this.#history.rollback();
|
|
449
445
|
}
|
|
450
446
|
|
|
451
|
-
#navigatePage(
|
|
452
|
-
const newAddress =
|
|
453
|
-
|
|
447
|
+
#navigatePage(navigation: Navigation): void {
|
|
448
|
+
const newAddress = navigation === Navigation.FORWARD ? this.#address + this.#numBytesPerPage :
|
|
449
|
+
this.#address - this.#numBytesPerPage;
|
|
454
450
|
const addressInRange = Math.max(0, Math.min(newAddress, this.#outerMemoryLength - 1));
|
|
455
451
|
this.#jumpToAddress(addressInRange);
|
|
456
452
|
}
|