Last updated:
0 purchases
kd utils
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';
copied to clipboard
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
copied to clipboard
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);
},
),
copied to clipboard
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(),
)
copied to clipboard
Extension methos #
Widgets Extension
200.height,
10.width,
copied to clipboard
Context Extension
ThemeData themeData = context.theme;
EdgeInsets padding = context.viewPadding;
Size screenSize = context.screenSize;
double screenWidth = context.screenWidth;
double screenHeight = context.screenHeight;
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.