Commit Graph

406 Commits

Author SHA1 Message Date
Kian Eliasi
e3c50f0cd6
Chore: Remove any from public/app/plugins/datasource/elasticsearch/hooks/useNextId.test.tsx (#53427)
* Remove any from public/app/plugins/datasource/elasticsearch/hooks/useNextId.test.tsx

* Fix lint and update betterer results
2022-08-10 09:25:35 +02:00
eledobleefe
9930fd522d
Chore: convert DashboardGrid test to RTL (#53405) 2022-08-08 17:43:35 +02:00
Ivana Huckova
84b2498150
Loki: Fix showing of unusable labels field in detected fields (#53319)
* Loki: Fix showing of labels field in detected fields

* Create reusable createlogRow mock
2022-08-08 14:27:33 +02:00
Matias Chomicki
6f01930e9d
Chore: remove any from test (#53260) 2022-08-08 11:26:12 +02:00
Leo
64967325b2
Search: Migrated impressions to use dashboardUID (#53090)
* used dashboarduid in impressions

* handle scenario to convert all ids saved in storage to uids
2022-08-08 11:13:19 +02:00
Josh Hunt
4b4d546e32
Typed variables pt4: Remove generics from getVariable (#53017)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* Chore: Type VariableState to use TypedVariableModel

* fix typo

* remove type assertion from template_srv.getVariables

* use typescript/no-redeclare for compatibility with ts overloads

* remove generics from getVariable() and overload it to only return undefined based on arguments

* update usages of getVariable()

* Fix Interval variable options picker not working
2022-08-05 13:44:52 +01:00
eledobleefe
c65b4c732f
Chore: Convert FolderSettingsPage.test.tsx to RTL (#53307) 2022-08-04 16:00:04 +02:00
Drew Slobodnjak
fe0f193189
Geomap: Add measuring tools (#51608)
* Geomap: add measuring tools

* Add measure type selection

* Add controls and state to measure overlay

* Override tooltip mouse events when menu active

* Move measure tools to top right

* Lay groundwork for units and consolidate measuring

* Create measure vector layer class

* Improve styling to match other overlay controls

* Consolidate styling and use theme2

* Update unit language and add km2

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-08-03 16:19:30 -07:00
Matias Chomicki
97ce40577b
Loki: Fix types in querybuilder state test (#53223)
* Chore: add missing refId property to LokiQuery type

* Chore: fix types in Loki querybuilder state test

* Chore: remove unnecessary added property to LokiQuery
2022-08-03 15:59:33 +02:00
Ivana Huckova
3877964470
Loki: Remove some of any assertions from tests (#53114)
* Loki: Remove some of any assertions from tests

* Remove unnecessary as assertions
2022-08-03 15:57:38 +02:00
ismail simsek
87af08129c
Prometheus: Add tests for new explain section (#53182)
* Prometheus: Add tests for new explain section

* Update public/app/plugins/datasource/prometheus/querybuilder/components/PromQueryBuilder.test.tsx

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

* Mock MonacoQueryFieldWrapper

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-08-03 15:48:16 +02:00
Jack Westbrook
d87bf30e9e
Build: Introduce ESM and Treeshaking to NPM package builds (#51517)
* Revert "Chore: Bump terser to fix security vulnerability (#53052)"

This reverts commit 7ae74d2a18.

* feat: use tsc and rollup directly with esbuild and publishConfig, files props

* refactor(grafana-data): fix isolatedModules re-export type error

* refactor(grafana-data): import paths from src not package name

* refactor(rollup): fix dts output.file

* chore(grafana-schema): delete dashboard_experimental.gen.ts - cannot work with isolatedModules

* refactor(grafana-e2e-selectors): fix export types isolatedModules error

* refactor(grafana-runtime): fix isolatedModules re-export type error

* refactor(grafana-ui): fix isolatedModules re-export type error

* feat(grafana-ui): use named imports for treeshaking

* refactor(grafana-ui): use named imports for treeshaking

* feat: react and react-dom as peerDeps for packages

* feat(grafana-ui): emotion packages as peerDeps

* feat(grafana-e2e): use tsc, rollup, esbuild for bundling

* chore(packages): clean up redundant dependencies

* chore(toolkit): deprecate unused package:build task

* chore(schema): put back dashboard_experimental and exclude to prevent isolatedModules error

* docs(packages): update readme

* chore(storybook): disable isolatedModules for builds

* chore: relax peerDeps for emotion and react

* revert(grafana-ui): put @emotion dependencies back

* refactor: replace relative package imports with package name

* build(packages): set emitDeclaration false for typecheck scripts to work

* test(publicdashboarddatasource): move test next to implementation. try to appease the betterer gods

* chore(storybook): override ts-node config for storybook compilation

* refactor(grafana-data): use ternary so babel doesnt complain about expecting flow types

* chore(toolkit): prefer files and publishConfig package.json props over copying

* build(npm): remove --contents dist arg from publishing commands

* chore(packages): introduce sideEffects prop to package.json to hint package can be treeshaken

* chore(packages): remove redundant index.js files

* feat(packages): set publishConfig.access to public

* feat(packages): use yarn berry and npm for packaging and publishing

* refactor(packages): simplify rollup configs

* chore(schema): add comment explaining need to exclude dashboard_experimental

* revert(toolkit): put back clean to prevent cli failures

* ci(packages): run packages:pack before a canary publish

* chore(gitignore): add npm-artifacts directory to ignore list

* test(publicdashboarddatasource): fix module mocking

* chore(packages): delete package.tgz when running clean

* chore(grafana-data): move dependencies from devDeps to prevent build resolution errors
2022-08-03 15:47:09 +02:00
Josh Hunt
c7d3fec515
Typed variables pt3: Type VariableState with TypedVariableModel (#53015)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* Chore: Type VariableState to use TypedVariableModel

* fix typo

* remove type assertion from template_srv.getVariables

* undo whatever changes i did to swagger spec
2022-08-03 12:38:59 +01:00
user10x
fb00a11b5f
rename table_model.ts => TableModel.ts (#51659)
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-03 10:33:13 +00:00
Scott Lepper
fe7add0bc6
ref experimental query editor (#53061)
* ref experimental query editor
2022-08-02 11:44:06 -04:00
Ivana Huckova
5009c330ca
Loki: Add tests for explain section in builder and code editor (#53113)
* Loki: Add tests for new explain section

* Update any assertions
2022-08-02 17:20:22 +02:00
Ashley Harrison
9c6aab3bc9
Chore: remove UseState + add support for controls in TimeOfDayPicker/TimeRangeInput story (#53040)
* remove UseState + add support for controls in TimeOfDayPicker story

* remove UseState + add controls support in TimeRangeInput story

* Add documentation + fix error when clearing

* properly type range
2022-08-02 13:33:59 +01:00
Josh Hunt
eaf6aea98f
Typed variables pt1: Use discriminated union for variable model (#52981)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up
2022-08-02 10:15:25 +01:00
Adela Almasan
5797fbc0b2
Canvas: Cleanup default elements (#52958) 2022-08-01 15:34:05 -05:00
Nathan Marrs
7b249d19b2
Canvas: Inline element settings (#52771) 2022-08-01 12:22:13 -05:00
Konrad Lalik
54f2c056f5
Alerting: Configure alert manager data source as an external AM (#52081)
Co-authored-by: Jean-Philippe Quéméner <JohnnyQQQQ@users.noreply.github.com>
Co-authored-by: gotjosh <josue.abreu@gmail.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-08-01 10:20:43 +02:00
Ryan McKinley
197acd73c0
Storage: support git + github backed roots (#52192) 2022-07-28 23:26:44 -07:00
ismail simsek
2f9636e698
InfluxDB: move datasource health check to backend (#52668)
* Move datasource health check to backend

* Introduce healthcheck unit tests

* Remove unused method
2022-07-28 12:06:09 +02:00
Leon Sorokin
8ee0555bac
TimeSeries: Implement auto decimals for y axes (#52912) 2022-07-28 02:58:42 -04:00
Ryan McKinley
8a2d40c2bc
Canvas: Add all options to inline editor (#52834)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-07-27 19:20:39 -04:00
Brendan O'Handley
6c3efb0c88
Graphite Plugin: Remove angular dependencies for graphite annotations (#52261)
* fix merge conflict

* fix betterer

* handle new creating annotations

* add h5 'or' tag to annotation editor

* fix annotation regression looking for tags before target

* remove angular annotation partial

* change ann tags type to string[] and use TagsInput to create ann

* remove GraphiteEventsType, return annotations targets setting 'textEditor': true

* fix yarn typecheck errors

* add dateTime for yarn fix to tests

* fix incorrect merge conflict resolution

* fix betterer

* making changes for PR approval resolutions

* fix prettier issue

* fix prettier
2022-07-27 16:27:42 -04:00
Adela Almasan
a5410063c6
Canvas: Merge tree view and layer element list UX (#52701)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-07-26 19:51:20 -04:00
ismail simsek
0a664faeeb
Graphite: Introduce new query types in annotation editor (#52341)
* Fix comment lines

* Introduce graphite variable editor

* Render results differently based on queryType

* Add comments and fallback values

* Unit tests for different type of graphite queries

* Use metrics/expand endpoint to retrieve metric names
2022-07-26 18:30:23 +02:00
Ryan McKinley
238d761450
Geomap: refactor and cleanup structures (#52760)
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
2022-07-25 20:12:20 -04:00
Joey Tawadrous
cb35729553
Traces: Align APM table names (#52591)
* Order col values according to rate names order

* Tests
2022-07-25 18:59:43 +01:00
Torkel Ödegaard
b782d9aa12
GrafanaContext: Exploring a way to get rid of global scope singletons (#52128)
* Context start

* More progress on more generic react context for services

* Update

* Update Page test

* Fixing tests

* Moving to core app
2022-07-23 17:09:03 +02:00
Ryan McKinley
2fa10dc903
TimeSeries: Support multiple timezones in x axis (#52424)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-07-22 22:18:27 -05:00
Ashley Harrison
2b46138202
improve meta and story typings (#52659) 2022-07-22 17:19:16 +01:00
kay delaney
0c89743759
Variables: Optimize "timeRangeUpdated" path (#52047) 2022-07-22 16:10:10 +01:00
Konrad Lalik
0507b3564f
Alerting: Fix alert panel instance-based rules filtering (#52583) 2022-07-22 12:52:56 +02:00
Ivan Ortega Alba
2ec01c8d08
Preferences: Use dashboardUID to set the home dashboard (#51919) 2022-07-22 10:44:22 +02:00
Ashley Harrison
27542445ce
Chore: remove UseState from ColorPicker story (#52611)
* remove UseState from ColorPicker story

* remove story meta type assertion
2022-07-21 16:15:55 +01:00
Ashley Harrison
f25c609105
Convert MultiModeGraphTooltip test to RTL (#52595)
* Convert MultiModeGraphTooltip test to RTL

* don't export these styles

* use theme instead of hardcoded style values
2022-07-21 15:54:18 +01:00
Scott Lepper
de956fc3d8
Core code editor/builder components (#52421)
* migrate experimental to core grafana - update refs

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-07-20 12:50:08 -04:00
Torkel Ödegaard
77f7e8dafc
PageLayouts: Updates dashboard section routes with navId (#52175)
* First stab at new page layouts behind feature toggle

* Simplifying PageHeader

* Progress on a new model that can more easily support new and old page layouts

* Progress

* rename folder

* Progress

* Minor change

* fixes

* Fixing tests

* Make breadcrumbs work

* Add tests for old Page component

* Adding tests for new Page component and behavior

* fixing page header test

* Fixed test

* Moving user profile routes to navId

* PageLayouts: Updates dashboards routes with navId

* added missing navId

* AppChrome outside route

* Renaming folder

* Minor fix

* Updated

* Fixing StoragePage

* Updated

* Updating translation ids

* Updated snapshot

* update nav translation ids (yes this is confusing)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: joshhunt <josh@trtr.co>
2022-07-20 17:26:52 +02:00
Sven Grossmann
6cab909132
Loki: Fix show context not working in some occasions (#52458)
* added missing `languageProvider.start` call

* moved `languageProvider.start`
2022-07-20 12:28:11 +02:00
Levente Balogh
d6d49d8ba3
DataSources: refactor datasource pages to be reusable (#51874)
* refactor: move utility functions out of the redux actions

* refactor: move password handlers to the feature root

* refactor: move API related functions to an api.ts

* refactor: move components under a /components folder

* refactor: move page containers under a /pages folder and extract components

* refactor: update mocks to be easier to reuse

* refactor: move tests into a state/tests/ subfolder

* refactor: expose 'initialState' for plugins

* refactor: move generic types to the root folder of the feature

* refactor: import path fixe

* refactor: update import paths for app routes

* chore: update betterer

* refactor: fix type errors due to changed mock functions

* chore: fix mocking context_srv in tests

* refactor: udpate imports to be more concise

* fix: update failing test because of mocks

* refactor: use the new `navId` prop where we can

* fix: use UID instead ID in datasource edit links

* fix:clean up Redux state when unmounting the edit page

* refactor: use `uid` instead of `id`

* refactor: always fetch the plugin details when editing a datasource

The deleted lines could provide performance benefits, although they also make the
implementation more prone to errors. (Mostly because we are storing the information
about the currently loaded plugin in a single field, and it was not validating if it
is for the latest one).

We are planning to introduce some kind of caching, but first we would like to clean up
the underlying state a bit (plugins & datasources.

* fix: add missing dispatch() wrapper for update datasource callback

* refactor: prefer using absolute import paths

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>

* fix: ESLINT import order issue

* refactor: put test files next to their files

* refactor: use implicit return types for components

* fix: remove caching from datasource fetching

I have introduced a cache to only fetch data-sources once, however as we
are missing a good logic for updating the instances in the Redux store
when they change (create, update, delete), this approach is not keeping the UI in sync.
Due to this reason I have removed the caching for now, and will reintroduce it once we have a
more robust client-side state logic.

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-07-20 09:25:09 +02:00
Torkel Ödegaard
8d92417a16
Scenes: Improve typing of scene state to avoid type guards and casting (#52422)
* Trying to get rid of type guard but failing

* Improve typing of scene object state

* Fixed wrongly renamed event

* Tweaks
2022-07-19 17:46:49 +02:00
kay delaney
0142c8ccd1
Dashboard Links: Fix styles for very long dashboard titles (#52443) 2022-07-19 16:15:59 +01:00
Leo
c60487fdbf
Plugins: Convert BarGaugePanel to RTL (#52423)
* Plugins: Convert bargaugepanel tests to RTL

* Chore: Improved test methods used in BarGaugePanel
2022-07-19 14:17:22 +02:00
Torkel Ödegaard
4aae9d1567
Scene: Support for collapsable rows via a nested scene object (#52367)
* initial row test

* Updated

* Row is more of a nested collapsable scene

* Updated

* Added test for nested scene

* Added test for nested scene
2022-07-18 20:26:10 +02:00
Ivana Huckova
8ff152f98f
ModifyQuery: Improve typing for modifyQuery and query hints (#52326)
* ModifyQuery: Improve typing

* Elasticsearch: Added `modifyQuery` method to add filters in Explore (#52313)

* fixed elasticsearch `QueryFixAction` type

Co-authored-by: Sven Grossmann <Svennergr@gmail.com>
2022-07-18 14:13:34 +02:00
Artur Wierzbicki
b2736ac1fe
Storage: limit the number of uploaded files (#50796)
* #50608: sql file upload quotas

* rename `files_in_sql` to `file`

* merge conflict
2022-07-18 15:24:39 +04:00
Scott Lepper
53933972b6
mysql query editor - angular to react (#50343)
mysql conversion to react

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2022-07-15 16:49:24 -04:00
Zoltán Bedi
35d98104ad
MSSQL: Migrate to React (#51765)
* Fix: sql plugins feature

* SQLDS: Use builtin annotation editor

Plus strict rule fixes

* MSSQL: Migrate query editor to React

* Make code editor work

* Make SQLOptions and SQLQuery in SQLDatasource and in Editor generic

* MSSQL: Fix ts issues

* Fix SQLDatasource refID

* Remove comment

* Revert "Make SQLOptions and SQLQuery in SQLDatasource and in Editor generic"

This reverts commit 1d15b4061a.

* Fix ts issues without generic

* TS
2022-07-15 19:51:28 +02:00
Ryan McKinley
da1701ce57
Dashboards: load from storage (#51949) 2022-07-14 15:36:17 -07:00
Oscar Kilhed
9498ee3d54
SQL: Migrate (MS/My/Postgres)SQL configuration pages from Angular to React (#51891)
* Migrate SQL configuration pages from angular to react

* Move enums to types.ts and remove angular partials

* remove es lint disables and update betterer instead

* Fix automatically added type declarations

* Bump wor.. betterer ;)

* Export SecretInput component from grafana-ui

* Fix A11y issues

* Export SecretTextArea as well

* Fix typo

* Use const instead of var

* Fix typo in doc

* Add autoDetectFeatures to postgres config editor

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2022-07-14 13:29:08 +02:00
Ivana Huckova
1d077e84ce
Loki: Add hint for pipeline error to query builder (#52134)
* WIP

* Update

* Add tests

* Fix lint/betterer errors

* Update public/app/plugins/datasource/loki/addToQuery.ts

* Update copy
2022-07-14 10:48:27 +02:00
Konrad Lalik
169a1c5b0f
Use non-blocking way of fetching ruler api availability (#52102)
Co-authored-by: Joe Blubaugh <joe.blubaugh@grafana.com>
2022-07-13 11:50:20 +02:00
Ryan McKinley
ededf1dd6f
Graph: move time region calculation to a utility function (#51413) 2022-07-12 12:09:49 -07:00
Adela Almasan
c73d78eaac
Canvas: Tree View Navigation (#51855)
* tree navigation using rc-tree library
2022-07-12 08:31:02 -05:00
Zoltán Bedi
4155dc8eca
SQL: Fix couple of issues in SQLDatasource (#52080)
* Fix: sql plugins feature

(cherry picked from commit 035862bade)

* SQLDS: Use builtin annotation editor

Plus strict rule fixes

(cherry picked from commit fee2eb3716)
2022-07-12 14:11:54 +02:00
Torkel Ödegaard
4d4ab87bb6
Page: Update profile page components to use new navId (#51664) 2022-07-11 14:35:30 +02:00
Joey Tawadrous
5aacc7cc2a
Traces: More feature tracking (#51686)
* Added tracing for json upload, service graph, loki queries

* Tracking for node graph expand/collapse

* Tracking for traceID expand/collapse

* Updated betterer.results

* Update tests

* Updated betterer.results

* Fixed?

* Fix for test

* Update report interaction key for loki expr

* Change grafana_traces_search_queried limit to resultLimit as limit is reserved keyword
2022-07-11 10:21:24 +01:00
Leon Sorokin
fda7f064ad
GraphNG: uPlot 1.6.22 (#51945) 2022-07-08 09:45:16 -04:00
Josh Hunt
0c88850070
Chore: Sync betterer results (#51963) 2022-07-08 14:19:17 +01:00
Ieva
0c33b9f211
Access control: Allow organisation admins to add existing users to org (#51668)
* check users with user add permission to access the invite endpoint

* undo unneeded changes

* tests and cleanup

* linting

* linting

* betterer

* betterer again

* fix prettier issue

Co-authored-by: jguer <joao.guerreiro@grafana.com>
2022-07-08 12:07:00 +01:00
Isabella Siu
8dd8c50dc4
CloudWatch: Add default log groups to config page (#49286)
Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>
2022-07-07 13:03:02 -04:00
ismail simsek
885c517983
Plugins: InfluxDB variable interpolation fix (#51917)
* Don't use regex on flux mode while applying template variables
2022-07-07 17:16:35 +02:00
Torkel Ödegaard
849134b5dd
Scene: Small refactorings and name changes (#51866)
* Rename onMount and onUnmount and some other small refactorings

* More refactorings fixing typescript issues
2022-07-07 16:49:05 +02:00
Ivana Huckova
10cb84e401
Loki: Implement hints for query builder (#51795)
* Loki: Implement hints for query builder

* Update name of file

* Update imports

* Refactor

* Remove unused import

* Unify

* Revert "Unify"

This reverts commit 78da0e27e3.

* Unify

* Fix types

* Fix tests

* Fix type error

* Simplify

* Update test

* Add documentation

* Update comment

* Add tests for addParserToQuery

* Smaller updates
2022-07-07 15:49:31 +02:00
Levente Balogh
99de3313f7
Datasources: Refactor the list page (#51438)
* refactor(Data Sources): rename file to follow naming convention

* refactor: use react-redux hooks for interacting with the store

* tests: update data-sources list related test files

* refactor: extract datasource list page contents

* refactor: pass dataSources to the DataSourcesList as a prop

* refactor: use proper typing for navIndex mocks
2022-07-07 11:15:34 +02:00
Torkel Ödegaard
935334cbda
Scene: POC for a future dashboard model and runtime (#50980)
* Playing around

* This is getting interesting

* Updates

* Updated

* Observable experiments

* This is tricky

* VizPanel panel renderer

* New model progress

* Maybe this could be something

* Updated

* Rename

* updates

* Updated

* Query runners? not sure

* Updated

* updates

* flex box layout starting to work

* Testing

* Tested an action

* Parent context sort of working

* Progress

* Progress

* Updated

* Starting to work

* Things are working

* Scene list, nested scene demo

* Progress on repeats

* Moving things

* Pretty big progress

* More things working

* Great progress

* Progress

* Name changing

* Minor tweaks

* Simplified sizing

* Move toggleDirection to SceneFlexLayout

* add feature flag (#50990)

* removed new useObservable hook

* Rename folder and feature toggle to scenes

* Caching scenes so you can go back to another scene without having to re-query data

* Fix issue with subs on re-mount

* Fixing test

* Added SceneCanvasText to play around with layout elements with size based on content

* Scene: Edit mode and component edit wrapper that handles selection  (#51078)

* First step for scene variables

* Started playing around with a scene edit mode

* Better way to set component

* Progress on edit mode

* Update

* Progress on edit mode

* Progress on editor

* Progress on editor

* Updates

* More working

* Progress

* Minor update

* removed unnessary file

* Moving things around

* Updated

* Making time range separate from time picker

* minor rename of methods

* The most basic variable start

* Minor renames

* Fixed interpolate issue if not found at closest level

* An embryo of event model and url sync handling

* Update url sync types

* Removed unnessary any type arg

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-07-07 08:53:02 +02:00
Torkel Ödegaard
4f931afe29
Betterer: Rebuild better results file as it was corrupt (#51861) 2022-07-07 08:32:56 +02:00
owensmallwood
0b4af38bfa
Public Dashboards: Query Caching (#51403)
* passes id and uid to PublicDashboardDatasource

* betterer results

* If for a public dashboard, return the PublicDashboardDataSource first or else getDatasourceSrv.get() will fail bc of no authed user.

Added some unit tests for resolving the uid from the many possible datasource types.

* updates betterer

* Exports DashboardService. Adds method to DashboardService to build anonymous user for use with public dashboards where there is no authed user. Adds method on dashboard_queries to get all dashboard uids from a dashboard.

* refactors to get unique datasource uids

* Adds tests for getting all unique datasource uids off a dashboard

* adds test for building anonymous user with read and query actions that are scoped to each datasource uid in the dashboard

* updates casing of DashboardService

* updates test case to have additional panel with a different datasource

* gives default interval to public dashboard data source
2022-07-06 12:42:39 -06:00
Kevin Yu
b5eef488ce
Cloud Monitoring: Update LabelFilter to use experimental UI components (#51342)
* add label filter

* add tests

* define labels once

* update betterer results
2022-07-06 11:28:54 -04:00
Torkel Ödegaard
1e85a6f4fd
TopNav: New page layouts (#51510)
* First stab at new page layouts behind feature toggle

* Simplifying PageHeader

* Progress on a new model that can more easily support new and old page layouts

* Progress

* rename folder

* Progress

* Minor change

* fixes

* Fixing tests

* Make breadcrumbs work

* Add tests for old Page component

* Adding tests for new Page component and behavior

* fixing page header test

* Fixed test

* AppChrome outside route

* Renaming folder

* Minor fix

* Updated

* Fixing StoragePage

* Fix for banners

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-07-06 17:00:56 +02:00
Joey Tawadrous
45a00bdc94
Traces: Move towards using OTEL naming conventions (#51379)
* Updates names

* Update tests

* Update betterer results

* Updated betterer.results

* Updated tests
2022-07-06 11:12:53 +01:00
Joey Tawadrous
01130f22b7
Traces: Span bar label (#50931)
* Add SpanBarSettings

* Add SpanBarSettings to Jaeger

* Add SpanBarSettings to Zipkin

* Updated title

* Add dropdown to select identifer and make duration a default option

* Show duration by default

* Add option to hide

* Move identifers into constants

* Add process

* Update text

* Update placeholders

* Text/meta data updates

* Added tests

* Added docs

* Update find

* Merge tag and prcoess options

* Update docs

* Updated tests

* Update betterer results and trace view to match

* Updated docs
2022-07-06 08:14:03 +01:00
Alexander Zobnin
21591be469
Geomap: Support shared crosshair for route layer (#51495) 2022-07-06 10:08:55 +03:00
Josh Hunt
ffd9d9d0c5
Chore: Refactor logs_model to clean up types (#51201)
* Chore: Minor refector of logs_model to clean up types

* undo a change i didn't commit to

* use isObservable instead

* fix type
2022-07-06 08:49:45 +02:00
Ryan McKinley
4a00c7ebde
Storage: Add basic file upload management (#50638) 2022-07-05 10:53:41 -07:00
eledobleefe
13fbe6ed28
Storybook: Add documentation to PluginSignatureBadge story (#51645)
* Import the mdx documentation file to PluginSignatureBadge.story.tsx and add to its export defaul

* Create the mdx file of PluginSignatureBadge with its information

* Fix signed PluginSignatureBadge status

* Modify text according to reviewer suggestions

* betterer

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-07-05 09:38:26 -04:00
Seyaji
500010e0b6
Chore: Convert QueryOperationRow test to RTL (#51290)
* Convert QueryOperationRow test to RTL

* Convert QueryOperationRow test to RTL

* Convert QueryOperationRow test to RTL

* Convert QueryOperationRow test to RTL

* Update QueryOperationRow.test.tsx

* update betterer

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-07-05 08:10:20 -04:00
kay delaney
d4eef3bd76
TimeSrv: Don't modify refresh interval when editing panel (#51718) 2022-07-05 05:25:07 -04:00
Pawan Verma
920bd1e88d
Chore: Improve SecretInput story (#51665)
* Added mdx file for secret input

* Chore: Improve SecretInput story

* review related changes in docs

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-07-05 09:32:51 +01:00
Sriram
f78b7f1f17
TestDataDB: update CSV wave scenario ui (#51719)
* update testdb csv wave

* support enter key

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-07-05 04:57:32 +01:00
Ashley Harrison
986b766ca0
Chore: Make betterer tests more stable (#51703)
* rewrite eslint test to not care about position of errors

* changing file contents shouldn't require a betterer.results update

* fix up eslint test

* fix the undocumented stories test

* ignore .test.ts files as well
2022-07-04 12:13:20 +01:00
Ivan Ortega Alba
f8ac160545
DashboardRow: collapse shortcut doesn't allow to move the row (#51589) 2022-07-04 12:32:21 +02:00
Zoltán Bedi
ebb9025669
StateTimeline: Try to sort time field (#51569)
* StateTimeline: Try to sort time field

* Sort frame earlier
2022-07-04 10:11:33 +02:00
Seyaji
e88514beea
Chore: Convert SpanDetailsRow test to RTL (#51345)
* Convert SpanDetailsRow test to RTL

* Convert SpanDetailsRow test to RTL
2022-07-04 10:30:03 +03:00
Alexander Emelin
a2478c3a32
Search: Sort by updated at and created at (#50416)
Co-authored-by: Artur Wierzbicki <artur.wierzbicki@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-06-30 16:33:30 -07:00
Scott Lepper
fa560d96b6
sql plugins - angular to react - base sql datasource (#51655)
* base sql datasource and components
2022-06-30 16:38:48 -04:00
Ryan McKinley
281ed419a8
Chore: add generics to backendSrv (#51606) 2022-06-30 14:34:23 -04:00
Ryan McKinley
c0f10af545
SearchV2: Use the same components for both SQL and bluge backends (#50125) 2022-06-30 12:45:45 -04:00
Gilles De Mey
d63ffa314e
Alerting: Fix normalization of alert states for panel annotations (#51637)
A bug introduced by #49259 would crash the annotations view of a panel with a linked alert rule. States are now normalized so crashes won't occur and the base state is used instead.
2022-06-30 10:46:54 -04:00
Ivana Huckova
66b4a9e6a1
Loki: Remove unused prop from query builder (#51504) 2022-06-30 16:02:27 +02:00
Gilles De Mey
a1fb73c503
Alerting: Adds contact point template syntax highlighting (#51559) 2022-06-30 14:01:02 +02:00
Konrad Lalik
117bac71f5
Alerting: Use folders' RBAC permission to control rules actions (#51434)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-06-30 13:00:29 +02:00
Ashley Harrison
2a6b32598d
Chore: some low-hanging type assertion fruit (#51618)
* some low-hanging type assertion fruit

* results
2022-06-30 10:40:00 +01:00
Leon Sorokin
3bd2bdcebb
DataFrame: more thorough detection of unsorted values (#51602) 2022-06-29 18:08:42 -05:00
user10x
39bd3e2fe3
rename logs_model.ts->logsModel.ts; update references (#51468) 2022-06-29 21:04:30 +02:00
Leon Sorokin
1f939f64e9
ColorScale: prevent vertical scrollbar in container during hover (#51591) 2022-06-29 14:34:12 -04:00
Nathan Marrs
b0f1d35708
Search: Refine clear tags UI #51590 2022-06-29 14:16:49 -04:00
Nathan Marrs
35240f6d5a
Annotations: Fix custom tag functionality (#51537) 2022-06-29 13:37:50 -04:00
Nathan Marrs
66c911f263
Canvas: Stop selecto box from triggering when programmatically selecting elements (#51579)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-06-29 13:19:48 -04:00
Nathan Marrs
5d9ffe54ee
Canvas: Enable multi-select via shift key 2022-06-29 10:00:58 -07:00
Seyaji
2473dc68f6
Chore: Convert KeyValuesTable to RTL (#51278)
* Convert KeyValuesTable to RTL

* Update data-testid

* Update data-testid

* Convert KeyValuesTable to RTL

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-06-29 16:44:48 +01:00
kay delaney
8053f770c1
Export: Fix export/import of dash with library panels (#49319) 2022-06-29 16:18:27 +01:00
Ashley Harrison
67802e64e6
keep the betterer message generic (#51563) 2022-06-29 15:57:49 +01:00
ismail simsek
0de544f3a2
Handle scalar and string resultType separately (#51411) 2022-06-29 16:43:33 +02:00
Michael Mandrus
7ef21662f9
Plugins: Show that Secrets Manager Plugin is active in the UI (#50953)
* add special handling on the plugin gathering side to check whether secrets manager plugins are enabled or not

* show disabled badge in front end if the plugin is not enabled

* Only show error in disabled badge hover if one is present (otherwise it shows "undefined")

* refactor to make use of fields already available in the DTO

* fix typo

* if there is no error returned for the plugin, just show 'disabled'

* fix typo

* Update public/app/features/plugins/admin/components/Badges/PluginDisabledBadge.tsx

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>

* Update frontendsettings.go

add clarifying comment

* fix unit test

* rework task to use new frontend property combined with plugin type to determine if the plugin should be disabled

* Update helpers.test.ts

revert test change

* fix unit test

* bogus commit to trigger precommit

* undo commit

* run precommit manually

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2022-06-29 08:48:23 -04:00
Polina Boneva
f83f05d6b3
Variables: variables in Markdown links are not interpolated (#51392)
* on a text panel first interpolate, then markdown, then sanitize;

* update devenv dashboard + e2e tests

* fix typo and undo changes in grafana/data

* handling of config option disableSanitizeHtml more readable when preparing markdown in text panel

* betterer

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-06-29 15:26:31 +03:00
Ashley Harrison
688164bbd6
Chore: add a betterer test for undocumented stories (#51444)
* add a betterer test for undocumented stories

* update results

* Update .betterer.ts

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>

* update results

* prettier

* slightly nicer regexp

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2022-06-29 12:25:31 +01:00
Ivana Huckova
60454192b7
Loki: Add e2e test for query builder (#51314)
* Loki: Add e2e test for query builder

* Update

* Update test

* Update test

* Update test

* Update test

* Add more checks in test

* Update betterer

* Update betterer
2022-06-29 11:04:27 +02:00
Ashley Harrison
683bbc7373
Templating: Changing between variables with the same name now correctly triggers a dashboard refresh (#51490)
* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:public/app/features/variables/pickers/OptionsPicker/actions.ts

* user essentials mob! 🔱

lastFile:public/app/features/variables/pickers/OptionsPicker/actions.test.ts

* linting

* update betterer

Co-authored-by: kay delaney <kay@grafana.com>
2022-06-29 09:10:55 +01:00
Leon Sorokin
d32ec75661
HeatmapNG: expand log y axis min/max config to full powers (#51472)
also fix x bucket count setting for calculate (regressed in #51089)

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-06-28 19:13:13 -05:00
Dominik Prokop
daf0e3cb4e
Bar chart: Fix stacking bug when data produces 0 accumulators (#51450)
* Don't divide by 0 ...

* Add test panel to gdev dashboard
2022-06-28 07:21:18 -07:00
Torkel Ödegaard
f047f7dcf6
TopNav: A possible approach having a TopNav that lives outside route (#51301)
* Add topnav in Route

* TopBar: Good progress on a approach that looks promising

* Added some elements to top level

* Get page nav from route

* Progress

* Making breadcrumbs slightly more real

* Updates

* Memoize selector

* Removed some console.log

* correctly type iconName

* betterer updates

* Change setting to hideNav

* Rename again

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-06-28 09:47:12 -04:00
Seyaji
37c6a0b3cb
Chore: Convert AccordianReferences test to RTL (#51274)
* Convert AccordianReferences test to RTL

* Convert AccordianReferences test to RTL

* Convert AccordianReferences test to RTL

* Convert AccordianReferences tests to RTL

* Convert AccordianReferences test to RTL

* fix betterer

* Convert AccordianReferences test to RTL

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-06-28 11:20:37 +01:00
Gilles De Mey
97c9b25d44
Alerting: Skip the default data source if incompatible (#51452) 2022-06-28 10:05:53 +02:00
Timur Olzhabayev
7c886fb6f9
Frontend Logging: Integrate grafana javascript agent (#50801)
Add Grafana Javascript Agent integration to Grafana
2022-06-28 03:25:30 -04:00
Ryan McKinley
b6a9b9804d
Plugin admin: Add a page to show where panel plugins are used in dashboards (#50909) 2022-06-27 20:23:43 -04:00
Leon Sorokin
fd6c7d518d
TimeSeries: Improved constantY rendering parity with Graph (old) (#51401)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-06-27 19:02:05 -05:00
Leon Sorokin
89b150ab58
HeatmapNG: pre-allocate arrays during calc (#51465) 2022-06-27 18:43:59 -05:00
Ryan McKinley
cfbfacb152
Heatmap: migrate old zero gap to one (#51467) 2022-06-27 19:13:09 -04:00
Ezequiel Victorero
99f921cf32
Public Dashboards: adding telemetry for Sharing Modal options and Public Dashboards events (#50834)
* Public Dashboards: adding telemetry for Sharing Modal options and Public Dashboards events
2022-06-27 12:33:30 -03:00
Ashley Harrison
ee3f4f1709
Navigation: Display Starred dashboards in the Navbar (#51038)
* remove feature toggle, add empty state and fix bug with initial starring

* Extract empty message into lingui

* remove full stop

* add empty message in the backend

* remove unused import

* translate starred + empty starred states

* betterer changes
2022-06-27 15:41:00 +01:00
Daniel Lee
292b24e30d
Piechart: Implements series override -> hide in area for the legend or tooltip (#51297)
* piechart: support series override for hiding legend item

* piechart: add support for hiding values in multi tooltip

* tidy up variable names

* piechart: typing for hideFrom variable

* betterer fixes
2022-06-27 15:13:19 +02:00
Dominik Prokop
b2b0be7b93
Table panel: Add multiple data links support to Default, Image and JSONView cells (#51162)
* Table panel: Support multiple data links in default cell

* Table panel: Show data links for Image and JSONView cells

* Simplify DataLinksContextMenu api

* Betterer
2022-06-27 05:23:29 -07:00
Dominik Prokop
4a397c9c24
Time series panel: Hide axis when series is hidden from the visualization (#51432)
* Time series panel: Hide axis when series is hidden from the visualization

* Fix snap
2022-06-27 08:17:46 -04:00
Joao Silva
f2d8b1ceee
Dashboards: Fixes issue with the initial panel layout counting as an unsaved change (#51315) 2022-06-27 12:30:59 +01:00
Nathaniel Saxe
683f31f2c6
Variables: improve performance of transformMetricFindResponse (#49360)
* improve performance of transformMetricFindResponse

* use lodash uniqBy for postgres

* use lodash uniqBy for mysql

* use lodash uniqBy for mssql

* hopefully conform to import linting rules

* Added .betterer.results

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Victor Marin <victor.marin@grafana.com>
2022-06-27 14:26:46 +03:00
Ashley Harrison
0124dc8e6b
Chore: reintroduce type assertion test + change emitted metric names (#51375)
* reintroduce type assertion test + change emitted metric names

* rename test to better eslint to be more generic
2022-06-25 07:45:38 -04:00
Ryan McKinley
c8f814196a
CommandPalette: Populate dashboard search when the palette is opened (#51293)
Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
2022-06-24 23:08:29 +02:00
Ivana Huckova
d3dd3042d6
Loki: Fix support of ad-hoc filters for specific queries (#51232)
* Loki: Refactor ad-hoc filters to use parser

* Remove renaming of files for easier review

* Update

* Update

* Add previously buggy test

* Fix tests

* Fix typos

* Update, improve typing

* Move reused code up

* Update order

* Update betterer statss
2022-06-24 22:29:22 +02:00
Artur Wierzbicki
c496b3e712
Search: Fix pagination in the new search page (#51366)
* Fix pagination in the new search

* update betterer betterer betterer betterer betterer betterer

* revert packagejson
2022-06-24 21:21:59 +04:00
Todd Treece
342344bb03
Variables: Selectively reload panels on URL update (#51003) 2022-06-24 13:06:36 -04:00
Leon Sorokin
7e1667ce87
HeatmapNG: explicitly pass scales for cursor sync config (#51389) 2022-06-24 11:42:39 -05:00
Connor Lindsey
620309ced5
Explore: Sort trace process attributes alphabetically (#51261)
* Explore: Sort trace process attributes alphabetically

* Update betterer?
2022-06-24 08:20:23 -06:00
Jguer
9a82ed7105
Remove LDAP specific example from team sync (#51368)
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2022-06-24 15:29:50 +02:00
ismail simsek
c804639b53
Hide datalink button when datasource for exemplar is undefined (#51236) 2022-06-24 15:26:52 +02:00
Ashley Harrison
fa466e2134
Chore: comment out type assertions check due to bug (#51371)
* comment out type assertions check due to bug

* forgot to push the merge 🤦
2022-06-24 11:56:31 +01:00
Joey Tawadrous
adfe4ef564
Update betterer tests (#51370) 2022-06-24 11:21:03 +01:00
Ryan McKinley
588bd43e49
Chore: update betterer.results for heatmap rename (#51361) 2022-06-24 00:10:03 -07:00
Isabella Siu
497310a9cb
CloudWatch: Factor LogGroupSelector into a separate component (#50829) 2022-06-23 14:40:43 -04:00
Isabella Siu
8ba8e1df83
CloudWatch: fix variable query migration with json template variables (#51207)
* CloudWatch: fix variable query migration with json template variables

* fix error messages

* changes for reviews

* fix lint

* fix betterer
2022-06-23 14:23:56 -04:00
Ryan McKinley
a093250dd5
Chore: avoid implicit any by using inline functions (#51338) 2022-06-23 11:19:08 -07:00
Seyaji
91ee019140
Convert TimelineCollapser test to RTL (#51281) 2022-06-23 18:20:16 +01:00
Ezequiel Victorero
25d4ddf959
PublicDashboards: disable annotations (#50984)
* PublicDashboards: disable annotations
2022-06-23 13:09:30 -03:00
Ashley Harrison
64356509b5
upate betterer results again.... (#51336) 2022-06-23 17:49:28 +02:00
Josh Hunt
78ee9ffa37
Chore: Remove CI stats that are also reported by betterer (#51318)
* Chore: Remove CI stats that are reported by betterer

* update betterer results
2022-06-23 14:20:45 +02:00
Seyaji
ec1480b964
Chore: Convert DataSourceDashboards test to RTL (#51294)
* Convert DataSourceDashboards test to RTL

* Convert DataSourceDashboards test to RTL

* Convert DataSourceDashboards test to RTL

* Update public/app/features/datasources/DataSourceDashboards.test.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Convert DataSourceDashboards test to RTL

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-06-23 14:39:00 +03:00
Ashley Harrison
2705edf5f5
update betterer cache (#51317) 2022-06-23 13:26:31 +02:00
Ashley Harrison
ded3d53d89
Chore: Additional betterer tests for type assertions and explicit any (#45901)
* Add betterer tests to prevent adding more type assertions and explicit any's into the codebase

* update betterer results file

* better glob matching

* updated results

* update results again...

* use more up to date betterer packages

* they're devdeps...

* Commit latest betterer results

* latest .betterer.results

Co-authored-by: joshhunt <josh@trtr.co>
2022-06-23 11:36:20 +01:00
Polina Boneva
496c2e26f4
I18n: User and Org Preferences allow change of Language (#51175)
* add locale selection settings under preferences; Alpha feature toggle;

* extract components' ids for internationalisation references

* migrate OrgDetailsPage tests from Enzyme to RTL

* test locale selection in shared preferences

* fix OrgDetailsPage needing a fetch polyfill; "Real fetch shouldn't be being hit." - Josh

* remove snapshot

* remove snapshot
2022-06-23 11:20:31 +03:00
Seyaji
0b1a886b9d
Chore: Convert GraphTicks test to RTL (#51203)
* Convert GraphTicks test to RTL

* Convert GraphTicks test to RTL
2022-06-23 10:55:38 +03:00
Seyaji
a0949314ef
Convert AccordianLogsTest to RTL (#51260)
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-06-22 19:00:04 +02:00
Seyaji
fe5416508a
Chore: Convert TracePageHeader test to RTL (#51216)
* Convert TracePageHeader test to RTL

* Convert TracePageHeader test to RTL

* Convert TracePageHeader test to RTL
2022-06-22 17:46:36 +01:00
Seyaji
d760b03784
Convert AccordianKeyValues test to RTL (#51257) 2022-06-22 17:42:04 +01:00
Seyaji
5ad3d10016
Convert CanvasSpanGraph test to RTL (#51180) 2022-06-22 14:46:01 +03:00
Seyaji
0bfd48c164
Chore: Convert DataLinks tests to RTL (#51137)
* Convert DataLinks tests to RTL

* Convert DataLinks test to RTL

* Convert DataLinks test to RTL

* Convert DataLinks test to RTL
2022-06-21 15:55:10 +01:00
Seyaji
bab017799e
Chore: Convert QueryOperationAction test to RTL (#51139)
* Convert QueryOperationAction test to RTL

* Convert QueryOperationAction to RTL

* Convert QueryOperationAction test to RTL
2022-06-21 15:53:10 +01:00
Seyaji
3710c9a7c8
Chore: Convert DataSourcesListPage test to RTL (#51138)
* Convert DataSourceListPage test to RTL

* Convert DataSourceListPage test to RTL
2022-06-21 11:47:54 +01:00
Seyaji
902101c524
Chore: Convert PanelHeaderCorner test to RTL (#51074)
* export props

* Convert PanelHeaderCorner test to RTL

* Update public/app/features/dashboard/dashgrid/PanelHeader/PanelHeaderCorner.test.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-06-20 14:54:13 +02:00
Seyaji
606732dd5e
Chore: Converts ButtonRow tests to RTL (#51068) 2022-06-20 15:46:11 +03:00
Seyaji
e4f4cc4a32
Chore: Convert pageActionBar test to RTL (#51073)
* Convert pageActionBar test to RTL

* add test for conditional render of button
2022-06-20 15:42:56 +03:00
Seyaji
244650835e
Refactor 'Basic Settings' test to RTL from Enzyme (#51059)
* Refactor 'Basic Settings' test to RTL from Enzyme

* Update public/app/features/datasources/settings/BasicSettings.test.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Refactor 'Basic Settings' test to RTL from Enzyme

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-06-18 13:13:51 +03:00
Ashley Harrison
3430928294
Convert InviteesTable test to RTL (#50674) 2022-06-15 09:54:26 +01:00
Joey Tawadrous
f87927c82e
Traces: Add absolute time to span details (#50685)
* Show absolute time

* Add test
2022-06-14 11:13:33 +01:00
Alex Khomenko
701edcdc46
UserListPage: Convert tests to RTL (#50717) 2022-06-14 11:39:43 +03:00
Ashley Harrison
d23bc5c390
Convert ApiKeysAddedModal test to RTL (#50669) 2022-06-13 14:52:17 +01:00
Alex Khomenko
fd239f94e8
TeamSettings: Convert tests to RTL (#50513) 2022-06-10 09:50:53 +02:00
Ashley Harrison
6da4feb2a9
Convert OrgProfile test to RTL (#50525) 2022-06-09 16:07:40 +01:00
Alex Khomenko
ffb8ae4900
TeamPages: Convert tests to RTL (#50429)
* TeamPages: Setup tests

* TeamPages: Finalise tests

* TeamPages: Add missing test
2022-06-08 19:05:27 +03:00
Kevin Yu
8bd56b8226
Chore: convert Cloud Monitoring Aggregation enzyme tests to RTL (#50326) 2022-06-08 10:03:58 +02:00
Zoltán Bedi
aa74371008
Chore: Convert ReferenceLink.test.js to RTL (#50338) 2022-06-07 17:40:04 +02:00
Connor Lindsey
c65d62c95b
Tracing: Fix links to traces in Explore (#50113)
* Tracing: Fix links to traces in Explore

* Fix links in dashboard

* Fix references and tracetimelineviewer tests

* Remove hard-coded references to fix tests

* Add noopener
2022-06-07 07:21:01 -06:00
Joey Tawadrous
d20608ab84
Convert packages/jaeger-ui-components/src/TracePageHeader/TracePageSearchBar.test.js to RTL (#49992)
* Added new selectors

* Added selector to UIFindInput

* Added selectors to TracePageSearchBar

* Convert tests

* Remove next/prev button test ids

* Remove uiFindInput selector

* Remove tracePageSearchBar selector

* Remove tracePageSearchBarSuffix selector

* Update TraceViewContainer test
2022-06-06 16:31:51 +01:00
Ashley Harrison
6fcb2cd307
remove exported test globals from test/lib/common (#50256) 2022-06-06 15:38:37 +01:00
Ashley Harrison
22fbcebabf
Chore: convert DashboardsTable test to RTL (#50252)
* convert DashboardsTable test to RTL

* ensure render does not throw
2022-06-06 15:27:40 +01:00
Marcus Efraimsson
36c3398c6d
Datasource: Remove support for unencrypted passwords (#49987)
* Datasource: Remove support for unencrypted passwords

* regenerate swagger

* [WIP] Remove references to datasource password and basic auth password fields (#50015)

* try delete moar tings

* delete provisioning stuff

* remove from yaml

* update snapshots

* remove lingering snapshot fields

* fix ds http settings

* Re-generate swagger and fix swagger-api-spec make target

Co-authored-by: Will Browne <will.browne@grafana.com>
Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2022-06-03 17:38:22 +02:00
Ashley Harrison
0de9808008
Draggable: only set drag handle props on the drag handle itself (#50025) 2022-06-02 13:34:05 +02:00
Joey Tawadrous
6703722278
Updated test (#50041) 2022-06-02 09:47:02 +01:00
Joey Tawadrous
3d26502db1
Convert packages/jaeger-ui-components/src/common/UiFindInput.test.js to RTL (#49994)
* Add selector

* Add test

* Remove snapshot

* Remove uiFindInput selector
2022-06-02 09:46:31 +01:00
Kevin Yu
dca0453c2e
CloudWatch: Add multi-value template variable support for log group names in logs query builder (#49737)
* Add multi-value template variable support for log group names

* add test for multi-value template variable for log group names

* add test
2022-06-01 10:23:31 -07:00
polibb
a19c3dae5a
Convert Enzyme UsersTable test to RTL (#49836)
* Convert Enzyme UsersTable test to RTL

* Fixes on UsersTable test; no additions

* remove snapshot of UsersTable test
2022-05-31 18:58:59 +03:00
Joao Silva
a91ecc566b
Chore: Converts DashboardRow tests to RTL (#49722) 2022-05-31 16:51:44 +01:00
Alex Khomenko
0a48b92d28
TeamMembers: Refactor test to RTL (#49922) 2022-05-31 17:11:12 +03:00
Zoltán Bedi
8e0342bc74
Chore: convert NewWindowIcon test to rtl (#49830) 2022-05-31 14:34:46 +02:00
Alex Khomenko
bfbe856319
TeamMemberRow: Convert tests to RTL (#49875)
* TeamMemberRow: Remove legacy select

* TeamMemberRow: Update attributes

* TeamMemberRow: Refactor tests to RTL
2022-05-31 10:33:27 +02:00
Zoltán Bedi
f87c1b0eb9
Chore: Convert FolderPicker test to rtl (#49838) 2022-05-30 17:36:16 +02:00
kay delaney
bae9a60089
Chore: Convert legacy Input test to RTL (#49713) 2022-05-26 17:10:35 +01:00
Ashley Harrison
a12cdf8283
convert PartialHighlighter test to RTL (#49708) 2022-05-26 17:09:44 +01:00
Ashley Harrison
43249464bb
convert bargauge test to RTL (#49701) 2022-05-26 14:58:01 +01:00
Ashley Harrison
ec65332c82
convert Typeahead test to RTL (#49509) 2022-05-25 16:53:55 +01:00
Ashley Harrison
970c395fb1
Cue: Use BarGauge, DashList and Gauge panel cue schemas (#49580)
* user essentials mob! 🔱

* Wip

* user essentials mob! 🔱

lastFile:public/app/plugins/panel/bargauge/module.tsx

* user essentials mob! 🔱

* update betterer results file

Co-authored-by: kay delaney <kay@grafana.com>
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
Co-authored-by: Joao Silva <joao.silva@grafana.com>
2022-05-25 14:18:21 +01:00
Karl Persson
ef6b53ed23
AccessControl: Pass current org id to UsersTable (#49584)
* Pass current org id to UsersTable

* Mock contextSrv and update snapshot
2022-05-25 13:56:36 +02:00
Piotr Jamróz
f93ad85b08
Chore: Convert a test from enzyme to testing library (#49492) 2022-05-25 12:19:51 +02:00
Alex Khomenko
5557d2e666
TeamList: Convert test to RTL (#49567) 2022-05-25 13:01:40 +03:00
Joao Silva
71ffa5e5db
Chore: Converts SaveDashboardAsForm tests to RTL (#49436) 2022-05-24 10:17:40 +01:00
Joao Silva
51bc1bad1b
Chore: Converts SaveDashboardForm tests to RTL (#49434) 2022-05-23 18:17:25 +01:00
Alex Khomenko
18727f0bf5
TeamGroupSync: Refactor tests to use RTL (#49417) 2022-05-23 16:45:36 +02:00
Piotr Jamróz
060f0e5633
Query History: Results pagination (#49217)
* Load Rich History when the container is opened

* Store rich history for each pane separately

* Do not update currently opened query history when an item is added

It's impossible to figure out if the item should be added or not, because filters are applied in the backend. We don't want to replicate that filtering logic in frontend. One way to make it work could be by refreshing both panes.

* Test starring and deleting query history items when both panes are open

* Remove e2e dependency on ExploreId

* Fix unit test

* Assert exact queries

* Simplify test

* Fix e2e tests

* Fix toolbar a11y

* Reload the history after an item is added

* Fix unit test

* Remove references to Explore from generic PageToolbar component

* Update test name

* Fix test assertion

* Add issue item to TODO

* Improve test assertion

* Simplify test setup

* Move query history settings to persistence layer

* Fix test import

* Fix unit test

* Fix unit test

* Test local storage settings API

* Code formatting

* Fix linting errors

* Add an integration test

* Add missing aria role

* Fix a11y issues

* Fix a11y issues

* Use divs instead of ul/li

Otherwis,e pa11y-ci reports the error below claiming there are no children with role=tab:

Certain ARIA roles must contain particular children
   (https://dequeuniversity.com/rules/axe/4.3/aria-required-children?application=axeAPI)

   (#reactRoot > div > main > div:nth-child(3) > div > div:nth-child(1) > div >
   div:nth-child(1) > div > div > nav > div:nth-child(2) > ul)

   <ul class="css-af3vye" role="tablist"><li class="css-1ciwanz"><a href...</ul>

* Clean up settings tab

* Remove redundant aria label

* Remove redundant container

* Clean up test assertions

* Move filtering to persistence layer

* Move filtering to persistence layer

* Simplify applying filters

* Split applying filters and reloading the history

* Debounce updating filters

* Update tests

* Fix waiting for debounced results

* Clear results when switching tabs

* Improve test coverage

* Update docs

* Revert extra handling for uid (will be added when we introduce remote storage)

* Create basic plan

* Rename query history toggle

* Add list of supported features and add ds name to RichHistoryQuery object

* Clean up

Removed planned items will be addressed in upcoming prs (filtering and pagination)

* Handle data source filters

* Simplify DTO conversion

* Clean up

* Fix betterer conflicts

* Fix imports

* Fix imports

* Post-merge fixes

* Use config instead of a feature flag

* Use config instead of a feature flag

* Update converter tests

* Add tests for RichHistoryRemoteStorage

* Simplify test setup

* Simplify assertion

* Add e2e test for query history

* Remove duplicated entry

* Fix unit tests

* Improve readability

* Remove unnecessary casting

* Mock backend in integration tests

* Remove unnecessary casting

* Fix integration test

* Update betterer results

* Fix unit tests

* Simplify testing with DataSourceSrv

* Fix sorting and add to/from filtering

* Basic pagination

* Show load more only if there are items to load

* Post-merge fixes

* Change initial page limit to 100

* Fix unit tests

* Fix linting errors

* Test pagination

* Fix query migration

* Fix unit tests

* Fix prettier

* Remove full stop

* Do not show number of queries with partial results to avoid confusion

* Show number of displayed results when partial results are shown
2022-05-23 14:43:38 +02:00
svennergr
2949ebc264
Traces: Fixed missing CopyButton on KeyValueTables and overlapping of panels (#49271)
* rewrote `CopyIcon` to an functional component

- fixed missing `CopyIcon` on `KeyValuesTable`

* added fixed height of `30px` to `KeyValuesTable` to fix overlapping

* removed unused CopyIcon snapshot

* KeyValuesTable: moved `30px` height from `tr` to `td` to fix vertical alignment
2022-05-20 20:24:33 +02:00