You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
869 B
44 lines
869 B
2 years ago
|
import React from 'react';
|
||
|
import { Select } from 'antd';
|
||
|
|
||
|
const App: React.FC = () => (
|
||
|
<Select
|
||
|
showSearch
|
||
|
style={{ width: 200 }}
|
||
|
placeholder="Search to Select"
|
||
|
optionFilterProp="children"
|
||
|
filterOption={(input, option) => (option?.label ?? '').includes(input)}
|
||
|
filterSort={(optionA, optionB) =>
|
||
|
(optionA?.label ?? '').toLowerCase().localeCompare((optionB?.label ?? '').toLowerCase())
|
||
|
}
|
||
|
options={[
|
||
|
{
|
||
|
value: '1',
|
||
|
label: 'Not Identified',
|
||
|
},
|
||
|
{
|
||
|
value: '2',
|
||
|
label: 'Closed',
|
||
|
},
|
||
|
{
|
||
|
value: '3',
|
||
|
label: 'Communicated',
|
||
|
},
|
||
|
{
|
||
|
value: '4',
|
||
|
label: 'Identified',
|
||
|
},
|
||
|
{
|
||
|
value: '5',
|
||
|
label: 'Resolved',
|
||
|
},
|
||
|
{
|
||
|
value: '6',
|
||
|
label: 'Cancelled',
|
||
|
},
|
||
|
]}
|
||
|
/>
|
||
|
);
|
||
|
|
||
|
export default App;
|