Skip to content
This repository has been archived by the owner on Aug 13, 2023. It is now read-only.

Commit

Permalink
Merge pull request #3328 from bbc/section-label-bug
Browse files Browse the repository at this point in the history
Invalid HTML bug in section label
  • Loading branch information
OlgaLyubin authored Apr 6, 2020
2 parents d0b421a + eeec85e commit 9087583
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 33 deletions.
1 change: 1 addition & 0 deletions packages/components/psammead-section-label/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<!-- prettier-ignore -->
| Version | Description |
|---------|-------------|
| 5.0.3 | [PR#3328](https://github.com/bbc/psammead/pull/3328) Replace a `div` with a `span` tag to fix invalid HTML syntax |
| 5.0.2 | [PR#3262](https://github.com/bbc/psammead/pull/3262) Add `backgroundColor` prop |
| 5.0.1 | [PR#3195](https://github.com/bbc/psammead/pull/3195) Define `z-index` on section-label wrapper |
| 5.0.0 | [PR#3133](https://github.com/bbc/psammead/pull/3133) Change background colour from white to ghost |
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/components/psammead-section-label/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@bbc/psammead-section-label",
"version": "5.0.2",
"version": "5.0.3",
"description": "React styled component for a section label",
"main": "dist/index.js",
"module": "esm/index.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ exports[`SectionLabel When hideSectionHeader is true should add styling to hide
<h2
class="c1"
>
<div
<span
class="c2"
>
<span
Expand All @@ -136,7 +136,7 @@ exports[`SectionLabel When hideSectionHeader is true should add styling to hide
This is the text in a SectionLabel
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -336,7 +336,7 @@ exports[`SectionLabel With bar With linking title should render correctly 1`] =
class="c3"
href="/igbo/other-index"
>
<div
<span
class="c4"
>
<span
Expand All @@ -358,7 +358,7 @@ exports[`SectionLabel With bar With linking title should render correctly 1`] =
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -559,7 +559,7 @@ exports[`SectionLabel With bar With linking title should render correctly with a
class="c3"
href="/igbo/other-index"
>
<div
<span
class="c4"
>
<span
Expand All @@ -581,7 +581,7 @@ exports[`SectionLabel With bar With linking title should render correctly with a
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -782,7 +782,7 @@ exports[`SectionLabel With bar With linking title should render correctly with e
class="c3"
href="/igbo/other-index"
>
<div
<span
class="c4"
>
<span
Expand All @@ -804,7 +804,7 @@ exports[`SectionLabel With bar With linking title should render correctly with e
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -1005,7 +1005,7 @@ exports[`SectionLabel With bar With linking title should render correctly with e
class="c3"
href="/igbo/other-index"
>
<div
<span
class="c4"
>
<span
Expand All @@ -1027,7 +1027,7 @@ exports[`SectionLabel With bar With linking title should render correctly with e
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -1170,7 +1170,7 @@ exports[`SectionLabel With bar With plain title should render correctly 1`] = `
<h2
class="c2"
>
<div
<span
class="c3"
>
<span
Expand All @@ -1184,7 +1184,7 @@ exports[`SectionLabel With bar With plain title should render correctly 1`] = `
This is text in a SectionLabel.
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -1326,7 +1326,7 @@ exports[`SectionLabel With bar With plain title should render correctly with ara
<h2
class="c2"
>
<div
<span
class="c3"
>
<span
Expand All @@ -1340,7 +1340,7 @@ exports[`SectionLabel With bar With plain title should render correctly with ara
بعض محتوى النص
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -1482,7 +1482,7 @@ exports[`SectionLabel With bar With plain title should render correctly with exp
<h2
class="c2"
>
<div
<span
class="c3"
>
<span
Expand All @@ -1496,7 +1496,7 @@ exports[`SectionLabel With bar With plain title should render correctly with exp
This is text in a SectionLabel rendering in ltr mode.
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -1638,7 +1638,7 @@ exports[`SectionLabel With bar With plain title should render correctly with exp
<h2
class="c2"
>
<div
<span
class="c3"
>
<span
Expand All @@ -1652,7 +1652,7 @@ exports[`SectionLabel With bar With plain title should render correctly with exp
This is text in a SectionLabel, and there is a bar over to the right
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -1829,7 +1829,7 @@ exports[`SectionLabel Without bar With linking title should render correctly 1`]
class="c2"
href="/igbo/other-index"
>
<div
<span
class="c3"
>
<span
Expand All @@ -1851,7 +1851,7 @@ exports[`SectionLabel Without bar With linking title should render correctly 1`]
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -2029,7 +2029,7 @@ exports[`SectionLabel Without bar With linking title should render correctly wit
class="c2"
href="/igbo/other-index"
>
<div
<span
class="c3"
>
<span
Expand All @@ -2051,7 +2051,7 @@ exports[`SectionLabel Without bar With linking title should render correctly wit
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -2229,7 +2229,7 @@ exports[`SectionLabel Without bar With linking title should render correctly wit
class="c2"
href="/igbo/other-index"
>
<div
<span
class="c3"
>
<span
Expand All @@ -2251,7 +2251,7 @@ exports[`SectionLabel Without bar With linking title should render correctly wit
See All
</span>
</span>
</div>
</span>
</a>
</h2>
</div>
Expand Down Expand Up @@ -2371,7 +2371,7 @@ exports[`SectionLabel Without bar With plain title should render correctly 1`] =
<h2
class="c1"
>
<div
<span
class="c2"
>
<span
Expand All @@ -2385,7 +2385,7 @@ exports[`SectionLabel Without bar With plain title should render correctly 1`] =
This is text in a SectionLabel.
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -2504,7 +2504,7 @@ exports[`SectionLabel Without bar With plain title should render correctly with
<h2
class="c1"
>
<div
<span
class="c2"
>
<span
Expand All @@ -2518,7 +2518,7 @@ exports[`SectionLabel Without bar With plain title should render correctly with
بعض محتوى النص
</span>
</span>
</div>
</span>
</h2>
</div>
`;
Expand Down Expand Up @@ -2637,7 +2637,7 @@ exports[`SectionLabel Without bar With plain title should render correctly with
<h2
class="c1"
>
<div
<span
class="c2"
>
<span
Expand All @@ -2651,7 +2651,7 @@ exports[`SectionLabel Without bar With plain title should render correctly with
This is text in a SectionLabel rendering in ltr mode.
</span>
</span>
</div>
</span>
</h2>
</div>
`;
2 changes: 1 addition & 1 deletion packages/components/psammead-section-label/src/titles.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const paddingReverseDir = ({ dir }) =>
// This makes it work right. I don't fully understand how, but am
// eternally grateful to the Flexbugs project.
// https://github.com/philipwalton/flexbugs#flexbug-3
const FlexColumn = styled.div`
const FlexColumn = styled.span`
display: flex;
flex-direction: column;
`;
Expand Down

0 comments on commit 9087583

Please sign in to comment.