Last active
August 29, 2015 13:57
-
-
Save gabhi/9735248 to your computer and use it in GitHub Desktop.
ionic side menu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ion-side-menus> | |
<!-- Center content --> | |
<ion-pane ion-side-menu-content> | |
<header class="bar bar-header bar-positive"> | |
<button class="button button-icon" ng-click="toggleMenu()"> | |
Left | |
</button> | |
<h1 class="title">Center</h1> | |
<button class="button button-clear" ng-click="toggleRight()"> | |
Right | |
</button> | |
</header> | |
<ion-content has-header="true" scroll="true"> | |
center content | |
</content> | |
</ion-pane> | |
<!-- Left menu --> | |
<ion-side-menu side="left"> | |
<header class="bar bar-header bar-positive"> | |
Left content header | |
</header> | |
<ion-content has-header="true" scroll="true"> | |
left content | |
</ion-content> | |
</ion-side-menu> | |
<ion-side-menu side="right"> | |
<header class="bar bar-header bar-positive"> | |
right content header | |
</header> | |
<ion-content has-header="true" scroll="true"> | |
right content | |
</ion-content> | |
</ion-side-menu> | |
</ion-side-menus> | |
---- in the contoller add following functions | |
$scope.toggleRight = function() { | |
$scope.sideMenuController.toggleRight(); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment