import {storyStates} from "@/lib/constants/story"; import {BookOpen, Keyboard, LucideIcon, Palette, PenLine, Wand2} from "lucide-react"; import React, {Dispatch, SetStateAction} from "react"; export interface RadioBoxValue { label: string; value: number; } interface RadioBoxProps { selected: number; setSelected: Dispatch>; name: string; } const storyStateIcons: LucideIcon[] = [PenLine, Keyboard, Palette, BookOpen, Wand2]; export default function RadioBox( { selected, setSelected, name }: RadioBoxProps) { return (
{storyStates.map((option: RadioBoxValue) => { const Icon = storyStateIcons[option.value]; return (
setSelected(option.value)} className="hidden" />
); })}
) }