chrome-devtools-frontend 1.0.950971 → 1.0.952403
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/config/gni/devtools_grd_files.gni +6 -3
- package/extension-api/ExtensionAPI.d.ts +1 -1
- package/front_end/.eslintrc.js +6 -0
- package/front_end/Tests.js +10 -0
- package/front_end/core/common/App.ts +0 -3
- package/front_end/core/common/AppProvider.ts +0 -3
- package/front_end/core/common/JavaScriptMetaData.ts +0 -3
- package/front_end/core/common/QueryParamHandler.ts +0 -3
- package/front_end/core/common/Runnable.ts +0 -3
- package/front_end/core/common/SimpleHistoryManager.ts +0 -3
- package/front_end/core/host/UserMetrics.ts +2 -1
- package/front_end/core/i18n/locales/en-US.json +186 -183
- package/front_end/core/i18n/locales/en-XL.json +186 -183
- package/front_end/core/root/Runtime.ts +4 -12
- package/front_end/core/sdk/CSSRule.ts +1 -1
- package/front_end/core/sdk/DOMModel.ts +12 -37
- package/front_end/core/sdk/OverlayModel.ts +18 -34
- package/front_end/core/sdk/OverlayPersistentHighlighter.ts +0 -12
- package/front_end/core/sdk/PageResourceLoader.ts +2 -1
- package/front_end/core/sdk/RuntimeModel.ts +0 -1
- package/front_end/core/sdk/SourceMap.ts +1 -1
- package/front_end/core/sdk/TracingManager.ts +0 -3
- package/front_end/entrypoints/formatter_worker/AcornTokenizer.ts +39 -39
- package/front_end/entrypoints/formatter_worker/CSSFormatter.ts +54 -54
- package/front_end/entrypoints/formatter_worker/ESTreeWalker.ts +20 -20
- package/front_end/entrypoints/formatter_worker/FormattedContentBuilder.ts +54 -54
- package/front_end/entrypoints/formatter_worker/HTMLFormatter.ts +145 -144
- package/front_end/entrypoints/formatter_worker/JavaScriptFormatter.ts +40 -40
- package/front_end/entrypoints/heap_snapshot_worker/AllocationProfile.ts +65 -70
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +203 -204
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotLoader.ts +109 -108
- package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotWorkerDispatcher.ts +18 -18
- package/front_end/entrypoints/inspector_main/InspectorMain.ts +30 -30
- package/front_end/entrypoints/inspector_main/RenderingOptions.ts +25 -25
- package/front_end/entrypoints/main/ExecutionContextSelector.ts +52 -55
- package/front_end/entrypoints/main/MainImpl.ts +49 -49
- package/front_end/entrypoints/node_app/NodeConnectionsPanel.ts +43 -43
- package/front_end/entrypoints/node_app/NodeMain.ts +38 -38
- package/front_end/generated/InspectorBackendCommands.js +5 -1
- package/front_end/generated/protocol.d.ts +16 -0
- package/front_end/legacy/legacy-defs.d.ts +0 -21
- package/front_end/models/bindings/CSSWorkspaceBinding.ts +0 -3
- package/front_end/models/bindings/DebuggerLanguagePlugins.ts +1 -2
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +1 -4
- package/front_end/models/bindings/FileUtils.ts +0 -4
- package/front_end/models/bindings/IgnoreListManager.ts +1 -2
- package/front_end/models/bindings/NetworkProject.ts +1 -2
- package/front_end/models/extensions/ExtensionAPI.ts +2 -2
- package/front_end/models/extensions/ExtensionTraceProvider.ts +0 -3
- package/front_end/models/heap_snapshot_model/HeapSnapshotModel.ts +1 -1
- package/front_end/models/issues_manager/ClientHintIssue.ts +95 -0
- package/front_end/models/issues_manager/ContentSecurityPolicyIssue.ts +6 -6
- package/front_end/models/issues_manager/ContrastCheckTrigger.ts +15 -15
- package/front_end/models/issues_manager/CorsIssue.ts +9 -9
- package/front_end/models/issues_manager/CrossOriginEmbedderPolicyIssue.ts +5 -5
- package/front_end/models/issues_manager/DeprecationIssue.ts +7 -7
- package/front_end/models/issues_manager/GenericIssue.ts +5 -5
- package/front_end/models/issues_manager/HeavyAdIssue.ts +5 -5
- package/front_end/models/issues_manager/Issue.ts +10 -10
- package/front_end/models/issues_manager/IssueResolver.ts +11 -10
- package/front_end/models/issues_manager/IssuesManager.ts +61 -56
- package/front_end/models/issues_manager/LowTextContrastIssue.ts +4 -4
- package/front_end/models/issues_manager/MixedContentIssue.ts +7 -7
- package/front_end/models/issues_manager/NavigatorUserAgentIssue.ts +7 -7
- package/front_end/models/issues_manager/QuirksModeIssue.ts +4 -4
- package/front_end/models/issues_manager/SameSiteCookieIssue.ts +17 -18
- package/front_end/models/issues_manager/SharedArrayBufferIssue.ts +5 -5
- package/front_end/models/issues_manager/SourceFrameIssuesManager.ts +32 -31
- package/front_end/models/issues_manager/TrustedWebActivityIssue.ts +5 -5
- package/front_end/models/issues_manager/WasmCrossOriginModuleSharingIssue.ts +5 -5
- package/front_end/models/issues_manager/descriptions/clientHintMetaTagAllowListInvalidOrigin.md +4 -0
- package/front_end/models/issues_manager/descriptions/clientHintMetaTagModifiedHTML.md +4 -0
- package/front_end/models/issues_manager/issues_manager.ts +2 -0
- package/front_end/models/timeline_model/TimelineModel.ts +1 -1
- package/front_end/models/timeline_model/TracingLayerTree.ts +0 -1
- package/front_end/panels/accessibility/ARIAMetadata.ts +0 -1
- package/front_end/panels/accessibility/AXBreadcrumbsPane.ts +2 -2
- package/front_end/panels/accessibility/AccessibilityNodeView.ts +1 -2
- package/front_end/panels/animation/AnimationTimeline.ts +0 -1
- package/front_end/panels/application/ApplicationPanelCacheSection.ts +3 -4
- package/front_end/panels/application/ServiceWorkerUpdateCycleView.ts +0 -2
- package/front_end/panels/application/StorageView.ts +2 -6
- package/front_end/panels/application/{BackForwardCacheStrings.ts → components/BackForwardCacheStrings.ts} +2 -2
- package/front_end/panels/application/{BackForwardCacheView.ts → components/BackForwardCacheView.ts} +96 -62
- package/front_end/panels/application/components/EndpointsGrid.ts +12 -12
- package/front_end/panels/application/components/FrameDetailsView.ts +108 -110
- package/front_end/panels/application/components/OriginTrialTreeView.ts +45 -45
- package/front_end/panels/application/components/PermissionsPolicySection.ts +19 -19
- package/front_end/panels/application/components/ReportsGrid.ts +30 -30
- package/front_end/panels/application/components/StackTrace.ts +48 -47
- package/front_end/panels/application/components/TrustTokensView.ts +31 -31
- package/front_end/panels/application/{backForwardCacheView.css → components/backForwardCacheView.css} +9 -0
- package/front_end/panels/application/components/components.ts +2 -0
- package/front_end/panels/console/ConsoleView.ts +1 -1
- package/front_end/panels/console/ConsoleViewMessage.ts +1 -25
- package/front_end/panels/console/consoleView.css +5 -0
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +41 -52
- package/front_end/panels/css_overview/CSSOverviewController.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewPanel.ts +18 -27
- package/front_end/panels/css_overview/CSSOverviewProcessingView.ts +2 -2
- package/front_end/panels/css_overview/CSSOverviewSidebarPanel.ts +6 -6
- package/front_end/panels/css_overview/components/CSSOverviewStartView.ts +4 -4
- package/front_end/panels/elements/ComputedStyleModel.ts +2 -2
- package/front_end/panels/elements/ElementsPanel.ts +1 -5
- package/front_end/panels/elements/ElementsTreeElement.ts +2 -6
- package/front_end/panels/elements/ElementsTreeOutline.ts +2 -2
- package/front_end/panels/elements/StylesSidebarPane.ts +1 -1
- package/front_end/panels/elements/components/AccessibilityTreeNode.ts +17 -17
- package/front_end/panels/elements/components/AdornerManager.ts +21 -21
- package/front_end/panels/elements/components/AdornerSettingsPane.ts +14 -14
- package/front_end/panels/elements/components/CSSQuery.ts +16 -16
- package/front_end/panels/elements/components/ComputedStyleProperty.ts +14 -14
- package/front_end/panels/elements/components/ComputedStyleTrace.ts +15 -15
- package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +78 -78
- package/front_end/panels/elements/components/ElementsPanelLink.ts +16 -16
- package/front_end/panels/elements/components/LayoutPane.ts +47 -47
- package/front_end/panels/elements/components/NodeText.ts +18 -18
- package/front_end/panels/elements/components/QueryContainer.ts +40 -40
- package/front_end/panels/elements/components/StylePropertyEditor.ts +18 -18
- package/front_end/panels/emulation/components/DeviceSizeInputElement.ts +4 -4
- package/front_end/panels/event_listeners/EventListenersUtils.ts +2 -1
- package/front_end/panels/issues/AffectedBlockedByResponseView.ts +4 -4
- package/front_end/panels/issues/AffectedCookiesView.ts +4 -5
- package/front_end/panels/issues/AffectedDirectivesView.ts +19 -19
- package/front_end/panels/issues/AffectedDocumentsInQuirksModeView.ts +7 -8
- package/front_end/panels/issues/AffectedElementsView.ts +4 -4
- package/front_end/panels/issues/AffectedElementsWithLowContrastView.ts +7 -8
- package/front_end/panels/issues/AffectedHeavyAdView.ts +8 -8
- package/front_end/panels/issues/AffectedResourcesView.ts +25 -26
- package/front_end/panels/issues/AffectedSharedArrayBufferIssueDetailsView.ts +8 -8
- package/front_end/panels/issues/AffectedSourcesView.ts +4 -4
- package/front_end/panels/issues/AffectedTrustedWebActivityIssueDetailsView.ts +4 -4
- package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +17 -17
- package/front_end/panels/issues/CSPViolationsListView.ts +22 -23
- package/front_end/panels/issues/CSPViolationsView.ts +17 -17
- package/front_end/panels/issues/ComboBoxOfCheckBoxes.ts +13 -13
- package/front_end/panels/issues/CorsIssueDetailsView.ts +23 -23
- package/front_end/panels/issues/GenericIssueDetailsView.ts +4 -4
- package/front_end/panels/issues/HiddenIssuesRow.ts +7 -7
- package/front_end/panels/issues/IssueAggregator.ts +95 -95
- package/front_end/panels/issues/IssueKindView.ts +14 -14
- package/front_end/panels/issues/IssueView.ts +98 -98
- package/front_end/panels/issues/IssuesPane.ts +102 -102
- package/front_end/panels/issues/WasmCrossOriginModuleSharingAffectedResourcesView.ts +5 -5
- package/front_end/panels/issues/components/HideIssuesMenu.ts +10 -10
- package/front_end/panels/layer_viewer/Layers3DView.ts +3 -9
- package/front_end/panels/lighthouse/LighthouseController.ts +4 -5
- package/front_end/panels/media/PlayerListView.ts +160 -97
- package/front_end/panels/media/PlayerMessagesView.ts +1 -0
- package/front_end/panels/media/TickingFlameChart.ts +1 -2
- package/front_end/panels/media/playerListView.css +58 -0
- package/front_end/panels/network/NetworkLogView.ts +2 -6
- package/front_end/panels/network/NetworkLogViewColumns.ts +1 -1
- package/front_end/panels/network/NetworkWaterfallColumn.ts +2 -4
- package/front_end/panels/network/components/RequestTrustTokensView.ts +40 -40
- package/front_end/panels/network/components/WebBundleInfoView.ts +9 -9
- package/front_end/panels/performance_monitor/PerformanceMonitor.ts +92 -37
- package/front_end/panels/performance_monitor/performanceMonitor.css +32 -0
- package/front_end/panels/profiler/HeapProfileView.ts +1 -1
- package/front_end/panels/profiler/HeapSnapshotDataGrids.ts +0 -1
- package/front_end/panels/profiler/HeapSnapshotView.ts +1 -2
- package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +2 -2
- package/front_end/panels/search/SearchConfig.ts +0 -6
- package/front_end/panels/security/SecurityModel.ts +2 -4
- package/front_end/panels/security/SecurityPanel.ts +2 -2
- package/front_end/panels/settings/KeybindsSettingsTab.ts +4 -0
- package/front_end/panels/settings/components/SyncSection.ts +14 -14
- package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +96 -96
- package/front_end/panels/sources/BreakpointEditDialog.ts +4 -3
- package/front_end/panels/sources/FilteredUISourceCodeListProvider.ts +2 -2
- package/front_end/panels/sources/NavigatorView.ts +4 -10
- package/front_end/panels/sources/ScopeChainSidebarPane.ts +2 -3
- package/front_end/panels/sources/SourceMapNamesResolver.ts +3 -3
- package/front_end/panels/sources/SourcesPanel.ts +1 -3
- package/front_end/panels/sources/SourcesView.ts +0 -3
- package/front_end/panels/sources/TabbedEditorContainer.ts +1 -4
- package/front_end/panels/timeline/TimelineFlameChartDataProvider.ts +2 -5
- package/front_end/panels/timeline/TimelineFlameChartNetworkDataProvider.ts +0 -1
- package/front_end/panels/timeline/TimelineFlameChartView.ts +1 -2
- package/front_end/panels/timeline/TimelineLoader.ts +0 -3
- package/front_end/panels/timeline/TimelinePanel.ts +2 -3
- package/front_end/panels/timeline/TimelineTreeView.ts +1 -1
- package/front_end/panels/timeline/TimelineUIUtils.ts +1 -1
- package/front_end/panels/timeline/components/WebVitalsLane.ts +77 -76
- package/front_end/panels/timeline/components/WebVitalsTimeline.ts +133 -133
- package/front_end/panels/timeline/components/WebVitalsTooltip.ts +9 -9
- package/front_end/panels/webauthn/WebauthnPane.ts +203 -205
- package/front_end/third_party/codemirror.next/bundle.ts +3 -3
- package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
- package/front_end/third_party/codemirror.next/chunk/markdown.js +2 -1
- package/front_end/third_party/codemirror.next/codemirror.next.d.ts +10 -1
- package/front_end/third_party/codemirror.next/codemirror.next.js +2 -1
- package/front_end/third_party/codemirror.next/package.json +3 -3
- package/front_end/third_party/diff/DiffWrapper.ts +7 -0
- package/front_end/third_party/puppeteer/package/README.md +11 -11
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/api-docs-entry.d.ts +4 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/AriaQueryHandler.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/AriaQueryHandler.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Browser.d.ts +4 -6
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/BrowserConnector.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Connection.d.ts +1 -4
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Coverage.d.ts +1 -4
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.d.ts +9 -7
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.js +21 -12
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/DOMWorld.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Dialog.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/EvalTypes.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/ExecutionContext.d.ts +3 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FileChooser.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.d.ts +8 -10
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.js +3 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/FrameManager.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.d.ts +50 -11
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.js +70 -33
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPRequest.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.d.ts +12 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.js +25 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/HTTPResponse.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Input.d.ts +2 -4
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.d.ts +39 -6
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.js +36 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/JSHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.d.ts +3 -4
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.js +2 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/LifecycleWatcher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.d.ts +46 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.d.ts.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.js +124 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkEventManager.js.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.d.ts +27 -10
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.js +144 -74
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/NetworkManager.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Puppeteer.d.ts +5 -6
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/QueryHandler.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/Target.d.ts +4 -6
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/common/WebWorker.d.ts +3 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.d.ts +4 -5
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.js +43 -17
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/BrowserRunner.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/LaunchOptions.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.js +101 -34
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Launcher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/NodeWebSocketTransport.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/PipeTransport.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/node/Puppeteer.d.ts +5 -7
- package/front_end/third_party/puppeteer/package/lib/cjs/puppeteer/revisions.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/api-docs-entry.d.ts +4 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/AriaQueryHandler.js +2 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/AriaQueryHandler.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Browser.d.ts +4 -6
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Browser.js +2 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/BrowserConnector.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/BrowserConnector.js +3 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Connection.d.ts +1 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Coverage.d.ts +1 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Coverage.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.d.ts +9 -7
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.js +24 -17
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/DOMWorld.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Dialog.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/EvalTypes.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/ExecutionContext.d.ts +3 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FileChooser.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.d.ts +8 -10
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.js +7 -8
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/FrameManager.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.d.ts +50 -11
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.js +70 -34
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPRequest.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.d.ts +12 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.js +26 -7
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/HTTPResponse.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Input.d.ts +2 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.d.ts +39 -6
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.js +38 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/JSHandle.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.d.ts +3 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.js +4 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/LifecycleWatcher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.d.ts +46 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.d.ts.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.js +120 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkEventManager.js.map +1 -0
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.d.ts +27 -10
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.js +144 -75
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/NetworkManager.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Page.js +12 -14
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Puppeteer.d.ts +5 -6
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Puppeteer.js +3 -4
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/QueryHandler.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/Target.d.ts +4 -6
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/WebWorker.d.ts +3 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/WebWorker.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/common/helper.js +3 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/initialize-node.js +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserFetcher.js +10 -12
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.d.ts +4 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.js +43 -20
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/BrowserRunner.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/LaunchOptions.d.ts +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.d.ts.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.js +104 -40
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Launcher.js.map +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/NodeWebSocketTransport.d.ts +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.d.ts +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/PipeTransport.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Puppeteer.d.ts +5 -7
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/Puppeteer.js +1 -3
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node/install.js +3 -5
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node-puppeteer-core.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/node.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/revisions.js +1 -1
- package/front_end/third_party/puppeteer/package/lib/esm/puppeteer/web.js +1 -2
- package/front_end/third_party/puppeteer/package/lib/types.d.ts +173 -36
- package/front_end/third_party/puppeteer/package/package.json +3 -3
- package/front_end/ui/components/adorners/Adorner.ts +2 -2
- package/front_end/ui/components/buttons/Button.ts +9 -9
- package/front_end/ui/components/data_grid/DataGrid.ts +64 -64
- package/front_end/ui/components/data_grid/DataGridController.ts +22 -22
- package/front_end/ui/components/data_grid/DataGridUtils.ts +3 -0
- package/front_end/ui/components/diff_view/DiffView.ts +6 -6
- package/front_end/ui/components/expandable_list/ExpandableList.ts +5 -5
- package/front_end/ui/components/icon_button/Icon.ts +4 -4
- package/front_end/ui/components/icon_button/IconButton.ts +4 -4
- package/front_end/ui/components/issue_counter/IssueCounter.ts +3 -3
- package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +11 -11
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspector.ts +50 -50
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorController.ts +6 -6
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorPane.ts +4 -4
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryNavigator.ts +12 -12
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryValueInterpreter.ts +11 -11
- package/front_end/ui/components/linear_memory_inspector/LinearMemoryViewer.ts +40 -39
- package/front_end/ui/components/linear_memory_inspector/ValueInterpreterDisplay.ts +18 -18
- package/front_end/ui/components/linear_memory_inspector/ValueInterpreterSettings.ts +6 -6
- package/front_end/ui/components/linkifier/LinkifierImpl.ts +4 -4
- package/front_end/ui/components/markdown_view/MarkdownImage.ts +5 -5
- package/front_end/ui/components/markdown_view/MarkdownLink.ts +2 -2
- package/front_end/ui/components/markdown_view/MarkdownView.ts +4 -5
- package/front_end/ui/components/panel_feedback/FeedbackButton.ts +2 -2
- package/front_end/ui/components/panel_feedback/PanelFeedback.ts +2 -2
- package/front_end/ui/components/panel_feedback/PreviewToggle.ts +4 -4
- package/front_end/ui/components/render_coordinator/RenderCoordinator.ts +22 -22
- package/front_end/ui/components/report_view/ReportView.ts +16 -16
- package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +14 -14
- package/front_end/ui/components/settings/SettingCheckbox.ts +5 -5
- package/front_end/ui/components/survey_link/SurveyLink.ts +8 -8
- package/front_end/ui/components/text_editor/TextEditor.ts +9 -9
- package/front_end/ui/components/text_editor/cursor_tooltip.ts +7 -1
- package/front_end/ui/components/text_prompt/TextPrompt.ts +18 -18
- package/front_end/ui/components/tree_outline/TreeOutline.ts +69 -70
- package/front_end/ui/legacy/ContextFlavorListener.ts +0 -4
- package/front_end/ui/legacy/ContextMenu.ts +2 -3
- package/front_end/ui/legacy/InspectorView.ts +1 -1
- package/front_end/ui/legacy/ReportView.ts +3 -4
- package/front_end/ui/legacy/SearchableView.ts +14 -6
- package/front_end/ui/legacy/SplitWidget.ts +2 -3
- package/front_end/ui/legacy/SuggestBox.ts +0 -3
- package/front_end/ui/legacy/TextPrompt.ts +1 -1
- package/front_end/ui/legacy/UIUtils.ts +1 -1
- package/front_end/ui/legacy/XLink.ts +1 -1
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +2 -2
- package/front_end/ui/legacy/components/data_grid/DataGrid.ts +9 -9
- package/front_end/ui/legacy/components/data_grid/dataGrid.css +7 -7
- package/front_end/ui/legacy/components/inline_editor/CSSShadowEditor.ts +1 -1
- package/front_end/ui/legacy/components/perf_ui/FlameChart.ts +1 -5
- package/front_end/ui/legacy/components/source_frame/JSONView.ts +1 -1
- package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +13 -13
- package/front_end/ui/legacy/components/source_frame/XMLView.ts +2 -2
- package/front_end/ui/legacy/components/utils/Linkifier.ts +2 -2
- package/front_end/ui/legacy/themeColors.css +2 -0
- package/front_end/ui/legacy/theme_support/theme_support_impl.ts +42 -4
- package/package.json +1 -1
- package/scripts/eslint_rules/lib/use_private_class_members.js +41 -0
- package/scripts/eslint_rules/tests/use_private_class_members_test.js +62 -0
- package/scripts/migration/class-fields/migrate.js +2 -3
- package/scripts/migration/class-fields/migrate.sh +1 -3
- package/scripts/migration/class-fields/package.json +1 -1
- package/config/gni/all_devtools_files.gni +0 -255
- package/scripts/build/devtools_file_hashes.py +0 -82
- package/scripts/devtools_run/devtools_run_cli +0 -49
- package/scripts/devtools_run/package.json +0 -13
- package/scripts/unzip.py +0 -20
- package/scripts/visualize_deps/jquery_svg.html +0 -57
- package/scripts/visualize_deps/run_visualize.js +0 -119
|
@@ -62,27 +62,27 @@ export interface CreateRequestCellOptions {
|
|
|
62
62
|
* as well as machinery for resolving request and frame ids to SDK objects.
|
|
63
63
|
*/
|
|
64
64
|
export abstract class AffectedResourcesView extends UI.TreeOutline.TreeElement {
|
|
65
|
-
|
|
65
|
+
readonly #parentView: IssueView;
|
|
66
66
|
protected issue: AggregatedIssue;
|
|
67
67
|
protected affectedResourcesCountElement: HTMLElement;
|
|
68
68
|
protected affectedResources: HTMLElement;
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
69
|
+
#affectedResourcesCount: number;
|
|
70
|
+
#frameListeners: Common.EventTarget.EventDescriptor[];
|
|
71
|
+
#unresolvedFrameIds: Set<string>;
|
|
72
72
|
protected requestResolver: Logs.RequestResolver.RequestResolver;
|
|
73
73
|
|
|
74
74
|
constructor(parent: IssueView, issue: AggregatedIssue) {
|
|
75
75
|
super();
|
|
76
|
-
this
|
|
76
|
+
this.#parentView = parent;
|
|
77
77
|
this.issue = issue;
|
|
78
78
|
this.toggleOnClick = true;
|
|
79
79
|
this.affectedResourcesCountElement = this.createAffectedResourcesCounter();
|
|
80
80
|
|
|
81
81
|
this.affectedResources = this.createAffectedResources();
|
|
82
|
-
this
|
|
82
|
+
this.#affectedResourcesCount = 0;
|
|
83
83
|
this.requestResolver = new Logs.RequestResolver.RequestResolver();
|
|
84
|
-
this
|
|
85
|
-
this
|
|
84
|
+
this.#frameListeners = [];
|
|
85
|
+
this.#unresolvedFrameIds = new Set();
|
|
86
86
|
}
|
|
87
87
|
|
|
88
88
|
/**
|
|
@@ -113,14 +113,14 @@ export abstract class AffectedResourcesView extends UI.TreeOutline.TreeElement {
|
|
|
113
113
|
protected abstract getResourceNameWithCount(count: number): string;
|
|
114
114
|
|
|
115
115
|
protected updateAffectedResourceCount(count: number): void {
|
|
116
|
-
this
|
|
116
|
+
this.#affectedResourcesCount = count;
|
|
117
117
|
this.affectedResourcesCountElement.textContent = this.getResourceNameWithCount(count);
|
|
118
|
-
this.hidden = this
|
|
119
|
-
this
|
|
118
|
+
this.hidden = this.#affectedResourcesCount === 0;
|
|
119
|
+
this.#parentView.updateAffectedResourceVisibility();
|
|
120
120
|
}
|
|
121
121
|
|
|
122
122
|
isEmpty(): boolean {
|
|
123
|
-
return this
|
|
123
|
+
return this.#affectedResourcesCount === 0;
|
|
124
124
|
}
|
|
125
125
|
|
|
126
126
|
clear(): void {
|
|
@@ -129,7 +129,7 @@ export abstract class AffectedResourcesView extends UI.TreeOutline.TreeElement {
|
|
|
129
129
|
}
|
|
130
130
|
|
|
131
131
|
expandIfOneResource(): void {
|
|
132
|
-
if (this
|
|
132
|
+
if (this.#affectedResourcesCount === 1) {
|
|
133
133
|
this.expand();
|
|
134
134
|
}
|
|
135
135
|
}
|
|
@@ -139,32 +139,31 @@ export abstract class AffectedResourcesView extends UI.TreeOutline.TreeElement {
|
|
|
139
139
|
* a listener is installed that takes care of updating the view if the frame is added. This is useful if the issue is
|
|
140
140
|
* added before the frame gets reported.
|
|
141
141
|
*/
|
|
142
|
-
|
|
142
|
+
#resolveFrameId(frameId: Protocol.Page.FrameId): SDK.ResourceTreeModel.ResourceTreeFrame|null {
|
|
143
143
|
const frame = SDK.FrameManager.FrameManager.instance().getFrame(frameId);
|
|
144
144
|
if (!frame || !frame.url) {
|
|
145
|
-
this
|
|
146
|
-
if (!this
|
|
145
|
+
this.#unresolvedFrameIds.add(frameId);
|
|
146
|
+
if (!this.#frameListeners.length) {
|
|
147
147
|
const addListener = SDK.FrameManager.FrameManager.instance().addEventListener(
|
|
148
|
-
SDK.FrameManager.Events.FrameAddedToTarget, this
|
|
148
|
+
SDK.FrameManager.Events.FrameAddedToTarget, this.#onFrameChanged, this);
|
|
149
149
|
const navigateListener = SDK.FrameManager.FrameManager.instance().addEventListener(
|
|
150
|
-
SDK.FrameManager.Events.FrameNavigated, this
|
|
151
|
-
this
|
|
150
|
+
SDK.FrameManager.Events.FrameNavigated, this.#onFrameChanged, this);
|
|
151
|
+
this.#frameListeners = [addListener, navigateListener];
|
|
152
152
|
}
|
|
153
153
|
}
|
|
154
154
|
return frame;
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
|
|
158
|
-
void {
|
|
157
|
+
#onFrameChanged(event: Common.EventTarget.EventTargetEvent<{frame: SDK.ResourceTreeModel.ResourceTreeFrame}>): void {
|
|
159
158
|
const frame = event.data.frame;
|
|
160
159
|
if (!frame.url) {
|
|
161
160
|
return;
|
|
162
161
|
}
|
|
163
|
-
const frameWasUnresolved = this
|
|
164
|
-
if (this
|
|
162
|
+
const frameWasUnresolved = this.#unresolvedFrameIds.delete(frame.id);
|
|
163
|
+
if (this.#unresolvedFrameIds.size === 0 && this.#frameListeners.length) {
|
|
165
164
|
// Stop listening once all requests are resolved.
|
|
166
|
-
Common.EventTarget.removeEventListeners(this
|
|
167
|
-
this
|
|
165
|
+
Common.EventTarget.removeEventListeners(this.#frameListeners);
|
|
166
|
+
this.#frameListeners = [];
|
|
168
167
|
}
|
|
169
168
|
if (frameWasUnresolved) {
|
|
170
169
|
this.update();
|
|
@@ -173,7 +172,7 @@ export abstract class AffectedResourcesView extends UI.TreeOutline.TreeElement {
|
|
|
173
172
|
|
|
174
173
|
protected createFrameCell(frameId: Protocol.Page.FrameId, issueCategory: IssuesManager.Issue.IssueCategory):
|
|
175
174
|
HTMLElement {
|
|
176
|
-
const frame = this
|
|
175
|
+
const frame = this.#resolveFrameId(frameId);
|
|
177
176
|
const url = frame && (frame.unreachableUrl() || frame.url) || i18nString(UIStrings.unknown);
|
|
178
177
|
|
|
179
178
|
const frameCell = document.createElement('td');
|
|
@@ -58,7 +58,7 @@ export class AffectedSharedArrayBufferIssueDetailsView extends AffectedResources
|
|
|
58
58
|
return i18nString(UIStrings.nViolations, {n: count});
|
|
59
59
|
}
|
|
60
60
|
|
|
61
|
-
|
|
61
|
+
#appendStatus(element: HTMLElement, isWarning: boolean): void {
|
|
62
62
|
const status = document.createElement('td');
|
|
63
63
|
if (isWarning) {
|
|
64
64
|
status.classList.add('affected-resource-report-only-status');
|
|
@@ -70,7 +70,7 @@ export class AffectedSharedArrayBufferIssueDetailsView extends AffectedResources
|
|
|
70
70
|
element.appendChild(status);
|
|
71
71
|
}
|
|
72
72
|
|
|
73
|
-
|
|
73
|
+
#appendType(element: HTMLElement, type: Protocol.Audits.SharedArrayBufferIssueType): void {
|
|
74
74
|
const status = document.createElement('td');
|
|
75
75
|
switch (type) {
|
|
76
76
|
case Protocol.Audits.SharedArrayBufferIssueType.CreationIssue:
|
|
@@ -85,7 +85,7 @@ export class AffectedSharedArrayBufferIssueDetailsView extends AffectedResources
|
|
|
85
85
|
element.appendChild(status);
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
#appendDetails(sabIssues: Iterable<IssuesManager.SharedArrayBufferIssue.SharedArrayBufferIssue>): void {
|
|
89
89
|
const header = document.createElement('tr');
|
|
90
90
|
this.appendColumnTitle(header, i18nString(UIStrings.sourceLocation));
|
|
91
91
|
this.appendColumnTitle(header, i18nString(UIStrings.trigger));
|
|
@@ -95,26 +95,26 @@ export class AffectedSharedArrayBufferIssueDetailsView extends AffectedResources
|
|
|
95
95
|
let count = 0;
|
|
96
96
|
for (const sabIssue of sabIssues) {
|
|
97
97
|
count++;
|
|
98
|
-
this
|
|
98
|
+
this.#appendDetail(sabIssue);
|
|
99
99
|
}
|
|
100
100
|
this.updateAffectedResourceCount(count);
|
|
101
101
|
}
|
|
102
102
|
|
|
103
|
-
|
|
103
|
+
#appendDetail(sabIssue: IssuesManager.SharedArrayBufferIssue.SharedArrayBufferIssue): void {
|
|
104
104
|
const element = document.createElement('tr');
|
|
105
105
|
element.classList.add('affected-resource-directive');
|
|
106
106
|
|
|
107
107
|
const sabIssueDetails = sabIssue.details();
|
|
108
108
|
const location = IssuesManager.Issue.toZeroBasedLocation(sabIssueDetails.sourceCodeLocation);
|
|
109
109
|
this.appendSourceLocation(element, location, sabIssue.model()?.getTargetIfNotDisposed());
|
|
110
|
-
this
|
|
111
|
-
this
|
|
110
|
+
this.#appendType(element, sabIssueDetails.type);
|
|
111
|
+
this.#appendStatus(element, sabIssueDetails.isWarning);
|
|
112
112
|
|
|
113
113
|
this.affectedResources.appendChild(element);
|
|
114
114
|
}
|
|
115
115
|
|
|
116
116
|
update(): void {
|
|
117
117
|
this.clear();
|
|
118
|
-
this
|
|
118
|
+
this.#appendDetails(this.issue.getSharedArrayBufferIssues());
|
|
119
119
|
}
|
|
120
120
|
}
|
|
@@ -19,10 +19,10 @@ const str_ = i18n.i18n.registerUIStrings('panels/issues/AffectedSourcesView.ts',
|
|
|
19
19
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
20
20
|
|
|
21
21
|
export class AffectedSourcesView extends AffectedResourcesView {
|
|
22
|
-
|
|
22
|
+
#appendAffectedSources(affectedSources: Iterable<Protocol.Audits.SourceCodeLocation>): void {
|
|
23
23
|
let count = 0;
|
|
24
24
|
for (const source of affectedSources) {
|
|
25
|
-
this
|
|
25
|
+
this.#appendAffectedSource(source);
|
|
26
26
|
count++;
|
|
27
27
|
}
|
|
28
28
|
this.updateAffectedResourceCount(count);
|
|
@@ -32,7 +32,7 @@ export class AffectedSourcesView extends AffectedResourcesView {
|
|
|
32
32
|
return i18nString(UIStrings.nSources, {n: count});
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
#appendAffectedSource({url, lineNumber, columnNumber}: Protocol.Audits.SourceCodeLocation): void {
|
|
36
36
|
const cellElement = document.createElement('td');
|
|
37
37
|
// TODO(chromium:1072331): Check feasibility of plumping through scriptId for `linkifyScriptLocation`
|
|
38
38
|
// to support source maps and formatted scripts.
|
|
@@ -52,6 +52,6 @@ export class AffectedSourcesView extends AffectedResourcesView {
|
|
|
52
52
|
|
|
53
53
|
update(): void {
|
|
54
54
|
this.clear();
|
|
55
|
-
this
|
|
55
|
+
this.#appendAffectedSources(this.issue.sources());
|
|
56
56
|
}
|
|
57
57
|
}
|
|
@@ -37,7 +37,7 @@ export class AffectedTrustedWebActivityIssueDetailsView extends AffectedResource
|
|
|
37
37
|
return i18nString(UIStrings.nResources, {n: count});
|
|
38
38
|
}
|
|
39
39
|
|
|
40
|
-
|
|
40
|
+
#appendDetail(twaIssue: IssuesManager.TrustedWebActivityIssue.TrustedWebActivityIssue): void {
|
|
41
41
|
const element = document.createElement('tr');
|
|
42
42
|
element.classList.add('affected-resource-row');
|
|
43
43
|
|
|
@@ -56,7 +56,7 @@ export class AffectedTrustedWebActivityIssueDetailsView extends AffectedResource
|
|
|
56
56
|
this.affectedResources.appendChild(element);
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
#appendDetails(twaIssues: Iterable<IssuesManager.TrustedWebActivityIssue.TrustedWebActivityIssue>): void {
|
|
60
60
|
const header = document.createElement('tr');
|
|
61
61
|
if (this.issue.code() === IssuesManager.TrustedWebActivityIssue.httpViolationCode) {
|
|
62
62
|
this.appendColumnTitle(header, i18nString(UIStrings.statusCode));
|
|
@@ -72,7 +72,7 @@ export class AffectedTrustedWebActivityIssueDetailsView extends AffectedResource
|
|
|
72
72
|
|
|
73
73
|
let count = 0;
|
|
74
74
|
for (const twaIssue of twaIssues) {
|
|
75
|
-
this
|
|
75
|
+
this.#appendDetail(twaIssue);
|
|
76
76
|
count++;
|
|
77
77
|
}
|
|
78
78
|
this.updateAffectedResourceCount(count);
|
|
@@ -80,6 +80,6 @@ export class AffectedTrustedWebActivityIssueDetailsView extends AffectedResource
|
|
|
80
80
|
|
|
81
81
|
update(): void {
|
|
82
82
|
this.clear();
|
|
83
|
-
this
|
|
83
|
+
this.#appendDetails(this.issue.getTrustedWebActivityIssues());
|
|
84
84
|
}
|
|
85
85
|
}
|
|
@@ -80,13 +80,13 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
80
80
|
this.clear();
|
|
81
81
|
const issues = this.issue.getAttributionReportingIssues();
|
|
82
82
|
if (issues.size > 0) {
|
|
83
|
-
this
|
|
83
|
+
this.#appendDetails(issues.values().next().value.code(), issues);
|
|
84
84
|
} else {
|
|
85
85
|
this.updateAffectedResourceCount(0);
|
|
86
86
|
}
|
|
87
87
|
}
|
|
88
88
|
|
|
89
|
-
|
|
89
|
+
#appendDetails(
|
|
90
90
|
issueCode: IssuesManager.AttributionReportingIssue.IssueCode,
|
|
91
91
|
issues: Iterable<IssuesManager.AttributionReportingIssue.AttributionReportingIssue>): void {
|
|
92
92
|
const header = document.createElement('tr');
|
|
@@ -156,12 +156,12 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
156
156
|
let count = 0;
|
|
157
157
|
for (const issue of issues) {
|
|
158
158
|
count++;
|
|
159
|
-
this
|
|
159
|
+
this.#appendDetail(issueCode, issue);
|
|
160
160
|
}
|
|
161
161
|
this.updateAffectedResourceCount(count);
|
|
162
162
|
}
|
|
163
163
|
|
|
164
|
-
|
|
164
|
+
async #appendDetail(
|
|
165
165
|
issueCode: IssuesManager.AttributionReportingIssue.IssueCode,
|
|
166
166
|
issue: IssuesManager.AttributionReportingIssue.AttributionReportingIssue): Promise<void> {
|
|
167
167
|
const element = document.createElement('tr');
|
|
@@ -171,12 +171,12 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
171
171
|
|
|
172
172
|
switch (issueCode) {
|
|
173
173
|
case IssuesManager.AttributionReportingIssue.IssueCode.AttributionUntrustworthyFrameOrigin:
|
|
174
|
-
this
|
|
175
|
-
this
|
|
174
|
+
this.#appendFrameOrEmptyCell(element, issue);
|
|
175
|
+
this.#appendRequestOrEmptyCell(element, details.request);
|
|
176
176
|
this.appendIssueDetailCell(element, details.invalidParameter || '');
|
|
177
177
|
break;
|
|
178
178
|
case IssuesManager.AttributionReportingIssue.IssueCode.AttributionSourceUntrustworthyOrigin:
|
|
179
|
-
await this
|
|
179
|
+
await this.#appendElementOrEmptyCell(element, issue);
|
|
180
180
|
this.appendIssueDetailCell(element, details.invalidParameter || '');
|
|
181
181
|
break;
|
|
182
182
|
case IssuesManager.AttributionReportingIssue.IssueCode.AttributionTriggerDataTooLarge:
|
|
@@ -186,31 +186,31 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
186
186
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidEventSourceTriggerData:
|
|
187
187
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidTriggerPriority:
|
|
188
188
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidTriggerDedupKey:
|
|
189
|
-
this
|
|
189
|
+
this.#appendRequestOrEmptyCell(element, details.request);
|
|
190
190
|
this.appendIssueDetailCell(element, details.invalidParameter || '');
|
|
191
191
|
break;
|
|
192
192
|
case IssuesManager.AttributionReportingIssue.IssueCode.AttributionSourceUntrustworthyFrameOrigin:
|
|
193
193
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidAttributionSourceEventId:
|
|
194
194
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidAttributionSourceExpiry:
|
|
195
195
|
case IssuesManager.AttributionReportingIssue.IssueCode.InvalidAttributionSourcePriority:
|
|
196
|
-
this
|
|
197
|
-
await this
|
|
196
|
+
this.#appendFrameOrEmptyCell(element, issue);
|
|
197
|
+
await this.#appendElementOrEmptyCell(element, issue);
|
|
198
198
|
this.appendIssueDetailCell(element, details.invalidParameter || '');
|
|
199
199
|
break;
|
|
200
200
|
case IssuesManager.AttributionReportingIssue.IssueCode.MissingAttributionData:
|
|
201
|
-
this
|
|
201
|
+
this.#appendRequestOrEmptyCell(element, details.request);
|
|
202
202
|
break;
|
|
203
203
|
case IssuesManager.AttributionReportingIssue.IssueCode.PermissionPolicyDisabled:
|
|
204
|
-
this
|
|
205
|
-
await this
|
|
206
|
-
this
|
|
204
|
+
this.#appendFrameOrEmptyCell(element, issue);
|
|
205
|
+
await this.#appendElementOrEmptyCell(element, issue);
|
|
206
|
+
this.#appendRequestOrEmptyCell(element, details.request);
|
|
207
207
|
break;
|
|
208
208
|
}
|
|
209
209
|
|
|
210
210
|
this.affectedResources.appendChild(element);
|
|
211
211
|
}
|
|
212
212
|
|
|
213
|
-
|
|
213
|
+
#appendFrameOrEmptyCell(
|
|
214
214
|
parent: HTMLElement, issue: IssuesManager.AttributionReportingIssue.AttributionReportingIssue): void {
|
|
215
215
|
const details = issue.issueDetails;
|
|
216
216
|
if (details.frame) {
|
|
@@ -220,7 +220,7 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
220
220
|
}
|
|
221
221
|
}
|
|
222
222
|
|
|
223
|
-
|
|
223
|
+
async #appendElementOrEmptyCell(
|
|
224
224
|
parent: HTMLElement, issue: IssuesManager.AttributionReportingIssue.AttributionReportingIssue): Promise<void> {
|
|
225
225
|
const details = issue.issueDetails;
|
|
226
226
|
if (details.violatingNodeId !== undefined) {
|
|
@@ -233,7 +233,7 @@ export class AttributionReportingIssueDetailsView extends AffectedResourcesView
|
|
|
233
233
|
}
|
|
234
234
|
}
|
|
235
235
|
|
|
236
|
-
|
|
236
|
+
#appendRequestOrEmptyCell(parent: HTMLElement, request?: Protocol.Audits.AffectedRequest): void {
|
|
237
237
|
if (!request) {
|
|
238
238
|
this.appendIssueDetailCell(parent, '');
|
|
239
239
|
return;
|
|
@@ -11,15 +11,15 @@ import * as LitHtml from '../../ui/lit-html/lit-html.js';
|
|
|
11
11
|
import cspViolationsListViewStyles from './cspViolationsListView.css.js';
|
|
12
12
|
|
|
13
13
|
export class CSPViolationsListView extends UI.Widget.VBox {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
#table = new DataGrid.DataGridController.DataGridController();
|
|
15
|
+
#categoryFilter = new Set<string>();
|
|
16
|
+
#issueRows =
|
|
17
17
|
new Map<IssuesManager.ContentSecurityPolicyIssue.ContentSecurityPolicyIssue, DataGrid.DataGridUtils.Row>();
|
|
18
18
|
|
|
19
19
|
constructor() {
|
|
20
20
|
super(true);
|
|
21
21
|
|
|
22
|
-
this
|
|
22
|
+
this.#table.data = {
|
|
23
23
|
columns: [
|
|
24
24
|
{id: 'sourceCode', title: 'Source Code', sortable: false, widthWeighting: 1, visible: true, hideable: false},
|
|
25
25
|
{
|
|
@@ -35,34 +35,33 @@ export class CSPViolationsListView extends UI.Widget.VBox {
|
|
|
35
35
|
],
|
|
36
36
|
rows: [],
|
|
37
37
|
};
|
|
38
|
-
this.contentElement.appendChild(this
|
|
38
|
+
this.contentElement.appendChild(this.#table);
|
|
39
39
|
}
|
|
40
40
|
|
|
41
41
|
updateTextFilter(filter: string): void {
|
|
42
42
|
if (filter.length === 0) {
|
|
43
|
-
this
|
|
43
|
+
this.#table.data = {...this.#table.data, filters: []};
|
|
44
44
|
} else {
|
|
45
|
-
this
|
|
46
|
-
...this
|
|
45
|
+
this.#table.data = {
|
|
46
|
+
...this.#table.data,
|
|
47
47
|
filters: [{text: filter, key: undefined, regex: undefined, negative: false}],
|
|
48
48
|
};
|
|
49
49
|
}
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
updateCategoryFilter(categories: Set<string>): void {
|
|
53
|
-
this
|
|
53
|
+
this.#categoryFilter = categories;
|
|
54
54
|
const rows = [];
|
|
55
|
-
for (const [issue, row] of this
|
|
56
|
-
if (this
|
|
55
|
+
for (const [issue, row] of this.#issueRows.entries()) {
|
|
56
|
+
if (this.#isIssueInFilterCategories(issue)) {
|
|
57
57
|
rows.push(row);
|
|
58
58
|
}
|
|
59
59
|
}
|
|
60
|
-
this
|
|
60
|
+
this.#table.data = {...this.#table.data, rows: rows};
|
|
61
61
|
}
|
|
62
62
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
return (this.categoryFilter.has(issue.code()) || this.categoryFilter.size === 0);
|
|
63
|
+
#isIssueInFilterCategories(issue: IssuesManager.ContentSecurityPolicyIssue.ContentSecurityPolicyIssue): boolean {
|
|
64
|
+
return (this.#categoryFilter.has(issue.code()) || this.#categoryFilter.size === 0);
|
|
66
65
|
}
|
|
67
66
|
|
|
68
67
|
addIssue(issue: IssuesManager.ContentSecurityPolicyIssue.ContentSecurityPolicyIssue): void {
|
|
@@ -71,7 +70,7 @@ export class CSPViolationsListView extends UI.Widget.VBox {
|
|
|
71
70
|
return;
|
|
72
71
|
}
|
|
73
72
|
const status = issue.details().isReportOnly ? 'report-only' : 'blocked';
|
|
74
|
-
const category = this
|
|
73
|
+
const category = this.#issueViolationCodeToCategoryName(issue.code());
|
|
75
74
|
const newIssue = {
|
|
76
75
|
cells: [
|
|
77
76
|
{
|
|
@@ -87,20 +86,20 @@ export class CSPViolationsListView extends UI.Widget.VBox {
|
|
|
87
86
|
{columnId: 'status', value: status},
|
|
88
87
|
],
|
|
89
88
|
};
|
|
90
|
-
this
|
|
89
|
+
this.#issueRows.set(issue, newIssue);
|
|
91
90
|
|
|
92
|
-
if (this
|
|
93
|
-
this
|
|
94
|
-
this
|
|
91
|
+
if (this.#isIssueInFilterCategories(issue)) {
|
|
92
|
+
this.#table.data.rows.push(newIssue);
|
|
93
|
+
this.#table.data = {...this.#table.data};
|
|
95
94
|
}
|
|
96
95
|
}
|
|
97
96
|
|
|
98
97
|
clearIssues(): void {
|
|
99
|
-
this
|
|
100
|
-
this
|
|
98
|
+
this.#issueRows.clear();
|
|
99
|
+
this.#table.data = {...this.#table.data, rows: []};
|
|
101
100
|
}
|
|
102
101
|
|
|
103
|
-
|
|
102
|
+
#issueViolationCodeToCategoryName(code: string): string {
|
|
104
103
|
if (code === IssuesManager.ContentSecurityPolicyIssue.inlineViolationCode) {
|
|
105
104
|
return 'Inline Violation';
|
|
106
105
|
}
|
|
@@ -23,8 +23,8 @@ const str_ = i18n.i18n.registerUIStrings('panels/issues/CSPViolationsView.ts', U
|
|
|
23
23
|
const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
24
24
|
let cspViolationsViewInstance: CSPViolationsView;
|
|
25
25
|
export class CSPViolationsView extends UI.Widget.VBox {
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
#listView = new CSPViolationsListView();
|
|
27
|
+
#issuesManager = IssuesManager.IssuesManager.IssuesManager.instance();
|
|
28
28
|
|
|
29
29
|
/**
|
|
30
30
|
* @private
|
|
@@ -37,7 +37,7 @@ export class CSPViolationsView extends UI.Widget.VBox {
|
|
|
37
37
|
const topToolbar = new UI.Toolbar.Toolbar('csp-violations-toolbar', this.contentElement);
|
|
38
38
|
const textFilterUI = new UI.Toolbar.ToolbarInput(i18nString(UIStrings.filter), '', 1, .2, '');
|
|
39
39
|
textFilterUI.addEventListener(UI.Toolbar.ToolbarInput.Event.TextChanged, () => {
|
|
40
|
-
this
|
|
40
|
+
this.#listView.updateTextFilter(textFilterUI.value());
|
|
41
41
|
});
|
|
42
42
|
topToolbar.appendToolbarItem(textFilterUI);
|
|
43
43
|
|
|
@@ -55,16 +55,16 @@ export class CSPViolationsView extends UI.Widget.VBox {
|
|
|
55
55
|
});
|
|
56
56
|
levelMenuButton.setOnOptionClicked(() => {
|
|
57
57
|
const categories = new Set(levelMenuButton.getOptions().filter(x => x.enabled).map(x => x.value));
|
|
58
|
-
this
|
|
58
|
+
this.#listView.updateCategoryFilter(categories);
|
|
59
59
|
});
|
|
60
60
|
topToolbar.appendToolbarItem(levelMenuButton);
|
|
61
|
-
this
|
|
61
|
+
this.#listView.show(this.contentElement);
|
|
62
62
|
|
|
63
|
-
this
|
|
64
|
-
this
|
|
65
|
-
IssuesManager.IssuesManager.Events.FullUpdateRequired, this
|
|
63
|
+
this.#issuesManager.addEventListener(IssuesManager.IssuesManager.Events.IssueAdded, this.#onIssueAdded, this);
|
|
64
|
+
this.#issuesManager.addEventListener(
|
|
65
|
+
IssuesManager.IssuesManager.Events.FullUpdateRequired, this.#onFullUpdateRequired, this);
|
|
66
66
|
|
|
67
|
-
this
|
|
67
|
+
this.#addAllIssues();
|
|
68
68
|
}
|
|
69
69
|
|
|
70
70
|
static instance(opts = {forceNew: null}): CSPViolationsView {
|
|
@@ -76,22 +76,22 @@ export class CSPViolationsView extends UI.Widget.VBox {
|
|
|
76
76
|
return cspViolationsViewInstance;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
|
|
79
|
+
#onIssueAdded(event: Common.EventTarget.EventTargetEvent<IssuesManager.IssuesManager.IssueAddedEvent>): void {
|
|
80
80
|
const {issue} = event.data;
|
|
81
81
|
if (issue instanceof IssuesManager.ContentSecurityPolicyIssue.ContentSecurityPolicyIssue) {
|
|
82
|
-
this
|
|
82
|
+
this.#listView.addIssue(issue);
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
85
|
|
|
86
|
-
|
|
87
|
-
this
|
|
88
|
-
this
|
|
86
|
+
#onFullUpdateRequired(): void {
|
|
87
|
+
this.#listView.clearIssues();
|
|
88
|
+
this.#addAllIssues();
|
|
89
89
|
}
|
|
90
90
|
|
|
91
|
-
|
|
92
|
-
for (const issue of this
|
|
91
|
+
#addAllIssues(): void {
|
|
92
|
+
for (const issue of this.#issuesManager.issues()) {
|
|
93
93
|
if (issue instanceof IssuesManager.ContentSecurityPolicyIssue.ContentSecurityPolicyIssue) {
|
|
94
|
-
this
|
|
94
|
+
this.#listView.addIssue(issue);
|
|
95
95
|
}
|
|
96
96
|
}
|
|
97
97
|
}
|
|
@@ -6,52 +6,52 @@ import type * as Common from '../../core/common/common.js';
|
|
|
6
6
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
7
7
|
|
|
8
8
|
export class ComboBoxOfCheckBoxes extends UI.Toolbar.ToolbarButton {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
#options = new Array<MenuOption>();
|
|
10
|
+
#headers = new Array<MenuHeader>();
|
|
11
|
+
#onOptionClicked = (): void => {};
|
|
12
12
|
constructor(title: string) {
|
|
13
13
|
super(title);
|
|
14
14
|
this.turnIntoSelect();
|
|
15
|
-
this.addEventListener(UI.Toolbar.ToolbarButton.Events.Click, this
|
|
15
|
+
this.addEventListener(UI.Toolbar.ToolbarButton.Events.Click, this.#showLevelContextMenu.bind(this));
|
|
16
16
|
UI.ARIAUtils.markAsMenuButton(this.element);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
addOption(option: string, value: string, defaultEnabled: boolean): void {
|
|
20
|
-
this
|
|
20
|
+
this.#options.push({'title': option, 'value': value, default: defaultEnabled, 'enabled': defaultEnabled});
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
setOptionEnabled(index: number, enabled: boolean): void {
|
|
24
|
-
const option = this
|
|
24
|
+
const option = this.#options[index];
|
|
25
25
|
if (!option) {
|
|
26
26
|
return;
|
|
27
27
|
}
|
|
28
28
|
option.enabled = enabled;
|
|
29
|
-
this
|
|
29
|
+
this.#onOptionClicked();
|
|
30
30
|
}
|
|
31
31
|
|
|
32
32
|
addHeader(headerName: string, callback: (() => void)): void {
|
|
33
|
-
this
|
|
33
|
+
this.#headers.push({title: headerName, callback: callback});
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
setOnOptionClicked(onOptionClicked: (() => void)): void {
|
|
37
|
-
this
|
|
37
|
+
this.#onOptionClicked = onOptionClicked;
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
getOptions(): Array<MenuOption> {
|
|
41
|
-
return this
|
|
41
|
+
return this.#options;
|
|
42
42
|
}
|
|
43
43
|
|
|
44
|
-
|
|
44
|
+
#showLevelContextMenu({data: mouseEvent}: Common.EventTarget.EventTargetEvent<Event>): void {
|
|
45
45
|
const contextMenu = new UI.ContextMenu.ContextMenu(mouseEvent, {
|
|
46
46
|
useSoftMenu: true,
|
|
47
47
|
x: this.element.totalOffsetLeft(),
|
|
48
48
|
y: this.element.totalOffsetTop() + this.element.offsetHeight,
|
|
49
49
|
});
|
|
50
50
|
|
|
51
|
-
for (const {title, callback} of this
|
|
51
|
+
for (const {title, callback} of this.#headers) {
|
|
52
52
|
contextMenu.headerSection().appendCheckboxItem(title, () => callback());
|
|
53
53
|
}
|
|
54
|
-
for (const [index, {title, enabled}] of this
|
|
54
|
+
for (const [index, {title, enabled}] of this.#options.entries()) {
|
|
55
55
|
contextMenu.defaultSection().appendCheckboxItem(title, () => {
|
|
56
56
|
this.setOptionEnabled(index, !enabled);
|
|
57
57
|
}, enabled);
|