diff --git a/src/features/content/renderers/details/QiBloodDetailRenderer.tsx b/src/features/content/renderers/details/QiBloodDetailRenderer.tsx index f7e4677..61dcec1 100644 --- a/src/features/content/renderers/details/QiBloodDetailRenderer.tsx +++ b/src/features/content/renderers/details/QiBloodDetailRenderer.tsx @@ -77,6 +77,11 @@ function parseClinicalManifestations(raw: unknown): string[] { return [text]; } +const DEFAULT_CATEGORY_FALLBACKS: Record = { + qi_and_blood: + "Qi and blood are mutually dependent. Qi generates, moves, and holds blood, while blood nourishes and carries qi. Pathological changes often involve both substances concurrently, manifesting as combined patterns of deficiency and stasis.", +}; + function extractCategoryOverview(data: Record, categoryCode: string): string { const normalizedCode = categoryCode.toLowerCase().replace(/[^a-z0-9_]/g, "_"); @@ -106,6 +111,10 @@ function extractCategoryOverview(data: Record, categoryCode: st return data.content.trim(); } + if (DEFAULT_CATEGORY_FALLBACKS[normalizedCode]) { + return DEFAULT_CATEGORY_FALLBACKS[normalizedCode]; + } + return ""; } diff --git a/src/features/content/renderers/registry.ts b/src/features/content/renderers/registry.ts index 53f3a95..08f74d2 100644 --- a/src/features/content/renderers/registry.ts +++ b/src/features/content/renderers/registry.ts @@ -73,6 +73,11 @@ export const collectionRenderers: Readonly