@arkstack/common 0.6.2 → 0.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -2
- package/resources/views/error.edge +199 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@arkstack/common",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Shared foundations and core utilities for Arkstack applications and packages.",
|
|
6
6
|
"homepage": "https://arkstack.toneflix.net",
|
|
@@ -20,7 +20,8 @@
|
|
|
20
20
|
"arkstack"
|
|
21
21
|
],
|
|
22
22
|
"files": [
|
|
23
|
-
"dist"
|
|
23
|
+
"dist",
|
|
24
|
+
"resources"
|
|
24
25
|
],
|
|
25
26
|
"publishConfig": {
|
|
26
27
|
"access": "public"
|
|
@@ -0,0 +1,199 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
|
|
4
|
+
<head>
|
|
5
|
+
<meta charset="UTF-8" />
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
7
|
+
<title>{{ code }} | {{ title }}</title>
|
|
8
|
+
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
9
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
10
|
+
<link href="https://fonts.googleapis.com/css2?family=Syne:wght@700;800&family=DM+Mono:wght@400;500&display=swap"
|
|
11
|
+
rel="stylesheet" />
|
|
12
|
+
<style>
|
|
13
|
+
*,
|
|
14
|
+
*::before,
|
|
15
|
+
*::after {
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
margin: 0;
|
|
18
|
+
padding: 0;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/* ── Dark theme (default) ── */
|
|
22
|
+
:root {
|
|
23
|
+
--gold-light: #f0c040;
|
|
24
|
+
--gold-mid: #c9960c;
|
|
25
|
+
--bg: #0b0c0e;
|
|
26
|
+
--bg-card: #111317;
|
|
27
|
+
--bg-stack: #0d0f12;
|
|
28
|
+
--border: rgba(201, 150, 12, 0.18);
|
|
29
|
+
--border-err: rgba(220, 60, 60, 0.22);
|
|
30
|
+
--text: #f5f0e8;
|
|
31
|
+
--muted: #7a7567;
|
|
32
|
+
--red: #e05252;
|
|
33
|
+
--radius: 10px;
|
|
34
|
+
--pre-color: #c0a888;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/* ── Light theme ── */
|
|
38
|
+
[data-theme="light"] {
|
|
39
|
+
--gold-light: #a06800;
|
|
40
|
+
--gold-mid: #8a5a00;
|
|
41
|
+
--bg: #f5f3ef;
|
|
42
|
+
--bg-card: #ffffff;
|
|
43
|
+
--bg-stack: #faf8f5;
|
|
44
|
+
--border: rgba(160, 104, 0, 0.16);
|
|
45
|
+
--border-err: rgba(180, 40, 40, 0.18);
|
|
46
|
+
--text: #1a1714;
|
|
47
|
+
--muted: #9a9080;
|
|
48
|
+
--red: #c0392b;
|
|
49
|
+
--pre-color: #6a5040;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/* ── OS preference fallback (no JS) ── */
|
|
53
|
+
@media (prefers-color-scheme: light) {
|
|
54
|
+
:root:not([data-theme="dark"]) {
|
|
55
|
+
--gold-light: #a06800;
|
|
56
|
+
--gold-mid: #8a5a00;
|
|
57
|
+
--bg: #f5f3ef;
|
|
58
|
+
--bg-card: #ffffff;
|
|
59
|
+
--bg-stack: #faf8f5;
|
|
60
|
+
--border: rgba(160, 104, 0, 0.16);
|
|
61
|
+
--border-err: rgba(180, 40, 40, 0.18);
|
|
62
|
+
--text: #1a1714;
|
|
63
|
+
--muted: #9a9080;
|
|
64
|
+
--red: #c0392b;
|
|
65
|
+
--pre-color: #6a5040;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
html,
|
|
70
|
+
body {
|
|
71
|
+
min-height: 100vh;
|
|
72
|
+
background: var(--bg);
|
|
73
|
+
color: var(--text);
|
|
74
|
+
font-family: 'DM Mono', monospace;
|
|
75
|
+
display: flex;
|
|
76
|
+
align-items: center;
|
|
77
|
+
justify-content: center;
|
|
78
|
+
padding: 2rem 1rem;
|
|
79
|
+
transition: background 0.25s, color 0.25s;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.page {
|
|
83
|
+
max-width: 620px;
|
|
84
|
+
width: 100%;
|
|
85
|
+
display: flex;
|
|
86
|
+
flex-direction: column;
|
|
87
|
+
align-items: flex-start;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/* ── Top bar ── */
|
|
91
|
+
.topbar {
|
|
92
|
+
width: 100%;
|
|
93
|
+
display: flex;
|
|
94
|
+
align-items: center;
|
|
95
|
+
justify-content: space-between;
|
|
96
|
+
margin-bottom: 3rem;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/* ── Error heading ── */
|
|
100
|
+
.error-code {
|
|
101
|
+
font-family: 'Syne', sans-serif;
|
|
102
|
+
font-size: 3.5rem;
|
|
103
|
+
font-weight: 800;
|
|
104
|
+
line-height: 1;
|
|
105
|
+
letter-spacing: -0.04em;
|
|
106
|
+
color: var(--red);
|
|
107
|
+
margin-bottom: 0.5rem;
|
|
108
|
+
opacity: 0.9;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.error-title {
|
|
112
|
+
font-family: 'Syne', sans-serif;
|
|
113
|
+
font-size: 1.2rem;
|
|
114
|
+
font-weight: 700;
|
|
115
|
+
color: var(--text);
|
|
116
|
+
margin-bottom: 0.6rem;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.error-message {
|
|
120
|
+
font-size: 0.78rem;
|
|
121
|
+
color: var(--muted);
|
|
122
|
+
line-height: 1.7;
|
|
123
|
+
margin-bottom: 2rem;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/* ── Divider ── */
|
|
127
|
+
.divider {
|
|
128
|
+
width: 100%;
|
|
129
|
+
height: 1px;
|
|
130
|
+
background: linear-gradient(90deg, var(--border-err), transparent);
|
|
131
|
+
margin-bottom: 2rem;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
/* ── Stack trace ── */
|
|
135
|
+
.stack-label {
|
|
136
|
+
font-size: 0.65rem;
|
|
137
|
+
letter-spacing: 0.14em;
|
|
138
|
+
text-transform: uppercase;
|
|
139
|
+
color: var(--muted);
|
|
140
|
+
margin-bottom: 0.65rem;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.stack-block {
|
|
144
|
+
width: 100%;
|
|
145
|
+
background: var(--bg-stack);
|
|
146
|
+
border: 1px solid var(--border-err);
|
|
147
|
+
border-radius: var(--radius);
|
|
148
|
+
padding: 1.1rem 1.25rem;
|
|
149
|
+
position: relative;
|
|
150
|
+
overflow: hidden;
|
|
151
|
+
transition: background 0.25s, border-color 0.25s;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
.stack-block::before {
|
|
155
|
+
content: '';
|
|
156
|
+
position: absolute;
|
|
157
|
+
top: 0;
|
|
158
|
+
left: 0;
|
|
159
|
+
right: 0;
|
|
160
|
+
height: 2px;
|
|
161
|
+
background: linear-gradient(90deg, var(--red), transparent);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.stack-block pre {
|
|
165
|
+
font-family: 'DM Mono', monospace;
|
|
166
|
+
font-size: 0.72rem;
|
|
167
|
+
color: var(--pre-color);
|
|
168
|
+
line-height: 1.85;
|
|
169
|
+
overflow-x: auto;
|
|
170
|
+
white-space: pre;
|
|
171
|
+
}
|
|
172
|
+
</style>
|
|
173
|
+
</head>
|
|
174
|
+
|
|
175
|
+
<body>
|
|
176
|
+
<div class="page">
|
|
177
|
+
<div class="error-code">{{ code }}</div>
|
|
178
|
+
<div class="error-title">{{ title }}</div>
|
|
179
|
+
<p class="error-message">{{ message }}</p>
|
|
180
|
+
|
|
181
|
+
<div class="divider"></div>
|
|
182
|
+
|
|
183
|
+
@if(stack)
|
|
184
|
+
<div class="stack-label">Stack Trace</div>
|
|
185
|
+
<div class="stack-block">
|
|
186
|
+
<pre>{{ stack }}</pre>
|
|
187
|
+
</div>
|
|
188
|
+
@end
|
|
189
|
+
|
|
190
|
+
</div>
|
|
191
|
+
|
|
192
|
+
<script>
|
|
193
|
+
const root = document.documentElement;
|
|
194
|
+
const prefersDark = window.matchMedia('(prefers-color-scheme: dark)').matches;
|
|
195
|
+
root.setAttribute('data-theme', prefersDark ? 'dark' : 'light');
|
|
196
|
+
</script>
|
|
197
|
+
</body>
|
|
198
|
+
|
|
199
|
+
</html>
|