Skip to content

Commit 7be2e67

Browse files
author
Fergus Bisset
committed
fix(Header): centre logo alignment in branded header
1 parent 1ba2e3f commit 7be2e67

File tree

2 files changed

+79
-73
lines changed

2 files changed

+79
-73
lines changed

dist/meta/components.json

Lines changed: 73 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"version": "0.0.44-alpha.13",
3-
"generatedAt": "2025-10-26T13:03:33.187Z",
2+
"version": "0.0.44-alpha.14",
3+
"generatedAt": "2025-10-26T13:04:31.353Z",
44
"count": 18,
55
"components": {
66
"Textarea": {
@@ -343,6 +343,50 @@
343343
],
344344
"source": "src/components/Radios/Radios.schema.ts"
345345
},
346+
"Panel": {
347+
"name": "Panel",
348+
"category": "content",
349+
"since": "0.1.1",
350+
"props": [
351+
{
352+
"name": "id",
353+
"type": "string",
354+
"description": "Unique identifier"
355+
},
356+
{
357+
"name": "className",
358+
"type": "string",
359+
"description": "Additional CSS classes"
360+
},
361+
{
362+
"name": "headingText",
363+
"type": "string",
364+
"description": "Heading text (ignored if headingHtml is provided)"
365+
},
366+
{
367+
"name": "headingHtml",
368+
"type": "string",
369+
"description": "Heading HTML (overrides headingText)"
370+
},
371+
{
372+
"name": "headingLevel",
373+
"type": "1|2|3|4|5|6",
374+
"defaultValue": "2",
375+
"description": "Heading level to render for the heading"
376+
},
377+
{
378+
"name": "bodyText",
379+
"type": "string",
380+
"description": "Body text (ignored if bodyHtml is provided)"
381+
},
382+
{
383+
"name": "bodyHtml",
384+
"type": "string",
385+
"description": "Body HTML (overrides bodyText)"
386+
}
387+
],
388+
"source": "src/components/Panel/Panel.schema.ts"
389+
},
346390
"Label": {
347391
"name": "Label",
348392
"category": "form",
@@ -547,49 +591,51 @@
547591
],
548592
"source": "src/components/Input/Input.schema.ts"
549593
},
550-
"Panel": {
551-
"name": "Panel",
552-
"category": "content",
594+
"Heading": {
595+
"name": "Heading",
596+
"category": "typography",
553597
"since": "0.1.1",
598+
"a11yNotes": [
599+
"Allows separation of visual size from semantic level to maintain proper document outline."
600+
],
554601
"props": [
555602
{
556-
"name": "id",
557-
"type": "string",
558-
"description": "Unique identifier"
603+
"name": "level",
604+
"type": "1|2|3|4|5|6",
605+
"description": "Semantic heading level (h1-h6); auto-derived from size if omitted"
606+
},
607+
{
608+
"name": "size",
609+
"type": "'xs'|'s'|'m'|'l'|'xl'|'xxl'",
610+
"description": "Visual size variant"
559611
},
560612
{
561613
"name": "className",
562614
"type": "string",
563615
"description": "Additional CSS classes"
564616
},
565617
{
566-
"name": "headingText",
618+
"name": "text",
567619
"type": "string",
568-
"description": "Heading text (ignored if headingHtml is provided)"
620+
"description": "Plain text content"
569621
},
570622
{
571-
"name": "headingHtml",
623+
"name": "html",
572624
"type": "string",
573-
"description": "Heading HTML (overrides headingText)"
574-
},
575-
{
576-
"name": "headingLevel",
577-
"type": "1|2|3|4|5|6",
578-
"defaultValue": "2",
579-
"description": "Heading level to render for the heading"
625+
"description": "HTML content (unsafe unless trusted); ignored if children provided"
580626
},
581627
{
582-
"name": "bodyText",
583-
"type": "string",
584-
"description": "Body text (ignored if bodyHtml is provided)"
628+
"name": "children",
629+
"type": "ReactNode|string",
630+
"description": "Explicit node content overrides text/html"
585631
},
586632
{
587-
"name": "bodyHtml",
633+
"name": "marginBottom",
588634
"type": "string",
589-
"description": "Body HTML (overrides bodyText)"
635+
"description": "Custom CSS margin-bottom value"
590636
}
591637
],
592-
"source": "src/components/Panel/Panel.schema.ts"
638+
"source": "src/components/Heading/Heading.schema.ts"
593639
},
594640
"Hint": {
595641
"name": "Hint",
@@ -618,52 +664,6 @@
618664
],
619665
"source": "src/components/Hint/Hint.schema.ts"
620666
},
621-
"Heading": {
622-
"name": "Heading",
623-
"category": "typography",
624-
"since": "0.1.1",
625-
"a11yNotes": [
626-
"Allows separation of visual size from semantic level to maintain proper document outline."
627-
],
628-
"props": [
629-
{
630-
"name": "level",
631-
"type": "1|2|3|4|5|6",
632-
"description": "Semantic heading level (h1-h6); auto-derived from size if omitted"
633-
},
634-
{
635-
"name": "size",
636-
"type": "'xs'|'s'|'m'|'l'|'xl'|'xxl'",
637-
"description": "Visual size variant"
638-
},
639-
{
640-
"name": "className",
641-
"type": "string",
642-
"description": "Additional CSS classes"
643-
},
644-
{
645-
"name": "text",
646-
"type": "string",
647-
"description": "Plain text content"
648-
},
649-
{
650-
"name": "html",
651-
"type": "string",
652-
"description": "HTML content (unsafe unless trusted); ignored if children provided"
653-
},
654-
{
655-
"name": "children",
656-
"type": "ReactNode|string",
657-
"description": "Explicit node content overrides text/html"
658-
},
659-
{
660-
"name": "marginBottom",
661-
"type": "string",
662-
"description": "Custom CSS margin-bottom value"
663-
}
664-
],
665-
"source": "src/components/Heading/Heading.schema.ts"
666-
},
667667
"Fieldset": {
668668
"name": "Fieldset",
669669
"category": "form",
@@ -1130,13 +1130,13 @@
11301130
"Tag"
11311131
],
11321132
"content": [
1133-
"InsetText",
11341133
"Panel",
1134+
"InsetText",
11351135
"Details"
11361136
],
11371137
"typography": [
1138-
"Hint",
1139-
"Heading"
1138+
"Heading",
1139+
"Hint"
11401140
],
11411141
"uncategorised": [
11421142
"CharacterCount",

src/components/Header/Header.brand.fdp.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@
66
[data-brand="fdp"] {
77
// FDP brand defaults: white header background and appropriate text/link colors
88
.nhsuk-header {
9+
10+
// Centre justify the FDP logo / service area.
11+
.nhsuk-header__service {
12+
justify-content: center;
13+
}
14+
915
// Allow per-consumer overrides via CSS custom properties with semantic fallbacks
1016
background-color: var(
1117
--fdp-header-bg,

0 commit comments

Comments
 (0)