summaryrefslogtreecommitdiffstats
path: root/src/components/Buttons/ButtonLink
diff options
context:
space:
mode:
authorArmand Philippot <git@armandphilippot.com>2021-12-29 17:52:21 +0100
committerArmand Philippot <git@armandphilippot.com>2021-12-29 18:01:06 +0100
commit8e0c8c9255ba5ab466d8372fe223efeb5a3f0833 (patch)
tree67102c4c0776f83c8f845266728cb4099a14b41a /src/components/Buttons/ButtonLink
parent76c01d51ccbdd0faaf12b624328a40ef24f33f88 (diff)
chore: replace read more link with ButtonLink component
I also fix the load more button position since I removed the margin auto.
Diffstat (limited to 'src/components/Buttons/ButtonLink')
-rw-r--r--src/components/Buttons/ButtonLink/ButtonLink.tsx6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/components/Buttons/ButtonLink/ButtonLink.tsx b/src/components/Buttons/ButtonLink/ButtonLink.tsx
index 70039a8..a2f75f2 100644
--- a/src/components/Buttons/ButtonLink/ButtonLink.tsx
+++ b/src/components/Buttons/ButtonLink/ButtonLink.tsx
@@ -8,13 +8,17 @@ const ButtonLink = ({
target,
position = 'left',
isExternal = false,
+ hasIcon = false,
}: {
children: ReactNode;
target: string;
position?: ButtonPosition;
isExternal?: boolean;
+ hasIcon?: boolean;
}) => {
- const classes = `${styles.btn} ${styles.link} ${styles[`link--${position}`]}`;
+ const classes = `${styles.btn} ${styles.link} ${styles[`link--${position}`]}${
+ hasIcon ? ` ${styles['link--icon']}` : ''
+ }`;
return isExternal ? (
<a className={classes} href={target}>