vchikalkin 32f265fc8d optimize package/ui/elements imports
optimize antd/link imports

ui/elements/text: use antd component

ui/element: optimize input, input-number, switch, checkbox imports

fix Number typename

ui/elements: optimize Radio, Segmented, Select

move type Status to store types

fix TableInsurance builders

packages/ui: remove antd dir

Output/Results: fix elements margin

revert Loading status to elements

packages/ui: remove value from props

remove unnecessary loading prop
2023-05-16 11:31:45 +03:00

19 lines
439 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import type { SelectProps } from 'antd';
import { Select as AntSelect } from 'antd';
import { useMemo } from 'react';
export default function Select({ options = [], ...props }: SelectProps<string | null>) {
const optionsWithNull = useMemo(
() => [
{
label: 'Не выбрано',
value: null,
},
...options,
],
[options]
);
return <AntSelect options={optionsWithNull} {...props} />;
}