~ knotless Search/
↑↓ move↵ open⇧↵ all results

chadtmiller.com/hud

A remote MCP server that shows atproto records as interactive UI inside MCP Apps hosts

0
0
17 lines · 607 B Raw History
<script lang="ts">
	import AppIcon from '../atoms/AppIcon.svelte';
	import Avatar from '../atoms/Avatar.svelte';
	import type { Tile } from '../model';
	import { actorOf, iconOf } from '../tiles';

	/** What a tile is, at 16px, beside its title: the account's face for a profile, else its app's icon, else its kind's. */
	let { tile }: { tile: Pick<Tile, 'tool' | 'arguments' | 'icon'> } = $props();

	const actor = $derived(actorOf(tile.tool, tile.arguments));
</script>

{#if actor}
	<Avatar did={actor} size="sm" />
{:else}
	<AppIcon src={tile.icon} fallback={iconOf(tile.tool, tile.arguments)} />
{/if}