diff --git a/apps/gacha/src/app/page.tsx b/apps/gacha/src/app/page.tsx index 1d2ad4f..83f7a7f 100644 --- a/apps/gacha/src/app/page.tsx +++ b/apps/gacha/src/app/page.tsx @@ -1,7 +1,7 @@ import { ArrowDownOutlined } from '@ant-design/icons'; import { Button } from '@imphnen-frontend-service/ui/atoms'; import { cn } from '@imphnen-frontend-service/utils'; -import { FC, Fragment, ReactElement, useEffect, useState } from 'react'; +import { FC, Fragment, ReactElement, useState } from 'react'; import ModalFormForgotPassword from './_components/form/modal-form-forgot-password'; import ModalFormLogin from './_components/form/modal-form-login'; import ModalFormRegister from './_components/form/modal-form-register'; @@ -12,6 +12,27 @@ interface GachaItemProps { className?: string; } +const GachaItem: FC = ({ + src, + label, + className, +}): ReactElement => { + return ( +
+
+ Banner +
+

{label}

+
+ ); +}; + export const Components: FC = (): ReactElement => { const [showModalForgotPassword, setShowModalForgotPassword] = useState(false); const [showModalLogin, setShowModalLogin] = useState(false); @@ -24,49 +45,6 @@ export const Components: FC = (): ReactElement => { } }; - useEffect(() => { - const gachaPlaySection = document.getElementById('gacha-play'); - if (gachaPlaySection) { - let currentIndex = 0; - const items = gachaPlaySection.children; - const totalItems = items.length; - - const scrollItems = () => { - if (currentIndex >= totalItems) { - currentIndex = 0; - } - items[currentIndex].scrollIntoView({ - behavior: 'smooth', - inline: 'center', - }); - currentIndex++; - }; - - const intervalId = setInterval(scrollItems, 2800); - - return () => clearInterval(intervalId); - } - }, []); - - const GachaItem: FC = ({ - src, - label, - className, - }): ReactElement => { - return ( -
-
- -
-

{label}

-
- ); - }; - const handleForgotPasswordClick = () => { setShowModalLogin(false); setShowModalForgotPassword(true); @@ -74,7 +52,6 @@ export const Components: FC = (): ReactElement => { return ( - {/* Landing Page */}
{ ~ 175k ~ -
+
Merch 2
@@ -163,7 +146,7 @@ export const Components: FC = (): ReactElement => {
- {/* Roulette Page */} +
{ -
+
Here Take Your Prize
@@ -223,7 +203,7 @@ export const Components: FC = (): ReactElement => { Spin Now
- {/* TODO: Change using real button trigger */} +
- {/* Diffuser & Cloud */}
- {/* Login Modal */} setShowModalLogin(false)} @@ -247,7 +225,6 @@ export const Components: FC = (): ReactElement => { key="login" /> - {/* Register Modal */} { @@ -256,7 +233,6 @@ export const Components: FC = (): ReactElement => { key="register" /> - {/* Forgot Password Modal */} {