Skip to content

JobayerFaisal/BookSphere

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

4 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

BookSphere

๐Ÿ“š BookSphere

A personal library management app built for book lovers. Track your books, write reviews, discover reading habits, and manage your collection โ€” in both Bengali and English.

Live Demo React Firebase Netlify


โœจ Features

๐Ÿ“– Library Management

  • Add books manually, by ISBN lookup, or by title/author search
  • Barcode scanner using device camera to scan ISBN barcodes
  • Track 200+ books with full details โ€” title, author, publisher, year, edition, ISBN
  • Support for Bengali (เฆฌเฆพเฆ‚เฆฒเฆพ) and English books with proper font rendering
  • Organize into custom shelves / collections

๐Ÿ—‚๏ธ Reading Tracking

  • Track reading progress page by page with a visual progress bar
  • Log reading sessions โ€” "I read 30 pages today" โ€” with daily pace chart
  • Set a yearly reading goal with a progress tracker on the dashboard
  • Mark books as To Read / Reading / Finished / Paused / Dropped

โญ Reviews & Organization

  • Write full-text reviews in Bengali or English
  • 5-star rating system per book and per story
  • Add free-form tags (e.g. favorite, gift, reread)
  • Multiple genres per book
  • Wishlist for books you want to buy or borrow
  • Stories / Parts tracker for collected works and omnibus editions (e.g. Complete Sherlock Holmes)

๐Ÿ“Š Analytics & Discovery

  • Reading habit charts โ€” genre breakdown, language split, rating distribution
  • Book recommendations based on your reading history and top-rated genres
  • Track reading pace over time with session charts

๐Ÿ”— Sharing & Export

  • Share a book review via public link โ€” no sign-in required for viewers
  • Export library as CSV โ€” open in Excel or Google Sheets
  • Export library as PDF โ€” formatted, printable document
  • Print library list โ€” clean printable view with summary stats

๐ŸŒ™ Experience

  • Dark mode โ€” toggleable, preference saved across sessions
  • Progressive Web App (PWA) โ€” install on Android or iPhone like a native app
  • Works on desktop, tablet, and mobile
  • All data private and synced across devices via Firebase

๐Ÿ–ฅ๏ธ Screenshots

Library Book Detail Analytics
Book grid with real covers Progress, reviews, sessions Reading habit charts

๐Ÿ› ๏ธ Tech Stack

Layer Technology
Frontend React 18 (Create React App)
Database Firebase Firestore
Authentication Firebase Auth (Google + Email/Password)
Hosting Netlify
Barcode scanning @zxing/library
PDF export jsPDF
Book data Open Library API (free, no key needed)
Fonts Google Fonts โ€” Playfair Display, DM Sans, Noto Serif Bengali

๐Ÿš€ Getting Started

Prerequisites

1. Clone the repo

git clone https://github.com/JobayerFaisal/BookSphere.git
cd BookSphere

2. Install dependencies

npm install

3. Set up Firebase

  1. Go to Firebase Console โ†’ Create a new project
  2. Enable Authentication โ†’ Sign-in methods โ†’ Enable Google and Email/Password
  3. Enable Firestore Database โ†’ Start in production mode โ†’ Region: asia-south1
  4. Register a Web app โ†’ copy the config values

4. Configure environment variables

Create a .env file in the project root:

REACT_APP_FIREBASE_API_KEY=your_api_key
REACT_APP_FIREBASE_AUTH_DOMAIN=your_project.firebaseapp.com
REACT_APP_FIREBASE_PROJECT_ID=your_project_id
REACT_APP_FIREBASE_STORAGE_BUCKET=your_project.appspot.com
REACT_APP_FIREBASE_MESSAGING_SENDER_ID=your_sender_id
REACT_APP_FIREBASE_APP_ID=your_app_id

5. Set Firestore security rules

In Firebase Console โ†’ Firestore โ†’ Rules:

rules_version = '2';
service cloud.firestore {
  match /databases/{database}/documents {
    match /users/{userId}/{document=**} {
      allow read, write: if request.auth != null && request.auth.uid == userId;
    }
    match /shares/{shareId} {
      allow read: if true;
      allow write: if request.auth != null && request.auth.uid == resource.data.uid;
      allow create: if request.auth != null && request.auth.uid == request.resource.data.uid;
    }
  }
}

6. Run locally

npm start

Open http://localhost:3000 in your browser.

7. Build for production

npm run build

๐ŸŒ Deploying to Netlify

  1. Push your code to GitHub
  2. Go to Netlify โ†’ Import from GitHub โ†’ Select this repo
  3. Build settings are auto-detected from netlify.toml
  4. Add your Firebase environment variables in Netlify โ†’ Site configuration โ†’ Environment variables
  5. Add your Netlify URL to Firebase Auth โ†’ Authorized domains

See DEPLOY.md for detailed deployment instructions.


๐Ÿ“ฑ Install as Mobile App (PWA)

Android: Open the live URL in Chrome โ†’ tap โ‹ฎ menu โ†’ "Add to Home screen"

iPhone: Open the live URL in Safari โ†’ tap Share โ†’ "Add to Home Screen"


๐Ÿ“ Project Structure

src/
โ”œโ”€โ”€ components/
โ”‚   โ”œโ”€โ”€ BookCard.js          # Book grid card with cover image
โ”‚   โ”œโ”€โ”€ ExportModal.js       # CSV / PDF export
โ”‚   โ”œโ”€โ”€ Layout.js            # Sidebar navigation, dark mode toggle
โ”‚   โ”œโ”€โ”€ PrintView.js         # Printable library list
โ”‚   โ””โ”€โ”€ StoriesTracker.js    # Sub-book tracker for series/omnibus
โ”œโ”€โ”€ context/
โ”‚   โ””โ”€โ”€ ThemeContext.js      # Dark mode state
โ”œโ”€โ”€ pages/
โ”‚   โ”œโ”€โ”€ AddBook.js           # Add/edit form with ISBN & title search
โ”‚   โ”œโ”€โ”€ Analytics.js         # Reading habit charts
โ”‚   โ”œโ”€โ”€ BookDetail.js        # Full book page with sessions & stories
โ”‚   โ”œโ”€โ”€ Library.js           # Main book grid with goal tracker
โ”‚   โ”œโ”€โ”€ Login.js             # Auth โ€” Google + email/password
โ”‚   โ”œโ”€โ”€ Recommendations.js   # Personalized book suggestions
โ”‚   โ”œโ”€โ”€ ShareView.js         # Public share page (no login needed)
โ”‚   โ”œโ”€โ”€ Shelves.js           # Shelf browser
โ”‚   โ””โ”€โ”€ Wishlist.js          # Wishlist page
โ”œโ”€โ”€ services/
โ”‚   โ”œโ”€โ”€ books.js             # Firestore CRUD for books
โ”‚   โ”œโ”€โ”€ export.js            # CSV and PDF export logic
โ”‚   โ”œโ”€โ”€ sessions.js          # Reading session tracking
โ”‚   โ”œโ”€โ”€ share.js             # Public share link service
โ”‚   โ””โ”€โ”€ stories.js           # Stories/parts tracker service
โ””โ”€โ”€ firebase.js              # Firebase initialization

๐Ÿค Contributing

This is a personal project, but suggestions and improvements are welcome.

  1. Fork the repo
  2. Create a feature branch: git checkout -b feature/my-feature
  3. Commit your changes: git commit -m 'Add my feature'
  4. Push to the branch: git push origin feature/my-feature
  5. Open a Pull Request

๐Ÿ“„ License

Distributed under the Apache 2.0 License. See LICENSE for more information.


Built with โค๏ธ by Jobayer Faisal

About

A personal library management app to track my books in the library, write reviews, scan ISBN barcodes, and discover reading habits. Supports Bengali and English.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors