fix(BOOK-53): Seo filter block now uses h3 as summary content and adjusted spacing
Approved-by: Bianca Widstam
This commit is contained in:
@@ -17,6 +17,7 @@ export interface AccordionItemProps
|
||||
extends React.HtmlHTMLAttributes<HTMLDetailsElement>,
|
||||
VariantProps<typeof accordionItemVariants> {
|
||||
title: string
|
||||
titleLevel?: 'span' | 'p' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6'
|
||||
iconName?: IconName
|
||||
icon?: ReactNode
|
||||
subtitle?: string
|
||||
@@ -29,6 +30,7 @@ export default function AccordionItem({
|
||||
icon,
|
||||
iconName,
|
||||
title,
|
||||
titleLevel = 'p',
|
||||
type,
|
||||
className,
|
||||
subtitle,
|
||||
@@ -70,6 +72,8 @@ export default function AccordionItem({
|
||||
}
|
||||
}
|
||||
|
||||
const TitleLevel = titleLevel
|
||||
|
||||
return (
|
||||
<li className={accordionItemVariants({ className, type })}>
|
||||
<details ref={detailsRef} onToggle={toggleAccordion}>
|
||||
@@ -83,11 +87,11 @@ export default function AccordionItem({
|
||||
<div className={styles.title}>
|
||||
{subtitle || showAsSubtitle ? (
|
||||
<Typography variant="Title/Subtitle/md">
|
||||
<p className={styles.title}>{title}</p>
|
||||
<TitleLevel className={styles.title}>{title}</TitleLevel>
|
||||
</Typography>
|
||||
) : (
|
||||
<Typography variant="Body/Paragraph/mdBold">
|
||||
<p className={styles.title}>{title}</p>
|
||||
<TitleLevel className={styles.title}>{title}</TitleLevel>
|
||||
</Typography>
|
||||
)}
|
||||
{subtitle && (
|
||||
|
||||
Reference in New Issue
Block a user