Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins: consistent alpha behaviour across panel/datasource #16530

Merged
merged 10 commits into from
Apr 12, 2019

Conversation

ryantxu
Copy link
Member

@ryantxu ryantxu commented Apr 11, 2019

fixes #16529

In #16528 I will look at adding this to App plugins

This will add a banner to the top of panels that looks like:
image

Text is moved from the datasource -- i did not write it :)

@torkelo
Copy link
Member

torkelo commented Apr 11, 2019

nice!

@@ -162,6 +162,7 @@ func (hs *HTTPServer) getFrontendSettingsMap(c *m.ReqContext) (map[string]interf
"hideFromList": panel.HideFromList,
"sort": getPanelSort(panel.Id),
"dataFormats": panel.DataFormats,
"state": panel.State,
Copy link
Member Author

@ryantxu ryantxu Apr 11, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@torkelo -- now most panel plugins get:

 'state': '',

is there a good way in go to only add state if it exists?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to make dto for this and then we can add json attribute to not include the prop if empty. But leaving that as is for now.

@ryantxu
Copy link
Member Author

ryantxu commented Apr 11, 2019

Trying to make a review on #16528 easier, this includes a few typescript changes that are not really necessary here.

Hopefully this one is pretty straight forward

@ryantxu ryantxu requested a review from torkelo April 11, 2019 20:26
@torkelo
Copy link
Member

torkelo commented Apr 12, 2019

Looks good, made some refactorings, moved to [plugins] section. And updated docs. Added a bit of backward compatible logic to support old location for setting as well.

@torkelo torkelo merged commit 3c21a12 into grafana:master Apr 12, 2019
ryantxu added a commit to ryantxu/grafana that referenced this pull request Apr 12, 2019
…-srv

* grafana/master: (59 commits)
  Chore: Remove implicit anys for DashboardModel and tests (grafana#16553)
  Pushover alert, support for different sound for OK (grafana#16525)
  Chore: Lowered implicit anys limit to 6816
  CloudWatch: Fix template variable expand bug (grafana#16405)
  CloudWatch: fix color order (grafana#16408)
  Plugins: Unifying alpha state & options for all plugins  (grafana#16530)
  Revert "Build: Upgrades to go 1.12.3 (grafana#16491)" (grafana#16544)
  Annotations: Annotation list style improvements   (grafana#16541)
  QueryInspector: Now shows error responses (grafana#16514)
  Build: Upgrades to go 1.12.3 (grafana#16491)
  Build: Update master version number (grafana#16532)
  Elasticsearch: Format elasticsearch test dashboard json (grafana#16537)
  Update jwt regexp to include = (grafana#16521)
  Chore: docs fixes underscore formatting (grafana#16516)
  Fix: Pass missing maxDataPoints to query in Explore (grafana#16513)
  Fix: Recalculate intervals in Explore on run queries (grafana#16510)
  devenv: add elasticsearch v6 filebeat integration (grafana#16493)
  devenv: add worldmap panel panels for elasticsearch (grafana#16313)
  Plugins: Optionally preload some plugins during frontend app boot (grafana#15266)
  Panels: Add types for DataList and range (grafana#16500)
  ...
ryantxu added a commit to ryantxu/grafana that referenced this pull request Apr 14, 2019
* grafana/master: (63 commits)
  DirectInput: new alpha datasource that lets you enter data via CSV
  Plugins: expose getBackendSrv() to plugins (grafana#15268)
  DataPanel: Added built-in interval variables to scopedVars (grafana#16556)
  TestData: Add minInterval query option
  Chore: Remove implicit anys for DashboardModel and tests (grafana#16553)
  Pushover alert, support for different sound for OK (grafana#16525)
  Chore: Lowered implicit anys limit to 6816
  CloudWatch: Fix template variable expand bug (grafana#16405)
  CloudWatch: fix color order (grafana#16408)
  Plugins: Unifying alpha state & options for all plugins  (grafana#16530)
  Revert "Build: Upgrades to go 1.12.3 (grafana#16491)" (grafana#16544)
  Annotations: Annotation list style improvements   (grafana#16541)
  QueryInspector: Now shows error responses (grafana#16514)
  Build: Upgrades to go 1.12.3 (grafana#16491)
  Build: Update master version number (grafana#16532)
  Elasticsearch: Format elasticsearch test dashboard json (grafana#16537)
  Update jwt regexp to include = (grafana#16521)
  Chore: docs fixes underscore formatting (grafana#16516)
  Fix: Pass missing maxDataPoints to query in Explore (grafana#16513)
  Fix: Recalculate intervals in Explore on run queries (grafana#16510)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Consistent alpha support across plugins
2 participants