import 'package:flutter/material.dart'; import '../theme.dart'; import '../l10n/app_localizations.dart'; class StorePage extends StatelessWidget { const StorePage({super.key}); @override Widget build(BuildContext context) { final l10n = AppLocalizations.of(context)!; return Scaffold( backgroundColor: AppColors.background, appBar: AppBar(title: Text(l10n.storeList)), body: ListView( padding: const EdgeInsets.all(20), children: [ _buildStoreCard( name: '智念度假酒店', address: '浙江省杭州市西湖区灵隐路18号', phone: '0571-88888888', status: l10n.open, type: l10n.hotel, imageColor: const Color(0xFF1A56DB), icon: Icons.hotel, ), const SizedBox(height: 16), _buildStoreCard( name: '智念风景区', address: '浙江省杭州市西湖区龙井路88号', phone: '0571-88888899', status: l10n.openScenic, type: l10n.scenic, imageColor: const Color(0xFF10B981), icon: Icons.park, ), const SizedBox(height: 16), _buildStoreCard( name: '智念SPA养生中心', address: '浙江省杭州市西湖区杨公堤12号', phone: '0571-88888877', status: l10n.open, type: l10n.spa, imageColor: const Color(0xFFEC4899), icon: Icons.spa, ), ], ), ); } Widget _buildStoreCard({ required String name, required String address, required String phone, required String status, required String type, required Color imageColor, required IconData icon, }) { return Container( padding: const EdgeInsets.all(20), decoration: BoxDecoration( color: AppColors.surface, borderRadius: BorderRadius.circular(20), boxShadow: [ BoxShadow( color: Colors.black.withOpacity(0.04), blurRadius: 12, offset: const Offset(0, 4), ), ], ), child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Row( children: [ Container( width: 56, height: 56, decoration: BoxDecoration( color: imageColor.withOpacity(0.1), borderRadius: BorderRadius.circular(14), ), child: Icon(icon, color: imageColor, size: 28), ), const SizedBox(width: 16), Expanded( child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ Text( name, style: TextStyle( fontSize: 17, fontWeight: FontWeight.w600, color: AppColors.textPrimary, ), ), const SizedBox(height: 6), Row( children: [ Container( padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 3), decoration: BoxDecoration( color: AppColors.success.withOpacity(0.1), borderRadius: BorderRadius.circular(20), ), child: Text( status, style: const TextStyle( fontSize: 11, color: AppColors.success, fontWeight: FontWeight.w500, ), ), ), const SizedBox(width: 8), Container( padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 3), decoration: BoxDecoration( color: AppColors.background, borderRadius: BorderRadius.circular(20), ), child: Text( type, style: TextStyle( fontSize: 11, color: AppColors.textSecondary, ), ), ), ], ), ], ), ), Icon(Icons.chevron_right, color: AppColors.textTertiary), ], ), const Divider(height: 24), _buildInfoRow(Icons.location_on_outlined, address), const SizedBox(height: 8), _buildInfoRow(Icons.phone_outlined, phone), ], ), ); } Widget _buildInfoRow(IconData icon, String text) { return Row( children: [ Icon(icon, size: 16, color: AppColors.textTertiary), const SizedBox(width: 8), Expanded( child: Text( text, style: TextStyle(fontSize: 13, color: AppColors.textSecondary), ), ), ], ); } }