Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mim 2054 heading size prop links #670

Merged
merged 6 commits into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/Header/Header.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const Header = () => {
const history = useHistory();
const location = useLocation();
const [menuIsOpen, toggleMenu] = useState(false);
const version = 'v2.2.16';
const version = 'v2.3.3';

return (
<div className={`header-component-wrapper${location.pathname === '/get-started' || location.pathname === '/' ? ' front-page' : ''}`}>
Expand Down
25 changes: 19 additions & 6 deletions src/pages/Components/ComponentsInfo/LinksInfo.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,17 +127,22 @@ const profiledLinksIconHtml = `
`;

const headerLinks = `
<Link href=" " linkType="header">This is an header link</Link>
<Link negative href=" " linkType="header">This is an header link</Link>
<Link href=" " linkType="header">This is a header link</Link>
<Link href=" " linkType="header" headingSize={3}>This is a header link with heading 3</Link>
<Link negative href=" " linkType="header">This is a header link</Link>
`;

const headerLinksHtml = `
<a class="ssb-link header" href=" " target="" rel="">
<span class="link-text">This is an header link</span>
<span class="link-text">This is a header link</span>
</a>

<a class="ssb-link header" href=" " target="" rel="">
<h3 class="link-text">This is a header link with heading 3</h3>
</a>

<a class="ssb-link header negative" href=" " target="" rel="">
<span class="link-text">This is an header link</span>
<span class="link-text">This is a header link</span>
</a>
`;

Expand Down Expand Up @@ -395,13 +400,16 @@ const LinksInfo = () => {
</div>
<div className="component-example col-lg col-md-12 divider-left d-flex flex-column align-items-center">
<div className="d-flex justify-content-center mb-4 flex-wrap component-wrapper">
<Link href=" " linkType="header">This is an header link</Link>
<Link href=" " linkType="header">This is a header link</Link>
</div>
<div className="ps-4 mb-4">
<Link href=" " linkType="header" headingSize={3}>This is a header link with heading 3</Link>
</div>
<div className="ps-4 mb-4">
<Link href=" " linkType="header">This is a long header link that will go over several lines</Link>
</div>
<div className="d-flex justify-content-center flex-wrap negative-wrapper">
<Link href=" " linkType="header" negative>This is an header link</Link>
<Link href=" " linkType="header" negative>This is a header link</Link>
</div>
</div>
<div className="col-lg-12">
Expand Down Expand Up @@ -526,6 +534,11 @@ const LinksInfo = () => {
<td>string</td>
<td>Optional container class</td>
</tr>
<tr>
<td><code>headingSize</code></td>
<td>1, 2, 3, 4, 5 or 6</td>
<td>Changes header element size for header links</td>
</tr>
<tr>
<td><code>href</code></td>
<td>string</td>
Expand Down