-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Architecture #10
base: main
Are you sure you want to change the base?
Architecture #10
Conversation
ccitygril
commented
Jul 24, 2024
- сделана верста
- добавлен Elementary
- проведен небольшой рефактор
- в процессе di
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
В целом выглядит круто. Только по поводу структуры проекта - у тебя почти в папку ui грубо говоря попали фичи. Лучше сделать всё-таки папку features в lib, где у тебя будут лежать theme и image, в image перенести все папки data, di и т.д. из lib и создать папку screens, где уже разместить свои elementary-экраны
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
di_scope*
@freezed | ||
class ImageEntity with _$ImageEntity { | ||
const factory ImageEntity({ | ||
required int id, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Скорее всего id у нас будут строки, а точнее пути до файлов
@@ -0,0 +1,5 @@ | |||
import 'package:flutter/material.dart'; | |||
|
|||
class AppColor { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
А это что и зачем?
import 'package:flutter/material.dart'; | ||
import 'package:surf_flutter_summer_school_24/ui/ui_kit/color/color_theme.dart'; | ||
|
||
abstract class AppThemeData { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Оно всё-таки должно быть в uikit
} | ||
} | ||
|
||
class PageCarousel extends StatefulWidget { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Не очень понимаю, а это точно что-то нужное?
@override | ||
void initWidgetModel() { | ||
super.initWidgetModel(); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Если пустой, то не надо переопределять метод
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
А, ты сюда подгрузку планируешь добавить. Тогда ок
Widget build(BuildContext context) { | ||
return Scaffold( | ||
appBar: const CustomAppBar(), | ||
body: Column( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
А смайлик?
ElevatedButton( | ||
onPressed: () {}, child: const Text("ПОПРОБОВАТЬ СНОВА")) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Кнопочку лучше вынести в отдельный виджет
Только сюда не сливай, сливай в свой репозиторий |