Skip to content
Snippets Groups Projects

search-ui: add props to SearchBox for VS Code

Merged Warren Gifford requested to merge tjk/search-box-refprop into main

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

Merged by avatar (Jul 13, 2025 6:31am 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