1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-11-24 12:06:15 +01:00

Revert "reference barrels"

This reverts commit 2d9f53fbed.
This commit is contained in:
Kyle Spearrin 2018-02-19 13:07:19 -05:00
parent 2d9f53fbed
commit 166ed44392
62 changed files with 223 additions and 293 deletions

View File

@ -1,21 +1,17 @@
import { EnvironmentUrls } from '../models/domain'; import { EnvironmentUrls } from '../models/domain/environmentUrls';
import { import { CipherRequest } from '../models/request/cipherRequest';
CipherRequest, import { FolderRequest } from '../models/request/folderRequest';
FolderRequest, import { PasswordHintRequest } from '../models/request/passwordHintRequest';
PasswordHintRequest, import { RegisterRequest } from '../models/request/registerRequest';
RegisterRequest, import { TokenRequest } from '../models/request/tokenRequest';
TokenRequest, import { TwoFactorEmailRequest } from '../models/request/twoFactorEmailRequest';
TwoFactorEmailRequest,
} from '../models/request';
import { import { CipherResponse } from '../models/response/cipherResponse';
CipherResponse, import { FolderResponse } from '../models/response/folderResponse';
FolderResponse, import { IdentityTokenResponse } from '../models/response/identityTokenResponse';
IdentityTokenResponse, import { IdentityTwoFactorResponse } from '../models/response/identityTwoFactorResponse';
IdentityTwoFactorResponse, import { SyncResponse } from '../models/response/syncResponse';
SyncResponse,
} from '../models/response';
export abstract class ApiService { export abstract class ApiService {
urlsSet: boolean; urlsSet: boolean;

View File

@ -1,6 +1,6 @@
import { TwoFactorProviderType } from '../enums'; import { TwoFactorProviderType } from '../enums/twoFactorProviderType';
import { AuthResult } from '../models/domain'; import { AuthResult } from '../models/domain/authResult';
export abstract class AuthService { export abstract class AuthService {
email: string; email: string;

View File

@ -1,15 +1,11 @@
import { CipherData } from '../models/data'; import { CipherData } from '../models/data/cipherData';
import { import { Cipher } from '../models/domain/cipher';
Cipher, import { Field } from '../models/domain/field';
Field, import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey';
SymmetricCryptoKey,
} from '../models/domain';
import { import { CipherView } from '../models/view/cipherView';
CipherView, import { FieldView } from '../models/view/fieldView';
FieldView,
} from '../models/view';
export abstract class CipherService { export abstract class CipherService {
decryptedCipherCache: CipherView[]; decryptedCipherCache: CipherView[];

View File

@ -1,8 +1,8 @@
import { CollectionData } from '../models/data'; import { CollectionData } from '../models/data/collectionData';
import { Collection } from '../models/domain'; import { Collection } from '../models/domain/collection';
import { CollectionView } from '../models/view'; import { CollectionView } from '../models/view/collectionView';
export abstract class CollectionService { export abstract class CollectionService {
decryptedCollectionCache: CollectionView[]; decryptedCollectionCache: CollectionView[];

View File

@ -1,9 +1,7 @@
import { import { CipherString } from '../models/domain/cipherString';
CipherString, import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey';
SymmetricCryptoKey,
} from '../models/domain';
import { ProfileOrganizationResponse } from '../models/response'; import { ProfileOrganizationResponse } from '../models/response/profileOrganizationResponse';
export abstract class CryptoService { export abstract class CryptoService {
setKey: (key: SymmetricCryptoKey) => Promise<any>; setKey: (key: SymmetricCryptoKey) => Promise<any>;

View File

@ -1,8 +1,8 @@
import { FolderData } from '../models/data'; import { FolderData } from '../models/data/folderData';
import { Folder } from '../models/domain'; import { Folder } from '../models/domain/folder';
import { FolderView } from '../models/view'; import { FolderView } from '../models/view/folderView';
export abstract class FolderService { export abstract class FolderService {
decryptedFolderCache: FolderView[]; decryptedFolderCache: FolderView[];

View File

@ -1,4 +1,4 @@
import { PasswordHistory } from '../models/domain'; import { PasswordHistory } from '../models/domain/passwordHistory';
export abstract class PasswordGenerationService { export abstract class PasswordGenerationService {
generatePassword: (options: any) => string; generatePassword: (options: any) => string;

View File

@ -1,4 +1,4 @@
import { DeviceType } from '../enums'; import { DeviceType } from '../enums/deviceType';
export abstract class PlatformUtilsService { export abstract class PlatformUtilsService {
getDevice: () => DeviceType; getDevice: () => DeviceType;

View File

@ -1,8 +1,6 @@
import { import { AppIdService } from '../abstractions/appId.service';
AppIdService, import { PlatformUtilsService } from '../abstractions/platformUtils.service';
PlatformUtilsService, import { StorageService } from '../abstractions/storage.service';
StorageService,
} from '../abstractions';
import { ConstantsService } from '../services/constants.service'; import { ConstantsService } from '../services/constants.service';

View File

@ -1,4 +1,4 @@
import { AttachmentResponse } from '../response'; import { AttachmentResponse } from '../response/attachmentResponse';
export class AttachmentData { export class AttachmentData {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { CipherType } from '../../enums'; import { CipherType } from '../../enums/cipherType';
import { AttachmentData } from './attachmentData'; import { AttachmentData } from './attachmentData';
import { CardData } from './cardData'; import { CardData } from './cardData';
@ -7,7 +7,7 @@ import { IdentityData } from './identityData';
import { LoginData } from './loginData'; import { LoginData } from './loginData';
import { SecureNoteData } from './secureNoteData'; import { SecureNoteData } from './secureNoteData';
import { CipherResponse } from '../response'; import { CipherResponse } from '../response/cipherResponse';
export class CipherData { export class CipherData {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { CollectionResponse } from '../response'; import { CollectionResponse } from '../response/collectionResponse';
export class CollectionData { export class CollectionData {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { FieldType } from '../../enums'; import { FieldType } from '../../enums/fieldType';
export class FieldData { export class FieldData {
type: FieldType; type: FieldType;

View File

@ -1,4 +1,4 @@
import { FolderResponse } from '../response'; import { FolderResponse } from '../response/folderResponse';
export class FolderData { export class FolderData {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { SecureNoteType } from '../../enums'; import { SecureNoteType } from '../../enums/secureNoteType';
export class SecureNoteData { export class SecureNoteData {
type: SecureNoteType; type: SecureNoteType;

View File

@ -1,9 +1,9 @@
import { AttachmentData } from '../data'; import { AttachmentData } from '../data/attachmentData';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';
import { AttachmentView } from '../view'; import { AttachmentView } from '../view/attachmentView';
export class Attachment extends Domain { export class Attachment extends Domain {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { TwoFactorProviderType } from '../../enums'; import { TwoFactorProviderType } from '../../enums/twoFactorProviderType';
export class AuthResult { export class AuthResult {
twoFactor: boolean = false; twoFactor: boolean = false;

View File

@ -1,9 +1,9 @@
import { CardData } from '../data'; import { CardData } from '../data/cardData';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';
import { CardView } from '../view'; import { CardView } from '../view/cardView';
export class Card extends Domain { export class Card extends Domain {
cardholderName: CipherString; cardholderName: CipherString;

View File

@ -1,8 +1,8 @@
import { CipherType } from '../../enums'; import { CipherType } from '../../enums/cipherType';
import { CipherData } from '../data'; import { CipherData } from '../data/cipherData';
import { CipherView } from '../view'; import { CipherView } from '../view/cipherView';
import { Attachment } from './attachment'; import { Attachment } from './attachment';
import { Card } from './card'; import { Card } from './card';

View File

@ -1,6 +1,6 @@
import { EncryptionType } from '../../enums'; import { EncryptionType } from '../../enums/encryptionType';
import { CryptoService } from '../../abstractions'; import { CryptoService } from '../../abstractions/crypto.service';
export class CipherString { export class CipherString {
encryptedString?: string; encryptedString?: string;

View File

@ -1,6 +1,6 @@
import { CollectionData } from '../data'; import { CollectionData } from '../data/collectionData';
import { CollectionView } from '../view'; import { CollectionView } from '../view/collectionView';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';

View File

@ -1,6 +1,6 @@
import { CipherString } from './cipherString'; import { CipherString } from '../domain/cipherString';
import { View } from '../view'; import { View } from '../view/view';
export default abstract class Domain { export default abstract class Domain {
protected buildDomainModel<D extends Domain>(domain: D, dataObj: any, map: any, protected buildDomainModel<D extends Domain>(domain: D, dataObj: any, map: any,

View File

@ -1,11 +1,11 @@
import { FieldType } from '../../enums'; import { FieldType } from '../../enums/fieldType';
import { FieldData } from '../data'; import { FieldData } from '../data/fieldData';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';
import { FieldView } from '../view'; import { FieldView } from '../view/fieldView';
export class Field extends Domain { export class Field extends Domain {
name: CipherString; name: CipherString;

View File

@ -1,6 +1,6 @@
import { FolderData } from '../data'; import { FolderData } from '../data/folderData';
import { FolderView } from '../view'; import { FolderView } from '../view/folderView';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';

View File

@ -1,9 +1,9 @@
import { IdentityData } from '../data'; import { IdentityData } from '../data/identityData';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';
import { IdentityView } from '../view'; import { IdentityView } from '../view/identityView';
export class Identity extends Domain { export class Identity extends Domain {
title: CipherString; title: CipherString;

View File

@ -1,6 +1,6 @@
import { LoginData } from '../data'; import { LoginData } from '../data/loginData';
import { LoginView } from '../view'; import { LoginView } from '../view/loginView';
import { CipherString } from './cipherString'; import { CipherString } from './cipherString';
import Domain from './domain'; import Domain from './domain';

View File

@ -1,10 +1,10 @@
import { SecureNoteType } from '../../enums'; import { SecureNoteType } from '../../enums/secureNoteType';
import { SecureNoteData } from '../data'; import { SecureNoteData } from '../data/secureNoteData';
import Domain from './domain'; import Domain from './domain';
import { SecureNoteView } from '../view'; import { SecureNoteView } from '../view/secureNoteView';
export class SecureNote extends Domain { export class SecureNote extends Domain {
type: SecureNoteType; type: SecureNoteType;

View File

@ -1,6 +1,6 @@
import * as forge from 'node-forge'; import * as forge from 'node-forge';
import { EncryptionType } from '../../enums'; import { EncryptionType } from '../../enums/encryptionType';
import { SymmetricCryptoKeyBuffers } from './symmetricCryptoKeyBuffers'; import { SymmetricCryptoKeyBuffers } from './symmetricCryptoKeyBuffers';

View File

@ -1,4 +1,4 @@
import { CipherType } from '../../enums'; import { CipherType } from '../../enums/cipherType';
export class CipherRequest { export class CipherRequest {
type: CipherType; type: CipherType;

View File

@ -1,6 +1,6 @@
import { DeviceType } from '../../enums'; import { DeviceType } from '../../enums/deviceType';
import { PlatformUtilsService } from '../../abstractions'; import { PlatformUtilsService } from '../../abstractions/platformUtils.service';
export class DeviceRequest { export class DeviceRequest {
type: DeviceType; type: DeviceType;

View File

@ -1,4 +1,4 @@
import { Folder } from '../domain'; import { Folder } from '../domain/folder';
export class FolderRequest { export class FolderRequest {
name: string; name: string;

View File

@ -1,4 +1,4 @@
import { DeviceType } from '../../enums'; import { DeviceType } from '../../enums/deviceType';
export class DeviceResponse { export class DeviceResponse {
id: string; id: string;

View File

@ -1,4 +1,4 @@
import { TwoFactorProviderType } from '../../enums'; import { TwoFactorProviderType } from '../../enums/twoFactorProviderType';
export class IdentityTwoFactorResponse { export class IdentityTwoFactorResponse {
twoFactorProviders: TwoFactorProviderType[]; twoFactorProviders: TwoFactorProviderType[];

View File

@ -1,6 +1,6 @@
import { View } from './view'; import { View } from './view';
import { Attachment } from '../domain'; import { Attachment } from '../domain/attachment';
export class AttachmentView implements View { export class AttachmentView implements View {
id: string; id: string;

View File

@ -1,6 +1,6 @@
import { View } from './view'; import { View } from './view';
import { Card } from '../domain'; import { Card } from '../domain/card';
export class CardView implements View { export class CardView implements View {
cardholderName: string; cardholderName: string;

View File

@ -1,6 +1,6 @@
import { CipherType } from '../../enums'; import { CipherType } from '../../enums/cipherType';
import { Cipher } from '../domain'; import { Cipher } from '../domain/cipher';
import { AttachmentView } from './attachmentView'; import { AttachmentView } from './attachmentView';
import { CardView } from './cardView'; import { CardView } from './cardView';

View File

@ -1,6 +1,6 @@
import { View } from './view'; import { View } from './view';
import { Collection } from '../domain'; import { Collection } from '../domain/collection';
export class CollectionView implements View { export class CollectionView implements View {
id: string; id: string;

View File

@ -1,8 +1,8 @@
import { FieldType } from '../../enums'; import { FieldType } from '../../enums/fieldType';
import { View } from './view'; import { View } from './view';
import { Field } from '../domain'; import { Field } from '../domain/field';
export class FieldView implements View { export class FieldView implements View {
name: string; name: string;

View File

@ -1,6 +1,6 @@
import { View } from './view'; import { View } from './view';
import { Folder } from '../domain'; import { Folder } from '../domain/folder';
export class FolderView implements View { export class FolderView implements View {
id: string = null; id: string = null;

View File

@ -1,6 +1,6 @@
import { View } from './view'; import { View } from './view';
import { Identity } from '../domain'; import { Identity } from '../domain/identity';
export class IdentityView implements View { export class IdentityView implements View {
title: string = null; title: string = null;

View File

@ -1,9 +1,7 @@
export { AttachmentView } from './attachmentView'; export { AttachmentView } from './attachmentView';
export { CardView } from './cardView'; export { CardView } from './cardView';
export { CipherView } from './cipherView'; export { CipherView } from './cipherView';
export { CollectionView } from './collectionView';
export { FieldView } from './fieldView'; export { FieldView } from './fieldView';
export { FolderView } from './folderView';
export { IdentityView } from './identityView'; export { IdentityView } from './identityView';
export { LoginView } from './loginView'; export { LoginView } from './loginView';
export { SecureNoteView } from './secureNoteView'; export { SecureNoteView } from './secureNoteView';

View File

@ -1,8 +1,8 @@
import { View } from './view'; import { View } from './view';
import { Login } from '../domain'; import { Login } from '../domain/login';
import { PlatformUtilsService } from '../../abstractions'; import { PlatformUtilsService } from '../../abstractions/platformUtils.service';
export class LoginView implements View { export class LoginView implements View {
username: string; username: string;

View File

@ -1,8 +1,8 @@
import { SecureNoteType } from '../../enums'; import { SecureNoteType } from '../../enums/secureNoteType';
import { View } from './view'; import { View } from './view';
import { SecureNote } from '../domain'; import { SecureNote } from '../domain/secureNote';
export class SecureNoteView implements View { export class SecureNoteView implements View {
type: SecureNoteType; type: SecureNoteType;

View File

@ -1,30 +1,24 @@
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { import { ApiService as ApiServiceAbstraction } from '../abstractions/api.service';
ApiService as ApiServiceAbstraction, import { PlatformUtilsService } from '../abstractions/platformUtils.service';
PlatformUtilsService, import { TokenService } from '../abstractions/token.service';
TokenService,
} from '../abstractions';
import { EnvironmentUrls } from '../models/domain'; import { EnvironmentUrls } from '../models/domain/environmentUrls';
import { import { CipherRequest } from '../models/request/cipherRequest';
CipherRequest, import { FolderRequest } from '../models/request/folderRequest';
FolderRequest, import { PasswordHintRequest } from '../models/request/passwordHintRequest';
PasswordHintRequest, import { RegisterRequest } from '../models/request/registerRequest';
RegisterRequest, import { TokenRequest } from '../models/request/tokenRequest';
TokenRequest, import { TwoFactorEmailRequest } from '../models/request/twoFactorEmailRequest';
TwoFactorEmailRequest,
} from '../models/request';
import { import { CipherResponse } from '../models/response/cipherResponse';
CipherResponse, import { ErrorResponse } from '../models/response/errorResponse';
ErrorResponse, import { FolderResponse } from '../models/response/folderResponse';
FolderResponse, import { IdentityTokenResponse } from '../models/response/identityTokenResponse';
IdentityTokenResponse, import { IdentityTwoFactorResponse } from '../models/response/identityTwoFactorResponse';
IdentityTwoFactorResponse, import { SyncResponse } from '../models/response/syncResponse';
SyncResponse,
} from '../models/response';
export class ApiService implements ApiServiceAbstraction { export class ApiService implements ApiServiceAbstraction {
urlsSet: boolean = false; urlsSet: boolean = false;

View File

@ -1,9 +1,7 @@
import { UtilsService } from './utils.service'; import { UtilsService } from './utils.service';
import { import { AppIdService as AppIdServiceInterface } from '../abstractions/appId.service';
AppIdService as AppIdServiceInterface, import { StorageService } from '../abstractions/storage.service';
StorageService,
} from '../abstractions';
export class AppIdService implements AppIdServiceInterface { export class AppIdService implements AppIdServiceInterface {
constructor(private storageService: StorageService) { constructor(private storageService: StorageService) {

View File

@ -1,32 +1,24 @@
import { TwoFactorProviderType } from '../enums'; import { TwoFactorProviderType } from '../enums/twoFactorProviderType';
import { import { AuthResult } from '../models/domain/authResult';
AuthResult, import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey';
SymmetricCryptoKey,
} from '../models/domain';
import { import { DeviceRequest } from '../models/request/deviceRequest';
DeviceRequest, import { TokenRequest } from '../models/request/tokenRequest';
TokenRequest,
} from '../models/request';
import { import { IdentityTokenResponse } from '../models/response/identityTokenResponse';
IdentityTokenResponse, import { IdentityTwoFactorResponse } from '../models/response/identityTwoFactorResponse';
IdentityTwoFactorResponse,
} from '../models/response';
import { ConstantsService } from '../services/constants.service'; import { ConstantsService } from '../services/constants.service';
import { import { ApiService } from '../abstractions/api.service';
ApiService, import { AppIdService } from '../abstractions/appId.service';
AppIdService, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { I18nService } from '../abstractions/i18n.service';
I18nService, import { MessagingService } from '../abstractions/messaging.service';
MessagingService, import { PlatformUtilsService } from '../abstractions/platformUtils.service';
PlatformUtilsService, import { TokenService } from '../abstractions/token.service';
TokenService, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
export const TwoFactorProviders = { export const TwoFactorProviders = {
[TwoFactorProviderType.Authenticator]: { [TwoFactorProviderType.Authenticator]: {

View File

@ -1,47 +1,38 @@
import { CipherType } from '../enums'; import { CipherType } from '../enums/cipherType';
import { CipherData } from '../models/data'; import { CipherData } from '../models/data/cipherData';
import {
Card,
Cipher,
CipherString,
Field,
Identity,
Login,
SecureNote,
SymmetricCryptoKey,
} from '../models/domain';
import { Card } from '../models/domain/card';
import { Cipher } from '../models/domain/cipher';
import { CipherString } from '../models/domain/cipherString';
import Domain from '../models/domain/domain'; import Domain from '../models/domain/domain';
import { Field } from '../models/domain/field';
import { Identity } from '../models/domain/identity';
import { Login } from '../models/domain/login';
import { SecureNote } from '../models/domain/secureNote';
import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey';
import { CipherRequest } from '../models/request'; import { CipherRequest } from '../models/request/cipherRequest';
import { import { CipherResponse } from '../models/response/cipherResponse';
CipherResponse, import { ErrorResponse } from '../models/response/errorResponse';
ErrorResponse,
} from '../models/response';
import { import { CardView } from '../models/view/cardView';
CardView, import { CipherView } from '../models/view/cipherView';
CipherView, import { FieldView } from '../models/view/fieldView';
FieldView, import { IdentityView } from '../models/view/identityView';
IdentityView, import { LoginView } from '../models/view/loginView';
LoginView, import { View } from '../models/view/view';
View,
} from '../models/view';
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { import { ApiService } from '../abstractions/api.service';
ApiService, import { CipherService as CipherServiceAbstraction } from '../abstractions/cipher.service';
CipherService as CipherServiceAbstraction, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { I18nService } from '../abstractions/i18n.service';
I18nService, import { SettingsService } from '../abstractions/settings.service';
SettingsService, import { StorageService } from '../abstractions/storage.service';
StorageService, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
const Keys = { const Keys = {
ciphersPrefix: 'ciphers_', ciphersPrefix: 'ciphers_',

View File

@ -1,16 +1,14 @@
import { CollectionData } from '../models/data'; import { CollectionData } from '../models/data/collectionData';
import { Collection } from '../models/domain'; import { Collection } from '../models/domain';
import { CollectionView } from '../models/view'; import { CollectionView } from '../models/view/collectionView';
import { import { CollectionService as CollectionServiceAbstraction } from '../abstractions/collection.service';
CollectionService as CollectionServiceAbstraction, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { I18nService } from '../abstractions/i18n.service';
I18nService, import { StorageService } from '../abstractions/storage.service';
StorageService, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
const Keys = { const Keys = {
collectionsPrefix: 'collections_', collectionsPrefix: 'collections_',

View File

@ -1,4 +1,4 @@
import { PlatformUtilsService } from '../abstractions'; import { PlatformUtilsService } from '../abstractions/platformUtils.service';
export class ConstantsService { export class ConstantsService {
static readonly environmentUrlsKey: string = 'environmentUrls'; static readonly environmentUrlsKey: string = 'environmentUrls';

View File

@ -1,7 +1,5 @@
import { import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { PlatformUtilsService } from '../abstractions/platformUtils.service';
PlatformUtilsService,
} from '../abstractions';
export class ContainerService { export class ContainerService {
constructor(private cryptoService: CryptoService, constructor(private cryptoService: CryptoService,

View File

@ -1,19 +1,14 @@
import * as forge from 'node-forge'; import * as forge from 'node-forge';
import { EncryptionType } from '../enums'; import { EncryptionType } from '../enums/encryptionType';
import { import { CipherString } from '../models/domain/cipherString';
CipherString, import { EncryptedObject } from '../models/domain/encryptedObject';
EncryptedObject, import { SymmetricCryptoKey } from '../models/domain/symmetricCryptoKey';
SymmetricCryptoKey, import { ProfileOrganizationResponse } from '../models/response/profileOrganizationResponse';
} from '../models/domain';
import { ProfileOrganizationResponse } from '../models/response'; import { CryptoService as CryptoServiceAbstraction } from '../abstractions/crypto.service';
import { StorageService as StorageServiceInterface } from '../abstractions/storage.service';
import {
CryptoService as CryptoServiceAbstraction,
StorageService as StorageServiceAbstraction,
} from '../abstractions';
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { UtilsService } from './utils.service'; import { UtilsService } from './utils.service';
@ -46,8 +41,8 @@ export class CryptoService implements CryptoServiceAbstraction {
private privateKey: ArrayBuffer; private privateKey: ArrayBuffer;
private orgKeys: Map<string, SymmetricCryptoKey>; private orgKeys: Map<string, SymmetricCryptoKey>;
constructor(private storageService: StorageServiceAbstraction, constructor(private storageService: StorageServiceInterface,
private secureStorageService: StorageServiceAbstraction) { private secureStorageService: StorageServiceInterface) {
} }
async setKey(key: SymmetricCryptoKey): Promise<any> { async setKey(key: SymmetricCryptoKey): Promise<any> {

View File

@ -1,12 +1,10 @@
import { EnvironmentUrls } from '../models/domain'; import { EnvironmentUrls } from '../models/domain/environmentUrls';
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { import { ApiService } from '../abstractions/api.service';
ApiService, import { EnvironmentService as EnvironmentServiceAbstraction } from '../abstractions/environment.service';
EnvironmentService as EnvironmentServiceAbstraction, import { StorageService } from '../abstractions/storage.service';
StorageService,
} from '../abstractions';
export class EnvironmentService implements EnvironmentServiceAbstraction { export class EnvironmentService implements EnvironmentServiceAbstraction {
baseUrl: string; baseUrl: string;

View File

@ -1,21 +1,19 @@
import { FolderData } from '../models/data'; import { FolderData } from '../models/data/folderData';
import { Folder } from '../models/domain'; import { Folder } from '../models/domain/folder';
import { FolderRequest } from '../models/request'; import { FolderRequest } from '../models/request/folderRequest';
import { FolderResponse } from '../models/response'; import { FolderResponse } from '../models/response/folderResponse';
import { FolderView } from '../models/view'; import { FolderView } from '../models/view/folderView';
import { import { ApiService } from '../abstractions/api.service';
ApiService, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { FolderService as FolderServiceAbstraction } from '../abstractions/folder.service';
FolderService as FolderServiceAbstraction, import { I18nService } from '../abstractions/i18n.service';
I18nService, import { StorageService } from '../abstractions/storage.service';
StorageService, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
const Keys = { const Keys = {
foldersPrefix: 'folders_', foldersPrefix: 'folders_',

View File

@ -1,15 +1,13 @@
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { import { CipherService } from '../abstractions/cipher.service';
CipherService, import { CollectionService } from '../abstractions/collection.service';
CollectionService, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { FolderService } from '../abstractions/folder.service';
FolderService, import { LockService as LockServiceAbstraction } from '../abstractions/lock.service';
LockService as LockServiceAbstraction, import { MessagingService } from '../abstractions/messaging.service';
MessagingService, import { PlatformUtilsService } from '../abstractions/platformUtils.service';
PlatformUtilsService, import { StorageService } from '../abstractions/storage.service';
StorageService,
} from '../abstractions';
export class LockService implements LockServiceAbstraction { export class LockService implements LockServiceAbstraction {
constructor(private cipherService: CipherService, private folderService: FolderService, constructor(private cipherService: CipherService, private folderService: FolderService,

View File

@ -1,15 +1,13 @@
import { import { CipherString } from '../models/domain/cipherString';
CipherString, import { PasswordHistory } from '../models/domain/passwordHistory';
PasswordHistory,
} from '../models/domain';
import { UtilsService } from './utils.service'; import { UtilsService } from './utils.service';
import { CryptoService } from '../abstractions/crypto.service';
import { import {
CryptoService,
PasswordGenerationService as PasswordGenerationServiceAbstraction, PasswordGenerationService as PasswordGenerationServiceAbstraction,
StorageService, } from '../abstractions/passwordGeneration.service';
} from '../abstractions'; import { StorageService } from '../abstractions/storage.service';
const DefaultOptions = { const DefaultOptions = {
length: 14, length: 14,

View File

@ -1,8 +1,6 @@
import { import { SettingsService as SettingsServiceAbstraction } from '../abstractions/settings.service';
SettingsService as SettingsServiceAbstraction, import { StorageService } from '../abstractions/storage.service';
StorageService, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
const Keys = { const Keys = {
settingsPrefix: 'settings_', settingsPrefix: 'settings_',

View File

@ -1,4 +1,4 @@
import { StateService as StateServiceAbstraction } from '../abstractions'; import { StateService as StateServiceAbstraction } from '../abstractions/state.service';
export class StateService implements StateServiceAbstraction { export class StateService implements StateServiceAbstraction {
private state: any = {}; private state: any = {};

View File

@ -1,29 +1,23 @@
import { import { ApiService } from '../abstractions/api.service';
ApiService, import { CipherService } from '../abstractions/cipher.service';
CipherService, import { CollectionService } from '../abstractions/collection.service';
CollectionService, import { CryptoService } from '../abstractions/crypto.service';
CryptoService, import { FolderService } from '../abstractions/folder.service';
FolderService, import { MessagingService } from '../abstractions/messaging.service';
MessagingService, import { SettingsService } from '../abstractions/settings.service';
SettingsService, import { StorageService } from '../abstractions/storage.service';
StorageService, import { SyncService as SyncServiceAbstraction } from '../abstractions/sync.service';
SyncService as SyncServiceAbstraction, import { UserService } from '../abstractions/user.service';
UserService,
} from '../abstractions';
import { import { CipherData } from '../models/data/cipherData';
CipherData, import { CollectionData } from '../models/data/collectionData';
CollectionData, import { FolderData } from '../models/data/folderData';
FolderData,
} from '../models/data';
import { import { CipherResponse } from '../models/response/cipherResponse';
CipherResponse, import { CollectionResponse } from '../models/response/collectionResponse';
CollectionResponse, import { DomainsResponse } from '../models/response/domainsResponse';
DomainsResponse, import { FolderResponse } from '../models/response/folderResponse';
FolderResponse, import { ProfileResponse } from '../models/response/profileResponse';
ProfileResponse,
} from '../models/response';
const Keys = { const Keys = {
lastSyncPrefix: 'lastSync_', lastSyncPrefix: 'lastSync_',

View File

@ -1,10 +1,8 @@
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { UtilsService } from './utils.service'; import { UtilsService } from './utils.service';
import { import { StorageService } from '../abstractions/storage.service';
StorageService, import { TokenService as TokenServiceAbstraction } from '../abstractions/token.service';
TokenService as TokenServiceAbstraction,
} from '../abstractions';
const Keys = { const Keys = {
accessToken: 'accessToken', accessToken: 'accessToken',

View File

@ -1,9 +1,7 @@
import { ConstantsService } from './constants.service'; import { ConstantsService } from './constants.service';
import { import { StorageService } from '../abstractions/storage.service';
StorageService, import { TotpService as TotpServiceAbstraction } from '../abstractions/totp.service';
TotpService as TotpServiceAbstraction,
} from '../abstractions';
const b32Chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ234567'; const b32Chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ234567';

View File

@ -1,8 +1,6 @@
import { import { StorageService } from '../abstractions/storage.service';
StorageService, import { TokenService } from '../abstractions/token.service';
TokenService, import { UserService as UserServiceAbsrtaction } from '../abstractions/user.service';
UserService as UserServiceAbsrtaction,
} from '../abstractions';
const Keys = { const Keys = {
userId: 'userId', userId: 'userId',

View File

@ -1,4 +1,4 @@
import { UtilsService as UtilsServiceAbstraction } from '../abstractions'; import { UtilsService as UtilsServiceAbstraction } from '../abstractions/utils.service';
export class UtilsService implements UtilsServiceAbstraction { export class UtilsService implements UtilsServiceAbstraction {
static copyToClipboard(text: string, doc?: Document): void { static copyToClipboard(text: string, doc?: Document): void {