diff --git a/lib/src/ui/ui_services/ui_proofs/list_of_service_proofs.dart b/lib/src/ui/ui_services/ui_proofs/list_of_service_proofs.dart index c216696e..87a41c6c 100644 --- a/lib/src/ui/ui_services/ui_proofs/list_of_service_proofs.dart +++ b/lib/src/ui/ui_services/ui_proofs/list_of_service_proofs.dart @@ -34,39 +34,13 @@ class ListOfServiceProofs extends ConsumerWidget { // // > header // - Center( - child: Column( - children: [ - const Padding( - padding: EdgeInsets.all(8), - child: Divider(), - ), - Text( - tr().optional, - textAlign: TextAlign.center, - style: Theme.of(context).textTheme.headlineMedium, - ), - Text( - tr().proofOfService, - textAlign: TextAlign.center, - style: Theme.of(context).textTheme.headlineSmall, - ), - Padding( - padding: const EdgeInsets.all(8), - child: Text( - tr().makeProofOfService, - textAlign: TextAlign.center, - ), - ), - ], - ), - ), + const _ProofsHeaderText(), // - // > Display list of proofs in columns + // > display list of proofs in columns // const ProofsBuilder(), // - // > add new record(proof row) button + // > button to add new proof (new row) // FloatingActionButton( onPressed: proofController.addProof, @@ -77,6 +51,41 @@ class ListOfServiceProofs extends ConsumerWidget { } } +class _ProofsHeaderText extends StatelessWidget { + const _ProofsHeaderText(); + + @override + Widget build(BuildContext context) { + return Center( + child: Column( + children: [ + const Padding( + padding: EdgeInsets.all(8), + child: Divider(), + ), + Text( + tr().optional, + textAlign: TextAlign.center, + style: Theme.of(context).textTheme.headlineMedium, + ), + Text( + tr().proofOfService, + textAlign: TextAlign.center, + style: Theme.of(context).textTheme.headlineSmall, + ), + Padding( + padding: const EdgeInsets.all(8), + child: Text( + tr().makeProofOfService, + textAlign: TextAlign.center, + ), + ), + ], + ), + ); + } +} + /// Display list of proofs in two columns. /// /// If there is missing image - display add button [AddProofButton].