const constructure
This commit is contained in:
@@ -13,7 +13,9 @@ class _PrinterBluetoothDialogState extends State<PrinterBluetoothDialog> {
|
||||
@override
|
||||
void initState() {
|
||||
loadPermissionBluetooth();
|
||||
context.read<BluetoothLoaderBloc>().add(BluetoothLoaderEvent.fetched());
|
||||
context.read<BluetoothLoaderBloc>().add(
|
||||
const BluetoothLoaderEvent.fetched(),
|
||||
);
|
||||
super.initState();
|
||||
}
|
||||
|
||||
@@ -21,13 +23,13 @@ class _PrinterBluetoothDialogState extends State<PrinterBluetoothDialog> {
|
||||
Widget build(BuildContext context) {
|
||||
return CustomModalDialog(
|
||||
title: 'Bluetooth',
|
||||
contentPadding: EdgeInsets.all(16),
|
||||
contentPadding: const EdgeInsets.all(16),
|
||||
minHeight: context.deviceHeight * 0.6,
|
||||
minWidth: context.deviceWidth * 0.4,
|
||||
child: BlocBuilder<BluetoothLoaderBloc, BluetoothLoaderState>(
|
||||
builder: (context, state) {
|
||||
if (state.isFetching) {
|
||||
return Center(child: LoaderWithText());
|
||||
return const Center(child: LoaderWithText());
|
||||
}
|
||||
|
||||
if (state.bluetoothDevices.isEmpty) {
|
||||
@@ -50,7 +52,7 @@ class _PrinterBluetoothDialogState extends State<PrinterBluetoothDialog> {
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
padding: const EdgeInsets.symmetric(vertical: 12),
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
border: Border(
|
||||
bottom: BorderSide(color: AppColor.border, width: 1),
|
||||
),
|
||||
@@ -66,7 +68,7 @@ class _PrinterBluetoothDialogState extends State<PrinterBluetoothDialog> {
|
||||
color: AppColor.primary,
|
||||
),
|
||||
),
|
||||
SpaceHeight(4),
|
||||
const SpaceHeight(4),
|
||||
Text(
|
||||
item.macAdress,
|
||||
style: AppStyle.sm.copyWith(
|
||||
|
||||
Reference in New Issue
Block a user