更新样式

This commit is contained in:
2026-02-10 13:37:24 +08:00
parent 10867178fa
commit 5364612a6f

View File

@@ -62,10 +62,10 @@ class _ReservationListBottomSheetState extends State<ReservationListBottomSheet>
return SingleChildScrollView( return SingleChildScrollView(
scrollDirection: Axis.horizontal, scrollDirection: Axis.horizontal,
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8), padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
child: Row( children: _statusOptions.entries.map((entry) { child: Row(
children: _statusOptions.entries.map((entry) {
bool isSelected = _selectedStatus == entry.key; bool isSelected = _selectedStatus == entry.key;
return GestureDetector( return GestureDetector(
// 关键点:增加 HitTestBehavior.opaque 扩大点击有效范围
behavior: HitTestBehavior.opaque, behavior: HitTestBehavior.opaque,
onTap: () { onTap: () {
if (_selectedStatus == entry.key) return; if (_selectedStatus == entry.key) return;
@@ -84,7 +84,7 @@ class _ReservationListBottomSheetState extends State<ReservationListBottomSheet>
decoration: BoxDecoration( decoration: BoxDecoration(
// 选中色使用深绿色,未选中保持纯白 // 选中色使用深绿色,未选中保持纯白
color: isSelected ? const Color(0xFF006633) : Colors.white, color: isSelected ? const Color(0xFF006633) : Colors.white,
borderRadius: BorderRadius.circular(25), // 圆角稍微调大一点更像胶囊 borderRadius: BorderRadius.circular(25),
boxShadow: [ boxShadow: [
BoxShadow( BoxShadow(
color: Colors.black.withOpacity(0.04), color: Colors.black.withOpacity(0.04),