changed country to dropdown

This commit is contained in:
juhanikat
2025-07-28 19:58:29 +03:00
parent 436475b461
commit 33dc6d636c
@@ -1,15 +1,18 @@
import { ArrayFrame } from '@/components/DetailView/common/tabLayoutHelpers'
import { useDetailContext } from '@/components/DetailView/Context/DetailContext'
import { Museum } from '@/shared/types'
import { validCountries } from '@/shared/validators/countryList'
export const MuseumInfoTab = ({ isNew }: { isNew?: boolean }) => {
const { textField, radioSelection } = useDetailContext<Museum>()
const { textField, radioSelection, dropdownWithSearch } = useDetailContext<Museum>()
const countryOptions = ['', ...validCountries]
const museumInfo = [
['Institution', textField('institution')],
['Alt. name', textField('alt_int_name')],
['City', textField('city')],
['Country', textField('country')],
['Country', dropdownWithSearch('country', countryOptions, 'Country')],
['State', textField('state')],
['State code', textField('state_code')],
[