Skip to content

Commit

Permalink
fix: Add key prop to buttons in Game component and fix typo in SetLes…
Browse files Browse the repository at this point in the history
…sons component
  • Loading branch information
SICout9010 committed Jul 21, 2024
1 parent db03cb1 commit d34f794
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions app/game/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ function Game(): GameProps {
<div className="w-full h-fit items-center justify-center flex flex-col">
<p className="text-4xl font-bold text-wrap text-center text-[#343434]">{currentQuiz.question}</p>
<div className="flex gap-6 mt-20">
{currentQuiz.options.map((option) => (
<button className={`text-4xl text-white p-24 ${currentQuiz.type == 'boolean' ? "bg-[#35CD4D]" : "bg-[#FBAE17]"} rounded-[36px]`} onClick={
{currentQuiz.options.map((option, index) => (
<button key={index} className={`text-4xl text-white p-24 ${currentQuiz.type == 'boolean' ? "bg-[#35CD4D]" : "bg-[#FBAE17]"} rounded-[36px]`} onClick={
() => {
setSelectedOption(option)
if (selectedOption === currentQuiz.answer) {
Expand Down
8 changes: 4 additions & 4 deletions components/setLessons.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ const prompt = Prompt({ subsets: ["latin"], weight: ["300", "400", "500", "600",

function SetLessons() {
return (
<main className="min-w-[1440px] flex flex-col justify-center">
<div className="flex gap-2 items-center">
<main className="min-w-[1440px] h-full flex flex-col justify-center">
<div className="flex tems-center justify-between">

<div>
<div className="flex items-center justify-center mb-1">
<div className="flex items-centermb-1">
<svg width="55" height="50" viewBox="0 0 55 50" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M25.9722 32.7709L18.3333 24.7501M18.3333 24.7501L25.9722 16.7292M18.3333 24.7501H36.6666" stroke="#343434" stroke-width="3.66667" stroke-linecap="round" stroke-linejoin="round" />
</svg>
Expand All @@ -27,7 +27,7 @@ function SetLessons() {

<div className="relative w-[340px] h-[500px]">
<div className="absolute">
<Image src={step1} alt="step1"/>
<Image className="" src={step1} alt="step1"/>
<Image src={step2} alt="step2"/>
<Image src={step3} alt="step3"/>

Expand Down

0 comments on commit d34f794

Please sign in to comment.