Skip to content

Commit a6a84a0

Browse files
carlhaggrenmemagu
andauthored
Make button pretty (#937)
* Make button pretty 2 hours to make the button look better * Make button square Button is no longer weirdly rectangular * Fix formatting --------- Co-authored-by: Melker Widén <85902964+memagu@users.noreply.github.com>
1 parent c4d98b1 commit a6a84a0

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/lib/components/GlobalAlert.svelte

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
})();
2222
</script>
2323

24-
<div role="alert" class={`alert alert-${severity} rounded-none`}>
24+
<div role="alert" class={`alert alert-${severity} gap-1 rounded-none`}>
2525
<span class={`${icon} text-xl`}></span>
2626
<span class="font-bold prose-a:link">
2727
<!-- eslint-disable-next-line svelte/no-at-html-tags -- Sanitized client-side -->
@@ -30,6 +30,7 @@
3030
<form
3131
method="POST"
3232
action="/api/closeAlert"
33+
class="h-7 w-20 border-t-[1.5px] border-black border-opacity-20 sm:h-[unset] sm:w-7 sm:border-0"
3334
on:submit={(e) => {
3435
e.preventDefault();
3536
const ACTION_URL = "/api/closeAlert";
@@ -47,7 +48,11 @@
4748
}).then(() => invalidate("alerts"));
4849
}}
4950
>
50-
<button class="p-2 font-black"> ✕ </button>
51+
<button
52+
class="mt-1 aspect-square h-7 w-7 rounded-lg bg-transparent font-black transition hover:bg-white/20 sm:mt-0"
53+
>
54+
55+
</button>
5156
<input type="hidden" name="alertId" value={id} />
5257
</form>
5358
</div>

0 commit comments

Comments
 (0)