health page, manifest page, watch unauth, begin redesign

This commit is contained in:
Matt Hill
2021-06-22 17:34:56 -06:00
committed by Aiden McClelland
parent 7013364ae8
commit 5d24d9324c
28 changed files with 614 additions and 302 deletions

View File

@@ -5,7 +5,8 @@ import { isEmptyObject } from '../util/misc.util'
name: 'empty',
})
export class EmptyPipe implements PipeTransform {
transform (obj: { }): boolean {
return isEmptyObject(obj)
transform (val: object | [] = { }): boolean {
if (Array.isArray(val)) return !val.length
return isEmptyObject(val)
}
}

View File

@@ -5,6 +5,12 @@ import { Pipe, PipeTransform } from '@angular/core'
})
export class TypeofPipe implements PipeTransform {
transform (value: any): any {
if (value === null) {
return 'null'
} else if (Array.isArray(value)) {
return 'array'
}
return typeof value
}
}