Perbarui tampilan di beberapa view untuk meningkatkan konsistensi dan pengalaman pengguna. Ganti penggunaan parameter key dengan super.key di beberapa widget. Tambahkan pengecekan null pada data pengaduan untuk mencegah kesalahan saat menampilkan informasi. Modifikasi beberapa metode untuk menyederhanakan kode dan meningkatkan keterbacaan.

This commit is contained in:
Khafidh Fuadi
2025-03-19 09:36:58 +07:00
parent 7ee56903ee
commit 984b8336f0
140 changed files with 19314 additions and 122 deletions

View File

@ -7,11 +7,11 @@ class AppBottomNavigationBar extends StatelessWidget {
final List<AppBottomNavigationBarItem> items;
const AppBottomNavigationBar({
Key? key,
super.key,
required this.currentIndex,
required this.onTap,
required this.items,
}) : super(key: key);
});
@override
Widget build(BuildContext context) {

View File

@ -12,7 +12,7 @@ class AppDrawer extends StatelessWidget {
final List<DrawerMenuItem> menuItems;
const AppDrawer({
Key? key,
super.key,
required this.nama,
required this.role,
this.desa,
@ -20,7 +20,7 @@ class AppDrawer extends StatelessWidget {
this.notificationCount,
required this.onLogout,
required this.menuItems,
}) : super(key: key);
});
@override
Widget build(BuildContext context) {

View File

@ -1,5 +1,4 @@
import 'package:flutter/material.dart';
import 'package:get/get.dart';
import 'package:intl/intl.dart';
import 'package:penyaluran_app/app/data/models/penerima_penyaluran_model.dart';
import 'package:penyaluran_app/app/widgets/status_badge.dart';
@ -10,11 +9,11 @@ class BantuanCard extends StatelessWidget {
final bool isCompact;
const BantuanCard({
Key? key,
super.key,
required this.item,
this.onTap,
this.isCompact = false,
}) : super(key: key);
});
@override
Widget build(BuildContext context) {

View File

@ -9,14 +9,14 @@ class SectionHeader extends StatelessWidget {
final TextStyle? titleStyle;
const SectionHeader({
Key? key,
super.key,
required this.title,
this.onViewAll,
this.viewAllText = 'Lihat Semua',
this.trailing,
this.padding = const EdgeInsets.only(bottom: 4),
this.titleStyle,
}) : super(key: key);
});
@override
Widget build(BuildContext context) {
@ -38,11 +38,11 @@ class SectionHeader extends StatelessWidget {
else if (onViewAll != null)
TextButton(
onPressed: onViewAll,
child: Text(viewAllText!),
style: TextButton.styleFrom(
padding: const EdgeInsets.symmetric(horizontal: 8),
minimumSize: const Size(0, 36),
),
child: Text(viewAllText!),
),
],
),

View File

@ -8,13 +8,13 @@ class StatusBadge extends StatelessWidget {
final EdgeInsets padding;
const StatusBadge({
Key? key,
super.key,
required this.status,
this.customColors,
this.customLabels,
this.fontSize = 12,
this.padding = const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
}) : super(key: key);
});
@override
Widget build(BuildContext context) {