forked from califa/unify-loader
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
105 lines (94 loc) · 2.9 KB
/
Copy pathindex.html
File metadata and controls
105 lines (94 loc) · 2.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Unify Loader</title>
<link rel="icon" media="(prefers-color-scheme: light)" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect x='7' y='7' width='18' height='18' fill='%23FAF7F4' stroke='%23241E20' stroke-width='3'/%3E%3C/svg%3E">
<link rel="icon" media="(prefers-color-scheme: dark)" href="data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3E%3Crect x='7' y='7' width='18' height='18' fill='%231B191A' stroke='%23F4EEE8' stroke-width='3'/%3E%3C/svg%3E">
<style>
:root {
color-scheme: light dark;
--loader-background: #faf7f4;
--loader-foreground: #241e20;
--loader-focus: #fe3c01;
background: var(--loader-background);
}
@media (prefers-color-scheme: dark) {
:root {
--loader-background: #1B191A;
--loader-foreground: #f4eee8;
}
}
* {
box-sizing: border-box;
}
html,
body {
width: 100%;
min-width: 100%;
min-height: 100%;
margin: 0;
background: var(--loader-background);
}
body {
overflow: hidden;
background: var(--loader-background);
}
.loader-page {
position: relative;
width: 100vw;
height: 100vh;
min-height: 520px;
overflow: hidden;
background: var(--loader-background);
}
.loader-canvas {
position: absolute;
left: 50%;
top: 50%;
width: 100vmax;
height: 100vmax;
display: block;
background: transparent;
transform: translate(-50%, -50%);
}
.loader-end-button {
position: absolute;
left: 50%;
bottom: 28px;
z-index: 1;
min-width: 112px;
height: 40px;
padding: 0 18px;
border: 1px solid var(--loader-foreground);
border-radius: 999px;
color: var(--loader-background);
background: var(--loader-foreground);
font: 500 14px/1 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
cursor: pointer;
transform: translateX(-50%);
transition: background 160ms ease, color 160ms ease, opacity 160ms ease;
}
.loader-end-button:hover:not(:disabled) {
color: var(--loader-foreground);
background: var(--loader-background);
}
.loader-end-button:focus-visible {
outline: 2px solid var(--loader-focus);
outline-offset: 3px;
}
.loader-end-button:disabled {
cursor: default;
opacity: 0.56;
}
</style>
</head>
<body>
<main class="loader-page">
<canvas id="loaderCanvas" class="loader-canvas" aria-label="Unify loading animation"></canvas>
<button id="endLoadButton" class="loader-end-button" type="button">End Load</button>
</main>
<script type="module" src="/src/main.ts"></script>
</body>
</html>