chrome-devtools-frontend 1.0.927127 → 1.0.927419

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 (35) hide show
  1. package/config/gni/devtools_grd_files.gni +3 -0
  2. package/front_end/core/host/UserMetrics.ts +0 -1
  3. package/front_end/core/i18n/locales/en-US.json +27 -9
  4. package/front_end/core/i18n/locales/en-XL.json +27 -9
  5. package/front_end/core/platform/keyboard-utilities.ts +1 -0
  6. package/front_end/entrypoints/main/MainImpl.ts +0 -1
  7. package/front_end/models/bindings/DebuggerWorkspaceBinding.ts +0 -6
  8. package/front_end/panels/snippets/SnippetsQuickOpen.ts +8 -3
  9. package/front_end/panels/sources/sources-meta.ts +22 -7
  10. package/front_end/third_party/codemirror.next/chunk/codemirror.js +1 -1
  11. package/front_end/third_party/codemirror.next/package.json +4 -4
  12. package/front_end/ui/components/code_highlighter/CodeHighlighter.ts +137 -0
  13. package/front_end/ui/components/code_highlighter/codeHighlighter.css +51 -0
  14. package/front_end/ui/components/code_highlighter/code_highlighter.ts +11 -0
  15. package/front_end/ui/components/docs/text_editor/basic.html +28 -0
  16. package/front_end/ui/components/docs/text_editor/basic.ts +14 -0
  17. package/front_end/ui/components/docs/text_prompt/basic.html +35 -0
  18. package/front_end/ui/components/docs/text_prompt/basic.ts +19 -0
  19. package/front_end/ui/components/render_coordinator/RenderCoordinator.ts +17 -0
  20. package/front_end/ui/components/text_editor/TextEditor.ts +161 -0
  21. package/front_end/ui/components/text_editor/config.ts +264 -0
  22. package/front_end/ui/components/text_editor/text_editor.ts +6 -0
  23. package/front_end/ui/components/text_editor/theme.ts +113 -0
  24. package/front_end/ui/components/text_prompt/TextPrompt.ts +144 -0
  25. package/front_end/ui/components/text_prompt/textPrompt.css +33 -0
  26. package/front_end/ui/components/text_prompt/text_prompt.ts +9 -0
  27. package/front_end/ui/legacy/components/quick_open/CommandMenu.ts +8 -3
  28. package/front_end/ui/legacy/components/quick_open/FilteredListWidget.ts +38 -38
  29. package/front_end/ui/legacy/components/quick_open/HelpQuickOpen.ts +10 -4
  30. package/front_end/ui/legacy/components/quick_open/QuickOpen.ts +23 -6
  31. package/front_end/ui/legacy/components/quick_open/filteredListWidget.css +7 -8
  32. package/front_end/ui/legacy/filter.css +1 -0
  33. package/inspector_overlay/main.ts +2 -1
  34. package/inspector_overlay/tool_screenshot.ts +8 -1
  35. package/package.json +1 -1
@@ -484,6 +484,7 @@ grd_files_release_sources = [
484
484
  "front_end/ui/components/report_view/report_view.js",
485
485
  "front_end/ui/components/request_link_icon/request_link_icon.js",
486
486
  "front_end/ui/components/survey_link/survey_link.js",
487
+ "front_end/ui/components/text_prompt/text_prompt.js",
487
488
  "front_end/ui/components/tree_outline/tree_outline.js",
488
489
  "front_end/ui/legacy/components/color_picker/color_picker-legacy.js",
489
490
  "front_end/ui/legacy/components/color_picker/color_picker.js",
@@ -1395,6 +1396,8 @@ grd_files_debug_sources = [
1395
1396
  "front_end/ui/components/request_link_icon/requestLinkIcon.css.js",
1396
1397
  "front_end/ui/components/survey_link/SurveyLink.js",
1397
1398
  "front_end/ui/components/survey_link/surveyLink.css.js",
1399
+ "front_end/ui/components/text_prompt/TextPrompt.js",
1400
+ "front_end/ui/components/text_prompt/textPrompt.css.js",
1398
1401
  "front_end/ui/components/tree_outline/TreeOutline.js",
1399
1402
  "front_end/ui/components/tree_outline/TreeOutlineUtils.js",
1400
1403
  "front_end/ui/components/tree_outline/treeOutline.css.js",
@@ -546,7 +546,6 @@ export const DevtoolsExperiments: {
546
546
  'backgroundServicesPushMessaging': 6,
547
547
  'blackboxJSFramesOnTimeline': 7,
548
548
  'cssOverview': 8,
549
- 'emptySourceMapAutoStepping': 9,
550
549
  'inputEventsOnTimelineOverview': 10,
551
550
  'liveHeapProfile': 11,
552
551
  'protocolMonitor': 13,
@@ -8651,8 +8651,11 @@
8651
8651
  "panels/snippets/SnippetsQuickOpen.ts | noSnippetsFound": {
8652
8652
  "message": "No snippets found."
8653
8653
  },
8654
- "panels/snippets/SnippetsQuickOpen.ts | runSnippet": {
8655
- "message": "Run snippet"
8654
+ "panels/snippets/SnippetsQuickOpen.ts | run": {
8655
+ "message": "Run"
8656
+ },
8657
+ "panels/snippets/SnippetsQuickOpen.ts | snippet": {
8658
+ "message": "Snippet"
8656
8659
  },
8657
8660
  "panels/sources/AddSourceMapURLDialog.ts | add": {
8658
8661
  "message": "Add"
@@ -9146,18 +9149,21 @@
9146
9149
  "panels/sources/sources-meta.ts | evaluateSelectedTextInConsole": {
9147
9150
  "message": "Evaluate selected text in console"
9148
9151
  },
9152
+ "panels/sources/sources-meta.ts | file": {
9153
+ "message": "File"
9154
+ },
9149
9155
  "panels/sources/sources-meta.ts | filesystem": {
9150
9156
  "message": "Filesystem"
9151
9157
  },
9158
+ "panels/sources/sources-meta.ts | goTo": {
9159
+ "message": "Go to"
9160
+ },
9152
9161
  "panels/sources/sources-meta.ts | goToAFunctionDeclarationruleSet": {
9153
9162
  "message": "Go to a function declaration/rule set"
9154
9163
  },
9155
9164
  "panels/sources/sources-meta.ts | goToLine": {
9156
9165
  "message": "Go to line"
9157
9166
  },
9158
- "panels/sources/sources-meta.ts | goToSymbol": {
9159
- "message": "Go to symbol"
9160
- },
9161
9167
  "panels/sources/sources-meta.ts | incrementCssUnitBy": {
9162
9168
  "message": "Increment CSS unit by {PH1}"
9163
9169
  },
@@ -9167,14 +9173,17 @@
9167
9173
  "panels/sources/sources-meta.ts | jumpToPreviousEditingLocation": {
9168
9174
  "message": "Jump to previous editing location"
9169
9175
  },
9176
+ "panels/sources/sources-meta.ts | line": {
9177
+ "message": "Line"
9178
+ },
9170
9179
  "panels/sources/sources-meta.ts | nextCallFrame": {
9171
9180
  "message": "Next call frame"
9172
9181
  },
9173
9182
  "panels/sources/sources-meta.ts | none": {
9174
9183
  "message": "None"
9175
9184
  },
9176
- "panels/sources/sources-meta.ts | openFile": {
9177
- "message": "Open file"
9185
+ "panels/sources/sources-meta.ts | open": {
9186
+ "message": "Open"
9178
9187
  },
9179
9188
  "panels/sources/sources-meta.ts | pauseScriptExecution": {
9180
9189
  "message": "Pause script execution"
@@ -9266,6 +9275,9 @@
9266
9275
  "panels/sources/sources-meta.ts | switchFile": {
9267
9276
  "message": "Switch file"
9268
9277
  },
9278
+ "panels/sources/sources-meta.ts | symbol": {
9279
+ "message": "Symbol"
9280
+ },
9269
9281
  "panels/sources/sources-meta.ts | threads": {
9270
9282
  "message": "Threads"
9271
9283
  },
@@ -11000,6 +11012,9 @@
11000
11012
  "ui/components/survey_link/SurveyLink.ts | thankYouForYourFeedback": {
11001
11013
  "message": "Thank you for your feedback"
11002
11014
  },
11015
+ "ui/components/text_editor/config.ts | codeEditor": {
11016
+ "message": "Code editor"
11017
+ },
11003
11018
  "ui/legacy/components/color_picker/ContrastDetails.ts | aa": {
11004
11019
  "message": "AA"
11005
11020
  },
@@ -11417,14 +11432,17 @@
11417
11432
  "ui/legacy/components/perf_ui/PieChart.ts | total": {
11418
11433
  "message": "Total"
11419
11434
  },
11435
+ "ui/legacy/components/quick_open/CommandMenu.ts | command": {
11436
+ "message": "Command"
11437
+ },
11420
11438
  "ui/legacy/components/quick_open/CommandMenu.ts | noCommandsFound": {
11421
11439
  "message": "No commands found"
11422
11440
  },
11423
11441
  "ui/legacy/components/quick_open/CommandMenu.ts | oneOrMoreSettingsHaveChanged": {
11424
11442
  "message": "One or more settings have changed which requires a reload to take effect."
11425
11443
  },
11426
- "ui/legacy/components/quick_open/CommandMenu.ts | runCommand": {
11427
- "message": "Run Command"
11444
+ "ui/legacy/components/quick_open/CommandMenu.ts | run": {
11445
+ "message": "Run"
11428
11446
  },
11429
11447
  "ui/legacy/components/quick_open/FilteredListWidget.ts | noResultsFound": {
11430
11448
  "message": "No results found"
@@ -8651,8 +8651,11 @@
8651
8651
  "panels/snippets/SnippetsQuickOpen.ts | noSnippetsFound": {
8652
8652
  "message": "N̂ó ŝńîṕp̂ét̂ś f̂óûńd̂."
8653
8653
  },
8654
- "panels/snippets/SnippetsQuickOpen.ts | runSnippet": {
8655
- "message": "R̂ún̂ śn̂íp̂ṕêt́"
8654
+ "panels/snippets/SnippetsQuickOpen.ts | run": {
8655
+ "message": "R̂ún̂"
8656
+ },
8657
+ "panels/snippets/SnippetsQuickOpen.ts | snippet": {
8658
+ "message": "Ŝńîṕp̂ét̂"
8656
8659
  },
8657
8660
  "panels/sources/AddSourceMapURLDialog.ts | add": {
8658
8661
  "message": "Âd́d̂"
@@ -9146,18 +9149,21 @@
9146
9149
  "panels/sources/sources-meta.ts | evaluateSelectedTextInConsole": {
9147
9150
  "message": "Êv́âĺûát̂é ŝél̂éĉt́êd́ t̂éx̂t́ îń ĉón̂śôĺê"
9148
9151
  },
9152
+ "panels/sources/sources-meta.ts | file": {
9153
+ "message": "F̂íl̂é"
9154
+ },
9149
9155
  "panels/sources/sources-meta.ts | filesystem": {
9150
9156
  "message": "F̂íl̂éŝýŝt́êḿ"
9151
9157
  },
9158
+ "panels/sources/sources-meta.ts | goTo": {
9159
+ "message": "Ĝó t̂ó"
9160
+ },
9152
9161
  "panels/sources/sources-meta.ts | goToAFunctionDeclarationruleSet": {
9153
9162
  "message": "Ĝó t̂ó â f́ûńĉt́îón̂ d́êćl̂ár̂át̂íôń/r̂úl̂é ŝét̂"
9154
9163
  },
9155
9164
  "panels/sources/sources-meta.ts | goToLine": {
9156
9165
  "message": "Ĝó t̂ó l̂ín̂é"
9157
9166
  },
9158
- "panels/sources/sources-meta.ts | goToSymbol": {
9159
- "message": "Ĝó t̂ó ŝým̂b́ôĺ"
9160
- },
9161
9167
  "panels/sources/sources-meta.ts | incrementCssUnitBy": {
9162
9168
  "message": "Îńĉŕêḿêńt̂ ĆŜŚ ûńît́ b̂ý {PH1}"
9163
9169
  },
@@ -9167,14 +9173,17 @@
9167
9173
  "panels/sources/sources-meta.ts | jumpToPreviousEditingLocation": {
9168
9174
  "message": "Ĵúm̂ṕ t̂ó p̂ŕêv́îóûś êd́ît́îńĝ ĺôćât́îón̂"
9169
9175
  },
9176
+ "panels/sources/sources-meta.ts | line": {
9177
+ "message": "L̂ín̂é"
9178
+ },
9170
9179
  "panels/sources/sources-meta.ts | nextCallFrame": {
9171
9180
  "message": "N̂éx̂t́ ĉál̂ĺ f̂ŕâḿê"
9172
9181
  },
9173
9182
  "panels/sources/sources-meta.ts | none": {
9174
9183
  "message": "N̂ón̂é"
9175
9184
  },
9176
- "panels/sources/sources-meta.ts | openFile": {
9177
- "message": "Ôṕêń f̂íl̂é"
9185
+ "panels/sources/sources-meta.ts | open": {
9186
+ "message": "Ôṕêń"
9178
9187
  },
9179
9188
  "panels/sources/sources-meta.ts | pauseScriptExecution": {
9180
9189
  "message": "P̂áûśê śĉŕîṕt̂ éx̂éĉút̂íôń"
@@ -9266,6 +9275,9 @@
9266
9275
  "panels/sources/sources-meta.ts | switchFile": {
9267
9276
  "message": "Ŝẃît́ĉh́ f̂íl̂é"
9268
9277
  },
9278
+ "panels/sources/sources-meta.ts | symbol": {
9279
+ "message": "Ŝým̂b́ôĺ"
9280
+ },
9269
9281
  "panels/sources/sources-meta.ts | threads": {
9270
9282
  "message": "T̂h́r̂éâd́ŝ"
9271
9283
  },
@@ -11000,6 +11012,9 @@
11000
11012
  "ui/components/survey_link/SurveyLink.ts | thankYouForYourFeedback": {
11001
11013
  "message": "T̂h́âńk̂ ýôú f̂ór̂ ýôúr̂ f́êéd̂b́âćk̂"
11002
11014
  },
11015
+ "ui/components/text_editor/config.ts | codeEditor": {
11016
+ "message": "Ĉód̂é êd́ît́ôŕ"
11017
+ },
11003
11018
  "ui/legacy/components/color_picker/ContrastDetails.ts | aa": {
11004
11019
  "message": "ÂÁ"
11005
11020
  },
@@ -11417,14 +11432,17 @@
11417
11432
  "ui/legacy/components/perf_ui/PieChart.ts | total": {
11418
11433
  "message": "T̂ót̂ál̂"
11419
11434
  },
11435
+ "ui/legacy/components/quick_open/CommandMenu.ts | command": {
11436
+ "message": "Ĉóm̂ḿâńd̂"
11437
+ },
11420
11438
  "ui/legacy/components/quick_open/CommandMenu.ts | noCommandsFound": {
11421
11439
  "message": "N̂ó ĉóm̂ḿâńd̂ś f̂óûńd̂"
11422
11440
  },
11423
11441
  "ui/legacy/components/quick_open/CommandMenu.ts | oneOrMoreSettingsHaveChanged": {
11424
11442
  "message": "Ôńê ór̂ ḿôŕê śêt́t̂ín̂ǵŝ h́âv́ê ćĥán̂ǵêd́ ŵh́îćĥ ŕêq́ûír̂éŝ á r̂él̂óâd́ t̂ó t̂ák̂é êf́f̂éĉt́."
11425
11443
  },
11426
- "ui/legacy/components/quick_open/CommandMenu.ts | runCommand": {
11427
- "message": "R̂ún̂ Ćôḿm̂án̂d́"
11444
+ "ui/legacy/components/quick_open/CommandMenu.ts | run": {
11445
+ "message": "R̂ún̂"
11428
11446
  },
11429
11447
  "ui/legacy/components/quick_open/FilteredListWidget.ts | noResultsFound": {
11430
11448
  "message": "N̂ó r̂éŝúl̂t́ŝ f́ôún̂d́"
@@ -9,6 +9,7 @@ export const enum ArrowKey {
9
9
  RIGHT = 'ArrowRight',
10
10
  }
11
11
 
12
+ export const ENTER_KEY = 'Enter';
12
13
  export const ESCAPE_KEY = 'Escape';
13
14
 
14
15
  export const ARROW_KEYS = new Set<ArrowKey>([
@@ -243,7 +243,6 @@ export class MainImpl {
243
243
  'ignoreListJSFramesOnTimeline', 'Ignore List for JavaScript frames on Timeline', true);
244
244
  Root.Runtime.experiments.register(
245
245
  'cssOverview', 'CSS Overview', undefined, 'https://developer.chrome.com/blog/new-in-devtools-87/#css-overview');
246
- Root.Runtime.experiments.register('emptySourceMapAutoStepping', 'Empty sourcemap auto-stepping');
247
246
  Root.Runtime.experiments.register('inputEventsOnTimelineOverview', 'Input events on Timeline overview', true);
248
247
  Root.Runtime.experiments.register('liveHeapProfile', 'Live heap profile', true);
249
248
  Root.Runtime.experiments.register(
@@ -90,8 +90,6 @@ export class DebuggerWorkspaceBinding implements SDK.TargetManager.SDKModelObser
90
90
  return true;
91
91
  }
92
92
 
93
- // TODO(crbug.com/1018234): Also take into account source maps here and remove the auto-stepping
94
- // logic in the front-end (which is currently still an experiment) completely.
95
93
  const rawLocation = callFrame.location();
96
94
  if (!rawLocation) {
97
95
  return [];
@@ -118,10 +116,6 @@ export class DebuggerWorkspaceBinding implements SDK.TargetManager.SDKModelObser
118
116
  }
119
117
  }
120
118
 
121
- if (!Root.Runtime.experiments.isEnabled('emptySourceMapAutoStepping')) {
122
- return [];
123
- }
124
-
125
119
  const compilerMapping = this.debuggerModelToData.get(rawLocation.debuggerModel)?.compilerMapping;
126
120
  if (!compilerMapping) {
127
121
  return [];
@@ -14,9 +14,13 @@ const UIStrings = {
14
14
  */
15
15
  noSnippetsFound: 'No snippets found.',
16
16
  /**
17
- *@description Text to run a code snippet
17
+ *@description Text for command prefix of run a code snippet
18
18
  */
19
- runSnippet: 'Run snippet',
19
+ run: 'Run',
20
+ /**
21
+ *@description Text for suggestion of run a code snippet
22
+ */
23
+ snippet: 'Snippet',
20
24
  };
21
25
  const str_ = i18n.i18n.registerUIStrings('panels/snippets/SnippetsQuickOpen.ts', UIStrings);
22
26
  const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);
@@ -77,6 +81,7 @@ export class SnippetsQuickOpen extends QuickOpen.FilteredListWidget.Provider {
77
81
  QuickOpen.FilteredListWidget.registerProvider({
78
82
  prefix: '!',
79
83
  iconName: 'ic_command_run_snippet',
80
- title: i18nLazyString(UIStrings.runSnippet),
81
84
  provider: () => Promise.resolve(SnippetsQuickOpen.instance()),
85
+ titlePrefix: i18nLazyString(UIStrings.run),
86
+ titleSuggestion: i18nLazyString(UIStrings.snippet),
82
87
  });
@@ -348,13 +348,25 @@ const UIStrings = {
348
348
  */
349
349
  disallowScrollingPastEndOfFile: 'Disallow scrolling past end of file',
350
350
  /**
351
- *@description Title of the Filtered List WidgetProvider of Quick Open
351
+ *@description Text for command prefix of go to a given line or symbol
352
352
  */
353
- goToSymbol: 'Go to symbol',
353
+ goTo: 'Go to',
354
354
  /**
355
- *@description Text to open a file
355
+ *@description Text for command suggestion of go to a given line
356
356
  */
357
- openFile: 'Open file',
357
+ line: 'Line',
358
+ /**
359
+ *@description Text for command suggestion of go to a given symbol
360
+ */
361
+ symbol: 'Symbol',
362
+ /**
363
+ *@description Text for command prefix of open a file
364
+ */
365
+ open: 'Open',
366
+ /**
367
+ *@description Text for command suggestion of open a file
368
+ */
369
+ file: 'File',
358
370
  /**
359
371
  * @description Title of a setting under the Sources category in Settings. If this option is off,
360
372
  * the sources panel will not be automatically be focsed whenever the application hits a breakpoint
@@ -1688,29 +1700,32 @@ UI.ContextMenu.registerItem({
1688
1700
  QuickOpen.FilteredListWidget.registerProvider({
1689
1701
  prefix: '@',
1690
1702
  iconName: 'ic_command_go_to_symbol',
1691
- title: i18nLazyString(UIStrings.goToSymbol),
1692
1703
  async provider() {
1693
1704
  const Sources = await loadSourcesModule();
1694
1705
  return Sources.OutlineQuickOpen.OutlineQuickOpen.instance();
1695
1706
  },
1707
+ titlePrefix: i18nLazyString(UIStrings.goTo),
1708
+ titleSuggestion: i18nLazyString(UIStrings.symbol),
1696
1709
  });
1697
1710
 
1698
1711
  QuickOpen.FilteredListWidget.registerProvider({
1699
1712
  prefix: ':',
1700
1713
  iconName: 'ic_command_go_to_line',
1701
- title: i18nLazyString(UIStrings.goToLine),
1702
1714
  async provider() {
1703
1715
  const Sources = await loadSourcesModule();
1704
1716
  return Sources.GoToLineQuickOpen.GoToLineQuickOpen.instance();
1705
1717
  },
1718
+ titlePrefix: i18nLazyString(UIStrings.goTo),
1719
+ titleSuggestion: i18nLazyString(UIStrings.line),
1706
1720
  });
1707
1721
 
1708
1722
  QuickOpen.FilteredListWidget.registerProvider({
1709
1723
  prefix: '',
1710
1724
  iconName: 'ic_command_open_file',
1711
- title: i18nLazyString(UIStrings.openFile),
1712
1725
  async provider() {
1713
1726
  const Sources = await loadSourcesModule();
1714
1727
  return Sources.OpenFileQuickOpen.OpenFileQuickOpen.instance();
1715
1728
  },
1729
+ titlePrefix: i18nLazyString(UIStrings.open),
1730
+ titleSuggestion: i18nLazyString(UIStrings.file),
1716
1731
  });