Drawer - set screen width for auto display

  • I’m build an SPA at the moment whicch uses a drawer for most of its navigation.

    Is it possible to set the minimum display width at which the drawer is displayed? At the moment the drawer is displayed on phones in landscape mode, which I’d like to avoid - I really only want it shown when screen width exceeds say 1000px.


  • Admin

    Upgrade to Quasar v0.13. It will get displayed by default when width is over 920px. Tell me if you need a certain width set.

  • Thanks. If it’s easily configured as a theme variable that would be great, otherwise 920 should work

  • Admin

    You can set $layout-big-min theme variable to 1000px. Note that this has implications in all areas where a big width window detection is used.
    Pushed a commit which adds $drawer-screen-width-threshold theme variable, specifically for what you need. It’s available in edge now and in next version after v0.13.0.

    Best way to go would be to set $drawer-screen-width-threshold theme variable in your app now and wait for next version after v0.13.0 when you’ll be able to see the changes.


  • Excellent - $layout-big-min should be better anyway - due to the way this is getting deployed it will be on either phonesize or ultrawide screens, hence wanting to play with it a little.

  • Admin

    Yes, and this new theme variable will default to $layout-big-min (like it works now) anyway.

Log in to reply