custom_scroll_date_range_picker 1.0.10 custom_scroll_date_range_picker: ^1.0.10 copied to clipboard
This package allows you to pick 'from' and 'to' dates in a convenient scrollable interface.
Here's a README template for your GitHub repository for the Custom Scroll Date Range Picker package:
Custom Scroll Date Range Picker #
Custom Scroll Date Range Picker is a Flutter package that allows users to easily select a date range using a scrollable and interactive interface. This package simplifies date selection by offering a smooth, intuitive user experience with day, month, and year precision.
Features #
- Scrollable Interface: Allows users to scroll through dates for quick and precise selection.
- Date Range Selection: Users can choose both the start and end dates in an easy-to-use interface.
- Customizable: Offers flexibility in design and layout to suit various project needs.
- Day, Month, and Year Navigation: Provides smooth scrolling between days, months, and years, making it easy to pick date ranges for any time period.
Video Demo #
Check out this video demonstration to see how the Custom Scroll Date Range Picker works in action.
Installation #
To use this package, add custom_scroll_date_range_picker
to your pubspec.yaml
:
dependencies:
flutter:
sdk: flutter
custom_scroll_date_range_picker: ^1.0.0
Then, run flutter pub get
to install the package.
Usage #
Import the package:
import 'package:custom_scroll_date_range_picker/custom_scroll_date_range_picker.dart';
Create the Custom Scroll Date Range Picker widget in your app:
CustomScrollDateRangePicker(
startDate: DateTime.now(),
endDate: DateTime.now().add(Duration(days: 30)),
onDateRangeSelected: (DateTime start, DateTime end) {
print('Selected range: $start to $end');
},
);
Example #
import 'package:flutter/material.dart';
import 'package:custom_scroll_date_range_picker/custom_scroll_date_range_picker.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(title: Text('Custom Scroll Date Range Picker')),
body: Center(
child: CustomScrollDateRangePicker(
startDate: DateTime.now(),
endDate: DateTime.now().add(Duration(days: 30)),
onDateRangeSelected: (DateTime start, DateTime end) {
print('Selected range: $start to $end');
},
),
),
),
);
}
}
License #
This package is open-source and available under the MIT License.
For more information, visit the Custom Scroll Date Range Picker on Pub.dev.
This README includes the core information needed for users to understand and integrate the Custom Scroll Date Range Picker into their projects, along with visual examples and installation instructions.