chrome-devtools-frontend 1.0.1512349 → 1.0.1513662
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/docs/cookbook/release_management.md +15 -13
- package/docs/get_the_code.md +114 -35
- package/front_end/core/common/Color.ts +40 -44
- package/front_end/core/common/Console.ts +4 -4
- package/front_end/core/common/ParsedURL.ts +14 -14
- package/front_end/core/common/ResourceType.ts +20 -20
- package/front_end/core/common/SegmentedRange.ts +13 -14
- package/front_end/core/common/Settings.ts +4 -4
- package/front_end/core/common/StringOutputStream.ts +4 -4
- package/front_end/core/host/GdpClient.ts +38 -0
- package/front_end/core/host/InspectorFrontendHost.ts +4 -1
- package/front_end/core/host/InspectorFrontendHostAPI.ts +2 -0
- package/front_end/core/host/ResourceLoader.ts +2 -2
- package/front_end/core/host/UserMetrics.ts +0 -2
- package/front_end/core/protocol_client/InspectorBackend.ts +9 -9
- package/front_end/core/root/Runtime.ts +5 -2
- package/front_end/core/sdk/AccessibilityModel.ts +48 -48
- package/front_end/core/sdk/AnimationModel.ts +78 -79
- package/front_end/core/sdk/CPUProfilerModel.ts +5 -5
- package/front_end/core/sdk/CPUThrottlingManager.ts +17 -17
- package/front_end/core/sdk/CSSMatchedStyles.ts +44 -44
- package/front_end/core/sdk/CSSMedia.ts +22 -22
- package/front_end/core/sdk/CSSModel.ts +4 -4
- package/front_end/core/sdk/CSSProperty.ts +9 -9
- package/front_end/core/sdk/CSSPropertyParser.ts +1 -2
- package/front_end/core/sdk/CSSRule.ts +3 -3
- package/front_end/core/sdk/CSSStyleDeclaration.ts +27 -28
- package/front_end/core/sdk/CSSStyleSheetHeader.ts +13 -13
- package/front_end/core/sdk/CategorizedBreakpoint.ts +4 -4
- package/front_end/core/sdk/ChildTargetManager.ts +6 -6
- package/front_end/core/sdk/CompilerSourceMappingContentProvider.ts +4 -4
- package/front_end/core/sdk/ConsoleModel.ts +24 -24
- package/front_end/core/sdk/Cookie.ts +16 -16
- package/front_end/core/sdk/CookieParser.ts +6 -6
- package/front_end/core/sdk/DOMDebuggerModel.ts +88 -89
- package/front_end/core/sdk/DOMModel.ts +113 -113
- package/front_end/core/sdk/DebuggerModel.ts +102 -103
- package/front_end/core/sdk/EmulationModel.ts +6 -6
- package/front_end/core/sdk/EventBreakpointsModel.ts +5 -5
- package/front_end/core/sdk/HeapProfilerModel.ts +5 -5
- package/front_end/core/sdk/IsolateManager.ts +26 -26
- package/front_end/core/sdk/LayerTreeBase.ts +29 -30
- package/front_end/core/sdk/OverlayModel.ts +6 -6
- package/front_end/core/sdk/Resource.ts +43 -43
- package/front_end/core/sdk/ResourceTreeModel.ts +58 -61
- package/front_end/core/sdk/RuntimeModel.ts +12 -13
- package/front_end/core/sdk/SDKModel.ts +3 -3
- package/front_end/core/sdk/Script.ts +17 -17
- package/front_end/core/sdk/SecurityOriginManager.ts +14 -14
- package/front_end/core/sdk/ServerTiming.ts +2 -2
- package/front_end/core/sdk/ServiceWorkerCacheModel.ts +15 -15
- package/front_end/core/sdk/ServiceWorkerManager.ts +19 -24
- package/front_end/core/sdk/SourceMap.ts +10 -10
- package/front_end/core/sdk/StorageKeyManager.ts +12 -12
- package/front_end/core/sdk/Target.ts +33 -34
- package/front_end/core/sdk/TargetManager.ts +20 -20
- package/front_end/entrypoints/formatter_worker/AcornTokenizer.ts +8 -8
- package/front_end/entrypoints/formatter_worker/HTMLFormatter.ts +7 -7
- package/front_end/entrypoints/heap_snapshot_worker/AllocationProfile.ts +7 -7
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +24 -24
- package/front_end/entrypoints/main/GlobalAiButton.ts +3 -3
- package/front_end/entrypoints/main/MainImpl.ts +16 -14
- package/front_end/entrypoints/main/main-meta.ts +1 -2
- package/front_end/generated/InspectorBackendCommands.js +3 -2
- package/front_end/generated/SupportedCSSProperties.js +20 -0
- package/front_end/generated/protocol-mapping.d.ts +4 -0
- package/front_end/generated/protocol-proxy-api.d.ts +5 -0
- package/front_end/generated/protocol.ts +20 -0
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +15 -16
- package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.snapshot.txt +127 -0
- package/front_end/models/ai_assistance/data_formatters/PerformanceInsightFormatter.ts +149 -26
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.snapshot.txt +6 -0
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +9 -10
- package/front_end/models/badges/AiExplorerBadge.ts +21 -0
- package/front_end/models/badges/Badge.ts +3 -5
- package/front_end/models/badges/CodeWhispererBadge.ts +21 -0
- package/front_end/models/badges/DOMDetectiveBadge.ts +4 -3
- package/front_end/models/badges/SpeedsterBadge.ts +6 -4
- package/front_end/models/badges/StarterBadge.ts +4 -3
- package/front_end/models/badges/UserBadges.ts +29 -3
- package/front_end/models/bindings/CSSWorkspaceBinding.ts +6 -6
- package/front_end/models/bindings/DebuggerLanguagePlugins.ts +18 -18
- package/front_end/models/bindings/FileUtils.ts +15 -15
- package/front_end/models/bindings/ResourceScriptMapping.ts +14 -14
- package/front_end/models/elements/ElementUpdateRecord.ts +11 -11
- package/front_end/models/emulation/DeviceModeModel.ts +123 -131
- package/front_end/models/emulation/EmulatedDevices.ts +22 -22
- package/front_end/models/extensions/ExtensionPanel.ts +24 -24
- package/front_end/models/extensions/ExtensionServer.ts +4 -4
- package/front_end/models/javascript_metadata/NativeFunctions.js +14 -2
- package/front_end/models/persistence/IsolatedFileSystem.ts +18 -19
- package/front_end/models/persistence/IsolatedFileSystemManager.ts +13 -13
- package/front_end/models/trace/EventsSerializer.ts +5 -5
- package/front_end/models/trace/LanternComputationData.ts +10 -10
- package/front_end/models/trace/ModelImpl.ts +32 -41
- package/front_end/models/trace/Processor.ts +28 -30
- package/front_end/models/trace/extras/FilmStrip.ts +6 -6
- package/front_end/models/trace/extras/StackTraceForEvent.ts +22 -25
- package/front_end/models/trace/extras/ThirdParties.ts +16 -17
- package/front_end/models/trace/extras/TraceFilter.ts +1 -1
- package/front_end/models/trace/handlers/Threads.ts +10 -10
- package/front_end/models/trace/handlers/helpers.ts +9 -9
- package/front_end/models/trace/handlers/types.ts +3 -3
- package/front_end/models/trace/insights/CLSCulprits.ts +12 -14
- package/front_end/models/trace/insights/Cache.ts +8 -4
- package/front_end/models/trace/insights/DOMSize.ts +8 -5
- package/front_end/models/trace/insights/DocumentLatency.ts +2 -2
- package/front_end/models/trace/insights/DuplicatedJavaScript.ts +3 -3
- package/front_end/models/trace/insights/FontDisplay.ts +3 -4
- package/front_end/models/trace/insights/ForcedReflow.ts +3 -3
- package/front_end/models/trace/insights/INPBreakdown.ts +2 -2
- package/front_end/models/trace/insights/ImageDelivery.ts +11 -11
- package/front_end/models/trace/insights/LCPBreakdown.ts +4 -4
- package/front_end/models/trace/insights/LCPDiscovery.ts +4 -4
- package/front_end/models/trace/insights/LegacyJavaScript.ts +2 -2
- package/front_end/models/trace/insights/ModernHTTP.ts +4 -5
- package/front_end/models/trace/insights/NetworkDependencyTree.ts +12 -12
- package/front_end/models/trace/insights/RenderBlocking.ts +9 -10
- package/front_end/models/trace/insights/SlowCSSSelector.ts +2 -2
- package/front_end/models/trace/insights/ThirdParties.ts +4 -5
- package/front_end/models/trace/insights/Viewport.ts +8 -5
- package/front_end/models/trace/insights/types.ts +1 -0
- package/front_end/models/trace/lantern/testing/MetricTestUtils.ts +10 -10
- package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +52 -52
- package/front_end/panels/accessibility/AccessibilitySidebarView.ts +8 -8
- package/front_end/panels/animation/AnimationTimeline.ts +5 -5
- package/front_end/panels/animation/AnimationUI.ts +22 -23
- package/front_end/panels/application/ApplicationPanelSidebar.ts +12 -12
- package/front_end/panels/application/DOMStorageModel.ts +23 -23
- package/front_end/panels/application/ExtensionStorageModel.ts +31 -31
- package/front_end/panels/application/IndexedDBModel.ts +1 -0
- package/front_end/panels/application/PreloadingTreeElement.ts +8 -8
- package/front_end/panels/application/ServiceWorkersView.ts +0 -53
- package/front_end/panels/application/preloading/components/PreloadingDisabledInfobar.ts +2 -2
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +2 -2
- package/front_end/panels/common/BadgeNotification.ts +24 -4
- package/front_end/panels/common/GdpSignUpDialog.ts +5 -0
- package/front_end/panels/common/badgeNotification.css +26 -9
- package/front_end/panels/console/ConsoleContextSelector.ts +9 -9
- package/front_end/panels/console/ConsolePrompt.ts +8 -5
- package/front_end/panels/console/ConsoleView.ts +13 -13
- package/front_end/panels/console/ConsoleViewport.ts +29 -29
- package/front_end/panels/coverage/CoverageModel.ts +22 -22
- package/front_end/panels/elements/ClassesPaneWidget.ts +1 -1
- package/front_end/panels/elements/ComputedStyleModel.ts +17 -18
- package/front_end/panels/elements/DOMPath.ts +2 -2
- package/front_end/panels/elements/ElementsPanel.ts +13 -13
- package/front_end/panels/elements/ElementsTreeElement.ts +18 -18
- package/front_end/panels/elements/ElementsTreeOutline.ts +41 -48
- package/front_end/panels/elements/ShortcutTreeElement.ts +4 -4
- package/front_end/panels/elements/StylePropertiesSection.ts +4 -4
- package/front_end/panels/elements/StylePropertyTreeElement.ts +49 -50
- package/front_end/panels/elements/StylesSidebarPane.ts +19 -19
- package/front_end/panels/emulation/DeviceModeToolbar.ts +7 -7
- package/front_end/panels/emulation/DeviceModeView.ts +6 -6
- package/front_end/panels/emulation/MediaQueryInspector.ts +18 -18
- package/front_end/panels/event_listeners/EventListenersView.ts +13 -14
- package/front_end/panels/layer_viewer/LayerTreeOutline.ts +3 -3
- package/front_end/panels/layer_viewer/LayerViewHost.ts +13 -13
- package/front_end/panels/layer_viewer/PaintProfilerView.ts +9 -10
- package/front_end/panels/layer_viewer/TransformController.ts +34 -36
- package/front_end/panels/layers/LayerTreeModel.ts +41 -40
- package/front_end/panels/lighthouse/LighthouseReportSelector.ts +13 -13
- package/front_end/panels/lighthouse/LighthouseStartView.ts +7 -7
- package/front_end/panels/media/PlayerMessagesView.ts +5 -5
- package/front_end/panels/media/TickingFlameChart.ts +24 -24
- package/front_end/panels/media/TickingFlameChartHelpers.ts +32 -32
- package/front_end/panels/network/NetworkItemView.ts +4 -4
- package/front_end/panels/network/NetworkLogViewColumns.ts +29 -29
- package/front_end/panels/network/NetworkPanel.ts +8 -5
- package/front_end/panels/network/ResourceWebSocketFrameView.ts +10 -10
- package/front_end/panels/profiler/HeapDetachedElementsView.ts +3 -3
- package/front_end/panels/profiler/HeapProfileView.ts +1 -1
- package/front_end/panels/profiler/ProfileFlameChartDataProvider.ts +3 -4
- package/front_end/panels/profiler/ProfileHeader.ts +25 -25
- package/front_end/panels/profiler/ProfileLauncherView.ts +5 -6
- package/front_end/panels/recorder/components/ReplaySection.ts +3 -1
- package/front_end/panels/security/OriginTreeElement.ts +8 -8
- package/front_end/panels/security/SecurityPanel.ts +5 -5
- package/front_end/panels/settings/SettingsScreen.ts +18 -12
- package/front_end/panels/settings/components/SyncSection.ts +20 -6
- package/front_end/panels/sources/AiCodeCompletionPlugin.ts +3 -0
- package/front_end/panels/sources/DebuggerPausedMessage.ts +8 -9
- package/front_end/panels/sources/NavigatorView.ts +43 -46
- package/front_end/panels/sources/SourcesPanel.ts +35 -35
- package/front_end/panels/sources/SourcesView.ts +13 -13
- package/front_end/panels/sources/TabbedEditorContainer.ts +19 -22
- package/front_end/panels/sources/UISourceCodeFrame.ts +4 -4
- package/front_end/panels/sources/WatchExpressionsSidebarPane.ts +34 -36
- package/front_end/panels/timeline/AnimationsTrackAppender.ts +3 -3
- package/front_end/panels/timeline/CompatibilityTracksAppender.ts +8 -8
- package/front_end/panels/timeline/CountersGraph.ts +16 -16
- package/front_end/panels/timeline/EntriesFilter.ts +4 -3
- package/front_end/panels/timeline/EventsTimelineTreeView.ts +3 -3
- package/front_end/panels/timeline/GPUTrackAppender.ts +3 -3
- package/front_end/panels/timeline/Initiators.ts +10 -10
- package/front_end/panels/timeline/InteractionsTrackAppender.ts +5 -5
- package/front_end/panels/timeline/LayoutShiftsTrackAppender.ts +7 -7
- package/front_end/panels/timeline/ModificationsManager.ts +8 -15
- package/front_end/panels/timeline/TargetForEvent.ts +2 -2
- package/front_end/panels/timeline/ThirdPartyTreeView.ts +1 -1
- package/front_end/panels/timeline/ThreadAppender.ts +13 -13
- package/front_end/panels/timeline/TimelineDetailsView.ts +6 -14
- package/front_end/panels/timeline/TimelineEventOverview.ts +27 -26
- package/front_end/panels/timeline/TimelineFilters.ts +5 -5
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +54 -53
- package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +34 -34
- package/front_end/panels/timeline/TimelineFlameChartView.ts +18 -31
- package/front_end/panels/timeline/TimelineHistoryManager.ts +17 -18
- package/front_end/panels/timeline/TimelineMiniMap.ts +6 -6
- package/front_end/panels/timeline/TimelinePaintProfilerView.ts +6 -6
- package/front_end/panels/timeline/TimelinePanel.ts +52 -59
- package/front_end/panels/timeline/TimelineSelectorStatsView.ts +7 -5
- package/front_end/panels/timeline/TimelineTreeView.ts +10 -10
- package/front_end/panels/timeline/TimelineUIUtils.ts +43 -43
- package/front_end/panels/timeline/TimingsTrackAppender.ts +12 -12
- package/front_end/panels/timeline/TracingLayerTree.ts +43 -43
- package/front_end/panels/timeline/TrackConfigBanner.ts +6 -6
- package/front_end/panels/timeline/TrackConfiguration.ts +1 -1
- package/front_end/panels/timeline/components/DetailsView.ts +4 -4
- package/front_end/panels/timeline/components/LayoutShiftDetails.ts +12 -21
- package/front_end/panels/timeline/components/LiveMetricsView.ts +2 -1
- package/front_end/panels/timeline/components/NetworkRequestDetails.ts +5 -5
- package/front_end/panels/timeline/components/Sidebar.ts +4 -14
- package/front_end/panels/timeline/components/SidebarInsightsTab.ts +13 -36
- package/front_end/panels/timeline/components/SidebarSingleInsightSet.ts +21 -19
- package/front_end/panels/timeline/components/insights/BaseInsightComponent.ts +1 -1
- package/front_end/panels/timeline/components/insights/Cache.ts +4 -0
- package/front_end/panels/timeline/components/insights/DOMSize.ts +5 -1
- package/front_end/panels/timeline/components/insights/Helpers.ts +19 -0
- package/front_end/panels/timeline/components/insights/NetworkDependencyTree.ts +1 -1
- package/front_end/panels/timeline/components/insights/Viewport.ts +4 -0
- package/front_end/panels/timeline/overlays/OverlaysImpl.ts +1 -1
- package/front_end/panels/timeline/utils/AICallTree.ts +11 -11
- package/front_end/panels/timeline/utils/AIContext.ts +17 -19
- package/front_end/panels/timeline/utils/EntityMapper.ts +6 -5
- package/front_end/panels/timeline/utils/EntryName.ts +2 -2
- package/front_end/panels/timeline/utils/EntryNodes.ts +5 -5
- package/front_end/panels/timeline/utils/EntryStyles.ts +4 -4
- package/front_end/panels/timeline/utils/FreshRecording.ts +3 -3
- package/front_end/panels/timeline/utils/Helpers.ts +0 -18
- package/front_end/panels/timeline/utils/InsightAIContext.ts +6 -6
- package/front_end/panels/timeline/utils/SourceMapsResolver.ts +7 -7
- package/front_end/panels/webauthn/WebauthnPane.ts +1 -0
- 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/angular.js.map +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/legacy.js.map +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/vue.js.map +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.js +1 -1
- package/front_end/third_party/codemirror.next/package.json +1 -1
- package/front_end/third_party/codemirror.next/rebuild.sh +1 -1
- package/front_end/third_party/json5/rebuild.sh +1 -1
- package/front_end/third_party/legacy-javascript/{update.sh → rebuild.sh} +1 -1
- package/front_end/third_party/lit/lib/decorators.d.ts +26 -9
- package/front_end/third_party/lit/lib/decorators.js +5 -5
- package/front_end/third_party/lit/lib/decorators.js.map +1 -1
- package/front_end/third_party/lit/lib/directive.js.map +1 -1
- package/front_end/third_party/lit/lib/directives.js +8 -13
- package/front_end/third_party/lit/lib/directives.js.map +1 -1
- package/front_end/third_party/lit/lib/lit.d.ts +26 -9
- package/front_end/third_party/lit/lib/lit.js +5 -5
- package/front_end/third_party/lit/lib/lit.js.map +1 -1
- package/front_end/third_party/lit/lib/static-html.js +2 -2
- package/front_end/third_party/lit/lib/static-html.js.map +1 -1
- package/front_end/third_party/lit/rebuild.sh +1 -1
- package/front_end/third_party/third-party-web/rebuild.sh +1 -1
- package/front_end/ui/components/dialogs/Dialog.ts +6 -7
- package/front_end/ui/legacy/ActionRegistration.ts +9 -9
- package/front_end/ui/legacy/DockController.ts +18 -18
- package/front_end/ui/legacy/FilterBar.ts +7 -7
- package/front_end/ui/legacy/Fragment.ts +4 -4
- package/front_end/ui/legacy/GlassPane.ts +12 -12
- package/front_end/ui/legacy/InspectorView.ts +5 -15
- package/front_end/ui/legacy/ListControl.ts +27 -27
- package/front_end/ui/legacy/ListWidget.ts +4 -4
- package/front_end/ui/legacy/PopoverHelper.ts +4 -4
- package/front_end/ui/legacy/ShortcutRegistry.ts +17 -17
- package/front_end/ui/legacy/TabbedPane.ts +74 -75
- package/front_end/ui/legacy/TextPrompt.ts +31 -31
- package/front_end/ui/legacy/Toolbar.ts +13 -14
- package/front_end/ui/legacy/ViewManager.ts +30 -31
- package/front_end/ui/legacy/Widget.ts +6 -6
- package/front_end/ui/legacy/XLink.ts +9 -9
- package/front_end/ui/legacy/ZoomManager.ts +9 -9
- package/front_end/ui/legacy/components/color_picker/ContrastDetails.ts +27 -27
- package/front_end/ui/legacy/components/color_picker/ContrastInfo.ts +30 -32
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +15 -15
- package/front_end/ui/legacy/components/data_grid/DataGrid.ts +64 -64
- package/front_end/ui/legacy/components/data_grid/ShowMoreDataGridNode.ts +2 -2
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +10 -11
- package/front_end/ui/legacy/components/perf_ui/ChartViewport.ts +12 -12
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +3 -3
- package/front_end/ui/legacy/components/perf_ui/TimelineGrid.ts +14 -14
- package/front_end/ui/legacy/components/perf_ui/TimelineOverviewPane.ts +8 -8
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +5 -5
- package/front_end/ui/legacy/components/source_frame/ResourceSourceFrame.ts +4 -4
- package/front_end/ui/legacy/theme_support/ThemeSupport.ts +4 -4
- package/front_end/ui/visual_logging/KnownContextValues.ts +2 -2
- package/package.json +1 -1
@@ -50,7 +50,7 @@ export class EmulatedDevice {
|
|
50
50
|
isFoldableScreen: boolean;
|
51
51
|
verticalSpanned: Orientation;
|
52
52
|
horizontalSpanned: Orientation;
|
53
|
-
#
|
53
|
+
#show: Show;
|
54
54
|
#showByDefault: boolean;
|
55
55
|
|
56
56
|
constructor() {
|
@@ -69,7 +69,7 @@ export class EmulatedDevice {
|
|
69
69
|
this.verticalSpanned = {width: 0, height: 0, outlineInsets: null, outlineImage: null, hinge: null};
|
70
70
|
this.horizontalSpanned = {width: 0, height: 0, outlineInsets: null, outlineImage: null, hinge: null};
|
71
71
|
|
72
|
-
this.#
|
72
|
+
this.#show = Show.Default;
|
73
73
|
this.#showByDefault = true;
|
74
74
|
}
|
75
75
|
|
@@ -263,7 +263,7 @@ export class EmulatedDevice {
|
|
263
263
|
if (!Object.values(Show).includes(show)) {
|
264
264
|
throw new Error('Emulated device has wrong show mode: ' + show);
|
265
265
|
}
|
266
|
-
result.#
|
266
|
+
result.#show = show;
|
267
267
|
|
268
268
|
return result;
|
269
269
|
} catch {
|
@@ -364,7 +364,7 @@ export class EmulatedDevice {
|
|
364
364
|
json['show-by-default'] = this.#showByDefault;
|
365
365
|
json['dual-screen'] = this.isDualScreen;
|
366
366
|
json['foldable-screen'] = this.isFoldableScreen;
|
367
|
-
json['show'] = this.#
|
367
|
+
json['show'] = this.#show;
|
368
368
|
|
369
369
|
if (this.userAgentMetadata) {
|
370
370
|
json['user-agent-metadata'] = this.userAgentMetadata;
|
@@ -453,18 +453,18 @@ export class EmulatedDevice {
|
|
453
453
|
}
|
454
454
|
}
|
455
455
|
show(): boolean {
|
456
|
-
if (this.#
|
456
|
+
if (this.#show === Show.Default) {
|
457
457
|
return this.#showByDefault;
|
458
458
|
}
|
459
|
-
return this.#
|
459
|
+
return this.#show === Show.Always;
|
460
460
|
}
|
461
461
|
|
462
462
|
setShow(show: boolean): void {
|
463
|
-
this.#
|
463
|
+
this.#show = show ? Show.Always : Show.Never;
|
464
464
|
}
|
465
465
|
|
466
466
|
copyShowFrom(other: EmulatedDevice): void {
|
467
|
-
this.#
|
467
|
+
this.#show = other.#show;
|
468
468
|
}
|
469
469
|
|
470
470
|
touch(): boolean {
|
@@ -508,20 +508,20 @@ let emulatedDevicesListInstance: EmulatedDevicesList;
|
|
508
508
|
|
509
509
|
export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<EventTypes> {
|
510
510
|
readonly #standardSetting: Common.Settings.Setting<any[]>;
|
511
|
-
#
|
511
|
+
#standard: Set<EmulatedDevice>;
|
512
512
|
readonly #customSetting: Common.Settings.Setting<any[]>;
|
513
|
-
readonly #
|
513
|
+
readonly #custom: Set<EmulatedDevice>;
|
514
514
|
constructor() {
|
515
515
|
super();
|
516
516
|
|
517
517
|
this.#standardSetting = Common.Settings.Settings.instance().createSetting('standard-emulated-device-list', []);
|
518
|
-
this.#
|
519
|
-
this.listFromJSONV1(this.#standardSetting.get(), this.#
|
518
|
+
this.#standard = new Set();
|
519
|
+
this.listFromJSONV1(this.#standardSetting.get(), this.#standard);
|
520
520
|
this.updateStandardDevices();
|
521
521
|
|
522
522
|
this.#customSetting = Common.Settings.Settings.instance().createSetting('custom-emulated-device-list', []);
|
523
|
-
this.#
|
524
|
-
if (!this.listFromJSONV1(this.#customSetting.get(), this.#
|
523
|
+
this.#custom = new Set();
|
524
|
+
if (!this.listFromJSONV1(this.#customSetting.get(), this.#custom)) {
|
525
525
|
this.saveCustomDevices();
|
526
526
|
}
|
527
527
|
}
|
@@ -541,8 +541,8 @@ export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<Even
|
|
541
541
|
devices.add(device);
|
542
542
|
}
|
543
543
|
}
|
544
|
-
this.copyShowValues(this.#
|
545
|
-
this.#
|
544
|
+
this.copyShowValues(this.#standard, devices);
|
545
|
+
this.#standard = devices;
|
546
546
|
this.saveStandardDevices();
|
547
547
|
}
|
548
548
|
|
@@ -571,11 +571,11 @@ export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<Even
|
|
571
571
|
}
|
572
572
|
|
573
573
|
standard(): EmulatedDevice[] {
|
574
|
-
return [...this.#
|
574
|
+
return [...this.#standard];
|
575
575
|
}
|
576
576
|
|
577
577
|
custom(): EmulatedDevice[] {
|
578
|
-
return [...this.#
|
578
|
+
return [...this.#custom];
|
579
579
|
}
|
580
580
|
|
581
581
|
revealCustomSetting(): void {
|
@@ -583,18 +583,18 @@ export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<Even
|
|
583
583
|
}
|
584
584
|
|
585
585
|
addCustomDevice(device: EmulatedDevice): void {
|
586
|
-
this.#
|
586
|
+
this.#custom.add(device);
|
587
587
|
this.saveCustomDevices();
|
588
588
|
}
|
589
589
|
|
590
590
|
removeCustomDevice(device: EmulatedDevice): void {
|
591
|
-
this.#
|
591
|
+
this.#custom.delete(device);
|
592
592
|
this.saveCustomDevices();
|
593
593
|
}
|
594
594
|
|
595
595
|
saveCustomDevices(): void {
|
596
596
|
const json: any[] = [];
|
597
|
-
this.#
|
597
|
+
this.#custom.forEach(device => json.push(device.toJSON()));
|
598
598
|
|
599
599
|
this.#customSetting.set(json);
|
600
600
|
this.dispatchEventToListeners(Events.CUSTOM_DEVICES_UPDATED);
|
@@ -602,7 +602,7 @@ export class EmulatedDevicesList extends Common.ObjectWrapper.ObjectWrapper<Even
|
|
602
602
|
|
603
603
|
saveStandardDevices(): void {
|
604
604
|
const json: any[] = [];
|
605
|
-
this.#
|
605
|
+
this.#standard.forEach(device => json.push(device.toJSON()));
|
606
606
|
|
607
607
|
this.#standardSetting.set(json);
|
608
608
|
this.dispatchEventToListeners(Events.STANDARD_DEVICES_UPDATED);
|
@@ -48,7 +48,7 @@ export class ExtensionPanel extends UI.Panel.Panel implements UI.SearchableView.
|
|
48
48
|
private readonly server: ExtensionServer;
|
49
49
|
private readonly id: string;
|
50
50
|
private readonly panelToolbar: UI.Toolbar.Toolbar;
|
51
|
-
|
51
|
+
readonly #searchableView: UI.SearchableView.SearchableView;
|
52
52
|
|
53
53
|
constructor(server: ExtensionServer, panelName: string, id: string, pageURL: string) {
|
54
54
|
super(panelName);
|
@@ -57,11 +57,11 @@ export class ExtensionPanel extends UI.Panel.Panel implements UI.SearchableView.
|
|
57
57
|
this.setHideOnDetach();
|
58
58
|
this.panelToolbar = this.element.createChild('devtools-toolbar', 'hidden');
|
59
59
|
|
60
|
-
this
|
61
|
-
this.
|
60
|
+
this.#searchableView = new UI.SearchableView.SearchableView(this, null);
|
61
|
+
this.#searchableView.show(this.element);
|
62
62
|
|
63
63
|
const extensionView = new ExtensionView(server, this.id, pageURL, 'extension');
|
64
|
-
extensionView.show(this.
|
64
|
+
extensionView.show(this.#searchableView.element);
|
65
65
|
}
|
66
66
|
|
67
67
|
addToolbarItem(item: UI.Toolbar.ToolbarItem): void {
|
@@ -71,11 +71,11 @@ export class ExtensionPanel extends UI.Panel.Panel implements UI.SearchableView.
|
|
71
71
|
|
72
72
|
onSearchCanceled(): void {
|
73
73
|
this.server.notifySearchAction(this.id, ExtensionAPI.PrivateAPI.Panels.SearchAction.CancelSearch);
|
74
|
-
this.
|
74
|
+
this.#searchableView.updateSearchMatchesCount(0);
|
75
75
|
}
|
76
76
|
|
77
77
|
override searchableView(): UI.SearchableView.SearchableView {
|
78
|
-
return this
|
78
|
+
return this.#searchableView;
|
79
79
|
}
|
80
80
|
|
81
81
|
performSearch(searchConfig: UI.SearchableView.SearchConfig, _shouldJump: boolean, _jumpBackwards?: boolean): void {
|
@@ -102,37 +102,37 @@ export class ExtensionPanel extends UI.Panel.Panel implements UI.SearchableView.
|
|
102
102
|
|
103
103
|
export class ExtensionButton {
|
104
104
|
private readonly id: string;
|
105
|
-
|
105
|
+
readonly #toolbarButton: UI.Toolbar.ToolbarButton;
|
106
106
|
constructor(server: ExtensionServer, id: string, iconURL: string, tooltip?: string, disabled?: boolean) {
|
107
107
|
this.id = id;
|
108
108
|
|
109
|
-
this
|
110
|
-
this.
|
109
|
+
this.#toolbarButton = new UI.Toolbar.ToolbarButton('', '');
|
110
|
+
this.#toolbarButton.addEventListener(
|
111
111
|
UI.Toolbar.ToolbarButton.Events.CLICK, server.notifyButtonClicked.bind(server, this.id));
|
112
112
|
this.update(iconURL, tooltip, disabled);
|
113
113
|
}
|
114
114
|
|
115
115
|
update(iconURL?: string, tooltip?: string, disabled?: boolean): void {
|
116
116
|
if (typeof iconURL === 'string') {
|
117
|
-
this.
|
117
|
+
this.#toolbarButton.setBackgroundImage(iconURL);
|
118
118
|
}
|
119
119
|
if (typeof tooltip === 'string') {
|
120
|
-
this.
|
120
|
+
this.#toolbarButton.setTitle(tooltip);
|
121
121
|
}
|
122
122
|
if (typeof disabled === 'boolean') {
|
123
|
-
this.
|
123
|
+
this.#toolbarButton.setEnabled(!disabled);
|
124
124
|
}
|
125
125
|
}
|
126
126
|
|
127
127
|
toolbarButton(): UI.Toolbar.ToolbarButton {
|
128
|
-
return this
|
128
|
+
return this.#toolbarButton;
|
129
129
|
}
|
130
130
|
}
|
131
131
|
|
132
132
|
export class ExtensionSidebarPane extends UI.View.SimpleView {
|
133
|
-
|
133
|
+
readonly #panelName: string;
|
134
134
|
private server: ExtensionServer;
|
135
|
-
|
135
|
+
#id: string;
|
136
136
|
private extensionView?: ExtensionView;
|
137
137
|
private objectPropertiesView?: ExtensionNotifierView;
|
138
138
|
constructor(server: ExtensionServer, panelName: string, title: Platform.UIString.LocalizedString, id: string) {
|
@@ -141,22 +141,22 @@ export class ExtensionSidebarPane extends UI.View.SimpleView {
|
|
141
141
|
const viewId = Platform.StringUtilities.toKebabCase(title);
|
142
142
|
super({title, viewId});
|
143
143
|
this.element.classList.add('fill');
|
144
|
-
this
|
144
|
+
this.#panelName = panelName;
|
145
145
|
this.server = server;
|
146
|
-
this
|
146
|
+
this.#id = id;
|
147
147
|
}
|
148
148
|
|
149
149
|
id(): string {
|
150
|
-
return this
|
150
|
+
return this.#id;
|
151
151
|
}
|
152
152
|
|
153
153
|
panelName(): string {
|
154
|
-
return this
|
154
|
+
return this.#panelName;
|
155
155
|
}
|
156
156
|
|
157
157
|
setObject(object: Object, title: string|undefined, callback: (arg0?: (string|null)|undefined) => void): void {
|
158
158
|
this.createObjectPropertiesView();
|
159
|
-
this
|
159
|
+
this.#setObject(SDK.RemoteObject.RemoteObject.fromLocalObject(object), title, callback);
|
160
160
|
}
|
161
161
|
|
162
162
|
setExpression(
|
@@ -176,7 +176,7 @@ export class ExtensionSidebarPane extends UI.View.SimpleView {
|
|
176
176
|
this.extensionView.detach(true);
|
177
177
|
}
|
178
178
|
|
179
|
-
this.extensionView = new ExtensionView(this.server, this
|
179
|
+
this.extensionView = new ExtensionView(this.server, this.#id, url, 'extension fill');
|
180
180
|
this.extensionView.show(this.element);
|
181
181
|
|
182
182
|
if (!this.element.style.height) {
|
@@ -196,7 +196,7 @@ export class ExtensionSidebarPane extends UI.View.SimpleView {
|
|
196
196
|
} else if (!result) {
|
197
197
|
callback();
|
198
198
|
} else {
|
199
|
-
this
|
199
|
+
this.#setObject(result, title, callback);
|
200
200
|
}
|
201
201
|
}
|
202
202
|
|
@@ -208,11 +208,11 @@ export class ExtensionSidebarPane extends UI.View.SimpleView {
|
|
208
208
|
this.extensionView.detach(true);
|
209
209
|
delete this.extensionView;
|
210
210
|
}
|
211
|
-
this.objectPropertiesView = new ExtensionNotifierView(this.server, this
|
211
|
+
this.objectPropertiesView = new ExtensionNotifierView(this.server, this.#id);
|
212
212
|
this.objectPropertiesView.show(this.element);
|
213
213
|
}
|
214
214
|
|
215
|
-
|
215
|
+
#setObject(
|
216
216
|
object: SDK.RemoteObject.RemoteObject, title: string|undefined,
|
217
217
|
callback: (arg0?: (string|null)|undefined) => void): void {
|
218
218
|
const objectPropertiesView = this.objectPropertiesView;
|
@@ -165,7 +165,7 @@ export class ExtensionServer extends Common.ObjectWrapper.ObjectWrapper<EventTyp
|
|
165
165
|
private lastRequestId: number;
|
166
166
|
private registeredExtensions: Map<string, RegisteredExtension>;
|
167
167
|
private status: ExtensionStatus;
|
168
|
-
|
168
|
+
readonly #sidebarPanes: ExtensionSidebarPane[];
|
169
169
|
private extensionsEnabled: boolean;
|
170
170
|
private inspectedTabId?: string;
|
171
171
|
private readonly extensionAPITestHook?: (server: unknown, api: unknown) => unknown;
|
@@ -185,7 +185,7 @@ export class ExtensionServer extends Common.ObjectWrapper.ObjectWrapper<EventTyp
|
|
185
185
|
this.lastRequestId = 0;
|
186
186
|
this.registeredExtensions = new Map();
|
187
187
|
this.status = new ExtensionStatus();
|
188
|
-
this
|
188
|
+
this.#sidebarPanes = [];
|
189
189
|
// TODO(caseq): properly unload extensions when we disable them.
|
190
190
|
this.extensionsEnabled = true;
|
191
191
|
|
@@ -726,7 +726,7 @@ export class ExtensionServer extends Common.ObjectWrapper.ObjectWrapper<EventTyp
|
|
726
726
|
}
|
727
727
|
const id = message.id;
|
728
728
|
const sidebar = new ExtensionSidebarPane(this, message.panel, i18n.i18n.lockedString(message.title), id);
|
729
|
-
this.
|
729
|
+
this.#sidebarPanes.push(sidebar);
|
730
730
|
this.clientObjects.set(id, sidebar);
|
731
731
|
this.dispatchEventToListeners(Events.SidebarPaneAdded, sidebar);
|
732
732
|
|
@@ -734,7 +734,7 @@ export class ExtensionServer extends Common.ObjectWrapper.ObjectWrapper<EventTyp
|
|
734
734
|
}
|
735
735
|
|
736
736
|
sidebarPanes(): ExtensionSidebarPane[] {
|
737
|
-
return this
|
737
|
+
return this.#sidebarPanes;
|
738
738
|
}
|
739
739
|
|
740
740
|
private onSetSidebarHeight(message: PrivateAPI.ExtensionServerRequestMessage): Record {
|
@@ -6097,6 +6097,10 @@ export const NativeFunctions = [
|
|
6097
6097
|
name: "DocumentTimeline",
|
6098
6098
|
signatures: [["?options"]]
|
6099
6099
|
},
|
6100
|
+
{
|
6101
|
+
name: "EventTrigger",
|
6102
|
+
signatures: [["?options"]]
|
6103
|
+
},
|
6100
6104
|
{
|
6101
6105
|
name: "KeyframeEffect",
|
6102
6106
|
signatures: [["source"],["target","keyframes","?options"]]
|
@@ -7588,7 +7592,7 @@ export const NativeFunctions = [
|
|
7588
7592
|
signatures: [["element","x","y","?dwidth","?dheight"]]
|
7589
7593
|
},
|
7590
7594
|
{
|
7591
|
-
name: "
|
7595
|
+
name: "drawHTML",
|
7592
7596
|
signatures: [["element","x","y","?dwidth","?dheight"]]
|
7593
7597
|
},
|
7594
7598
|
{
|
@@ -8427,6 +8431,14 @@ export const NativeFunctions = [
|
|
8427
8431
|
name: "RTCSessionDescription",
|
8428
8432
|
signatures: [["?descriptionInitDict"]]
|
8429
8433
|
},
|
8434
|
+
{
|
8435
|
+
name: "RtcTransport",
|
8436
|
+
signatures: [["name"]]
|
8437
|
+
},
|
8438
|
+
{
|
8439
|
+
name: "sendPackets",
|
8440
|
+
signatures: [["packets"]]
|
8441
|
+
},
|
8430
8442
|
{
|
8431
8443
|
name: "revoke",
|
8432
8444
|
signatures: [["permission"]]
|
@@ -8878,7 +8890,7 @@ export const NativeFunctions = [
|
|
8878
8890
|
signatures: [["provokeMode"]]
|
8879
8891
|
},
|
8880
8892
|
{
|
8881
|
-
name: "
|
8893
|
+
name: "texHTML2D",
|
8882
8894
|
signatures: [["target","level","internalformat","format","type","element"]]
|
8883
8895
|
},
|
8884
8896
|
{
|
@@ -74,14 +74,14 @@ const str_ = i18n.i18n.registerUIStrings('models/persistence/IsolatedFileSystem.
|
|
74
74
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
75
75
|
export class IsolatedFileSystem extends PlatformFileSystem {
|
76
76
|
private readonly manager: IsolatedFileSystemManager;
|
77
|
-
|
77
|
+
readonly #embedderPath: Platform.DevToolsPath.RawPathString;
|
78
78
|
private readonly domFileSystem: FileSystem;
|
79
79
|
private readonly excludedFoldersSetting:
|
80
80
|
Common.Settings.Setting<Record<Platform.DevToolsPath.UrlString, Platform.DevToolsPath.EncodedPathString[]>>;
|
81
|
-
|
81
|
+
#excludedFolders: Set<Platform.DevToolsPath.EncodedPathString>;
|
82
82
|
private readonly excludedEmbedderFolders: Platform.DevToolsPath.RawPathString[] = [];
|
83
|
-
|
84
|
-
|
83
|
+
readonly #initialFilePaths = new Set<Platform.DevToolsPath.EncodedPathString>();
|
84
|
+
readonly #initialGitFolders = new Set<Platform.DevToolsPath.EncodedPathString>();
|
85
85
|
private readonly fileLocks = new Map<Platform.DevToolsPath.EncodedPathString, Promise<unknown>>();
|
86
86
|
|
87
87
|
constructor(
|
@@ -90,11 +90,11 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
90
90
|
automatic: boolean) {
|
91
91
|
super(path, type, automatic);
|
92
92
|
this.manager = manager;
|
93
|
-
this
|
93
|
+
this.#embedderPath = embedderPath;
|
94
94
|
this.domFileSystem = domFileSystem;
|
95
95
|
this.excludedFoldersSetting =
|
96
96
|
Common.Settings.Settings.instance().createLocalSetting('workspace-excluded-folders', {});
|
97
|
-
this
|
97
|
+
this.#excludedFolders = new Set(this.excludedFoldersSetting.get()[path] || []);
|
98
98
|
}
|
99
99
|
|
100
100
|
static async create(
|
@@ -142,15 +142,15 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
142
142
|
}
|
143
143
|
|
144
144
|
override initialFilePaths(): Platform.DevToolsPath.EncodedPathString[] {
|
145
|
-
return [...this
|
145
|
+
return [...this.#initialFilePaths];
|
146
146
|
}
|
147
147
|
|
148
148
|
override initialGitFolders(): Platform.DevToolsPath.EncodedPathString[] {
|
149
|
-
return [...this
|
149
|
+
return [...this.#initialGitFolders];
|
150
150
|
}
|
151
151
|
|
152
152
|
override embedderPath(): Platform.DevToolsPath.RawPathString {
|
153
|
-
return this
|
153
|
+
return this.#embedderPath;
|
154
154
|
}
|
155
155
|
|
156
156
|
private initializeFilePaths(): Promise<void> {
|
@@ -167,14 +167,14 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
167
167
|
entry.fullPath as Platform.DevToolsPath.RawPathString))) {
|
168
168
|
continue;
|
169
169
|
}
|
170
|
-
this.
|
170
|
+
this.#initialFilePaths.add(Common.ParsedURL.ParsedURL.rawPathToEncodedPathString(
|
171
171
|
Common.ParsedURL.ParsedURL.substr(entry.fullPath as Platform.DevToolsPath.RawPathString, 1)));
|
172
172
|
} else {
|
173
173
|
if (entry.fullPath.endsWith('/.git')) {
|
174
174
|
const lastSlash = entry.fullPath.lastIndexOf('/');
|
175
175
|
const parentFolder = Common.ParsedURL.ParsedURL.substr(
|
176
176
|
entry.fullPath as Platform.DevToolsPath.RawPathString, 1, lastSlash);
|
177
|
-
this.
|
177
|
+
this.#initialGitFolders.add(Common.ParsedURL.ParsedURL.rawPathToEncodedPathString(parentFolder));
|
178
178
|
}
|
179
179
|
if (this.isFileExcluded(Common.ParsedURL.ParsedURL.concatenate(
|
180
180
|
Common.ParsedURL.ParsedURL.rawPathToEncodedPathString(
|
@@ -502,18 +502,18 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
502
502
|
|
503
503
|
private saveExcludedFolders(): void {
|
504
504
|
const settingValue = this.excludedFoldersSetting.get();
|
505
|
-
settingValue[this.path()] = [...this
|
505
|
+
settingValue[this.path()] = [...this.#excludedFolders];
|
506
506
|
this.excludedFoldersSetting.set(settingValue);
|
507
507
|
}
|
508
508
|
|
509
509
|
override addExcludedFolder(path: Platform.DevToolsPath.EncodedPathString): void {
|
510
|
-
this.
|
510
|
+
this.#excludedFolders.add(path);
|
511
511
|
this.saveExcludedFolders();
|
512
512
|
this.manager.dispatchEventToListeners(Events.ExcludedFolderAdded, path);
|
513
513
|
}
|
514
514
|
|
515
515
|
override removeExcludedFolder(path: Platform.DevToolsPath.EncodedPathString): void {
|
516
|
-
this.
|
516
|
+
this.#excludedFolders.delete(path);
|
517
517
|
this.saveExcludedFolders();
|
518
518
|
this.manager.dispatchEventToListeners(Events.ExcludedFolderRemoved, path);
|
519
519
|
}
|
@@ -525,7 +525,7 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
525
525
|
}
|
526
526
|
|
527
527
|
override isFileExcluded(folderPath: Platform.DevToolsPath.EncodedPathString): boolean {
|
528
|
-
if (this.
|
528
|
+
if (this.#excludedFolders.has(folderPath)) {
|
529
529
|
return true;
|
530
530
|
}
|
531
531
|
const regex = (this.manager.workspaceFolderExcludePatternSetting()).asRegExp();
|
@@ -533,14 +533,13 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
533
533
|
}
|
534
534
|
|
535
535
|
override excludedFolders(): Set<Platform.DevToolsPath.EncodedPathString> {
|
536
|
-
return this
|
536
|
+
return this.#excludedFolders;
|
537
537
|
}
|
538
538
|
|
539
539
|
override searchInPath(query: string, progress: Common.Progress.Progress): Promise<string[]> {
|
540
540
|
return new Promise(resolve => {
|
541
541
|
const requestId = this.manager.registerCallback(innerCallback);
|
542
|
-
Host.InspectorFrontendHost.InspectorFrontendHostInstance.searchInPath(
|
543
|
-
requestId, this.embedderPathInternal, query);
|
542
|
+
Host.InspectorFrontendHost.InspectorFrontendHostInstance.searchInPath(requestId, this.#embedderPath, query);
|
544
543
|
|
545
544
|
function innerCallback(files: Platform.DevToolsPath.RawPathString[]): void {
|
546
545
|
resolve(files.map(path => Common.ParsedURL.ParsedURL.rawPathToUrlString(path)));
|
@@ -553,7 +552,7 @@ export class IsolatedFileSystem extends PlatformFileSystem {
|
|
553
552
|
progress.setTotalWork(1);
|
554
553
|
const requestId = this.manager.registerProgress(progress);
|
555
554
|
Host.InspectorFrontendHost.InspectorFrontendHostInstance.indexPath(
|
556
|
-
requestId, this
|
555
|
+
requestId, this.#embedderPath, JSON.stringify(this.excludedEmbedderFolders));
|
557
556
|
}
|
558
557
|
|
559
558
|
override mimeFromPath(path: Platform.DevToolsPath.UrlString): string {
|
@@ -53,16 +53,16 @@ const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
53
53
|
let isolatedFileSystemManagerInstance: IsolatedFileSystemManager|null;
|
54
54
|
|
55
55
|
export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrapper<EventTypes> {
|
56
|
-
|
56
|
+
readonly #fileSystems: Map<Platform.DevToolsPath.UrlString, PlatformFileSystem>;
|
57
57
|
private readonly callbacks: Map<number, (arg0: Platform.DevToolsPath.RawPathString[]) => void>;
|
58
58
|
private readonly progresses: Map<number, Common.Progress.Progress>;
|
59
|
-
|
59
|
+
readonly #workspaceFolderExcludePatternSetting: Common.Settings.RegExpSetting;
|
60
60
|
private fileSystemRequestResolve: ((arg0: IsolatedFileSystem|null) => void)|null;
|
61
61
|
private readonly fileSystemsLoadedPromise: Promise<IsolatedFileSystem[]>;
|
62
62
|
private constructor() {
|
63
63
|
super();
|
64
64
|
|
65
|
-
this
|
65
|
+
this.#fileSystems = new Map();
|
66
66
|
this.callbacks = new Map();
|
67
67
|
this.progresses = new Map();
|
68
68
|
|
@@ -116,7 +116,7 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
116
116
|
defaultExcludedFolders = defaultExcludedFolders.concat(defaultLinuxExcludedFolders);
|
117
117
|
}
|
118
118
|
const defaultExcludedFoldersPattern = defaultExcludedFolders.join('|');
|
119
|
-
this
|
119
|
+
this.#workspaceFolderExcludePatternSetting = Common.Settings.Settings.instance().createRegExpSetting(
|
120
120
|
'workspace-folder-exclude-pattern', defaultExcludedFoldersPattern, Host.Platform.isWin() ? 'i' : '');
|
121
121
|
|
122
122
|
this.fileSystemRequestResolve = null;
|
@@ -194,7 +194,7 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
194
194
|
if (!fileSystem) {
|
195
195
|
return null;
|
196
196
|
}
|
197
|
-
this.
|
197
|
+
this.#fileSystems.set(fileSystemURL, fileSystem);
|
198
198
|
fileSystem.addEventListener(PlatformFileSystemEvents.FILE_SYSTEM_ERROR, this.#onFileSystemError, this);
|
199
199
|
if (dispatchEvent) {
|
200
200
|
this.dispatchEventToListeners(Events.FileSystemAdded, fileSystem);
|
@@ -204,7 +204,7 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
204
204
|
}
|
205
205
|
|
206
206
|
addPlatformFileSystem(fileSystemURL: Platform.DevToolsPath.UrlString, fileSystem: PlatformFileSystem): void {
|
207
|
-
this.
|
207
|
+
this.#fileSystems.set(fileSystemURL, fileSystem);
|
208
208
|
fileSystem.addEventListener(PlatformFileSystemEvents.FILE_SYSTEM_ERROR, this.#onFileSystemError, this);
|
209
209
|
this.dispatchEventToListeners(Events.FileSystemAdded, fileSystem);
|
210
210
|
}
|
@@ -238,11 +238,11 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
238
238
|
private onFileSystemRemoved(event: Common.EventTarget.EventTargetEvent<Platform.DevToolsPath.RawPathString>): void {
|
239
239
|
const embedderPath = event.data;
|
240
240
|
const fileSystemPath = Common.ParsedURL.ParsedURL.rawPathToUrlString(embedderPath);
|
241
|
-
const isolatedFileSystem = this.
|
241
|
+
const isolatedFileSystem = this.#fileSystems.get(fileSystemPath);
|
242
242
|
if (!isolatedFileSystem) {
|
243
243
|
return;
|
244
244
|
}
|
245
|
-
this.
|
245
|
+
this.#fileSystems.delete(fileSystemPath);
|
246
246
|
isolatedFileSystem.removeEventListener(PlatformFileSystemEvents.FILE_SYSTEM_ERROR, this.#onFileSystemError, this);
|
247
247
|
isolatedFileSystem.fileSystemRemoved();
|
248
248
|
this.dispatchEventToListeners(Events.FileSystemRemoved, isolatedFileSystem);
|
@@ -265,8 +265,8 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
265
265
|
new Platform.MapUtilities.Multimap<Platform.DevToolsPath.UrlString, Platform.DevToolsPath.UrlString>();
|
266
266
|
for (const embedderPath of embedderPaths) {
|
267
267
|
const filePath = Common.ParsedURL.ParsedURL.rawPathToUrlString(embedderPath);
|
268
|
-
for (const fileSystemPath of this.
|
269
|
-
const fileSystem = this.
|
268
|
+
for (const fileSystemPath of this.#fileSystems.keys()) {
|
269
|
+
const fileSystem = this.#fileSystems.get(fileSystemPath);
|
270
270
|
if (fileSystem?.isFileExcluded(Common.ParsedURL.ParsedURL.rawPathToEncodedPathString(embedderPath))) {
|
271
271
|
continue;
|
272
272
|
}
|
@@ -282,15 +282,15 @@ export class IsolatedFileSystemManager extends Common.ObjectWrapper.ObjectWrappe
|
|
282
282
|
}
|
283
283
|
|
284
284
|
fileSystems(): PlatformFileSystem[] {
|
285
|
-
return [...this.
|
285
|
+
return [...this.#fileSystems.values()];
|
286
286
|
}
|
287
287
|
|
288
288
|
fileSystem(fileSystemPath: Platform.DevToolsPath.UrlString): PlatformFileSystem|null {
|
289
|
-
return this.
|
289
|
+
return this.#fileSystems.get(fileSystemPath) || null;
|
290
290
|
}
|
291
291
|
|
292
292
|
workspaceFolderExcludePatternSetting(): Common.Settings.RegExpSetting {
|
293
|
-
return this
|
293
|
+
return this.#workspaceFolderExcludePatternSetting;
|
294
294
|
}
|
295
295
|
|
296
296
|
registerCallback(callback: (arg0: Platform.DevToolsPath.RawPathString[]) => void): number {
|
@@ -2,8 +2,8 @@
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
3
3
|
// found in the LICENSE file.
|
4
4
|
|
5
|
-
import type * as Handlers from './handlers/handlers.js';
|
6
5
|
import * as Helpers from './helpers/helpers.js';
|
6
|
+
import type {ParsedTrace} from './ModelImpl.js';
|
7
7
|
import * as Types from './types/types.js';
|
8
8
|
|
9
9
|
export class EventsSerializer {
|
@@ -29,7 +29,7 @@ export class EventsSerializer {
|
|
29
29
|
return key;
|
30
30
|
}
|
31
31
|
|
32
|
-
eventForKey(key: Types.File.SerializableKey, parsedTrace:
|
32
|
+
eventForKey(key: Types.File.SerializableKey, parsedTrace: ParsedTrace): Types.Events.Event {
|
33
33
|
const eventValues = Types.File.traceEventKeyToValues(key);
|
34
34
|
|
35
35
|
if (EventsSerializer.isProfileCallKey(eventValues)) {
|
@@ -37,7 +37,7 @@ export class EventsSerializer {
|
|
37
37
|
}
|
38
38
|
|
39
39
|
if (EventsSerializer.isLegacyTimelineFrameKey(eventValues)) {
|
40
|
-
const event = parsedTrace.Frames.frames.at(eventValues.rawIndex);
|
40
|
+
const event = parsedTrace.data.Frames.frames.at(eventValues.rawIndex);
|
41
41
|
if (!event) {
|
42
42
|
throw new Error(`Could not find frame with index ${eventValues.rawIndex}`);
|
43
43
|
}
|
@@ -75,14 +75,14 @@ export class EventsSerializer {
|
|
75
75
|
return key.type === Types.File.EventKeyType.SYNTHETIC_EVENT;
|
76
76
|
}
|
77
77
|
|
78
|
-
#getModifiedProfileCallByKeyValues(key: Types.File.ProfileCallKeyValues, parsedTrace:
|
78
|
+
#getModifiedProfileCallByKeyValues(key: Types.File.ProfileCallKeyValues, parsedTrace: ParsedTrace):
|
79
79
|
Types.Events.SyntheticProfileCall {
|
80
80
|
const cacheResult = this.#modifiedProfileCallByKey.get(key);
|
81
81
|
if (cacheResult) {
|
82
82
|
return cacheResult;
|
83
83
|
}
|
84
84
|
const profileCallsInThread =
|
85
|
-
parsedTrace.Renderer.processes.get(key.processID)?.threads.get(key.threadID)?.profileCalls;
|
85
|
+
parsedTrace.data.Renderer.processes.get(key.processID)?.threads.get(key.threadID)?.profileCalls;
|
86
86
|
if (!profileCallsInThread) {
|
87
87
|
throw new Error(`Unknown profile call serializable key: ${(key)}`);
|
88
88
|
}
|