grafana/public/app/plugins/datasource/cloudwatch/__mocks__/metric-math-test-data
Sarah Zinger 58a71c7e91
Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985)
* Create a "monarch" folder with everything you need to do syntax highlighting and autocompletion.

* Use this new monarch folder with existing cloudwatch sql.

* Add metric math syntax highlighting and autocomplete.

* Make autocomplete "smarter":
- search always inserts a string as first arg
- strings can't contain predefined functions
- operators follow the last closing )

* Add some tests for Metric Math's CompletionItemProvider.

* Fixes After CR:
- refactor CompletionItemProvider, so that it only requires args that are dynamic or outside of it's responsibility
- Update and add tests with mocked monaco
- Add more autocomplete suggestions for SEARCH expression functions
- sort keywords and give different priority from function to make more visually distinctive.

* Change QueryEditor to auto-resize and look more like the one in Prometheus.

* Add autocomplete for time periods for the third arg of Search.

* More CR fixes:
- fix missing break
- add unit tests for statementPosition
- fix broken time period
- sort time periods

* Bug fix
2022-02-01 22:53:32 -05:00
..
afterFunctionQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
index.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
secondArgAfterSearchQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
secondArgQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
singleLineEmptyQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
thirdArgAfterSearchQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00
withinStringQuery.ts Cloudwatch: Add syntax highlighting and autocomplete for "Metric Search" (#43985) 2022-02-01 22:53:32 -05:00