forked from ddrilling/asb_cloud_front
PeriodPicker добавлена возможность указывать доп атриббуты
This commit is contained in:
parent
e7fed714ee
commit
cf7323ba5a
@ -16,10 +16,12 @@ const timePeriodCollection = [
|
||||
type PeriodPickerProps = {
|
||||
defaultValue?: number
|
||||
onChange?: (value: number) => void
|
||||
[other: string]: any
|
||||
}
|
||||
|
||||
export const PeriodPicker = ({ defaultValue = defaultPeriod, onChange }: PeriodPickerProps) => (
|
||||
export const PeriodPicker = ({ defaultValue = defaultPeriod, onChange, ...other }: PeriodPickerProps) => (
|
||||
<Select
|
||||
{...other}
|
||||
defaultValue={defaultValue}
|
||||
onChange={(value) => onChange?.(Number(value))}
|
||||
options={timePeriodCollection}
|
||||
|
Loading…
Reference in New Issue
Block a user