fix: small ui change

This commit is contained in:
alzalia1 2025-08-14 01:08:55 +02:00
parent 618764f513
commit d16d1e2778
2 changed files with 24 additions and 13 deletions

View file

@ -28,7 +28,7 @@ class SellViewModel extends ChangeNotifier {
*/ */
final List<BookInstance> _scannedBooks = []; final List<BookInstance> _scannedBooks = [];
get scannedBooks => _scannedBooks; List<BookInstance> get scannedBooks => _scannedBooks;
void scanBook(BarcodeCapture barcode) { void scanBook(BarcodeCapture barcode) {
final addedBook = BookInstance( final addedBook = BookInstance(
balId: 5, balId: 5,

View file

@ -62,10 +62,19 @@ class _SellPageState extends State<SellPage> {
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
crossAxisAlignment: CrossAxisAlignment.center, crossAxisAlignment: CrossAxisAlignment.center,
children: [ children: [
SizedBox(height: 6), Center(
child: Text(
"Livres dans la vente actuelle",
style: TextStyle(fontSize: 20),
),
),
SizedBox(height: 15),
Expanded( Expanded(
child: ListView( child: ListView(
children: [ children: [
(widget.viewModel.scannedBooks.isEmpty)
? Center(child: Text("Aucun"))
: SizedBox(),
for (BookInstance bookInstance for (BookInstance bookInstance
in widget.viewModel.scannedBooks) in widget.viewModel.scannedBooks)
Padding( Padding(
@ -99,18 +108,20 @@ class _SellPageState extends State<SellPage> {
), ),
), ),
SizedBox(height: 40), SizedBox(height: 40),
Text("Somme minimum requise : 20€"), Text("Montant minimum à payer : 20€"),
SizedBox( Padding(
width: 400, padding: const EdgeInsets.symmetric(horizontal: 60.0),
child: TextField( child: SizedBox(
decoration: InputDecoration( child: TextField(
labelText: "Argent reçu", decoration: InputDecoration(
helperText: labelText: "Argent reçu",
"L'argent reçu sera réparti automatiquement", helperText:
suffixText: "", "L'argent reçu sera réparti automatiquement",
border: OutlineInputBorder(), suffixText: "",
border: OutlineInputBorder(),
),
keyboardType: TextInputType.number,
), ),
keyboardType: TextInputType.number,
), ),
), ),
SizedBox(height: 10), SizedBox(height: 10),