This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

core / web / src / lib / components / repo / Readme.svelte
899 B 28 lines
1<script lang="ts"> 2 import FileText from "$icon/file-text"; 3 4 interface Props { 5 filename: string; 6 contents: string; 7 html?: string | null; 8 } 9 10 let { filename, contents, html = null }: Props = $props(); 11</script> 12 13<div class="mt-4 w-full overflow-hidden rounded bg-background-default shadow-sm"> 14 <div class="border-b border-border-default px-4 py-2"> 15 <span class="flex items-center gap-2"> 16 <FileText class="size-4 text-foreground-subtle" aria-hidden="true" /> 17 <span class="font-mono text-sm text-foreground-muted">{filename}</span> 18 </span> 19 </div> 20 {#if html} 21 <!-- eslint-disable-next-line svelte/no-at-html-tags -- sanitised in $lib/markup --> 22 <div class="markup overflow-x-auto px-6 py-4">{@html html}</div> 23 {:else} 24 <div class="overflow-x-auto px-6 py-4"> 25 <pre class="font-mono text-sm whitespace-pre-wrap text-foreground-default">{contents}</pre> 26 </div> 27 {/if} 28</div>