How yahiachokri928-hash/sokna works
Sokna is a Flutter rental-listing app for Tunisia: renters browse and filter homes, inspect details and reviews, and save favorites; authenticated owners can publish and manage listings. The README describes authentication and profile flows, guest access gates, and hybrid cloud/local persistence. The graph follows documented feature responsibilities and relationships; Dart implementation excerpts were not provided, so internal call paths are limited to those stated in the README. The README also describes offline and cloud variants, so its REST/local fallback and Firestore capabilities may not all coexist in this checkout.
Main entry points: listing_data_source.dart Listing data access · listings_bloc.dart Listing state · home_screen.dart Home catalogue · listing_detail_screen.dart Listing details
Components 22
App experience
- App entry
lib/main.dart - App navigation
lib/core/router/app_router.dart - Home catalogue
lib/features/listings/presentation/screens/home_screen.dart - Search and filters
lib/features/listings/presentation/screens/search_screen.dart - Listing details
lib/features/listings/presentation/screens/listing_detail_screen.dart
Identity and access
- Sign-in and registration
lib/features/auth/presentation/screens/login_screen.dart - User profile
lib/features/auth/presentation/screens/profile_screen.dart - Authentication state
lib/features/auth/presentation/blocs/auth/auth_bloc.dart - Account operations
lib/features/auth/domain/usecases
Rental marketplace
- Listing state
lib/features/listings/presentation/blocs/listings/listings_bloc.dart - Listing data access
lib/features/listings/data/datasources/listing_data_source.dart - Listing repository
lib/features/listings/data/repositories/listing_repository_impl.dart - Publish listing
lib/features/listings/presentation/screens/post_listing_screen.dart - Reviews and ratings
lib/features/listings/presentation/blocs/reviews/reviews_bloc.dart - Saved listings
lib/features/favorites/presentation/blocs/saved_listings/saved_listings_bloc.dart - Favorites repository
lib/features/favorites/data/repositories/favorites_repository_impl.dart
Persistence and services
- Cloud Firestore
- Firebase Auth
- Local preferences
lib/features/favorites/data/datasources/favorites_local_data_source.dart - Firestore service
lib/core/firebase/firestore_service.dart - Remote JSON catalogue
assets/data/listings.json
Other components
- Renter or owner
Connections 26
- Renter or owner → App entry: opens
README.md - App entry → App navigation: starts navigation
- App navigation → Home catalogue: routes to
README.md - Renter or owner → Search and filters: filters homes
README.md - Home catalogue → Listing state: loads catalogue
README.md - Search and filters → Listing state: requests search
README.md - Listing state → Listing repository: requests listings
- Listing repository → Listing data access: uses data source
- Listing data access → Firestore service: reads listings
README.md - Firestore service → Cloud Firestore: reads and writes
README.md - Listing data access → Remote JSON catalogue: fallback catalogue
README.md - Home catalogue → Listing details: opens listing
README.md - Listing details → Reviews and ratings: shows and submits
README.md - Reviews and ratings → Cloud Firestore: stores reviews
README.md - Listing details → Saved listings: toggles saved
README.md - Saved listings → Favorites repository: updates favorites
- Favorites repository → Cloud Firestore: syncs IDs
README.md - Favorites repository → Local preferences: mirrors locally
README.md - Renter or owner → Sign-in and registration: signs in
README.md - Sign-in and registration → Authentication state: submits credentials
- Authentication state → Account operations: runs account actions
- Account operations → Firebase Auth: authenticates
README.md - User profile → Authentication state: updates profile
README.md - Renter or owner → Publish listing: publishes listing
README.md - Publish listing → Listing state: submits listing
- Listing data access → Cloud Firestore: creates or deletes
README.md