diff options
| author | Somhairle H. Marisol <[email protected]> | 2026-09-18 18:11:53 +0800 |
|---|---|---|
| committer | Somhairle H. Marisol <[email protected]> | 2026-09-18 18:11:53 +0800 |
| commit | c52a727d11b87d70ec00a7e2569841e6e6abcd9c (patch) | |
| tree | c7bc7217cb0ef02613b34e5a1f228ac3a68431a9 /frontend/src/pages/RunsPage.svelte | |
| parent | 63098a260dadf9e5d01650afb02570343abe20d9 (diff) | |
| download | strategy-lab-c52a727d11b87d70ec00a7e2569841e6e6abcd9c.tar.gz | |
[变更性质] 用户旅程重排:项目首页指标摘要+项目卡、结果页首屏 capital 三卡+交易分页、数据/策略/回测 CTA 与三态统一,token 白名单清扫(docs/ui-user-journey-round6.md §1/§2)
Diffstat (limited to 'frontend/src/pages/RunsPage.svelte')
| -rw-r--r-- | frontend/src/pages/RunsPage.svelte | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/frontend/src/pages/RunsPage.svelte b/frontend/src/pages/RunsPage.svelte index 77626b5..ce66a25 100644 --- a/frontend/src/pages/RunsPage.svelte +++ b/frontend/src/pages/RunsPage.svelte @@ -103,10 +103,16 @@ </script> <Page title="实验记录" subtitle="查看与选择比较不同回测;结果仅展示真实完成任务的数据" wide> - <div class="flex flex-col gap-3"> - <Status busy={busy} error={error} busyText="正在加载实验…" empty={null} /> - - {#if !busy && !error && runs.length === 0} + <div class="flex flex-col gap-4 md:gap-6"> + {#if busy} + <Status busy skeletonRows={4} busyText="正在加载实验…" empty={null} /> + {:else if error} + <Status busy={false} {error} empty={null}> + {#snippet errorCta()} + <Button onclick={load}>重新加载</Button> + {/snippet} + </Status> + {:else if runs.length === 0} <Status busy={false} empty="还没有实验记录" emptyHint="进入项目「回测」标签发起一次回测后记录会出现在这里" /> {/if} @@ -152,12 +158,12 @@ {/each} </Table.Body> </Table.Root> - <p class="text-sm text-muted-foreground p-2">最多同时选中 4 个已完成的回测用于比较。</p> + <p class="text-xs text-muted-foreground p-4">最多同时选中 4 个已完成的回测用于比较。</p> </Card.Root> {#if selected.length > 0} - <Card.Root size="sm" class="p-4 flex flex-col gap-3 overflow-x-auto"> - <h2 class="text-lg font-semibold">条件差异</h2> + <Card.Root size="sm" class="p-4 flex flex-col gap-4 overflow-x-auto"> + <h2 class="text-lg font-semibold m-0">条件差异</h2> <Table.Root> <Table.Header> <Table.Row> @@ -179,10 +185,10 @@ </Card.Root> {#if comparable.length > 1} - <Card.Root size="sm" class="p-4 flex flex-col gap-3"> - <h2 class="text-lg font-semibold">收益曲线对齐比较(首日归一)</h2> + <Card.Root size="sm" class="p-4 flex flex-col gap-4"> + <h2 class="text-lg font-semibold m-0">收益曲线对齐比较(首日归一)</h2> <Chart data={compare.data} series={compare.series} ariaLabel="多回测对比曲线" height={340} /> - <p class="text-sm text-muted-foreground">起点对齐为 1,仅叠加不同起点的曲线时只在各自区间内展示。</p> + <p class="text-xs text-muted-foreground">起点对齐为 1,仅叠加不同起点的曲线时只在各自区间内展示。</p> </Card.Root> {:else} <Status busy={false} empty="请再选中至少一个已完成的回测以展示比较" /> |
