diff options
| author | Oskar Nyberg <oskar@mullvad.net> | 2021-11-03 02:02:09 +0100 |
|---|---|---|
| committer | Oskar Nyberg <oskar@mullvad.net> | 2022-03-14 13:58:44 +0100 |
| commit | 46fa74ad03658ad0afa9dc984565b7f10106af94 (patch) | |
| tree | e271c92db8c2f06db457548f3ebb95ef97a4ab09 /gui/src/shared | |
| parent | 7c23c00a45d4a9342c69211d23ef8f8fd634725a (diff) | |
| download | mullvadvpn-46fa74ad03658ad0afa9dc984565b7f10106af94.tar.xz mullvadvpn-46fa74ad03658ad0afa9dc984565b7f10106af94.zip | |
Replace account token in settings event with device event
Diffstat (limited to 'gui/src/shared')
| -rw-r--r-- | gui/src/shared/daemon-rpc-types.ts | 14 | ||||
| -rw-r--r-- | gui/src/shared/ipc-schema.ts | 3 |
2 files changed, 15 insertions, 2 deletions
diff --git a/gui/src/shared/daemon-rpc-types.ts b/gui/src/shared/daemon-rpc-types.ts index a45bdada4d..3b0f7774d3 100644 --- a/gui/src/shared/daemon-rpc-types.ts +++ b/gui/src/shared/daemon-rpc-types.ts @@ -104,7 +104,8 @@ export type DaemonEvent = | { tunnelState: TunnelState } | { settings: ISettings } | { relayList: IRelayList } - | { appVersionInfo: IAppVersionInfo }; + | { appVersionInfo: IAppVersionInfo } + | { deviceConfig: IDeviceConfig }; export interface ITunnelStateRelayInfo { endpoint: ITunnelEndpoint; @@ -320,8 +321,17 @@ export interface IAppVersionInfo { suggestedIsBeta?: boolean; } -export interface ISettings { +export interface IDeviceConfig { accountToken?: AccountToken; + device?: IDevice; +} + +export interface IDevice { + id: string; + name: string; +} + +export interface ISettings { allowLan: boolean; autoConnect: boolean; blockWhenDisconnected: boolean; diff --git a/gui/src/shared/ipc-schema.ts b/gui/src/shared/ipc-schema.ts index a6d41298ce..6b3082cdd7 100644 --- a/gui/src/shared/ipc-schema.ts +++ b/gui/src/shared/ipc-schema.ts @@ -6,6 +6,7 @@ import { BridgeState, IAccountData, IAppVersionInfo, + IDeviceConfig, IDnsOptions, ILocation, IRelayList, @@ -50,6 +51,7 @@ export interface IAppStateSnapshot { accountHistory?: AccountToken; tunnelState: TunnelState; settings: ISettings; + deviceConfig: IDeviceConfig; relayListPair: IRelayListPair; currentVersion: ICurrentAppVersionInfo; upgradeVersion: IAppVersionInfo; @@ -163,6 +165,7 @@ export const ipcSchema = { }, account: { '': notifyRenderer<IAccountData | undefined>(), + device: notifyRenderer<IDeviceConfig>(), create: invoke<void, string>(), login: invoke<AccountToken, void>(), logout: invoke<void, void>(), |
