diff options
| author | Oskar Nyberg <oskar@mullvad.net> | 2022-11-04 10:54:07 +0100 |
|---|---|---|
| committer | Oskar Nyberg <oskar@mullvad.net> | 2022-11-07 10:46:07 +0100 |
| commit | 40bc4e6bbd51fd78ff67e376a5fbe921cd4c4964 (patch) | |
| tree | cc3833ddeefa03f5979883bb77464098fa9b32aa /gui/src/shared | |
| parent | f5037f6fbc93148569210f18dfa24be4be1e0a6a (diff) | |
| download | mullvadvpn-40bc4e6bbd51fd78ff67e376a5fbe921cd4c4964.tar.xz mullvadvpn-40bc4e6bbd51fd78ff67e376a5fbe921cd4c4964.zip | |
Add view state to history location state
Diffstat (limited to 'gui/src/shared')
| -rw-r--r-- | gui/src/shared/ipc-schema.ts | 3 | ||||
| -rw-r--r-- | gui/src/shared/ipc-types.ts | 7 |
2 files changed, 6 insertions, 4 deletions
diff --git a/gui/src/shared/ipc-schema.ts b/gui/src/shared/ipc-schema.ts index 85c7f2cabc..210e85e007 100644 --- a/gui/src/shared/ipc-schema.ts +++ b/gui/src/shared/ipc-schema.ts @@ -34,7 +34,6 @@ import { ICurrentAppVersionInfo, IHistoryObject, IWindowShapeParameters, - ScrollPositions, } from './ipc-types'; export interface ITranslations { @@ -76,7 +75,6 @@ export interface IAppStateSnapshot { changelog: IChangelog; forceShowChanges: boolean; navigationHistory?: IHistoryObject; - scrollPositions: ScrollPositions; } // The different types of requests are: @@ -130,7 +128,6 @@ export const ipcSchema = { navigation: { reset: notifyRenderer<void>(), setHistory: send<IHistoryObject>(), - setScrollPositions: send<ScrollPositions>(), }, daemon: { isPerformingPostUpgrade: notifyRenderer<boolean>(), diff --git a/gui/src/shared/ipc-types.ts b/gui/src/shared/ipc-types.ts index 2b42f42b0e..4d2a35357f 100644 --- a/gui/src/shared/ipc-types.ts +++ b/gui/src/shared/ipc-types.ts @@ -13,8 +13,13 @@ export interface IWindowShapeParameters { export type IChangelog = Array<string>; +export interface LocationState { + scrollPosition: [number, number]; + expandedSections: number[]; +} + export interface IHistoryObject { - entries: Location<unknown>[]; + entries: Location<LocationState>[]; index: number; lastAction: Action; } |
