chadtmiller.com/hud
A remote MCP server that shows atproto records as interactive UI inside MCP Apps hosts
place.hud.hudkit 0.3.1 Latest 5 packages
0
0
<script lang="ts">
import type { Snippet } from 'svelte';
// One field of a record or group: its name, a small tag with its type, and
// its value (`children`). `title`, the lexicon's description where the
// server sends it, shows only as the name's tooltip, as
// plain text.
let { name, tag, title, children }: { name: string; tag: string; title?: string; children: Snippet } = $props();
</script>
<div class="field">
<dt>
<span class="name" {title}>{name}</span>
<span class="tag">{tag}</span>
</dt>
<dd>{@render children()}</dd>
</div>
<style>
.field {
display: grid;
grid-template-columns: minmax(0, 1fr);
gap: 0.125rem var(--hud-space-3);
padding: var(--hud-space-2) 0;
border-top: var(--border-width-regular) solid var(--color-border-secondary);
}
.field:first-child {
border-top: 0;
}
@container (min-width: 32rem) {
.field {
grid-template-columns: 9rem minmax(0, 1fr);
}
}
dt {
display: flex;
flex-wrap: wrap;
align-items: baseline;
gap: 0 var(--hud-space-2);
min-width: 0;
}
.name {
color: var(--color-text-secondary);
font-size: var(--font-text-sm-size);
font-weight: var(--font-weight-medium);
overflow-wrap: anywhere;
}
.tag {
color: var(--color-text-tertiary);
font-family: var(--font-mono);
font-size: 0.6875rem;
}
dd {
margin: 0;
min-width: 0;
font-size: var(--font-text-sm-size);
line-height: var(--font-text-sm-line-height);
}
</style>