fix(ui): show a parked task's error once and wrap long log lines on a phone
This commit is contained in:
1 parent
8d0d707d3e
commit
30105666e2
5 files changed
+9
-9
No files matched your search
@@ -20,7 +20,7 @@ const fields = () => Object.entries(props.entry.fields ?? {});
|
||||
|
||||
<template>
|
||||
<div
|
||||
class="grid grid-cols-[62px_52px_1fr] items-baseline gap-3 border-b border-b-border border-l-2 px-1 py-2 hover:bg-accent"
|
||||
class="grid grid-cols-[62px_52px_1fr] items-baseline gap-x-3 gap-y-1 max-sm:grid-cols-[62px_1fr] border-b border-b-border border-l-2 px-1 py-2 hover:bg-accent"
|
||||
:class="rowClass(props.entry.level)"
|
||||
>
|
||||
<span class="font-mono text-fg-subtle">{{
|
||||
@@ -32,8 +32,8 @@ const fields = () => Object.entries(props.entry.fields ?? {});
|
||||
>
|
||||
{{ (props.entry.level || "info").toUpperCase() }}
|
||||
</span>
|
||||
<span class="flex min-w-0 flex-wrap items-baseline gap-2">
|
||||
<span class="break-words font-mono text-foreground">{{
|
||||
<span class="flex min-w-0 flex-wrap items-baseline gap-2 max-sm:col-span-2">
|
||||
<span class="min-w-0 font-mono text-foreground [overflow-wrap:anywhere]">{{
|
||||
props.entry.message || props.entry.msg || ""
|
||||
}}</span>
|
||||
<span
|
||||
|
||||
@@ -127,7 +127,7 @@ const startedAt = computed(() => {
|
||||
timeLimit
|
||||
}}</span>
|
||||
</div>
|
||||
<p v-if="attempt.error" role="alert" class="mb-3 whitespace-pre-wrap break-words text-sm text-danger">{{ attempt.error }}</p>
|
||||
<p v-if="attempt.error && attempt.error !== run.task?.park_reason" role="alert" class="mb-3 whitespace-pre-wrap break-words text-sm text-danger">{{ attempt.error }}</p>
|
||||
<ol
|
||||
v-if="stages.length"
|
||||
:aria-label="`Stages recorded in attempt ${attempt.attempt}`"
|
||||
@@ -142,7 +142,7 @@ const startedAt = computed(() => {
|
||||
@select="selectStage(stage)"
|
||||
/>
|
||||
</ol>
|
||||
<Empty v-else>
|
||||
<Empty v-else-if="!attempt.error">
|
||||
<EmptyHeader>
|
||||
<EmptyTitle>No workflow steps recorded</EmptyTitle>
|
||||
</EmptyHeader>
|
||||
|
||||
@@ -174,7 +174,7 @@ const headerActions = computed(() =>
|
||||
<Button variant="ghost" size="sm" :disabled="jumping || run.attemptNumber == null" @click="jumpToLog">Jump to log line</Button>
|
||||
</AlertTitle>
|
||||
<AlertDescription>
|
||||
<p v-if="failure.detail" class="mt-0.5 font-mono text-xs break-words text-fg-muted">{{ failure.detail }}</p>
|
||||
<p v-if="failure.detail" class="mt-0.5 font-mono text-xs text-fg-muted [overflow-wrap:anywhere]">{{ failure.detail }}</p>
|
||||
<p v-if="jumpError" class="mt-1 text-xs" role="alert">{{ jumpError }}</p>
|
||||
<Button v-if="failure.parked && run.attempts?.recovery" as-child size="sm" class="mt-2">
|
||||
<RouterLink :to="run.attempts.recovery.link">{{ run.attempts.recovery.label }}</RouterLink>
|
||||
|
||||
Reference in new issue
Block a user