From e9c851789935f067c77ae9774ad57feae839cfe8 Mon Sep 17 00:00:00 2001 From: vato007 Date: Sat, 5 Jul 2025 09:17:48 +0930 Subject: [PATCH] Clear table state upon changing tabs --- src/app/file-viewer/file-viewer.component.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/file-viewer/file-viewer.component.ts b/src/app/file-viewer/file-viewer.component.ts index bd6ffd1..46c679e 100644 --- a/src/app/file-viewer/file-viewer.component.ts +++ b/src/app/file-viewer/file-viewer.component.ts @@ -303,9 +303,10 @@ export class FileViewerComponent { }); this.currentValue.set(newValue); } - // TODO: Replace this with previous state once persistence is implemented + // TODO: Replace this with previous state once persistence is implemented (should be per tab at the very least) const table = this.table(); if (table) { + this.clear(table); table.multiSortMeta = [{ field: this.columns()[0].name, order: 1 }]; table.sortMultiple(); }