A beautiful, feature-rich Quran application built with Flutter. Read, listen, bookmark, and explore the Holy Quran with English translations and audio recitations.
- Complete Quran: All 114 Surahs with Arabic text.........
- English Translations: Sahih International translation for all verses
- Audio Recitation: High-quality audio playback with auto-play functionality
- Bookmarks: Save and manage your favorite verses
- Last Read: Quick access to your last read position
- Search: Search through all Surahs
- Share: Share verses with others
- Responsive UI: Works on mobile, tablet, and web
- Offline Support: Assets cached locally for offline reading
---////
This project follows a modular, feature-based architecture with clean separation of concerns using Riverpod for state management.
lib/
βββ main.dart # App entry point
βββ screen.dart # Main screen routing
β
βββ models/ # Data Models (Entities)
β βββ bookmark_model.dart
β βββ last_read_model.dart
β βββ player_state_model.dart
β βββ quran_audio_model.dart
β βββ surah_detail_model.dart
β βββ surah_model.dart
β βββ verse_model.dart
β
βββ providers/ # State Management (Riverpod Providers)
β βββ audio_provider.dart
β βββ bookmark_provider.dart
β βββ last_read_provider.dart
β βββ search_provider.dart
β βββ startup_provider.dart
β βββ surah_provider.dart
β
βββ modules/ # UI Features (Screens & Components)
β βββ home/
β βββ startup/
β βββ surah-detail/
β βββ bookmark/
β
βββ repositories/ # Data Access Layer
β βββ surah_repository.dart
β
βββ services/ # Core Services
β βββ audio/
β βββ storage/
β
βββ shared/ # Shared/Reusable Components
β βββ audio_player_box.dart
β βββ shell_route_layout.dart
β βββ single_scrolling_layout.dart
β
βββ utils/ # Utilities & Helpers
β
βββ extension/ # Dart Extensions
βββ cache_for.dart
Purpose: Define the data structure and business entities.
surah_model.dart: Represents a Surah (chapter) with number, name, revelation type, etc.verse_model.dart: Represents a verse (ayah) with Arabic text, translation, audio URLbookmark_model.dart: Stores bookmarked verses with metadatalast_read_model.dart: Tracks user's last read positionplayer_state_model.dart: Audio player state (playing, paused, loading, progress)quran_audio_model.dart: Audio metadata for verse playback
Connection: Models are used by Providers to manage state and by Repositories to transform API/database data.
Purpose: Manage application state using Riverpod. Acts as the glue between UI and data layer.
State Notifiers (manage mutable state):
audio_provider.dart: Manages audio playback (play, pause, next, progress tracking)bookmark_provider.dart: Handles bookmark CRUD operationslast_read_provider.dart: Tracks and updates last read position
Async Providers (fetch data):
surah_provider.dart: Provides Surah list and verse datasearch_provider.dart: Handles search queries across Surahsstartup_provider.dart: Initializes app (loads data, checks storage)
Connection Flow:
UI (Consumer Widget)
β reads/watches
Provider (StateNotifier/FutureProvider)
β uses
Repository/Service
β returns
Model (Data)
β updates
Provider State
β rebuilds
UI
Purpose: Feature-based UI organization. Each module is a complete feature with its own screens and components.
modules/
βββ home/
β βββ components/ # Reusable widgets for home
β β βββ last_read_box.dart
β β βββ search_box.dart
β β βββ surah_tab.dart
β βββ home_page.dart # Main home screen
β
βββ surah-detail/
β βββ components/
β β βββ tab_view_container.dart
β β βββ verse_lists.dart
β β βββ surah_header.dart
β βββ surah_detail_page.dart
β
βββ bookmark/
β βββ bookmark_page.dart
β
βββ startup/
βββ startup_page.dart # Splash/loading screen
Connection: Modules consume Providers using ref.watch() and ref.read() to get data and trigger actions.
Purpose: Abstract data access. Handles fetching data from assets, APIs, or local storage.
surah_repository.dart:- Loads Surah list from
assets/data/surah.json - Loads verse data from
assets/verses/surah-{id}.json - Parses JSON and returns Models
- Loads Surah list from
Connection: Providers call Repository methods to get data, Repository returns Models.
Purpose: Core functionality that doesn't fit in Providers or Repositories.
Audio Service (/services/audio/):
- Wraps
just_audiopackage - Provides AudioPlayer instance
- Handles audio initialization and disposal
Storage Service (/services/storage/):
- Manages local data persistence using Hive
- Stores bookmarks, last read, user preferences
- Provides database access
Connection: Services are injected into Providers as dependencies.
Purpose: Reusable UI components used across multiple modules.
audio_player_box.dart: Bottom audio player widget (shown globally)shell_route_layout.dart: App shell/scaffold wrapper for routingsingle_scrolling_layout.dart: Custom scroll behavior wrapper
Connection: Used by multiple screens/modules for consistent UI.
Purpose: Helper functions, constants, and utilities.
- Theme constants
- Date formatters
- String helpers
- Constants (colors, sizes, API endpoints)
Purpose: Dart extensions to add functionality to existing classes.
cache_for.dart: Extension methods for caching/memoization
1. User taps play button on verse
β
2. UI calls: ref.read(playAudioProvider(QuranAudioModel(...)))
β
3. playAudioProvider (FutureProvider):
- Fetches all verses from surah_provider
- Extracts audio URLs
- Calls playerStateProvider.notifier.loaded()
β
4. PlayerStateNotifier (in audio_provider.dart):
- Updates state.sources with audio list
- Calls _player.setUrl() (AudioPlayer service)
- Updates state.isLoading, state.currentNumber
β
5. State changes trigger UI rebuild
β
6. audio_player_box.dart (shared widget) shows player
β
7. When verse completes:
- ProcessingState.completed event fires
- PlayerStateNotifier auto-plays next verse
- UI updates to show new verse number
Components:
-
Search Box (
search_box.dart):- Search input field
- Triggers
search_provideron input - Shows search results dynamically
-
Last Read Box (
last_read_box.dart):- Displays last read Surah and verse
- Quick navigation to continue reading
- Uses
last_read_provider
-
Surah Tab (
surah_tab.dart):- List of all 114 Surahs
- Shows Surah name (Arabic & English)
- Revelation type, verse count
- Navigate to detail on tap
State Management:
- Watches
surahListProviderfor Surah list - Watches
lastReadProviderfor last position - Watches
searchProviderwhen searching
Components:
-
Surah Header (
surah_header.dart):- Surah name, revelation type
- Total verses, Bismillah
- Back button
-
Tab View Container (
tab_view_container.dart):- Tabs: Verses, Info
- Switch between verse list and Surah info
-
Verse Lists (
verse_lists.dart):- Displays all verses in Surah
- Arabic text, English translation
- Play, Bookmark, Share buttons
- Verse number badge
State Management:
- Watches
versesProvider(surahId)for verse list - Reads
playAudioProviderto play audio - Reads
bookmarkProviderto add/remove bookmarks - Reads
lastReadProviderto save last read
Features:
- Shows currently playing verse
- Play/Pause button
- Progress bar with seek
- Next/Previous buttons
- Verse number indicator
- Dismiss button
State Management:
- Watches
playerStateProviderfor player state - Calls
playerStateProvider.notifier.play/pause/destroy
Features:
- Lists all bookmarked verses
- Shows Surah name, verse number, snippet
- Remove bookmark
- Navigate to verse on tap
State Management:
- Watches
bookmarkProviderfor bookmark list - Calls
bookmarkProvider.notifier.removeBookmark()
Used for local persistence:
Boxes:
- Bookmarks Box: Stores
BookmarkModelobjects - Last Read Box: Stores
LastReadModelobject - Settings Box: User preferences (future)
Location:
- Mobile: App documents directory
- Web: IndexedDB
assets/
βββ data/
β βββ surah.json # List of all 114 Surahs
β βββ interpretations/ # Tafsir (commentary)
β βββ surah-details/ # Additional Surah info
β
βββ verses/
β βββ surah-1.json # Al-Fatihah verses
β βββ surah-2.json # Al-Baqarah verses
β βββ ...
β βββ surah-114.json # An-Nas verses
β
βββ fonts/ # Custom fonts
βββ icons/ # App icons
βββ images/ # Images/illustrations
{
"nomor": 1,
"nama": "Al-Fatihah",
"ayat": [
{
"nomorAyat": 1,
"teksArab": "Ψ¨ΩΨ³ΩΩ
Ω Ψ§ΩΩΩΩΩΩ Ψ§ΩΨ±ΩΩΨΩΩ
ΩΩ°ΩΩ Ψ§ΩΨ±ΩΩΨΩΩΩ
Ω",
"teksLatin": "BismillΔhir-raαΈ₯mΔnir-raαΈ₯Δ«m",
"teksInggris": "In the name of Allah, the Entirely Merciful...",
"audio": {
"05": "https://cdn.equran.id/audio-partial/..."
}
}
]
}- Flutter SDK >= 3.9.2
- Dart SDK >= 3.9.2
- Node.js (for scraping scripts)
- Bun or npm (for running scripts)
- Clone the repository
git clone <repository-url>
cd noor_e_quran- Install dependencies
flutter pub get- Generate missing Surah files (if needed)
node download_surahs.js- Add English translations
node enrich_english.js- Run the app
flutter run -d chrome # For web
flutter run # For mobile (connected device)flutter run -d chrome --web-port=8080Web:
flutter build web --releaseAndroid:
flutter build apk --release
flutter build appbundle --releaseiOS:
flutter build ios --releaseWindows:
flutter build windows --releaseDownloads all 114 Surah JSON files from equran.id API.
node download_surahs.jsAdds English translations from Quran.com API to existing Surah files.
node enrich_english.jsLegacy script with both download and enrich functionality.
bun scrape.js # Download verses
bun scrape.js en # Add English translationsKey dependencies:
flutter_riverpod: State managementgo_router: Navigation/routingjust_audio: Audio playbackhive: Local databasegoogle_fonts: Typographyflutter_svg: SVG renderingshare_plus: Share functionality
Theme colors defined in utils/ (to be created):
class ThemeColor {
static const primary = Color(0xFF...);
static const background = Color(0xFF...);
// ...
}flutter test| Package | Purpose |
|---|---|
flutter_riverpod |
State management, dependency injection |
go_router |
Declarative routing |
just_audio |
Audio playback with streaming support |
hive |
Fast, lightweight local database |
google_fonts |
Beautiful typography |
share_plus |
Share content across platforms |
visibility_detector |
Detect widget visibility |
flutter_native_splash |
Custom splash screen |
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit changes (
git commit -m 'Add amazing feature') - Push to branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the MIT License.
For questions or support, please open an issue on GitHub.
Made with β€οΈ using Flutter