smoothdatepicker 0.0.3 copy "smoothdatepicker: ^0.0.3" to clipboard
smoothdatepicker: ^0.0.3 copied to clipboard

outdated

Horizontal and vertical date picker in Flutter, with the ability to change the scroll and card direction in any combination

example/main.dart

import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
import 'package:smoothdatepicker/smoothdatepicker.dart';


void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      title: 'SQFlite Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  // reference to our single class that manages the database
  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {


  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Color.fromRGBO(63, 136, 197, 1),
      body: Column(
        mainAxisAlignment: MainAxisAlignment.center,
        children: <Widget>[

          Text(time.toString()),

          HDatePicker(
            scrollDirection: Axis.horizontal,
            cardDirection: Axis.horizontal,
            mainColor: Colors.blue,
            secondColor: Colors.yellow,
            onSelectionChanged: (selectedDate){
              setState(() {
                time = selectedDate;
              });
            },

          ),
        ],
      ),
    );
  }
}

DateTime time = DateTime.now();
10
likes
40
pub points
0%
popularity

Publisher

unverified uploader

Horizontal and vertical date picker in Flutter, with the ability to change the scroll and card direction in any combination

Repository (GitHub)
View/report issues

License

MIT (LICENSE)

Dependencies

flutter, vibration

More

Packages that depend on smoothdatepicker