Skip to content

Commit 276ea47

Browse files
committed
Merge branch 'release/1.0.1'
2 parents 2d73f0a + 0dc921d commit 276ea47

File tree

16 files changed

+149
-159
lines changed

16 files changed

+149
-159
lines changed

.vscode/.BROWSE.VC.DB

4 KB
Binary file not shown.

.vscode/.BROWSE.VC.DB-wal

1010 KB
Binary file not shown.

bower.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "lussa-ui",
33
"description": "Responsive, Mobile-First, Front-End Frameworks for Angular-Based App on Lussa Team",
4-
"version": "1.0.0",
4+
"version": "1.0.1",
55
"homepage": "http://git.lussa.net/tarsius/lussa-ui",
66
"license": "MIT",
77
"main": [

dist/css/lussa-ui.css

Lines changed: 30 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/css/lussa-ui.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/css/lussa-ui.min.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/js/lussa-ui.js

Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*!
2-
* lussa-ui v0.0.1 (http://git.lussa.net/tarsius/tarsius-ui)
3-
* Copyright 2014-2016 Muhammad Hasan
2+
* lussa-ui v1.0.0 (http://git.lussa.net/tarsius/tarsius-ui)
3+
* Copyright 2014-2017 Muhammad Hasan
44
* Licensed under MIT
55
*/
66

@@ -509,7 +509,7 @@ angular.module('lussa.ui.collapse', [])
509509

510510
var dropDown = angular.module('lussa.ui.dropdown',[]);
511511

512-
dropDown.directive('dropdown', ['$log', function($log){
512+
dropDown.directive('dropdown', ['$log','$animate', function($log){
513513
var SPEED_DEFAULT = 500,
514514
EASING_DEFAULT = 'easeOutExpo';
515515

@@ -519,44 +519,27 @@ dropDown.directive('dropdown', ['$log', function($log){
519519
'isOpen': '@',
520520
'onOpen': '&',
521521
'onClose': '&',
522-
'openEasing': '@',
523-
'openSpeed': '@',
524-
'closeEasing': '@',
525-
'closeSpeed': '@',
522+
'enableAnimation': '@',
526523
'toggleByHover': '@'
527524
},
528525
restrict: 'AEC',
529526
link: function(scope, element, attrs, controller) {
530527
// init vars
531-
var opened = attrs.isOpen || false,
528+
var opened = scope.isOpen || false,
532529
wrapper = element,
533530
toggler = element.find('.dropdown-toggle, a:first, .button:first, button:first'),
534-
content = element.find('.dropdown-content, .dropdown-menu'),
535-
fx = {
536-
open: {
537-
speed: attrs.openSpeed || SPEED_DEFAULT,
538-
easing: attrs.openEasing || EASING_DEFAULT,
539-
},
540-
close: {
541-
speed: attrs.closeSpeed || SPEED_DEFAULT,
542-
easing: attrs.closeEasing || EASING_DEFAULT,
543-
}
544-
};
531+
content = element.find('.dropdown-content, .dropdown-menu');
545532

546533
// default state
547-
if(opened)
548-
content.show();
534+
if(opened) open_menu();
549535

550536
/**
551537
* [close_menu description]
552538
* @return {[type]} [description]
553539
*/
554540
function close_menu(){
555541
opened = false;
556-
content.slideUp(fx.open.speed, fx.open.easing, function(){
557-
wrapper.removeClass('open');
558-
});
559-
542+
content.removeClass('open');
560543
// callback
561544
scope.onOpen(element);
562545
}
@@ -567,9 +550,7 @@ dropDown.directive('dropdown', ['$log', function($log){
567550
*/
568551
function open_menu(){
569552
opened = true;
570-
content.slideDown(fx.close.speed, fx.close.easing);
571-
wrapper.addClass('open');
572-
553+
content.addClass('open');
573554
// callback
574555
scope.onClose(element);
575556
}
@@ -598,6 +579,9 @@ dropDown.directive('dropdown', ['$log', function($log){
598579
});
599580
}
600581

582+
toggler.on('blur', function(e){
583+
close_menu();
584+
});
601585
}
602586
};
603587
}]);

dist/js/lussa-ui.min.js

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/dist/css/lussa-ui.css

Lines changed: 30 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/dist/css/lussa-ui.css.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)