Skip to content

Commit

Permalink
Pack version 0.6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
indrimuska committed Aug 30, 2016
1 parent c3a71b3 commit b74ee7c
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 19 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "angular-moment-picker",
"version": "0.6.0",
"version": "0.6.1",
"authors": [
"Indri Muska <[email protected]>"
],
Expand Down
2 changes: 1 addition & 1 deletion dist/angular-moment-picker.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Angular Moment Picker - v0.6.0 - https://github.com/indrimuska/angular-moment-picker - (c) 2015 Indri Muska - MIT */
/*! Angular Moment Picker - v0.6.1 - https://github.com/indrimuska/angular-moment-picker - (c) 2015 Indri Muska - MIT */
.moment-picker { position: relative; display: block; }
.moment-picker .moment-picker-contents { cursor: pointer; }
.moment-picker .moment-picker-container { color: #404040; min-width: 15em; background: #fff; padding: 4px; border: 1px solid #f0f3f4; border-radius: 4px; position: absolute;
Expand Down
20 changes: 7 additions & 13 deletions dist/angular-moment-picker.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Angular Moment Picker - v0.6.0 - https://github.com/indrimuska/angular-moment-picker - (c) 2015 Indri Muska - MIT */
/*! Angular Moment Picker - v0.6.1 - https://github.com/indrimuska/angular-moment-picker - (c) 2015 Indri Muska - MIT */
(function (angular) {
'use strict';

Expand Down Expand Up @@ -397,17 +397,10 @@
};
// month view
$scope.monthView = {
perLine: 7,
days: (function () {
var days = [],
day = moment().locale($scope.locale).startOf('week'),
end = day.clone().endOf('week');
while (!day.isSame(end, 'day')) {
days.push(day.format('dd'));
day.add(1, 'days');
}
return days;
})(),
perLine: moment.weekdays().length,
days: moment.weekdays().map(function (day, i) {
return moment().locale($scope.locale).startOf('week').add(i, 'day').format('dd');
}),
weeks: [],
render: function () {
var month = $scope.view.moment.month(),
Expand Down Expand Up @@ -683,8 +676,9 @@
// event listeners
$scope.input
.on('focus', function () { if (!$scope.view.isOpen) $scope.$apply($scope.view.open); })
.on('blur', function () { $timeout(function () { if ($scope.view.isOpen && document.activeElement !== $scope.input[0]) $scope.view.close(); }, 10); })
.on('blur', function () { $timeout(function () { if ($scope.view.isOpen && document.activeElement !== $scope.input[0]) $scope.view.close(); }, 100); })
.on('keydown', function (e) { if ($scope.keyboard) $scope.$apply(function () { $scope.view.keydown(e); }); });
$scope.contents.on('click', function () { $scope.input[0].focus(); });
$scope.container.on('click', function () { $scope.input[0].focus(); });
angular.element($window).on('resize scroll', $scope.view.position);
};
Expand Down
2 changes: 1 addition & 1 deletion dist/angular-moment-picker.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit b74ee7c

Please sign in to comment.