Skip to content

Commit b415d12

Browse files
committed
✨ Improve blocks
1 parent d76b966 commit b415d12

File tree

8 files changed

+11
-4
lines changed

8 files changed

+11
-4
lines changed

src/blocks/ErrorPage/ErrorPage.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ const typeStyle = typeColor
3232
{!!buttons?.length && (
3333
<div class="flex xs wrap justify-center">
3434
{buttons?.map(button => (
35-
<Button {...button}>
35+
<Button {...button} icon={null}>
3636
{button.icon && (
3737
<Fragment>
3838
{button.icon.startsWith('<svg')

src/blocks/ErrorPage/ErrorPage.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
{#if buttons?.length}
2727
<div class="flex xs wrap justify-center">
2828
{#each buttons as button}
29-
<Button {...button}>
29+
<Button {...button} icon={null}>
3030
{#if button.icon}
3131
{@html button.icon}
3232
{/if}

src/blocks/ErrorPage/ErrorPage.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ const ErrorPage = ({
3030
<Button
3131
{...button}
3232
key={index}
33+
icon={null}
3334
dangerouslySetInnerHTML={{ __html: button.icon
3435
? `${button.icon} ${button.text}`
3536
: button.text

src/blocks/Hero/Hero.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const classes = [
4343
{!!buttons?.length && (
4444
<div class:list={[styles.cta, 'flex xs wrap']}>
4545
{buttons?.map(button => (
46-
<Button {...button}>
46+
<Button {...button} icon={null}>
4747
{button.icon && (
4848
<Fragment>
4949
{button.icon.startsWith('<svg')

src/blocks/Hero/Hero.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
{#if buttons?.length}
4040
<div class={classNames([styles.cta, 'flex xs wrap'])}>
4141
{#each buttons as button}
42-
<Button {...button}>
42+
<Button {...button} icon={null}>
4343
{#if button.icon}
4444
{@html button.icon}
4545
{/if}

src/blocks/Hero/Hero.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ const Hero = ({
4141
<Button
4242
{...button}
4343
key={index}
44+
icon={null}
4445
dangerouslySetInnerHTML={{ __html: button.icon
4546
? `${button.icon} ${button.text}`
4647
: button.text

src/components/Button/button.module.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,4 +89,8 @@
8989
@include background(alert-accent);
9090
}
9191
}
92+
93+
svg {
94+
pointer-events: none;
95+
}
9296
}

src/components/ConditionalWrapper/conditionalwrapper.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
export type ConditionalWrapperProps = {
22
condition: boolean
3+
[key: string]: any
34
}
45

56
export type ReactConditionalWrapperProps = {

0 commit comments

Comments
 (0)