design: make bolder and distinguish thread lines in comment trees
This commit is contained in:
2 files changed
+10
-10
No files matched your search
@@ -116,8 +116,7 @@
|
||||
{#if meta}
|
||||
<button
|
||||
onclick={() => (open = !open)}
|
||||
class="flex flex-row cursor-pointer gap-2 items-center group text-[13px] flex-wrap w-full
|
||||
z-0 group relative"
|
||||
class="flex flex-row cursor-pointer gap-2 items-center group text-[13px] flex-wrap w-full z-0 group"
|
||||
>
|
||||
{@render metaSuffix?.()}
|
||||
<span class:font-bold={op} class="flex flex-row gap-1 items-center">
|
||||
|
||||
@@ -96,8 +96,11 @@
|
||||
contentClass={[
|
||||
(node.children.length > 0 ||
|
||||
node.comment_view.counts.child_count > 0) &&
|
||||
'border-l',
|
||||
'ml-2.5 border-slate-200 dark:border-zinc-800 pl-3 sm:pl-4 lg:pl-5',
|
||||
'border-l-2',
|
||||
'ml-2.5 pl-3 sm:pl-4 lg:pl-5',
|
||||
node.depth % 2 == 0
|
||||
? 'border-slate-200 dark:border-zinc-800'
|
||||
: 'border-slate-300/80 dark:border-zinc-700',
|
||||
]}
|
||||
bind:open={nodes[index].expanded}
|
||||
>
|
||||
@@ -108,22 +111,20 @@
|
||||
{#if node.comment_view.counts.child_count > 0 && node.children.length == 0}
|
||||
<svelte:element
|
||||
this={browser ? 'div' : 'a'}
|
||||
class="w-full h-10 border-y-0! -mt-2 -ml-2.5"
|
||||
href="/comment/{page.params.instance}/{node.comment_view.comment.id}"
|
||||
class="w-full h-10 -mt-2 -ml-2.5"
|
||||
href="/comment/{node.comment_view.comment.id}"
|
||||
>
|
||||
<Button
|
||||
loading={nodes[index].loading}
|
||||
disabled={nodes[index].loading}
|
||||
rounding="pill"
|
||||
color="tertiary"
|
||||
class="font-normal text-sm! text-slate-600 dark:text-zinc-400"
|
||||
class="font-normal text-slate-600 dark:text-zinc-400"
|
||||
shadow="none"
|
||||
loaderWidth={16}
|
||||
onclick={() => {
|
||||
if (nodes[index].depth > 4) {
|
||||
goto(
|
||||
`/comment/${page.params.instance}/${nodes[index].comment_view.comment.id}#comments`,
|
||||
)
|
||||
goto(`/comment/${nodes[index].comment_view.comment.id}#comments`)
|
||||
} else {
|
||||
nodes[index].loading = true
|
||||
fetchChildren(nodes[index]).then(
|
||||
|
||||
Reference in new issue
Block a user