نسخة كاملة من مستودع سيرو عند ecfe7568 لتكون أساس تطبيق «انطلق». نُسخ المتعقَّب في git فقط (12,509 ملفاً / 302 م.ب) بـ git archive، لا `cp -r` — فاستُثنيت تلقائياً مخلفات البناء (build · node_modules · .dart_tool · .gradle · Pods ≈ 10.7 غ.ب) وكل ما يستثنيه .gitignore. هذا الكوميت **بلا أي تعديل عمداً** حتى يكون كل ما يليه فرقاً مقروءاً مقابل سيرو الأصلي. سيرو نفسه لم يُمسّ. ⚠️ لا يبني بعد: `.env` و`lib/env/env.g.dart` غير متعقَّبين في سيرو (وهذا صحيح — أسرار لكل مستأجر). كل تطبيق فلاتر هنا يحتاج .env خاصاً بانطلق ثم توليد env.g.dart عبر build_runner. لا تُنسخ أسرار سيرو. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
130 lines
3.1 KiB
Dart
130 lines
3.1 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:get/get.dart';
|
|
|
|
import 'lang/translation_service.dart';
|
|
import 'routes/app_pages.dart';
|
|
import 'shared/logger/logger_utils.dart';
|
|
|
|
void main() {
|
|
runApp(MyApp());
|
|
}
|
|
|
|
class MyApp extends StatelessWidget {
|
|
const MyApp({Key? key}) : super(key: key);
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return GetMaterialApp.router(
|
|
debugShowCheckedModeBanner: false,
|
|
enableLog: true,
|
|
logWriterCallback: Logger.write,
|
|
// initialRoute: AppPages.INITIAL,
|
|
getPages: AppPages.routes,
|
|
locale: TranslationService.locale,
|
|
fallbackLocale: TranslationService.fallbackLocale,
|
|
translations: TranslationService(),
|
|
);
|
|
}
|
|
}
|
|
|
|
/// Nav 2 snippet
|
|
// void main() {
|
|
// runApp(MyApp());
|
|
// }
|
|
|
|
// class MyApp extends StatelessWidget {
|
|
// MyApp({Key? key}) : super(key: key);
|
|
|
|
// @override
|
|
// Widget build(BuildContext context) {
|
|
// return GetMaterialApp.router(
|
|
// getPages: [
|
|
// GetPage(
|
|
// participatesInRootNavigator: true,
|
|
// name: '/first',
|
|
// page: () => First()),
|
|
// GetPage(
|
|
// name: '/second',
|
|
// page: () => Second(),
|
|
// ),
|
|
// GetPage(
|
|
// name: '/third',
|
|
// page: () => Third(),
|
|
// ),
|
|
// ],
|
|
// debugShowCheckedModeBanner: false,
|
|
// );
|
|
// }
|
|
// }
|
|
|
|
// class First extends StatelessWidget {
|
|
// @override
|
|
// Widget build(BuildContext context) {
|
|
// return Scaffold(
|
|
// appBar: AppBar(
|
|
// title: Text('page one'),
|
|
// leading: IconButton(
|
|
// icon: Icon(Icons.more),
|
|
// onPressed: () {
|
|
// Get.changeTheme(
|
|
// context.isDarkMode ? ThemeData.light() : ThemeData.dark());
|
|
// },
|
|
// ),
|
|
// ),
|
|
// body: Center(
|
|
// child: Container(
|
|
// height: 300,
|
|
// width: 300,
|
|
// child: ElevatedButton(
|
|
// onPressed: () {},
|
|
// child: Text('next screen'),
|
|
// ),
|
|
// ),
|
|
// ),
|
|
// );
|
|
// }
|
|
// }
|
|
|
|
// class Second extends StatelessWidget {
|
|
// @override
|
|
// Widget build(BuildContext context) {
|
|
// return Scaffold(
|
|
// appBar: AppBar(
|
|
// title: Text('page two ${Get.parameters["id"]}'),
|
|
// ),
|
|
// body: Center(
|
|
// child: Container(
|
|
// height: 300,
|
|
// width: 300,
|
|
// child: ElevatedButton(
|
|
// onPressed: () {},
|
|
// child: Text('next screen'),
|
|
// ),
|
|
// ),
|
|
// ),
|
|
// );
|
|
// }
|
|
// }
|
|
|
|
// class Third extends StatelessWidget {
|
|
// @override
|
|
// Widget build(BuildContext context) {
|
|
// return Scaffold(
|
|
// backgroundColor: Colors.red,
|
|
// appBar: AppBar(
|
|
// title: Text('page three'),
|
|
// ),
|
|
// body: Center(
|
|
// child: Container(
|
|
// height: 300,
|
|
// width: 300,
|
|
// child: ElevatedButton(
|
|
// onPressed: () {},
|
|
// child: Text('go to first screen'),
|
|
// ),
|
|
// ),
|
|
// ),
|
|
// );
|
|
// }
|
|
// }
|