ADropdownForm.tsx 486 Bytes
Newer Older
1
2
import React, { useState } from "react";
import { DropdownType } from "../types";
Lee SeoYeon's avatar
Lee SeoYeon committed
3

4
5
6
7
8
type Props = {
  element: DropdownType;
};

export const ADropdownForm = ({ element }: Props) => {
Lee SeoYeon's avatar
Lee SeoYeon committed
9
  return (
10
    <div className="flex flex-col container w-4/5 h-auto items-center m-3 py-3">
Lee SeoYeon's avatar
.    
Lee SeoYeon committed
11
      <select className="py-2 hover:bg-themeColor bg-gray-200 rounded ">
12
13
14
        {element.content.choices.map((choice) => (
          <option>{choice.text}</option>
        ))}
Lee SeoYeon's avatar
Lee SeoYeon committed
15
16
17
18
      </select>
    </div>
  );
};