Skip to content
Snippets Groups Projects

search-ui: add props to SearchBox for VS Code

Created by: tjkandala

Add props to SearchBox used in the VS Code extension.

  • onEditorCreated: Used to get a reference to the underlying Monaco instance. We use this in the extension to focus the search box on events such as sidebar suggestion clicks or search tab focus.
  • className and containerClassName: Self-explanatory, enables variable styling across clients now that we use CSS modules (unable to reference class to override)
  • fetchStreamSuggestions: We use a different implementation of this in the extension (we call the "default" implementation in node, send result in message back to UI)

Test plan

  • sg start web-standalone
  • Observe that the search box still works.
  • We don't seem to have unit tests for Monaco, so I added a temporary onEditorCreated callback in SearchNavbarItem to ensure that everything is wired up correctly (just logged editor instance to console).

Merge request reports

Approval is optional

Merged by avatar (Jul 30, 2025 10:40pm UTC)

Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading