feat(filelib): 移除最近打开模块(ADR-0032,supersede ADR-0031 对应半部)

- FileLibRecentVisit 删表(手写迁移;表当日新建无生产数据)
- recentService/recentRoutes/RecentView 删除;GridLibraryView 埋点与
  navTarget 跳转一并移除;types 清 RecentEntry
- 左栏保留 文件库/回收站(ADR-0031 回收站半部不受影响)
- breadcrumb 的 role 字段保留(独立可用的增量字段)
This commit is contained in:
ymy
2026-07-31 13:39:18 +08:00
parent 475b397ca8
commit 83a6b012b7
11 changed files with 38 additions and 366 deletions
+4 -14
View File
@@ -4,25 +4,17 @@
import { me, authChecked } from "$lib/stores.js";
import { loadSession } from "$lib/session.js";
import LoginView from "$lib/LoginView.svelte";
import GridLibraryView, { type NavTarget } from "$lib/GridLibraryView.svelte";
import RecentView from "$lib/RecentView.svelte";
import GridLibraryView from "$lib/GridLibraryView.svelte";
import BinView from "$lib/BinView.svelte";
import Icon from "$lib/Icon.svelte";
onMount(loadSession);
type View = "library" | "recent" | "bin";
type View = "library" | "bin";
let view = $state<View>("library");
let navTarget = $state<NavTarget | null>(null);
function openFromRecent(target: NavTarget): void {
navTarget = target;
view = "library";
}
const tabs: ReadonlyArray<readonly [View, string, "layers" | "clock" | "trash"]> = [
const tabs: ReadonlyArray<readonly [View, string, "layers" | "trash"]> = [
["library", "文件库", "layers"],
["recent", "最近打开", "clock"],
["bin", "回收站", "trash"],
];
</script>
@@ -49,9 +41,7 @@
</nav>
{#if view === "library"}
<GridLibraryView {navTarget} onnavigated={() => (navTarget = null)} />
{:else if view === "recent"}
<RecentView onopen={openFromRecent} />
<GridLibraryView />
{:else}
<BinView />
{/if}