Skip to content

Instantly share code, notes, and snippets.

@ku1ik
Last active December 15, 2015 03:39
Show Gist options
  • Save ku1ik/5196377 to your computer and use it in GitHub Desktop.
Save ku1ik/5196377 to your computer and use it in GitHub Desktop.
angular.module('time', [])
.directive('accordion', function() {
return function(scope, element, attrs) {
element.find('li').bind('click', function() {
var $li = $(this);
// show $li, hide others
var $calendar = $li.find('.calendar')
var scope = angular.element($calendar).scope()
scope.onDisplayed()
});
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment