Dodano changelog; poprawki reaktywności

This commit is contained in:
2022-08-20 18:07:21 +02:00
parent 6c4c33cb65
commit 9b252cf205
10 changed files with 218 additions and 84 deletions
+48 -3
View File
@@ -1,4 +1,41 @@
export type Availability = 'default' | 'unavailable' | 'nonPublic' | 'abandoned' | 'nonDefault';
export type ChangeProp =
| 'name'
| 'url'
| 'lines'
| 'project'
| 'reqLevel'
| 'signalType'
| 'controlType'
| 'SUP'
| 'routes'
| 'checkpoints'
| 'authors'
| 'availability';
export enum HeaderTypes {
name = 'Nazwa',
url = 'URL',
lines = 'Linie',
project = 'Projekt',
reqLevel = 'Wym. poziom',
signalType = 'Sygnalizacja',
controlType = 'Sterowanie',
SUP = 'SUP',
authors = 'Autorzy',
routes = 'Szlaki',
checkpoints = 'Posterunki',
availability = 'Dostępność',
toRemove = 'Usuń',
}
export enum AvailabilityTypes {
'default' = 'w paczce',
'nonDefault' = 'poza paczką',
'nonPublic' = 'niepubliczna',
'abandoned' = 'wycofana',
'unavailable' = 'niedostępna',
}
export interface SceneryRowItem {
id: string;
@@ -16,15 +53,23 @@ export interface SceneryRowItem {
availability: Availability;
}
export type ChangeItem = {
[key in ChangeProp]?: string | number | boolean | null;
} & {
id: string;
name: string;
toRemove?: boolean;
};
export interface IStore {
dataState: string;
unsavedChanges: boolean;
stationList: SceneryRowItem[];
backupList: string;
backupList: SceneryRowItem[];
stationsToRemove: string[];
searchedSceneryName: string;
changeList: { [key: string]: any };
changeBackupList: { [key: string]: any };
changeList: ChangeItem[];
newStationsCount: number;
routesModalVisible: boolean;
currentStation: SceneryRowItem | null;