new login design (#4442)

* new login design

* remove effects file (wrong direction)

* add Known Hosts dropdown component

Co-authored-by: Jeremy Letto <jeremy.letto@datasite.com>
This commit is contained in:
Jeremy Letto 2021-10-25 13:28:43 -05:00 committed by GitHub
parent 6f360374cc
commit d684a9c5fc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
25 changed files with 675 additions and 212 deletions

View file

@ -0,0 +1,28 @@
import { IndexableType } from 'dexie';
import { Host } from 'types';
import { dexieService } from '../DexieService';
export class HostDTO extends Host {
save() {
return dexieService.hosts.put(this);
}
static add(host: HostDTO): Promise<IndexableType> {
return dexieService.hosts.add(host);
}
static get(id): Promise<HostDTO> {
return dexieService.hosts.where('id').equals(id).first();
}
static getAll(): Promise<HostDTO[]> {
return dexieService.hosts.toArray();
}
static bulkAdd(hosts: Host[]): Promise<IndexableType> {
return dexieService.hosts.bulkAdd(hosts);
}
};
dexieService.hosts.mapToClass(HostDTO);

View file

@ -1,3 +1,4 @@
export * from './CardDTO';
export * from './SetDTO';
export * from './TokenDTO';
export * from './HostDTO';