From d388e8b73dbdcf210c1cad0c439d1de9654dae99 Mon Sep 17 00:00:00 2001 From: Zak Timson Date: Tue, 1 Jan 2019 22:11:03 -0500 Subject: [PATCH] Added placeholder security screen --- src/app/security/security.component.html | 32 +++++++++++++++++++++++- src/app/security/security.component.ts | 22 ++++++++++------ 2 files changed, 45 insertions(+), 9 deletions(-) diff --git a/src/app/security/security.component.html b/src/app/security/security.component.html index 14742dc..575038f 100644 --- a/src/app/security/security.component.html +++ b/src/app/security/security.component.html @@ -1 +1,31 @@ -

Coming Soon

+
+
+ + +
+
+ +
+
+

Armed

+

Standby

+
+
+
+
+ + +

Log

+ +
+
+ {{l.timestamp | date: 'short'}}: + {{l.message}} +
+
+
+
+
+
diff --git a/src/app/security/security.component.ts b/src/app/security/security.component.ts index ce61cb5..9c65ec7 100644 --- a/src/app/security/security.component.ts +++ b/src/app/security/security.component.ts @@ -1,14 +1,20 @@ -import { Component, OnInit } from '@angular/core'; +import {Component} from '@angular/core'; @Component({ - selector: 'app-security', - templateUrl: './security.component.html' + selector: 'app-security', + templateUrl: './security.component.html' }) -export class SecurityComponent implements OnInit { +export class SecurityComponent { + armed: boolean = false; + log = [ + {timestamp: new Date(), message: 'Currently under construction'}, + {timestamp: new Date(), message: 'Give the power button a flick!'}, + ]; - constructor() { } - - ngOnInit() { - } + constructor() { } + toggle() { + this.armed = !this.armed; + this.log = [{timestamp: new Date(), message: this.armed ? 'Arming Security' : 'Disengaged'}].concat(this.log); + } }