Skip to content

Commit

Permalink
fix(lists): Fixing style of links with icons - FRONT-4700 (#3746)
Browse files Browse the repository at this point in the history
  • Loading branch information
planctus authored Dec 11, 2024
1 parent 3ecc744 commit 652cf1d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ $list: null !default;
}

.ecl-link,
.ecl-link .ecl-link__label,
%ecl-ordered-list-link {
text-decoration: none;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ $list: null !default;
}

.ecl-link,
.ecl-link .ecl-link__label,
%ecl-unordered-list-link {
text-decoration: none;

Expand Down
10 changes: 9 additions & 1 deletion src/specs/components/ordered-list/demo/data--link.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
const iconPath = require('@ecl/resources-icons/dist/sprites/icons.svg');

const publicUrl = process.env.PUBLIC_URL || '';
const exampleLink = `${publicUrl}/example`;

Expand All @@ -24,7 +26,13 @@ module.exports = {
label: `<a class="ecl-link" href="${exampleLink}">Morbi vitae tortor accumsan</a>`,
},
{
label: `<a class="ecl-link" href="${exampleLink}">Nulla facilisi</a>`,
label: `<a href="${exampleLink}" class="ecl-link ecl-link--icon">
<span class="ecl-link__label">Phasellus suscipit</span>
<svg class="ecl-icon ecl-icon--2xs ecl-link__icon" focusable="false" aria-hidden="false" role="img">
<title>Link to an external domain</title>
<use xlink:href="${iconPath}#external"></use>
</svg>
</a>`,
},
{
label: `<a class="ecl-link" href="${exampleLink}">Phasellus in metus et libero scelerisque sagittis sollicitudin at lectus</a>`,
Expand Down

1 comment on commit 652cf1d

@github-actions
Copy link

Choose a reason for hiding this comment

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

Please sign in to comment.