1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-23 03:33:54 +00:00

Feature/password protected export (#612)

* Add password protected export

* Run prettier

* Test password protected export service

* Create type for known import type strings

* Test import service changes

* Test bitwarden password importer

* Run prettier

* Remove unnecessary class properties

* Run prettier

* Tslint fixes

* Add KdfType to password protected export

* Linter fixes

* run prettier
This commit is contained in:
Matt Gibson
2022-02-07 10:33:10 -05:00
committed by GitHub
parent 9caea70ea2
commit 7afb748791
8 changed files with 594 additions and 75 deletions

View File

@@ -2,6 +2,11 @@ import { EventView } from "../models/view/eventView";
export abstract class ExportService {
getExport: (format?: "csv" | "json" | "encrypted_json") => Promise<string>;
getPasswordProtectedExport: (
password: string,
format?: "csv" | "json" | "encrypted_json",
organizationId?: string
) => Promise<string>;
getOrganizationExport: (
organizationId: string,
format?: "csv" | "json" | "encrypted_json"

View File

@@ -1,13 +1,14 @@
import { Importer } from "../importers/importer";
import { ImportType } from "../services/import.service";
export interface ImportOption {
id: string;
name: string;
}
export abstract class ImportService {
featuredImportOptions: ImportOption[];
regularImportOptions: ImportOption[];
featuredImportOptions: readonly ImportOption[];
regularImportOptions: readonly ImportOption[];
getImportOptions: () => ImportOption[];
import: (importer: Importer, fileContents: string, organizationId?: string) => Promise<Error>;
getImporter: (format: string, organizationId: string) => Importer;
getImporter: (format: ImportType, organizationId: string, password?: string) => Importer;
}