criado widgets dropdown_with_subtitle.dart, input_with_subtitle.dart, onbackbutton.dart, switch_with_subtitle.dart

criada as telas main_register_citizen_screen.dart e main_procedures_screen.dart
This commit is contained in:
Reginaldo
2023-03-24 22:54:42 -03:00
parent 9677a9ce71
commit 13e9eb4b24
13 changed files with 1550 additions and 40 deletions

View File

@@ -0,0 +1,35 @@
import 'package:flutter/material.dart';
import 'package:rkm/widgets/text_default.dart';
import '../utils/color_palette.dart';
import 'button_default.dart';
class OnBackButton{
onBackButton(context)async {
bool exiApp = await showDialog(
context: context,
builder: (context){
return AlertDialog(
title: TextDefault(text: 'Aviso',color: ColorPalette.black54,textAlign: TextAlign.center,),
content: TextDefault(text: 'Deseja sair e descartar as alterações?',color: ColorPalette.black54,),
actions: [
ButtonDefault(
onPressed: ()=>Navigator.pushNamedAndRemoveUntil(context, '/home', (route) => false),
title: 'Sim',
background: ColorPalette.appBar,
borderColor: ColorPalette.appBar,
textColor: ColorPalette.white,
),
ButtonDefault(
onPressed: ()=>Navigator.of(context).pop(false),
title: 'Não',
background: ColorPalette.white,
borderColor: ColorPalette.white,
textColor: ColorPalette.black54,
),
],
);
}
);
}
}