[PR #5536] [CLOSED] Feature: add a read option in book show page and impliment a popup mo… #6516

Closed
opened 2026-02-05 10:34:23 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/BookStackApp/BookStack/pull/5536
Author: @tselven
Created: 3/16/2025
Status: Closed

Base: developmentHead: f2-book-reader-page-flip


📝 Commits (1)

  • 19fe925 Feature: add a read option in book show page and impliment a popup model to show book

📊 Changes

11 files changed (+299 additions, -185 deletions)

View changed files

📝 app/Entities/Controllers/BookApiController.php (+12 -18)
📝 app/Entities/Models/Page.php (+1 -1)
app/Services/PDFtoTxtService.php (+23 -0)
📝 composer.json (+1 -0)
📝 composer.lock (+53 -2)
📝 lang/en/common.php (+1 -0)
📝 package-lock.json (+1 -1)
📝 resources/views/books/parts/form.blade.php (+16 -6)
📝 resources/views/books/show.blade.php (+174 -144)
📝 resources/views/entities/grid-item.blade.php (+16 -12)
📝 resources/views/layouts/tri.blade.php (+1 -1)

📄 Description

📖 Implement Book-Like Page Reading Experience on Show Book Page

📝 Description

This PR introduces a book-like page reading experience to the show book page on BookStack. Instead of displaying content in a standard scrolling format, the pages are now structured in a side-by-side spread, mimicking a real book.

🎯 Features

  • 📚 Two-Page Layout – Displays book pages in a left-right format like a real book.
  • 🔄 Page Navigation – Users can switch pages using Next and Previous buttons.
  • 📡 Dynamic Content Loading – Book data is fetched dynamically via API.

🛠️ Changes Made

  • Added a modal-based book reader.
  • Structured book content into page spreads.
  • Implemented basic page switching (without smooth flip animations).
  • Integrated API fetching for dynamic book loading.

How to Test

  1. Open a book on the show page.
  2. Click the "Read Book" button to open the flipbook.
  3. Use the Next and Previous buttons to navigate through pages.
  4. Ensure that content loads correctly in a two-page format.

🚀 What's Next?

  • Implement smooth page-flipping animation for a more realistic experience.
  • Improve mobile responsiveness and add swipe gestures for touchscreens.
  • Optimize performance for larger books.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/BookStackApp/BookStack/pull/5536 **Author:** [@tselven](https://github.com/tselven) **Created:** 3/16/2025 **Status:** ❌ Closed **Base:** `development` ← **Head:** `f2-book-reader-page-flip` --- ### 📝 Commits (1) - [`19fe925`](https://github.com/BookStackApp/BookStack/commit/19fe9258ed90e4c8ac1be886802f9d1c745f49cb) Feature: add a read option in book show page and impliment a popup model to show book ### 📊 Changes **11 files changed** (+299 additions, -185 deletions) <details> <summary>View changed files</summary> 📝 `app/Entities/Controllers/BookApiController.php` (+12 -18) 📝 `app/Entities/Models/Page.php` (+1 -1) ➕ `app/Services/PDFtoTxtService.php` (+23 -0) 📝 `composer.json` (+1 -0) 📝 `composer.lock` (+53 -2) 📝 `lang/en/common.php` (+1 -0) 📝 `package-lock.json` (+1 -1) 📝 `resources/views/books/parts/form.blade.php` (+16 -6) 📝 `resources/views/books/show.blade.php` (+174 -144) 📝 `resources/views/entities/grid-item.blade.php` (+16 -12) 📝 `resources/views/layouts/tri.blade.php` (+1 -1) </details> ### 📄 Description # 📖 Implement Book-Like Page Reading Experience on Show Book Page ## 📝 Description This PR introduces a **book-like page reading experience** to the show book page on BookStack. Instead of displaying content in a standard scrolling format, the pages are now structured in a **side-by-side spread**, mimicking a real book. ## 🎯 Features - 📚 **Two-Page Layout** – Displays book pages in a left-right format like a real book. - 🔄 **Page Navigation** – Users can switch pages using **Next** and **Previous** buttons. - 📡 **Dynamic Content Loading** – Book data is fetched dynamically via API. ## 🛠️ Changes Made - Added a **modal-based book reader**. - Structured book content into **page spreads**. - Implemented **basic page switching** (without smooth flip animations). - Integrated API fetching for dynamic book loading. ## ✅ How to Test 1. Open a book on the show page. 2. Click the **"Read Book"** button to open the flipbook. 3. Use the **Next** and **Previous** buttons to navigate through pages. 4. Ensure that content loads correctly in a **two-page format**. ## 🚀 What's Next? - Implement **smooth page-flipping animation** for a more realistic experience. - Improve mobile responsiveness and add **swipe gestures** for touchscreens. - Optimize performance for larger books. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-05 10:34:23 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#6516