Read is how reading is tracked: how long, which book, and how far through it. Each entry is one session of reading, an interval with the book and a position at either end. The Daily habits module makes Read and the Books catalog it picks from (Modules). Nothing in it is particular to books: the progress field it uses works along any catalog item, and Read is an ordinary trackable a person could have made.
Read
Read (readTrackable in packages/core/src/modules.ts) has three fields:
- Time, an interval from Start to Stop, dated by its start, so a session belongs to the evening you sat down (Intervals);
- Book, an item field on the Books catalog, required;
- Pages, a progress field along the Book, required once the session has ended.
Its own Reading is a Sum, the time read in a day; “did I read” is the same trackable read as Any (Readings). It is asked once a day in the Rundown, and a day the app was used with no Read entry reads as none.
A session is started and stopped in the entry panel like any interval, or logged afterwards with both ends. Picking a book fills where the session starts, from where the previous entry of that book stopped. A template of one line fills the book, so a book being read can be one tap (The List Model).
Books
The Books catalog’s items have Pages, a whole number of at least 1, and an Author. It has no basis unit, so a book’s numbers are facts of the whole book and are never scaled by an entry; this is what makes a Read entry name a book where a Diet entry logs an amount of a food. A book with no page count, an e-book, is read in percent.
The progress field
A progress field (kind: "progress") measures how far through an item an entry got. It names the item field it runs along (along) and, optionally, the item’s number attribute that holds its length (length, a book’s Pages).
- What is stored is the position where the entry started and where it stopped, in percent of the item,
{ from, to }, withtoempty while a session runs. The percent is what is kept for every item; the page count only adds pages to what is shown, worked out when read, so correcting a book’s page count re-reads every entry of it (packages/core/src/progress.ts). Percent rather than pages, because an e-reader reflows its text, so its page count is not a fixed quantity, and one unit for every item keeps positions comparable across books. A position outside 0 to 100 percent is refused when the entry is written. There is no pages-read field: what an entry covered is its stop minus its start, and typing it as well would let the two disagree. - Typing a position takes a percent or a fraction read as how far through: “206/412” of a book, “415/817” of an e-book’s locations (
parsePosition). - Shown as a bar and in words: how far through, the page that falls on where the book has a page count, and what the entry covered (“50% · p. 206 of 412 · +12% (49 pages)”). A session that reaches the end reads “Finishes it.”; one whose stop is before its start says so and cannot be logged. A day’s Day view counts the pages read that day: what each entry covered, added up over the books that give a page count. Percents of different books are never added.
- Where the next session starts (
nextFrom): where the latest stopped, or 0 after a finish.
Times through a book
An item’s sessions group into read-throughs (readThroughs). Within one, every session belongs to it, so going back a few pages to reread a chapter stays in the same read-through. A finish ends one, and the next session begins the next. A give-up ends one too: a session that carries on from where it stopped, or later, takes it back up, and one that starts earlier begins a new one. How much of the book a read-through covered counts each part once, so a textbook read out of order is not counted twice.
A book’s page lists its times through, each In progress, Finished or Dropped, how far each got and how many times the book was finished, with Dropped or Take it back up on the latest. Dropped is marked on the final entry before it. There is no Finish button: the session that reaches 100% finishes the read-through, and its day is the finish date; Dropped is the only status marked by hand. The status belongs to a read-through, not to the book, so a reread never overwrites how an earlier time through ended. Progress, Finished and Dropped are glossary terms; the status is never called “Reading”, which is the term for how a trackable is read.
In the demo profiles
John reads three books over his month and Chad eight over his year, going round twice: two e-books read in percent, Sapiens Dropped a third of the way in, and every second time round a reread.
Related
Intervals · Catalog Entities · The List Model · Readings · Modules