mirror of
https://github.com/bitwarden/browser
synced 2025-12-17 08:43:33 +00:00
added models, crypto, and constants services
This commit is contained in:
27
src/models/domain/secureNote.ts
Normal file
27
src/models/domain/secureNote.ts
Normal file
@@ -0,0 +1,27 @@
|
||||
import { SecureNoteType } from '../../enums/secureNoteType';
|
||||
|
||||
import { SecureNoteData } from '../data/secureNoteData';
|
||||
|
||||
import Domain from './domain';
|
||||
|
||||
class SecureNote extends Domain {
|
||||
type: SecureNoteType;
|
||||
|
||||
constructor(obj?: SecureNoteData, alreadyEncrypted: boolean = false) {
|
||||
super();
|
||||
if (obj == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.type = obj.type;
|
||||
}
|
||||
|
||||
decrypt(orgId: string): any {
|
||||
return {
|
||||
type: this.type,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
export { SecureNote };
|
||||
(window as any).SecureNote = SecureNote;
|
||||
Reference in New Issue
Block a user