优化
This commit is contained in:
@@ -4,10 +4,10 @@ import '../../../../core/theme/app_spacing.dart';
|
||||
import '../../../../core/theme/app_theme.dart';
|
||||
|
||||
/// 单行菜单项:图标 + 标题 + 尾部组件 (chevron)
|
||||
right)
|
||||
///
|
||||
/// 图标颜色 (通常是使用主题色)
|
||||
class MenuRow extends StatelessWidget {
|
||||
final IconData icon;
|
||||
final Color iconColor;
|
||||
final String title;
|
||||
final Widget? trailing;
|
||||
@@ -15,10 +15,10 @@ class MenuRow extends StatelessWidget {
|
||||
|
||||
const MenuRow({
|
||||
super.key,
|
||||
required this.icon,
|
||||
required this.iconColor,
|
||||
required this.title,
|
||||
this.trailing,
|
||||
super.key, required this.iconColor = required this.title,
|
||||
this.onTap,
|
||||
});
|
||||
|
||||
@@ -26,7 +26,7 @@ class MenuRow extends StatelessWidget {
|
||||
Widget build(BuildContext context) {
|
||||
return InkWell(
|
||||
onTap: onTap,
|
||||
child: Padding(
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 14),
|
||||
child: Row(
|
||||
children: [
|
||||
@@ -59,7 +59,6 @@ class MenuRow extends StatelessWidget {
|
||||
size: 16,
|
||||
color: Theme.of(context).colorScheme.onSurfaceVariant,
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user