From 2d31dfc29ca8a80b2a73f13c3fe6d48aff50b58e Mon Sep 17 00:00:00 2001 From: Johannes Millan Date: Sun, 25 Nov 2018 23:14:34 +0100 Subject: [PATCH] refactor(reminders): cleanup --- src/app/app.component.html | 3 +-- src/app/note/note/note.component.ts | 11 ++--------- 2 files changed, 3 insertions(+), 11 deletions(-) diff --git a/src/app/app.component.html b/src/app/app.component.html index e41786a4a1..bf3e40dc60 100644 --- a/src/app/app.component.html +++ b/src/app/app.component.html @@ -10,8 +10,7 @@ [@warpRoute]="getPage(o)"> - diff --git a/src/app/note/note/note.component.ts b/src/app/note/note/note.component.ts index 33f6dee8c2..e235d61c15 100644 --- a/src/app/note/note/note.component.ts +++ b/src/app/note/note/note.component.ts @@ -1,10 +1,8 @@ -import { ChangeDetectionStrategy, Component, Input, OnInit, ViewChild } from '@angular/core'; +import { ChangeDetectionStrategy, Component, Input, ViewChild } from '@angular/core'; import { Note } from '../note.model'; import { NoteService } from '../note.service'; import { MatDialog } from '@angular/material'; import { DialogAddNoteReminderComponent } from '../dialog-add-note-reminder/dialog-add-note-reminder.component'; -import { ReminderService } from '../../reminder/reminder.service'; -import { SnackService } from '../../core/snack/snack.service'; @Component({ selector: 'note', @@ -12,7 +10,7 @@ import { SnackService } from '../../core/snack/snack.service'; styleUrls: ['./note.component.scss'], changeDetection: ChangeDetectionStrategy.OnPush }) -export class NoteComponent implements OnInit { +export class NoteComponent { @Input() note: Note; @Input() isFocus: boolean; @@ -21,14 +19,9 @@ export class NoteComponent implements OnInit { constructor( private readonly _matDialog: MatDialog, private readonly _noteService: NoteService, - private readonly _snackService: SnackService, - private readonly _reminderService: ReminderService, ) { } - ngOnInit() { - } - toggleLock() { this._noteService.update(this.note.id, {isLock: !this.note.isLock}); }