notes infinite scroll

This commit is contained in:
Mo Bitar
2017-01-28 13:58:02 -06:00
parent 92c8892054
commit 5d9c1c3413
11 changed files with 180 additions and 154 deletions

View File

@@ -18,10 +18,11 @@
%li
%a.text{"ng-click" => "ctrl.selectedMenuItem(); ctrl.selectedTagDelete()"} Delete Tag
.note{"ng-repeat" => "note in ctrl.tag.notes | filter: ctrl.filterNotes",
"ng-click" => "ctrl.selectNote(note)", "ng-class" => "{'selected' : ctrl.selectedNote == note}"}
.name{"ng-if" => "note.title"}
{{note.title}}
.note-preview
{{note.text}}
.date {{(note.created_at | appDateTime) || 'Now'}}
%div{"infinite-scroll" => "ctrl.paginate()", "can-load" => "true", "threshold" => "200"}
.note{"ng-repeat" => "note in ctrl.tag.notes | limitTo:ctrl.notesToDisplay | filter: ctrl.filterNotes",
"ng-click" => "ctrl.selectNote(note)"}
.name{"ng-if" => "note.title"}
{{note.title}}
.note-preview
{{note.text}}
.date {{(note.created_at | appDateTime) || 'Now'}}