* Use deepEqual to ensure migratedQuery is only returned when query is unchanged
* Add selectors for query editors
* Add more tests for query editor component
* Clarifying comments
* Fix how state is set
* Simplify query editor loading and migration
* MultiSelect: Respect value passed to the component regardless of custom value being allowed or not
* reset input for test
---------
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
* chore(storybook): run yarn dlx storybook@latest upgrade
* chore(storybook): remove storybook/blocks patch
* chore(yarn): clean up storybook dependencies
* feat(storybook): migrate to v8 config via migration codemods
* refactor(storybook): update stories to use v8 types via codemod
* refactor(storybook): update stories to use preview-api instead of client-api
* refactor(storybook): replace mdx usage of ArgsTable with PureArgsTable
* refactor(storybook): migrate remaining mdx files to v8 storybook/blocks api
* refactor(storybook): clean up mdx imports and blocks component names
* chore(storybook): clean up typescript configuration
* fix(frontend): align types/react versions across monorepo so grafana ui can be built
* fix(storybook): pub back react-docgen-typescript and use ArgTypes so props tables work
* chore(storybook): patch blocks package to expose Preview component
* revert(storybook): revert changes related to using Canvas component in mdx files
* Storybook upgrade: Fix icon typing (#87793)
fix iconOptions typing
* refactor(storybook): prefer as const over asserting types
* revert(storybook): put back correct case in box.mdx
---------
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
* Implement changes for new Scopes API
* Update from linkID to linkId
* Fixes
* Fix tests
* prom/scopes: change query model to recieve []ScopeSpec
* Move to basic backend service
---------
Co-authored-by: Kyle Brandt <kyle@grafana.com>
* Tempo: Escape backslash in span name for promsql query
In promsql, backslashes in regexes must be doubly escaped for them to be
interpreted as a literal backslash character.
Fixes#79791
* Fix regex replace
---------
Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
* WIP
* add configure irm componet and pass it to Nav
* add check if theres datasource for Alerts
* update incident steps links
* uncomment done property in the interface
* Fix not having data sources in store and removing warning using wrong Icon name type
* call incidents api in done step
* Show checked steps with an icon instead of a badge
* Implemnt check contact point ready in essentials
* Fix codeowners and prettify file
* Check if there is one oncall integration in at least one contact point
* Refactor
* Check for oncall integration being created
* Add the test oncall integration action
* Do not hide any card in irm page, and refactor
* Refactor: move hooks to a separate file
* Implement oncall chatops checks
* update incidents hook
* Show new irm page only on cloud and for admins
* fix prettier in irmhooks
* remove unused import
* fix prettier in irm hooks
* fix axios method
* Add progress bar on essentials
* Update texts and some styles
* Refactor
* fix api call
* fix check is plugin is installed
* fix async call
* fix lint
* Do not show check icon when done field is undefined in a step
* refactor
* Add test for Essentials
* check if incident plugin installed
* call incidents api to get steps
* add the new api to get config
* fix prettier
* memoize the api call
* fix lint
* add proper api call
* check if response is valid
* fix typo
* use state to save the values
* fix lint
* fix response schema
* fix prettier
* update incident steps copy
* udapte texts in respond tooltips
* Fix confiure IRM route check
* Fix logic for the data source check: check if there is a data source that is alerting compatible
* Use existing header prop in NavLandingPage instead of creating a new prop
* fix wrong updated file
* Update logic for default contact point check and update some links
* Update texts and show only one item for oncall integration with alerting checks
* Update texts following suggestions in the doc
* Fix getting default contact point and update oncall link for slack tab
* Update texts, buttons and checks following last meeting action items
* remove unnecessary component drawer
* Track interactions: user open or close essentials drawer
* Refactor
* remove unnecessary createMonitoringLogger for tracking irm events
* remove unnecessary style
* refactor
* refactor
* Add fallback links and labels for action buttons when step is done
* Update irm card styles
* remove extra space after progress bar numbers
* remove progress bar border
* Address pr review comments
* remove unnecessary AlertmanagerProvider
* fix logic behind default contact point check
* update test
* Address pr review comments part1
* add aria and properties role for Progressbar
* Reorganize hooks into separate folders/files for each app
* move done field to the step level
* Handle empty dropdown options
* Handle loading state
* Update tooltip for connecting alerting to oncall
* Use RTKQ for incidents
* handle loading for oncall hooks
* refactor getting configuration for each app
* fix incident rtkq query to be a query instead of mutation
* refactor: rename variable
* Address some nits in the review
---------
Co-authored-by: reemtariqq <reem.tariq@grafana.com>
* Create basic feature toggle
* Rename context to reflect it contains query history and query library
* Update icons and variants
* Rename hooks
* Update tests
* Fix mock
* Add tracking
* Turn button into a toggle
* Make dropdown active as well
This is required to have better UI and an indication of selected state in split view
* Update Query Library icon
This is to make it consistent with the toolbar button
* Hide query history button when query library is available
This is to avoid confusing UX with 2 button triggering the drawer but with slightly different behavior
* Make the drawer bigger for query library
To avoid confusion for current users and test it internally a bit more it's behind a feature toggle. Bigger drawer may obstruct the view and add more friction in the UX.
* Fix tests
The test was failing because queryLibraryAvailable was set to true for tests. This change makes it more explicit what use case is being tested
* Remove active state underline from the dropdown
* Add basic types and api methods
This is just moved from the app. To be cleaned up and refactored later.
* Move API utils from Query Library app to Grafana packages
* Move API utils from Query Library app to Grafana packages
* Move API utils from Query Library app to Grafana packages
* Add basic table for query templates
* Add sorting
* Style cells
* Style table cells
* Allow closing Query Library drawer from the toolbar
* Remove Private Query toggle
It will be moved to the kebab
* Add empty state
* Remove variables detection for now
Just to simplify the PR, it's not needed for Explore yet.
* Simplify getting useDatasource.tsx
* Rename cell
* Move QueryTemplatesTable to a separate folder
* Use RTK Query to get list of query templates
* Clean up query templates table
* Simplify useDatasource hook
* Add a test
* Retrigger the build
* Remove unused code
* Small clean up
* Update import
* Add reduxjs/toolkit as a peer dependecy
* Revert "Add reduxjs/toolkit as a peer dependecy"
This reverts commit aa9da6e442.
* Update import
* Add reduxjs/toolkit as a peer dependecy
* Revert "Add reduxjs/toolkit as a peer dependecy"
This reverts commit 2e68a62ab6.
* Add @reduxjs/toolkit as peer dependency
* Add @reduxjs/toolkit as peer dependecy
* Move reactjs/toolkit to dev dependecies
* Minor clean up and use react-redux as a peer dependency
* Move query library code to core features
* Update code owners
* Update export
* Update exports
* Use Redux store instead of APIProvider
* Await for query templates to show during the test
* Add more explicit docs that the feature is experimental
---------
Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
* Fix deleting rules when silencing/resuming rule from a panel alert tab
* fix test and return early when no group target is found
* address pr review comment
* GenAI: Fixes multiple calls to settings and health
* swap order of tests given new caching
---------
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
* improve typings in opentsdb datasource
* couple of influx improvements
* couple more
* more
* more more more
* 3 more
* changes to variables/inspect/utils
* some graphite improvements
* [explore] lookup datasource by name when present in legacy compact URLs
* update unit test
* prettier fix
---------
Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
* Reduce number of request fetching rules in the dashboard view using rtkq
* Fix UnifiedAlertStatesWorker work
* refactor ungroupRulesByFileName
* Address review comments and fix test
* fix DashboardQueryRunner test
* Fix tests
* Update AlertStatesDataLayer to use RTKQ
* Fix PanelAlertTabContent test
* Fix PanelAlertTabContent test after adding RTKQ
* fix test and address PR review comments
* Update useCombinedRuleNamespaces to have both dashboardUID and panelId as optional params and rename the hook
* Address review pr comment
* remove test about template variables
* Use poll interval in useCombinedRules
* set selected config type before save
* use effect once and move in mssql
* add to prom
* Update ConfigurationEditor.tsx
* Update ConfigurationEditor.tsx
* Delete public/app/plugins/datasource/mssql/configuration/ConfigurationEditor.tsx
* omadsfdsa
* remove unneeded assign
* MixedDataSource: Support multi value data source variable
* go work sync
* fix typo
* if it is not interpolated use the actual uid
* Update tests
* prettier
* go work sync
* add more unit test case
* Update tests to use scene variables
* merge main
* Update
---------
Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* I18n: Change verify-i18n script to use node_deb image with make in it
* remove swagger from i18n make
* make verify-i18n fail ci
* fix incorrect and unextracted nav translations
* fix more copy paste
* wip filtering
* Remove corresponding children from parentlessItem ref on register
* wip filtering
* Remove corresponding children from parentlessItem ref on register
* Highlighting filters
* OMG
* Handle updating highlight field inside context
* Toggling legend from the content outline
* Support multiple selects for log filters in content outline
* Remove commented out code
* Fix an issue with loki datasource; use same datastructure for logsVolume in Logs and LogVolume panel
* Fix registering logic
* cleanup
* Don't register outline items when having multiple log volume levels
* Remove checking mergeSingleChild logic because in context because ContentOutline does it
* Fix logic so it works for elasticsearch
* Better logic
* Add log color and sort
* Show items at full opacity
* Remove commented sort
* Do not highlight if all are selected, and highlight = 100% opacity, active = 30%
* dont auto collapse after filter unselect
* Remove console logs
* No partial opacity, add height for consistent display
---------
Co-authored-by: Piotr Jamroz <pm.jamroz@gmail.com>
Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
* update plugin install filter to show all by default
* make pretty
* remove aria-label on lock icon
* wip: attempt to fix overflow
* switch to stack, add aria label back for testing
* make pretty
* switch to TextLink
* remove learn more link from catalog
* add hover text
* docs: update plugin install to reflect state filter change
* Revert "docs: update plugin install to reflect state filter change"
This reverts commit 16222aee0b.
* Only let nodeGraph frames process through nodeGraph
* add metadata to test frames to be processed
* Revert "add metadata to test frames to be processed"
This reverts commit fc366a0ab4.
* Revert "Only let nodeGraph frames process through nodeGraph"
This reverts commit b8be50e219.
* Only send node graph frames to node graph logic
* remove unnecessary logic
* Loki: Add label values API selector to setting and use label_values API when selected
* remove CHANGELOG change
* add docs
* Support Loki 2.7+ only, so unconditionally use /labels API
* Correct doc for fetchLabels and fetchLabelValues functions
* Fixes after merge
* Do not encode query parameter twice
* return getLabelKeys in Completion Provider
* docs
* Add test for LabelParamEditor
* Update public/app/plugins/datasource/loki/LogContextProvider.test.ts
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* toHaveBeenCalledWith
---------
Co-authored-by: Matias Chomicki <matyax@gmail.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* fix: reloaded scene first step topScene
The top scene was not being initialized
when reloading trails, causing it to use
the top scene of whatever was selected
previously.
* fix: select new metric node not reloading right
On reloading trails, any metric node that
was 'green' with a undefined metric due to
clicking on the "select new metric" button,
was reloading with the metric of the step
directly before it (in index order).
* fix: opt-in to `useQueriesAsFilterForOptions`
With updating the scenes library, dashboards must now explicitly
opt in to `useQueriesAsFilterForOptions`.
* fix: loaded trails modified parent var on new step
This ensures that recently loaded trails won't have variable changes
which create new steps modify the previous step.
* Update Yarn to v4.2.1
* add new yarn version
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Add reqAction to Prometheus routes
This should allow provisioned service accounts that do not have a role to use the /proxy endpoints for Prometheus. This
is desired for some integrations that need to query for labels or other data not part of /ds/query.
* Add auth checks and test
* Check user is authorized to view rule and add tests
* Change naming
* Update Swagger params
* Update auth test and swagger gen
* Update swagger gen
* Change response to GettableExtendedRuleNode
* openapi3-gen
* Update tests with refactors models pkg
* Create basic structure PanelDataQueriesTab unit test
* Add more test cases to the PanelDataQueriesTab test
* Update public/app/features/dashboard-scene/panel-edit/VizPanelManager.tsx