import { getStories } from "app/lib/get"
export default async function StoryDropdown() {
	const stories = await getStories()
	const storiesDrowpdown = stories.map(e => {
		return <option value={e.id} key={`${e.title}`}>{e.title}</option>
	})
	return (
		<>
			<label htmlFor="storyDropdown">Story:</label>
			<select key="storyDropdown" id="storyDropdown">
				{storiesDrowpdown}
			</select>
		</>
	)
}
