ionic-framework icon indicating copy to clipboard operation
ionic-framework copied to clipboard

bug: History Back Button can be clicked while menu is open

Open paulking00 opened this issue 11 years ago • 2 comments

Type: bug

Platform: all

Situation:

Navigation history is enabled, and the open menu button is also visible. When the menu is opened, the user can click on the menu icon again to close the menu. The navigation back button, however is right next to the menu button, and when acidentally clicked, will both close the menu and navigate to the previous page.

Codepen:

http://codepen.io/gnomeontherun/pen/tbvdH

Steps:

  1. Click on Scientific Facts
  2. Open left slide menu
  3. While menu is open, click the navigation history back button

This issue is most apparent on a phone where the menu takes up 80% of the screen.

Opinion:

All buttons on the main page including the back button should be disabled while the menu isopen.

paulking00 avatar Mar 11 '15 09:03 paulking00

Follow this codepen: http://codepen.io/ionic/pen/QwamEW

The ion-side-menus should add enable-menu-with-back-views="false": <ion-side-menus enable-menu-with-back-views="false">

The back button should use the menu-toggle="left" attribute: <button class="button button-icon button-clear ion-navicon" menu-toggle="left">

http://ionicframework.com/docs/api/directive/menuToggle/

adamdbradley avatar Mar 12 '15 01:03 adamdbradley

Hi Adam

Thanks for the initial reply, however I think i may not have sufficiently described the issue.

I want the menu to be able to be opened from all states, thus enable-menu-with-back-views="true"

When you have navigated to a few different pages, and have some navigation history, the ion-nav-back-button is available to navigate back to the previous state.

At this point, if the side menu is opened, all buttons on the page are disabled/non-clickable EXCEPT the ion-nav-back-button. To close the menu, you can click anywhere on the main page and the menu will close. HOWEVER if you click on the ion-nav-back-button, the menu will close AND the app will navigate back to the previous page.

I am of the opinion that also the ion-nav-back-button should be disable/non-clickable when the menu is open.

Hopefully I have better described myself.

situation

paulking00 avatar Mar 12 '15 08:03 paulking00