chrome-devtools-frontend 1.0.1548980 → 1.0.1550444
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/contributing/settings-experiments-features.md +35 -0
- package/docs/styleguide/ux/components.md +53 -12
- package/docs/styleguide/ux/images/cards.png +0 -0
- package/docs/styleguide/ux/patterns.md +27 -0
- package/docs/ui_engineering.md +2 -2
- package/eslint.config.mjs +1 -0
- package/front_end/Tests.js +2 -0
- package/front_end/core/host/InspectorFrontendHost.ts +26 -558
- package/front_end/core/host/InspectorFrontendHostAPI.ts +6 -3
- package/front_end/core/host/InspectorFrontendHostStub.ts +558 -0
- package/front_end/core/host/ResourceLoader.ts +9 -23
- package/front_end/core/host/UserMetrics.ts +4 -4
- package/front_end/core/root/DevToolsContext.ts +4 -0
- package/front_end/core/root/Runtime.ts +10 -0
- package/front_end/core/sdk/CSSMatchedStyles.ts +2 -2
- package/front_end/core/sdk/CSSModel.ts +24 -24
- package/front_end/core/sdk/CSSPropertyParserMatchers.ts +11 -11
- package/front_end/core/sdk/CSSQuery.ts +1 -1
- package/front_end/core/sdk/CSSRule.ts +2 -2
- package/front_end/core/sdk/CSSStyleDeclaration.ts +1 -1
- package/front_end/core/sdk/CSSStyleSheetHeader.ts +1 -1
- package/front_end/core/sdk/DOMModel.ts +3 -0
- package/front_end/core/sdk/NetworkManager.ts +41 -41
- package/front_end/core/sdk/NetworkRequest.ts +4 -0
- package/front_end/core/sdk/OverlayModel.ts +2 -2
- package/front_end/core/sdk/PageResourceLoader.ts +71 -38
- package/front_end/core/sdk/SourceMap.ts +6 -0
- package/front_end/core/sdk/SourceMapCache.ts +21 -0
- package/front_end/core/sdk/SourceMapManager.ts +14 -7
- package/front_end/core/sdk/SourceMapScopesInfo.ts +6 -2
- package/front_end/core/sdk/TargetManager.ts +14 -2
- package/front_end/core/sdk/sdk-meta.ts +13 -0
- package/front_end/entrypoints/formatter_worker/FormatterActions.ts +1 -0
- package/front_end/entrypoints/formatter_worker/ScopeParser.ts +1 -1
- package/front_end/entrypoints/main/MainImpl.ts +5 -4
- package/front_end/foundation/Universe.ts +8 -1
- package/front_end/generated/Deprecation.ts +18 -4
- package/front_end/generated/InspectorBackendCommands.ts +38 -33
- package/front_end/generated/SupportedCSSProperties.js +41 -41
- package/front_end/generated/protocol-mapping.d.ts +20 -0
- package/front_end/generated/protocol-proxy-api.d.ts +17 -0
- package/front_end/generated/protocol.ts +146 -35
- package/front_end/models/ai_assistance/AiConversation.ts +5 -4
- package/front_end/models/ai_assistance/BuiltInAi.ts +79 -5
- package/front_end/models/ai_assistance/ChangeManager.ts +4 -4
- package/front_end/models/ai_assistance/ConversationHandler.ts +0 -15
- package/front_end/models/ai_assistance/agents/AiAgent.ts +9 -6
- package/front_end/models/ai_assistance/agents/PerformanceAgent.ts +135 -3
- package/front_end/models/ai_assistance/data_formatters/PerformanceTraceFormatter.ts +24 -0
- package/front_end/models/bindings/CompilerScriptMapping.ts +43 -0
- package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +19 -0
- package/front_end/models/bindings/ResourceMapping.ts +73 -0
- package/front_end/models/bindings/ResourceScriptMapping.ts +50 -0
- package/front_end/models/issues_manager/AttributionReportingIssue.ts +6 -8
- package/front_end/models/issues_manager/BounceTrackingIssue.ts +4 -14
- package/front_end/models/issues_manager/ClientHintIssue.ts +5 -12
- package/front_end/models/issues_manager/ContentSecurityPolicyIssue.ts +5 -12
- package/front_end/models/issues_manager/CookieDeprecationMetadataIssue.ts +7 -14
- package/front_end/models/issues_manager/CookieIssue.ts +27 -30
- package/front_end/models/issues_manager/CorsIssue.ts +8 -17
- package/front_end/models/issues_manager/CrossOriginEmbedderPolicyIssue.ts +5 -8
- package/front_end/models/issues_manager/DeprecationIssue.ts +7 -14
- package/front_end/models/issues_manager/ElementAccessibilityIssue.ts +7 -14
- package/front_end/models/issues_manager/FederatedAuthRequestIssue.ts +4 -11
- package/front_end/models/issues_manager/FederatedAuthUserInfoRequestIssue.ts +4 -11
- package/front_end/models/issues_manager/GenericIssue.ts +28 -16
- package/front_end/models/issues_manager/HeavyAdIssue.ts +4 -11
- package/front_end/models/issues_manager/Issue.ts +12 -4
- package/front_end/models/issues_manager/IssueAggregator.ts +8 -2
- package/front_end/models/issues_manager/LowTextContrastIssue.ts +3 -10
- package/front_end/models/issues_manager/MixedContentIssue.ts +7 -13
- package/front_end/models/issues_manager/PartitioningBlobURLIssue.ts +4 -11
- package/front_end/models/issues_manager/PropertyRuleIssue.ts +6 -12
- package/front_end/models/issues_manager/QuirksModeIssue.ts +3 -10
- package/front_end/models/issues_manager/SRIMessageSignatureIssue.ts +7 -13
- package/front_end/models/issues_manager/SharedArrayBufferIssue.ts +4 -11
- package/front_end/models/issues_manager/SharedDictionaryIssue.ts +6 -13
- package/front_end/models/issues_manager/StylesheetLoadingIssue.ts +8 -13
- package/front_end/models/issues_manager/UnencodedDigestIssue.ts +2 -9
- package/front_end/models/issues_manager/descriptions/genericNavigationEntryMarkedSkippable.md +7 -0
- package/front_end/models/javascript_metadata/NativeFunctions.js +7 -16
- package/front_end/models/source_map_scopes/FunctionCodeResolver.snapshot.txt +98 -0
- package/front_end/models/source_map_scopes/FunctionCodeResolver.ts +270 -0
- package/front_end/models/source_map_scopes/source_map_scopes.ts +2 -0
- package/front_end/models/workspace/UISourceCode.ts +51 -44
- package/front_end/panels/ai_assistance/AiAssistancePanel.ts +76 -34
- package/front_end/panels/ai_assistance/aiAssistancePanel.css +1 -0
- package/front_end/panels/ai_assistance/components/ChatView.ts +23 -11
- package/front_end/panels/application/AppManifestView.ts +7 -6
- package/front_end/panels/application/ApplicationPanelSidebar.ts +21 -21
- package/front_end/panels/application/BackForwardCacheTreeElement.ts +2 -2
- package/front_end/panels/application/BounceTrackingMitigationsTreeElement.ts +2 -2
- package/front_end/panels/application/FrameDetailsView.ts +5 -6
- package/front_end/panels/application/InterestGroupTreeElement.ts +2 -2
- package/front_end/panels/application/OpenedWindowDetailsView.ts +2 -2
- package/front_end/panels/application/OriginTrialTreeView.ts +1 -1
- package/front_end/panels/application/PreloadingTreeElement.ts +3 -3
- package/front_end/panels/application/ReportingApiTreeElement.ts +2 -2
- package/front_end/panels/application/ServiceWorkerCacheTreeElement.ts +3 -3
- package/front_end/panels/application/ServiceWorkersView.ts +2 -2
- package/front_end/panels/application/SharedStorageListTreeElement.ts +2 -2
- package/front_end/panels/application/StorageBucketsTreeElement.ts +3 -3
- package/front_end/panels/application/StorageView.ts +2 -2
- package/front_end/panels/application/TrustTokensTreeElement.ts +4 -8
- package/front_end/panels/application/components/PermissionsPolicySection.ts +202 -158
- package/front_end/panels/application/components/ProtocolHandlersView.ts +118 -81
- package/front_end/panels/application/components/ServiceWorkerRouterView.ts +47 -41
- package/front_end/panels/application/components/SharedStorageMetadataView.ts +1 -1
- package/front_end/panels/application/components/StorageMetadataView.ts +31 -34
- package/front_end/panels/application/components/TrustTokensView.ts +77 -69
- package/front_end/panels/application/preloading/components/PreloadingGrid.ts +1 -1
- package/front_end/panels/application/preloading/components/RuleSetGrid.ts +1 -1
- package/front_end/panels/application/preloading/components/UsedPreloadingView.ts +1 -1
- package/front_end/panels/changes/ChangesSidebar.ts +2 -0
- package/front_end/panels/changes/CombinedDiffView.ts +2 -0
- package/front_end/panels/common/AnnotationManager.ts +71 -0
- package/front_end/panels/common/PersistenceUtils.ts +6 -7
- package/front_end/panels/common/common.ts +1 -0
- package/front_end/panels/console/ConsolePrompt.ts +4 -4
- package/front_end/panels/console/ConsoleView.ts +5 -4
- package/front_end/panels/console/ConsoleViewMessage.ts +16 -15
- package/front_end/panels/console/console-meta.ts +0 -13
- package/front_end/panels/console_counters/WarningErrorCounter.ts +2 -0
- package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +1 -1
- package/front_end/panels/developer_resources/DeveloperResourcesView.ts +3 -1
- package/front_end/panels/elements/CSSRuleValidator.ts +7 -7
- package/front_end/panels/elements/CSSRuleValidatorHelper.ts +2 -2
- package/front_end/panels/elements/ColorSwatchPopoverIcon.ts +3 -3
- package/front_end/panels/elements/ElementsPanel.ts +49 -0
- package/front_end/panels/elements/ElementsTreeElement.ts +172 -121
- package/front_end/panels/elements/ElementsTreeOutline.ts +11 -3
- package/front_end/panels/elements/LayoutPane.ts +12 -10
- package/front_end/panels/elements/ShortcutTreeElement.ts +2 -2
- package/front_end/panels/elements/StyleEditorWidget.ts +2 -2
- package/front_end/panels/elements/StylePropertyTreeElement.ts +18 -18
- package/front_end/panels/elements/StylesSidebarPane.ts +4 -5
- package/front_end/panels/elements/TopLayerContainer.ts +2 -2
- package/front_end/panels/elements/components/AdornerManager.ts +3 -3
- package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +1 -1
- package/front_end/panels/elements/components/ElementsTreeExpandButton.ts +1 -1
- package/front_end/panels/elements/components/QueryContainer.ts +1 -1
- package/front_end/panels/elements/components/StylePropertyEditor.ts +7 -7
- package/front_end/panels/emulation/DeviceModeWrapper.ts +48 -3
- package/front_end/panels/explain/components/ConsoleInsight.ts +6 -4
- package/front_end/panels/issues/AffectedResourcesView.ts +2 -2
- package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +2 -2
- package/front_end/panels/issues/IssueKindView.ts +2 -2
- package/front_end/panels/issues/IssueView.ts +4 -4
- package/front_end/panels/js_timeline/js_timeline-meta.ts +4 -2
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryHighlightChipList.ts +28 -50
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryInspector.ts +15 -11
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryNavigator.ts +1 -1
- package/front_end/panels/linear_memory_inspector/components/LinearMemoryValueInterpreter.ts +1 -1
- package/front_end/panels/linear_memory_inspector/components/ValueInterpreterDisplay.ts +1 -1
- package/front_end/panels/media/PlayerListView.ts +100 -73
- package/front_end/panels/media/playerListView.css +5 -0
- package/front_end/panels/mobile_throttling/ThrottlingManager.ts +2 -2
- package/front_end/panels/mobile_throttling/ThrottlingSettingsTab.ts +4 -5
- package/front_end/panels/network/NetworkDataGridNode.ts +3 -3
- package/front_end/panels/network/NetworkFrameGrouper.ts +2 -2
- package/front_end/panels/network/NetworkItemView.ts +4 -4
- package/front_end/panels/network/NetworkLogViewColumns.ts +3 -3
- package/front_end/panels/network/RequestConditionsDrawer.ts +5 -5
- package/front_end/panels/network/RequestCookiesView.ts +2 -2
- package/front_end/panels/network/SignedExchangeInfoView.ts +2 -2
- package/front_end/panels/network/components/DirectSocketConnectionView.ts +17 -0
- package/front_end/panels/network/components/RequestTrustTokensView.ts +5 -6
- package/front_end/panels/network/resourceChunkView.css +4 -0
- package/front_end/panels/profiler/HeapSnapshotGridNodes.ts +3 -3
- package/front_end/panels/profiler/ProfileDataGrid.ts +2 -2
- package/front_end/panels/profiler/ProfilesPanel.ts +2 -2
- package/front_end/panels/protocol_monitor/JSONEditor.ts +1 -1
- package/front_end/panels/recorder/components/CreateRecordingView.ts +1 -1
- package/front_end/panels/recorder/components/ExtensionView.ts +1 -1
- package/front_end/panels/recorder/components/RecordingListView.ts +1 -1
- package/front_end/panels/recorder/components/RecordingView.ts +1 -1
- package/front_end/panels/recorder/components/StepView.ts +1 -1
- package/front_end/panels/screencast/ScreencastView.ts +8 -8
- package/front_end/panels/search/SearchView.ts +1 -1
- package/front_end/panels/security/CookieControlsTreeElement.ts +2 -2
- package/front_end/panels/security/CookieControlsView.ts +1 -1
- package/front_end/panels/security/CookieReportTreeElement.ts +2 -2
- package/front_end/panels/security/SecurityPanel.ts +5 -5
- package/front_end/panels/security/SecurityPanelSidebar.ts +3 -4
- package/front_end/panels/sensors/LocationsSettingsTab.ts +1 -1
- package/front_end/panels/settings/FrameworkIgnoreListSettingsTab.ts +1 -1
- package/front_end/panels/settings/KeybindsSettingsTab.ts +5 -5
- package/front_end/panels/settings/SettingsScreen.ts +7 -8
- package/front_end/panels/settings/WorkspaceSettingsTab.ts +1 -1
- package/front_end/panels/settings/emulation/DevicesSettingsTab.ts +1 -1
- package/front_end/panels/snippets/SnippetsQuickOpen.ts +16 -6
- package/front_end/panels/sources/BreakpointEditDialog.ts +3 -3
- package/front_end/panels/sources/BreakpointsView.ts +1 -1
- package/front_end/panels/sources/CSSPlugin.ts +4 -4
- package/front_end/panels/sources/CallStackSidebarPane.ts +4 -4
- package/front_end/panels/sources/DebuggerPausedMessage.ts +3 -3
- package/front_end/panels/sources/FilteredUISourceCodeListProvider.ts +40 -23
- package/front_end/panels/sources/GoToLineQuickOpen.ts +11 -5
- package/front_end/panels/sources/NavigatorView.ts +4 -4
- package/front_end/panels/sources/OpenFileQuickOpen.ts +11 -16
- package/front_end/panels/sources/OutlineQuickOpen.ts +23 -23
- package/front_end/panels/sources/ProfilePlugin.ts +21 -12
- package/front_end/panels/sources/SourcesView.ts +2 -2
- package/front_end/panels/sources/TabbedEditorContainer.ts +4 -5
- package/front_end/panels/sources/ThreadsSidebarPane.ts +2 -2
- package/front_end/panels/sources/UISourceCodeFrame.ts +5 -6
- package/front_end/panels/sources/filteredUISourceCodeListProvider.css +41 -0
- package/front_end/panels/timeline/TimelineHistoryManager.ts +2 -2
- package/front_end/panels/timeline/TimelinePanel.ts +29 -25
- package/front_end/panels/timeline/TimelineSelectorStatsView.ts +3 -3
- package/front_end/panels/timeline/components/CPUThrottlingSelector.ts +1 -1
- package/front_end/panels/timeline/components/LiveMetricsView.ts +1 -1
- package/front_end/panels/timeline/components/NetworkRequestTooltip.ts +1 -1
- package/front_end/panels/timeline/components/NetworkThrottlingSelector.ts +1 -1
- package/front_end/panels/timeline/components/OriginMap.ts +1 -1
- package/front_end/panels/timeline/components/insights/Checklist.ts +1 -1
- package/front_end/panels/timeline/components/insights/DOMSize.ts +1 -1
- package/front_end/panels/timeline/components/insights/ImageDelivery.ts +1 -1
- package/front_end/panels/timeline/components/insights/NetworkDependencyTree.ts +1 -1
- package/front_end/panels/timeline/components/insights/SlowCSSSelector.ts +2 -2
- package/front_end/panels/timeline/docs/flame_chart_migration.md +11 -16
- package/front_end/panels/timeline/overlays/components/EntriesLinkOverlay.ts +1 -1
- package/front_end/panels/timeline/overlays/components/EntryLabelOverlay.ts +1 -1
- package/front_end/panels/timeline/timeline-meta.ts +3 -2
- package/front_end/panels/utils/utils.ts +18 -3
- package/front_end/panels/whats_new/ReleaseNoteText.ts +10 -20
- package/front_end/panels/whats_new/resources/WNDT.md +8 -8
- package/front_end/third_party/chromium/README.chromium +1 -1
- package/front_end/third_party/puppeteer/third_party/mitt/README.chromium +1 -0
- package/front_end/third_party/puppeteer/third_party/parsel/README.chromium +1 -0
- package/front_end/third_party/puppeteer/third_party/rxjs/README.chromium +1 -0
- package/front_end/ui/components/adorners/Adorner.ts +21 -1
- package/front_end/ui/components/annotations/AnnotationRepository.ts +98 -0
- package/front_end/ui/components/annotations/AnnotationType.ts +10 -0
- package/front_end/ui/components/annotations/annotations.ts +6 -0
- package/front_end/ui/components/buttons/Button.ts +2 -2
- package/front_end/ui/components/buttons/FloatingButton.ts +2 -2
- package/front_end/ui/components/chrome_link/ChromeLink.ts +1 -1
- package/front_end/ui/components/dialogs/ButtonDialog.ts +1 -1
- package/front_end/ui/components/dialogs/Dialog.ts +1 -1
- package/front_end/ui/components/dialogs/ShortcutDialog.ts +1 -0
- package/front_end/ui/components/diff_view/DiffView.ts +1 -1
- package/front_end/ui/components/expandable_list/ExpandableList.ts +1 -1
- package/front_end/ui/components/highlighting/HighlightElement.ts +16 -2
- package/front_end/ui/components/highlighting/MarkupHighlight.ts +162 -0
- package/front_end/ui/components/highlighting/highlighting.ts +7 -0
- package/front_end/ui/components/icon_button/FileSourceIcon.ts +2 -2
- package/front_end/ui/components/icon_button/IconButton.ts +2 -2
- package/front_end/ui/components/icon_button/icon_button.ts +0 -2
- package/front_end/ui/components/issue_counter/IssueCounter.ts +2 -2
- package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +2 -2
- package/front_end/ui/components/legacy_wrapper/LegacyWrapper.ts +1 -1
- package/front_end/ui/components/linkifier/LinkifierImpl.ts +1 -1
- package/front_end/ui/components/list/List.ts +184 -0
- package/front_end/ui/components/list/list.css +90 -0
- package/front_end/ui/components/{cards/cards.ts → list/lists.ts} +3 -3
- package/front_end/ui/components/markdown_view/CodeBlock.ts +1 -1
- package/front_end/ui/components/markdown_view/MarkdownImage.ts +4 -4
- package/front_end/ui/components/markdown_view/MarkdownLink.ts +1 -1
- package/front_end/ui/components/markdown_view/MarkdownView.ts +1 -1
- package/front_end/ui/components/menus/Menu.ts +1 -1
- package/front_end/ui/components/menus/SelectMenu.ts +1 -1
- package/front_end/ui/components/node_text/NodeText.ts +1 -1
- package/front_end/ui/components/panel_feedback/FeedbackButton.ts +1 -1
- package/front_end/ui/components/panel_feedback/PanelFeedback.ts +1 -1
- package/front_end/ui/components/panel_feedback/PreviewToggle.ts +1 -1
- package/front_end/ui/components/panel_introduction_steps/PanelIntroductionSteps.ts +1 -1
- package/front_end/ui/components/report_view/ReportView.ts +1 -1
- package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +2 -2
- package/front_end/ui/components/settings/SettingCheckbox.ts +1 -1
- package/front_end/ui/components/settings/SettingDeprecationWarning.ts +2 -2
- package/front_end/ui/components/snackbars/Snackbar.ts +1 -1
- package/front_end/ui/components/spinners/Spinner.ts +1 -1
- package/front_end/ui/components/srgb_overlay/SrgbOverlay.ts +1 -1
- package/front_end/ui/components/suggestion_input/SuggestionInput.ts +1 -0
- package/front_end/ui/components/survey_link/SurveyLink.ts +2 -2
- package/front_end/ui/components/switch/SwitchImpl.ts +1 -1
- package/front_end/ui/components/text_editor/TextEditor.ts +1 -0
- package/front_end/ui/components/text_editor/config.ts +2 -2
- package/front_end/ui/components/text_prompt/TextPrompt.ts +1 -1
- package/front_end/ui/components/tooltips/Tooltip.ts +1 -1
- package/front_end/ui/components/tree_outline/TreeOutline.ts +1 -1
- package/front_end/ui/kit/cards/Card.docs.ts +43 -0
- package/front_end/ui/{components/icon_button → kit/icons}/Icon.docs.ts +3 -4
- package/front_end/ui/{components/icon_button → kit/icons}/Icon.ts +6 -4
- package/front_end/ui/kit/kit.ts +6 -0
- package/front_end/ui/legacy/Infobar.ts +3 -3
- package/front_end/ui/legacy/InspectorView.ts +3 -3
- package/front_end/ui/legacy/SearchableView.ts +2 -2
- package/front_end/ui/legacy/SoftContextMenu.ts +5 -5
- package/front_end/ui/legacy/SoftDropDown.ts +2 -2
- package/front_end/ui/legacy/TabbedPane.ts +106 -8
- package/front_end/ui/legacy/Toolbar.ts +3 -3
- package/front_end/ui/legacy/Treeoutline.ts +2 -2
- package/front_end/ui/legacy/UIUtils.ts +4 -188
- package/front_end/ui/legacy/ViewManager.ts +27 -12
- package/front_end/ui/legacy/ViewRegistration.ts +21 -22
- package/front_end/ui/legacy/components/color_picker/ContrastDetails.ts +8 -8
- package/front_end/ui/legacy/components/color_picker/Spectrum.ts +4 -4
- package/front_end/ui/legacy/components/cookie_table/CookiesTable.ts +4 -4
- package/front_end/ui/legacy/components/inline_editor/FontEditor.ts +2 -2
- package/front_end/ui/legacy/components/inline_editor/Swatches.ts +5 -5
- package/front_end/ui/legacy/components/object_ui/CustomPreviewComponent.ts +3 -3
- package/front_end/ui/legacy/components/object_ui/ObjectPropertiesSection.ts +5 -4
- package/front_end/ui/legacy/components/perf_ui/LineLevelProfile.ts +73 -35
- package/front_end/ui/legacy/components/perf_ui/LiveHeapProfile.ts +11 -2
- package/front_end/ui/legacy/components/perf_ui/OverviewGrid.ts +3 -3
- package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +23 -31
- package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +11 -27
- package/front_end/ui/legacy/components/quick_open/HelpQuickOpen.ts +11 -15
- package/front_end/ui/legacy/components/quick_open/filteredListWidget.css +18 -65
- package/front_end/ui/legacy/components/source_frame/JSONView.ts +2 -1
- package/front_end/ui/legacy/components/utils/Linkifier.ts +3 -3
- package/front_end/ui/legacy/tabbedPane.css +10 -0
- package/front_end/ui/visual_logging/KnownContextValues.ts +3 -0
- package/inspector_overlay/README.md +3 -3
- package/mcp/HostBindings.ts +310 -0
- package/mcp/mcp.ts +18 -0
- package/mcp/tsconfig.json +6 -1
- package/package.json +26 -24
- /package/front_end/ui/{components → kit}/cards/Card.ts +0 -0
- /package/front_end/ui/{components → kit}/cards/card.css +0 -0
- /package/front_end/ui/{components/icon_button → kit/icons}/icon.css +0 -0
|
@@ -68,6 +68,10 @@ const UIStrings = {
|
|
|
68
68
|
* @description Text in Connection info View of the Network panel
|
|
69
69
|
*/
|
|
70
70
|
directSocketStatusAborted: 'Aborted',
|
|
71
|
+
/**
|
|
72
|
+
* @description Text in Connection info View of the Network panel
|
|
73
|
+
*/
|
|
74
|
+
joinedMulticastGroups: 'joinedMulticastGroups',
|
|
71
75
|
|
|
72
76
|
} as const;
|
|
73
77
|
|
|
@@ -167,6 +171,10 @@ export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
167
171
|
${renderRow(i18nString(UIStrings.type), getDirectSocketTypeString(socketInfo.type))}
|
|
168
172
|
${renderRow(i18nString(UIStrings.status), getDirectSocketStatusString(socketInfo.status))}
|
|
169
173
|
${renderRow(i18nString(UIStrings.errorMessage), socketInfo.errorMessage)}
|
|
174
|
+
${
|
|
175
|
+
renderRow(
|
|
176
|
+
i18nString(UIStrings.joinedMulticastGroups),
|
|
177
|
+
socketInfo.joinedMulticastGroups ? Array.from(socketInfo.joinedMulticastGroups).join(', ') : '')}
|
|
170
178
|
</div>`;
|
|
171
179
|
|
|
172
180
|
const optionsContent = html`
|
|
@@ -181,6 +189,15 @@ export const DEFAULT_VIEW: View = (input, _output, target) => {
|
|
|
181
189
|
${
|
|
182
190
|
renderRow(i18n.i18n.lockedString('receiveBufferSize'), socketInfo.createOptions.receiveBufferSize?.toString(10))}
|
|
183
191
|
${renderRow(i18n.i18n.lockedString('dnsQueryType'), socketInfo.createOptions.dnsQueryType)}
|
|
192
|
+
${
|
|
193
|
+
renderRow(
|
|
194
|
+
i18n.i18n.lockedString('multicastTimeToLive'), socketInfo.createOptions.multicastTimeToLive?.toString(10))}
|
|
195
|
+
${
|
|
196
|
+
renderRow(i18n.i18n.lockedString('multicastLoopback'), socketInfo.createOptions.multicastLoopback?.toString())}
|
|
197
|
+
${
|
|
198
|
+
renderRow(
|
|
199
|
+
i18n.i18n.lockedString('multicastAllowAddressSharing'),
|
|
200
|
+
socketInfo.createOptions.multicastAllowAddressSharing?.toString())}
|
|
184
201
|
</div>`;
|
|
185
202
|
|
|
186
203
|
let openInfoContent: Lit.LitTemplate = Lit.nothing;
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
/* eslint-disable @devtools/no-lit-render-outside-of-view */
|
|
5
5
|
|
|
6
6
|
import '../../../ui/components/report_view/report_view.js';
|
|
7
|
-
import '../../../ui/
|
|
7
|
+
import '../../../ui/kit/kit.js';
|
|
8
8
|
|
|
9
9
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
10
10
|
import * as SDK from '../../../core/sdk/sdk.js';
|
|
11
11
|
import * as Protocol from '../../../generated/protocol.js';
|
|
12
|
-
import type * as IconButton from '../../../ui/components/icon_button/icon_button.js';
|
|
13
12
|
import * as LegacyWrapper from '../../../ui/components/legacy_wrapper/legacy_wrapper.js';
|
|
13
|
+
import type {IconWithName} from '../../../ui/kit/kit.js';
|
|
14
14
|
import * as Lit from '../../../ui/lit/lit.js';
|
|
15
15
|
import * as VisualLogging from '../../../ui/visual_logging/visual_logging.js';
|
|
16
16
|
|
|
@@ -223,12 +223,12 @@ export class RequestTrustTokensView extends LegacyWrapper.LegacyWrapper.Wrappabl
|
|
|
223
223
|
}
|
|
224
224
|
}
|
|
225
225
|
|
|
226
|
-
const SUCCESS_ICON_DATA:
|
|
226
|
+
const SUCCESS_ICON_DATA: IconWithName = {
|
|
227
227
|
color: 'var(--icon-checkmark-green)',
|
|
228
228
|
iconName: 'check-circle',
|
|
229
229
|
};
|
|
230
230
|
|
|
231
|
-
const FAILURE_ICON_DATA:
|
|
231
|
+
const FAILURE_ICON_DATA: IconWithName = {
|
|
232
232
|
color: 'var(--icon-error)',
|
|
233
233
|
iconName: 'cross-circle-filled',
|
|
234
234
|
};
|
|
@@ -239,8 +239,7 @@ export function statusConsideredSuccess(status: Protocol.Network.TrustTokenOpera
|
|
|
239
239
|
status === Protocol.Network.TrustTokenOperationDoneEventStatus.FulfilledLocally;
|
|
240
240
|
}
|
|
241
241
|
|
|
242
|
-
function getIconForStatusCode(status: Protocol.Network.TrustTokenOperationDoneEventStatus):
|
|
243
|
-
IconButton.Icon.IconWithName {
|
|
242
|
+
function getIconForStatusCode(status: Protocol.Network.TrustTokenOperationDoneEventStatus): IconWithName {
|
|
244
243
|
return statusConsideredSuccess(status) ? SUCCESS_ICON_DATA : FAILURE_ICON_DATA;
|
|
245
244
|
}
|
|
246
245
|
|
|
@@ -10,7 +10,7 @@ import * as Platform from '../../core/platform/platform.js';
|
|
|
10
10
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
11
11
|
import type * as Protocol from '../../generated/protocol.js';
|
|
12
12
|
import * as HeapSnapshotModel from '../../models/heap_snapshot_model/heap_snapshot_model.js';
|
|
13
|
-
import
|
|
13
|
+
import {createIcon} from '../../ui/kit/kit.js';
|
|
14
14
|
import * as DataGrid from '../../ui/legacy/components/data_grid/data_grid.js';
|
|
15
15
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
16
16
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
@@ -631,12 +631,12 @@ export abstract class HeapSnapshotGenericObjectNode extends HeapSnapshotGridNode
|
|
|
631
631
|
const div = fragment.$('container');
|
|
632
632
|
this.prefixObjectCell(div);
|
|
633
633
|
if (this.reachableFromWindow) {
|
|
634
|
-
const frameIcon =
|
|
634
|
+
const frameIcon = createIcon('frame', 'heap-object-tag');
|
|
635
635
|
UI.Tooltip.Tooltip.install(frameIcon, i18nString(UIStrings.userObjectReachableFromWindow));
|
|
636
636
|
div.appendChild(frameIcon);
|
|
637
637
|
}
|
|
638
638
|
if (this.detachedDOMTreeNode) {
|
|
639
|
-
const frameIcon =
|
|
639
|
+
const frameIcon = createIcon('scissors', 'heap-object-tag');
|
|
640
640
|
UI.Tooltip.Tooltip.install(frameIcon, i18nString(UIStrings.detachedFromDomTree));
|
|
641
641
|
div.appendChild(frameIcon);
|
|
642
642
|
}
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
32
32
|
import * as Platform from '../../core/platform/platform.js';
|
|
33
33
|
import type * as CPUProfile from '../../models/cpu_profile/cpu_profile.js';
|
|
34
|
-
import
|
|
34
|
+
import {Icon} from '../../ui/kit/kit.js';
|
|
35
35
|
import * as DataGrid from '../../ui/legacy/components/data_grid/data_grid.js';
|
|
36
36
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
37
37
|
|
|
@@ -203,7 +203,7 @@ export class ProfileDataGridNode extends DataGrid.DataGrid.DataGridNode<unknown>
|
|
|
203
203
|
cell.classList.toggle('highlight', this.searchMatchedFunctionColumn);
|
|
204
204
|
if (this.deoptReason) {
|
|
205
205
|
cell.classList.add('not-optimized');
|
|
206
|
-
const warningIcon = new
|
|
206
|
+
const warningIcon = new Icon();
|
|
207
207
|
warningIcon.name = 'warning-filled';
|
|
208
208
|
warningIcon.classList.add('profile-warn-marker', 'small');
|
|
209
209
|
UI.Tooltip.Tooltip.install(warningIcon, i18nString(UIStrings.notOptimizedS, {PH1: this.deoptReason}));
|
|
@@ -33,7 +33,7 @@ import '../../ui/legacy/legacy.js';
|
|
|
33
33
|
import * as Common from '../../core/common/common.js';
|
|
34
34
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
35
35
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
36
|
-
import
|
|
36
|
+
import {createIcon} from '../../ui/kit/kit.js';
|
|
37
37
|
// eslint-disable-next-line @devtools/es-modules-import
|
|
38
38
|
import objectValueStyles from '../../ui/legacy/components/object_ui/objectValue.css.js';
|
|
39
39
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
@@ -668,7 +668,7 @@ export class ProfilesSidebarTreeElement extends UI.TreeOutline.TreeElement {
|
|
|
668
668
|
.createChild('span', 'title-container')
|
|
669
669
|
.createChild('span', 'title')
|
|
670
670
|
.textContent = i18nString(UIStrings.profiles);
|
|
671
|
-
this.setLeadingIcons([
|
|
671
|
+
this.setLeadingIcons([createIcon('tune')]);
|
|
672
672
|
}
|
|
673
673
|
}
|
|
674
674
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import '../../ui/
|
|
5
|
+
import '../../ui/kit/kit.js';
|
|
6
6
|
import '../../ui/components/menus/menus.js';
|
|
7
7
|
|
|
8
8
|
import * as Common from '../../core/common/common.js';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import '../../../ui/
|
|
5
|
+
import '../../../ui/kit/kit.js';
|
|
6
6
|
import './ControlButton.js';
|
|
7
7
|
|
|
8
8
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
/* eslint-disable @devtools/no-lit-render-outside-of-view */
|
|
5
5
|
|
|
6
6
|
import '../../../ui/legacy/legacy.js';
|
|
7
|
-
import '../../../ui/
|
|
7
|
+
import '../../../ui/kit/kit.js';
|
|
8
8
|
|
|
9
9
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
10
10
|
import type * as PublicExtensions from '../../../models/extensions/extensions.js';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import '../../../ui/
|
|
5
|
+
import '../../../ui/kit/kit.js';
|
|
6
6
|
|
|
7
7
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
8
8
|
import * as Buttons from '../../../ui/components/buttons/buttons.js';
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import '../../../ui/
|
|
5
|
+
import '../../../ui/kit/kit.js';
|
|
6
6
|
import './ExtensionView.js';
|
|
7
7
|
import './ControlButton.js';
|
|
8
8
|
import './ReplaySection.js';
|
|
@@ -10,7 +10,7 @@ import * as i18n from '../../core/i18n/i18n.js';
|
|
|
10
10
|
import type * as Platform from '../../core/platform/platform.js';
|
|
11
11
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
12
12
|
import * as Protocol from '../../generated/protocol.js';
|
|
13
|
-
import
|
|
13
|
+
import {createIcon, Icon} from '../../ui/kit/kit.js';
|
|
14
14
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
15
15
|
|
|
16
16
|
import {InputModel} from './InputModel.js';
|
|
@@ -104,8 +104,8 @@ export class ScreencastView extends UI.Widget.VBox implements SDK.OverlayModel.H
|
|
|
104
104
|
private navigationProgressBar?: ProgressTracker;
|
|
105
105
|
private touchInputToggle?: HTMLButtonElement;
|
|
106
106
|
private mouseInputToggle?: HTMLButtonElement;
|
|
107
|
-
private touchInputToggleIcon?:
|
|
108
|
-
private mouseInputToggleIcon?:
|
|
107
|
+
private touchInputToggleIcon?: Icon;
|
|
108
|
+
private mouseInputToggleIcon?: Icon;
|
|
109
109
|
private historyIndex?: number;
|
|
110
110
|
private historyEntries?: Protocol.Page.NavigationEntry[];
|
|
111
111
|
private isCasting = false;
|
|
@@ -648,17 +648,17 @@ export class ScreencastView extends UI.Widget.VBox implements SDK.OverlayModel.H
|
|
|
648
648
|
this.navigationBar = this.element.createChild('div', 'screencast-navigation');
|
|
649
649
|
|
|
650
650
|
this.navigationBack = this.navigationBar.createChild('button', 'navigation');
|
|
651
|
-
this.navigationBack.appendChild(
|
|
651
|
+
this.navigationBack.appendChild(createIcon('arrow-back'));
|
|
652
652
|
this.navigationBack.disabled = true;
|
|
653
653
|
UI.ARIAUtils.setLabel(this.navigationBack, i18nString(UIStrings.back));
|
|
654
654
|
|
|
655
655
|
this.navigationForward = this.navigationBar.createChild('button', 'navigation');
|
|
656
|
-
this.navigationForward.appendChild(
|
|
656
|
+
this.navigationForward.appendChild(createIcon('arrow-forward'));
|
|
657
657
|
this.navigationForward.disabled = true;
|
|
658
658
|
UI.ARIAUtils.setLabel(this.navigationForward, i18nString(UIStrings.forward));
|
|
659
659
|
|
|
660
660
|
this.navigationReload = this.navigationBar.createChild('button', 'navigation');
|
|
661
|
-
this.navigationReload.appendChild(
|
|
661
|
+
this.navigationReload.appendChild(createIcon('refresh'));
|
|
662
662
|
UI.ARIAUtils.setLabel(this.navigationReload, i18nString(UIStrings.reload));
|
|
663
663
|
|
|
664
664
|
this.navigationUrl = this.navigationBar.appendChild(UI.UIUtils.createInput());
|
|
@@ -668,14 +668,14 @@ export class ScreencastView extends UI.Widget.VBox implements SDK.OverlayModel.H
|
|
|
668
668
|
this.mouseInputToggle = this.navigationBar.createChild('button');
|
|
669
669
|
this.mouseInputToggle.disabled = true;
|
|
670
670
|
{
|
|
671
|
-
this.mouseInputToggleIcon = this.mouseInputToggle.appendChild(new
|
|
671
|
+
this.mouseInputToggleIcon = this.mouseInputToggle.appendChild(new Icon());
|
|
672
672
|
this.mouseInputToggleIcon.name = 'mouse';
|
|
673
673
|
this.mouseInputToggleIcon.classList.toggle('toggled', true);
|
|
674
674
|
}
|
|
675
675
|
UI.ARIAUtils.setLabel(this.mouseInputToggle, i18nString(UIStrings.mouseInput));
|
|
676
676
|
|
|
677
677
|
this.touchInputToggle = this.navigationBar.createChild('button');
|
|
678
|
-
this.touchInputToggleIcon = this.touchInputToggle.appendChild(
|
|
678
|
+
this.touchInputToggleIcon = this.touchInputToggle.appendChild(createIcon('touch-app'));
|
|
679
679
|
UI.ARIAUtils.setLabel(this.touchInputToggle, i18nString(UIStrings.touchInput));
|
|
680
680
|
|
|
681
681
|
this.navigationProgressBar = new ProgressTracker(
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
5
|
import '../../ui/legacy/legacy.js';
|
|
6
|
-
import '../../ui/
|
|
6
|
+
import '../../ui/kit/kit.js';
|
|
7
7
|
|
|
8
8
|
import * as Common from '../../core/common/common.js';
|
|
9
9
|
import * as Host from '../../core/host/host.js';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
// Copyright 2024 The Chromium Authors
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
|
-
import
|
|
4
|
+
import {createIcon} from '../../ui/kit/kit.js';
|
|
5
5
|
|
|
6
6
|
import {SecurityPanelSidebarTreeElement} from './SecurityPanelSidebarTreeElement.js';
|
|
7
7
|
|
|
8
8
|
export class CookieControlsTreeElement extends SecurityPanelSidebarTreeElement {
|
|
9
9
|
constructor(title: string, jslogContext: string|number) {
|
|
10
10
|
super(title, false, jslogContext);
|
|
11
|
-
this.setLeadingIcons([
|
|
11
|
+
this.setLeadingIcons([createIcon('gear', 'cookie-icon')]);
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
override get elemId(): string {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
5
|
import '../../ui/components/switch/switch.js';
|
|
6
|
-
import '../../ui/
|
|
6
|
+
import '../../ui/kit/kit.js';
|
|
7
7
|
import '../../ui/components/chrome_link/chrome_link.js';
|
|
8
8
|
|
|
9
9
|
import * as Common from '../../core/common/common.js';
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
// Copyright 2024 The Chromium Authors
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
|
-
import
|
|
4
|
+
import {createIcon} from '../../ui/kit/kit.js';
|
|
5
5
|
|
|
6
6
|
import {SecurityPanelSidebarTreeElement} from './SecurityPanelSidebarTreeElement.js';
|
|
7
7
|
|
|
8
8
|
export class CookieReportTreeElement extends SecurityPanelSidebarTreeElement {
|
|
9
9
|
constructor(title: string, jslogContext: string|number) {
|
|
10
10
|
super(title, false, jslogContext);
|
|
11
|
-
this.setLeadingIcons([
|
|
11
|
+
this.setLeadingIcons([createIcon('cookie', 'cookie-icon')]);
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
override get elemId(): string {
|
|
@@ -10,7 +10,7 @@ import type * as Platform from '../../core/platform/platform.js';
|
|
|
10
10
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
11
11
|
import * as Protocol from '../../generated/protocol.js';
|
|
12
12
|
import * as NetworkForward from '../../panels/network/forward/forward.js';
|
|
13
|
-
import
|
|
13
|
+
import {createIcon, type Icon} from '../../ui/kit/kit.js';
|
|
14
14
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
15
15
|
import {html, render} from '../../ui/lit/lit.js';
|
|
16
16
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
@@ -470,7 +470,7 @@ const WARNING_ICON_NAME = 'warning';
|
|
|
470
470
|
const UNKNOWN_ICON_NAME = 'indeterminate-question-box';
|
|
471
471
|
|
|
472
472
|
export function getSecurityStateIconForDetailedView(
|
|
473
|
-
securityState: Protocol.Security.SecurityState, className: string):
|
|
473
|
+
securityState: Protocol.Security.SecurityState, className: string): Icon {
|
|
474
474
|
let iconName: string;
|
|
475
475
|
|
|
476
476
|
switch (securityState) {
|
|
@@ -488,11 +488,11 @@ export function getSecurityStateIconForDetailedView(
|
|
|
488
488
|
break;
|
|
489
489
|
}
|
|
490
490
|
|
|
491
|
-
return
|
|
491
|
+
return createIcon(iconName, className);
|
|
492
492
|
}
|
|
493
493
|
|
|
494
494
|
export function getSecurityStateIconForOverview(
|
|
495
|
-
securityState: Protocol.Security.SecurityState, className: string):
|
|
495
|
+
securityState: Protocol.Security.SecurityState, className: string): Icon {
|
|
496
496
|
let iconName: string;
|
|
497
497
|
switch (securityState) {
|
|
498
498
|
case Protocol.Security.SecurityState.Unknown: // fallthrough
|
|
@@ -509,7 +509,7 @@ export function getSecurityStateIconForOverview(
|
|
|
509
509
|
case Protocol.Security.SecurityState.Info:
|
|
510
510
|
throw new Error(`Unexpected security state ${securityState}`);
|
|
511
511
|
}
|
|
512
|
-
return
|
|
512
|
+
return createIcon(iconName, className);
|
|
513
513
|
}
|
|
514
514
|
|
|
515
515
|
export function createHighlightedUrl(url: Platform.DevToolsPath.UrlString, securityState: string): Element {
|
|
@@ -8,7 +8,7 @@ import * as i18n from '../../core/i18n/i18n.js';
|
|
|
8
8
|
import * as Platform from '../../core/platform/platform.js';
|
|
9
9
|
import * as Root from '../../core/root/root.js';
|
|
10
10
|
import * as Protocol from '../../generated/protocol.js';
|
|
11
|
-
import type
|
|
11
|
+
import type {Icon} from '../../ui/kit/kit.js';
|
|
12
12
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
13
13
|
|
|
14
14
|
import {CookieControlsTreeElement} from './CookieControlsTreeElement.js';
|
|
@@ -73,7 +73,7 @@ const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
|
73
73
|
export class SecurityPanelSidebar extends UI.Widget.VBox {
|
|
74
74
|
readonly #securitySidebarLastItemSetting: Common.Settings.Setting<string>;
|
|
75
75
|
readonly sidebarTree: UI.TreeOutline.TreeOutlineInShadow;
|
|
76
|
-
readonly #originGroupTitles: Map<OriginGroup, {title: string, icon?:
|
|
76
|
+
readonly #originGroupTitles: Map<OriginGroup, {title: string, icon?: Icon}>;
|
|
77
77
|
#originGroups: Map<OriginGroup, UI.TreeOutline.TreeElement>;
|
|
78
78
|
securityOverviewElement: OriginTreeElement;
|
|
79
79
|
readonly #cookieControlsTreeElement: CookieControlsTreeElement|undefined;
|
|
@@ -204,8 +204,7 @@ export class SecurityPanelSidebar extends UI.Widget.VBox {
|
|
|
204
204
|
return this.#originGroups.get(originGroup) as UI.TreeOutline.TreeElement;
|
|
205
205
|
}
|
|
206
206
|
|
|
207
|
-
#createOriginGroupElement(originGroupTitle: string, originGroupIcon?:
|
|
208
|
-
UI.TreeOutline.TreeElement {
|
|
207
|
+
#createOriginGroupElement(originGroupTitle: string, originGroupIcon?: Icon): UI.TreeOutline.TreeElement {
|
|
209
208
|
const originGroup = new UI.TreeOutline.TreeElement(originGroupTitle, true);
|
|
210
209
|
originGroup.selectable = false;
|
|
211
210
|
originGroup.expand();
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
5
5
|
|
|
6
|
-
import '../../ui/
|
|
6
|
+
import '../../ui/kit/kit.js';
|
|
7
7
|
|
|
8
8
|
import * as Common from '../../core/common/common.js';
|
|
9
9
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
5
5
|
|
|
6
|
-
import '../../ui/
|
|
6
|
+
import '../../ui/kit/kit.js';
|
|
7
7
|
|
|
8
8
|
import * as Common from '../../core/common/common.js';
|
|
9
9
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
@@ -3,14 +3,14 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
5
5
|
|
|
6
|
-
import '../../ui/
|
|
6
|
+
import '../../ui/kit/kit.js';
|
|
7
7
|
|
|
8
8
|
import * as Common from '../../core/common/common.js';
|
|
9
9
|
import * as Host from '../../core/host/host.js';
|
|
10
10
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
11
11
|
import * as Platform from '../../core/platform/platform.js';
|
|
12
12
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
13
|
-
import
|
|
13
|
+
import {createIcon, type Icon} from '../../ui/kit/kit.js';
|
|
14
14
|
import * as SettingsUI from '../../ui/legacy/components/settings_ui/settings_ui.js';
|
|
15
15
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
16
16
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
@@ -383,7 +383,7 @@ export class ShortcutListItem {
|
|
|
383
383
|
|
|
384
384
|
private createEmptyInfo(): void {
|
|
385
385
|
if (UI.ShortcutRegistry.ShortcutRegistry.instance().actionHasDefaultShortcut(this.item.id())) {
|
|
386
|
-
const icon =
|
|
386
|
+
const icon = createIcon('keyboard-pen', 'keybinds-modified');
|
|
387
387
|
UI.ARIAUtils.setLabel(icon, i18nString(UIStrings.shortcutModified));
|
|
388
388
|
this.element.appendChild(icon);
|
|
389
389
|
}
|
|
@@ -441,9 +441,9 @@ export class ShortcutListItem {
|
|
|
441
441
|
if (this.editedShortcuts.has(shortcut) && !this.editedShortcuts.get(shortcut)) {
|
|
442
442
|
return;
|
|
443
443
|
}
|
|
444
|
-
let icon:
|
|
444
|
+
let icon: Icon;
|
|
445
445
|
if (shortcut.type !== UI.KeyboardShortcut.Type.UNSET_SHORTCUT && !shortcut.isDefault()) {
|
|
446
|
-
icon =
|
|
446
|
+
icon = createIcon('keyboard-pen', 'keybinds-modified');
|
|
447
447
|
UI.ARIAUtils.setLabel(icon, i18nString(UIStrings.shortcutModified));
|
|
448
448
|
this.element.appendChild(icon);
|
|
449
449
|
}
|
|
@@ -5,16 +5,15 @@
|
|
|
5
5
|
|
|
6
6
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
7
7
|
|
|
8
|
-
import '../../ui/
|
|
8
|
+
import '../../ui/kit/kit.js';
|
|
9
9
|
|
|
10
10
|
import * as Common from '../../core/common/common.js';
|
|
11
11
|
import * as Host from '../../core/host/host.js';
|
|
12
12
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
13
13
|
import * as Root from '../../core/root/root.js';
|
|
14
14
|
import * as Buttons from '../../ui/components/buttons/buttons.js';
|
|
15
|
-
import type * as Cards from '../../ui/components/cards/cards.js';
|
|
16
|
-
import * as IconButton from '../../ui/components/icon_button/icon_button.js';
|
|
17
15
|
import * as UIHelpers from '../../ui/helpers/helpers.js';
|
|
16
|
+
import {type Card, createIcon} from '../../ui/kit/kit.js';
|
|
18
17
|
import * as SettingsUI from '../../ui/legacy/components/settings_ui/settings_ui.js';
|
|
19
18
|
import * as Components from '../../ui/legacy/components/utils/utils.js';
|
|
20
19
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
@@ -83,7 +82,7 @@ const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
|
|
|
83
82
|
|
|
84
83
|
let settingsScreenInstance: SettingsScreen;
|
|
85
84
|
|
|
86
|
-
function createSettingsCard(heading: Common.UIString.LocalizedString, ...content: HTMLElement[]):
|
|
85
|
+
function createSettingsCard(heading: Common.UIString.LocalizedString, ...content: HTMLElement[]): Card {
|
|
87
86
|
const card = document.createElement('devtools-card');
|
|
88
87
|
card.heading = heading;
|
|
89
88
|
card.append(...content);
|
|
@@ -382,8 +381,8 @@ export class GenericSettingsTab extends UI.Widget.VBox implements SettingsTab {
|
|
|
382
381
|
}
|
|
383
382
|
|
|
384
383
|
export class ExperimentsSettingsTab extends UI.Widget.VBox implements SettingsTab {
|
|
385
|
-
#experimentsSection:
|
|
386
|
-
#unstableExperimentsSection:
|
|
384
|
+
#experimentsSection: Card|undefined;
|
|
385
|
+
#unstableExperimentsSection: Card|undefined;
|
|
387
386
|
private readonly experimentToControl = new Map<Root.Runtime.Experiment, HTMLElement>();
|
|
388
387
|
private readonly containerElement: HTMLElement;
|
|
389
388
|
|
|
@@ -460,7 +459,7 @@ export class ExperimentsSettingsTab extends UI.Widget.VBox implements SettingsTa
|
|
|
460
459
|
private createExperimentsWarningSubsection(warningMessage: string): HTMLElement {
|
|
461
460
|
const subsection = document.createElement('div');
|
|
462
461
|
subsection.classList.add('experiments-warning-subsection');
|
|
463
|
-
const warningIcon =
|
|
462
|
+
const warningIcon = createIcon('warning');
|
|
464
463
|
subsection.appendChild(warningIcon);
|
|
465
464
|
const warning = subsection.createChild('span');
|
|
466
465
|
warning.textContent = warningMessage;
|
|
@@ -581,7 +580,7 @@ export class Revealer implements Common.Revealer.Revealer<Root.Runtime.Experimen
|
|
|
581
580
|
}
|
|
582
581
|
|
|
583
582
|
// Reveal settings views
|
|
584
|
-
for (const view of UI.ViewManager.getRegisteredViewExtensions()) {
|
|
583
|
+
for (const view of UI.ViewManager.ViewManager.instance().getRegisteredViewExtensions()) {
|
|
585
584
|
const id = view.viewId();
|
|
586
585
|
const location = view.location();
|
|
587
586
|
if (location !== UI.ViewManager.ViewLocationValues.SETTINGS_VIEW) {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
import '../../ui/legacy/legacy.js';
|
|
6
6
|
import '../../ui/components/buttons/buttons.js';
|
|
7
|
-
import '../../ui/
|
|
7
|
+
import '../../ui/kit/kit.js';
|
|
8
8
|
|
|
9
9
|
import * as Common from '../../core/common/common.js';
|
|
10
10
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
/* eslint-disable @devtools/no-imperative-dom-api */
|
|
5
5
|
|
|
6
|
-
import '../../../ui/
|
|
6
|
+
import '../../../ui/kit/kit.js';
|
|
7
7
|
|
|
8
8
|
import * as i18n from '../../../core/i18n/i18n.js';
|
|
9
9
|
import * as EmulationModel from '../../../models/emulation/emulation.js';
|
|
@@ -2,10 +2,13 @@
|
|
|
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 '../../ui/kit/kit.js';
|
|
6
|
+
import '../../ui/components/highlighting/highlighting.js';
|
|
7
|
+
|
|
5
8
|
import * as i18n from '../../core/i18n/i18n.js';
|
|
6
9
|
import type * as Workspace from '../../models/workspace/workspace.js';
|
|
7
|
-
import * as IconButton from '../../ui/components/icon_button/icon_button.js';
|
|
8
10
|
import * as QuickOpen from '../../ui/legacy/components/quick_open/quick_open.js';
|
|
11
|
+
import {html, type TemplateResult} from '../../ui/lit/lit.js';
|
|
9
12
|
|
|
10
13
|
import {evaluateScriptSnippet, findSnippetsProject} from './ScriptSnippetFileSystem.js';
|
|
11
14
|
|
|
@@ -81,11 +84,18 @@ export class SnippetsQuickOpen extends QuickOpen.FilteredListWidget.Provider {
|
|
|
81
84
|
return this.snippets[itemIndex].name();
|
|
82
85
|
}
|
|
83
86
|
|
|
84
|
-
override renderItem(itemIndex: number, query: string
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
87
|
+
override renderItem(itemIndex: number, query: string): TemplateResult {
|
|
88
|
+
// clang-format off
|
|
89
|
+
const snippet = this.snippets[itemIndex].name();
|
|
90
|
+
const highlightRanges = QuickOpen.FilteredListWidget.FilteredListWidget.getHighlightRanges(snippet, query, true);
|
|
91
|
+
return html`
|
|
92
|
+
<devtools-icon class="snippet" name="snippet"></devtools-icon>
|
|
93
|
+
<div>
|
|
94
|
+
<devtools-highlight type="markup" ranges=${highlightRanges}>
|
|
95
|
+
${snippet}
|
|
96
|
+
</devtools-highlight>
|
|
97
|
+
</div>`;
|
|
98
|
+
// clang-format on
|
|
89
99
|
}
|
|
90
100
|
}
|
|
91
101
|
|
|
@@ -10,8 +10,8 @@ import * as i18n from '../../core/i18n/i18n.js';
|
|
|
10
10
|
import * as SDK from '../../core/sdk/sdk.js';
|
|
11
11
|
import type * as BreakpointManager from '../../models/breakpoints/breakpoints.js';
|
|
12
12
|
import * as CodeMirror from '../../third_party/codemirror.next/codemirror.next.js';
|
|
13
|
-
import * as IconButton from '../../ui/components/icon_button/icon_button.js';
|
|
14
13
|
import * as TextEditor from '../../ui/components/text_editor/text_editor.js';
|
|
14
|
+
import {createIcon} from '../../ui/kit/kit.js';
|
|
15
15
|
import * as UI from '../../ui/legacy/legacy.js';
|
|
16
16
|
import * as VisualLogging from '../../ui/visual_logging/visual_logging.js';
|
|
17
17
|
|
|
@@ -181,7 +181,7 @@ export class BreakpointEditDialog extends UI.Widget.Widget {
|
|
|
181
181
|
}));
|
|
182
182
|
editorWrapper.appendChild(this.editor);
|
|
183
183
|
|
|
184
|
-
const closeIcon =
|
|
184
|
+
const closeIcon = createIcon('cross');
|
|
185
185
|
closeIcon.title = i18nString(UIStrings.closeDialog);
|
|
186
186
|
closeIcon.setAttribute('jslog', `${VisualLogging.close().track({click: true})}`);
|
|
187
187
|
closeIcon.onclick = () => this.finishEditing(true, this.editor.state.doc.toString());
|
|
@@ -196,7 +196,7 @@ export class BreakpointEditDialog extends UI.Widget.Widget {
|
|
|
196
196
|
const link = UI.Fragment.html`<x-link class="link devtools-link" tabindex="0" href="https://goo.gle/devtools-loc"
|
|
197
197
|
jslog="${VisualLogging.link('learn-more')}">${
|
|
198
198
|
i18nString(UIStrings.learnMoreOnBreakpointTypes)}</x-link>` as UI.XLink.XLink;
|
|
199
|
-
const linkIcon =
|
|
199
|
+
const linkIcon = createIcon('open-externally', 'link-icon');
|
|
200
200
|
link.prepend(linkIcon);
|
|
201
201
|
linkWrapper.appendChild(link);
|
|
202
202
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// Use of this source code is governed by a BSD-style license that can be
|
|
3
3
|
// found in the LICENSE file.
|
|
4
4
|
|
|
5
|
-
import '../../ui/
|
|
5
|
+
import '../../ui/kit/kit.js';
|
|
6
6
|
|
|
7
7
|
import * as Common from '../../core/common/common.js';
|
|
8
8
|
import * as Host from '../../core/host/host.js';
|