Commit Graph
100 Commits
Author SHA1 Message Date
Dominik Prokop 80a2dce994 Select: Fix direct usages of react-select to make the scroll great again (#21822) 2020-01-29 14:52:43 +01:00
Dominik Prokop 6c32a4c0ab Forms: Allow custom value creation in async select (#21759) 2020-01-28 08:38:21 +01:00
Dominik Prokop d9e1cb44c8 Annotations: Fix issue with annotation queries editors (#21712) 2020-01-24 10:55:54 +01:00
Dominik Prokop 5e87af8b2a grafana/ui: Remove path import from grafana-data (#21707) 2020-01-24 10:02:11 +01:00
Dominik Prokop cdfac32dfd PhantomJS: Fix rendering of panels using Prometheus datasource
In 043bb59 a URLSearchParams usage was introduced which is not supported by PhantomJS. @babel/polyfill(deprecated) does not contain polyfill for URLSearchParams, hence the code (and Prometheus graphs rendering) was failing in PhantomJS environment.

The solution is to add https://www.npmjs.com/package/url-search-params-polyfill that takes care of the URLSearchParams
2020-01-23 13:10:38 +01:00
Dominik Prokop 814020c05c Circle: Introduce es-check to branches & pr workflow (#21677)
* Transpile selected es6 node deps

* Add es-check to build-fast-frontend

* change es-check is used

* transpile react-hook-form
2020-01-23 08:33:39 +01:00
Dominik Prokop 5afcf79c59 Migrations: migrate admin user create page (#21506)
* Create basic react page for AdminUserCreate

* Forms.Field - render asterisk when field is marked as required

* Add validation to user create form wih react-hook-form

* Remove Angular code for UserCreatePage

* Remove commented route for admin settings

* Remove unused import

* Hide react-hooks-form behind Form component

* Fix webkit autofill

* Webkit autofill on inpiuts - bring back focus shadow

* Temporarily fix story (before 21635 is merged)

* Form: docs and minor updates to new form elements (#21635)

* Allow Switch, checkbox to be uncontrolled, forward refs, styles update

* Add Form docs

* User create page update

* Remove unused import

* Apply review notes
2020-01-22 15:26:03 +01:00
Dominik Prokop aba402f98e E2E docs: Add guide to debuging PhantomJS (#21606)
* Add guide to debuging PhanomJS

* Update contribute/style-guides/e2e.md
2020-01-20 08:34:36 +01:00
Dominik Prokop 8bc4ef3e9c Revert "Babel: use babel-loader instead of ts-loader, ng-annotate with babel-plugin-angularjs-annotate (#21554)" (#21570)
This reverts #21554 which caused problems with e2e.
This reverts commit e7e0d18bc8.
2020-01-17 15:52:56 +01:00
Dominik Prokop 18fda3b8b4 Changelog generation: Generate grafana/ui changelog (#21531) 2020-01-16 10:49:35 +01: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
Dominik Prokop 2355d0901a DataLinks: Make data links input grow again (#21499) 2020-01-15 08:20:24 +01:00
Dominik Prokop 386035da4d Storybook: Remove reference to jquery.flot.pie file from storybook config (#21378) 2020-01-07 13:35:10 +01:00
Dominik Prokop 630f75d3ef Forms: revamped select (#21092) 2020-01-07 09:20:06 +01:00
Dominik Prokop 41fd265c64 grafana/ui: Do not build in strict mode as grafana/ui depends on non-strict libs (#21319) 2020-01-03 10:02:27 +01:00
Dominik Prokop 22ff0eab15 grafana/toolkit: Readme update (#21218) 2019-12-20 17:32:30 +01:00
Dominik Prokop d98fa28287 grafana/toolkit: Resolve modules correctly (#21216) 2019-12-20 16:16:55 +01:00
Dominik Prokop 26aa1f0cca DataLinks: Sanitize data/panel link URLs (#21140)
* Sanitize html in panel links

* Add sanitize-url package

* Enable config mocking

* Sanitize datalinks urls

* Update public/app/core/config.ts

* Minor test update

* Remove sanitize-url dependency

* Remove typings

* Review update

* Revert "Remove sanitize-url dependency"

This reverts commit c4f38e6de6.

* Revert "Remove typings"

This reverts commit 676d47e8c2.

* Sanitaze, don't escape html when sanitizing URL
2019-12-18 11:31:11 +01:00
Dominik Prokop 5d6d5bf64d Forms: introduce RadioButtonGroup (#20828)
* introduce checkbox theme variables

* Add checkbox component

* Style tweaks

* Namespace form styles returned from getFormStyles

* wip

* Radio button ui

* Add simple docs for RadioButtonGroup

* Merge fix

* Move radio button variables from theme to component style getter
2019-12-09 14:41:30 +01:00
Dominik ProkopandPeter Holmberg 178bb1d3ab Echo: mechanism for collecting custom events lazily (#20365)
* Introduce Echo for collecting frontend metrics

* Update public/app/core/services/echo/Echo.ts

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

* Custom meta when adding event

* Rename consumer to backend

* Remove buffer from Echo

* Minor tweaks

* Update package.json

* Update public/app/app.ts

* Update public/app/app.ts

* Collect paint metrics when collecting tti. Remove echoBackendFactory

* Update yarn.lock

* Move Echo interfaces to runtime

* progress on meta and echo

* Collect meta analytics events

* Move MetaanalyticsBackend to enterprise repo

* Fixed unit tests

* Removed unused type from test

* Fixed issues with chunk loading (reverted index-template changes)

* Restored changes

* Fixed webpack prod
2019-12-05 08:30:39 +01:00
Dominik Prokop ad33d95dd3 Graphite: Use data frames when procesing annotation query in graphite ds (#20857)
* Use data frames when procesing annotation query in graphite ds

* Remove destruct
2019-12-04 18:07:11 +01:00
Dominik Prokop 3f348287aa Fix prettier (#20827) 2019-12-03 10:23:41 +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
Dominik ProkopandPeter Holmberg 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 b7a3758799 grafana/toolkit: Update FAQ (#20592) 2019-11-25 09:05:02 +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
Dominik Prokop caff9146ea Tooltip: Fix issue with tooltip throwing an error when retrieving values (#20565) 2019-11-21 17:07:11 +01:00
Dominik ProkopandMarcus Olsson bff08ab99f Enable theme context mocking in tests (#20519)
* Enable theme context mocking in tests

* Expose mockThemeContext from grafana/ui

* Add docs

* Update contribute/style-guides/themes.md

Co-Authored-By: Marcus Olsson <olsson.e.marcus@gmail.com>

* Update packages/grafana-ui/src/themes/ThemeContext.tsx

Co-Authored-By: Marcus Olsson <olsson.e.marcus@gmail.com>

* Update contribute/style-guides/themes.md

Co-Authored-By: Marcus Olsson <olsson.e.marcus@gmail.com>

* Docs update

* Update contribute/style-guides/themes.md

Co-Authored-By: Marcus Olsson <olsson.e.marcus@gmail.com>
2019-11-21 16:52:57 +01:00
Dominik Prokop 9f94e059cf grafana/ui: Expose Icon component (#20524) 2019-11-20 17:45:04 +01:00
Dominik Prokop de9ea829a4 Packages: stable release tags update (#20417)
* Update next npm tag when publishing stable release

* shellcheck fix
2019-11-17 19:51:57 +01:00
Dominik Prokop d602da20f6 Fix flot overriding onselectstart/ondrag events (#20381) 2019-11-15 09:21:45 +01:00
Dominik Prokop 17fe704ae8 grafana/ui: Add Icon component (#20353)
* Add Icon component

* Add missing Icon types

* Polish icon story

* Update packages/grafana-ui/src/components/Icon/Icon.mdx
2019-11-13 13:33:29 +01:00
Dominik Prokop 422a94707d ColorPicker: Fixes issue with ColorPicker disappearing too quickly (#20289) 2019-11-11 12:18:03 +01:00
Dominik Prokop 4d741ea387 Build: Collect frontend build time metric (#20254) 2019-11-08 12:48:32 +01:00
Dominik Prokop 225ecd680a Explore: Configure explore series colours via field config (#20239) 2019-11-07 14:58:50 +01:00
Dominik Prokop 96dbed5efc Graph: introduce Tooltip to React graph (#20046) 2019-11-07 12:37:46 +01:00
Dominik Prokop 1c774df823 Docs: Add docs abooout time range URL query params (#20215) 2019-11-07 07:40:50 +01:00
Dominik Prokop df6d8851d0 OAuth: Make the login button display name of custom OAuth provider (#20209) 2019-11-06 16:38:54 +01:00
Dominik Prokop 46a4118461 DataLinks: fix syntax highlighting not being applied on first render (#20199)
* Enable prism syntax for data links outside of effect

* Retrieve theme with useTheme hook
2019-11-06 12:41:41 +01: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
Dominik Prokop 2d7d171e06 grafana/toolkit: save artifacts in a zip id in the folder (#20123) 2019-10-31 15:08:42 -07: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
Dominik Prokop 6edc91aca8 Add info about static files (#19965) 2019-10-23 14:09:25 +02:00
Dominik Prokop 8e824f0b25 grafana/toolkit: Support js plugins (#19952)
* Making flowchart work

* Enable testEnvironment jest option

* Add babel-jest to grafana-toolkit

* Fix test

* Resolve either js or ts jest setup files

* Update packages/grafana-toolkit/src/config/jest.plugin.config.ts

* Update packages/grafana-toolkit/src/config/webpack.plugin.config.ts
2019-10-22 23:23:37 +02:00
Dominik Prokop 64e609e19e Forms: Introduce typographic form elements (#19879)
* Implement Label component

* Expose next-gen form components from grafana-ui under Forms namespace

* Minor Label update

* Add Legend component

* Test form story

* Expose Legend class name via getFormStyles

* Test

* FieldValidationMessage spacing

* Expose FieldValidationMessage styles via getFormStyles

* Update snapshot
2019-10-22 17:36:07 +02:00
Dominik Prokop 2a8762f6a3 grafana/ui: Enable mdx imports in stories (#19937) 2019-10-22 09:05:14 +02:00
Dominik Prokop 3119f35715 grafana/ui: Enable storybook docs (#19930) 2019-10-21 16:39:43 +02:00
Dominik Prokop ccf42ccbd9 Chore: Bump storybook to 5.2.4 (#19895)
* Bump storybook to 5.2.4

* Update yarn.lock

* Babel bump

* Add core-js 2 to dev deps for babel to resolve dependencies correctly

This is because storybook 5.2 introduced core-js 3.x which caused babel to have problems resolving core-js dependencies
2019-10-18 13:45:52 +02:00
Dominik Prokop c9b11bfc7a ReactMigration: Migrate DataSource HTTP Settings to React (#19452)
* Basic components for HTTP settings migration WIP

* Add secureJsonFields to DataSourceSettings

* Introduce datasource-http-settings-next directive for backward compatibility

* fix lint

* renames

* rename fix

* TagsInput component

* move tags from app to grafana/ui

* implement tagsinput on datasourcesettings

* capitalize

* new file for react directive for testing

* some layout touch ups

* FormField story

* Minor touch ups

* add url validation

* using prevent default to prevent updating datasource when adding tag

* using Stylefactory and fix tslint issue on MouseEvent

* only show tlsauthsettings if tls or ca cert

* fix url input length

* fix for showAccessOptions

* Implemented CertTextArea, removed commented code

* removed commented / not used code

* Rename and add more elements to Certification component

* fixing newSecureJsonData

* spelling

* Fix issue with checkboxes being undefined

* Removed old partials and minor fix

* removed unused props from story
2019-10-18 12:09:53 +02:00
Dominik Prokop c674fa1d79 Forms: Introduce new spacing variables to GrafanaTheme (#19875)
* Introduce next-gen form spacing variables
* Update snapshots
2019-10-17 16:13:55 +02:00
Dominik Prokop 1e3b19acd5 Forms: Introduce new color variables to GrafanaTheme (#19874)
* Introduce new color primitives for next-gen forms
* Introduce next-gen form functional colors palette
* Update snapshot
2019-10-17 15:56:17 +02:00
Dominik Prokop 2e18930285 @grafana/toolkit: Check if git user.name config is set (#19821) 2019-10-16 08:04:24 +02:00
Dominik Prokop 00d0640b6e DataLinks: Fix context menu not showing in singlestat-ish visualisations (#19809)
* Fix data links menu being hidden in siglestat-ish visualizations

* ts fix

* Review updates
2019-10-15 13:38:22 +02:00
Dominik Prokop 6f7f9aa774 Add missing info about stylesFactory 2019-10-14 12:29:10 +02:00
Dominik Prokop 1b5e7ceee7 grafana/toolkit: Remove hack to expose plugin/e2e exports & types (#19467) 2019-09-27 08:07:20 -07:00
Dominik Prokop d6eb4e8459 Docs: Update package's manual release guide (#19469) 2019-09-27 14:32:52 +02:00
Dominik Prokop dadc2925a2 Release: Make sure packages are released from clean git state (#19402) 2019-09-26 20:33:14 +02:00
Dominik Prokop 75b21c7603 Docs: Add styling.md with guide to Emotion at Grafana (#19411)
* Add styling.md with guide to emotion

* Update style_guides/styling.md

* Update style_guides/styling.md

* Update style_guides/styling.md

* Update PR guide

* Add stylesFactory helper function

* Simplify styles creator signature

* Make styles factory deps optional

* Update typing

* First batch of updates

* Remove unused import

* Update tests
2019-09-26 20:32:44 +02:00
Dominik Prokopandkay delaney 2aaaa98eee grafana/toolkit: Improve contribution readme (#19400)
* Improve toolkit's readme about contributing

* Update packages/grafana-toolkit/README.md

Co-Authored-By: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2019-09-25 16:23:59 +02:00
Dominik Prokop 97beb26f0c DataLinks: suggestions menu improvements (#19396)
* Deduplicate series labels in datalinks variables suggestions

* Allways show all variables available in datalinks suggestions
2019-09-25 12:46:37 +02:00
Dominik Prokop feb6bc6747 DataLinks: Small UX improvements to DataLinksInput (#19313)
Closes #19257
2019-09-23 14:17:17 +02:00
Dominik Prokop b7752b8c02 Update changelog task to generate toolkit changelog too (#19262) 2019-09-23 11:19:34 +02:00
Dominik Prokop 9feac7753b Docs: Update theming docs (#19248) 2019-09-20 11:27:57 +02:00
Dominik Prokop 809e2ca3c7 grafana/toolkit: Fix toolkit not building @grafana/toolkit (#19253)
* Fix toolkit not building

Weird TS didn't pick this up...

* Update packages/grafana-toolkit/src/cli/index.ts
2019-09-20 11:17:07 +02:00
Dominik Prokop 54ebf174a0 grafana/toolkit: Add plugin scaffolding (#19207) 2019-09-20 09:47:49 +02:00
Dominik Prokop be8097fca2 Snapshots: store DataFrameDTO instead of MutableDataFrame in snapshot data (#19247) 2019-09-20 09:40:16 +02:00
Dominik Prokop fcec156cb3 Chore: Update latest.json (#19177) 2019-09-17 17:37:35 +02:00
Dominik Prokop ca9a46309a Chore: Update version to next (#19169) 2019-09-17 15:54:30 +02:00
Dominik Prokop f7de64bd15 Chore: Changelog for v6.4.0-beta1 (#19171) 2019-09-17 14:04:08 +02:00
Dominik Prokop 503dccb771 Revert "Chore: Update Slate to 0.47.8 (#18412)" (#19167)
This reverts commit 601853fc84.
2019-09-17 13:21:50 +02:00
Dominik Prokop b25cbef361 Docs: What's new 6.4 draft (#19144)
* What's new 6.4 draft

* data model notes

* minor progress

* Only include top highlights list
2019-09-17 12:15:04 +02:00
Dominik Prokop bc0f909a96 Docs: Add docs around feature toggles config (#19162) 2019-09-17 12:11:27 +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
Dominik Prokop 97ff75732d Routing: Update routing to require sign in on every route (#19118)
* Update routing to require sign in on every route

* Review update
2019-09-16 14:06:50 +02:00
Dominik Prokop 44a2a648c6 Login: fix login page failing when navigating from reset password views (#19124) 2019-09-16 13:38:03 +02:00
Dominik Prokop c2bd36f550 grafana/toolkit: Find module files correctly and add basic error tracing (#19089)
* Find correct module files

* Add basic error tracing
2019-09-15 20:20:45 +02:00
Dominik Prokop 0607189ed5 TimeSeries: Replace fieldName with fieldIndex (#19030) 2019-09-12 09:55:15 +02:00
Dominik Prokop c66a23ea31 DataLinksInput - change the way enter key is handled (#18985) 2019-09-12 09:36:57 +02:00
Dominik Prokop 0994350e8b TimeSeries: Add data frame index and field name (#19005) 2019-09-12 08:47:18 +02:00
Dominik Prokop c2dea633e6 Packages: update versioning and release process (#18195) 2019-09-12 08:00:31 +02:00
Dominik Prokop 205c0a58ac grafana/toolkit: Add default mock for stylesheet imports for Jest (#18955)
Up until now one had to manually specify module name mapper for stylesheet files in order for Jest not to fail when running tests that import stylesheet files.

This adds default mock for stylesheet file and some tests
2019-09-09 08:43:15 +02:00
Dominik Prokop e2b1cdd7ac grafana/toolkit: Improve readme (#18747)
* Improve grafana toolkit related readmes

* Post review updates

* Update packages/grafana-toolkit/README.md

* Update packages/grafana-toolkit/README.md
2019-09-09 08:18:38 +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
Dominik Prokop 6e6e2c96dd grafana/toolkit: fix common webpack config (#18862) 2019-09-03 17:28:56 +02:00
Dominik Prokop e4a0b2240d Panels: Destroy panel model when recreating repeated panels (#18799)
Fixes #18533

To recreate the bug described in the original issue in the simplest possible way:

1. Setup dashboard with a single panel and repeat it using variables
2. Set the dashboard refresh to 5s
3. Hover over repeated panel during the refresh

What happened there?
When panels are repeated every time the dashboard is refreshed or variables change the repeated PanelModels are recreated. In https://github.com/grafana/grafana/blob/master/public/app/features/dashboard/state/DashboardModel.ts#L322 the models are removed from dashboard panel's model property what makes the dashboard re-render with source panel only, and then back again with the repeated panels when models are re-created. This means creating new DashboardPanel components. But when the repeated PanelModels are removed, they are not destroyed what results in a behaviour described in #18533.

This is a quick fix for this issue. Ideally I think we should use some cache and update the repeated PanelModels when the refresh or variables change trigger re-render, instead of re-creating those every time. I don't want to do this ATM as the logic around repeating panels is quite complex and require some <3.
2019-08-30 08:42:21 +02:00
Dominik Prokop 90508cdbf2 Datasource: Support min time interval input in ms (#18719)
* Support min time interval input in ms in SQL datasource settings

* Enable ms in elastic min time interval setup
2019-08-29 09:36:10 +02:00
Dominik Prokop 6d3a05a02b TimeSrv: Enable value time windowing in TimeSrv (#18636)
This introduces change to TimeSrv that enables time & time.window query param. Thanks to that time range of a dashboard can be specified as a window(time.window param) around given timestamp(time param)
2019-08-22 11:42:36 +02:00
Dominik Prokop 6c34936aee Packages: Fix path import from grafana/data (#18667) 2019-08-21 13:19:11 -07: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
Dominik Prokop 350b9a9494 Packages: Temporarily skip canary releases if packages build fail (#18577) 2019-08-15 08:02:45 -07:00
Dominik Prokop 15711ba2d1 grafana/toolkit: Unpublish previous "next" version when releasing a new one (#18552)
* Unpublish previous canary when releasing a new one

* Update scripts/circle-release-next-packages.sh

* Shellcheck fix
2019-08-15 09:02:17 +02:00
Dominik Prokop 993e5636d6 Annotations: Fix failing annotation query when time series query is cancelled (#18532) 2019-08-13 13:03:14 +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
Dominik Prokop 81c42fc912 DataLinks: respect timezone when displaying datapoint's timestamp in graph context menu (#18461) 2019-08-09 11:03:21 +02:00
Dominik Prokop b6ec06eeb4 DataLinks: Apply scoped variables correctly (#18454) 2019-08-08 16:36:37 +02:00
Dominik Prokop 20d0c07359 DataLinks: Use datapoint timestamp correctly when interpolating variables (#18459) 2019-08-08 16:30:01 +02:00
Dominik Prokop 6b293cd4e4 Docs: Minor Readme update (#18438) 2019-08-08 08:51:46 +02:00
Dominik Prokop c38804216c DataLinks: Enable multiple data links per panel (#18434)
In response to #18282

DataLinksEditor does not limit amount of links by default now (it was 1 link before, unless maxLinks prop was specified). Also, links that do not have label specified, are not rendered anymore.
2019-08-07 14:13:19 +02:00