fix: comments not appearing immediately

This commit is contained in:
Xylight committed 2025-09-21 10:18:27 -07:00
1 parent 1a12533fa8
commit 9a27e95a5f
6 files changed
+157 -252

No files matched your search

+2
View File
@@ -18,6 +18,8 @@
$effect(() => {
if (data.filters.value.sort)
settings.defaultSort.sort = data.filters.value.sort
if (data.filters.value.type_)
settings.defaultSort.feed = data.filters.value.type_
})
const FeedComponent = $derived(
@@ -116,7 +116,12 @@
<CommentForm
postId={post.post.id}
oncomment={(comment) => {
comments.unshift(comment.comment_view)
tree.unshift({
children: [],
depth: 1,
expanded: true,
comment_view: comment.comment_view,
})
}}
onfocus={() => (commenting = true)}
tools={commenting}