Skip to content

extensions: add focus status bar and notification commands

Warren Gifford requested to merge tjk/focus-thru-cmd into main

Created by: tjkandala

Part of #36751 (closed). Closes #36753 (closed) and #36849 (closed).

We currently don't have any built in command palette actions. To ensure minimal changes to command palette code (e.g. adding abstraction for built in commands), my approach was to use the same APIs as extensions to add actions to the command palette.

cmd-pal-exts

So, we call registerCommand and registerContributions on the extension host + main thread APIs from the status bar and notifications components.

Test plan

  • Existing automated tests pass
  • Ensure focus works through manual testing
    • Status bar (on blob page)
      • Activate command palette with the ctrl + p shortcut
      • Search for Focus status bar command
      • Press enter/return and observe focus on first status bar item
    • Notifications (on search results page with search-export extension enabled)
      • Click Export search results button
      • Activate command palette with the ctrl + p shortcut
      • Search for Focus notifications command
      • Press enter/return and observe focus on first notification

App preview:

Check out the client app preview documentation to learn more.

Merge request reports

Loading