The stored `colors` key names a palette — rhema (the default, Jadeite), aquamarine, black-and-white, or dracula — and the Appearance page of /settings cycles it live, like the theme and icon toggles beside it. Each palette carries a dark and a light appearance under the existing `theme` key; dracula's light side is derived, the official palette ships only dark. The appearance decision moves off token comparison: Theme now answers is_dark() from the ground/text luminance, so palettes beyond the original two get the right per-profile fallback tones.
44 lines
1.3 KiB
Vue
44 lines
1.3 KiB
Vue
<script setup lang="ts">
|
|
// A turn's stream-ordered middle: tool rows, the agent's asks, its
|
|
// handovers — each at the position the stream delivered it, so an ask
|
|
// sits at the tool call that raised it rather than at the turn's top.
|
|
import type { TurnEntry } from '~/composables/useTranscript'
|
|
import type { ConsentAnswer } from '~/composables/useClaw'
|
|
|
|
defineProps<{ entries: TurnEntry[] }>()
|
|
|
|
const emit = defineEmits<{
|
|
consentAnswer: [id: string, answer: ConsentAnswer]
|
|
consentDeny: [id: string]
|
|
downloadAttachment: [id: string, name: string]
|
|
}>()
|
|
</script>
|
|
|
|
<template>
|
|
<div v-if="entries.length > 0" class="entries">
|
|
<template v-for="(entry, index) in entries" :key="index">
|
|
<TurnToolRow v-if="entry.kind === 'tool'" :row="entry.row" />
|
|
<TurnConsentCard
|
|
v-else-if="entry.kind === 'consent'"
|
|
:consent="entry.consent"
|
|
@answer="(id, answer) => emit('consentAnswer', id, answer)"
|
|
@deny="(id) => emit('consentDeny', id)"
|
|
/>
|
|
<TurnAttachmentCard
|
|
v-else
|
|
:attachment="entry.attachment"
|
|
@download="(id, name) => emit('downloadAttachment', id, name)"
|
|
/>
|
|
</template>
|
|
</div>
|
|
</template>
|
|
|
|
<style scoped>
|
|
.entries {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 4px;
|
|
margin-bottom: 10px;
|
|
}
|
|
</style>
|