Screen · Media

Now Reading SwiftUI Screen

A reading home with the book in hand as a big cover, its progress and time left, the week's reading and the pile up next.

The home tab of a reading app: the book you're reading as a drawn cover with the percentage read, a progress bar and the page you're on with the time left at your pace, a Start session button and a quick way to keep a passage. Below it the last seven days as bars of minutes with the week's total and your streak, and the next books on your pile as a grid of covers. With nothing in hand it asks for a first book.

  • SwiftUI
  • iOS 17.0+
  • reading-now
Get SwiftPieces Pro

$199 once, every piece included. See how installing works · Sign in

01

What's included

SwiftUI source you own, built on Apple frameworks only.

  • The book in hand as a drawn cover with its percentage and time left
  • Start a session or keep a passage from the first screen
  • The week as bars of minutes, with the total and your streak
  • Up next as a grid of covers you open
  • ReadingCover: a title, author and spine drawn in your theme's motif

Used in

Reading App (template)

02

Implementation notes

How it behaves, what it handles, and the decisions behind it.

The screen opens on a large title with search and a plus in the corner, then the book you're reading as a drawn cover beside its title, author and how far in you are as a large percentage that rolls when the page changes. A progress bar and a page line follow, "p. 214 of 368 · about 3 h left", with the time worked out from your own pace. Under it Start session fills the width beside a smaller quote button for keeping a passage. The week sits in a card: seven bars of minutes with today in the accent, the week's total and your streak. Up next shows the next four books on your pile as covers that fit inside the margins, with the pile's count to see the rest. With nothing in hand the hero turns into an empty shelf that asks for a first book.

Notes

  • NowReading(book:week:streak:upNext:onStart:onHighlight:onAdd:) takes everything as values and hands every tap back as a closure, so it sits on any store. Pass nil for book to show the empty shelf, and leave onSearch or onShowAll nil to hide the magnifier or keep the pile's count as plain text.
  • A NowReadingBook has its pages, the page you're on and an optional minutesLeft; progress is worked out from the pages. block picks the cover's block from theme.color.tile(_:) and seeds its art.
  • ReadingCover(title:author:block:) is the cover on its own: the block with the family's art from SPCoverArt (dithered pixels in Phosphor, overprinted inks in Riso, rings in Velvet), the title in a book serif at the top, the author on a label at the foot and a spine crease. Give it a 2:3 frame; the type scales with the width. Pass showsText: false for a small thumbnail.
  • week is seven NowReadingDays, oldest first, with today marked. The bars share one scale, and a day with no reading keeps a short stub so the week still reads as seven days.
  • The hero is one VoiceOver element ("Now reading The Salt Orchard by Mira Okonkwo, 58 percent") and the week reads each day with its minutes. Type scales with Dynamic Type, and at accessibility sizes the cover narrows to leave the text room.
  • NowReadingExample at the end of NowReading.swift is the screen in the preview, in the Phosphor showcase preset, with The Salt Orchard on page 214 and six books up next. Copy it as a starting point.