feat: complete academic symbol lexicon heal, 2-column Cooper extraction, and updated assets
This commit is contained in:
+36
-22
@@ -1,12 +1,19 @@
|
||||
import 'screens/divination_hub_screen.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'screens/catalog_screen.dart';
|
||||
import 'screens/history_screen.dart';
|
||||
import 'screens/home_search_screen.dart';
|
||||
import 'screens/oracle_chat_screen.dart';
|
||||
import 'screens/houses_field_screen.dart';
|
||||
import 'screens/provider_bakeoff_screen.dart';
|
||||
import 'screens/settings_screen.dart';
|
||||
import 'services/lenormand_pairs_repository.dart';
|
||||
import 'services/ogham_feda_repository.dart';
|
||||
import 'services/tarot_majors_repository.dart';
|
||||
import 'services/settings_repository.dart';
|
||||
import 'services/traditions_repository.dart';
|
||||
import 'services/words_repository.dart';
|
||||
import 'services/word_of_the_day_service.dart';
|
||||
import 'widgets/gradient_star_badge.dart';
|
||||
|
||||
import 'g4f/client.dart';
|
||||
@@ -21,7 +28,12 @@ import 'g4f/providers/phind_ai.dart';
|
||||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
await WordsRepository().init();
|
||||
await TraditionsRepository().init();
|
||||
await LenormandPairsRepository().init();
|
||||
await TarotMajorsRepository().init();
|
||||
await OghamFedaRepository().init();
|
||||
await SettingsRepository().init();
|
||||
await WordOfTheDayService().init();
|
||||
runApp(const Words999App());
|
||||
}
|
||||
|
||||
@@ -36,7 +48,7 @@ class _Words999AppState extends State<Words999App> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
title: 'Оракул 999 Символов',
|
||||
title: 'Оракул',
|
||||
debugShowCheckedModeBanner: false,
|
||||
themeMode: ThemeMode.dark, // Default to rich mystical dark mode
|
||||
darkTheme: ThemeData(
|
||||
@@ -87,6 +99,9 @@ class _Words999AppState extends State<Words999App> {
|
||||
}),
|
||||
),
|
||||
),
|
||||
builder: (context, child) {
|
||||
return SelectionArea(child: child ?? const SizedBox.shrink());
|
||||
},
|
||||
home: const bool.fromEnvironment('ORACLE_BAKEOFF')
|
||||
? const ProviderBakeoffScreen()
|
||||
: const MainNavigationContainer(),
|
||||
@@ -97,6 +112,13 @@ class _Words999AppState extends State<Words999App> {
|
||||
class MainNavigationContainer extends StatefulWidget {
|
||||
const MainNavigationContainer({super.key});
|
||||
|
||||
static void switchToTab(BuildContext context, int index) {
|
||||
final state = context.findAncestorStateOfType<_MainNavigationContainerState>();
|
||||
if (state != null) {
|
||||
state.setTab(index);
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
State<MainNavigationContainer> createState() => _MainNavigationContainerState();
|
||||
}
|
||||
@@ -105,11 +127,16 @@ class _MainNavigationContainerState extends State<MainNavigationContainer> {
|
||||
int _currentIndex = 0;
|
||||
|
||||
final List<Widget> _screens = const [
|
||||
HomeSearchScreen(),
|
||||
DivinationHubScreen(),
|
||||
CatalogScreen(),
|
||||
HistoryScreen(),
|
||||
SettingsScreen(),
|
||||
];
|
||||
|
||||
void setTab(int index) {
|
||||
setState(() => _currentIndex = index);
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
@@ -125,10 +152,15 @@ class _MainNavigationContainerState extends State<MainNavigationContainer> {
|
||||
},
|
||||
destinations: const [
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.casino_outlined),
|
||||
icon: Icon(Icons.auto_awesome_outlined),
|
||||
selectedIcon: GradientStar(size: 22),
|
||||
label: 'Оракул',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.auto_stories_outlined),
|
||||
selectedIcon: GradientStar(size: 22),
|
||||
label: 'Справочник',
|
||||
),
|
||||
NavigationDestination(
|
||||
icon: Icon(Icons.history_rounded),
|
||||
selectedIcon: GradientStar(size: 22),
|
||||
@@ -141,24 +173,6 @@ class _MainNavigationContainerState extends State<MainNavigationContainer> {
|
||||
),
|
||||
],
|
||||
),
|
||||
floatingActionButton: GestureDetector(
|
||||
onLongPress: () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(builder: (context) => const ProviderBakeoffScreen()),
|
||||
);
|
||||
},
|
||||
child: FloatingActionButton.extended(
|
||||
onPressed: () {
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(builder: (context) => const OracleChatScreen()),
|
||||
);
|
||||
},
|
||||
icon: const Icon(Icons.auto_awesome),
|
||||
label: const Text("ОРАКУЛ"),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user