My Utils
A My_Utils is make to help developers to fast and smooth coding experience with helping widget and method in flutter
Get Started
import 'package:kd_utils/kd_utils.dart';
TimeStamp
Usage.
final DateTime date = timeStampToDateTime("1694160861");
print(date); // 2023-09-08 13:44:21.000
final weekDay = getWeekDay(1, short: true);
print(weekDay); // Mon
Date Picker

Usage.
DatePickerView(
currentDate: DateTime.now(),
startDate: DateTime.now().subtract(Duration(days: 50)),
endDate: DateTime.now().add(Duration(days: 50)),
weekday: TextStyle(fontSize: 12, fontWeight: FontWeight.bold),
decoration: BoxDecoration(borderRadius: BorderRadius.circular(10)),
onDateClick: (selectedDate) {
print(selectedDate);
},
),
OTP View
Usage.
OTPView(
otpCount: 5,
style: OTPStyle(
cursorColor: Colors.green,
maxHeight: 60,
inputBorder: OutlineInputBorder(
borderRadius: BorderRadius.circular(8),
borderSide: BorderSide(
color: Colors.green,
width: 3,
),
),
isDense: true,
space: 20),
onSubmit: (otp) {
log(otp.toString());
},
controller: TextEditingController(),
)
Extension methos
Widgets Extension
200.height,
10.width,
Context Extension
ThemeData themeData = context.theme;
EdgeInsets padding = context.viewPadding;
Size screenSize = context.screenSize;
double screenWidth = context.screenWidth;
double screenHeight = context.screenHeight;
Libraries
- api_service/api_enum
- api_service/api_service_lib
- api_service/exceptions/exceptions
- custom_painters/dot_line_painter
- extensions/extensions
- kd_utils
- methods/get_week_day
- methods/show_snack_bar
- methods/time_stamp
- widgets/date_picker/date_picker_state
- widgets/date_picker/date_picker_view
- widgets/otp_widget/otp_state
- widgets/otp_widget/otp_view
- widgets/otp_widget/widget/otp_felid