diff --git a/src/features/content/renderers/collections/ModuleCatalogRenderers.tsx b/src/features/content/renderers/collections/ModuleCatalogRenderers.tsx index 56579f8..25f15f5 100644 --- a/src/features/content/renderers/collections/ModuleCatalogRenderers.tsx +++ b/src/features/content/renderers/collections/ModuleCatalogRenderers.tsx @@ -22,7 +22,15 @@ export function ModuleCatalogCardRenderer({ }: CollectionItemRendererProps) { const attributes = item.attributes; const title = asString(attributes.name) || item.title; - const label = asString(attributes.content_label) || item.summary || null; + const label = + asString(attributes.sub_title) || + asString(attributes.content_label) || + (asString(attributes.title) && asString(attributes.title) !== title + ? asString(attributes.title) + : null) || + asString(attributes.description) || + item.summary || + null; return ( typeof v==="string"||typeof v==="number").map(([k,v])=>({label:k,value:String(v)}))}/>; } +export function IndexEntryDetailRenderer({content,data,definitions,presentationAttributes}:DetailRendererProps){ + const subtitle = asString(data.sub_title) || asString(data.subtitle) || undefined; + return ( + + + + + typeof v==="string"||typeof v==="number").map(([k,v])=>({label:k,value:String(v)}))}/> + + + + ); +}