Commit Graph

404 Commits

Author SHA1 Message Date
Torkel Ödegaard
3fae28be52
FieldOverride: Fixed number override so that it return undefined for null/undefined values and not NaN (#23344)
* FieldOverride: Fixed number override so that it return undefined for null/undefined values and not NaN

* Made process function be able to return undefined an null
2020-04-05 06:52:33 +02:00
Ryan McKinley
6366e43a44
Chore: swap [value,time] order when converting to DataFrame (#23206) 2020-04-03 11:11:28 -07:00
Stephanie Closson
c5252f1b64
Toolkit: simplify the plugin ci docker image (#23267)
* removing src dir on publish

* Moved from binary to native typescript
1. Moved to a native typescrpt github publish using the existing
github client.
2. Change dist.js to detect running in a linked environment.
Todo: Optimize docker image for build size.

* Optimized build of docker container
Much smaller. From 5.47 gb to 2.88

* Feedback from discussion with Ryan
- Added gget for getting grafana versions
- Added infrastructure for testing
- Uploaded new docker image

* Fixed typo... Not sure what happened there :)

* Added command to download canary

* small fix for displaying versions in help

* Removed --dev option
Should really just rename version to (ex: 1.2.0-dev)

* removing src dir on publish

* Moved from binary to native typescript
1. Moved to a native typescrpt github publish using the existing
github client.
2. Change dist.js to detect running in a linked environment.
Todo: Optimize docker image for build size.

* Optimized build of docker container
Much smaller. From 5.47 gb to 2.88

* Feedback from discussion with Ryan
- Added gget for getting grafana versions
- Added infrastructure for testing
- Uploaded new docker image

* Fixed typo... Not sure what happened there :)

* Added command to download canary

* small fix for displaying versions in help

* Removed --dev option
Should really just rename version to (ex: 1.2.0-dev)
2020-04-02 13:57:33 -06:00
Andrej Ocenas
a4d4dd325f
Explore: Add trace UI to show traces from tracing datasources (#23047)
* Add integration with Jeager
Add Jaeger datasource and modify derived fields in loki to allow for opening a trace in Jager in separate split.
Modifies build so that this branch docker images are pushed to docker hub
Add a traceui dir with docker-compose and provision files for demoing.:wq

* Enable docker logger plugin to send logs to loki

* Add placeholder zipkin datasource

* Fixed rebase issues, added enhanceDataFrame to non-legacy code path

* Trace selector for jaeger query field

* Fix logs default mode for Loki

* Fix loading jaeger query field services on split

* Updated grafana image in traceui/compose file

* Fix prettier error

* Hide behind feature flag, clean up unused code.

* Fix tests

* Fix tests

* Cleanup code and review feedback

* Remove traceui directory

* Remove circle build changes

* Fix feature toggles object

* Fix merge issues

* Add trace ui in Explore

* WIP

* WIP

* WIP

* Make jaeger datasource return trace data instead of link

* Allow js in jest tests

* Return data from Jaeger datasource

* Take yarn.lock from master

* Fix missing component

* Update yarn lock

* Fix some ts and lint errors

* Fix merge

* Fix type errors

* Make tests pass again

* Add tests

* Fix es5 compatibility

Co-authored-by: David Kaltschmidt <david.kaltschmidt@gmail.com>
2020-04-02 13:34:16 +02:00
Torkel Ödegaard
61e6e41ead
FieldConfig: Some name change suggestions and moving defaults to PanelPlugin (#23265)
* FieldConfig: Some name change suggestions and moving defaults to PanelPlugin

* More name changes
2020-04-02 13:24:50 +02:00
Dominik Prokop
dcf6bbc14f
NewPanelEditor: Options/FieldConfig API for defaults and common options selection (#23214)
* Add "some" typesafety to panel options/field config APIs

* Allow selected common field config properties config, allow option defaults config via fluent API

* Update packages/grafana-data/src/panel/PanelPlugin.ts

Co-Authored-By: Ryan McKinley <ryantxu@gmail.com>

* Add defaults support for custom field config

* Enable defaults setting for standard and custom field configs

* Remove setFieldConfigDefaults from PanelPlugin API and replace it with useStandardFieldConfig

* Update API for standard field config defaults

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2020-04-01 15:33:10 +02:00
flopp999
911a91308f
Units: add (IEC) and (Metric) (#23175)
since only bits and bytes is displayed when it is selected, I added (IEC) and (Metric)

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-03-30 20:47:13 +02:00
Hugo Häggmark
5307cfeabd
Transformers: adds series to column transformer (#23012)
* Refactor: adds first naive implemenation of join by field name

* Chore: changes after PR comments

* Refactor: fixes labels and adds support for multiple columns
2020-03-30 06:24:54 +02:00
Torkel Ödegaard
53630b5f13
StatPanels: Refactoring DisplayValueOptions and renaming & adding new panel options to react panels (#23153)
* StatPanels: Refactoring DisplayValueOptions and renaming

* added return

* Progress

* Updated

* Made radio groups full width by default in panel options

* Fixed ts issue

* Updated

* Added remaining options

* Removed unused type

* Updated snapshot

* Renamed to ReduceDataOptions
2020-03-28 23:11:50 +01:00
Torkel Ödegaard
08133ea31a
BarGauge: First bar gauge panel option & some refactoring (#23128)
* First bar gauge panel option

* Update doc comments

* Minor changes

* progress

* Fixing typing errors

* Minor type updates

* Fix that TS!

* Bring satisfaction to that beast called typescript

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2020-03-27 12:38:46 +01:00
Dominik Prokop
4eae1b5483
NewPanelEditor: fluent API for custom field config and panel options creation (#23070)
* Registry of standard option editors

* Move override processors  to grafana data

* API for declaratively creating field config/panel options

* Enable declarative API in PanelPlugin for options and field config

* Use new api in react table panel

* Add color and unit picker to option registries

* Add some docs and tests

* Fix tests
2020-03-26 21:48:46 +01:00
Ryan McKinley
19123444a1
Chore: move specific DataQuery props to loki/tsdb (#23086) 2020-03-25 22:30:22 -07:00
Ryan McKinley
27913289d3
Chore: fix typo and remove deprecation (#23073) 2020-03-25 17:21:09 -07:00
Marcus Andersson
f75387bd14
Fix: reverted back to import * as module instead of using namespaces (#23069)
* Removed namespace declaration to prevent issues with external plugins.

* fixed imports and tests.
2020-03-25 17:01:43 +01:00
Torkel Ödegaard
0870ccea7d
NewPanelEdit: Fixed error with custom override properties (#23055) 2020-03-25 14:04:41 +01:00
Hugo Häggmark
6f3ca2616f
Chore: fixes test data in processDataFrame.test.ts (#23058) 2020-03-25 13:18:41 +01:00
Andrej Ocenas
ae09ccbf79
Trace UI demo (#20297)
* Add integration with Jeager
Add Jaeger datasource and modify derived fields in loki to allow for opening a trace in Jager in separate split.
Modifies build so that this branch docker images are pushed to docker hub
Add a traceui dir with docker-compose and provision files for demoing.:wq

* Enable docker logger plugin to send logs to loki

* Add placeholder zipkin datasource

* Fixed rebase issues, added enhanceDataFrame to non-legacy code path

* Trace selector for jaeger query field

* Fix logs default mode for Loki

* Fix loading jaeger query field services on split

* Updated grafana image in traceui/compose file

* Fix prettier error

* Hide behind feature flag, clean up unused code.

* Fix tests

* Fix tests

* Cleanup code and review feedback

* Remove traceui directory

* Remove circle build changes

* Fix feature toggles object

* Fix merge issues

* Fix some null errors

* Fix test after strict null changes

* Review feedback fixes

* Fix toggle name

Co-authored-by: David Kaltschmidt <david.kaltschmidt@gmail.com>
2020-03-25 12:25:39 +01:00
Arve Knudsen
b6f73e35a5
Chore: Typecheck TypeScript in CI pipelines (#23052)
* circle-test-frontend.sh: Typecheck TypeScript
* Chore: fixes type errors
Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
2020-03-25 12:19:21 +01:00
Lukas Siatka
3f08a789d7
DevEnv: update frontend dependencies - apache arrow, bizcharts, commander (#22994)
* DevEnv: updates bizcharts 3.5.5 -> 3.5.8 in grafana-ui package

* DevEnv: updates apache-arrow 0.15.1 -> 0.16.0 in grafana-data package

* DevEnv: updates commander 2.20.0 -> 5.0.0 in grafana-toolkit package

* DevEnv: updates commander 4.1.1 -> 5.0.0 in grafana-e2e package
2020-03-25 11:01:02 +01:00
Torkel Ödegaard
e8efd17ea9
Buttons: Improves vertical alignment in buttons (#23030)
* Buttons: Improves vertical alignment in buttons

* Updated snapshot

* Fixed strict null errors
2020-03-25 09:21:44 +01:00
Torkel Ödegaard
08c95c3419
UI: Theme changes (#22880)
* Theme: Updates the theme to align panel & page background colors

* Updated dashboard settings view to be similar to new panel edit

* Updated themes

* Added shadow

* Updates generated files

* Minor fix to inspect drawer

* Clean up old dashboard setttings stuff

* Polish to search

* Updated truth image

* Minor tweaks to dropdown menu

* Updates and alignments between inspect drawer and explore rich history

* removed unused variables

* Minor tweak to light page header bg
2020-03-24 10:30:53 +01:00
Lukas Siatka
ef7b2e3974
DevEnv: update frontend dependencies - pretty-format (#22987)
* DevEnv: updates pretty-format 24.9.0 -> 25.1.0 in grafana-data package

* DevEnv: updates pretty-format 24.9.0 -> 25.1.0 in grafana-ui package

* DevEnv: updates pretty-format 24.9.0 -> 25.1.0 in grafana-runtime package
2020-03-24 05:47:32 +01:00
Tobias Skarhed
aeb88015ab
Storybook: Fix broken stories (#22975)
* Rewrite to CSF and make it not crash

* Move comments to be in generated docs

* Fix broken ThresholdsEditor story

* Fix breaking Select docs
2020-03-23 17:54:48 +01:00
Tobias Skarhed
a2b3da2792
Migration: Create org (#22542)
* Add NewOrgPage

* Remove filrs

* Remove import

* Remove comments

* Get navModel from Redux

* Add DTO

* Get nav model from state

* Change error display

* Add async await and check if org is available

* Fix null strict null error

* Update public/app/features/org/NewOrgPage.tsx

Co-Authored-By: Dominik Prokop <dominik.prokop@grafana.com>

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2020-03-19 14:22:53 +01:00
Dominik Prokop
bf7579d984
FieldOverrides: Move FieldConfigSource from fieldOptions to PanelModel.fieldConfig (#22600)
* Apply field overrides in PanelChrome

* Move applyFieldOverrides to panel query runner

* Review updates

* Make sure overrides are applied back on souce panel when exiting the new edit mode

* TS ignores in est

* Make field display work in viz repeater

* Review updates

* Review and test updates

* Change the way overrides and trransformations are retrieved in PQR

* Add fieldConfig property to PanelModel

* Dashboard migration v1

* Use field config when exiting new panel edit mode

* Gauge - use fieldConfig from panel model

* FieldDisplayOptions - don's extend FieldConfigSource

* Fix fieldDisplay ts

* StatPanel updated

* Stat panel defaults applied

* Table2 panel options  update

* React graph updates

* BarGauge updated

* PieChart, Gauge, BarGauge and Stat updates

* PieChart - remove field config defaults from options

* FieldDisplayEditor - remove unused methos

* PanelModel - remove debugger

* Remove fieldConfig from field options when migrating dashboard

* Update data links migrations

* Update fieldDisaplay tests to respect new fieldConfig

* Update dashboard schema version in snapshots

* Fix BarGaugePanel test

* Rebase fixes

* Add onFieldConfigChange to PanelProps type

* Update shared single stat migration

* Pass PanelModel instead of options only for panel type change handler [breaking]

* Renames

* Don't mutate panel options

* Migrations update

* Remove obsolete snap

* Minor updates after review

* Fix null checks

* Temporarily (until we decide to switch to new pane edit) bring back old aditors

* Temporarily rename ValueMappingEditor and MappingRow to Legacy*

* Migrations update

* Updae setFieldConfigDefaults API

* Update the way field config defaults are applied

* Use standard field config for gauge, bar gauge and stat panels

* refactoring

* Revert dashboard fieldOptions migrations as those are handled by single stat migrator

* Fix ts in tests

* Strict null fix and some minor fixes

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-03-19 11:50:31 +01:00
Torkel Ödegaard
044ec40112
Graphite: Rollup Indicator (#22738)
* WIP: Rollup indiator progress

* Progress

* Progress, can now open inspector with right tab

* changed type and made inspect

* Showing stats

* Progress

* Progress

* Getting ready for v1

* Added option and fixed some strict nulls

* Updated

* Fixed test
2020-03-18 13:00:14 +01:00
Dominik Prokop
b930966fc7
FieldOverrides: Remove console warn from processFieldConfigValue (#22824) 2020-03-17 08:32:14 +01:00
Lukas Siatka
a3037e363f
DevEnv: update frontend dependencies - npm, nodemon, typescript (#22145)
* DevEnv: updates npm 6.13.4 -> 6.13.7

* DevEnv: updates nodemon 1.18.10 -> 2.0.2

* DevEnv: updates typescript 3.7.2 -> 3.7.5

* DevEnv: removes npm from dev dependencies

* DevEnv: updates typescript 3.7.2 -> 3.7.5 in grafana-data package

* DevEnv: updates typescript 3.7.2 -> 3.7.5 in grafana-e2e package

* DevEnv: updates typescript 3.7.2 -> 3.7.5 in grafana-toolkit package

* DevEnv: updates typescript 3.7.2 -> 3.7.5 in grafana-ui package

* DevEnv: updates typescript 3.7.2 -> 3.7.5 in grafana-runtime package
2020-03-16 15:04:02 +01:00
Dominik Prokop
642c1a16dd
FieldOverrides: Apply field overrides in PanelQueryRunner (#22439)
* Apply field overrides in PanelChrome

* Move applyFieldOverrides to panel query runner

* Review updates

* Make sure overrides are applied back on souce panel when exiting the new edit mode

* TS ignores in est

* Make field display work in viz repeater

* Review updates

* Review and test updates

* Change the way overrides and trransformations are retrieved in PQR

* Minor updates after review

* Fix null checks
2020-03-16 14:26:03 +01:00
Lukas Siatka
fd99bfab1d
DevEnv: update frontend dependencies - mixed 2/2 (#22148)
* DevEnv: updates sinon 1.17.6 -> 8.1.1

* DevEnv: updates zone.js 0.7.8 -> 0.10.2

* DevEnv: updates brace 0.10.0 -> 0.11.1

* DevEnv: updates eventemitter3 2.0.3 -> 4.0.0

* DevEnv: updates file-saver 1.3.8 -> 2.0.2

* DevEnv: updates is-hotkey 0.1.4 -> 0.1.6

* DevEnv: updates mousetrap 1.6.3 -> 1.6.5

* DevEnv: updates prismjs 1.16.0 -> 1.19.0

* DevEnv: updates search-query-parser 1.5.2 -> 1.5.4

* DevEnv: updates tether 1.4.5 -> 1.4.7

* DevEnv: updates xss 1.0.3 -> 1.0.6

* Revert "DevEnv: updates zone.js 0.7.8 -> 0.10.2"

* DevEnv: updates sinon 1.17.6 -> 8.1.1 in grafana-data package

* DevEnv: updates @types/sinon 7.0.11 -> 7.5.2 in grafana-data package

* DevEnv: updates eventemitter import

* DevEnv: updates lockfile
2020-03-16 13:14:57 +01:00
Lukas Siatka
d51e2221a4
DevEnv: update frontend dependencies - rollup (#22794)
* DevEnv: updates rollup 1.6.0 -> 2.0.6 in grafana-data package

* DevEnv: updates rollup 1.6.0 -> 2.0.6 in grafana-e2e package

* DevEnv: updates rollup 1.6.0 -> 2.0.6 in grafana-runtime package

* DevEnv: updates rollup 1.6.0 -> 2.0.6 in grafana-ui package

* DevEnv: updates rollup-plugin-sourcemaps 0.4.2 -> 0.5.0 in grafana-data package

* DevEnv: updates rollup-plugin-sourcemaps 0.4.2 -> 0.5.0 in grafana-e2e package

* DevEnv: updates rollup-plugin-sourcemaps 0.4.2 -> 0.5.0 in grafana-runtime package

* DevEnv: updates rollup-plugin-sourcemaps 0.4.2 -> 0.5.0 in grafana-ui package

* DevEnv: updates rollup-plugin-terser 4.0.4 -> 5.3.0 in grafana-data package

* DevEnv: updates rollup-plugin-terser 4.0.4 -> 5.3.0 in grafana-e2e package

* DevEnv: updates rollup-plugin-terser 4.0.4 -> 5.3.0 in grafana-runtime package

* DevEnv: updates rollup-plugin-terser 4.0.4 -> 5.3.0 in grafana-ui package

* DevEnv: updates rollup-plugin-typescript2 0.19.3 -> 0.26.0 in grafana-data package

* DevEnv: updates rollup-plugin-typescript2 0.19.3 -> 0.26.0 in grafana-e2e package

* DevEnv: updates rollup-plugin-typescript2 0.19.3 -> 0.26.0 in grafana-runtime package

* DevEnv: updates rollup-plugin-typescript2 0.19.3 -> 0.26.0 in grafana-ui package

* DevEnv: updates @rollup/plugin-commonjs 9.2.1 -> 11.0.2 in grafana-data package

* DevEnv: updates @rollup/plugin-commonjs 9.2.1 -> 11.0.2 in grafana-e2e package

* DevEnv: updates @rollup/plugin-commonjs 9.2.1 -> 11.0.2 in grafana-runtime package

* DevEnv: updates @rollup/plugin-commonjs 9.2.1 -> 11.0.2 in grafana-ui package

* DevEnv: updates rollup config import in grafana-data package

* DevEnv: updates rollup config import in grafana-e2e package

* DevEnv: updates rollup config import in grafana-ui package

* DevEnv: updates rollup config import in grafana-runtime package

* DevEnv: updates @rollup/plugin-node-resolve 4.0.1 -> 7.1.1 in grafana-data package

* DevEnv: updates @rollup/plugin-node-resolve 4.0.1 -> 7.1.1 in grafana-e2e package

* DevEnv: updates @rollup/plugin-node-resolve 4.0.1 -> 7.1.1 in grafana-runtime package

* DevEnv: updates @rollup/plugin-node-resolve 4.0.1 -> 7.1.1 in grafana-ui package

* DevEnv: updates lockfile

* DevEnv: updates rollup config plugin-node-resolve import in grafana-data package

* DevEnv: updates rollup config plugin-node-resolve import in grafana-ui package

* DevEnv: updates rollup config plugin-node-resolve import in grafana-e2e package

* DevEnv: updates rollup config plugin-node-resolve import in grafana-runtime package

* DevEnv: updates rollup-plugin-visualizer 0.9.2 -> 3.3.1 in grafana-data package

* DevEnv: updates rollup-plugin-visualizer 0.9.2 -> 3.3.1 in grafana-e2e package

* DevEnv: updates rollup-plugin-visualizer 0.9.2 -> 3.3.1 in grafana-runtime package

* DevEnv: updates rollup-plugin-visualizer 0.9.2 -> 3.3.1 in grafana-ui package
2020-03-15 16:39:40 +01:00
Dominik Prokop
1256d9e78d
grafana/data: PanelTypeChangedHandler API update to use PanelModel instead of panel options object [BREAKING] (#22754)
This changes PanelModel's API to support PanelModel API updates when changing panel type. Primary useful when changing panel type between Angular and React panels, as other migrations can be handled via DashboardMigrator.

API change: https://github.com/grafana/grafana/pull/22754/files#diff-d9e3f91dc7d5697f6d85ada008003b4b
2020-03-13 08:27:16 +01:00
Arve Knudsen
9c5020d53f
Increment Grafana version (#22728)
* Increment Grafana version to 7.0.0-pre
2020-03-11 17:20:56 +01:00
Peter Holmberg
08d8190c02
PanelInspector: Add Stats Tab (#22683)
* add tab

* add process measurement

* Fixed some design issues

* Align tabs margin

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-03-11 13:19:06 +01:00
Ryan McKinley
cf6adb8b54
support duplicate field names in arrow format (#22705) 2020-03-11 09:24:50 +01:00
Torkel Ödegaard
9824219a58
UX: Update new form styles to dark inputs (#22701)
* UX: Update new form styles to dark inputs

* Aligning styles a bit

* Updated snapshot
2020-03-11 09:20:28 +01:00
Tobias Skarhed
9a67e94618
StatPanel: Return base color when there is no value set (#22690) 2020-03-10 16:57:23 +01:00
Shavonn Brown
65370c5443
on update for checkbox and switch (#22656)
* on update for checkbox and switch

* use ? instead
2020-03-10 08:45:08 -04:00
Torkel Ödegaard
5d8fc6a1a9
StatPanel: Fixes base color is being used for null values (#22646)
* StatPanel: Fixed color for null values

* StatPanels: Show base value for null values
2020-03-09 17:00:25 +01:00
Dominik Prokop
9d858220ce
FieldOverrides: Add value mappings editor to standard config properties registry (#22648) 2020-03-09 15:09:32 +01:00
Shavonn Brown
b27985ef38
Azure Monitor: config editor updates, update sameas switch, fix test snaps (#22554)
* azure monitor config editor updates, do not show helper for sameas unless just switched, not create

* update snapshots
2020-03-04 09:11:11 -05:00
Emil Tullstedt
3c6a7a51bf
Logs: Improve log level guess (#22094)
Fixes #22075
2020-03-04 09:48:21 +01:00
Ryan McKinley
f09ee3d8c2
ArrowDataFrame: allow empty results (#22524) 2020-03-02 23:56:01 -08:00
Torkel Ödegaard
c002a39456
NewPanelEditor: Angular panel options, and angular component state to redux major change (#22448)
* NewPanelEdit: Added angular options to new panel editor and started looking and angular component state

* Moved angular component state to redux

* Close to working 100%

* Think everything is working

* AlertTab: Alert tab now gets angularComponent from redux

* Fixed panel menu access to angular panel component

* Added new tests

* Fixed unit test

* Fixed strict null errors

* Fixed typescript issues

* fixed issues
2020-02-28 11:04:40 +01:00
Steven Vachon
2b6a88bf59
Optimized package.json files (#22475)
* Used repository shortcut syntax where possible
* Added repository directories for monorepo packages
* Alphabetically sorted npm scripts
2020-02-27 12:00:36 -05:00
Marcus Andersson
e2038e0614
Docs: adding API reference documentation support for the packages libraries. (#21931)
* trying out api-extractor.

* works with our setup of build.

* wip.

* changed the packages so it works better with the api-extractor.

* Changes to make the api-extractor to work.

* cleaned up the api-extractor config files.

* added some more documentation.

* added tsdoc-metadata to gitignore.

* removed the generated docs (will do that in another PR).

* added execute permission to script for generating dosc.

* added so we will push generated docs to branch.

* will clean packages_api on abort.

* Fixed failing tests.

* fixed formatting issue with typedoc comment.

* temporarily disabled tslint rules about namespace until https://github.com/microsoft/rushstack/issues/1029 is resolved

* temporary enabled bable namespaces.

* updated build script.

* updated script.

* updated script with some colors.

* changed to camelCase.

* removed spacing.

* Starting to add documentation guidelines.

* added examples headline.

* added parameters and return values.

* Fixed merge error.

* changed so we use the eslint ignore syntax.

* changed to correct eslint ingnore comment.

* fixed some spelling errors reported by codespell.

* added script to generate docs in current folder.

* lerna bootstrap.

* removed file that should be ignored.

* updated locKFILE.

* referenced the code comments guidelines.

* updated packages.

* updated deps.
2020-02-25 13:59:11 +01:00
Steven Vachon
7bf3f0b9c1
grafana/data: runtime dependencies moved from devDependencies (#22283)
... so that they get installed within consumer projects
2020-02-19 14:40:41 +01:00
Torkel Ödegaard
c162af8142
FieldOverrides: Fix issue with same series name for every display value (#22234)
* fieldOverrides: Fix issue with same series name for every display value

* Added unit test
2020-02-16 14:56:24 +01:00
Ryan McKinley
cc589a0d76
Inspector: find the datasource from the refId, not the metadata (#22231)
* remove datasource

* get datasoure from refId

* metrictank does not need to say the datasource
2020-02-16 05:12:40 -08:00
Ryan McKinley
2c9b321c48
FieldOverides: apply field overrides based on configuration (#22047)
* test apply

* test apply

* Move standard field config editor registry to grafana-data

* merge master

* Apply field config defaults

* Make field and dataFrameIndex optional on on FieldOverrideContext

* Apply custom field config overrides

* Gauge - make sure thresholds are set

* Move series and field scoped vars calculation

* Enable template variables interpolation in title fields

* Expose standars field configs from grafana ui via function

* Add missing option to the config for the min value to be derived from field values

* Fix ts issue

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2020-02-13 21:37:24 +01:00
Torkel Ödegaard
df1d43167a
NewPanelEditor: Panel editor tabs in state (url) (#22102)
* tabs & style tweaks

* Styling updates

* ok look

* tweaks

* Updated snapshots

* Moved transforms

* Updated
2020-02-12 10:42:57 +01:00
Dominik Prokop
e612d7a2f9
New panel edit: data links edit (#22077)
* Move data links suggestions to grafana-data

* Data links -  field config and overrides

* Lint

* Fix test

* Add variable suggestions  to field override context

* Revert "Move data links suggestions to grafana-data"

This reverts commit 5d8d01a65e.

* Move FieldConfigEditor to core
2020-02-11 13:48:36 +01:00
Dominik Prokop
1728742096 New panel edit: field overrides ui (#22036)
* Add title editor

* Wip

* FIeld config overrides UI (v1)

* Basic property override editors

* name to prop

* use prop not path

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2020-02-09 14:34:42 +01:00
Torkel Ödegaard
34c397002c PanelChrome: Use react Panel Header for angular panels. (#21265)
* WIP: Angular panel chrome, this is going to be tricky

* AngularPanelChrome: initial render works

* Options are showing up

* viz options working

* Fixed singlestat background

* AngularPanels: Fixed alert tab

* Removed anuglar loading spinner

* Dashboard: Refactor dashboard reducer & actions

* Dashboard: minor refactoring

* PanelChrome: loading state moved to header

* Subscribe to render events to solve title update issue

* Time info and query errors now works

* PanelHeader: unifying angular and react behavior

* added getPanelMenu test

* Scrollable now works again

* Various fixes

* Making stuff work

* seperate event emitter for angular

* Fixed issue sending updated dimensions to angular panel

* Minor tweaks

* Fixed tests

* Alerting: alert state now works

* Fixed unit tests

* Fixed a few null check errors

* Simplified events handling

* Fixed strict null checks
2020-02-09 10:53:34 +01:00
Ryan McKinley
66191f946d New Editor: use unit picker (#22033)
* use unit picker

* export correct file name

* override is the same
2020-02-09 10:29:10 +01:00
Ryan McKinley
da395729c3 FieldEditor: extendable FieldConfig UI (#21882)
* initial POC

* fix import

* field config editor in the sidebar

* field config editor in the sidebar

* field config editor in the sidebar

* sidebar

* include threshold in sidebar

* include threshold in sidebar

* include threshold in sidebar

* init to empty threshold

* merge

* Make sure editor is fully rendered when page is refreshed

* use scrollbars

* add matcher UI folder

* remove

* Field options basic editors

* Removed deebugger

* Make number field editor controlled

* Update public/app/features/dashboard/state/PanelModel.ts

* Update public/app/plugins/panel/gauge/GaugePanel.tsx

* Ready for production

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2020-02-08 18:29:09 +01:00
Ryan McKinley
d0470409d6
Chore: export arrow dataframe utilities (#22016)
* export arrow dataframe

* use the same table
2020-02-08 09:50:35 +01:00
Steven Vachon
f48169633c
TSLint → ESLint (#21006)
* Alphabetized tslint and tsconfig files

* Optimized tsconfig files

* Optimized editorconfig & prettier config files

… to reduce redundancy

* Switched to @grafana/tsconfig

… and:
* de-duped options
* removed options with default values

* Fixed nasty issue with types for nested slate-react

* Replaced TSLint with ESLint

* TSLint disables → ESLint disables

… also JSHint removals, which haven’t had an affect since it was replaced with TSLint.

* Compliances for ESLint, Prettier and TypeScript

* Updated lockfile
2020-02-08 02:40:04 +01:00
Lukas Siatka
df48d1c19f
Explore: Adds Loki explore query editor (#21497)
* Explore: updates grafana-data explore query field props with explore mode

* Explore: updates query row to pass down explore mode to query fields

* Explore: adds LokiExploreQueryEditor

* Explore: updates loki query field form to render children

* Explore: adds loki explore extra field component

* Explore: adds extra field element to loki query field form

* Explore: updates loki explore query editor to use extra field element

* Explore: moves ExploreMode to grafana-data

* Explore: updates query row limit string

* Explore: adds maxLines to DataQuery

* Explore: adds maxLines to loki datasource runRangeQueryWithFallback

* Explore: adds onChangeQueryLimit to LokiExploreQueryEditor

* Explore: updates loki explore query editor to render extra field only in logs mode

* Explore: fixes query limits for live and legacy queries

* Explore: fixes result processor max lines limit in get logs result

* Explore: fixes Loki datasource limit test

* Explore: removes unnecessary ExploreMode from Loki language provider

* Explore: fixes formatting

* Explore: updates grafana-data datasource types - replaces strings with explore mode enum

* Explore: updates loki explore query field props to take ReactNode

* Explore: updates the way we calculate loki query lines limit to fall back to 0 lines on negative or invalid input instead of datasource maxLines

* Explore: updates result processor get logs result method to avoid counting invalid/negative line limits

* Explore: updates loki result transformer to process only an appropriate slice of a result instead of an entire one

* Explore: adds a method for query limit preprocessing/mapping

* Explore: updates loki datasource run range query with fallback method to use options.maxDataPoints in dashboards

* Explore: removes unnecessary maxlineslimt from getLogsResult in resultProcessor

* Explore: moves line limit to metadata

* Explore: adds an ability to specify input type of extra field

* Explore: updates LokiExploreQueryEditor - adds an input type

* Explore: updates LokiExploreQueryEditor to run queries when maxLines is positive

* Explore: fixes failing import of ExploreMode

* Explore: fixes reducers test imports formatting

* Explore: updates Loki extra field with min value set to 0

* Explore: exports LokiExploreExtraFieldProps

* Explore: adds render test of LokiExploreQueryEditor

* Explore: adds LokiExploreQueryEditor snapshot

* Explore: updates LokiExploreQueryEditor onChangeQueryLimit method to prevent it from running when query input is empty - fixes cheatsheet display issue

* Explore: updates Loki editor snapshots

* Explore: fixes typo in test set name in LokiExploreQueryEditor

* Explore: adds a render test of LokiExploreExtraField

* Explore: fixes typo in LokiExploreQueryEditor

* Explore: updates LokiExploreQueryEditor snapshot due to timezone issues

* Explore: updates LokiExploreExtraField to export both functional component and a version using memo

* Explore: updates LokiExploreQueryEditor to export both functional component and memoized function

* Explore: updates LokiExploreQueryEditor - removes unnecessary react fragment

* Explore: updates LokiExploreQueryEditor snapshot

* Explore: adds LokiExploreQueryEditor tests for different explore mode cases

* Explore: fixes Loki datasource and result transformer

* Explore: updates LokiExploreQueryEditor snapshot

* Explore: updates LokiExploreQueryEditor tests and test setup

* Explore: updates LokiExploreQueryEditor - refactors component

* Explore: updates LokiExploreQueryEditor to use default import from LokiExploreExtraField

* Explore: updates LokiExploreQueryEditor snapshot

* Explore: fixes formatting

* Explore: updates LokiExploreQueryEditor max lines change

* Explore: updates LokiExploreQueryEditor tests checking ExtraFieldElement

* Explore: adds mock loki datasource to LokiExploreQueryEditor

* Explore: updates LokiExploreQueryEditor test mock - adds language provider

* Explore: updates LokiExploreQueryEditor snapshot

* Explore: updates Loki ResultTransformer to filter out rows on limit - logic to be moved into a component with new form styles

* Explore: updates LokiExploreQueryEditor tests
2020-02-06 12:34:52 +00:00
Ryan McKinley
c140d110c6
grafana/data: Remove unused PanelSize interface (#21877) 2020-02-03 08:14:34 +01:00
Ryan McKinley
c15ddc295c
DataFrame: update golden test files (#21808) 2020-01-29 08:30:03 -08:00
Marcus Andersson
cab082438e
Fix: prevents the BarGauge from exploding when the datasource returns empty result. (#21791)
* Fixed issue where gauge throw error on empty result.

* Some refactorings to improve the code.

* Added some tests to make sure this doesn't happen again.
2020-01-29 11:40:30 +01:00
Ryan McKinley
67c5531961 grafana/data: Add type for secure json in DataSourceAPI (#21772) 2020-01-28 07:13:20 +01:00
Andrej Ocenas
0fda3c4f44
Explore: Fix context view in logs, where some rows may have been filtered out. (#21729)
* Fix timestamp formats and use uid to filter context rows

* Remove timestamps from tests
2020-01-26 23:13:56 +01:00
Ivana Huckova
e75840737e
Loki: Fix Loki with repeated panels and interpolation for Explore (#21685) 2020-01-24 09:50:09 +01:00
Ivana Huckova
6feb4a3221
Explore: Fix log level color and add tests (#21646) 2020-01-21 17:20:22 +01:00
Leonard Gram
4a1f993fd1
next version 6.7.0 (#21617)
* next version 6.7.0

* updates grafana/toolkit and co

* Verison: manually fixed version
2020-01-21 15:15:38 +01:00
kay delaney
cf2cc71393 Chore: Remove angular dependency from backendSrv (#20999)
* Chore: Remove angular dependency from backendSrv

* Refactor: Naive soultion for logging out unauthorized users

* Refactor: Restructures to different streams

* Refactor: Restructures datasourceRequest

* Refactor: Flipped back if statement

* Refactor: Extracted getFromFetchStream

* Refactor: Extracts toFailureStream operation

* Refactor: Fixes issue when options.params contains arrays

* Refactor: Fixes broken test (but we need a lot more)

* Refactor: Adds explaining comments

* Refactor: Adds latest RxJs version so cancellations work

* Refactor: Cleans up the takeUntil code

* Refactor: Adds tests for request function

* Refactor: Separates into smaller functions

* Refactor: Adds last error tests

* Started to changed so we require getBackendSrv from the @grafana-runtime when applicable.

* Using the getBackendSrv from @grafana/runtime.

* Changed so we use the getBackendSrv from the @grafana-runtime when possible.

* Fixed so Server Admin -> Orgs works again.

* Removed unused dependency.

* Fixed digest issues on the Server Admin -> Users page.

* Fix: Fixes digest problems in Playlists

* Fix: Fixes digest issues in VersionHistory

* Tests: Fixes broken tests

* Fix: Fixes digest issues in Alerting => Notification channels

* Fixed digest issues on the Intive page.

* Fixed so we run digest after password reset email sent.

* Fixed digest issue when trying to sign up account.

* Fixed so the Server Admin -> Edit Org works with backendSrv

* Fixed so Server Admin -> Users works with backend srv.

* Fixed digest issues in Server Admin -> Orgs

* Fix: Fixes digest issues in DashList plugin

* Fixed digest issues on Server Admin -> users.

* Fix: Fixes digest issues with Snapshots

* Fixed digest issue when deleting a user.

* Fix: Fixes digest issues with dashLink

* Chore: Changes RxJs version to 6.5.4 which includes the same cancellation fix

* Fix: Fixes digest issue when toggling folder in manage dashboards

* Fix: Fixes bug in executeInOrder

* Fix: Fixes digest issue with CreateFolderCtrl and FolderDashboardsCtrl

* Fix: Fixes tslint error in test

* Refactor: Changes default behaviour for emitted messages as before migration

* Fix: Fixes various digest issues when saving, starring or deleting dashboards

* Fix: Fixes digest issues with FolderPickerCtrl

* Fixed digest issue.

* Fixed digest issues.

* Fixed issues with angular digest.

* Removed the this.digest pattern.

Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>
Co-authored-by: Marcus Andersson <systemvetaren@gmail.com>
2020-01-21 10:08:07 +01:00
Ivana Huckova
c738a889ed
Explore: Context tooltip to copy labels and values from graph (#21405) 2020-01-17 15:52:08 +01:00
Ryan McKinley
29e9b1f774
DataFrames: add arrow test and capture metadata parsing errors (#21524) 2020-01-15 14:33:56 -08:00
Ryan McKinley
76ba2db4e7
DataLinks: allow using values from other fields in the same row (#21478) 2020-01-15 12:02:52 -08:00
Dominik Prokop
3f957a3735
grafana/data: Update plugin config page typings (BREAKING) (#21503)
* Change typyings of plugins config pages

* Update plugin config page types of core plugins
2020-01-15 19:42:44 +01:00
Shavonn Brown
a7509d2ca0
More datasource funcs poc (#21047)
* remove anon funcs, removed options from state, removed update method, static selects as constants

* cancellable promise

* cancel promise on unmount

* use new datasource funcs for dryer component

* event handler funcs

* updated funcs and moved to utils, updating config editors

* S has no keys. never will never work

* remove report json

* update azure snapshot

* DataSourceSettings keyof

* rename reset funcs
2020-01-10 14:26:33 -05:00
David
a3c99f4871
Logs: Fix parsing for logfmt fields that have parens (#21407)
* Logs: Fix parsing for logfmt fields that have parens

- added `()`, `[]`, and `{}` to be allowed in logfmt field names

* Fix matcher
2020-01-10 13:53:31 +01:00
Ryan McKinley
bf18704490
Inspector: support custom metadata display (#20854) 2020-01-09 22:59:23 -08:00
Ryan McKinley
f7053e19d2
TimeZones: fix utc test (#21393) 2020-01-07 14:01:06 -08:00
Ryan McKinley
1aa52f259c
Arrow: don't export arrow... breaking phantomjs e2e test (#21331) 2020-01-03 10:00:30 -08:00
Ryan McKinley
e550572033
DataFrame: round trip metadata to arrow Table (#21277) 2020-01-03 08:12:19 -08:00
Ryan McKinley
e1acc77297
@grafana/data: use timeZone parameter rather than isUtc (#21276) 2020-01-02 08:11:28 -08:00
Ryan McKinley
c1b707874d
Units: support dynamic count and currency units (#21279) 2020-01-02 07:46:49 -08:00
Ryan McKinley
d9e9843a10
FieldConfig: add thresholds and color modes (#21273) 2019-12-28 17:32:58 -08:00
Torkel Ödegaard
45b7de1910
Explore: Moves PromContext from query level to DataQueryRequest level (#21260)
Closes #19598

Fixes bug introduced recently where the new PromQueryEditor did not preserve
the PromContext.Explore set on the query model by PromQueryField which caused
the table to be empty for Prometheus in explore.
2019-12-27 09:11:16 +01:00
Ryan McKinley
af2cd77655
Units: support farenheit (existing misspelling) (#21249) 2019-12-23 22:05:26 -08:00
Torkel Ödegaard
3347b45a95
Table: Component progress & custom FieldConfig options (#21231)
* Table: Set & use field display processor

* Use applyFieldOverrides outside in story instead

* Change types a bit

* Table: Move to flexible layout

* Simplest possible custom field option

* Skip default column

* Added textAlign

* Explore: Set display processor for table data frame

* Fixed storybook

* Refactoring

* Progress on cell display mode

* Major progress

* Progress & refactoring

* Fixes

* Updated tests

* Added more tests

* Table: Progress on cell style customization

* Restored testdata random walk table scenario

* put back unrelated change

* remove unused things

* Updated table story

* Renamed property

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2019-12-23 06:22:54 +01:00
Ryan McKinley
8d537b7afb Chore: remove StreamHandler and DataStreamState (#21234)
* remove StreamHandler

* remove DataStreamState
2019-12-23 06:16:04 +01:00
Ryan McKinley
b8c0924ab1
NewsPanel: add news as a builtin panel (#21128) 2019-12-20 10:47:45 -08:00
Hugo Häggmark
05cb85feba
Table: Matches column names with unescaped regex characters (#21164)
* Table: Matches column names with unescaped regex characters
Fixes #21106

* Chore: Cleans up unused code
2019-12-18 12:38:39 +01:00
Torkel Ödegaard
4f1fffb948
FontSize: Change base font size to 14px (#21104) 2019-12-16 17:45:33 +01:00
Ryan McKinley
6de4933a4a
FieldConfig: set min/max automatically for gauge (#21073) 2019-12-13 08:36:49 -08:00
Ryan McKinley
1aa39ee458
FieldConfig: support overrides model (#20986) 2019-12-12 14:55:30 -08:00
Hendrik van Huyssteen
caa3c6c9a5 DisplayProcessor: Interpret empty strings as NaN instead of 0 to support empty value map texts in Singlestat (#20952) 2019-12-09 10:07:31 +01:00
Ryan McKinley
4ba5d946f2
DataSource: remove delta option (#20949) 2019-12-08 16:13:14 -08:00
Shavonn Brown
2098b9eb44
Azure Monitor: Standardize Config Editor Implementation (#20455)
* initial changes - removal from state, remove anon functions, reset secrets empty

* post testing cleanup

* init promise cancellation, other cleanup

* workspaces response parser, remove version incrementing

* update datasource funcs - DRYer

* remove prop mutation

* func to modify root config opt

* fix version issue

* update snapshot
2019-12-04 14:35:53 -05:00
Andrej Ocenas
4c9cb415ec Elastic: Fix parsing for millisecond number timestamps (#20290)
* Stop parsing 'field'

* Remove time field from query for docs queries

* Test refactor to test all versions

* Fix tests
2019-12-04 14:43:43 +01:00
Marcus Andersson
7a710737ae Gauge/BarGauge: Added support for value mapping of "no data"-state to text/value (#20842)
* FieldDisplay: added support for value mapping of no data state.

 Committer: Marcus Andersson <marcus.andersson@grafana.com>

* FieldDisplay: fixed issue when switching between modes and display numeric was null.

* ValueMapping: introduced a private function for checking null values.

* FieldDisplay: refactoring of test setup to reduce duplication.

* Docs: added info about new 'no data' value to text mapping.

* Docs: improved according to feedback. Reverted prettier formatting changes.

* FieldDisplay: removed unused import.
2019-12-04 14:29:42 +01:00
Ryan McKinley
d7c76dacad ValueFormats: dynamically create units (#20763)
* update fixed

* update fixed

* update fixed

* don't change any tests

* add mising space

* Custom unit formats

* return a string for kbn

* return a string for kbn

* return a string for kbn

* Simplify unit tests

* More units

* fix more tests

* fix more tests

* fix more tests

* format values

* format values

* TimeSeries to string

* more kbn tests

* use the formatted value

* BarGauge: Fixed font size calculations

* support prefix

* add si support

* avoid npe

* BarGauge/BigValue: value formatting

* fix some tests

* fix tests

* remove displayDateFormat

* another unicode char

* Graph: Use react unit picker

* Updated unit picker

* Fixed build errors

* more formatting

* graph2 tooltip formatting

* optional chaining
2019-12-04 09:08:07 +01:00
Ryan McKinley
3289ee8b77
@grafana/data: don't export ArrowDataFrame (#20855) 2019-12-03 23:17:48 -08:00
Kyle Brandt
431bf2b179 @grafana/data: export ArrowDataFrame (#20832) 2019-12-03 21:17:36 -08:00
kay delaney
a093fbb51a Migration: Migrate org switcher to react (#19607)
* Migration: Migrate org switcher to react

* Improve modal overflow behavior

* Updated modal backdrop

* Renamed type

* Modal: Refactoring and reducing duplication
2019-12-03 22:47:19 +01:00
Dominik Prokop
31181c9981
Forms: introduce checkbox (#20701)
* introduce checkbox theme variables

* Add checkbox component

* Style tweaks

* Namespace form styles returned from getFormStyles

* Name fix
2019-12-03 09:29:44 +01:00
Ryan McKinley
e216044c75
DataFrame: add utilities to @grafana/data that support apache arrow (#20813) 2019-12-02 12:39:50 -08:00
Sebastian Markgraf
a7a9bcbcbb Doc: Change inline comment on interface to doc comment (#20794) 2019-12-02 16:38:04 +01:00
Torkel Ödegaard
8894e2858c
StatPanel: ColorMode, GraphMode & JustifyMode changes (#20680)
* StatPanel: Options rethink

* Changed options to string based

* -Fixed tests

* Refactoring moving files

* Refactoring alignment factors

* Added alignment factors

* Added basic test

* Added unit test for layout

* Font size handling

* Font sizing works

* Progress on sizing

* Updated

* Minor update

* Updated

* Updated

* Removed line option

* updated

* Updated

* Updated

* Updated

* Highlight last point

* Fixed tests

* Code refactoring and cleanup

* updated

* Updated snapshot
2019-12-01 17:02:44 +01:00
Adam Zegelin
fcde26e2db Units: Remove SI prefix symbol from new milli/microSievert(/h) (#20650) 2019-11-29 16:47:16 -08:00
Hugo Häggmark
130fb02b17
Release: Updates latest.json and grafana/packages/*/package.json (#20734)
* Update latest.json

* Chore: Changes version to canary

* Chore: Changes version to 6.6.0-pre
2019-11-28 03:47:48 -08:00
Peter Holmberg
c5ff7fa580 ReactMigration: Migrate Graphite config page to React (#20444)
* adding configeditor

* fix method signature and add state for metrictankhelper

* fix onChangeHandler

* prettier fix

* remove config and fix autoversion

* adding optional parameter to make this build

* set default version if none specified

* Graphite: removed version detection
2019-11-27 15:45:35 -08:00
Sparkle
49dfb9a5d3 Units: remove unreachable code (#20684)
* Refactor: Remove the code which can't reach

* Test: Add more unit tests for toFixed and scaledUnits methods

- To make them easier to understand
2019-11-27 08:03:22 -08:00
Anirudh Ramesh
0a3662c359 Units: Add currency and energy units (#20428)
* Units: Add unit for currency - South Korean Won

* Units: Add support for 'femto' and 'pico' decimal SI prefix

* Units: Expand library of energy units

Add:
Power - Giga-watt (useful for viewing metrics of power flow through large-scale electrical infrastructure)
Electrical Resistance - Kilo-ohm, Mega-ohm (useful for viewing metrics of energy storage e.g. internal resistance of a battery and more)
Electrical Capacitance - Farad, Micro-farad, Nano-farad, Pico-farad, Femto-farad
Electrical Inductance - Henry, Milli-henry, Micro-henry

* Units: Add unit test for currency ₩

* Units: Add unit tests for energy units
2019-11-26 20:02:53 +01:00
Torkel Ödegaard
65942efb95
Panels: Add support for panels with no padding (#20012)
* Panels: Added support to set panel padding to zero

* WIP: fullChromeControl work

* Tweaks to header position

* Reverted some overlay mechanic and now back to no title only

* Fixed test

* Fixed transparent flag

* Added show title

* Added font weight to value

* Reverted back to no padding option

* Fixed issue with border and width and height
2019-11-25 13:26:18 -08:00
Dominik Prokop
1bd0c87f66
Forms: Introduce form field (#20632)
* Introduce new Switch component

* Experiment with different focus style

* Review update

* Update on/off swtch colors

* Introduce Form.Field component

* Enable className prop on form's field

* Remove not used imports

* Update packages/grafana-ui/src/components/Forms/Field.tsx

Co-Authored-By: Peter Holmberg <peterholmberg@users.noreply.github.com>

* Make switch usable in field story

* Add predefined input sizes

* Add util to display story on a debug canvas

* Test form

* Updated the test form

* Fix snapshot
2019-11-25 16:38:06 +01:00
Dominik Prokop
17362b4180
Forms: Introduce new Switch component (#20470)
* Introduce new Switch component

* Experiment with different focus style

* Review update

* Update on/off swtch colors
2019-11-25 08:25:56 +01:00
kay delaney
ca3dff99e8
Chore: Bumps prettier version for new typescript syntax support (#20463)
* Chore: Bumps prettier version for new typescript syntax support

* Ran new version of prettier against the codebase
2019-11-19 13:59:39 +00:00
Peter Holmberg
99e635071e
Forms: New Input component (#20159)
* Adding component, story and documentation file

* forgot files

* Add label and formvalidation

* fix for error/invalid message

* fixing font color when input is disabled

* red border if invalid

* fixing props and label margin

* added support for icon in input

* support for button and loading state

* redoing some of the markup

* fixing height on addons

* Adding some basic documentation

* remove not used types file

* Add some more knobs

* move component to it's own directory, updated styling

* Adding component, story and documentation file

* forgot files

* Add label and formvalidation

* fix for error/invalid message

* fixing font color when input is disabled

* red border if invalid

* fixing props and label margin

* added support for icon in input

* support for button and loading state

* redoing some of the markup

* fixing height on addons

* Adding some basic documentation

* remove not used types file

* Add some more knobs

* move component to it's own directory, updated styling

* Add Icon component

* Add useClientRect helper hook

* Add missing Icon types

* Simplify Inputs styling (POC)

* Render theme knob in a separate group

* Update packages/grafana-ui/src/components/Forms/Input/Input.tsx

Co-Authored-By: Peter Holmberg <peterholmberg@users.noreply.github.com>

* Update packages/grafana-ui/src/components/Forms/Input/Input.tsx

* Improve comment

* Restore increase/decrease spinner on number inputs

* Add period

* use input color variables

* fix test

* Expose input styles from getFormStyles
2019-11-19 10:42:59 +01:00
kay delaney
e0a2d4beac Grafana/Loki: Adds support for new Loki endpoints and metrics (#20158)
* Grafana/Loki: Adds support for new Loki endpoints and metrics

* Adds `/loki/` prefix to new loki endpoints and updates response interfaces

* Improved legacy support

* Removed changes related to plugin.json and added Loki-specific hacks

* Fixes live streaming for legacy loki datasources
2019-11-15 16:38:25 +01:00
kay delaney
f1c8330877
Chore: Upgrade typescript to 3.7 (#20375)
* Chore: Upgrade typescript to 3.7
2019-11-15 09:18:09 +00:00
Šimon Podlipský
4260cd548f DataFrame processing: Require table rows to be array (#20357) 2019-11-13 14:30:08 +01:00
Henrique Oliveira
9e0499000c ValueFormats: fix description for dateTimeAsUS (#20355) 2019-11-13 13:16:31 +01:00
Torkel Ödegaard
b756aa0bb1
Prometheus: Adds hint support to dashboard and fixes prometheus link in query editor (#20275)
* Prometheus: moved hints into query editor, and fixed missing refIds in responses

* Minor fix

* Removed unused type import
2019-11-11 16:47:17 +01:00
Ryan McKinley
8430a182ef
Transformations: filter results by refId (#20261) 2019-11-08 11:47:35 -08:00
Ryan McKinley
818aa8eefa
DataFrame: move labels to field (#19926) 2019-11-07 07:50:45 -08:00
Dominik Prokop
225ecd680a
Explore: Configure explore series colours via field config (#20239) 2019-11-07 14:58:50 +01:00
Hugo Häggmark
e66fc3d47a
ReactPanels: Adds Explore menu item (#20236)
* Fix: Adds Explore menuitem to React Panels
Fixes #19865

* Refactor: Adds CMD|CTRL+click to Explore menu item
2019-11-07 13:49:45 +01:00
Dominik Prokop
96dbed5efc
Graph: introduce Tooltip to React graph (#20046) 2019-11-07 12:37:46 +01:00
Ryan McKinley
8484b43001
DisplayProcessor: improve time field support (#20223) 2019-11-07 00:08:25 -08:00
Andrej Ocenas
0a78652404
Explore: Add custom DataLinks on datasource level for Loki (#20060)
Adds a config section with derived fields which is a config that allows you to create a new field based on a regex matcher run on a log message create DataLink to it which is the clickable in the log detail.
2019-11-06 16:15:08 +01:00
David
9507eda9d1
QueryField: Prevent query runs on blur in Explore (#20180)
As discussed in a UX feedback session, it's annoying that queries are
automatically executed in Explore. This change adds props to override
the blur behavior.

- add `onBlur` to Explore query field props
- Explore's query row will pass down an empty function for onBlur to the
query fields
- pass onBlur through to the QueryField component for Loki and
Prometheus
- add test to QueryField to make sure if onBlur is specified, the
onRunQuery is not executed
2019-11-06 15:08:30 +00:00
Dominik Prokop
9117fab43a
grafana/data: Make display processor work with time fields (#20174)
* Enable display processor on time fields

* Export default date time formats from grafana/data

* Add data time formatter for timezone

* Move date format from display process options to field config
2019-11-06 11:03:43 +01:00
lzd
31e7e35bff Datasource/Elasticsearch: Fix logs which were displayed with incorrect timestamp in Explore logs tab (#20009) 2019-11-06 07:42:36 +00:00
Ryan McKinley
92ab4d80f0
Error Handling: support errors and data in a response (#20169) 2019-11-05 15:20:04 -08:00
Ryan McKinley
4acceff0de Units: Add milli/microSievert, milli/microSievert/h and pixels (#20144)
* add more radiation units

* add pixels
2019-11-01 15:33:58 -04:00
Ivana Huckova
a5e8e0e291 Explore: UI change for log row details (#20034)
Add LogDetail section that is shown when log line is clicked and expanded. Contains labels/fields and actions to show stats and add/remove label filter.
2019-11-01 10:01:00 +01:00
Dominik Prokop
9b7748ec13
Chore: Reorg packages (#20111)
Primarily- moving majority of the types and utils from @grafana/ui to @grafana/data

* Move types from grafana-ui to grafana-data

* Move valueFormats to grafana-data

* Move utils from grafana-ui to grafana-data

* Update imports in grafana-ui

* revert data's tsconfig change

* Update imports in grafana-runtime

* Fix import paths in grafana-ui

* Move rxjs to devDeps

* Core import updates batch 1

* Import updates batch 2

* Imports fix batch 3

* Imports fixes batch i don't know

* Fix imorts in grafana-toolkit

* Fix imports after master merge
2019-10-31 10:48:05 +01:00
Ryan McKinley
9e004b9211
DataLinks: Implement javascript callback (#19851) 2019-10-28 04:08:19 -07:00
Kyle Brandt
1ffcb002db DataFrame: guess number field when on NaN (#19833) 2019-10-16 15:13:27 +02:00
Torkel Ödegaard
b37444f3ea
InputDataSource: Fixed issue with config editor (#19818) 2019-10-16 12:58:49 +02:00
kay delaney
99411bf37a
Types: Adds type safety to appEvents (#19418)
* Types: Add type safety to appEvents
2019-10-14 09:27:47 +01:00
Torkel Ödegaard
22fbaa7ac8
Singlestat: Fixed issue with mapping null to text (#19689) 2019-10-09 09:00:39 +02:00
Hugo Häggmark
13ffb03b57
Chore: Fixes lines that exceeded 150 chars (#19694)
(cherry picked from commit c29b3e2433)
2019-10-08 03:35:44 -07:00
Marcus Efraimsson
0ad2242fb8
Table: Proper handling of json data with dataframes (#19596)
When using Raw Document query with Elasticsearch there's a special 
response from datasource that is used which includes a type field with 
the value json. In the table panel there is a transformation for JSON 
data which up until this fix didn't work at all due to the new data 
structure we call data frames.

Co-Authored-By: Hugo Häggmark <hugo.haggmark@grafana.com>

Fixes #19531
2019-10-08 09:33:33 +02:00
Torkel Ödegaard
99c1c16a04
DataFormats: When transforming TableModel -> DataFrame -> Table preserve the type attribute (#19621) 2019-10-07 09:06:25 +02:00
Andrej Ocenas
0490dbb88d
Explore: Generate log row uid (#18994) 2019-09-30 14:44:15 +02:00
Hugo Häggmark
889f8e3131 PanelData: Adds timeRange prop to PanelData (#19361)
* Refactor: Adds newTimeRange property to PanelData

* Refactor: Handles timeRange prop after requests

* Refactor: Makes timeRange mandatory

* Refactor: Adds DefaultTimeRange
2019-09-25 11:19:17 +02:00
Peter Holmberg
bb0a438705
grafana/ui: Add Timezone picker (#19364)
* first things and story

* fixed data structure and fixed picker

* remove console log

* move variables into global scope
2019-09-24 15:34:12 +02:00
kay delaney
c93325cdd8
Chore: Bump typescript to version 3.6.3 (#19308) 2019-09-24 10:40:16 +01:00
Ryan McKinley
6787e7b5ab
Vector: remove toJSON() from interface (#19254) 2019-09-20 08:22:33 -07:00
Brenda Harjala
c9e566b156 Docs: Minor edits to the README and several md files (#19238)
* Update README.md

Capitalized the G and S in "Getting Started," and moved "guide" to match the section title in the docs.

* Fixed sentence structure. Changed "download" to "grafana.com/get" and changed "get" to "download".

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

*  Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)

* Docs: Replace "datasources" with "data sources" (#19111)
2019-09-20 00:04:56 +02:00
Dominik Prokop
5c0f424d1b
grafana/data: Reorganise code (#19136)
* Organise data frame and vectors code

* Organise transformations

* Move dataframe utils to dataframe dir

* Organise datetime utils

* Organise text utils

* Organise logs utils

* Revert "Organise logs utils"

This reverts commit c24115c755.

* registry -> Registry

* Transformations reorg
2019-09-17 08:23:47 +02:00
Dominik Prokop
1a71501440
Chore: cross-package security bumps (#19131)
* Bump lodash to 4.17.15

* Bump pretty-format to 24.9.0
2019-09-16 15:50:15 +02:00
Torkel Ödegaard
e968a2aa86
DataFrame: Fixes to dealing with empty results (#19119)
* DataFrame: Fixes to dealing with empty results

* review feedback fixes
2019-09-16 13:02:26 +02:00
Torkel Ödegaard
fd21e0ba14
DataLinks: enable access to labels & field names (#18918)
* POC: trying to see if there is a way to support objects in template interpolations

* Added support for nested objects, and arrays

* Added accessor cache

* fixed unit tests

* First take

* Use links supplier in graph

* Add field's index to cache items

* Get field index from field cache

* CHange FiledCacheItem to FieldWithIndex

* Add refId to TimeSeries class

* Make field link supplier work with _series, _field and _value vars

* use field link supplier in graph

* Fix yaxis settings

* Update dashboard schema version and add migration for data links variables

* Update snapshots

* Update build in data link variables

* FieldCache - idx -> index

* Add current query results to panel editor

* WIP Updated data links dropdown to display new variables

* Fix build

* Update variables syntac in field display, update migration

* Field links supplier: review updates

* Add data frame view and field name to TimeSeries for later inspection

* Retrieve data frame from TimeSeries when clicking on plot graph

* Use data frame's index instead of view

* Retrieve data frame by index instead of view on TimeSeries

* Update data links prism regex

* Fix typecheck

* Add value variables to suggestions list

* UI update

* Rename field to config in DisplayProcessorOptions

* Proces single value of a field instead of entire data frame

* Updated font size from 10px to 12px for auto complete

* Replace fieldName with fieldIndex in TimeSeries

* Don't use .entries() for iterating in field cache

* Don't use FieldCache when retrieving field for datalinks in graph

* Add value calculation variable to data links (#19031)

* Add support for labels with dots in the name (#19033)

* Docs update

* Use field name instead of removed series.fieldName

* Add test dashboard

* Typos fix

* Make visualization tab subscribe to query results

* Added tags to dashboard so it shows up in lists

* minor docs fix

* Update singlestat-ish variables suggestions to contain series variables

* Decrease suggestions update debounce

* Enable whitespace characters(new line, space) in links and strip them when processing the data link

* minor data links UI update

* DataLinks: Add __from and __to variables suggestions to data links (#19093)

* Add from and to variables suggestions to data links

* Update docs

* UI update and added info text

* Change ESC global bind to bind (doesn't capture ESC on input)

* Close datalinks suggestions on ESC

* Remove unnecessary fragment
2019-09-13 16:38:21 +02:00
Torkel Ödegaard
140ecbcf79
QueryProcessing: Observable query interface and RxJS for query & stream processing (#18899)
* I needed to learn some rxjs and understand this more, so just playing around

* Updated

* Removed all the complete calls

* Refactoring

* StreamHandler -> observable start

* progress

* simple singal works

* Handle update time range

* added error handling

* wrap old function

* minor changes

* handle data format in the subscribe function

* Use replay subject to return last value to subscribers

* Set loading state after no response in 50ms

* added missing file

* updated comment

* Added cancelation of network requests

* runRequest: Added unit test scenario framework

* Progress on tests

* minor refactor of unit tests

* updated test

* removed some old code

* Shared queries work again, and also became so much simplier

* unified query and observe methods

* implict any fix

* Fixed closed subject issue

* removed comment

* Use last returned data for loading state

* WIP: Explore to runRequest makover step1

* Minor progress

* Minor progress on explore and runRequest

* minor progress

* Things are starting to work in explore

* Updated prometheus to use new observable query response, greatly simplified code

* Revert refId change

* Found better solution for key/refId/requestId problem

* use observable with loki

* tests compile

* fix loki query prep

* Explore: correct first response handling

* Refactorings

* Refactoring

* Explore: Fixes LoadingState and GraphResults between runs (#18986)

* Refactor: Adds state to DataQueryResponse

* Fix: Fixes so we do not empty results before new data arrives
Fixes: #17409

* Transformations work

* observable test data

* remove single() from loki promise

* Fixed comment

* Explore: Fixes failing Loki and Prometheus unit tests (#18995)

* Tests: Makes datasource tests work again

* Fix: Fixes loki datasource so highligthing works

* Chore: Runs Prettier

* Fixed query runner tests

* Delay loading state indication to 200ms

* Fixed test

* fixed unit tests

* Clear cached calcs

* Fixed bug getProcesedDataFrames

* Fix the correct test is a better idea

* Fix: Fixes so queries in Explore are only run if Graph/Table is shown (#19000)

* Fix: Fixes so queries in Explore are only run if Graph/Table is shown
Fixes: #18618

* Refactor: Removes unnecessary condition

* PanelData: provide legacy data only when needed  (#19018)

* no legacy

* invert logic... now compiles

* merge getQueryResponseData and getDataRaw

* update comment about query editor

* use single getData() function

* only send legacy when it is used in explore

* pre process rather than post process

* pre process rather than post process

* Minor refactoring

* Add missing tags to test datasource response

* MixedDatasource: Adds query observable pattern to MixedDatasource (#19037)

* start mixed datasource

* Refactor: Refactors into observable parttern

* Tests: Fixes tests

* Tests: Removes console.log

* Refactor: Adds unique requestId
2019-09-12 17:28:46 +02:00
Dominik Prokop
c2dea633e6
Packages: update versioning and release process (#18195) 2019-09-12 08:00:31 +02:00
Torkel Ödegaard
7ca77b8a98
Calcs: Fixed calc reducer (#18998) 2019-09-11 09:02:33 +02:00
Peter Holmberg
196f8503a8
grafana/ui: Add Time of day picker (#18894)
* Adding DashboardPicker component

* fix prop names

* fix prop names pt2

* add component and modify utils

* add showHour prop

* add minuteStep to TimeOfDayPicker, add value to DashboardPicker

* fix for dashboard picker, missed adding file

* Adding story

* add another story for hiding hour and style fixes

* fix these generated files

* fixes after review

* rename current value

* fix type issue on onChange

* fix story
2019-09-11 09:00:14 +02:00
Ryan McKinley
7520ebadac
Refactor: move ScopedVars to grafana/data (#18992) 2019-09-10 12:06:01 -07:00
Andrej Ocenas
0e3e874eee
Annotations: Add annotations support to Loki (#18949) 2019-09-10 11:04:44 +02:00
Ryan McKinley
7d32caeac2 Transformers: configure result transformations after query(alpha) (#18740) 2019-09-09 08:58:57 +02:00
Dominik Prokop
5f1bb3947c
Storybook: fix type error (#18934)
* Use window.setTimeout/Interval instead of nodejs versions

* Remove awesome-typescript-loader dependency
2019-09-06 10:23:24 +02:00
kay delaney
7985aa1e57
Performance/Webpack: Introduces more aggressive code-splitting and other perf improvements (#18544)
* Performance/Webpack: Introduces more aggressive code-splitting and other perf improvements
- Introduces dynamic imports for built-in plugins
- Uses dynamic imports for various packages (rst2html, brace)
- Introduces route-based dynamic imports
- Splits angular and moment into separate bundles
2019-09-03 09:29:02 +01:00
Ryan McKinley
c777301535 DataFrame: split DataFrameHelper into MutableDataFrame and FieldCache (#18795)
* add appending utility

* add appending utility

* update comment

* rename to mutable

* move mutable functions out of DataFrameHelper

* move mutable functions out of DataFrameHelper

* move mutable functions out of DataFrameHelper

* turn DataFrameHelper into FieldCache

* guess time from name

* graph the numbers

* return the timeField, not just the index

* just warn on duplicate field names

* only use a parser if the input is a string

* append init all fields to the same length

* typo

* only parse string if value is a string

* DataFrame: test fixes

* Switch to null for missing values

* Fixed tests
2019-09-01 14:44:22 +02:00
Torkel Ödegaard
8e9cb5c81a
Explore: Fixes query hint issues (#18803)
* Explore: clear results when you change datasource

* Explore: Clear results on data source change, and fix query hints issue

* Clear results on clear all

* Prometheus: Update logic of when to re-check query hints
2019-08-30 15:22:36 +02:00
Ryan McKinley
5fcbc33710 @grafana/data: Matchers and Transforms (#16756)
* add extension framework

* add filter transformer

* more logging

* adding more tests

* make stats an extension

* make stats an extension

* test registry init

* first get a function, then call it

* move files to data package

* not used

* update to columnar

* Add more tests for nameMatcher

* Fix invert predicate

* add fluent API

* remove calc snapshot

* split Field matchers and Frame matchers

* split filter transformers

* Fix typo
2019-08-28 13:37:46 +02:00
Ryan McKinley
ff6b8c5adc DataLinks: enable data links in Gauge, BarGauge and SingleStat2 panel (#18605)
* datalink on field

* add dataFrame to view

* Use scoped variables to pass series name and value time to data links interpolation

* Use scoped variables to pass series name and value time to data links interpolation

* Enable value specific variable suggestions when Gauge is displaying values

* Fix prettier

* Add basic context menu with data links to GaugePanel

* Fix incorrect import in grafana/ui

* Add custom cursor indicating datalinks available via context menu (in Gauge only now)

* Add data links to SingleStat2

* Minor refactor

* Retrieve data links in a lazy way

* Update test to respect links retrieval being lazy

* delay link creation

* cleanup

* Add origin to LinkModel and introduce field & panel links suppliers

* Add value time and series name field link supplier

* Remove links prop from visualization and implement common UI for data links context menu

* Update snapshot

* Rename className prop to clickTargetClassName

* Simplify condition

* Updated drilldown dashboard and minor changes

* Use class name an onClick handler on the top level dom element in visualization

* Enable series name interpolation when presented value is a calculation
2019-08-28 08:50:43 +02:00
Ryan McKinley
73d9f262bd
@grafana/data: improve the CircularVector api (#18716) 2019-08-26 12:42:27 -07:00
Hugo Häggmark
e5e7bd3153
Dashboard: Adds Logs Panel (alpha) as visualization option for Dashboards (#18641)
* WIP: intial commit

* Switch: Adds tooltip

* Refactor: Adds props to LogsPanelEditor

* Refactor: Moves LogRowContextProvider to grafana/ui

* Refactor: Moves LogRowContext and Alert to grafana/ui

* Refactor: Moves LogLabelStats to grafana/ui

* Refactor: Moves LogLabels and LogLabel to grafana/ui

* Refactor: Moves LogMessageAnsi and ansicolor to grafana/ui

* Refactor: Moves calculateFieldStats, LogsParsers and getParser to grafana/data

* Refactor: Moves findHighlightChunksInText to grafana/data

* Refactor: Moves LogRow to grafana/ui

* Refactor: Moving ExploreGraphPanel to grafana/ui

* Refactor: Copies Logs to grafana/ui

* Refactor: Moves ToggleButtonGroup to grafana/ui

* Refactor: Adds Logs to LogsPanel

* Refactor: Moves styles to emotion

* Feature: Adds LogsRows

* Refactor: Introduces render limit

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Refactor: Adds sorting to LogsPanelEditor

* Tests: Adds tests for sorting

* Refactor: Changes according to PR comments

* Refactor: Changes according to PR comments

* Refactor: Moves Logs and ExploreGraphPanel out of grafana/ui

* Fix: Shows the Show context label again
2019-08-26 08:11:07 +02:00
Hugo Häggmark
774b7267df
Explore: Fixes so Show context shows results again (#18675)
* Fix: Fixes so Show context shows results again
Fixes: #18656

* Refactor: Removes unused import that made it thrugh the pre-commit somehow
2019-08-22 11:10:20 +02:00
Andrej Ocenas
d4382ad906
Add typings to package.json in packages (#18640)
Fixes Go to definition in webstorm
2019-08-22 10:20:17 +02:00
Dominik Prokop
faabb839e6
Chore: Revert React 16.9.0 bump (#18634)
Since React and other dependencies bump caused some troubles with building packages that @kaydelaney and me tried to debug without any success, we decided to revert React 16.9.0 bump.
2019-08-20 11:14:53 +02:00
Ryan McKinley
5a41e8b119 Refactor: move KeyValue and deprecation warning to @grafana/data (#18582)
* move KeyValue and deprecation warning

* move KeyValue and deprecation warning

* rename displayProcessor file
2019-08-16 11:10:32 +02:00
Ryan McKinley
6335509a23 Annotations: use a single row to represent a region (#17673)
* SQLite migrations

* cleanup

* migrate end times

* switch to update with a query

* real migration

* anno migrations

* remove old docs

* set isRegion from time changes

* use <> for is not

* add comment and fix index decleration

* single validation place

* add test

* fix test

* add upgrading docs

* use AnnotationEvent

* fix import

* remove regionId from typescript
2019-08-16 10:49:30 +02:00
Ryan McKinley
e59bae55d9
DataFrame: convert from row based to a columnar value format (#18391) 2019-08-15 09:18:51 -07:00
Ryan McKinley
0ba07720df TimeSeries: assume values are all numbers (#18540)
* assume number for TimeSeries types

* use const
2019-08-14 08:07:21 +02:00
Hugo Häggmark
4b3440325e
Explore: Replaces TimeSeries with GraphSeriesXY (#18475)
* Wip: Compiles and runs

* WIP: Logs Graph partially working

* Refactor: Adds GraphSeriesToggler

* Refactor: Adds tickDecimals to YAxis

* Refactor: Adds TimeZone and PlotSelection to Graph

* Refactor: Makes the graphResult work in Explore

* Refactor: Adds ExploreGraphPanel that is used by Logs and Explore

* Fix: Fixes strange behaviour with ExploreMode not beeing changed

* Fix: Adds onSelectionChanged to GraphWithLegend

* Refactor: Cleans up unused comments

* ExploreGraph: Disable colorpicker
2019-08-13 07:32:43 +02:00
Dominik Prokop
ab17015794
Fix: failing build after React bump (#18514)
* Bump react types and fix yarn.lock
* Fix typecheck
2019-08-12 17:31:58 +02:00
Dominik Prokop
0b828cfa44
Chore: bump React to 16.9.0 (#18502)
* Chore: bump react to 16.9.0

* Bump hooks testing lib
2019-08-12 14:26:11 +02:00
Šimon Podlipský
8b0bbb2c4f Typo: fix typo in processDataFrame.ts comment (#18492) 2019-08-11 21:43:54 -07:00
Tobias Skarhed
151b40ee2f Markdown: Handle undefined/null strings (#18433) 2019-08-07 13:25:09 +02:00
Ryan McKinley
66faedfb9d DataFrame: remove dateFormat (#18424) 2019-08-07 10:20:25 +02:00
Hugo Häggmark
b05afd7e4e
Explore: Moves GraphSeriesXY and DisplayValue to grafana/data (#18400)
* Chore: Move DisplayValue to grafana/data

* Chore: Move GraphSeriesXY to grafana/data
2019-08-06 10:49:54 +02:00
Hugo Häggmark
ead2d6e88f
Explore: Fixes incorrect handling of utc in timeEpic (#18386)
* Fix: Fixes incorrect handling of utc in timeEpic

* Chore: Renames dateTimeFromTimeZone to dateTimeForTimeZone
2019-08-06 10:43:53 +02:00
Torkel Ödegaard
541981c341
Gauge/BarGauge: Rewrite of how migrations are applied (#18375) 2019-08-06 08:26:11 +02:00
Ryan McKinley
d8f86834d9
grafana/toolkit: improve CI task (#18189) 2019-08-03 12:34:02 -07:00
Ryan McKinley
09e7938499 Gauge/BarGauge: Support decimals for min/max toFloatOrUndefined (#18368) 2019-08-03 16:10:41 +02:00
Tobias Skarhed
83da3660da
Chore: noImplictAny no errors left (#18303)
* Add types and rewrite datasourceChanged to async/await
2019-08-01 14:38:34 +02:00
kay delaney
9d87923986
Chore: Upgrades typescript to version 3.5 (#18263)
* Chore: Upgrade typescript to version 3.5
2019-07-26 15:14:06 +01:00
kay delaney
c01bbf2058 Timerange: Fixes a bug where custom time ranges didn't respect UTC (#18248)
Closes #18170
Closes #18178
2019-07-24 15:09:52 +02:00
kay delaney
6144c0f51d Revert "Timerange: Fixes a bug where custom time ranges didn't respect UTC (#18217)" (#18246)
This reverts commit 0752a09f92.
2019-07-24 12:29:12 +02:00
kay delaney
0752a09f92
Timerange: Fixes a bug where custom time ranges didn't respect UTC (#18217)
* Timerange: Fixes a bug where custom timeranges didn't respect UTC
Closes #18170
Closes #18178
2019-07-24 11:00:36 +01:00
Dominik Prokop
3f3fb9bd5c Packages: update package.json files (#18173) 2019-07-23 17:17:41 -07:00
Dominik Prokop
2c8809d3cf
@grafana/toolkit: integrate latest improvements (#18168)
* @grafana/toolkit: make ts-loader ignore files that are not bundled

* @grafana/toolkit: improve the circleci task (#18133)

This PR makes some minor improvements to the circle task

Adds build info to plugin.json
adds dependencies to deployed artifacts
Makes sure prettier has content before writing (avoid writing empty files)
renames 'bundle' to 'package' and saves stuff in a 'packages' file

* @grafana/toolkit: enable plugin themes to work with common stylesheet (#18160)

This makes it possible to use themes styleshheet files and stylesheet imports at the same time. The problem occurred when trying to migrate polystat panel to toolkit: grafana/grafana-polystat-panel#62
2019-07-18 13:48:35 +02:00
Ryan McKinley
c194ae1ba5
Registry: add a reusable function registry (#17047) 2019-07-16 11:40:23 -07:00
Dominik Prokop
de705229ba
Build: Release packages under next tag when changes detected on master (#18062)
* Testing lerna on circle

* Remove dependency on test task, fix yarn

* yarn fix

* Run lerna from local bin

* Use packages cache, run lern via npx

* Add packages:build

* Install packages before release

* Remove cache tmp

* add lerna bootstrap

* temporarily add tsignore

* lerna add data package to ui

* Remove @types/lodas resolution

* Try any...

* Typo fix

* Add publishing packages

* update lerna publish script

* Reset git befgore publishing package

* Correct lerna version

* Packages version bump

* Remove postpublish

* Publish to npm

* Set git creds before commit

* Rename job and run it after frontend tests and build passes

* Run next packages release on master but not when tagged with release

* Minor copy

* Update circle's config

* Fix config
2019-07-15 14:19:08 +02:00
Ryan McKinley
14caa6a068
FieldDisplay: move threshold and mapping to Field (#17043) 2019-07-12 08:32:39 -07:00
Ryan McKinley
ca628832ab grafana/toolkit: improve CircleCI integration (#18071)
* don't actually install grafana in the setup step

* updat eversion changes

* add report stage

* update versions

* don't do failing test

* upate version

* print plugins

* update versions

* copy docs

* Update package.json
2019-07-12 10:25:38 +02:00
Ryan McKinley
7ec87ee76b grafana/toolkit: improve CircleCI stubs (#17995)
* validate type and id

* copy all svg and png, useful if people don't use the img folder

* update comments

* add stubs for each ci task

* use ci-work folder rather than build

* use axios for basic testing

* Packages: publish packages@6.3.0-alpha.39

* bump version

* add download task

* Packages: publish packages@6.3.0-alpha.40

* merge all dist folders into one

* fix folder paths

* Fix ts error

* Packages: publish packages@6.3.0-beta.0

* Packages: publish packages@6.3.0-beta.1

* bump next to 6.4

* Packages: publish packages@6.4.0-alpha.2

* better build and bundle tasks

* fix lint

* Packages: publish packages@6.4.0-alpha.3

* copy the file to start grafana

* Packages: publish packages@6.4.0-alpha.4

* use sudo for copy

* Packages: publish packages@6.4.0-alpha.5

* add missing service

* add service and homepath

* Packages: publish packages@6.4.0-alpha.6

* make the folder

* Update packages/grafana-toolkit/src/cli/tasks/plugin.ci.ts

* Update packages/grafana-toolkit/src/cli/tasks/plugin.ci.ts
2019-07-11 12:47:58 +02:00
Tobias Skarhed
d6e8129588 Packages: create shared tsconfig.json (#18010) 2019-07-10 12:50:52 +02:00
Dominik Prokop
c32365f424 Packages: Use lerna for release orchestration (#17985) 2019-07-09 09:43:53 -07:00
Ryan McKinley
6599bdc7f1
AnnoList: add alpha annotations list plugin (#17187)
adding an alpha panel
2019-07-09 09:28:19 -07:00
Ryan McKinley
d918d1f5f4 Reducers: consistent result for first/last reducer shortcut (#17911)
* find the last non-null value

* also fix first

* check empty first

* remove unused import

* adding lastNotNull
2019-07-09 13:56:00 +02:00
Ryan McKinley
bdaf0aa81a
Refactor: move more files to @grafana/data (#17972) 2019-07-06 09:18:23 -07:00
Ryan McKinley
fcdc29746f
@grafana/data: export dateMath and rangeUtil (#17971) 2019-07-05 23:43:12 -07:00
Ryan McKinley
3f15170914 Refactor: move some files to @grafana/data (#17952)
* moving to data WIP

* more refactoring

* add missing test

* mock full path

* remove sinon from grafana-ui
2019-07-06 08:05:53 +02:00
Tobias Skarhed
8541214c9e
Markdown: Replace rendering library (#17686)
* Replace remarkable with marked

* Add wrapper and options for marked
2019-06-26 13:15:45 +02:00
Ryan McKinley
401615847c
Build: add @grafana/data package (#17436)
first step in moving non-ui components to their own package
2019-06-18 08:17:27 -07:00