tracker
All repositories: gitoria
2.6 KB
// components/franchises.hl — `/franchises` (tracker.worldapi.org#19, mission 066): every franchise (→ its index), then the// timelines that belong to none (most of them TMDB's movie collections, collections.hl seed), each with its number of titles.// The creator sees an "Edit" link to the editor (/franchises/edit). Data: franchises.hl franchiseIndexPage (the franchises on page 1, the loose timelines 40 per page: /franchises/page/N).parent './main.hl'import { navigate } from 'hl:web'import { appTitle } from '../project.hl'import { franchiseIndexPage, isEditorSession } from '../lib/franchises.hl'import Pagination from './pagination.hl'// static: an mpackdb-backed helper must be `static` (hybriel#115/#116), and LOCAL (mission 047)static indexOf = (&raw) => { return franchiseIndexPage(&raw) }static editorOf = (&session) => { return isEditorSession(&session) }session = nullpage = nullcanEdit = editorOf(&session)listing = indexOf(&page)franchiseRows = listing.franchisestimelineRows = listing.timelinespageNo = listing.pagehasFranchises = franchiseRows.length > 0noFranchises = franchiseRows.length == 0 && pageNo == 1hasTimelines = listing.total > 0pageCount = listing.pageshasPages = pageCount > 1// mobile audit MK: the timelines without a franchise are 40 per page (1,546 of them were one 54,000 px page that took 20 s)timelineCountText = (listing.total == 1 ? '1 timeline without a franchise' : listing.total + ' timelines without a franchise') + (hasPages ? ' · page ' + pageNo + ' of ' + pageCount : '')goPage = (to) => { navigate(to == 1 ? '/franchises' : '/franchises/page/' + to) }__title = pageNo > 1 ? 'Franchises, page ' + pageNo + ' — ' + appTitle : 'Franchises — ' + appTitleView {franchisesPage {franchisesHead {h1 { class = "typed" typeWord { class = "type-word type-franchise" "Franchises" } }if (canEdit) { a { id = "franchises-edit" class = "button" href = "/franchises/edit" "Edit" } }}if (noFranchises) { p { class = "muted" "No franchises yet." } }if (hasFranchises) {franchiseList { id = "franchise-list"for (f of franchiseRows) {a { class = "franchise-row" href = f.hreffranchiseName { f.name }franchiseCount { f.countText }}}}}if (hasTimelines) {h2 { class = "film-heading" "Timelines" }p { class = "muted list-count" timelineCountText }timelineList { id = "timeline-list"for (t of timelineRows) {a { class = "timeline-link" href = t.hreftimelineLinkName { t.name }timelineLinkCount { t.countText }}}}if (hasPages) {pagerBox { Pagination { pages = pageCount page = pageNo onPage = goPage } }}}}}
Branches
Latest commits
- 16b3354aMerge branch 'main' into rv28cmre
- 6f4f27d8log: RV28d started (day38b)mre
- e6cf03ffmission RV28d: rv28c onto day38bmre
- 3ccaee19status: live sweep freeze, waiting for Apollomre
- 49f76ecblog: watch toggle slowness = session sweep freeze (tracker#50)mre
- 3daf6eddlog: day37 live, still waiting for day39mre
- 796ba672records: #277 slips to day39mre
- a9eb9827records: mpackdb integrity clean, all 12 tablesmre
- 6cf40dbdrecords: mpackdb integrity check, shows uncheckedmre
- 1880f42arecords: day38 deploy may swap normallymre
- 9d806e35records: mpackdb freeze until day38mre
- a660239drecords: day37 lacks #277, wait for day38mre
- b0abfdeaLOG: Anton hybriel#277 fix ready for day37mre
- 7b5b2918Tracker: hybriel#277 fix comes in day37mre
- 7ddbeec8Tracker: RV28c blocked on day35 regressionmre
- 529096e8RV28c: reportmre
- a4047071RV28c: re-vendor Hybriel set day35 (source cb9e480d, bin 4bb25cfa)mre
- 765057fbMerge main into rv28c (LOG.md, STATUS.md: both sides kept)mre
- bf401884Tracker: RV28c startedmre
- 0ff4ecd4Tracker: RV28c briefmre