From 4218c0cf85c6b3ba8af490795a105ed66f94abff Mon Sep 17 00:00:00 2001 From: Moe <moe@chocola.dev> Date: Wed, 27 Apr 2022 17:16:07 +0700 Subject: [PATCH] Cleanup code --- lib/components/payment_body.dart | 20 ++++++++++---------- lib/components/transaction_box.dart | 3 --- lib/screens/transactions.dart | 1 - 3 files changed, 10 insertions(+), 14 deletions(-) diff --git a/lib/components/payment_body.dart b/lib/components/payment_body.dart index 629bfcf..9e45095 100644 --- a/lib/components/payment_body.dart +++ b/lib/components/payment_body.dart @@ -17,7 +17,7 @@ class _PaymentBodyState extends State<PaymentBody> { shrinkWrap: true, children: [ Container( - padding: EdgeInsets.only(top: 40, bottom: 30), + padding: const EdgeInsets.only(top: 40, bottom: 30), child: Row( mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ @@ -44,11 +44,11 @@ class _PaymentBodyState extends State<PaymentBody> { collapsedBackgroundColor: Colors.blue.shade800, textColor: Colors.white, collapsedTextColor: Colors.white, - title: Text('BCA'), - children: [ + title: const Text('BCA'), + children: const [ ListTile( textColor: Colors.white, - title: const Text( + title: Text( '1. Login pada alamat Internet Banking BCA (***) \n2. Pilih menu Pembayaran Tagihan > Pembayaran \n3. Pada Ke Rekening masukkan Rekening perusahaan \n4. Masukkan Jumlah Nominal yang akan ditransfer \n5. Kemudian tekan send. Cetak/simpan stuck Transfer sebagai bukti pembayaran'), ) ], @@ -58,11 +58,11 @@ class _PaymentBodyState extends State<PaymentBody> { collapsedBackgroundColor: Colors.blue.shade800, textColor: Colors.white, collapsedTextColor: Colors.white, - title: Text('BNI'), - children: [ + title: const Text('BNI'), + children: const [ ListTile( textColor: Colors.white, - title: const Text( + title: Text( '1. Login pada alamat Internet Banking BNI (***)\n2. Pilih menu Pembayaran Tagihan > Pembayaran > Antar Rekening\n3. Pada Ke Rekening masukkan Rekening perusahaan\n4. Masukkan Jumlah Nominal yang akan ditransfer\n5. Kemudian tekan send. Cetak/simpan stuck Transfer sebagai bukti pembayaran'), ) ], @@ -72,11 +72,11 @@ class _PaymentBodyState extends State<PaymentBody> { collapsedBackgroundColor: Colors.blue.shade800, textColor: Colors.white, collapsedTextColor: Colors.white, - title: Text('BRI'), - children: [ + title: const Text('BRI'), + children: const [ ListTile( textColor: Colors.white, - title: const Text( + title: Text( '1. Login pada alamat Internet Banking BRI (***)\n2. Pilih menu Pembayaran Tagihan > Pembayaran > Antar Rekening\n3. Pada Ke Rekening masukkan Rekening perusahaan\n4. Masukkan Jumlah Nominal yang akan ditransfer\n5. Kemudian tekan send. Cetak/simpan stuck Transfer sebagai bukti pembayaran'), ) ], diff --git a/lib/components/transaction_box.dart b/lib/components/transaction_box.dart index f32325f..5c184eb 100644 --- a/lib/components/transaction_box.dart +++ b/lib/components/transaction_box.dart @@ -1,5 +1,4 @@ import 'dart:convert'; -import 'package:cached_network_image/cached_network_image.dart'; import 'package:flutter/material.dart'; import 'package:nekoya_flutter/api/api.dart'; @@ -48,7 +47,6 @@ class _TransactionBoxState extends State<TransactionBox> { return ExpansionTile( backgroundColor: const Color(0xff212226), - // trailing: const Text('-', style: TextStyle(color: Colors.white),), iconColor: Colors.white, collapsedIconColor: Colors.white, title: Row( @@ -87,7 +85,6 @@ class _TransactionBoxState extends State<TransactionBox> { const Text('Logistic', style: TextStyle(color: Colors.white, fontSize: 14, fontWeight: FontWeight.w600),), const SizedBox(height: 5,), Text(widget.logistic, style: const TextStyle(color: Colors.white),), - // const SizedBox(height: 55,) ], ), ), diff --git a/lib/screens/transactions.dart b/lib/screens/transactions.dart index 522d59d..dba3863 100644 --- a/lib/screens/transactions.dart +++ b/lib/screens/transactions.dart @@ -43,7 +43,6 @@ class _TransactionsState extends State<Transactions> { logistic: data[index]['logistic'], data: data[index]['data'], ); - // return Text(data[index]['firstName'] + ' ' + data[index]['lastName'], style: const TextStyle(color: Colors.white),); } ); }