Skip to content

Commit

Permalink
extend global scope with custom typescript helper types
Browse files Browse the repository at this point in the history
* so we don't import custom typescript helper types explicitly anymore
  • Loading branch information
vladimiry committed Jun 6, 2019
1 parent 9f9bce6 commit 576d87a
Show file tree
Hide file tree
Showing 63 changed files with 96 additions and 116 deletions.
24 changes: 12 additions & 12 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@
"assets:copy:dev": "cpx \"./src/assets/dist/**/*\" ./app-dev/assets",
"assets:webclient:tutanota": "yarn run assets:webclient:tutanota:base ./app/webclient",
"assets:webclient:tutanota:dev": "yarn run assets:webclient:tutanota:base ./app-dev/webclient",
"assets:webclient:tutanota:base": "ts-node -r tsconfig-paths/register ./scripts/prepare-webclient/tutanota.ts",
"assets:webclient:tutanota:base": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/prepare-webclient/tutanota.ts",
"assets:webclient:protonmail": "yarn run assets:webclient:protonmail:base ./app/webclient",
"assets:webclient:protonmail:dev": "yarn run assets:webclient:protonmail:base ./app-dev/webclient",
"assets:webclient:protonmail:base": "ts-node -r tsconfig-paths/register ./scripts/prepare-webclient/protonmail.ts",
"assets:webclient:protonmail:base": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/prepare-webclient/protonmail.ts",
"electron-builder:install-app-deps": "electron-builder install-app-deps --arch=x64",
"electron-builder:dir": "electron-builder --x64 --dir",
"electron-builder:dist": "electron-builder --x64 --publish never",
Expand All @@ -63,18 +63,18 @@
"lint:ts": "yarn run lint:ts:base \"./src/**/*.ts\" \"./scripts/**/*.ts\" \"./webpack/**/*.ts\"",
"start:electron": "electron ./app/electron-main.js",
"start:electron:dev": "electron ./app-dev/electron-main.js",
"test:e2e": "ava --verbose \"./src/e2e/**/*.{spec,test}.ts\"",
"test:electron-main": "cross-env TS_NODE_PROJECT=./src/electron-main/tsconfig.json ava --verbose \"./src/electron-main/**/*.{spec,test}.ts\"",
"test:e2e": "cross-env TS_NODE_FILES=true ava --verbose \"./src/e2e/**/*.{spec,test}.ts\"",
"test:electron-main": "cross-env TS_NODE_PROJECT=./src/electron-main/tsconfig.json TS_NODE_FILES=true ava --verbose \"./src/electron-main/**/*.{spec,test}.ts\"",
"test:web": "cross-env NODE_ENV=test karma start ./src/web/test/karma.conf.ts --single-run",
"test:web:watch": "cross-env NODE_ENV=test karma start ./src/web/test/karma.conf.ts",
"scripts/dist-packages/print-hashes": "ts-node -r tsconfig-paths/register ./scripts/dist-packages/print-hashes.ts ./dist",
"scripts/dist-packages/upload": "ts-node -r tsconfig-paths/register ./scripts/dist-packages/upload.ts ./dist ./output",
"scripts/download-numbers-font": "ts-node -r tsconfig-paths/register ./scripts/download-numbers-font.ts ./app/assets/numbers.ttf",
"scripts/download-numbers-font:dev": "ts-node -r tsconfig-paths/register ./scripts/download-numbers-font.ts ./app-dev/assets/numbers.ttf",
"scripts/electron-builder/build-snap": "ts-node -r tsconfig-paths/register ./scripts/electron-builder/build-snap.ts",
"scripts/electron-builder/sequential-dist-linux": "ts-node -r tsconfig-paths/register scripts/electron-builder/sequential-dist-linux.ts",
"scripts/print-provider-repo-commit-hash": "ts-node -r tsconfig-paths/register ./scripts/print-provider-repo-commit-hash.ts",
"scripts/transfer": "ts-node -r tsconfig-paths/register ./scripts/transfer/index.ts",
"scripts/dist-packages/print-hashes": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/dist-packages/print-hashes.ts ./dist",
"scripts/dist-packages/upload": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/dist-packages/upload.ts ./dist ./output",
"scripts/download-numbers-font": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/download-numbers-font.ts ./app/assets/numbers.ttf",
"scripts/download-numbers-font:dev": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/download-numbers-font.ts ./app-dev/assets/numbers.ttf",
"scripts/electron-builder/build-snap": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/electron-builder/build-snap.ts",
"scripts/electron-builder/sequential-dist-linux": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register scripts/electron-builder/sequential-dist-linux.ts",
"scripts/print-provider-repo-commit-hash": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/print-provider-repo-commit-hash.ts",
"scripts/transfer": "cross-env TS_NODE_FILES=true ts-node -r tsconfig-paths/register ./scripts/transfer/index.ts",
"scripts/yarn-audit/audit": "scripts/yarn-audit/audit.sh"
},
"ava": {
Expand Down
2 changes: 1 addition & 1 deletion scripts/electron-builder/lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import mkdirp from "mkdirp";
import path from "path";

import {CWD, LOG, LOG_LEVELS, execShell} from "scripts/lib";
import {Locale, Unpacked} from "src/shared/types";
import {Locale} from "src/shared/model/common";
import {normalizeLocale} from "src/shared/util";

interface Dictionary {
Expand Down
2 changes: 0 additions & 2 deletions scripts/lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import path from "path";
import spawnAsync from "@expo/spawn-async";
import {pick} from "ramda";

import {Arguments, Unpacked} from "src/shared/types";

export const CWD = path.resolve(process.cwd());

// tslint:disable-next-line:no-console
Expand Down
1 change: 0 additions & 1 deletion scripts/prepare-webclient/lib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import {promisify} from "util";
import {AccountType} from "src/shared/model/account";
import {CWD, LOG, LOG_LEVELS, execShell} from "scripts/lib";
import {PROVIDER_REPO} from "src/shared/constants";
import {Unpacked} from "src/shared/types";

const [, , baseDestDir] = process.argv;

Expand Down
1 change: 0 additions & 1 deletion scripts/prepare-webclient/protonmail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import {promisify} from "util";

import {FolderAsDomainEntry, execAccountTypeFlow} from "./lib";
import {LOG, LOG_LEVELS, execShell} from "scripts/lib";
import {Unpacked} from "src/shared/types";

// tslint:disable-next-line:no-var-requires no-import-zones
const {name: PROJECT_NAME} = require("package.json");
Expand Down
1 change: 0 additions & 1 deletion scripts/prepare-webclient/tutanota.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import {FolderAsDomainEntry, execAccountTypeFlow} from "./lib";
import {LOG, execShell} from "scripts/lib";
import {Unpacked} from "src/shared/types";

const folderAsDomainEntries: Array<FolderAsDomainEntry<{}>> = [
{
Expand Down
14 changes: 14 additions & 0 deletions src/@types/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import {Observable} from "rxjs";

declare global {
type Arguments<F extends (...x: any[]) => any> =
F extends (...x: infer A) => any ? A : never;

type Unpacked<T> =
T extends Array<infer U1> ? U1 :
T extends Promise<infer U2> ? U2 :
T extends Observable<infer U3> ? U3 :
T;

type Mutable<T> = { -readonly [K in keyof T]: T[K]; };
}
1 change: 0 additions & 1 deletion src/e2e/workflow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import {promisify} from "util";

import {ACCOUNTS_CONFIG, ONE_SECOND_MS, PRODUCT_NAME, RUNTIME_ENV_E2E, RUNTIME_ENV_USER_DATA_DIR} from "src/shared/constants";
import {AccountType} from "src/shared/model/account";
import {Arguments} from "src/shared/types";
import {Config} from "src/shared/model/options";

export interface TestContext {
Expand Down
1 change: 0 additions & 1 deletion src/electron-main/api/endpoints-builders/database/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import {
IpcMainApiEndpoints,
IpcMainServiceScan,
} from "src/shared/api/main";
import {Unpacked} from "src/shared/types";
import {curryFunctionMembers, isEntityUpdatesPatchNotEmpty, walkConversationNodesTree} from "src/shared/util";
import {indexAccount, narrowIndexActionPayload} from "./indexing";
import {prepareFoldersView} from "./folders-view";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import {Config} from "src/shared/model/options";
import {DbAccountPk, INDEXABLE_MAIL_FIELDS_STUB_CONTAINER, Mail, MemoryDbAccount} from "src/shared/model/database";
import {IPC_MAIN_API_DB_INDEXER_NOTIFICATION$, IPC_MAIN_API_DB_INDEXER_ON_NOTIFICATION$} from "src/electron-main/api/constants";
import {IPC_MAIN_API_DB_INDEXER_NOTIFICATION_ACTIONS, IPC_MAIN_API_DB_INDEXER_ON_ACTIONS} from "src/shared/api/main";
import {Unpacked} from "src/shared/types";
import {curryFunctionMembers} from "src/shared/util";
import {hrtimeDuration} from "src/electron-main/util";

Expand Down
1 change: 0 additions & 1 deletion src/electron-main/api/endpoints-builders/general.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import {startWith} from "rxjs/operators";
import {Context} from "src/electron-main/model";
import {IPC_MAIN_API_NOTIFICATION$} from "src/electron-main/api/constants";
import {IPC_MAIN_API_NOTIFICATION_ACTIONS, IpcMainApiEndpoints, IpcMainServiceScan} from "src/shared/api/main";
import {Unpacked} from "src/shared/types";
import {showAboutBrowserWindow} from "src/electron-main/window/about";

type Methods = keyof Pick<IpcMainApiEndpoints,
Expand Down
1 change: 0 additions & 1 deletion src/electron-main/api/index.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ import {Context} from "src/electron-main/model";
import {INITIAL_STORES} from "src/electron-main/constants";
import {IpcMainApiEndpoints} from "src/shared/api/main";
import {StatusCodeError} from "src/shared/model/error";
import {Unpacked} from "src/shared/types";
import {accountPickingPredicate, pickBaseConfigProperties} from "src/shared/util";
import {buildSettingsAdapter} from "src/electron-main/util";

Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {randomBytes} from "crypto";

import {Config, ENCRYPTION_DERIVATION_PRESETS, KEY_DERIVATION_PRESETS, Settings} from "src/shared/model/options";
import {DEFAULT_API_CALL_TIMEOUT, DEFAULT_MESSAGES_STORE_PORTION_SIZE, ONE_MINUTE_MS, ONE_SECOND_MS} from "src/shared/constants";
import {LogLevel} from "src/shared/types";
import {LogLevel} from "src/shared/model/common";

export const INITIAL_STORES: Readonly<{
config: () => Omit<Config, "jsFlags"> & Required<Pick<Config, "jsFlags">>;
Expand Down
1 change: 0 additions & 1 deletion src/electron-main/keytar.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import {pick} from "ramda";

import {PACKAGE_NAME} from "src/shared/constants";
import {Unpacked} from "src/shared/types";

const service = PACKAGE_NAME;
const account = "master-password";
Expand Down
1 change: 0 additions & 1 deletion src/electron-main/session.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import _logger from "electron-log";
import {Session, session} from "electron";

import {AccountConfig, AccountType} from "src/shared/model/account";
import {Arguments} from "src/shared/types";
import {Config} from "src/shared/model/options";
import {Context} from "./model";
import {INITIAL_STORES} from "./constants";
Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/spell-check/controller.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import _logger from "electron-log";

import {Controller, FuzzyLocale, Provider} from "./model";
import {Locale} from "src/shared/types";
import {Locale} from "src/shared/model/common";
import {constructDummyProvider, constructProvider} from "./providers";
import {curryFunctionMembers} from "src/shared/util";

Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/spell-check/menu.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import {MenuItemConstructorOptions, WebContents} from "electron";

import {FuzzyLocale} from "./model";
import {Locale} from "src/shared/types";
import {Locale} from "src/shared/model/common";

export function buildSpellingSuggestionMenuItems(
webContents: Readonly<WebContents>,
Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/spell-check/model.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import {Provider as ElectronProvider} from "electron";

import {Locale} from "src/shared/types";
import {Locale} from "src/shared/model/common";

export type FuzzyLocale = Locale | true | false;

Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/spell-check/providers.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import _logger from "electron-log";
import {Spellchecker} from "spellchecker";

import {Locale} from "src/shared/types";
import {Locale} from "src/shared/model/common";
import {Provider} from "./model";
import {curryFunctionMembers, removeDuplicateItems} from "src/shared/util";

Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/spell-check/setup.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import path from "path";
import semver from "semver";

import {APP_EXEC_PATH_RELATIVE_HUNSPELL_DIR} from "src/shared/constants";
import {Locale} from "src/shared/types";
import {Locale} from "src/shared/model/common";
import {curryFunctionMembers, normalizeLocale, removeDuplicateItems} from "src/shared/util";

export let resolveDefaultLocale: () => Promise<Locale> = async () => {
Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/storage-upgrade.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {AccountConfig} from "src/shared/model/account";
import {Config, Settings} from "src/shared/model/options";
import {Database} from "./database";
import {DbAccountPk} from "src/shared/model/database";
import {EntryUrlItem} from "src/shared/types";
import {EntryUrlItem} from "src/shared/model/common";
import {INITIAL_STORES} from "./constants";

const CONFIG_UPGRADES: Record<string, (config: Config) => void> = {
Expand Down
2 changes: 1 addition & 1 deletion src/electron-main/web-contents.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import {platform} from "os";

import {ACCOUNTS_CONFIG, ACCOUNTS_CONFIG_ENTRY_URL_LOCAL_PREFIX} from "src/shared/constants";
import {Context} from "./model";
import {EntryUrlItem} from "src/shared/types";
import {EntryUrlItem} from "src/shared/model/common";
import {IPC_MAIN_API_NOTIFICATION$} from "./api/constants";
import {IPC_MAIN_API_NOTIFICATION_ACTIONS} from "src/shared/api/main";
import {buildSpellCheckSettingsMenuItems, buildSpellingSuggestionMenuItems} from "src/electron-main/spell-check/menu";
Expand Down
3 changes: 1 addition & 2 deletions src/electron-main/window/about.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {BrowserWindow} from "electron";
import {Context} from "src/electron-main/model";
import {DEFAULT_WEB_PREFERENCES} from "./constants";
import {PACKAGE_DESCRIPTION, PACKAGE_LICENSE, PACKAGE_VERSION, PRODUCT_NAME} from "src/shared/constants";
import {Unpacked} from "src/shared/types";
import {curryFunctionMembers} from "src/shared/util";
import {injectVendorsAppCssIntoHtmlFile} from "src/electron-main/util";

Expand Down Expand Up @@ -73,7 +72,7 @@ export const showAboutBrowserWindow: (ctx: Context) => Promise<BrowserWindow> =
return sanitizeHtml(`<li>${prop.substr(0, 1).toUpperCase()}${prop.substr(1)}: ${versions[prop]}</li>`);
})
.join("")
}
}
</ul>
`,
].join("");
Expand Down
1 change: 0 additions & 1 deletion src/electron-main/window/find-in-page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import {BrowserView} from "electron";

import {Context} from "src/electron-main/model";
import {DEFAULT_WEB_PREFERENCES} from "./constants";
import {Unpacked} from "src/shared/types";
import {curryFunctionMembers} from "src/shared/util";
import {injectVendorsAppCssIntoHtmlFile} from "src/electron-main/util";

Expand Down
6 changes: 3 additions & 3 deletions src/electron-preload/about/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "../../../tsconfig.json",
"include": [
"./index.ts"
"extends": "../tsconfig.json",
"files": [
"./**/*.ts"
]
}
6 changes: 3 additions & 3 deletions src/electron-preload/browser-window/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "../../../tsconfig.json",
"include": [
"./**/*"
"extends": "../tsconfig.json",
"files": [
"./**/*.ts"
]
}
6 changes: 3 additions & 3 deletions src/electron-preload/database-indexer/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "../../../tsconfig.json",
"include": [
"./index.ts"
"extends": "../tsconfig.json",
"files": [
"./**/*.ts"
]
}
2 changes: 1 addition & 1 deletion src/electron-preload/electron-exposure/logger.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import {IFileTransport} from "electron-log"; // tslint:disable-line:no-import-zones
import {remote} from "electron"; // tslint:disable-line:no-import-zones

import {Logger} from "src/shared/types";
import {Logger} from "src/shared/model/common";

const logger: Logger & { transports: { file: IFileTransport } } = remote.require("electron-log");

Expand Down
2 changes: 1 addition & 1 deletion src/electron-preload/events-handling.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {IPC_MAIN_API} from "src/shared/api/main";
import {Logger} from "src/shared/types";
import {Logger} from "src/shared/model/common";

type ObservableElement = Pick<HTMLElement, "addEventListener" | "removeEventListener">;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "../../../tsconfig.json",
"include": [
"./index.ts"
"extends": "../tsconfig.json",
"files": [
"./**/*.ts"
]
}
2 changes: 1 addition & 1 deletion src/electron-preload/spell-check.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import {Deferred} from "ts-deferred";
import {webFrame} from "electron"; // tslint:disable-line:no-import-zones

import {IPC_MAIN_API, IPC_MAIN_API_NOTIFICATION_ACTIONS} from "src/shared/api/main";
import {Locale, Logger} from "src/shared/types";
import {Locale, Logger} from "src/shared/model/common";
import {ONE_SECOND_MS} from "src/shared/constants";

const releaseApiClientDeferred = new Deferred<void>();
Expand Down
6 changes: 6 additions & 0 deletions src/electron-preload/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"extends": "../../tsconfig.json",
"include": [
"./../../src/@types/**/*"
]
}
2 changes: 1 addition & 1 deletion src/electron-preload/util.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import {LOGGER} from "src/electron-preload/electron-exposure/logger";
import {Logger} from "src/shared/types";
import {Logger} from "src/shared/model/common";
import {curryFunctionMembers} from "src/shared/util";

export function buildLoggerBundle(prefix: string): Logger {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import {ProtonmailApi, ProtonmailApiScan} from "src/shared/api/webview/protonmai
import {ProviderApi, resolveProviderApi} from "src/electron-preload/webview/protonmail/lib/provider-api";
import {StatusCodeError} from "src/shared/model/error";
import {UPSERT_EVENT_ACTIONS} from "src/electron-preload/webview/protonmail/lib/rest/model";
import {Unpacked} from "src/shared/types";
import {WEBVIEW_LOGGERS} from "src/electron-preload/webview/constants";
import {asyncDelay, curryFunctionMembers, isDatabaseBootstrapped} from "src/shared/util";
import {buildDbPatchRetryPipeline, buildEmptyDbPatch, persistDatabasePatch, resolveIpcMainApi} from "src/electron-preload/webview/util";
Expand All @@ -34,7 +33,7 @@ const buildDbPatchEndpoint: Pick<ProtonmailApi, "buildDbPatch" | "fetchSingleMai

logger.info();

const deferFactory: () => Promise<BuildDbPatchMethodReturnType> = async () => {
const deferFactory: () => Promise<BuildDbPatchMethodReturnType> = async () => {
logger.info("delayFactory()");

if (!isLoggedIn()) {
Expand Down
2 changes: 1 addition & 1 deletion src/electron-preload/webview/protonmail/api/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ const endpoints: ProtonmailApi = {
Observable<PageTypeOutput>,
Observable<UnreadOutput>,
Observable<BatchEntityUpdatesCounterOutput>
] = [
] = [
interval(WebviewConstants.NOTIFICATION_LOGGED_IN_POLLING_INTERVAL).pipe(
map(() => isLoggedIn()),
distinctUntilChanged(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import {v4 as uuid} from "uuid";

import * as Rest from "./rest";
import {ROLLING_RATE_LIMITER} from "src/electron-preload/electron-exposure/rolling-rate-limiter";
import {Unpacked} from "src/shared/types";
import {WEBVIEW_LOGGERS} from "src/electron-preload/webview/constants";
import {asyncDelay, curryFunctionMembers} from "src/shared/util";
import {resolveIpcMainApi} from "src/electron-preload/webview/util";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import {CONTACT_CARD, ENCRYPTED_STATUS, EVENT_ACTION, LABEL_TYPE, LOCATION, MAIL_TYPE} from "./constats";
import {Id, NumberBoolean} from "./common";
import {Unpacked} from "src/shared/types";

export interface Entity {
ID: Id;
Expand Down Expand Up @@ -139,7 +138,7 @@ export interface ContactEmail extends Entity {
"voice",
"work",
"x-name"
]>>;
]>>;
}

export interface ContactCard<TypeRecord = typeof CONTACT_CARD._.nameValueMap> {
Expand Down
1 change: 0 additions & 1 deletion src/electron-preload/webview/protonmail/lib/util.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import {pick} from "ramda";

import * as Rest from "./rest";
import {Arguments, Unpacked} from "src/shared/types";
import {UPSERT_EVENT_ACTIONS} from "src/electron-preload/webview/protonmail/lib/rest/model";
import {buildDbPatchRetryPipeline} from "src/electron-preload/webview/util";

Expand Down
4 changes: 2 additions & 2 deletions src/electron-preload/webview/protonmail/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"extends": "../../../../tsconfig.json",
"include": [
"extends": "../../tsconfig.json",
"files": [
"./index.ts",
"./typings.d.ts"
]
Expand Down

0 comments on commit 576d87a

Please sign in to comment.