0% found this document useful (0 votes)
9 views9 pages

Flutter Book Reading Tracker App

The Book Reading Tracker App is a Flutter-based mobile application designed to help users monitor their reading habits, set goals, and maintain a personal digital library. It addresses common challenges faced by readers, such as tracking progress and maintaining motivation, by allowing users to log daily reading activity and view visual progress. The app features modules for book management, progress tracking, and offline access, making it a comprehensive tool for promoting consistent reading habits.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views9 pages

Flutter Book Reading Tracker App

The Book Reading Tracker App is a Flutter-based mobile application designed to help users monitor their reading habits, set goals, and maintain a personal digital library. It addresses common challenges faced by readers, such as tracking progress and maintaining motivation, by allowing users to log daily reading activity and view visual progress. The app features modules for book management, progress tracking, and offline access, making it a comprehensive tool for promoting consistent reading habits.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

EX NO: 10 MINI PROJECT INVOLVING FLUTTER

MULTI-PLATFORM

Introduction:
Reading is a powerful habit that enhances knowledge, creativity, and critical thinking.
However, in today’s fast-paced lifestyle, many individuals struggle to maintain consistent
reading habits or track their progress effectively. The Book Reading Tracker App addresses
this issue by providing a simple and intuitive platform for users to monitor their reading
activity, set goals, and develop consistent habits. This Flutter-based mobile application allows
users to maintain a personal digital library, log daily reading activity, view progress visually,
and reflect on their reading history. Whether the user is a student, professional, or casual reader,
the app serves as a digital reading companion aimed at encouraging regular and goal-oriented
reading.

Problem Statement:
Many readers today face several challenges when it comes to tracking their reading progress.
These include:
• Forgetting how much they’ve read or where they left off.
• Lack of motivation due to the absence of visual progress.
• No structured way to track daily reading activity or goals.
• Difficulty in maintaining a reading log for reflection or academic purposes.
Despite the availability of digital reading platforms, very few provide simple, standalone tools
for progress tracking and history logging. Hence, there is a need for a lightweight, offline-
friendly solution that enables users to log pages read per day, track total book progress, and
stay consistent with their reading goals.

Objective:
The primary objective of this project is to design and implement a mobile application that
enables users to:
• Add and store book information.
• Log the number of pages read daily.
• View visual progress using a progress bar.
• Track and review their reading history over time.
• Rate books upon completion.
This application aims to promote reading as a daily habit by offering clear insights and
motivation through goal tracking and progress feedback.
System Design & Architecture:
The Book Reading Tracker is developed using Flutter, a modern UI toolkit for building cross-
platform applications, and Dart as the programming language.
Key Modules:
• Book Management: Add, edit, and delete book entries including title, author, total
pages, and rating.
• Progress Tracker: Log pages read daily, update total progress.
• Reading History: Maintain a date-wise record of each day’s reading session.
• Visual Feedback: Display reading progress using progress bars.
• Offline Access: All data is stored locally, making the app usable without internet
access.

Tools and Technologies Used:


Language : Dart

Framework : Flutter

UI Components : Material Design Widgets

Development : DartPad / Android Studio

Platform : Android (Extensible to iOS)

Coding:
Import 'package: flutter/[Link]';

void main() => runApp(BookReadingTrackerApp());

class BookReadingTrackerApp extends StatelessWidget {


@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Book Reading Tracker',
theme: ThemeData(primarySwatch: [Link]),
home: BookListScreen(),
);
}
}

class Book {
String title;
String author;
int totalPages;
int pagesRead = 0;
List<ReadingLog> history = [];

Book({required [Link], required [Link], required [Link]});


}

class ReadingLog {
final DateTime date;
final int pages;

ReadingLog({required [Link], required [Link]});


}

class BookListScreen extends StatefulWidget {


@override
_BookListScreenState createState() => _BookListScreenState();
}

class _BookListScreenState extends State<BookListScreen> {


List<Book> books = [];

final _titleController = TextEditingController();


final _authorController = TextEditingController();
final _pagesController = TextEditingController();

void _addBook() {
showDialog(
context: context,
builder: (_) => AlertDialog(
title: Text("Add Book"),
content: SingleChildScrollView(
child: Column(
children: [
TextField(
controller: _titleController,
decoration: InputDecoration(labelText: "Title"),
),
TextField(
controller: _authorController,
decoration: InputDecoration(labelText: "Author"),
),
TextField(
controller: _pagesController,
decoration: InputDecoration(labelText: "Total Pages"),
keyboardType: [Link],
),
],
),
),
actions: [
TextButton(
onPressed: () {
final title = _titleController.text;
final author = _authorController.text;
final totalPages = [Link](_pagesController.text) ?? 0;

if ([Link] && [Link] && totalPages > 0) {


setState(() {
[Link](Book(
title: title,
author: author,
totalPages: totalPages,
));
});
_titleController.clear();
_authorController.clear();
_pagesController.clear();
[Link](context).pop();
}
},
child: Text("Add"),
),
],
),
);
}

void _logReading(Book book) {


final _readController = TextEditingController();
showDialog(
context: context,
builder: (_) => AlertDialog(
title: Text("Log Reading"),
content: TextField(
controller: _readController,
decoration: InputDecoration(labelText: "Pages Read"),
keyboardType: [Link],
),
actions: [
TextButton(
onPressed: () {
final pages = [Link](_readController.text) ?? 0;
if (pages > 0) {
setState(() {
[Link] += pages;
[Link](
ReadingLog(date: [Link](), pages: pages),
);
});
[Link](context).pop();
}
},
child: Text("Save"),
),
],
),
);
}

void _viewHistory(Book book) {


showDialog(
context: context,
builder: (_) => AlertDialog(
title: Text("${[Link]} - Reading History"),
content: Container(
width: [Link],
child: [Link](
shrinkWrap: true,
itemCount: [Link],
itemBuilder: (_, index) {
final log = [Link][index];
return ListTile(
title: Text("${[Link]} pages"),
subtitle: Text("${[Link]()}".split(' ')[0]),
);
},
),
),
actions: [
TextButton(
onPressed: () => [Link](context),
child: Text("Close"),
)
],
),
);
}

Widget _buildBookCard(Book book) {


final progress = [Link] == 0
? 0.0
: ([Link] / [Link]).clamp(0.0, 1.0);
return Card(
elevation: 3,
margin: [Link](8),
child: ListTile(
title: Text([Link]),
subtitle: Column(
crossAxisAlignment: [Link],
children: [
Text("Author: ${[Link]}"),
Text("Pages Read: ${[Link]}/${[Link]}"),
LinearProgressIndicator(value: progress),
Row(
children: [
TextButton(
onPressed: () => _logReading(book),
child: Text("Log Pages"),
),
TextButton(
onPressed: () => _viewHistory(book),
child: Text("View History"),
),
],
),
],
),
),
);
}

@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text(" Book Reading Tracker"),
),
Body: [Link]
? Center(child: Text("No books added. Tap + to start."))
[Link](
itemCount: [Link],
itemBuilder: (_, index) => _buildBookCard(books[index]),
),
floatingActionButton: FloatingActionButton(
onPressed: _addBook,
child: Icon([Link]),
),
);
}}
Output:
Result:

Thus, the Book reading tracker mobile application by using Flutter and Dart, has been
developed successfully.

You might also like