fix: update svelte -> 5.43.8
This commit is contained in:
5 files changed
+11
-19
No files matched your search
@@ -53,18 +53,10 @@
|
||||
canVote = false
|
||||
|
||||
if (typeof id !== 'number') {
|
||||
await Promise.all([
|
||||
id.map((i) =>
|
||||
api
|
||||
.voteOnPoll({
|
||||
post_id: post.id,
|
||||
choice_id: i,
|
||||
})
|
||||
.catch((err) => {
|
||||
throw err
|
||||
}),
|
||||
),
|
||||
])
|
||||
await api.voteOnPoll({
|
||||
post_id: post.id,
|
||||
choice_id: id,
|
||||
})
|
||||
} else {
|
||||
await api.voteOnPoll({
|
||||
post_id: post.id,
|
||||
@@ -89,7 +81,7 @@
|
||||
{#each options.toSorted((a, b) => a.sort_order - b.sort_order) as choice}
|
||||
{@const active =
|
||||
selected == choice.id ||
|
||||
(typeof selected !== 'number' && selected?.includes(choice.id))}
|
||||
(typeof selected !== 'number' && selected?.includes?.(choice.id))}
|
||||
{@const percentage = Math.floor(
|
||||
(choice.num_votes / totalVotes || 0) * 100,
|
||||
)}
|
||||
@@ -114,7 +106,7 @@
|
||||
></div>
|
||||
{/if}
|
||||
<label
|
||||
class="px-4 py-2 w-full text-left flex flex-row gap-2 items-center"
|
||||
class="px-4 py-2 w-full text-left flex flex-row gap-2 items-center relative"
|
||||
>
|
||||
{#if !multi}
|
||||
<input
|
||||
|
||||
Reference in new issue
Block a user