mirror of
https://github.com/movie-web/movie-web.git
synced 2024-12-29 18:36:18 +00:00
Merge pull request #110 from JamesHawkinss/dev
Fix dropdown not rendering
This commit is contained in:
commit
4c50436a9e
|
@ -20,6 +20,10 @@
|
|||
"invalidUrl": "Your URL may be invalid",
|
||||
"arrowText": "Go back"
|
||||
},
|
||||
"seasons": {
|
||||
"season": "Season {{season}}",
|
||||
"failed": "Failed to get season data"
|
||||
},
|
||||
"notFound": {
|
||||
"backArrow": "Back to home",
|
||||
"media": {
|
||||
|
|
|
@ -15,6 +15,7 @@ interface DropdownProps {
|
|||
}
|
||||
|
||||
export function Dropdown(props: DropdownProps) {
|
||||
return (
|
||||
<div className="relative my-4 max-w-[18rem]">
|
||||
<Listbox value={props.selectedItem} onChange={props.setSelectedItem}>
|
||||
{({ open }) => (
|
||||
|
@ -55,5 +56,6 @@ export function Dropdown(props: DropdownProps) {
|
|||
</>
|
||||
)}
|
||||
</Listbox>
|
||||
</div>;
|
||||
</div>
|
||||
)
|
||||
}
|
||||
|
|
|
@ -75,7 +75,7 @@ export function Seasons(props: SeasonsProps) {
|
|||
|
||||
const mapSeason = (season: MWMediaSeason) => ({
|
||||
id: season.id,
|
||||
name: season.title || `${t('seasons.season')} ${season.sort}`,
|
||||
name: season.title || `${t('seasons.season', { season: season.sort })}`,
|
||||
});
|
||||
|
||||
const options = seasons.seasons.map(mapSeason);
|
||||
|
|
Loading…
Reference in a new issue