diff --git a/public/tutorial/adding-mii/step2.png b/public/tutorial/adding-mii/step2.png deleted file mode 100644 index 60a1eb9..0000000 Binary files a/public/tutorial/adding-mii/step2.png and /dev/null differ diff --git a/public/tutorial/adding-mii/step3.png b/public/tutorial/adding-mii/step3.png deleted file mode 100644 index df0840c..0000000 Binary files a/public/tutorial/adding-mii/step3.png and /dev/null differ diff --git a/public/tutorial/adding-mii/step4.png b/public/tutorial/adding-mii/step4.png deleted file mode 100644 index 2f21ed9..0000000 Binary files a/public/tutorial/adding-mii/step4.png and /dev/null differ diff --git a/public/tutorial/adding-mii/step5.png b/public/tutorial/adding-mii/step5.png deleted file mode 100644 index 9269d13..0000000 Binary files a/public/tutorial/adding-mii/step5.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step2.png b/public/tutorial/allow-copying/step2.png deleted file mode 100644 index 9c2b295..0000000 Binary files a/public/tutorial/allow-copying/step2.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step3.png b/public/tutorial/allow-copying/step3.png deleted file mode 100644 index 307b5f6..0000000 Binary files a/public/tutorial/allow-copying/step3.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step4.png b/public/tutorial/allow-copying/step4.png deleted file mode 100644 index f91cc5f..0000000 Binary files a/public/tutorial/allow-copying/step4.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step5.png b/public/tutorial/allow-copying/step5.png deleted file mode 100644 index 93b0cf5..0000000 Binary files a/public/tutorial/allow-copying/step5.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step6.png b/public/tutorial/allow-copying/step6.png deleted file mode 100644 index 67bae80..0000000 Binary files a/public/tutorial/allow-copying/step6.png and /dev/null differ diff --git a/public/tutorial/allow-copying/step7.png b/public/tutorial/allow-copying/step7.png deleted file mode 100644 index b30964d..0000000 Binary files a/public/tutorial/allow-copying/step7.png and /dev/null differ diff --git a/public/tutorial/allow-copying/thumbnail.png b/public/tutorial/allow-copying/thumbnail.png deleted file mode 100644 index ab54c2a..0000000 Binary files a/public/tutorial/allow-copying/thumbnail.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/step2.png b/public/tutorial/create-qr-code/step2.png deleted file mode 100644 index 60a1eb9..0000000 Binary files a/public/tutorial/create-qr-code/step2.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/step3.png b/public/tutorial/create-qr-code/step3.png deleted file mode 100644 index dbc6743..0000000 Binary files a/public/tutorial/create-qr-code/step3.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/step4.png b/public/tutorial/create-qr-code/step4.png deleted file mode 100644 index 562b19f..0000000 Binary files a/public/tutorial/create-qr-code/step4.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/step5.png b/public/tutorial/create-qr-code/step5.png deleted file mode 100644 index e6cf9fd..0000000 Binary files a/public/tutorial/create-qr-code/step5.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/step6.png b/public/tutorial/create-qr-code/step6.png deleted file mode 100644 index f78da9a..0000000 Binary files a/public/tutorial/create-qr-code/step6.png and /dev/null differ diff --git a/public/tutorial/create-qr-code/thumbnail.png b/public/tutorial/create-qr-code/thumbnail.png deleted file mode 100644 index cfb7906..0000000 Binary files a/public/tutorial/create-qr-code/thumbnail.png and /dev/null differ diff --git a/public/tutorial/step1.png b/public/tutorial/step1.png deleted file mode 100644 index 13983f9..0000000 Binary files a/public/tutorial/step1.png and /dev/null differ diff --git a/src/app/mii/[id]/page.tsx b/src/app/mii/[id]/page.tsx index 8e7381b..28bdfef 100644 --- a/src/app/mii/[id]/page.tsx +++ b/src/app/mii/[id]/page.tsx @@ -12,7 +12,8 @@ import LikeButton from "@/components/like-button"; import ImageViewer from "@/components/image-viewer"; import DeleteMiiButton from "@/components/delete-mii"; import ShareMiiButton from "@/components/share-mii-button"; -import ScanTutorialButton from "@/components/tutorial/scan"; +import ThreeDsScanTutorialButton from "@/components/tutorial/3ds-scan"; +import SwitchScanTutorialButton from "@/components/tutorial/switch-scan"; interface Props { params: Promise<{ id: string }>; @@ -233,7 +234,7 @@ export default async function MiiPage({ params }: Props) { Report - + {mii.platform === "THREE_DS" ? : } diff --git a/src/app/off-the-island/page.tsx b/src/app/off-the-island/page.tsx index cea9dd9..525228a 100644 --- a/src/app/off-the-island/page.tsx +++ b/src/app/off-the-island/page.tsx @@ -95,9 +95,7 @@ export default async function ExiledPage() {
mii image
-

- {mii.mii.name} -

+

{mii.mii.name}

Reason: {mii.reason}

diff --git a/src/components/tutorial/scan.tsx b/src/components/tutorial/3ds-scan.tsx similarity index 92% rename from src/components/tutorial/scan.tsx rename to src/components/tutorial/3ds-scan.tsx index 93e1bff..3d7063c 100644 --- a/src/components/tutorial/scan.tsx +++ b/src/components/tutorial/3ds-scan.tsx @@ -7,7 +7,7 @@ import { Icon } from "@iconify/react"; import TutorialPage from "./page"; -export default function ScanTutorialButton() { +export default function ThreeDsScanTutorialButton() { const [isOpen, setIsOpen] = useState(false); const [isVisible, setIsVisible] = useState(false); @@ -66,11 +66,11 @@ export default function ScanTutorialButton() {
- - - - - + + + + +
diff --git a/src/components/tutorial/3ds-submit.tsx b/src/components/tutorial/3ds-submit.tsx index 0995d7a..432eb57 100644 --- a/src/components/tutorial/3ds-submit.tsx +++ b/src/components/tutorial/3ds-submit.tsx @@ -69,7 +69,7 @@ export default function ThreeDsSubmitTutorialButton() {
- + {/* Allow Copying */} diff --git a/src/components/tutorial/starting-page.tsx b/src/components/tutorial/starting-page.tsx index 103cf0b..7655ac7 100644 --- a/src/components/tutorial/starting-page.tsx +++ b/src/components/tutorial/starting-page.tsx @@ -3,9 +3,10 @@ import { UseEmblaCarouselType } from "embla-carousel-react"; interface Props { emblaApi: UseEmblaCarouselType[1] | undefined; + isSwitch?: boolean; } -export default function StartingPage({ emblaApi }: Props) { +export default function StartingPage({ emblaApi, isSwitch }: Props) { const goToTutorial = (index: number) => { if (!emblaApi) return; @@ -29,7 +30,7 @@ export default function StartingPage({ emblaApi }: Props) { className="flex flex-col justify-center items-center bg-zinc-50 rounded-xl p-4 shadow-md border-2 border-zinc-300 cursor-pointer text-center text-sm transition hover:scale-[1.03] hover:bg-cyan-100 hover:border-cyan-600" > Allow Copying thumbnail Creating QR code thumbnail { + setIsVisible(false); + setTimeout(() => { + setIsOpen(false); + setSelectedIndex(0); + }, 300); + }; + + useEffect(() => { + if (isOpen) { + // slight delay to trigger animation + setTimeout(() => setIsVisible(true), 10); + } + }, [isOpen]); + + useEffect(() => { + if (!emblaApi) return; + emblaApi.on("select", () => setSelectedIndex(emblaApi.selectedScrollSnap())); + }, [emblaApi]); + + return ( + <> + + + {isOpen && + createPortal( +
+
+ +
+
+

Tutorial

+ +
+ +
+
+
+ + + + + + +
+
+ +
+ + + Adding Mii to Island + + +
+
+
+
, + document.body + )} + + ); +} diff --git a/src/components/tutorial/switch-submit.tsx b/src/components/tutorial/switch-submit.tsx index c52dec0..04d8364 100644 --- a/src/components/tutorial/switch-submit.tsx +++ b/src/components/tutorial/switch-submit.tsx @@ -69,32 +69,35 @@ export default function SwitchSubmitTutorialButton() {
- + {/* Allow Copying */} - - - - - - - + + + + + + + {/* Create QR Code */} - - - - + + + +