Last updated:
0 purchases
bilions ui
Bilions Flutter UI #
Documentation Here
Functions #
Alert #
alert(
context,
'Title here',
'Description here',
variant: Variant.warning,
)
copied to clipboard
Toast #
toast(context, 'Confirmed', variant: Variant.success);
copied to clipboard
Confirm Dialog #
confirm(
context,
ConfirmDialog(
'Are you sure?',
message: 'Are you sure to delete?'
variant : Variant.warning,
confirmed: () {
// do something here
},
),
)
copied to clipboard
Image Picker #
openUploader(
context,
variant: 'primary',
onPicked: (FileInfo file) {
console.log(file.path);
},
);
copied to clipboard
Add below lines in ios/Runner/info.plist
<key>NSPhotoLibraryUsageDescription</key>
<string>Allow Image access to upload your profile image</string>
<key>NSCameraUsageDescription</key>
<string>Allow Image access to upload your profile image</string>
copied to clipboard
Image Preview #
preview([
'https://picsum.photos/id/237/536/354',
'https://picsum.photos/id/238/536/354',
'https://picsum.photos/id/239/536/354',
])
copied to clipboard
Menu #
menu(
context,
MenuList([
MenuListItem(
Icon(
Icons.edit,
size: 20,
),
title: 'Edit',
onPressed: () {
// do something
},
),
])
)
copied to clipboard
Components #
DatePicker Input #
BilionsDatePicker(label: 'Date of Birth', onChanged: (date) => {}),
copied to clipboard
DateRangePicker Input #
BilionsDateRangePicker(
label: 'Date of Birth',
onChanged: (start, end) => {
},
),
copied to clipboard
TextInput #
BilionsTextInput(label: 'Full Name', onChanged: (text) => {})
copied to clipboard
Password Input #
BilionsPasswordInput(
label: 'Password',
onChanged: (value) => {},
variant: Variant.danger,
)
copied to clipboard
Avatar Image #
Avatar(
'https://i.pravatar.cc/150?img=3',
title: 'Zin Kyaw Kyaw',
subTitle: '[email protected]',
)
copied to clipboard
Image Slider #
ImageSlider([
'https://picsum.photos/id/237/536/354',
'https://picsum.photos/id/238/536/354',
'https://picsum.photos/id/239/536/354',
])
copied to clipboard
Buttons #
Primary Button
PrimaryButton(
'Button Title',
variant : Variant.success,
onPressed: () {
// do something
},
)
copied to clipboard
Secondary Button
SecondaryButton(
'Button Title',
variant : Variant.success,
onPressed: () {
// do something
},
)
copied to clipboard
Alert Widget #
BilionsAlert(
'Wake Up',
'You need to code flutter',
icon: Icon(Icons.alarm),
)
copied to clipboard
Card #
CardWidget(
header: const Avatar(
'https://i.pravatar.cc/150?img=3',
title: 'Zin Kyaw Kyaw',
subTitle: '[email protected]',
),
body: Column(
children: const [
Span(
"Lorem Ipsum is simply dummy text of the printing and variantsetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of variant and scrambled it to make a variant specimen book. It has survived not only five centuries, but also the leap into electronic variantsetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.",
)
],
),
footer: const Text('This is footer'),
)
copied to clipboard
Table #
BilionsTable(
variant: Variant.success,
widths: const [50, 30],
header: const [
TextLeft('Name', color: Colors.green, bold: true),
TextCenter('Rank', color: Colors.green, bold: true),
TextRight('Price', color: Colors.green, bold: true),
],
body: const [
[TextLeft('Ajay Pillai'), TextCenter('1'), TextRight('1000')],
[TextLeft('Kumar Sharno'), TextCenter('2'), TextRight('1000')],
[TextLeft('Anju Skk'), TextCenter('3'), TextRight('1000')],
[TextLeft('Zin Kyaw Kyaw'), TextCenter('4'), TextRight('1000')],
],
),
copied to clipboard
Utils #
Date formatter #
get current date time now() will return Current DateTime instance
format date to string moment.dateToString(now()) will return formatted string date
format date to string moment(now()).format(format: 'dd MMM yyyy') will return formatted string date
format date to string moment('2022-11-22').parse() will return DateTime instance
Theme Colors #
BilionsColor.primary
BilionsColor.primaryLight
BilionsColor.warning
BilionsColor.warningLight
BilionsColor.danger
BilionsColor.dangerLight
BilionsColor.info
BilionsColor.infoLight
BilionsColor.success
BilionsColor.successLight
copied to clipboard
Variants #
Variant.primary
Variant.warning
Variant.danger
Variant.info
Variant.success
copied to clipboard
Theme Color configuration #
Want to set your own colors?
You can set your own colors in main() function
void main() {
BilionsUI bilionsUI = BilionsUI();
bilionsUI.setColors(
ColorConfig(
danger: Colors.red,
primary: Colors.blue,
success: Colors.green,
warning: Colors.yellow,
info: Colors.purple,
),
);
runApp(const MyApp());
}
copied to clipboard
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.