Answers
diff --git a/src/components/game/states/Prepared.jsx b/src/components/game/states/Prepared.jsx
new file mode 100644
index 0000000..dca1c16
--- /dev/null
+++ b/src/components/game/states/Prepared.jsx
@@ -0,0 +1,31 @@
+import Circle from "@/components/icons/Circle"
+import CricleCheck from "@/components/icons/CricleCheck"
+import CricleXmark from "@/components/icons/CricleXmark"
+import Rhombus from "@/components/icons/Rhombus"
+import Square from "@/components/icons/Square"
+import Triangle from "@/components/icons/Triangle"
+import { usePlayerContext } from "@/context/player"
+import { useEffect } from "react"
+/*{ data: { number, total, question } }*/
+export default function Prepared() {
+ const { dispatch } = usePlayerContext()
+
+ return (
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ )
+}
diff --git a/src/components/game/states/Question.jsx b/src/components/game/states/Question.jsx
index 603c7eb..3d7805d 100644
--- a/src/components/game/states/Question.jsx
+++ b/src/components/game/states/Question.jsx
@@ -1,5 +1,4 @@
-import { useSocketContext } from "@/context/socket"
-import { useEffect, useRef } from "react"
+import { useRef } from "react"
export default function Question({ data: { question } }) {
const barRef = useRef(null)
diff --git a/src/constants.js b/src/constants.js
index d744316..af3d000 100644
--- a/src/constants.js
+++ b/src/constants.js
@@ -1 +1 @@
-export const WEBSOCKET_URL = "http://localhost:3000" ///"https://rahoot.ralex.app"
+export const WEBSOCKET_URL = "http://localhost:5157" ///"https://rahoot.ralex.app"
diff --git a/src/context/socket.jsx b/src/context/socket.jsx
index d47a78e..066b63f 100644
--- a/src/context/socket.jsx
+++ b/src/context/socket.jsx
@@ -2,7 +2,7 @@ import { io } from "socket.io-client"
import { createContext, useContext, useState } from "react"
import { WEBSOCKET_URL } from "@/constants"
-export const socket = io("http://localhost:5157", {
+export const socket = io(WEBSOCKET_URL, {
path: "/ws/",
//addTrailingSlash: false,
transports: ["websocket"],
diff --git a/src/pages/manager.jsx b/src/pages/manager.jsx
index ed27938..730a26e 100644
--- a/src/pages/manager.jsx
+++ b/src/pages/manager.jsx
@@ -2,6 +2,7 @@ import Button from "@/components/Button"
import GameWrapper from "@/components/game/GameWrapper"
import Answers from "@/components/game/states/Answers"
import Leaderboard from "@/components/game/states/Leaderboard"
+import Prepared from "@/components/game/states/Prepared"
import Question from "@/components/game/states/Question"
import Start from "@/components/game/states/Start"
import Wait from "@/components/game/states/Wait"
@@ -90,12 +91,15 @@ export default function Manager() {
+ >
)}
>
)
diff --git a/src/styles/globals.css b/src/styles/globals.css
index b9cd4cf..c068cc6 100644
--- a/src/styles/globals.css
+++ b/src/styles/globals.css
@@ -36,6 +36,20 @@
animation: show 0.5s ease-out;
}
+.anim-timer {
+ animation: timer 1s ease-out infinite;
+}
+
+.anim-quizz {
+ animation: quizz 1s ease-out;
+ transform: perspective(1200px) rotateY(-15deg) rotateX(15deg)
+ translateZ(100px);
+}
+
+.anim-quizz .button {
+ animation: quizzButton 1s ease-out;
+}
+
@keyframes show {
0% {
transform: scale(0);
@@ -59,3 +73,38 @@
width: 100%;
}
}
+
+@keyframes timer {
+ 0% {
+ transform: scale(1);
+ }
+ 30% {
+ transform: scale(1.4) rotate(-6deg);
+ }
+ 60% {
+ transform: scale(0.8) rotate(6deg);
+ }
+ 80% {
+ transform: scale(1);
+ }
+}
+
+@keyframes quizz {
+ 0% {
+ transform: scale(0) perspective(1200px) rotateY(-35deg) rotateX(15deg)
+ translateZ(100px);
+ }
+ 100% {
+ transform: scale(1) perspective(1200px) rotateY(-15deg) rotateX(15deg)
+ translateZ(100px);
+ }
+}
+
+@keyframes quizzButton {
+ 0% {
+ transform: scale(0);
+ }
+ 100% {
+ transform: scale(1);
+ }
+}