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(Link): remove unused attributes and duplicated code #498

Merged
merged 1 commit into from
May 12, 2023

Conversation

pylafleur
Copy link
Contributor

DS-714

L'élément <a> généré par les composants <RouteLink> et <ExternalLink> contiennent un attribut type erroné. Cet attribut existe dans la spec mais devrait contenir un mimetype s'il est utilisé. L'attribut en question a été retiré car il n'était pas utilisé.

De plus, certains attributs sont désuets depuis la migration à react-router v6 (activeClassName).

Finalement, certaines déclarations de style étaient dupliquées dans plusieurs types de liens. Elles ont été ramenées dans le composant abstrait <StyledLink>.

Tests fonctionnels

  • Tous les composants dont le snapshot a changé sont visuellement identiques dans le storybook

@pylafleur pylafleur requested a review from a team as a code owner May 10, 2023 03:54
@@ -807,10 +789,9 @@ exports[`BentoMenuButton Matches Snapshot (productGroups and externalLinks) 1`]
<li>
<a
aria-disabled="true"
class="c24 c25 c20 c21"
class="c24 c19 c20 c21"
Copy link
Contributor

Choose a reason for hiding this comment

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

J'ai pas réussi à trouver l'impact visuel, mais je pense pas que ce bloc soit sur une de ces classes 🤔

.c25:visited {
  color: #62a;
}

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah c'est que le style est override dans le bento, ça servait déjà pas!

@pylafleur pylafleur merged commit 011e30a into master May 12, 2023
19 checks passed
@pylafleur pylafleur deleted the dev/DS-714 branch May 12, 2023 03: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.

None yet

2 participants