fix: fix #28
This commit is contained in:
1 parent
ed42b70537
commit
b0e9e898f1
4 files changed
+5
-5
No files matched your search
@@ -7,7 +7,7 @@
|
||||
case 'default':
|
||||
return 'border border-slate-200 dark:border-zinc-800 dark:bg-zinc-900'
|
||||
case 'warning':
|
||||
return 'border border-yellow-300 dark:bg-yellow-800 dark:border-yellow-600 bg-yellow-50'
|
||||
return 'border border-yellow-300 dark:bg-yellow-950/30 dark:border-yellow-900 bg-yellow-50'
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ export function load({ params, url }) {
|
||||
if (Number(params.instance)) {
|
||||
const split = url.pathname.split('/')
|
||||
|
||||
split.splice(2, 0, `${get(instance)}`)
|
||||
split.splice(2, 0, `${get(instance)?.toLowerCase()}`)
|
||||
|
||||
const newUrl = new URL(url)
|
||||
newUrl.pathname = split.join('/')
|
||||
|
||||
@@ -81,7 +81,7 @@
|
||||
</svelte:head>
|
||||
|
||||
<div class="flex flex-col gap-2">
|
||||
{#if $authData && $page.params.instance != $authData.instance}
|
||||
{#if $authData && $page.params.instance.toLowerCase() != $authData.instance.toLowerCase()}
|
||||
<Card cardColor="warning" class="p-4 flex flex-col gap-1">
|
||||
<Icon
|
||||
src={ExclamationTriangle}
|
||||
|
||||
@@ -2,7 +2,7 @@ import { authData, getClient } from '$lib/lemmy.js'
|
||||
import { get } from 'svelte/store'
|
||||
|
||||
export async function load({ params }) {
|
||||
const post = await getClient(params.instance).getPost({
|
||||
const post = await getClient(params.instance.toLowerCase()).getPost({
|
||||
id: Number(params.id),
|
||||
auth: get(authData)?.token,
|
||||
})
|
||||
@@ -10,7 +10,7 @@ export async function load({ params }) {
|
||||
return {
|
||||
post: post,
|
||||
streamed: {
|
||||
comments: getClient(params.instance).getComments({
|
||||
comments: getClient(params.instance.toLowerCase()).getComments({
|
||||
post_id: Number(params.id),
|
||||
type_: 'All',
|
||||
limit: 25,
|
||||
|
||||
Reference in new issue
Block a user