feat: 글래스모피즘 디자인 시스템 및 색상 가이드 전면 적용

- @doc/color.md 가이드라인에 따른 색상 시스템 전면 개편
- 딥 블루(#2563EB), 스카이 블루(#60A5FA) 메인 컬러로 변경
- 모든 화면과 위젯에 글래스모피즘 효과 일관성 있게 적용
- darkNavy, navyGray 등 새로운 텍스트 색상 체계 도입
- 공통 스낵바 및 다이얼로그 컴포넌트 추가
- Claude AI 프로젝트 컨텍스트 파일(CLAUDE.md) 추가

영향받은 컴포넌트:
- 10개 스크린 (main, settings, detail, splash 등)
- 30개 이상 위젯 (buttons, cards, forms 등)
- 테마 시스템 (AppColors, AppTheme)

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
JiWoong Sul
2025-07-11 18:41:05 +09:00
parent 83c5e3d64e
commit 2f60ef585a
46 changed files with 1096 additions and 580 deletions

View File

@@ -9,6 +9,11 @@ import '../services/subscription_url_matcher.dart';
import 'package:intl/intl.dart'; // NumberFormat을 사용하기 위한 import 추가
import '../widgets/glassmorphism_card.dart';
import '../widgets/themed_text.dart';
import '../theme/app_colors.dart';
import '../widgets/common/snackbar/app_snackbar.dart';
import '../widgets/common/buttons/primary_button.dart';
import '../widgets/common/buttons/secondary_button.dart';
import '../widgets/common/form_fields/base_text_field.dart';
class SmsScanScreen extends StatefulWidget {
const SmsScanScreen({super.key});
@@ -352,41 +357,9 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
// 성공 메시지 표시
if (mounted) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Row(
children: [
const Icon(
Icons.check_circle,
color: Colors.white,
size: 20,
),
const SizedBox(width: 12),
Expanded(
child: Text(
'${subscription.serviceName} 구독이 추가되었습니다.',
style: const TextStyle(
fontSize: 16,
fontWeight: FontWeight.w500,
),
),
),
],
),
backgroundColor: const Color(0xFF10B981), // 초록색
behavior: SnackBarBehavior.floating,
margin: EdgeInsets.only(
top: MediaQuery.of(context).padding.top + 16, // 상단 여백
left: 16,
right: 16,
bottom: MediaQuery.of(context).size.height - 120, // 상단에 위치하도록 bottom 마진 설정
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(12),
),
duration: const Duration(seconds: 3),
dismissDirection: DismissDirection.horizontal,
),
AppSnackBar.showSuccess(
context: context,
message: '${subscription.serviceName} 구독이 추가되었습니다.',
);
}
@@ -395,12 +368,9 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
} catch (e) {
print('구독 추가 중 오류 발생: $e');
if (mounted) {
ScaffoldMessenger.of(context).showSnackBar(
SnackBar(
content: Text('구독 추가 중 오류가 발생했습니다: $e'),
backgroundColor: Colors.red,
duration: const Duration(seconds: 2),
),
AppSnackBar.showError(
context: context,
message: '구독 추가 중 오류가 발생했습니다: $e',
);
// 오류가 있어도 다음 구독으로 이동
@@ -411,6 +381,16 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
// 현재 구독 건너뛰기
void _skipCurrentSubscription() {
final subscription = _scannedSubscriptions[_currentIndex];
if (mounted) {
AppSnackBar.showInfo(
context: context,
message: '${subscription.serviceName} 구독을 건너뛰었습니다.',
icon: Icons.skip_next_rounded,
);
}
_moveToNextSubscription();
}
@@ -434,12 +414,9 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
navigationProvider.updateCurrentIndex(0);
// 완료 메시지 표시
ScaffoldMessenger.of(context).showSnackBar(
const SnackBar(
content: Text('모든 구독이 처리되었습니다.'),
backgroundColor: Colors.green,
duration: Duration(seconds: 2),
),
AppSnackBar.showSuccess(
context: context,
message: '모든 구독이 처리되었습니다.',
);
}
@@ -530,15 +507,17 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
// 로딩 상태 UI
Widget _buildLoadingState() {
return const Center(
return Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
CircularProgressIndicator(),
SizedBox(height: 16),
ThemedText('SMS 메시지를 스캔 중입니다...'),
SizedBox(height: 8),
ThemedText('구독 서비스를 찾고 있습니다', opacity: 0.7),
CircularProgressIndicator(
valueColor: AlwaysStoppedAnimation<Color>(AppColors.primaryColor),
),
const SizedBox(height: 16),
const ThemedText('SMS 메시지를 스캔 중입니다...', forceDark: true),
const SizedBox(height: 8),
const ThemedText('구독 서비스를 찾고 있습니다', opacity: 0.7, forceDark: true),
],
),
);
@@ -564,6 +543,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'2회 이상 결제된 구독 서비스 찾기',
fontSize: 20,
fontWeight: FontWeight.bold,
forceDark: true,
),
const SizedBox(height: 16),
const Padding(
@@ -572,16 +552,17 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'문자 메시지를 스캔하여 반복적으로 결제된 구독 서비스를 자동으로 찾습니다. 서비스명과 금액을 추출하여 쉽게 구독을 추가할 수 있습니다.',
textAlign: TextAlign.center,
opacity: 0.7,
forceDark: true,
),
),
const SizedBox(height: 32),
ElevatedButton.icon(
PrimaryButton(
text: '스캔 시작하기',
icon: Icons.search_rounded,
onPressed: _scanSms,
icon: const Icon(Icons.search),
label: const Text('스캔 시작하기'),
style: ElevatedButton.styleFrom(
padding: const EdgeInsets.symmetric(horizontal: 32, vertical: 12),
),
width: 200,
height: 56,
backgroundColor: AppColors.primaryColor,
),
],
),
@@ -591,9 +572,10 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
// 구독 표시 상태 UI
Widget _buildSubscriptionState() {
if (_currentIndex >= _scannedSubscriptions.length) {
return const Center(
child: ThemedText('모든 구독 처리 완료'),
);
// 처리 완료 후 초기 상태로 복귀
_scannedSubscriptions = [];
_currentIndex = 0;
return _buildInitialState(); // 스캔 버튼이 있는 초기 화면으로 돌아감
}
final subscription = _scannedSubscriptions[_currentIndex];
@@ -609,7 +591,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
// 진행 상태 표시
LinearProgressIndicator(
value: (_currentIndex + 1) / _scannedSubscriptions.length,
backgroundColor: Colors.grey.withValues(alpha: 0.2),
backgroundColor: AppColors.navyGray.withValues(alpha: 0.2),
valueColor: AlwaysStoppedAnimation<Color>(
Theme.of(context).colorScheme.primary),
),
@@ -618,6 +600,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'${_currentIndex + 1}/${_scannedSubscriptions.length}',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 24),
@@ -632,6 +615,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'다음 구독을 찾았습니다',
fontSize: 18,
fontWeight: FontWeight.bold,
forceDark: true,
),
const SizedBox(height: 24),
// 서비스명
@@ -639,12 +623,14 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'서비스명',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 4),
ThemedText(
subscription.serviceName,
fontSize: 22,
fontWeight: FontWeight.bold,
forceDark: true,
),
const SizedBox(height: 16),
@@ -659,6 +645,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'월 비용',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 4),
ThemedText(
@@ -675,6 +662,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
).format(subscription.monthlyCost),
fontSize: 18,
fontWeight: FontWeight.bold,
forceDark: true,
),
],
),
@@ -687,6 +675,7 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'반복 횟수',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 4),
ThemedText(
@@ -713,12 +702,14 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'결제 주기',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 4),
ThemedText(
subscription.billingCycle,
fontSize: 16,
fontWeight: FontWeight.w500,
forceDark: true,
),
],
),
@@ -731,12 +722,14 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
'결제일',
fontWeight: FontWeight.w500,
opacity: 0.7,
forceDark: true,
),
const SizedBox(height: 4),
ThemedText(
_getNextBillingText(subscription.nextBillingDate),
fontSize: 14,
fontWeight: FontWeight.w500,
forceDark: true,
),
],
),
@@ -746,17 +739,18 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
const SizedBox(height: 24),
// 웹사이트 URL 입력 필드 추가/수정
Padding(
padding: const EdgeInsets.all(8.0),
child: TextField(
controller: _websiteUrlController,
decoration: const InputDecoration(
labelText: '웹사이트 URL (자동 추출됨)',
hintText: '웹사이트 URL을 수정하거나 비워두세요',
prefixIcon: Icon(Icons.language),
border: OutlineInputBorder(),
),
BaseTextField(
controller: _websiteUrlController,
label: '웹사이트 URL (자동 추출됨)',
hintText: '웹사이트 URL을 수정하거나 비워두세요',
prefixIcon: Icon(
Icons.language,
color: AppColors.navyGray,
),
style: TextStyle(
color: AppColors.darkNavy,
),
fillColor: AppColors.pureWhite.withValues(alpha: 0.8),
),
const SizedBox(height: 32),
@@ -764,22 +758,18 @@ class _SmsScanScreenState extends State<SmsScanScreen> {
Row(
children: [
Expanded(
child: OutlinedButton(
child: SecondaryButton(
text: '건너뛰기',
onPressed: _skipCurrentSubscription,
style: OutlinedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 12),
),
child: const Text('건너뛰기'),
height: 48,
),
),
const SizedBox(width: 16),
Expanded(
child: ElevatedButton(
child: PrimaryButton(
text: '추가하기',
onPressed: _addCurrentSubscription,
style: ElevatedButton.styleFrom(
padding: const EdgeInsets.symmetric(vertical: 12),
),
child: const Text('추가하기'),
height: 48,
),
),
],