diff options
author | kartofen <mladenovnasko0@gmail.com> | 2022-08-28 23:22:15 +0300 |
---|---|---|
committer | kartofen <mladenovnasko0@gmail.com> | 2022-08-28 23:22:15 +0300 |
commit | 9d952483f250a97cbeab4061fa1c4e68341b330f (patch) | |
tree | 9d094911dc5178db9375eaa661e7f4bf0d5bf2cc /src/components/Comment.svelte | |
parent | 35b06b4fc851192916e000ad5e7e2f458846448c (diff) |
posting thread and image works
Diffstat (limited to 'src/components/Comment.svelte')
-rw-r--r-- | src/components/Comment.svelte | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/src/components/Comment.svelte b/src/components/Comment.svelte deleted file mode 100644 index bc53f4d..0000000 --- a/src/components/Comment.svelte +++ /dev/null @@ -1,45 +0,0 @@ -<script lang="ts"> - import { creatorColor, formatTime } from '../lib/util'; - import type Comment from '../models/Thread'; - export let comment: Comment; -</script> - - -<div class="commentbox" id="{comment.id}"> - - <span style="line-height: 2rem;"> - <span style="font-family: mono">{comment.id}</span> - at {formatTime(comment.creationDate)} <br> - -> <span style="{creatorColor(comment.commentCreator)}; font-family: mono"> - {comment.commentCreator} - </span> <br> - </span> - - {#if comment.imageId!= null && comment.imageId != undefined} - {#if comment.fileType == 'image'} - <a href="{comment.imageId}" target="_blank" rel="noopener noreferrer"> - <img src="{comment.imageId}" alt="{comment.imageId}" height="300px" width="300px"> <br> - </a> - {:else if comment.fileType == 'video'} - <video width="320" height="240" controls muted> - <source src="{comment.imageId}"> - </video> - {/if} - {/if} - -<p>{@html comment.commentText}</p> - -</div> - -<style> - .commentbox { - width: 500px; - border: 5px solid green; - padding: 10px; - margin: 10px; - background-color: white; - } - :target, .targeted { - background-color: #ffa; - } -</style> |