Skip to content

Commit 904d539

Browse files
committed
added styling to error page
1 parent 0d0092e commit 904d539

File tree

2 files changed

+32
-3
lines changed

2 files changed

+32
-3
lines changed

pages/_error/+Page.client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@ function pageDoesntExist() {
1212
h('h1', "404"),
1313
h('h2', "The rock you are looking for doesn't exist. Keep digging."),
1414
h('div.buttons', [
15-
h('button', { onClick: () => history.back() }, "Go back"),
16-
h('a', { href: "/dev/test-site/" }, "Go home")
15+
h('button', { className: "btn", onClick: () => history.back() }, "Go back"),
16+
h('a', { className: "btn", href: "/dev/test-site/" }, "Go home")
1717
]),
1818
])
1919
])

pages/_error/main.styl

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,33 @@
2121
z-index 1
2222
top 0
2323
left 0
24-
opacity .5
24+
opacity .5
25+
26+
.buttons
27+
display flex
28+
gap 100px
29+
justify-content center
30+
margin-top 50px
31+
32+
a
33+
color black
34+
text-decoration none
35+
36+
a:hover
37+
color black
38+
background-color rgba(100, 100, 100, 1)
39+
40+
.btn, button
41+
padding 10px 20px
42+
font-size 20px
43+
border none
44+
background-color white
45+
color black
46+
cursor pointer
47+
border-radius 5px
48+
transition background-color 0.3s ease
49+
50+
button:hover
51+
background-color rgba(100, 100, 100, 1)
52+
53+

0 commit comments

Comments
 (0)