Remove ViewState
The only remaining usage of view state was to reset the number of files
shown everytime the patchrange/change changes but we can do that when
we collapse all file diffs in the change page.
With this change we got rid of all viewState. :D
Release-Notes: skip
Change-Id: I6e2f91dbaf5fffa497292baf7576e4c92217784a
diff --git a/polygerrit-ui/app/types/types.ts b/polygerrit-ui/app/types/types.ts
index 3763733..c7a5d14 100644
--- a/polygerrit-ui/app/types/types.ts
+++ b/polygerrit-ui/app/types/types.ts
@@ -4,7 +4,7 @@
* SPDX-License-Identifier: Apache-2.0
*/
import {DiffLayer as DiffLayerApi} from '../api/diff';
-import {DiffViewMode, MessageTag, Side} from '../constants/constants';
+import {MessageTag, Side} from '../constants/constants';
import {IronA11yAnnouncer} from '@polymer/iron-a11y-announcer/iron-a11y-announcer';
import {FlattenedNodesObserver} from '@polymer/polymer/lib/utils/flattened-nodes-observer';
import {PaperInputElement} from '@polymer/paper-input/paper-input';
@@ -15,8 +15,6 @@
CommitId,
CommitInfo,
EditPatchSet,
- NumericChangeId,
- PatchRange,
PatchSetNum,
ReviewerUpdateInfo,
RevisionInfo,
@@ -172,15 +170,6 @@
removeListener?(listener: DiffLayerListener): void;
}
-export interface ChangeViewState {
- changeNum: NumericChangeId | null;
- patchRange: PatchRange | null;
- diffMode: DiffViewMode | null;
-}
-export interface ViewState {
- changeView: ChangeViewState;
-}
-
export interface PatchSetFile {
path: string;
basePath?: string;