implement board sorting

This commit is contained in:
marlon-erler
2024-07-23 14:27:38 +02:00
parent 20488f8a26
commit 4d55a4974a
6 changed files with 66 additions and 11 deletions
+8
View File
@@ -17,6 +17,8 @@ export default class BoardViewModel {
isSelected: React.State<boolean>;
isPresentingSettingsModal: React.State<boolean> = new React.State(false);
index: React.State<number> = new React.State(0);
// view
select = (): void => {
this.taskPageViewModel.selectBoard(this);
@@ -35,6 +37,12 @@ export default class BoardViewModel {
this.isPresentingSettingsModal.value = false;
};
updateIndex = (): void => {
const index: number =
this.taskPageViewModel.boardIndexManager.getIndex(this);
this.index.value = index;
};
// methods
saveSettings = (): void => {
const newBoardInfoFileContent: BoardInfoFileContent =