Commit e22a7d8d authored by Pascal Hartig's avatar Pascal Hartig

Merge branch 'pr/1577'

Close #1577
parents d692aa3f ddd4e059
...@@ -129,7 +129,7 @@ var todos; ...@@ -129,7 +129,7 @@ var todos;
TodoCtrl.prototype.onPath = function (path) { TodoCtrl.prototype.onPath = function (path) {
this.$scope.statusFilter = (path === '/active') ? this.$scope.statusFilter = (path === '/active') ?
{ completed: false } : (path === '/completed') ? { completed: false } : (path === '/completed') ?
{ completed: true } : null; { completed: true } : {};
}; };
TodoCtrl.prototype.onTodos = function () { TodoCtrl.prototype.onTodos = function () {
this.$scope.remainingCount = this.filterFilter(this.todos, { completed: false }).length; this.$scope.remainingCount = this.filterFilter(this.todos, { completed: false }).length;
......
...@@ -52,7 +52,7 @@ module todos { ...@@ -52,7 +52,7 @@ module todos {
onPath(path: string) { onPath(path: string) {
this.$scope.statusFilter = (path === '/active') ? this.$scope.statusFilter = (path === '/active') ?
{ completed: false } : (path === '/completed') ? { completed: false } : (path === '/completed') ?
{ completed: true } : null; { completed: true } : {};
} }
onTodos() { onTodos() {
......
...@@ -10,8 +10,8 @@ module todos { ...@@ -10,8 +10,8 @@ module todos {
doneCount: number; doneCount: number;
allChecked: boolean; allChecked: boolean;
reverted: boolean; reverted: boolean;
statusFilter: { completed: boolean; }; statusFilter: { completed?: boolean };
location: ng.ILocationService; location: ng.ILocationService;
vm: TodoCtrl; vm: TodoCtrl;
} }
} }
\ No newline at end of file
...@@ -316,7 +316,6 @@ html .clear-completed:active { ...@@ -316,7 +316,6 @@ html .clear-completed:active {
line-height: 20px; line-height: 20px;
text-decoration: none; text-decoration: none;
cursor: pointer; cursor: pointer;
position: relative;
} }
.clear-completed:hover { .clear-completed:hover {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment