Episode highlights per series: tag by lane, group on Episodes page, move to Finished Book when series ends; v2.9.1
Publish Container / build (push) Successful in 15m21s
Publish Container / build (push) Successful in 15m21s
- Highlights get a Series field (Lane A / Lane B / General); legacy highlights count as Lane A - Episodes page groups highlights under each series' title - Ending a series (scheduled or manual) moves only that series' highlights onto its Finished Book page; other lane and General stay - Archived highlights keep working: detail pages, sitemap, scripture index and search include them Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
ddcaec0ddf
commit
652b003bd9
9 files changed
+133
-57
No files matched your search
@@ -1,6 +1,7 @@
|
||||
import { useMemo, useState, useEffect, useRef } from 'react'
|
||||
import Fuse from 'fuse.js'
|
||||
import type { SiteContent } from '../content'
|
||||
import { getAllHighlights } from '../content'
|
||||
|
||||
export type SearchResultType = 'episode' | 'question' | 'resource' | 'series' | 'newsletter'
|
||||
|
||||
@@ -58,7 +59,7 @@ export function useGlobalSearch(content: SiteContent) {
|
||||
.then((data: { episodes?: Array<{ title: string; link: string; description?: string; episode?: string }> }) => {
|
||||
const eps: SearchResult[] = (data.episodes ?? []).map(ep => {
|
||||
// Check if there's a matching podcastFeaturedLink highlight page for this episode number
|
||||
const highlight = content.podcastFeaturedLinks?.find(
|
||||
const highlight = getAllHighlights(content).find(
|
||||
f => f.episodeNumber && ep.episode && String(f.episodeNumber) === String(ep.episode)
|
||||
)
|
||||
const hasRichPage = highlight && !!(
|
||||
@@ -76,7 +77,7 @@ export function useGlobalSearch(content: SiteContent) {
|
||||
setEpisodeItems(eps)
|
||||
})
|
||||
.catch(() => {})
|
||||
}, [content.podcastFeaturedLinks])
|
||||
}, [content])
|
||||
|
||||
// Fetch nuggets episodes once on mount
|
||||
useEffect(() => {
|
||||
|
||||
Reference in new issue
Block a user