{Object.entries(itemsState).map(([key, value], index) => (
<Box key={index} sx={{display: "flex", alignItems: "center", marginBottom: 1}}>
<TextField
required={true}
label={`${index + 1}회차 이상`}
variant="outlined"
size="small"
sx={{marginBottom: 1}}
value={value || ''}
onChange={(e) => {
setItemsState({
...itemsState,
[key]: parseInt(e.target.value),
});
}}
/>
<Typography variant="h6" sx={{marginLeft: 1}}>%</Typography>
</Box>
))}
{Object.entries(itemsState).map(([key, value], index) => (
<Box key={index} sx={{display: "flex", alignItems: "center", marginBottom: 1}}>
<TextField
required={true}
label={`${index + 1}회차 이상`}
variant="outlined"
size="small"
sx={{marginBottom: 1}}
value={value || ''}
onChange={(e) => {
setItemsState({
...itemsState,
[key]: parseInt(e.target.value),
});
}}
/>
<Typography variant="h6" sx={{marginLeft: 1}}>%</Typography>
</Box>
))}