diff options
| author | Oskar Nyberg <oskar@mullvad.net> | 2024-06-14 11:41:11 +0200 |
|---|---|---|
| committer | Oskar Nyberg <oskar@mullvad.net> | 2024-06-18 15:04:34 +0200 |
| commit | 59f21bba30b22a627d77184275a67a4d09daed23 (patch) | |
| tree | 0868fe15307d38ca85aec5a1369f33d4e680ff95 /gui/src/shared | |
| parent | 454df7dd6b0ff70c5eb63da5745e39e2b5c5897e (diff) | |
| download | mullvadvpn-59f21bba30b22a627d77184275a67a4d09daed23.tar.xz mullvadvpn-59f21bba30b22a627d77184275a67a4d09daed23.zip | |
Fix eslint errors
All changes in this commit were produced by running `npm run lint --
--fix`.
Diffstat (limited to 'gui/src/shared')
| -rw-r--r-- | gui/src/shared/daemon-rpc-types.ts | 9 | ||||
| -rw-r--r-- | gui/src/shared/ipc-helpers.ts | 2 | ||||
| -rw-r--r-- | gui/src/shared/notifications/block-when-disconnected.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/close-to-account-expiry.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/connecting.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/error.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/inconsistent-version.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/reconnecting.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/unsupported-version.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/notifications/update-available.ts | 3 |
10 files changed, 21 insertions, 14 deletions
diff --git a/gui/src/shared/daemon-rpc-types.ts b/gui/src/shared/daemon-rpc-types.ts index ce0f3a8968..295db8f323 100644 --- a/gui/src/shared/daemon-rpc-types.ts +++ b/gui/src/shared/daemon-rpc-types.ts @@ -490,11 +490,10 @@ export type NewAccessMethodSetting<T extends AccessMethod = AccessMethod> = Name enabled: boolean; }; -export type AccessMethodSetting< - T extends AccessMethod = AccessMethod -> = NewAccessMethodSetting<T> & { - id: string; -}; +export type AccessMethodSetting<T extends AccessMethod = AccessMethod> = + NewAccessMethodSetting<T> & { + id: string; + }; export type ApiAccessMethodSettings = { direct: AccessMethodSetting<DirectMethod>; diff --git a/gui/src/shared/ipc-helpers.ts b/gui/src/shared/ipc-helpers.ts index 0ff3ca2064..c49b7df9b8 100644 --- a/gui/src/shared/ipc-helpers.ts +++ b/gui/src/shared/ipc-helpers.ts @@ -39,7 +39,7 @@ type IpcMainFn<I extends AnyIpcCall> = I['direction'] extends 'main-to-renderer' // Renames all receiving IPC calls, e.g. `callName` to `listenCallName`. type IpcRendererKey< N extends string, - I extends AnyIpcCall + I extends AnyIpcCall, > = I['direction'] extends 'main-to-renderer' ? `listen${Capitalize<N>}` : N; // Selects either the send or receive function depending on direction. diff --git a/gui/src/shared/notifications/block-when-disconnected.ts b/gui/src/shared/notifications/block-when-disconnected.ts index c0b2f4e0f1..2f3df718b6 100644 --- a/gui/src/shared/notifications/block-when-disconnected.ts +++ b/gui/src/shared/notifications/block-when-disconnected.ts @@ -19,7 +19,8 @@ interface BlockWhenDisconnectedNotificationContext { } export class BlockWhenDisconnectedNotificationProvider - implements InAppNotificationProvider, SystemNotificationProvider { + implements InAppNotificationProvider, SystemNotificationProvider +{ public constructor(private context: BlockWhenDisconnectedNotificationContext) {} public mayDisplay() { diff --git a/gui/src/shared/notifications/close-to-account-expiry.ts b/gui/src/shared/notifications/close-to-account-expiry.ts index 60feb7ec4d..4fde6ab395 100644 --- a/gui/src/shared/notifications/close-to-account-expiry.ts +++ b/gui/src/shared/notifications/close-to-account-expiry.ts @@ -18,7 +18,8 @@ interface CloseToAccountExpiryNotificationContext { } export class CloseToAccountExpiryNotificationProvider - implements InAppNotificationProvider, SystemNotificationProvider { + implements InAppNotificationProvider, SystemNotificationProvider +{ public constructor(private context: CloseToAccountExpiryNotificationContext) {} public mayDisplay = () => closeToExpiry(this.context.accountExpiry); diff --git a/gui/src/shared/notifications/connecting.ts b/gui/src/shared/notifications/connecting.ts index 214e015e10..444dd42beb 100644 --- a/gui/src/shared/notifications/connecting.ts +++ b/gui/src/shared/notifications/connecting.ts @@ -17,7 +17,8 @@ interface ConnectingNotificationContext { } export class ConnectingNotificationProvider - implements SystemNotificationProvider, InAppNotificationProvider { + implements SystemNotificationProvider, InAppNotificationProvider +{ public constructor(private context: ConnectingNotificationContext) {} public mayDisplay() { diff --git a/gui/src/shared/notifications/error.ts b/gui/src/shared/notifications/error.ts index 387ed146a9..dae080bb29 100644 --- a/gui/src/shared/notifications/error.ts +++ b/gui/src/shared/notifications/error.ts @@ -26,7 +26,8 @@ interface ErrorNotificationContext { } export class ErrorNotificationProvider - implements SystemNotificationProvider, InAppNotificationProvider { + implements SystemNotificationProvider, InAppNotificationProvider +{ public constructor(private context: ErrorNotificationContext) {} public mayDisplay = () => this.context.tunnelState.state === 'error'; diff --git a/gui/src/shared/notifications/inconsistent-version.ts b/gui/src/shared/notifications/inconsistent-version.ts index f4a5616c43..e4f7a8ddc1 100644 --- a/gui/src/shared/notifications/inconsistent-version.ts +++ b/gui/src/shared/notifications/inconsistent-version.ts @@ -13,7 +13,8 @@ interface InconsistentVersionNotificationContext { } export class InconsistentVersionNotificationProvider - implements SystemNotificationProvider, InAppNotificationProvider { + implements SystemNotificationProvider, InAppNotificationProvider +{ public constructor(private context: InconsistentVersionNotificationContext) {} public mayDisplay = () => !this.context.consistent; diff --git a/gui/src/shared/notifications/reconnecting.ts b/gui/src/shared/notifications/reconnecting.ts index 43491322f0..4362c0edb6 100644 --- a/gui/src/shared/notifications/reconnecting.ts +++ b/gui/src/shared/notifications/reconnecting.ts @@ -10,7 +10,8 @@ import { } from './notification'; export class ReconnectingNotificationProvider - implements SystemNotificationProvider, InAppNotificationProvider { + implements SystemNotificationProvider, InAppNotificationProvider +{ public constructor(private context: TunnelState) {} public mayDisplay() { diff --git a/gui/src/shared/notifications/unsupported-version.ts b/gui/src/shared/notifications/unsupported-version.ts index 9d41bc268c..15c622703c 100644 --- a/gui/src/shared/notifications/unsupported-version.ts +++ b/gui/src/shared/notifications/unsupported-version.ts @@ -17,7 +17,8 @@ interface UnsupportedVersionNotificationContext { } export class UnsupportedVersionNotificationProvider - implements SystemNotificationProvider, InAppNotificationProvider { + implements SystemNotificationProvider, InAppNotificationProvider +{ public constructor(private context: UnsupportedVersionNotificationContext) {} public mayDisplay() { diff --git a/gui/src/shared/notifications/update-available.ts b/gui/src/shared/notifications/update-available.ts index 6f63bafd89..732e7bb9a8 100644 --- a/gui/src/shared/notifications/update-available.ts +++ b/gui/src/shared/notifications/update-available.ts @@ -17,7 +17,8 @@ interface UpdateAvailableNotificationContext { } export class UpdateAvailableNotificationProvider - implements InAppNotificationProvider, SystemNotificationProvider { + implements InAppNotificationProvider, SystemNotificationProvider +{ public constructor(private context: UpdateAvailableNotificationContext) {} public mayDisplay() { |
