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

Refactor logo into logo-link #621

Merged
merged 1 commit into from
May 14, 2024
Merged

Refactor logo into logo-link #621

merged 1 commit into from
May 14, 2024

Conversation

LasseStaus
Copy link
Contributor

@LasseStaus LasseStaus commented May 3, 2024

Link to issue

PR dækker to tickets:

DDFFORM-696

DDFFORM-709

Depends on PR in cms: danskernesdigitalebibliotek/dpl-cms#1099

Description

This PR refators the logo markup/css.
The component should now be updated to handle the redirect to frontpage, include an aria-label as requested in DDFFORM-709, and display the image/ fallback of library name and place accordingly.

I have left the UI changes unaccepted until reviewed.

<figure className="logo-link__content">
{hasImage && <img className="logo" src={logo} alt={altText} />}
<div
className={`logo-link__description ${
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should probably use clsx here, not that it makes a big difference

Copy link
Contributor

@kasperbirch1 kasperbirch1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

The current logo CSS / markup is outdated.

This refactors the logo component so that it displays the image, and / or the library name / place accordingly.

This also moves css for the logo away from "Header", as the logo is used elsewhere that the header as well.

Additionally the story has been updated, and any component using the <logo/> component has has its' props updated in accordance with the changes.

This also introduces an aria-label for the logo, which was requested in a seperate ticket: DDFFORM-750

DDFFORM-696
Copy link
Contributor

@rasben rasben left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I checked chromatic, and it looks good.

@LasseStaus LasseStaus merged commit 1737eab into release/hermod-14 May 14, 2024
8 checks passed
@LasseStaus LasseStaus deleted the DDFFORM-696 branch May 14, 2024 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants