fix: messed up redirects for http urls

This commit is contained in:
Xylight committed 2025-09-28 14:33:24 -07:00
1 parent a42644a042
commit fdcef736cf
7 files changed
+31 -27

No files matched your search

+4 -5
View File
@@ -6,7 +6,7 @@
import { t } from '$lib/app/i18n'
import { settings } from '$lib/app/settings.svelte'
import FormattedNumber from '$lib/ui/util/FormattedNumber.svelte'
import { buttonColor, toast } from 'mono-svelte'
import { toast } from 'mono-svelte'
import { ChevronDown, ChevronUp, Icon } from 'svelte-hero-icons/dist'
import { backOut } from 'svelte/easing'
import { fly } from 'svelte/transition'
@@ -74,7 +74,7 @@
<button
onclick={() => castVote(vote == targetNum ? 0 : targetNum)}
class={[
'flex items-center gap-0.5 transition-colors relative cursor-pointer h-full p-1.5',
'flex items-center gap-0.5 transition-colors relative cursor-pointer px-1.5 py-1',
'first:rounded-l-3xl last:rounded-r-3xl',
'last:flex-row-reverse',
vote == targetNum
@@ -112,14 +112,13 @@
<div
class={[
'h-full relative flex items-center overflow-hidden rounded-full hover:bg-transparent font-medium hover:dark:bg-transparent',
buttonColor.ghost,
'h-full relative flex items-center overflow-hidden rounded-full font-medium',
voteRatio < 85 && settings.voteRatioBar && 'vote-ratio',
'divide-x divide-slate-200 dark:divide-zinc-800 border border-slate-200 dark:border-zinc-800',
]}
style="--vote-ratio: {voteRatio}%;"
>
{@render voteButton(upvotes, 'upvote', vote)}
<div class="h-full p-0! border-l border-slate-200 dark:border-zinc-800"></div>
{#if site.data?.site_view.local_site.enable_downvotes ?? true}
{@render voteButton(downvotes, 'downvote', vote)}
{/if}