Make onChange optional

This commit is contained in:
Robert
2023-09-04 15:30:09 +01:00
parent 040a91a6d7
commit fd1c7f338d
2 changed files with 1 additions and 6 deletions

View File

@@ -20,7 +20,7 @@ type Props = {
options: Array<{ value: string; label: string }>;
disabled?: boolean;
disabledPlaceholder?: string;
onChange: (event: ChangeEvent<HTMLSelectElement>) => void;
onChange?: (event: ChangeEvent<HTMLSelectElement>) => void;
};
/**

View File

@@ -2,17 +2,12 @@ import * as React from "react";
import { Dropdown } from "../common/Dropdown";
export const InProgressDropdown = () => {
const noop = () => {
// Do nothing
};
return (
<Dropdown
value="Thinking..."
options={[]}
disabled={true}
disabledPlaceholder="Thinking..."
onChange={noop}
/>
);
};