186 lines
5.0 KiB
HTML
186 lines
5.0 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<link rel="icon" href="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 100'><text y='.9em' font-size='90'>%F0%9F%8C%B1</text></svg>">
|
|
<title>httpx</title>
|
|
|
|
<link rel="preconnect" href="https://fonts.googleapis.com/">
|
|
<link rel="preconnect" href="https://fonts.gstatic.com/" crossorigin="">
|
|
|
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/styles/atom-one-dark.min.css">
|
|
<link rel="stylesheet" href="https://unpkg.com/highlightjs-copy/dist/highlightjs-copy.min.css">
|
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.9.0/highlight.min.js"></script>
|
|
<script src="https://unpkg.com/highlightjs-copy/dist/highlightjs-copy.min.js"></script>
|
|
|
|
<script>
|
|
function hook(text, el) {
|
|
const lines = text.split('\n');
|
|
|
|
if (lines[0].startsWith('>>> ')) {
|
|
return lines
|
|
.filter(line => line.startsWith('>>> ') || line.startsWith('... '))
|
|
.map(line => line.replace(/^>>> |^\.{3} /, ''))
|
|
.join('\n');
|
|
}
|
|
|
|
if (lines[0].startsWith('$ ')) {
|
|
return lines
|
|
.map(line => line.startsWith('$ ') ? line.slice(2) : line)
|
|
.join('\n');
|
|
}
|
|
|
|
return text;
|
|
}
|
|
|
|
function httpx() {
|
|
const httpx = document.querySelectorAll('.httpx');
|
|
httpx.forEach(function(el) {
|
|
el.classList.remove('hidden');
|
|
});
|
|
const ahttpx = document.querySelectorAll('.ahttpx');
|
|
ahttpx.forEach(function(el) {
|
|
el.classList.add('hidden');
|
|
});
|
|
document.cookie = "selection=httpx; path=/;"
|
|
}
|
|
function ahttpx() {
|
|
const httpx = document.querySelectorAll('.httpx');
|
|
httpx.forEach(function(el) {
|
|
el.classList.add('hidden');
|
|
});
|
|
const ahttpx = document.querySelectorAll('.ahttpx');
|
|
ahttpx.forEach(function(el) {
|
|
el.classList.remove('hidden');
|
|
});
|
|
document.cookie = "selection=ahttpx; path=/;"
|
|
}
|
|
hljs.addPlugin(new CopyButtonPlugin({autohide: false, hook: hook}));
|
|
hljs.highlightAll();
|
|
</script>
|
|
<style>
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
font-family: "Poppins", Sans-serif;
|
|
line-height: 1.6;
|
|
color: #ffffffcc;
|
|
background-color: black;
|
|
}
|
|
|
|
main {
|
|
max-width: 680px;
|
|
margin: 0 auto;
|
|
padding: 3rem 1rem 1rem 1rem;
|
|
}
|
|
|
|
h1, h2, h3, h4 {
|
|
font-family: "Poppins", Sans-serif;
|
|
margin-top: 2rem;
|
|
margin-bottom: 1rem;
|
|
line-height: 1.3;
|
|
color: #474747;
|
|
}
|
|
|
|
h1 { text-align: center; font-weight: 300; font-size: 4rem; }
|
|
h2 { font-size: 2rem; }
|
|
h3 { font-size: 1.5rem; }
|
|
h4 { font-size: 1.25rem; }
|
|
|
|
h1 img {
|
|
width: 30%;
|
|
}
|
|
|
|
p {
|
|
margin-top: 1rem;
|
|
margin-bottom: 1rem;
|
|
font-size: 1rem;
|
|
}
|
|
|
|
strong {
|
|
font-weight: 600;
|
|
}
|
|
|
|
ul, ol {
|
|
margin-bottom: 1.5rem;
|
|
padding-left: 2rem;
|
|
}
|
|
|
|
li {
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
|
|
a {
|
|
color: #FF9300;
|
|
}
|
|
|
|
hr {
|
|
margin-top: 1rem;
|
|
margin-bottom: 1rem;
|
|
border: none;
|
|
border-top: 1px solid #FF9300;
|
|
}
|
|
|
|
div.tabs {
|
|
font-size: small;
|
|
font-family: courier;
|
|
text-align: right;
|
|
border-bottom: 1px solid grey;
|
|
}
|
|
|
|
div.tabs a {
|
|
color: white;
|
|
text-decoration: none;
|
|
cursor: pointer;
|
|
}
|
|
|
|
div.tabs a.hidden {
|
|
color: grey;
|
|
text-decoration: none;
|
|
}
|
|
|
|
pre.hidden {
|
|
display: none;
|
|
}
|
|
|
|
span.link-prev {
|
|
float: left;
|
|
}
|
|
|
|
span.link-next {
|
|
float: right;
|
|
clear: right;
|
|
}
|
|
|
|
@media (max-width: 600px) {
|
|
main {
|
|
padding: 1.5rem 1rem;
|
|
}
|
|
|
|
h1 { font-size: 2rem; }
|
|
h2 { font-size: 1.75rem; }
|
|
h3 { font-size: 1.375rem; }
|
|
h4 { font-size: 1.125rem; }
|
|
|
|
p {
|
|
font-size: 0.95rem;
|
|
}
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<main>
|
|
{{ content }}
|
|
</main>
|
|
<script>
|
|
document.addEventListener('DOMContentLoaded', function() {
|
|
if (document.cookie.match("selection=ahttpx")) {
|
|
ahttpx();
|
|
}
|
|
})
|
|
</script>
|
|
</body></html> |