fix: eslint type issue

This commit is contained in:
Lim Yang Zhi 2024-07-03 00:30:05 +08:00
parent 8a9750ee93
commit 03146a9d69

View File

@ -86,12 +86,14 @@ describe('Cascader.typescript', () => {
});
it('multiple onChange', () => {
const { container } = render(<Cascader multiple onChange={(values) => values} />);
const { container } = render(
<Cascader multiple onChange={(values: (string | number | null)[][]) => values} />,
);
expect(container).toBeTruthy();
});
it('props', () => {
const list: { props?: CascaderAutoProps }[] = [
{ props: { multiple: true, onChange: (value) => value } },
{ props: { multiple: true, onChange: (value: (string | number | null)[][]) => value } },
{ props: { multiple: false, onChange: (value) => value } },
];
expect(list).toBeTruthy();