GitHub

    Table of contents

  1. Example
  2. Related Links

CupertinoDatePicker

Edit this page

A date picker widget in iOS style.

Example

Future<void> _handleClickMe() async {
  showModalBottomSheet(
    context: context,
    builder: (context) {
      return Container(
        height: 300,
        child: CupertinoDatePicker(
          mode: CupertinoDatePickerMode.dateAndTime,
          onDateTimeChanged: (dateTime) {

          }
        ),
      );
    },
  );
}


Widget build(BuildContext context) {
  return FlatButton(
    onPressed: () {
      _handleClickMe();
    },
    child: Text(
      "CLICK ME!",
    ),
  );
}

Related Links