Skip to content

Commit 05167cb

Browse files
updated icons to include links as well on homepage (#2090)
1 parent c9c7fb5 commit 05167cb

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

docusaurus/src/components/FeaturesList/FeaturesList.jsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ export function FeatureListItem({
1414
...rest
1515
}) {
1616
const ContentElement = ((href || to) ? LinkWithArrow : 'span');
17+
const IconElement = ((href || to) ? 'a' : 'span');
1718

1819
return (
1920
<li
@@ -23,14 +24,17 @@ export function FeatureListItem({
2324
)}
2425
>
2526
{Icon && (
26-
<span
27+
<IconElement
2728
className={clsx(
2829
styles['features-list__item__icon'],
2930
(iconColor && styles[`features-list__item__icon--${iconColor}`]),
3031
)}
32+
href={href}
33+
to={to}
34+
{...(IconElement === 'a' ? { href: to || href } : {})}
3135
>
3236
<Icon />
33-
</span>
37+
</IconElement>
3438
)}
3539
<ContentElement
3640
className={styles['features-list__item__content']}

0 commit comments

Comments
 (0)