mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-20 05:22:02 +00:00
34 lines
685 B
TypeScript
34 lines
685 B
TypeScript
import SelectInput from '../input/SelectInput';
|
|
|
|
export interface OptionType {
|
|
label: string;
|
|
value: string | number;
|
|
}
|
|
|
|
interface TableRowSizeSelectorProps {
|
|
value: number;
|
|
onChange: (val: OptionType | OptionType[] | null) => void;
|
|
options: OptionType[];
|
|
}
|
|
|
|
export const TableRowSizeSelector = ({
|
|
value,
|
|
onChange,
|
|
options,
|
|
}: TableRowSizeSelectorProps) => {
|
|
return (
|
|
<div className='flex flex-row justify-end'>
|
|
<SelectInput
|
|
label='Baris'
|
|
options={options}
|
|
value={{
|
|
label: String(value),
|
|
value: value,
|
|
}}
|
|
onChange={onChange}
|
|
className={{ wrapper: 'max-w-28' }}
|
|
/>
|
|
</div>
|
|
);
|
|
};
|