mirror of https://gitee.com/answerdev/answer.git
feat(ui): add TimeZonePicker component
This commit is contained in:
parent
f863869406
commit
860f39664e
|
@ -0,0 +1,25 @@
|
|||
import { Form } from 'react-bootstrap';
|
||||
|
||||
import { TIMEZONES } from '@/common/constants';
|
||||
|
||||
const TimeZonePicker = (props) => {
|
||||
return (
|
||||
<Form.Select {...props}>
|
||||
{TIMEZONES?.map((item) => {
|
||||
return (
|
||||
<optgroup label={item.label} key={item.label}>
|
||||
{item.options.map((option) => {
|
||||
return (
|
||||
<option value={option.value} key={option.value}>
|
||||
{option.label}
|
||||
</option>
|
||||
);
|
||||
})}
|
||||
</optgroup>
|
||||
);
|
||||
})}
|
||||
</Form.Select>
|
||||
);
|
||||
};
|
||||
|
||||
export default TimeZonePicker;
|
Loading…
Reference in New Issue