Giter Site home page Giter Site logo

Default Menu State: Open about grafana HOT 10 CLOSED

raintank avatar raintank commented on June 30, 2024
Default Menu State: Open

from grafana.

Comments (10)

nopzor1200 avatar nopzor1200 commented on June 30, 2024

Probably a good thing for brand new Grafana users too (and then keep hiding it once they close it)?

from grafana.

mattttt avatar mattttt commented on June 30, 2024

Agreed.

from grafana.

bulletfactory avatar bulletfactory commented on June 30, 2024

I like his idea too.

Sent from my iPhone

On Apr 29, 2015, at 6:27 PM, Matt [email protected] wrote:

Agreed.


Reply to this email directly or view it on GitHub.

from grafana.

torkelo avatar torkelo commented on June 30, 2024

It does not make much sense for the state to be open by default for Grafana I think as you seldom need the sidemenu. The sidemenu state is remembered via local storage (browser storage), so the state is remembered when doing full page load.

from grafana.

nopzor1200 avatar nopzor1200 commented on June 30, 2024

I agree it shouldn't be open by default. I also agree you seldom need the side menu (especially as the side menu stands now).

I'm not sure if this was @mattttt original intent (I think it was) or what @bulletfactory thought, but let me rephrase what I thought to be the request:

"On first ever login, the side menu bar should be open"

From there, once they closed it for the first time it'd never appear again (even if they logged out and logged back in), unless they opened it up explicitly

It's a one time thing per user the way I imagine it. Not a default. The intent would be to educate the user that it even exists, how to open/close it, and provide a more 'cosy' introduction to their first 5 seconds in Grafana. (eg. help them add datasource, users, which are the first thing new users need to succeed at doing)

And I could be totally butchering @mattttt suggestion into something else, and maybe he did mean default.

And you could still think it's a bad idea for mainline grafana :)

from grafana.

torkelo avatar torkelo commented on June 30, 2024

@nopzor1200 no, I agree, that is something I have also felt would be good (that it is open on first login, or first 2 logins)

from grafana.

woodsaj avatar woodsaj commented on June 30, 2024

this looks pretty easy to implement.

just need to change this line to the below.
https://github.com/grafana/grafana/blob/master/public/app/services/contextSrv.js#L48

    this.sidemenu = store.getBool('grafana.sidemenu', true);

This will set the sidemenu to open if the the users local browser storage does not yet have any value stored.

from grafana.

nopzor1200 avatar nopzor1200 commented on June 30, 2024

It's not quite the ideal scenario but it's an improvement (It doesn't actually allow for only showing the sidemenu for the first 1 or 2 logins during the lifetime of the user. It just changes the default state)

Let's make this change for raintank/grafana for now, especially since I think we'll be using the sidebar for more stuff imminently..

from grafana.

woodsaj avatar woodsaj commented on June 30, 2024

submitted PR upstream for this.

grafana#1923

from grafana.

woodsaj avatar woodsaj commented on June 30, 2024

commits merged upstream.

from grafana.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.