Files
archie/ui/src/tasks/ChangeCapture.vue
T
sam 94f79177a2
deploy / gate (push) Successful in 4m53s
Quality / check (push) Successful in 6m42s
deploy / archied-image (push) Successful in 3m20s
deploy / agent-image (push) Successful in 11s
deploy / dist-zip (push) Skipped
fix(ui): adopt the type scale across components/ui and pages (#1758)
components/ui and the pages now use only the style.css scale:
text-[0.8rem]→text-label, text-[0.625rem]→text-micro, text-base/text-sm→
text-label (rows and controls), text-xs→text-caption (captions and
secondary text), text-lg/text-xl/text-2xl→text-title (panel and page
titles). Rendered markdown (ChatMarkdown/ChatInline/markdown.ts) keeps
Tailwind steps as the issue allows. 196 files, class-token swaps only.
2026-11-06 23:07:46 +11:00

72 lines
2.3 KiB
Vue

<script setup lang="ts">
import { computed } from "vue";
import { Timestamp } from "@/components/ui/timestamp";
import ChangeFileTable from "./ChangeFileTable.vue";
import { captureLinks, totalsLabel } from "./changed-files";
import type { Capture, TaskRecord } from "./task-run";
/**
* One change capture: when and where it was taken, the forge coordinates it
* carries, and the files it recorded.
*/
const props = defineProps<{ capture: Capture; task: TaskRecord | null }>();
const links = computed(() => captureLinks(props.capture, props.task));
const prNumber = computed(() => props.capture.pr_number);
</script>
<template>
<section>
<div class="flex flex-wrap items-baseline justify-between gap-3">
<span class="text-label font-medium">
{{
capture.captured_after
? `Captured after ${capture.captured_after}`
: "Captured"
}}<span v-if="capture.stage"> in stage {{ capture.stage }}</span>
</span>
<span v-if="capture.captured_at" class="text-caption text-fg-muted"><Timestamp :at="capture.captured_at" /></span>
</div>
<div
class="mt-2 mb-3 flex flex-wrap items-center gap-3 text-caption text-fg-muted"
>
<span class="font-mono">
<a
v-if="links.repo"
class="text-link hover:underline"
:href="links.repo"
target="_blank"
rel="noreferrer"
>
{{ capture.owner }}/{{ capture.repo }}
</a>
<template v-else
>{{ capture.owner || "" }}/{{ capture.repo || "" }}</template
>
</span>
<span v-if="capture.branch" class="font-mono">
{{ capture.branch
}}<span v-if="capture.base"> → {{ capture.base }}</span>
</span>
<span v-if="capture.head_sha" class="font-mono">{{
String(capture.head_sha).slice(0, 8)
}}</span>
<template v-if="prNumber">
<a
v-if="links.pr"
class="text-link hover:underline"
:href="links.pr"
target="_blank"
rel="noreferrer"
>PR #{{ prNumber }}
</a>
<span v-else class="font-mono">PR #{{ prNumber }}</span>
</template>
<span>{{ totalsLabel(capture.totals) }}</span>
</div>
<ChangeFileTable :capture="capture" />
</section>
</template>