code monitoring: use monaco query input for trigger
Created by: limitedmage
Fixes #17320
-
FormTriggerAreanow usesMonacoQueryInputfor the search query.- Some code needed to be reorganized to get the same look as before
-
isLIghtThemeandisSourcegraphDotComhad to be added as props because they are required byMonacoQueryInput. This added a bunch of prop drilling of these props through the code monitoring codebase.
- The existing mock for
window.matchMediainhover.test.tswas moved to a place where it would always be executed by adding it to the Jes config. Monaco requiresmatchMediabut the version of Jest/JSDom we are using does not provide it. - The hack used to enable tabbing in Monaco needed a slight modification with
setTimeoutbecause it was not working with the hiding/reappearingMonacoQueryInputin theFromTriggerArea. -
FormTriggerAreasnapshot test was removed since the existing unit tests and storybook tests already provide that coverage from functional and visual standpoints.
Screenshot
Test plan
- Manual testing different scenarios (create new monitor, edit existing monitor, continuously open and close the trigger area, etc)
- Update unit tests to use Monaco query input (integration tests did not need updating)
- Ensure all existing unit tests and integration tests pass
- Ensure any
