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

bug: Can't open right side-menu when left side-menu has expose-aside-when set #3184

Closed
JoeKomputer opened this issue Feb 25, 2015 · 9 comments

Comments

@JoeKomputer
Copy link

Type: bug

Platform: desktop browser

Currently I have two side menus, the left side menu contains the attr expose-aside-when="large". When the view is larger then 768px the left menu is exposed, but this also causes the right menu to become disabled.

@JoeKomputer JoeKomputer changed the title Can't open right side-menu when left side-menu has expose-aside-when set bug: Can't open right side-menu when left side-menu has expose-aside-when set Feb 25, 2015
@calebhaye
Copy link

+1 I'm seeing this too

@calebhaye
Copy link

It appears to be an issue inside of the $ionicSideMenuDelegate's toggleRight() method, as calling that directly produces the same buggy behavior

@calebhaye
Copy link

I've implemented a "fix" on my end, seems to be working well, but I'm not exactly clear on how to run tests and generate a new ionic bundle for testing. I'm going to figure that out soon and then push the fix.

@belliAndrea
Copy link

+1 i'm seeing this. Calebhay tried your solution but it doesn't semms to work :/

@calebhaye
Copy link

There's another piece... I add the following code to the main app delegate

    $scope.toggleRight = function() {
        $ionicSideMenuDelegate.toggleRight();
    };

... then invoke it directly from the view/menu:

    <ion-nav-buttons side="right">
      <button class="button button-icon button-clear ion-navicon" ng-click="toggleRight()" >
      </button>
    </ion-nav-buttons>

@calebhaye
Copy link

Just to be clear, this is not a good fix. If it were, I would fork and yadda yadda. It is however, a viable hack if you need it. I feel your pain, so I want to share what I can to help.

What I did was make the following modifications to the ionic.bundle.js file:

  • Comment out the following code on or near line 47667:
    if (isAsideExposed || !self.right.isEnabled) return;
  • Comment out the following code on or near line 47667:
    if (isAsideExposed || !self.right.isEnabled) return;

That, along with the calling directly via ng-click as aforementioned, did the trick

@krlwlfrt
Copy link

+1

@ericraio
Copy link

I really don't want to have to modify the ionic bundle, is there a permanent fix?

@mlynch
Copy link
Contributor

mlynch commented Dec 7, 2015

Duplicate of #2328 which is now fixed and will be in 1.2

@mlynch mlynch closed this as completed Dec 7, 2015
@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Sep 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants