-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
90 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { Loader2 } from "lucide-react" | ||
|
||
export default function BottomSpinner() { | ||
return ( | ||
<div className="mx-auto flex items-center justify-center gap-1 py-4 font-bold"> | ||
<Loader2 className="animate-spin" size={24} /> | ||
<p>Loading...</p> | ||
</div> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
"use client" | ||
|
||
import { Tooltip } from "@radix-ui/themes" | ||
import { ArrowLeft } from "lucide-react" | ||
import Link from "next/link" | ||
import { useRouter } from "next/navigation" | ||
|
||
export default function TopAppBar({ content, back }: { content: React.ReactNode; back?: boolean }) { | ||
const router = useRouter() | ||
|
||
return ( | ||
<div className="flex min-h-12 items-center border-b px-2"> | ||
{back && ( | ||
<Tooltip content="戻る"> | ||
<Link | ||
className="mr-5 rounded-full p-2 hover:bg-neutral-100" | ||
href="/home/" | ||
onClick={router.back}> | ||
<ArrowLeft className="text-neutral-600" size={18} /> | ||
</Link> | ||
</Tooltip> | ||
)} | ||
{content} | ||
</div> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
import { Emoji } from ".." | ||
import { Emoji } from "../types" | ||
import MisskeyLatestClient from "./misskey-latest" | ||
|
||
export default class MisskeyV12Client extends MisskeyLatestClient { | ||
id = "misskey-v12" | ||
|
||
override async emojiUrl(name: string): Promise<string | null> { | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const { emojis } = await super.post<any>("meta") | ||
const { emojis } = await super.post<any>("meta", {}) | ||
return emojis?.find?.((e: Record<keyof Emoji, unknown>) => e.name == name)?.url ?? null | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
import { Emoji } from ".." | ||
import { Emoji } from "../types" | ||
import MisskeyLatestClient from "./misskey-latest" | ||
|
||
export default class MisskeyV13Client extends MisskeyLatestClient { | ||
id = "misskey-v13" | ||
|
||
override async emojiUrl(name: string): Promise<string | null> { | ||
// eslint-disable-next-line @typescript-eslint/no-explicit-any | ||
const { emojis } = await super.get<any>("emojis") | ||
const { emojis } = await super.get<any>("emojis", {}) | ||
return emojis?.find?.((e: Record<keyof Emoji, unknown>) => e.name == name)?.url ?? null | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters