47 lines
1.6 KiB
Dart
47 lines
1.6 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:lucide_icons/lucide_icons.dart';
|
|
import '../../theme/app_colors.dart';
|
|
|
|
class HomeEmptyState extends StatelessWidget {
|
|
final bool isMenuMode;
|
|
|
|
const HomeEmptyState({
|
|
super.key,
|
|
this.isMenuMode = false,
|
|
});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
final appColors = Theme.of(context).extension<AppColors>()!;
|
|
|
|
return Center(
|
|
child: Column(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
isMenuMode
|
|
? Icon(LucideIcons.scrollText, size: 80, color: appColors.brandPrimary.withValues(alpha: 0.5))
|
|
: const Text('🍶', style: TextStyle(fontSize: 80)),
|
|
const SizedBox(height: 16),
|
|
Text(
|
|
isMenuMode ? 'お品書きに載せる日本酒がありません' : '日本酒のラベルを撮ってみましょう',
|
|
style: Theme.of(context).textTheme.titleLarge?.copyWith(
|
|
color: appColors.textPrimary,
|
|
fontWeight: FontWeight.bold
|
|
),
|
|
),
|
|
const SizedBox(height: 8),
|
|
Text(
|
|
isMenuMode
|
|
? 'まずはホーム画面に戻って、\n日本酒を登録してください'
|
|
: '右下のカメラボタンから「瞬撮」できます!\n長押しでギャラリーから追加もできます',
|
|
textAlign: TextAlign.center,
|
|
style: Theme.of(context).textTheme.bodyMedium?.copyWith(
|
|
color: appColors.textSecondary,
|
|
),
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|