diff options
| author | Ruben Beltran del Rio <ruben@unlimited.pizza> | 2021-04-19 21:04:59 +0200 |
|---|---|---|
| committer | Ruben Beltran del Rio <ruben@unlimited.pizza> | 2021-04-19 21:04:59 +0200 |
| commit | 879fa389c2592760def75177eefbd3193e1845c9 (patch) | |
| tree | 8648bb1790cea8b482b18ef10b4b5cab508b0ba3 /src/components/post_content | |
| parent | 77182aa8d0fa96b594d1c2582a168e2ebe15964d (diff) | |
Add tests for first batch of components
- Glyph
- Forum List
- Error Block
- Post
Diffstat (limited to 'src/components/post_content')
| -rw-r--r-- | src/components/post_content/post_content.svelte | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/src/components/post_content/post_content.svelte b/src/components/post_content/post_content.svelte deleted file mode 100644 index 5d8ef1c..0000000 --- a/src/components/post_content/post_content.svelte +++ /dev/null @@ -1,50 +0,0 @@ -<script> - export let post; - export let index = 0; - export let count = 1; - - import { _ } from 'svelte-i18n'; - import Glyph from '$/components/glyph/glyph.svelte'; - - const timestampToISO = (timestamp) => new Date(timestamp).toISOString(); -</script> - -<aside - class="post-meta" - title={$_('post.metadata_title', { values: { count: index + 1, total: count } })} -> - <Glyph uuid={post.author.id} /> - <span class="h-card"> - {$_('post.author_credit')} - <a href="/a/{post.author.handle}" class="p-nickname u-url">{post.author.handle}</a>. - </span> - <time role="presentation" class="dt-published" datetime={timestampToISO(post.created_at)}> - <a title={$_('post.permalink_title')} href="/p/{post.id}"> - {timestampToISO(post.created_at)} - </a> - </time> - {#if post.topic} - <span class="h-card"> - ({$_('post.topic_location')} <a href="/t/{post.topic.id}">{post.topic.title}</a>.) - </span> - {/if} -</aside> -<article - class="e-content" - title={$_('post.title', { - values: { count: index + 1, total: count, author: post.author.handle } - })} -> - {post.text} -</article> -<hr /> - -<style> - .post-meta * { - vertical-align: top; - } - - article { - white-space: pre; - } -</style> |