* Fix SQL query variable throwing error if query returns no data
* Tests to verify that metricFindQuery returns properly and doesn't throw error
* Fix all codepaths that might throw errors because of undefined backendSrv response
* update react 18 related deps
* fix some types
* make sure we're on react-router-dom >= 5.3.3
* Use new root API
* Remove StrictMode for now - react 18 double rendering causes issues
* fix + ignore some @grafana/ui types
* fix some more types
* use renderHook from @testing-library/react in almost all cases
* fix storybook types
* rewrite useDashboardSave to not use useEffect
* make props optional
* only render if props are provided
* add correct type for useCallback
* make resourcepicker tests more robust
* fix ModalManager rendering
* fix some more unit tests
* store the click coordinates in a ref as setState is NOT synchronous
* fix remaining e2e tests
* rewrite dashboardpage tests to avoid act warnings
* undo lint ignores
* fix ExpanderCell types
* set SymbolCell type correctly
* fix QueryAndExpressionsStep
* looks like the types were actually wrong instead :D
* undo this for now...
* remove spinner waits
* more robust tests
* rewrite errorboundary test to not explicitly count the number of renders
* make urlParam expect async
* increase timeout in waitFor
* revert ExplorePage test changes
* Update public/app/features/dashboard/containers/DashboardPage.test.tsx
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
* Update public/app/features/dashboard/containers/PublicDashboardPage.test.tsx
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
* Update public/app/features/dashboard/containers/PublicDashboardPage.test.tsx
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
* Update public/app/features/dashboard/containers/PublicDashboardPage.test.tsx
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
* skip fakeTimer test, ignore table types for now + other review comments
* update package peerDeps
* small tweak to resourcepicker test
* update lockfile...
* increase timeout in sharepublicdashboard tests
* ensure ExplorePaneContainer passes correct queries to initializeExplore
* fix LokiContextUI test
* fix unit tests
* make importDashboard flow more consistent
* wait for dashboard name before continuing
* more test fixes
* readd dashboard name to variable e2e tests
* wait for switches to be enabled before clicking
* fix modal rendering
* don't use @testing-library/dom directly
* quick fix for rendering of panels in firefox
* make PromQueryField test more robust
* don't wait for chartData - in react 18 this can happen before the wait code even gets executed
---------
Co-authored-by: kay delaney <kay@grafana.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
* Align log volumes on x an y axes
* Move helper functions to logs/utils
* Add tests
* Simplify supplementaryQueries.ts
* Fix tests
* Revert code simplifications
To simplify the PR, this can be added in a separate PR
* Fix reusing logs volume when limited/non-limited are used
* Use more specific property name
* Add missing property
* Stretch graph to selected range but only if there's data available
* Fix unit tests
* Fix calculating maximum when bars are stacked
* Sort log volumes by data source name
* Simplify logic to determine if log volumes can be zoomed in
* Transformations: Improve UX and fix refId issues
* Show query names and frame names in description
* move to main grafan UI component
* Added unit test
* Fix lint error
---------
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Show variables used in the target query
* Remove redundant dot
* Add usage stats about correlations
* Revert "Add usage stats about correlations"
This reverts commit 6f0c70084a.
* Add new property to AlertmanagerConfig type
* Implement fetching successfully applied configurations
Added method to fetch them from the API and its corresponding action and reducer
* Extract ConfigEditor as component to avoid code duplication
* Display dropdown with valid configs upon error and allow to save them
* Fix tests
* Refactor to call new endpoint using RTK
* Improve texts
* Apply suggested refactor
* Change constant casing
* Only show config selector for Grafana AM
* Remove ts-ignore
* Move code together for simplicity
* Remove invalid mock
* Update endpoint and types based on backend changes
* Rename property
* Rename alermanager config property from backend changes
* Disable editing old configurations
Due to the latest backend changes, we no longer will provide the option to edit previous AM configurations in a textearea.
Instead users will only be allowed to reset to a specific one with the same content. For this reason the textearea for old conf
igurations is disabled and a different form action (not submit) is executed on the "reset config" button. The updateAlertManage
rConfigAction is reset to its old functionality due to these changes.
* Add id to AlertManagerCortexConfig type
We'll need it to pass as a parameter to the new reset endpoint
* Add new endpoint for resetting AM configs to an old version
* Move the "Reset to selected configuration" button next to the drop-down
* Add relative offset to configurations
* Templating: __data __field and __series macros
* filter out datacontext from json serialization
* Fix condition
* Update
* Added test cases for formatting data, and field macros
* tracing: show backend trace ids in frontend
* better trace id naming
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* better trace id naming
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* better trace id naming
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* added feature flag
* bind functionality to the feature flag
* use non-generic name for traceid header
* fixed tests
* loki: do not create empty fields
* do not add empty fields
* fixed graphite test mock data
* added unit-tests to queryResponse
* added unit-tests for backend_srv
* more typescript-friendly check
* added unit-tests for runRequest
---------
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* working but unsure if best strategy
* removal of roleoptions to pass into the profile component
* remove the dispatch of ac
* added comment
* added one more comment tro trigger pipeline
* Added onClick to the link and made path optional.
* Added type to the import.
* revert(plugin-extensions): put back isPromise utility function
* Minor update to the isPromise function.
* added onClick in the panel menu item.
---------
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
* Hide dashboard hint when dashboard already selected
* Disable panels of types other than graph and timeseries
* Add a test checking disabled panels
* Make all panels selectable
* Fix tests
* wip for move folders
* hello
* Polish up move dashboard results messages
* tests
* fix other test
* tweak messages when things can't be moved
* tweak messages when things can't be moved
* fix tests
* remove comment
* restore failOnConsole
* .
* Fix move modal not opening due to dodgy rebase
* Logs Volume: identify timeouts and provide remediation action
* Supplementary result error: refactor updated component API
* Create helper to identify timeout errors
* Update timeout identifying function
* Add unit test
* Update panel unit test
* Update public/app/features/explore/utils/logsVolumeResponse.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Use some instead of reduce
* Change alert type to info
* Add comment
* Remove unnecessary optional chaining
* Remove unnecessary condition
* Remove unnecessary wrapping arrow function
---------
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* add selector to close dashboard settings and use it in e2e tests
* check visibility of add panel button
* check visibility of add new panel button before clicking