Skip to main content

DateTimePicker

Inputs & Controls

DateTimePicker

Coordinated date and time selection component built on top of picker primitives.

Usage

Capture timestamp values in a single cohesive control.

Highlights

  • Handles timezone-safe conversions
  • Plugs into date/time utilities

When to use it

  • Booking or scheduling forms that require time precision.
  • Any workflow that combines DatePicker + TimePicker.

Examples

Default

Preview (Web)
import { useState } from 'react';
import { DateTimePicker } from 'react-native-molecules/components/DateTimePicker';

export default function Example() {
  const [date, setDate] = useState<Date | null>(new Date());

  return <DateTimePicker date={date} onChange={setDate} />;
}
PropTypeDefaultDescription
is24Hourboolean | undefined
dateDate | null | undefined
onChange((date: Date | null) => void) | undefined
defaultValueDate | null | undefined
timePickerFieldPropsOmit<Partial<TimePickerFieldProps>, "onChangeText" | "value" | "date" | "onTimeChange"> | undefined
datePickerInputPropsOmit<Partial<DatePickerInputProps>, "onChange" | "value"> | undefined
datePickerInputRefRefObject<TextInputHandles | null> | undefined
timePickerInputRefRefObject<TextInputHandles | null> | undefined
WrapperComponentType<any> | undefined
styleViewStyle | undefined
Defined in react-native-molecules/components/DateTimePicker