Skip to content

Commit a80b446

Browse files
author
GitHub Actions
committed
Deploy HyperfocusSurfer/HyperfocusSurfer.github.io to HyperfocusSurfer/HyperfocusSurfer.github.io:gh-pages
0 parents  commit a80b446

22 files changed

Lines changed: 1960 additions & 0 deletions

.nojekyll

Whitespace-only changes.

404.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<!doctype html>
2+
<title>404 Not Found</title>
3+
<h1>404 Not Found</h1>

CNAME

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
feather.doomy.org

elasticlunr.min.js

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

feather.css

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

index.html

Lines changed: 182 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,182 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
4+
<head>
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
6+
<meta http-equiv="content-type" content="text/html; charset=utf-8">
7+
8+
<!-- Enable responsiveness on mobile devices-->
9+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
10+
11+
<title></title>
12+
<meta name="description" content="">
13+
14+
15+
16+
17+
18+
19+
20+
21+
<!-- css -->
22+
<noscript>
23+
<style>
24+
.theme-switcher {
25+
display: none;
26+
}
27+
</style>
28+
</noscript>
29+
<link rel="stylesheet" href="/reset.css">
30+
<link rel="stylesheet" href="/feather.css">
31+
32+
33+
<link rel="stylesheet" href="/syntax-theme-light.css" media="screen" />
34+
<link rel="stylesheet" href="/syntax-theme-dark.css" media="screen and (prefers-color-scheme: dark)" />
35+
36+
37+
38+
<link rel="stylesheet" id="syntax" />
39+
40+
41+
42+
43+
44+
45+
46+
</head>
47+
48+
<body >
49+
<div class="root">
50+
51+
<nav>
52+
<div class="flex padded">
53+
<div class="flex fill vcenter">
54+
<a href="/">
55+
<h4>Home</h4>
56+
</a>
57+
</div>
58+
59+
<button class="theme-switcher"></button>
60+
61+
</div>
62+
63+
</nav>
64+
65+
66+
67+
68+
<div class="container">
69+
<div class="posts">
70+
71+
72+
<div class="post">
73+
<div class='info'>
74+
<span>2025 Apr 20</span>
75+
</div>
76+
<a class='header-link' href="&#x2F;pinouts&#x2F;">
77+
<h4 class="title"> On searching for pinouts </h4>
78+
</a>
79+
<p>
80+
Sometimes when you&#x27;re trying to fix or piece together the inner workings of a piece of tech, you may stumble upon an IC that has neither datasheets nor even pinouts publicly available. Here&#x27;s one more relatively simple way that sometimes helps me find the…
81+
</p>
82+
83+
84+
<div class='flex gap-small'>
85+
86+
87+
<a href="https:&#x2F;&#x2F;hyperfocussurfer.github.io&#x2F;tags&#x2F;reverse-engineering&#x2F;"><span class="chip">reverse-engineering</span></a>
88+
89+
</div>
90+
91+
</div>
92+
<hr />
93+
94+
95+
96+
<div class="post">
97+
<div class='info'>
98+
<span>2025 Apr 19</span>
99+
</div>
100+
<a class='header-link' href="&#x2F;squid-api&#x2F;">
101+
<h4 class="title"> On basic &quot;reverse-engineering&quot; of simple web API&#x27;s </h4>
102+
</a>
103+
<p>
104+
So, you have a not actively hostile* website you want to automate some actions with, like a nice music downloader squid.wtf.
105+
Let&#x27;s write a simple script to use it from the terminal.
106+
* i.e. without captchas on every corner and stuff
107+
Recording the network t…
108+
</p>
109+
110+
111+
<div class='flex gap-small'>
112+
113+
114+
<a href="https:&#x2F;&#x2F;hyperfocussurfer.github.io&#x2F;tags&#x2F;web&#x2F;"><span class="chip">web</span></a>
115+
116+
</div>
117+
118+
</div>
119+
<hr />
120+
121+
122+
</div>
123+
</div>
124+
125+
126+
<footer>
127+
128+
<p>
129+
Feather theme by <a href="https://doomy.org">doomy</a>&nbsp;&nbsp;-&nbsp;&nbsp; Built with <a
130+
href="https://getzola.org">Zola</a>
131+
</p>
132+
133+
</footer>
134+
</div>
135+
136+
<script>
137+
function change_theme(theme) {
138+
if (theme == "light") {
139+
document.body.classList.remove("dark");
140+
document.body.classList.add("light");
141+
document.querySelector('#syntax').href = '/syntax-theme-light.css';
142+
} else if (theme == "dark") {
143+
document.body.classList.add("dark");
144+
document.body.classList.remove("light");
145+
document.querySelector('#syntax').href = '/syntax-theme-dark.css';
146+
}
147+
localStorage.setItem("theme", theme);
148+
}
149+
150+
window.addEventListener('load', () => {
151+
// Select the button
152+
const theme = (function () {
153+
const stored = localStorage.getItem("theme");
154+
if (stored == "null") {
155+
if (window.matchMedia("(prefers-color-scheme: dark)").matches) {
156+
return "dark";
157+
} else {
158+
return "light";
159+
}
160+
} else {
161+
return stored;
162+
}
163+
})();
164+
165+
change_theme(theme);
166+
167+
// Listen for a click on the button
168+
document.querySelector(".theme-switcher").addEventListener("click", function () {
169+
if (!document.body.classList.contains("dark")) {
170+
change_theme("dark");
171+
} else {
172+
change_theme("light");
173+
}
174+
});
175+
176+
});
177+
</script>
178+
179+
<script src="/js/footnote.js"></script>
180+
</body>
181+
182+
</html>

js/cusdis.es.js

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
window.CUSDIS = {};
2+
let e;
3+
function t(t) {
4+
return (
5+
e ||
6+
((e = document.createElement("iframe")),
7+
(function (e, t) {
8+
const s = window.matchMedia("(prefers-color-scheme: dark)"),
9+
d = (d) => {
10+
try {
11+
const i = JSON.parse(d.data);
12+
if ("cusdis" === i.from)
13+
switch (i.event) {
14+
case "onload":
15+
"auto" === t.dataset.theme &&
16+
n("setTheme", s.matches ? "dark" : "light");
17+
break;
18+
case "resize":
19+
e.style.height = i.data + "px";
20+
}
21+
} catch (i) {}
22+
};
23+
function i(e) {
24+
const s = e.matches;
25+
"auto" === t.dataset.theme && n("setTheme", s ? "dark" : "light");
26+
}
27+
window.addEventListener("message", d), s.addEventListener("change", i);
28+
})(e, t)),
29+
(e.srcdoc = ((e) => {
30+
const t = e.dataset.host || "https://cusdis.com",
31+
n = e.dataset.iframe || `${t}/js/iframe.umd.js`;
32+
return `<!DOCTYPE html>\n<html>\n <head>\n <link rel="stylesheet" href="${t}/js/style.css">\n <base target="_parent" />\n <link>\n <script>\n window.CUSDIS_LOCALE = ${JSON.stringify(window.CUSDIS_LOCALE)}\n window.__DATA__ = ${JSON.stringify(e.dataset)}\n <\/script>\n <style>\n :root {\n color-scheme: light;\n }\n .dark {background: #111622;} </style>\n </head>\n <body>\n <div id="root"></div>\n <script src="${n}" type="module">\n \n <\/script>\n </body>\n</html>`;
33+
})(t)),
34+
(e.style.width = "100%"),
35+
(e.style.border = "0"),
36+
e
37+
);
38+
}
39+
function n(t, n) {
40+
e &&
41+
e.contentWindow.postMessage(
42+
JSON.stringify({ from: "cusdis", event: t, data: n }),
43+
);
44+
}
45+
function s(e) {
46+
if (e) {
47+
e.innerHTML = "";
48+
const n = t(e);
49+
e.appendChild(n);
50+
}
51+
}
52+
function d() {
53+
let e;
54+
window.cusdisElementId
55+
? (e = document.querySelector(`#${window.cusdisElementId}`))
56+
: document.querySelector("#cusdis_thread")
57+
? (e = document.querySelector("#cusdis_thread"))
58+
: document.querySelector("#cusdis") &&
59+
(console.warn(
60+
"id `cusdis` is deprecated. Please use `cusdis_thread` instead",
61+
),
62+
(e = document.querySelector("#cusdis"))),
63+
!0 === window.CUSDIS_PREVENT_INITIAL_RENDER || (e && s(e));
64+
}
65+
(window.renderCusdis = s),
66+
(window.CUSDIS.renderTo = s),
67+
(window.CUSDIS.setTheme = function (e) {
68+
n("setTheme", e);
69+
}),
70+
(window.CUSDIS.initial = d),
71+
d();

js/footnote.js

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
(function () {
2+
const Y_OFFSET = 36.0;
3+
const ID = "definition_popup";
4+
// Create hidden definition popup
5+
let definition_popup = document.createElement("DIV");
6+
definition_popup.style.position = "absolute";
7+
definition_popup.style.opacity = 0;
8+
definition_popup.style.transition = "200ms opacity ease";
9+
definition_popup.style.display = "none";
10+
definition_popup.id = ID;
11+
document.body.append(definition_popup);
12+
13+
let references = document.querySelectorAll(".footnote-reference>a");
14+
references.forEach((reference_el) => {
15+
// Get the definition of each reference
16+
let definition_el = document.querySelector(reference_el.hash);
17+
let definition = definition_el.querySelector("p").innerHTML;
18+
reference_el.addEventListener("mouseover", (ev) => {
19+
// Show popup text
20+
let definition_popup = document.getElementById(ID);
21+
definition_popup.innerHTML = definition;
22+
definition_popup.style.display = "block";
23+
// Move to absolute position
24+
let origin_y = reference_el.offsetTop;
25+
let origin_x = reference_el.offsetLeft;
26+
27+
definition_popup.style.top = origin_y + Y_OFFSET + "px";
28+
definition_popup.style.left = origin_x + "px";
29+
definition_popup.style.opacity = 1;
30+
});
31+
reference_el.addEventListener("mouseleave", (ev) => {
32+
let definition_popup = document.getElementById(ID);
33+
definition_popup.style.opacity = 0;
34+
definition_popup.innerHTML = "";
35+
definition_popup.style.display = "none";
36+
});
37+
38+
39+
console.dir(definition)
40+
});
41+
42+
})();
43+
44+
// <div id="footnote-box"></div>

0 commit comments

Comments
 (0)