4.6 KiB
4.6 KiB
Flutter Folder Structure — GLM-4.7
tests: instruction-following, feature-first structure, domain accuracy
context: DESIGN.md excerpt (screens + navigation)
version: 1
lib/
├── main.dart
├── app.dart
├── features/
│ ├── onboarding/
│ │ ├── onboarding_screen.dart
│ │ ├── widgets/
│ │ │ ├── invite_gate_widget.dart
│ │ │ ├── email_entry_widget.dart
│ │ │ ├── magic_link_confirm_widget.dart
│ │ │ ├── social_handle_optin_widget.dart
│ │ │ └── follow_suggestions_widget.dart
│ │ └── onboarding_cubit.dart
│ ├── feed/
│ │ ├── feed_screen.dart
│ │ ├── widgets/
│ │ │ ├── post_card.dart
│ │ │ ├── photo_swiper.dart
│ │ │ ├── reaction_bar.dart
│ │ │ └── survey_card.dart
│ │ └── feed_cubit.dart
│ ├── posters/
│ │ ├── posters_screen.dart
│ │ ├── widgets/
│ │ │ ├── poster_card.dart
│ │ │ └── tag_filter.dart
│ │ └── posters_cubit.dart
│ ├── compose/
│ │ ├── compose_screen.dart
│ │ ├── widgets/
│ │ │ ├── photo_picker_widget.dart
│ │ │ ├── caption_field.dart
│ │ │ ├── post_type_toggle.dart
│ │ │ ├── tag_picker.dart
│ │ │ ├── event_form.dart
│ │ │ ├── saveable_toggle.dart
│ │ │ └── reaction_picker.dart
│ │ └── compose_cubit.dart
│ ├── stories/
│ │ ├── stories_screen.dart
│ │ ├── widgets/
│ │ │ ├── story_viewer.dart
│ │ │ ├── story_carousel.dart
│ │ │ ├── story_capture_widget.dart
│ │ │ └── filter_swipe_handler.dart
│ │ └── stories_cubit.dart
│ ├── profile/
│ │ ├── profile_screen.dart
│ │ ├── widgets/
│ │ │ ├── profile_header.dart
│ │ │ ├── social_handle_display.dart
│ │ │ ├── contact_prefs_display.dart
│ │ │ ├── posts_grid.dart
│ │ │ └── settings_access_button.dart
│ │ └── profile_cubit.dart
│ ├── settings/
│ │ ├── settings_screen.dart
│ │ ├── widgets/
│ │ │ ├── social_handle_setting.dart
│ │ │ ├── display_social_handle_preference.dart
│ │ │ └── contact_prefs_editor.dart
│ │ └── settings_cubit.dart
│ ├── feedback/
│ │ ├── feedback_screen.dart
│ │ ├── widgets/
│ │ │ ├── survey_widget.dart
│ │ │ └── free_text_field.dart
│ │ └── feedback_cubit.dart
│ └── navigation/
│ ├── main_tab_bar.dart
│ └── navigation_cubit.dart
├── services/
│ ├── auth_service.dart
│ ├── posts_service.dart
│ ├── upload_service.dart
│ ├── users_service.dart
│ └── tus_client.dart
├── shared/
│ ├── models/
│ │ ├── user.dart
│ │ ├── post.dart
│ │ ├── poster.dart
│ │ ├── story.dart
│ │ ├── reaction.dart
│ │ ├── comment.dart
│ │ └── survey.dart
│ ├── widgets/
│ │ ├── error_boundary.dart
│ │ ├── loading_indicator.dart
│ │ └── pull_to_refresh.dart
│ ├── utils/
│ │ ├── date_formatter.dart
│ │ ├── validators.dart
│ │ └── image_utils.dart
│ └── constants/
│ ├── app_colors.dart
│ ├── app_text_styles.dart
│ └── navigation_routes.dart
└── routing/
├── app_router.dart
└── route_handlers.dart
notes:
- feature-first structure as specified
- no notification-related files
- no chat/dm-related files
- compose modeled as a screen with post destination toggles
- stories has capture widget for camera/photo picker
- posters includes tag filter (UI only, implementation details TBD)
- feedback separates survey and free-text into distinct widgets
- social handles are opt-in, modeled in onboarding and settings
- all state management uses cubit pattern (consistent across features)
- tus_client for resumable uploads
- routing handles deep links for invite codes