@sansynx/erroratlas 0.1.3 → 0.1.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/README.md +3 -18
- package/dist/worker/assets.js +1 -0
- package/dist/worker/index.js +18 -1
- package/package.json +1 -1
- package/public/sequence.png +0 -0
package/dist/worker/index.js
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
import { buildPlaybookMarkdown, errorSignature, redactText, titleFromError } from "../shared/redaction";
|
|
2
|
-
import { faviconSvg } from "./assets";
|
|
2
|
+
import { faviconSvg, sequencePngBase64 } from "./assets";
|
|
3
|
+
function base64ToArrayBuffer(value) {
|
|
4
|
+
const binary = atob(value);
|
|
5
|
+
const buffer = new ArrayBuffer(binary.length);
|
|
6
|
+
const bytes = new Uint8Array(buffer);
|
|
7
|
+
for (let index = 0; index < binary.length; index += 1) {
|
|
8
|
+
bytes[index] = binary.charCodeAt(index);
|
|
9
|
+
}
|
|
10
|
+
return buffer;
|
|
11
|
+
}
|
|
3
12
|
import { encryptSensitivePayload } from "./crypto";
|
|
4
13
|
import { clampLimit, handleError, html, json, options, randomToken, readJson, sha256Hex, text } from "./http";
|
|
5
14
|
import { configured, requireScope, resolveActor, supabaseRest } from "./supabase";
|
|
@@ -28,6 +37,14 @@ export default {
|
|
|
28
37
|
if (request.method === "GET" && (url.pathname === "/favicon.svg" || url.pathname === "/public/favicon.svg")) {
|
|
29
38
|
return text(faviconSvg, 200, "image/svg+xml; charset=utf-8");
|
|
30
39
|
}
|
|
40
|
+
if (request.method === "GET" && (url.pathname === "/sequence.png" || url.pathname === "/public/sequence.png")) {
|
|
41
|
+
return new Response(base64ToArrayBuffer(sequencePngBase64), {
|
|
42
|
+
headers: {
|
|
43
|
+
"cache-control": "public, max-age=86400",
|
|
44
|
+
"content-type": "image/png",
|
|
45
|
+
},
|
|
46
|
+
});
|
|
47
|
+
}
|
|
31
48
|
if (request.method === "GET" && url.pathname === "/setup") {
|
|
32
49
|
return html(renderSetupGuideUi(env, url.origin));
|
|
33
50
|
}
|
package/package.json
CHANGED
|
Binary file
|