grafana icon indicating copy to clipboard operation
grafana copied to clipboard

TopNav: Dashboard settings

Open torkelo opened this issue 3 years ago • 2 comments

Part of #50791

  • [x] Make dashboard settings view not an overlay anymore (not absolutely positioned above everything), instead hide dashboard content and display settings view instead.
  • [x] Make edit index a URL parameter so we can use it outside each edit section to build the breadcrumbs (I know this is a bit messy and these should ideally be nested routes but that is a much bigger refactoring, especially to avoid unmounting the dashboard)
  • [x] Make annotations section support deep breadcrumbs
  • [ ] Make variables edit support breadcrumbs
  • [ ] Make links edit support breadcrumbs
  • [ ] Fix missing section nav when going into dashboard settings
  • [ ] Figure out how to add back the reportInteraction call when changing dashboard settings view
  • [ ] Fix the double page titles in many views

torkelo avatar Jul 23 '22 12:07 torkelo

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/27398

grafanabot avatar Jul 23 '22 12:07 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29273

grafanabot avatar Aug 09 '22 11:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29514

grafanabot avatar Aug 10 '22 14:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29664

grafanabot avatar Aug 11 '22 13:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29773

grafanabot avatar Aug 12 '22 07:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29792

grafanabot avatar Aug 12 '22 10:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29798

grafanabot avatar Aug 12 '22 11:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29809

grafanabot avatar Aug 12 '22 12:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29813

grafanabot avatar Aug 12 '22 12:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29817

grafanabot avatar Aug 12 '22 13:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29847

grafanabot avatar Aug 12 '22 14:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29850

grafanabot avatar Aug 12 '22 14:08 grafanabot

Sorry for the massive PR, I realised a bit late that there was a way to not solve everything in one PR (So Links and Versions compare does not support breadcrumbs). But now all the other pages do work.

torkelo avatar Aug 12 '22 14:08 torkelo

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29857

grafanabot avatar Aug 12 '22 15:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/29941

grafanabot avatar Aug 15 '22 07:08 grafanabot

Hi @torkelo 🙇‍♀️, the changes have made the experience of using the settings easier indeed. I tried hard-reloading of the page when I am on DashboardName > Annotations > A Test Annotation and when I am on DashboardName > Variables > A single Variable. The URL loads correctly when reloading with &editview=annotations&editIndex=0, but it fails to load when trying to open &editview=templating&editIndex=0.

It's interesting because it first loads the page and then it fails with:

An unexpected error happened DetailsError: Couldn't find variable with id:testavariable

at ConnectFunction
at div
at div
at div
at Scrollbars 
at CustomScrollbar
at div
at div
at div
at Page
at VariableEditorContainerUnconnected
at ConnectFunction
at DashboardSettings 
at UnthemedDashboardPage 
at DashboardPage
at ConnectFunction 
at LoadableComponent 
at GrafanaRoute 
at Route

polibb avatar Aug 15 '22 10:08 polibb

@ashharrison90

feels like this section header should be the name of the dashboard (instead of just Dashboard) to match the breadcrumbs:

Logically yes, but it somehow felt confusing.

  • Dashboard names can be very short and related to the system it's about, or there is context needed with the folder, this can make the section heading very confusing (unless you know it's the dashboard title).
  • Dashboard names can be very long and won't fit as section heading (so would either wrap or ellipsis.

Might still be the right decision but testing it felt off somehow, sections names should be more familiar and if we use the dashboard name there it's going to be very different each time the user enters dashboard settings. But if it always says "Dashboard" it will be instantly familiar that they are inside the dashboard settings section.

torkelo avatar Aug 16 '22 13:08 torkelo

sure makes sense 👍 doesn't have to hold this out but probably something to discuss with UX later

ashharrison90 avatar Aug 16 '22 14:08 ashharrison90

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30112

grafanabot avatar Aug 16 '22 14:08 grafanabot

@axelavargas added a "+ new variable" button, good catch! the issue with delete not removing the variable state from URL is an issue before this PR (likely existed forever). Also fixed the checkbox form alignment, I had accidentally committed a test of changing the form elements to horizontal, reverted so now the form is exactly like before.

@ashharrison90 removed the semicolon on the permissions page, good catch! really appreciate the help testing this.

torkelo avatar Aug 16 '22 14:08 torkelo

the changes have made the experience of using the settings easier indeed. I tried hard-reloading of the page when I am on DashboardName > Annotations > A Test Annotation and when I am on DashboardName > Variables > A single Variable. The URL loads correctly when reloading with &editview=annotations&editIndex=0, but it fails to load when trying to open &editview=templating&editIndex=0.

@polibb strange unable to replicate this.

torkelo avatar Aug 16 '22 14:08 torkelo

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30116

grafanabot avatar Aug 16 '22 14:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30125

grafanabot avatar Aug 16 '22 15:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30631

grafanabot avatar Aug 22 '22 15:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30722

grafanabot avatar Aug 23 '22 07:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30867

grafanabot avatar Aug 24 '22 07:08 grafanabot

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30924

grafanabot avatar Aug 24 '22 12:08 grafanabot

i think we can solve the a11y thing without reverting back to divs, but i don't wanna suggest that and be wrong and i don't want it to hold out this PR, so once it's in i'll have a play around and maybe raise a follow up

TabsBar and Tab is using divs , so it's consistent right now at least :)

torkelo avatar Aug 24 '22 14:08 torkelo

Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/30939

grafanabot avatar Aug 24 '22 14:08 grafanabot