refactor(cleanup): 사용하지 않는 코드 정리

## 삭제된 파일

### 미사용 예외 클래스
- lib/core/errors/app_exceptions.dart
- lib/core/errors/data_exceptions.dart
  - 정의만 되어 있고 실제 코드에서 사용되지 않음
  - network_exceptions.dart는 활발히 사용 중이므로 유지

### 미사용 공통 위젯
- lib/core/widgets/empty_state_widget.dart
- lib/core/widgets/loading_indicator.dart
  - 정의만 되어 있고 다른 화면에서 import하지 않음
  - error_widget.dart는 share_screen에서 사용 중이므로 유지

### 미사용 디버그 위젯
- lib/presentation/pages/calendar/widgets/debug_test_data_banner.dart
  - 테스트 데이터 배너 위젯이지만 calendar_screen에서 사용하지 않음

### 백업 파일
- lib/data/api/naver_api_client.dart.backup
- lib/presentation/pages/restaurant_list/widgets/add_restaurant_dialog.dart.backup
  - 불필요한 백업 파일 정리

## 검증
- flutter analyze 통과
This commit is contained in:
JiWoong Sul
2025-12-22 19:45:22 +09:00
parent 42c609c57a
commit 32e25aeb07
7 changed files with 0 additions and 2092 deletions

View File

@@ -1,92 +0,0 @@
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:lunchpick/core/constants/app_colors.dart';
import 'package:lunchpick/core/constants/app_typography.dart';
import 'package:lunchpick/presentation/providers/debug_test_data_provider.dart';
class DebugTestDataBanner extends ConsumerWidget {
final EdgeInsetsGeometry? margin;
const DebugTestDataBanner({super.key, this.margin});
@override
Widget build(BuildContext context, WidgetRef ref) {
if (!kDebugMode) {
return const SizedBox.shrink();
}
final isDark = Theme.of(context).brightness == Brightness.dark;
final state = ref.watch(debugTestDataNotifierProvider);
final notifier = ref.read(debugTestDataNotifierProvider.notifier);
return Card(
margin: margin ?? const EdgeInsets.all(16),
color: isDark ? AppColors.darkSurface : AppColors.lightSurface,
elevation: 1,
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(12)),
child: Padding(
padding: const EdgeInsets.all(12),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
const Icon(
Icons.science_outlined,
color: AppColors.lightPrimary,
size: 20,
),
const SizedBox(width: 8),
Text(
'테스트 데이터 미리보기',
style: AppTypography.body1(
isDark,
).copyWith(fontWeight: FontWeight.w600),
),
const Spacer(),
if (state.isProcessing)
const SizedBox(
width: 20,
height: 20,
child: CircularProgressIndicator(strokeWidth: 2),
),
const SizedBox(width: 8),
Switch.adaptive(
value: state.isEnabled,
onChanged: state.isProcessing
? null
: (value) async {
if (value) {
await notifier.enableTestData();
} else {
await notifier.disableTestData();
}
},
activeColor: AppColors.lightPrimary,
),
],
),
const SizedBox(height: 8),
Text(
state.isEnabled
? '디버그 빌드에서만 적용됩니다. 기록/통계 UI를 테스트용 데이터로 확인하세요.'
: '디버그 빌드에서만 사용 가능합니다. 스위치를 켜면 추천·방문 기록이 자동으로 채워집니다.',
style: AppTypography.caption(isDark),
),
if (state.errorMessage != null) ...[
const SizedBox(height: 6),
Text(
state.errorMessage!,
style: AppTypography.caption(isDark).copyWith(
color: AppColors.lightError,
fontWeight: FontWeight.w600,
),
),
],
],
),
),
);
}
}