Skip to content

Instantly share code, notes, and snippets.

@naoyeye
Created November 28, 2013 17:05
Show Gist options
  • Save naoyeye/7695067 to your computer and use it in GitHub Desktop.
Save naoyeye/7695067 to your computer and use it in GitHub Desktop.
controllers.controller('TabBarController',function TabBarController ($scope,$log,$http) {
var tabBarItem =$('#tabBar > .item');
var chatPanelOpen = false;
tabBarItem.click(function(){
var tabClass = $(this).data('tab');
if(!chatPanelOpen){
$('#wrapper').addClass(tabClass);
chatPanelOpen = true;
} else{
$('#wrapper').removeClass(tabClass);
chatPanelOpen = false;
}
})
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment