chrome-devtools-frontend 1.0.951864 → 1.0.952784

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.
Files changed (175) hide show
  1. package/config/gni/devtools_grd_files.gni +3 -0
  2. package/front_end/.eslintrc.js +6 -0
  3. package/front_end/core/host/UserMetrics.ts +2 -1
  4. package/front_end/core/i18n/locales/en-US.json +3 -0
  5. package/front_end/core/i18n/locales/en-XL.json +3 -0
  6. package/front_end/core/root/Runtime.ts +4 -12
  7. package/front_end/core/sdk/PageResourceLoader.ts +2 -1
  8. package/front_end/entrypoints/formatter_worker/AcornTokenizer.ts +39 -39
  9. package/front_end/entrypoints/formatter_worker/CSSFormatter.ts +54 -54
  10. package/front_end/entrypoints/formatter_worker/ESTreeWalker.ts +20 -20
  11. package/front_end/entrypoints/formatter_worker/FormattedContentBuilder.ts +54 -54
  12. package/front_end/entrypoints/formatter_worker/HTMLFormatter.ts +145 -144
  13. package/front_end/entrypoints/formatter_worker/JavaScriptFormatter.ts +40 -40
  14. package/front_end/entrypoints/heap_snapshot_worker/AllocationProfile.ts +64 -69
  15. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshot.ts +202 -200
  16. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotLoader.ts +109 -108
  17. package/front_end/entrypoints/heap_snapshot_worker/HeapSnapshotWorkerDispatcher.ts +17 -17
  18. package/front_end/entrypoints/inspector_main/InspectorMain.ts +30 -30
  19. package/front_end/entrypoints/inspector_main/RenderingOptions.ts +25 -25
  20. package/front_end/entrypoints/main/ExecutionContextSelector.ts +52 -55
  21. package/front_end/entrypoints/main/MainImpl.ts +49 -49
  22. package/front_end/entrypoints/node_app/NodeConnectionsPanel.ts +43 -43
  23. package/front_end/entrypoints/node_app/NodeMain.ts +38 -38
  24. package/front_end/generated/InspectorBackendCommands.js +5 -1
  25. package/front_end/generated/protocol.d.ts +16 -0
  26. package/front_end/legacy/legacy-defs.d.ts +0 -21
  27. package/front_end/models/heap_snapshot_model/HeapSnapshotModel.ts +1 -1
  28. package/front_end/models/issues_manager/ClientHintIssue.ts +95 -0
  29. package/front_end/models/issues_manager/ContentSecurityPolicyIssue.ts +6 -6
  30. package/front_end/models/issues_manager/ContrastCheckTrigger.ts +15 -15
  31. package/front_end/models/issues_manager/CorsIssue.ts +9 -9
  32. package/front_end/models/issues_manager/CrossOriginEmbedderPolicyIssue.ts +5 -5
  33. package/front_end/models/issues_manager/DeprecationIssue.ts +7 -7
  34. package/front_end/models/issues_manager/GenericIssue.ts +5 -5
  35. package/front_end/models/issues_manager/HeavyAdIssue.ts +5 -5
  36. package/front_end/models/issues_manager/Issue.ts +10 -10
  37. package/front_end/models/issues_manager/IssueResolver.ts +11 -10
  38. package/front_end/models/issues_manager/IssuesManager.ts +61 -56
  39. package/front_end/models/issues_manager/LowTextContrastIssue.ts +4 -4
  40. package/front_end/models/issues_manager/MixedContentIssue.ts +7 -7
  41. package/front_end/models/issues_manager/NavigatorUserAgentIssue.ts +7 -7
  42. package/front_end/models/issues_manager/QuirksModeIssue.ts +4 -4
  43. package/front_end/models/issues_manager/SameSiteCookieIssue.ts +16 -16
  44. package/front_end/models/issues_manager/SharedArrayBufferIssue.ts +5 -5
  45. package/front_end/models/issues_manager/SourceFrameIssuesManager.ts +32 -31
  46. package/front_end/models/issues_manager/TrustedWebActivityIssue.ts +5 -5
  47. package/front_end/models/issues_manager/WasmCrossOriginModuleSharingIssue.ts +5 -5
  48. package/front_end/models/issues_manager/descriptions/clientHintMetaTagAllowListInvalidOrigin.md +4 -0
  49. package/front_end/models/issues_manager/descriptions/clientHintMetaTagModifiedHTML.md +4 -0
  50. package/front_end/models/issues_manager/issues_manager.ts +2 -0
  51. package/front_end/panels/application/components/BackForwardCacheView.ts +33 -33
  52. package/front_end/panels/application/components/EndpointsGrid.ts +12 -12
  53. package/front_end/panels/application/components/FrameDetailsView.ts +108 -110
  54. package/front_end/panels/application/components/OriginTrialTreeView.ts +45 -45
  55. package/front_end/panels/application/components/PermissionsPolicySection.ts +19 -19
  56. package/front_end/panels/application/components/ReportsGrid.ts +30 -30
  57. package/front_end/panels/application/components/StackTrace.ts +48 -47
  58. package/front_end/panels/application/components/TrustTokensView.ts +31 -31
  59. package/front_end/panels/console/ConsoleView.ts +1 -1
  60. package/front_end/panels/css_overview/CSSOverviewCompletedView.ts +41 -52
  61. package/front_end/panels/css_overview/CSSOverviewController.ts +2 -2
  62. package/front_end/panels/css_overview/CSSOverviewPanel.ts +18 -27
  63. package/front_end/panels/css_overview/CSSOverviewProcessingView.ts +2 -2
  64. package/front_end/panels/css_overview/CSSOverviewSidebarPanel.ts +6 -6
  65. package/front_end/panels/css_overview/components/CSSOverviewStartView.ts +4 -4
  66. package/front_end/panels/elements/components/AccessibilityTreeNode.ts +17 -17
  67. package/front_end/panels/elements/components/AdornerManager.ts +21 -21
  68. package/front_end/panels/elements/components/AdornerSettingsPane.ts +14 -14
  69. package/front_end/panels/elements/components/CSSQuery.ts +16 -16
  70. package/front_end/panels/elements/components/ComputedStyleProperty.ts +14 -14
  71. package/front_end/panels/elements/components/ComputedStyleTrace.ts +15 -15
  72. package/front_end/panels/elements/components/ElementsBreadcrumbs.ts +78 -78
  73. package/front_end/panels/elements/components/ElementsPanelLink.ts +16 -16
  74. package/front_end/panels/elements/components/LayoutPane.ts +47 -47
  75. package/front_end/panels/elements/components/NodeText.ts +18 -18
  76. package/front_end/panels/elements/components/QueryContainer.ts +40 -40
  77. package/front_end/panels/elements/components/StylePropertyEditor.ts +18 -18
  78. package/front_end/panels/emulation/components/DeviceSizeInputElement.ts +4 -4
  79. package/front_end/panels/issues/AffectedBlockedByResponseView.ts +4 -4
  80. package/front_end/panels/issues/AffectedCookiesView.ts +4 -5
  81. package/front_end/panels/issues/AffectedDirectivesView.ts +19 -19
  82. package/front_end/panels/issues/AffectedDocumentsInQuirksModeView.ts +7 -8
  83. package/front_end/panels/issues/AffectedElementsView.ts +4 -4
  84. package/front_end/panels/issues/AffectedElementsWithLowContrastView.ts +7 -8
  85. package/front_end/panels/issues/AffectedHeavyAdView.ts +8 -8
  86. package/front_end/panels/issues/AffectedResourcesView.ts +25 -26
  87. package/front_end/panels/issues/AffectedSharedArrayBufferIssueDetailsView.ts +8 -8
  88. package/front_end/panels/issues/AffectedSourcesView.ts +4 -4
  89. package/front_end/panels/issues/AffectedTrustedWebActivityIssueDetailsView.ts +4 -4
  90. package/front_end/panels/issues/AttributionReportingIssueDetailsView.ts +17 -17
  91. package/front_end/panels/issues/CSPViolationsListView.ts +22 -23
  92. package/front_end/panels/issues/CSPViolationsView.ts +17 -17
  93. package/front_end/panels/issues/ComboBoxOfCheckBoxes.ts +13 -13
  94. package/front_end/panels/issues/CorsIssueDetailsView.ts +23 -23
  95. package/front_end/panels/issues/GenericIssueDetailsView.ts +4 -4
  96. package/front_end/panels/issues/HiddenIssuesRow.ts +7 -7
  97. package/front_end/panels/issues/IssueAggregator.ts +95 -95
  98. package/front_end/panels/issues/IssueKindView.ts +14 -14
  99. package/front_end/panels/issues/IssueView.ts +98 -98
  100. package/front_end/panels/issues/IssuesPane.ts +102 -102
  101. package/front_end/panels/issues/WasmCrossOriginModuleSharingAffectedResourcesView.ts +5 -5
  102. package/front_end/panels/issues/components/HideIssuesMenu.ts +10 -10
  103. package/front_end/panels/media/PlayerListView.ts +160 -97
  104. package/front_end/panels/media/PlayerMessagesView.ts +1 -0
  105. package/front_end/panels/media/playerListView.css +58 -0
  106. package/front_end/panels/network/NetworkLogView.ts +2 -6
  107. package/front_end/panels/network/NetworkWaterfallColumn.ts +2 -4
  108. package/front_end/panels/network/components/RequestTrustTokensView.ts +40 -40
  109. package/front_end/panels/network/components/WebBundleInfoView.ts +9 -9
  110. package/front_end/panels/performance_monitor/PerformanceMonitor.ts +92 -37
  111. package/front_end/panels/performance_monitor/performanceMonitor.css +32 -0
  112. package/front_end/panels/protocol_monitor/ProtocolMonitor.ts +2 -2
  113. package/front_end/panels/settings/components/SyncSection.ts +14 -14
  114. package/front_end/panels/settings/emulation/components/UserAgentClientHintsForm.ts +96 -96
  115. package/front_end/panels/sources/BreakpointEditDialog.ts +4 -3
  116. package/front_end/panels/timeline/TimelineFlameChartView.ts +1 -1
  117. package/front_end/panels/timeline/TimelineTreeView.ts +1 -1
  118. package/front_end/panels/timeline/components/WebVitalsLane.ts +77 -76
  119. package/front_end/panels/timeline/components/WebVitalsTimeline.ts +133 -133
  120. package/front_end/panels/timeline/components/WebVitalsTooltip.ts +9 -9
  121. package/front_end/panels/webauthn/WebauthnPane.ts +203 -205
  122. package/front_end/third_party/diff/DiffWrapper.ts +7 -0
  123. package/front_end/ui/components/adorners/Adorner.ts +2 -2
  124. package/front_end/ui/components/buttons/Button.ts +9 -9
  125. package/front_end/ui/components/data_grid/DataGrid.ts +64 -64
  126. package/front_end/ui/components/data_grid/DataGridController.ts +22 -22
  127. package/front_end/ui/components/data_grid/DataGridUtils.ts +3 -0
  128. package/front_end/ui/components/diff_view/DiffView.ts +6 -6
  129. package/front_end/ui/components/expandable_list/ExpandableList.ts +5 -5
  130. package/front_end/ui/components/icon_button/Icon.ts +4 -4
  131. package/front_end/ui/components/icon_button/IconButton.ts +4 -4
  132. package/front_end/ui/components/issue_counter/IssueCounter.ts +3 -3
  133. package/front_end/ui/components/issue_counter/IssueLinkIcon.ts +11 -11
  134. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspector.ts +50 -50
  135. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorController.ts +6 -6
  136. package/front_end/ui/components/linear_memory_inspector/LinearMemoryInspectorPane.ts +4 -4
  137. package/front_end/ui/components/linear_memory_inspector/LinearMemoryNavigator.ts +12 -12
  138. package/front_end/ui/components/linear_memory_inspector/LinearMemoryValueInterpreter.ts +11 -11
  139. package/front_end/ui/components/linear_memory_inspector/LinearMemoryViewer.ts +40 -39
  140. package/front_end/ui/components/linear_memory_inspector/ValueInterpreterDisplay.ts +18 -18
  141. package/front_end/ui/components/linear_memory_inspector/ValueInterpreterSettings.ts +6 -6
  142. package/front_end/ui/components/linkifier/LinkifierImpl.ts +4 -4
  143. package/front_end/ui/components/markdown_view/MarkdownImage.ts +5 -5
  144. package/front_end/ui/components/markdown_view/MarkdownLink.ts +2 -2
  145. package/front_end/ui/components/markdown_view/MarkdownView.ts +4 -4
  146. package/front_end/ui/components/panel_feedback/FeedbackButton.ts +2 -2
  147. package/front_end/ui/components/panel_feedback/PanelFeedback.ts +2 -2
  148. package/front_end/ui/components/panel_feedback/PreviewToggle.ts +4 -4
  149. package/front_end/ui/components/render_coordinator/RenderCoordinator.ts +22 -22
  150. package/front_end/ui/components/report_view/ReportView.ts +16 -16
  151. package/front_end/ui/components/request_link_icon/RequestLinkIcon.ts +14 -14
  152. package/front_end/ui/components/settings/SettingCheckbox.ts +5 -5
  153. package/front_end/ui/components/survey_link/SurveyLink.ts +8 -8
  154. package/front_end/ui/components/text_editor/TextEditor.ts +9 -9
  155. package/front_end/ui/components/text_prompt/TextPrompt.ts +18 -18
  156. package/front_end/ui/components/tree_outline/TreeOutline.ts +69 -70
  157. package/front_end/ui/legacy/SearchableView.ts +13 -4
  158. package/front_end/ui/legacy/components/source_frame/JSONView.ts +1 -1
  159. package/front_end/ui/legacy/components/source_frame/SourceFrame.ts +13 -12
  160. package/front_end/ui/legacy/components/source_frame/XMLView.ts +2 -2
  161. package/front_end/ui/legacy/themeColors.css +2 -0
  162. package/front_end/ui/legacy/theme_support/theme_support_impl.ts +34 -7
  163. package/package.json +1 -1
  164. package/scripts/eslint_rules/lib/use_private_class_members.js +41 -0
  165. package/scripts/eslint_rules/tests/use_private_class_members_test.js +62 -0
  166. package/scripts/migration/class-fields/migrate.js +2 -3
  167. package/scripts/migration/class-fields/migrate.sh +1 -3
  168. package/scripts/migration/class-fields/package.json +1 -1
  169. package/config/gni/all_devtools_files.gni +0 -255
  170. package/scripts/build/devtools_file_hashes.py +0 -82
  171. package/scripts/devtools_run/devtools_run_cli +0 -49
  172. package/scripts/devtools_run/package.json +0 -13
  173. package/scripts/unzip.py +0 -20
  174. package/scripts/visualize_deps/jquery_svg.html +0 -57
  175. package/scripts/visualize_deps/run_visualize.js +0 -119
@@ -218,77 +218,77 @@ export class RenderingOptionsView extends UI.Widget.VBox {
218
218
  private constructor() {
219
219
  super(true);
220
220
 
221
- this.appendCheckbox(
221
+ this.#appendCheckbox(
222
222
  i18nString(UIStrings.paintFlashing), i18nString(UIStrings.highlightsAreasOfThePageGreen),
223
223
  Common.Settings.Settings.instance().moduleSetting('showPaintRects'));
224
- this.appendCheckbox(
224
+ this.#appendCheckbox(
225
225
  i18nString(UIStrings.layoutShiftRegions), i18nString(UIStrings.highlightsAreasOfThePageBlueThat),
226
226
  Common.Settings.Settings.instance().moduleSetting('showLayoutShiftRegions'));
227
- this.appendCheckbox(
227
+ this.#appendCheckbox(
228
228
  i18nString(UIStrings.layerBorders), i18nString(UIStrings.showsLayerBordersOrangeoliveAnd),
229
229
  Common.Settings.Settings.instance().moduleSetting('showDebugBorders'));
230
- this.appendCheckbox(
230
+ this.#appendCheckbox(
231
231
  i18nString(UIStrings.frameRenderingStats), i18nString(UIStrings.plotsFrameThroughputDropped),
232
232
  Common.Settings.Settings.instance().moduleSetting('showFPSCounter'));
233
- this.appendCheckbox(
233
+ this.#appendCheckbox(
234
234
  i18nString(UIStrings.scrollingPerformanceIssues), i18nString(UIStrings.highlightsElementsTealThatCan),
235
235
  Common.Settings.Settings.instance().moduleSetting('showScrollBottleneckRects'));
236
- this.appendCheckbox(
236
+ this.#appendCheckbox(
237
237
  i18nString(UIStrings.highlightAdFrames), i18nString(UIStrings.highlightsFramesRedDetectedToBe),
238
238
  Common.Settings.Settings.instance().moduleSetting('showAdHighlights'));
239
- this.appendCheckbox(
239
+ this.#appendCheckbox(
240
240
  i18nString(UIStrings.coreWebVitals), i18nString(UIStrings.showsAnOverlayWithCoreWebVitals),
241
241
  Common.Settings.Settings.instance().moduleSetting('showWebVitals'));
242
- this.appendCheckbox(
242
+ this.#appendCheckbox(
243
243
  i18nString(UIStrings.disableLocalFonts), i18nString(UIStrings.disablesLocalSourcesInFontface),
244
244
  Common.Settings.Settings.instance().moduleSetting('localFontsDisabled'));
245
- this.appendCheckbox(
245
+ this.#appendCheckbox(
246
246
  i18nString(UIStrings.emulateAFocusedPage), i18nString(UIStrings.emulatesAFocusedPage),
247
247
  Common.Settings.Settings.instance().moduleSetting('emulatePageFocus'));
248
248
  this.contentElement.createChild('div').classList.add('panel-section-separator');
249
249
 
250
- this.appendSelect(
250
+ this.#appendSelect(
251
251
  i18nString(UIStrings.forcesMediaTypeForTestingPrint),
252
252
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMedia'));
253
- this.appendSelect(
253
+ this.#appendSelect(
254
254
  i18nString(UIStrings.forcesCssPreferscolorschemeMedia),
255
255
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeaturePrefersColorScheme'));
256
- this.appendSelect(
256
+ this.#appendSelect(
257
257
  i18nString(UIStrings.forcesCssForcedColors),
258
258
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeatureForcedColors'));
259
259
  if (supportsPrefersContrast()) {
260
- this.appendSelect(
260
+ this.#appendSelect(
261
261
  i18nString(UIStrings.forcesCssPreferscontrastMedia),
262
262
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeaturePrefersContrast'));
263
263
  }
264
- this.appendSelect(
264
+ this.#appendSelect(
265
265
  i18nString(UIStrings.forcesCssPrefersreducedmotion),
266
266
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeaturePrefersReducedMotion'));
267
267
  if (supportsPrefersReducedData()) {
268
- this.appendSelect(
268
+ this.#appendSelect(
269
269
  i18nString(UIStrings.forcesCssPrefersreduceddataMedia),
270
270
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeaturePrefersReducedData'));
271
271
  }
272
- this.appendSelect(
272
+ this.#appendSelect(
273
273
  i18nString(UIStrings.forcesCssColorgamutMediaFeature),
274
274
  Common.Settings.Settings.instance().moduleSetting('emulatedCSSMediaFeatureColorGamut'));
275
275
  this.contentElement.createChild('div').classList.add('panel-section-separator');
276
276
 
277
- this.appendSelect(
277
+ this.#appendSelect(
278
278
  i18nString(UIStrings.forcesVisionDeficiencyEmulation),
279
279
  Common.Settings.Settings.instance().moduleSetting('emulatedVisionDeficiency'));
280
280
 
281
281
  this.contentElement.createChild('div').classList.add('panel-section-separator');
282
- this.appendSelect(
282
+ this.#appendSelect(
283
283
  i18nString(UIStrings.emulatesAutoDarkMode),
284
284
  Common.Settings.Settings.instance().moduleSetting('emulateAutoDarkMode'));
285
285
  this.contentElement.createChild('div').classList.add('panel-section-separator');
286
286
 
287
- this.appendCheckbox(
287
+ this.#appendCheckbox(
288
288
  i18nString(UIStrings.disableAvifImageFormat), i18nString(UIStrings.requiresAPageReloadToApplyAnd),
289
289
  Common.Settings.Settings.instance().moduleSetting('avifFormatDisabled'));
290
290
 
291
- const webpCheckbox = this.appendCheckbox(
291
+ const webpCheckbox = this.#appendCheckbox(
292
292
  i18nString(UIStrings.disableWebpImageFormat), i18nString(UIStrings.requiresAPageReloadToApplyAnd),
293
293
  Common.Settings.Settings.instance().moduleSetting('webpFormatDisabled'));
294
294
 
@@ -298,7 +298,7 @@ export class RenderingOptionsView extends UI.Widget.VBox {
298
298
  if (!hasSupport) {
299
299
  return;
300
300
  }
301
- webpCheckbox.before(this.createCheckbox(
301
+ webpCheckbox.before(this.#createCheckbox(
302
302
  i18nString(UIStrings.disableJpegXlImageFormat), i18nString(UIStrings.requiresAPageReloadToApplyAnd),
303
303
  Common.Settings.Settings.instance().moduleSetting('jpegXlFormatDisabled')));
304
304
  });
@@ -315,23 +315,23 @@ export class RenderingOptionsView extends UI.Widget.VBox {
315
315
  return renderingOptionsViewInstance;
316
316
  }
317
317
 
318
- private createCheckbox(label: string, subtitle: string, setting: Common.Settings.Setting<boolean>):
318
+ #createCheckbox(label: string, subtitle: string, setting: Common.Settings.Setting<boolean>):
319
319
  UI.UIUtils.CheckboxLabel {
320
320
  const checkboxLabel = UI.UIUtils.CheckboxLabel.create(label, false, subtitle);
321
321
  UI.SettingsUI.bindCheckbox(checkboxLabel.checkboxElement, setting);
322
322
  return checkboxLabel;
323
323
  }
324
324
 
325
- private appendCheckbox(label: string, subtitle: string, setting: Common.Settings.Setting<boolean>):
325
+ #appendCheckbox(label: string, subtitle: string, setting: Common.Settings.Setting<boolean>):
326
326
  UI.UIUtils.CheckboxLabel {
327
- const checkbox = this.createCheckbox(label, subtitle, setting);
327
+ const checkbox = this.#createCheckbox(label, subtitle, setting);
328
328
  this.contentElement.appendChild(checkbox);
329
329
  return checkbox;
330
330
  }
331
331
 
332
332
  // TODO(crbug.com/1172300) Ignored during the jsdoc to ts migration
333
333
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
334
- private appendSelect(label: string, setting: Common.Settings.Setting<any>): void {
334
+ #appendSelect(label: string, setting: Common.Settings.Setting<any>): void {
335
335
  const control = UI.SettingsUI.createControlForSetting(setting, label);
336
336
  if (control) {
337
337
  this.contentElement.appendChild(control);
@@ -7,26 +7,26 @@ import type * as Common from '../../core/common/common.js';
7
7
  import type * as UI from '../../ui/legacy/legacy.js';
8
8
 
9
9
  export class ExecutionContextSelector implements SDK.TargetManager.SDKModelObserver<SDK.RuntimeModel.RuntimeModel> {
10
- private targetManager: SDK.TargetManager.TargetManager;
11
- private context: UI.Context.Context;
12
- private lastSelectedContextId?: string;
13
- private ignoreContextChanged?: boolean;
10
+ #targetManager: SDK.TargetManager.TargetManager;
11
+ #context: UI.Context.Context;
12
+ #lastSelectedContextId?: string;
13
+ #ignoreContextChanged?: boolean;
14
14
 
15
15
  constructor(targetManager: SDK.TargetManager.TargetManager, context: UI.Context.Context) {
16
- context.addFlavorChangeListener(SDK.RuntimeModel.ExecutionContext, this.executionContextChanged, this);
17
- context.addFlavorChangeListener(SDK.Target.Target, this.targetChanged, this);
16
+ context.addFlavorChangeListener(SDK.RuntimeModel.ExecutionContext, this.#executionContextChanged, this);
17
+ context.addFlavorChangeListener(SDK.Target.Target, this.#targetChanged, this);
18
18
 
19
19
  targetManager.addModelListener(
20
- SDK.RuntimeModel.RuntimeModel, SDK.RuntimeModel.Events.ExecutionContextCreated, this.onExecutionContextCreated,
20
+ SDK.RuntimeModel.RuntimeModel, SDK.RuntimeModel.Events.ExecutionContextCreated, this.#onExecutionContextCreated,
21
21
  this);
22
22
  targetManager.addModelListener(
23
23
  SDK.RuntimeModel.RuntimeModel, SDK.RuntimeModel.Events.ExecutionContextDestroyed,
24
- this.onExecutionContextDestroyed, this);
24
+ this.#onExecutionContextDestroyed, this);
25
25
  targetManager.addModelListener(
26
26
  SDK.RuntimeModel.RuntimeModel, SDK.RuntimeModel.Events.ExecutionContextOrderChanged,
27
- this.onExecutionContextOrderChanged, this);
28
- this.targetManager = targetManager;
29
- this.context = context;
27
+ this.#onExecutionContextOrderChanged, this);
28
+ this.#targetManager = targetManager;
29
+ this.#context = context;
30
30
  targetManager.observeModels(SDK.RuntimeModel.RuntimeModel, this);
31
31
  }
32
32
 
@@ -37,41 +37,41 @@ export class ExecutionContextSelector implements SDK.TargetManager.SDKModelObser
37
37
 
38
38
  function deferred(this: ExecutionContextSelector): void {
39
39
  // We always want the second context for the service worker targets.
40
- if (!this.context.flavor(SDK.Target.Target)) {
41
- this.context.setFlavor(SDK.Target.Target, runtimeModel.target());
40
+ if (!this.#context.flavor(SDK.Target.Target)) {
41
+ this.#context.setFlavor(SDK.Target.Target, runtimeModel.target());
42
42
  }
43
43
  }
44
44
  }
45
45
 
46
46
  modelRemoved(runtimeModel: SDK.RuntimeModel.RuntimeModel): void {
47
- const currentExecutionContext = this.context.flavor(SDK.RuntimeModel.ExecutionContext);
47
+ const currentExecutionContext = this.#context.flavor(SDK.RuntimeModel.ExecutionContext);
48
48
  if (currentExecutionContext && currentExecutionContext.runtimeModel === runtimeModel) {
49
- this.currentExecutionContextGone();
49
+ this.#currentExecutionContextGone();
50
50
  }
51
51
 
52
- const models = this.targetManager.models(SDK.RuntimeModel.RuntimeModel);
53
- if (this.context.flavor(SDK.Target.Target) === runtimeModel.target() && models.length) {
54
- this.context.setFlavor(SDK.Target.Target, models[0].target());
52
+ const models = this.#targetManager.models(SDK.RuntimeModel.RuntimeModel);
53
+ if (this.#context.flavor(SDK.Target.Target) === runtimeModel.target() && models.length) {
54
+ this.#context.setFlavor(SDK.Target.Target, models[0].target());
55
55
  }
56
56
  }
57
57
 
58
- private executionContextChanged({
58
+ #executionContextChanged({
59
59
  data: newContext,
60
60
  }: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.ExecutionContext|null>): void {
61
61
  if (newContext) {
62
- this.context.setFlavor(SDK.Target.Target, newContext.target());
63
- if (!this.ignoreContextChanged) {
64
- this.lastSelectedContextId = this.contextPersistentId(newContext);
62
+ this.#context.setFlavor(SDK.Target.Target, newContext.target());
63
+ if (!this.#ignoreContextChanged) {
64
+ this.#lastSelectedContextId = this.#contextPersistentId(newContext);
65
65
  }
66
66
  }
67
67
  }
68
68
 
69
- private contextPersistentId(executionContext: SDK.RuntimeModel.ExecutionContext): string {
69
+ #contextPersistentId(executionContext: SDK.RuntimeModel.ExecutionContext): string {
70
70
  return executionContext.isDefault ? executionContext.target().name() + ':' + executionContext.frameId : '';
71
71
  }
72
72
 
73
- private targetChanged({data: newTarget}: Common.EventTarget.EventTargetEvent<SDK.Target.Target|null>): void {
74
- const currentContext = this.context.flavor(SDK.RuntimeModel.ExecutionContext);
73
+ #targetChanged({data: newTarget}: Common.EventTarget.EventTargetEvent<SDK.Target.Target|null>): void {
74
+ const currentContext = this.#context.flavor(SDK.RuntimeModel.ExecutionContext);
75
75
 
76
76
  if (!newTarget || (currentContext && currentContext.target() === newTarget)) {
77
77
  return;
@@ -85,28 +85,28 @@ export class ExecutionContextSelector implements SDK.TargetManager.SDKModelObser
85
85
 
86
86
  let newContext: SDK.RuntimeModel.ExecutionContext|null = null;
87
87
  for (let i = 0; i < executionContexts.length && !newContext; ++i) {
88
- if (this.shouldSwitchToContext(executionContexts[i])) {
88
+ if (this.#shouldSwitchToContext(executionContexts[i])) {
89
89
  newContext = executionContexts[i];
90
90
  }
91
91
  }
92
92
  for (let i = 0; i < executionContexts.length && !newContext; ++i) {
93
- if (this.isDefaultContext(executionContexts[i])) {
93
+ if (this.#isDefaultContext(executionContexts[i])) {
94
94
  newContext = executionContexts[i];
95
95
  }
96
96
  }
97
- this.ignoreContextChanged = true;
98
- this.context.setFlavor(SDK.RuntimeModel.ExecutionContext, newContext || executionContexts[0]);
99
- this.ignoreContextChanged = false;
97
+ this.#ignoreContextChanged = true;
98
+ this.#context.setFlavor(SDK.RuntimeModel.ExecutionContext, newContext || executionContexts[0]);
99
+ this.#ignoreContextChanged = false;
100
100
  }
101
101
 
102
- private shouldSwitchToContext(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
103
- if (this.lastSelectedContextId && this.lastSelectedContextId === this.contextPersistentId(executionContext)) {
102
+ #shouldSwitchToContext(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
103
+ if (this.#lastSelectedContextId && this.#lastSelectedContextId === this.#contextPersistentId(executionContext)) {
104
104
  return true;
105
105
  }
106
- return !this.lastSelectedContextId && this.isDefaultContext(executionContext);
106
+ return !this.#lastSelectedContextId && this.#isDefaultContext(executionContext);
107
107
  }
108
108
 
109
- private isDefaultContext(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
109
+ #isDefaultContext(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
110
110
  if (!executionContext.isDefault || !executionContext.frameId) {
111
111
  return false;
112
112
  }
@@ -118,47 +118,44 @@ export class ExecutionContextSelector implements SDK.TargetManager.SDKModelObser
118
118
  return Boolean(frame?.isTopFrame());
119
119
  }
120
120
 
121
- private onExecutionContextCreated(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.ExecutionContext>):
122
- void {
123
- this.switchContextIfNecessary(event.data);
121
+ #onExecutionContextCreated(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.ExecutionContext>): void {
122
+ this.#switchContextIfNecessary(event.data);
124
123
  }
125
124
 
126
- private onExecutionContextDestroyed(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.ExecutionContext>):
127
- void {
125
+ #onExecutionContextDestroyed(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.ExecutionContext>): void {
128
126
  const executionContext = event.data;
129
- if (this.context.flavor(SDK.RuntimeModel.ExecutionContext) === executionContext) {
130
- this.currentExecutionContextGone();
127
+ if (this.#context.flavor(SDK.RuntimeModel.ExecutionContext) === executionContext) {
128
+ this.#currentExecutionContextGone();
131
129
  }
132
130
  }
133
131
 
134
- private onExecutionContextOrderChanged(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.RuntimeModel>):
135
- void {
132
+ #onExecutionContextOrderChanged(event: Common.EventTarget.EventTargetEvent<SDK.RuntimeModel.RuntimeModel>): void {
136
133
  const runtimeModel = event.data;
137
134
  const executionContexts = runtimeModel.executionContexts();
138
135
  for (let i = 0; i < executionContexts.length; i++) {
139
- if (this.switchContextIfNecessary(executionContexts[i])) {
136
+ if (this.#switchContextIfNecessary(executionContexts[i])) {
140
137
  break;
141
138
  }
142
139
  }
143
140
  }
144
141
 
145
- private switchContextIfNecessary(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
146
- if (!this.context.flavor(SDK.RuntimeModel.ExecutionContext) || this.shouldSwitchToContext(executionContext)) {
147
- this.ignoreContextChanged = true;
148
- this.context.setFlavor(SDK.RuntimeModel.ExecutionContext, executionContext);
149
- this.ignoreContextChanged = false;
142
+ #switchContextIfNecessary(executionContext: SDK.RuntimeModel.ExecutionContext): boolean {
143
+ if (!this.#context.flavor(SDK.RuntimeModel.ExecutionContext) || this.#shouldSwitchToContext(executionContext)) {
144
+ this.#ignoreContextChanged = true;
145
+ this.#context.setFlavor(SDK.RuntimeModel.ExecutionContext, executionContext);
146
+ this.#ignoreContextChanged = false;
150
147
  return true;
151
148
  }
152
149
  return false;
153
150
  }
154
151
 
155
- private currentExecutionContextGone(): void {
156
- const runtimeModels = this.targetManager.models(SDK.RuntimeModel.RuntimeModel);
152
+ #currentExecutionContextGone(): void {
153
+ const runtimeModels = this.#targetManager.models(SDK.RuntimeModel.RuntimeModel);
157
154
  let newContext: SDK.RuntimeModel.ExecutionContext|null = null;
158
155
  for (let i = 0; i < runtimeModels.length && !newContext; ++i) {
159
156
  const executionContexts = runtimeModels[i].executionContexts();
160
157
  for (const executionContext of executionContexts) {
161
- if (this.isDefaultContext(executionContext)) {
158
+ if (this.#isDefaultContext(executionContext)) {
162
159
  newContext = executionContext;
163
160
  break;
164
161
  }
@@ -173,8 +170,8 @@ export class ExecutionContextSelector implements SDK.TargetManager.SDKModelObser
173
170
  }
174
171
  }
175
172
  }
176
- this.ignoreContextChanged = true;
177
- this.context.setFlavor(SDK.RuntimeModel.ExecutionContext, newContext);
178
- this.ignoreContextChanged = false;
173
+ this.#ignoreContextChanged = true;
174
+ this.#context.setFlavor(SDK.RuntimeModel.ExecutionContext, newContext);
175
+ this.#ignoreContextChanged = false;
179
176
  }
180
177
  }
@@ -114,11 +114,11 @@ const str_ = i18n.i18n.registerUIStrings('entrypoints/main/MainImpl.ts', UIStrin
114
114
  const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
115
115
 
116
116
  export class MainImpl {
117
- private lateInitDonePromise!: Promise<void>;
117
+ #lateInitDonePromise!: Promise<void>;
118
118
 
119
119
  constructor() {
120
120
  MainImpl.instanceForTest = this;
121
- this.loaded();
121
+ this.#loaded();
122
122
  }
123
123
 
124
124
  static time(label: string): void {
@@ -135,7 +135,7 @@ export class MainImpl {
135
135
  console.timeEnd(label);
136
136
  }
137
137
 
138
- private async loaded(): Promise<void> {
138
+ async #loaded(): Promise<void> {
139
139
  console.timeStamp('Main._loaded');
140
140
  Root.Runtime.Runtime.setPlatform(Host.Platform.platform());
141
141
  const prefs = await new Promise<{[key: string]: string}>(resolve => {
@@ -143,7 +143,7 @@ export class MainImpl {
143
143
  });
144
144
 
145
145
  console.timeStamp('Main._gotPreferences');
146
- this.initializeGlobalsForLayoutTests();
146
+ this.#initializeGlobalsForLayoutTests();
147
147
  this.createSettings(prefs);
148
148
  await this.requestAndRegisterLocaleData();
149
149
 
@@ -152,10 +152,10 @@ export class MainImpl {
152
152
  Common.Settings.Settings.instance().moduleSetting<boolean>('sync_preferences').get());
153
153
  }
154
154
 
155
- this.createAppUI();
155
+ this.#createAppUI();
156
156
  }
157
157
 
158
- private initializeGlobalsForLayoutTests(): void {
158
+ #initializeGlobalsForLayoutTests(): void {
159
159
  // @ts-ignore layout test global
160
160
  self.Common = self.Common || {};
161
161
  // @ts-ignore layout test global
@@ -209,10 +209,10 @@ export class MainImpl {
209
209
  }
210
210
  }
211
211
 
212
- private createSettings(prefs: {
212
+ createSettings(prefs: {
213
213
  [x: string]: string,
214
214
  }): void {
215
- this.initializeExperiments();
215
+ this.#initializeExperiments();
216
216
  let storagePrefix = '';
217
217
  if (Host.Platform.isCustomDevtoolsFrontend()) {
218
218
  storagePrefix = '__custom__';
@@ -260,7 +260,7 @@ export class MainImpl {
260
260
  }
261
261
  }
262
262
 
263
- private initializeExperiments(): void {
263
+ #initializeExperiments(): void {
264
264
  Root.Runtime.experiments.register('applyCustomStylesheet', 'Allow extensions to load custom stylesheets');
265
265
  Root.Runtime.experiments.register('captureNodeCreationStacks', 'Capture node creation stacks');
266
266
  Root.Runtime.experiments.register('sourcesPrettyPrint', 'Automatically pretty print in the Sources Panel');
@@ -395,7 +395,7 @@ export class MainImpl {
395
395
  Host.userMetrics.experimentEnabledAtLaunch(experiment.name);
396
396
  }
397
397
  }
398
- private async createAppUI(): Promise<void> {
398
+ async #createAppUI(): Promise<void> {
399
399
  MainImpl.time('Main._createAppUI');
400
400
 
401
401
  // @ts-ignore layout test global
@@ -418,7 +418,7 @@ export class MainImpl {
418
418
  }
419
419
  UI.UIUtils.installComponentRootStyles((document.body as Element));
420
420
 
421
- this.addMainEventListeners(document);
421
+ this.#addMainEventListeners(document);
422
422
 
423
423
  const canDock = Boolean(Root.Runtime.Runtime.queryParam('can_dock'));
424
424
  // @ts-ignore layout test global
@@ -450,7 +450,7 @@ export class MainImpl {
450
450
  // @ts-ignore layout test global
451
451
  self.SDK.domDebuggerManager = SDK.DOMDebuggerModel.DOMDebuggerManager.instance({forceNew: true});
452
452
  SDK.TargetManager.TargetManager.instance().addEventListener(
453
- SDK.TargetManager.Events.SuspendStateChanged, this.onSuspendStateChanged.bind(this));
453
+ SDK.TargetManager.Events.SuspendStateChanged, this.#onSuspendStateChanged.bind(this));
454
454
 
455
455
  // @ts-ignore layout test global
456
456
  self.Workspace.fileManager = Workspace.FileManager.FileManager.instance({forceNew: true});
@@ -522,7 +522,7 @@ export class MainImpl {
522
522
  // @ts-ignore layout test global
523
523
  self.UI.shortcutRegistry =
524
524
  UI.ShortcutRegistry.ShortcutRegistry.instance({forceNew: true, actionRegistry: actionRegistryInstance});
525
- this.registerMessageSinkListener();
525
+ this.#registerMessageSinkListener();
526
526
 
527
527
  MainImpl.timeEnd('Main._createAppUI');
528
528
 
@@ -530,10 +530,10 @@ export class MainImpl {
530
530
  if (!appProvider) {
531
531
  throw new Error('Unable to boot DevTools, as the appprovider is missing');
532
532
  }
533
- await this.showAppUI(await appProvider.loadAppProvider());
533
+ await this.#showAppUI(await appProvider.loadAppProvider());
534
534
  }
535
535
 
536
- private async showAppUI(appProvider: Object): Promise<void> {
536
+ async #showAppUI(appProvider: Object): Promise<void> {
537
537
  MainImpl.time('Main._showAppUI');
538
538
  const app = (appProvider as Common.AppProvider.AppProvider).createApp();
539
539
  // It is important to kick controller lifetime after apps are instantiated.
@@ -549,7 +549,7 @@ export class MainImpl {
549
549
  }, this);
550
550
  }
551
551
  Host.InspectorFrontendHost.InspectorFrontendHostInstance.events.addEventListener(
552
- Host.InspectorFrontendHostAPI.Events.RevealSourceLine, this.revealSourceLine, this);
552
+ Host.InspectorFrontendHostAPI.Events.RevealSourceLine, this.#revealSourceLine, this);
553
553
 
554
554
  await UI.InspectorView.InspectorView.instance().createToolbars();
555
555
  Host.InspectorFrontendHost.InspectorFrontendHostInstance.loadCompleted();
@@ -563,11 +563,11 @@ export class MainImpl {
563
563
  UI.ARIAUtils.alertElementInstance();
564
564
 
565
565
  // Allow UI cycles to repaint prior to creating connection.
566
- setTimeout(this.initializeTarget.bind(this), 0);
566
+ setTimeout(this.#initializeTarget.bind(this), 0);
567
567
  MainImpl.timeEnd('Main._showAppUI');
568
568
  }
569
569
 
570
- private async initializeTarget(): Promise<void> {
570
+ async #initializeTarget(): Promise<void> {
571
571
  MainImpl.time('Main._initializeTarget');
572
572
 
573
573
  // We rely on having the early initialization runnables registered in Common when an app loads its
@@ -579,11 +579,11 @@ export class MainImpl {
579
579
  // Used for browser tests.
580
580
  Host.InspectorFrontendHost.InspectorFrontendHostInstance.readyForTest();
581
581
  // Asynchronously run the extensions.
582
- setTimeout(this.lateInitialization.bind(this), 100);
582
+ setTimeout(this.#lateInitialization.bind(this), 100);
583
583
  MainImpl.timeEnd('Main._initializeTarget');
584
584
  }
585
585
 
586
- private lateInitialization(): void {
586
+ #lateInitialization(): void {
587
587
  MainImpl.time('Main._lateInitialization');
588
588
  Extensions.ExtensionServer.ExtensionServer.instance().initializeExtensions();
589
589
  const promises: Promise<void>[] =
@@ -606,15 +606,15 @@ export class MainImpl {
606
606
  Common.Settings.Settings.instance().moduleSetting(setting).addChangeListener(changeListener);
607
607
  }
608
608
  }
609
- this.lateInitDonePromise = Promise.all(promises).then(() => undefined);
609
+ this.#lateInitDonePromise = Promise.all(promises).then(() => undefined);
610
610
  MainImpl.timeEnd('Main._lateInitialization');
611
611
  }
612
612
 
613
613
  lateInitDonePromiseForTest(): Promise<void>|null {
614
- return this.lateInitDonePromise;
614
+ return this.#lateInitDonePromise;
615
615
  }
616
616
 
617
- private registerMessageSinkListener(): void {
617
+ #registerMessageSinkListener(): void {
618
618
  Common.Console.Console.instance().addEventListener(Common.Console.Events.MessageAdded, messageAdded);
619
619
 
620
620
  function messageAdded({data: message}: Common.EventTarget.EventTargetEvent<Common.Console.Message>): void {
@@ -624,8 +624,8 @@ export class MainImpl {
624
624
  }
625
625
  }
626
626
 
627
- private revealSourceLine(
628
- event: Common.EventTarget.EventTargetEvent<Host.InspectorFrontendHostAPI.RevealSourceLineEvent>): void {
627
+ #revealSourceLine(event: Common.EventTarget.EventTargetEvent<Host.InspectorFrontendHostAPI.RevealSourceLineEvent>):
628
+ void {
629
629
  const {url, lineNumber, columnNumber} = event.data;
630
630
  const uiSourceCode = Workspace.Workspace.WorkspaceImpl.instance().uiSourceCodeForURL(url);
631
631
  if (uiSourceCode) {
@@ -646,13 +646,13 @@ export class MainImpl {
646
646
  Workspace.Workspace.Events.UISourceCodeAdded, listener);
647
647
  }
648
648
 
649
- private postDocumentKeyDown(event: Event): void {
649
+ #postDocumentKeyDown(event: Event): void {
650
650
  if (!event.handled) {
651
651
  UI.ShortcutRegistry.ShortcutRegistry.instance().handleShortcut((event as KeyboardEvent));
652
652
  }
653
653
  }
654
654
 
655
- private redispatchClipboardEvent(event: Event): void {
655
+ #redispatchClipboardEvent(event: Event): void {
656
656
  const eventCopy = new CustomEvent('clipboard-' + event.type, {bubbles: true});
657
657
  // @ts-ignore Used in ElementsTreeOutline
658
658
  eventCopy['original'] = event;
@@ -666,22 +666,22 @@ export class MainImpl {
666
666
  }
667
667
  }
668
668
 
669
- private contextMenuEventFired(event: Event): void {
669
+ #contextMenuEventFired(event: Event): void {
670
670
  if (event.handled || (event.target as HTMLElement).classList.contains('popup-glasspane')) {
671
671
  event.preventDefault();
672
672
  }
673
673
  }
674
674
 
675
- private addMainEventListeners(document: Document): void {
676
- document.addEventListener('keydown', this.postDocumentKeyDown.bind(this), false);
677
- document.addEventListener('beforecopy', this.redispatchClipboardEvent.bind(this), true);
678
- document.addEventListener('copy', this.redispatchClipboardEvent.bind(this), false);
679
- document.addEventListener('cut', this.redispatchClipboardEvent.bind(this), false);
680
- document.addEventListener('paste', this.redispatchClipboardEvent.bind(this), false);
681
- document.addEventListener('contextmenu', this.contextMenuEventFired.bind(this), true);
675
+ #addMainEventListeners(document: Document): void {
676
+ document.addEventListener('keydown', this.#postDocumentKeyDown.bind(this), false);
677
+ document.addEventListener('beforecopy', this.#redispatchClipboardEvent.bind(this), true);
678
+ document.addEventListener('copy', this.#redispatchClipboardEvent.bind(this), false);
679
+ document.addEventListener('cut', this.#redispatchClipboardEvent.bind(this), false);
680
+ document.addEventListener('paste', this.#redispatchClipboardEvent.bind(this), false);
681
+ document.addEventListener('contextmenu', this.#contextMenuEventFired.bind(this), true);
682
682
  }
683
683
 
684
- private onSuspendStateChanged(): void {
684
+ #onSuspendStateChanged(): void {
685
685
  const suspended = SDK.TargetManager.TargetManager.instance().allTargetsSuspended();
686
686
  UI.InspectorView.InspectorView.instance().onSuspendStateChanged(suspended);
687
687
  }
@@ -769,11 +769,11 @@ export class SearchActionDelegate implements UI.ActionRegistration.ActionDelegat
769
769
  let mainMenuItemInstance: MainMenuItem;
770
770
 
771
771
  export class MainMenuItem implements UI.Toolbar.Provider {
772
- private readonly itemInternal: UI.Toolbar.ToolbarMenuButton;
772
+ readonly #itemInternal: UI.Toolbar.ToolbarMenuButton;
773
773
  constructor() {
774
- this.itemInternal = new UI.Toolbar.ToolbarMenuButton(this.handleContextMenu.bind(this), true);
775
- this.itemInternal.element.classList.add('main-menu');
776
- this.itemInternal.setTitle(i18nString(UIStrings.customizeAndControlDevtools));
774
+ this.#itemInternal = new UI.Toolbar.ToolbarMenuButton(this.#handleContextMenu.bind(this), true);
775
+ this.#itemInternal.element.classList.add('main-menu');
776
+ this.#itemInternal.setTitle(i18nString(UIStrings.customizeAndControlDevtools));
777
777
  }
778
778
 
779
779
  static instance(opts: {
@@ -788,10 +788,10 @@ export class MainMenuItem implements UI.Toolbar.Provider {
788
788
  }
789
789
 
790
790
  item(): UI.Toolbar.ToolbarItem|null {
791
- return this.itemInternal;
791
+ return this.#itemInternal;
792
792
  }
793
793
 
794
- private handleContextMenu(contextMenu: UI.ContextMenu.ContextMenu): void {
794
+ #handleContextMenu(contextMenu: UI.ContextMenu.ContextMenu): void {
795
795
  if (UI.DockController.DockController.instance().canDock()) {
796
796
  const dockItemElement = document.createElement('div');
797
797
  dockItemElement.classList.add('flex-centered');
@@ -853,7 +853,7 @@ export class MainMenuItem implements UI.Toolbar.Provider {
853
853
  contextMenu.headerSection().appendCustomItem(dockItemElement);
854
854
  }
855
855
 
856
- const button = (this.itemInternal.element as HTMLButtonElement);
856
+ const button = (this.#itemInternal.element as HTMLButtonElement);
857
857
 
858
858
  function setDockSide(side: UI.DockController.DockState): void {
859
859
  UI.DockController.DockController.instance().once(UI.DockController.Events.AfterDockSideChanged).then(() => {
@@ -926,10 +926,10 @@ export class MainMenuItem implements UI.Toolbar.Provider {
926
926
  let settingsButtonProviderInstance: SettingsButtonProvider;
927
927
 
928
928
  export class SettingsButtonProvider implements UI.Toolbar.Provider {
929
- private readonly settingsButton: UI.Toolbar.ToolbarButton;
929
+ readonly #settingsButton: UI.Toolbar.ToolbarButton;
930
930
  private constructor() {
931
931
  const settingsActionId = 'settings.show';
932
- this.settingsButton =
932
+ this.#settingsButton =
933
933
  UI.Toolbar.Toolbar.createActionButtonForId(settingsActionId, {showLabel: false, userActionCode: undefined});
934
934
  }
935
935
 
@@ -945,19 +945,19 @@ export class SettingsButtonProvider implements UI.Toolbar.Provider {
945
945
  }
946
946
 
947
947
  item(): UI.Toolbar.ToolbarItem|null {
948
- return this.settingsButton;
948
+ return this.#settingsButton;
949
949
  }
950
950
  }
951
951
 
952
952
  export class PauseListener {
953
953
  constructor() {
954
954
  SDK.TargetManager.TargetManager.instance().addModelListener(
955
- SDK.DebuggerModel.DebuggerModel, SDK.DebuggerModel.Events.DebuggerPaused, this.debuggerPaused, this);
955
+ SDK.DebuggerModel.DebuggerModel, SDK.DebuggerModel.Events.DebuggerPaused, this.#debuggerPaused, this);
956
956
  }
957
957
 
958
- private debuggerPaused(event: Common.EventTarget.EventTargetEvent<SDK.DebuggerModel.DebuggerModel>): void {
958
+ #debuggerPaused(event: Common.EventTarget.EventTargetEvent<SDK.DebuggerModel.DebuggerModel>): void {
959
959
  SDK.TargetManager.TargetManager.instance().removeModelListener(
960
- SDK.DebuggerModel.DebuggerModel, SDK.DebuggerModel.Events.DebuggerPaused, this.debuggerPaused, this);
960
+ SDK.DebuggerModel.DebuggerModel, SDK.DebuggerModel.Events.DebuggerPaused, this.#debuggerPaused, this);
961
961
  const debuggerModel = event.data;
962
962
  const debuggerPausedDetails = debuggerModel.debuggerPausedDetails();
963
963
  UI.Context.Context.instance().setFlavor(SDK.Target.Target, debuggerModel.target());