feat: give unit title unique CSS class, preserving existing size

This commit is contained in:
nsprenkle
2025-12-02 15:14:18 -05:00
parent 85b0571335
commit bfefacb940
2 changed files with 6 additions and 4 deletions

View File

@@ -302,6 +302,11 @@
padding-left: 40px;
padding-right: 40px;
}
// Unit title is styled as an H3
.unit-title {
font-size: var(--pgn-typography-font-size-h3-base);
}
}
.unit-iframe-wrapper {

View File

@@ -27,10 +27,7 @@ const UnitTitleSlot = ({
>
<div className="d-flex justify-content-between">
<div className="mb-0">
{/* Unit title must be h1 as the page's primary heading for screen reader and accessibility compliance.
See: https://edx.readthedocs.io/projects/open-edx-building-and-running-a-course/en/latest/course_components/create_html_component.html#the-visual-editor
JIRA: https://2u-internal.atlassian.net/browse/AU-2135 */}
<h1 className="h3">{unit.title}</h1>
<h1 className="unit-title">{unit.title}</h1>
</div>
{isEnabledOutlineSidebar && renderUnitNavigation(true)}
</div>