diff --git a/components/date-picker/generatePicker/index.tsx b/components/date-picker/generatePicker/index.tsx index 0df45094eb..968e19972a 100644 --- a/components/date-picker/generatePicker/index.tsx +++ b/components/date-picker/generatePicker/index.tsx @@ -72,15 +72,19 @@ export function getTimeProps( const DataPickerPlacements = ['bottomLeft', 'bottomRight', 'topLeft', 'topRight'] as const; type DataPickerPlacement = typeof DataPickerPlacements[number]; +const HourStep = [0.5, 1, 1.5, 2, 3, 4, 6, 8, 12] as const; +type THourStep = typeof HourStep[number]; + type InjectDefaultProps = Omit< Props, - 'locale' | 'generateConfig' | 'hideHeader' | 'components' + 'locale' | 'generateConfig' | 'hideHeader' | 'components' | 'hourStep' > & { locale?: PickerLocale; size?: SizeType; placement?: DataPickerPlacement; bordered?: boolean; status?: InputStatus; + hourStep?: THourStep; }; export type PickerLocale = { diff --git a/components/time-picker/demo/interval-options.tsx b/components/time-picker/demo/interval-options.tsx index 862a3da43b..1fff93502a 100644 --- a/components/time-picker/demo/interval-options.tsx +++ b/components/time-picker/demo/interval-options.tsx @@ -1,6 +1,6 @@ -import React from 'react'; import { TimePicker } from 'antd'; +import React from 'react'; -const App: React.FC = () => ; +const App: React.FC = () => ; export default App;