~ecs/ecs.d2evs.net

8b3bd8070f130bab64768700f111dd3d6b4a043f — Ember Sawady 3 months ago d412db5
fix the feed yet again

also use /style.css for feed.xsl
2 files changed, 3 insertions(+), 113 deletions(-)

M feed.xsl
M html.awk
M feed.xsl => feed.xsl +1 -113
@@ 6,119 6,7 @@
			<head>
				<meta charset="utf=8" />
				<meta name="viewport" content="width=device-width, initial-scale=1" />
				<style>
					html {
						font-family: sans-serif;
						color: #080808;
					}

					body {
						max-width: 920px;
						margin: 0 auto;
						padding: 1rem 2rem;
					}

					blockquote {
						background-color: #eee;
						border-left: 3px solid #444;
						margin: 1rem -1rem 1rem calc(-1rem - 3px);
						padding: 1rem;
					}

					ul {
						margin-left: 0;
						padding: 0;
					}

					li {
						padding: 0;
					}

					li:not(:last-child) {
						margin-bottom: 0.5rem;
					}

					a {
						position: relative;
					}

					a:before {
						content: '⇒';
						color: #999;
						text-decoration: none;
						font-weight: bold;
						position: absolute;
						left: -1.25rem;
					}

					pre {
						background-color: #eee;
						margin: 0 -1rem;
						padding: 1rem;
						overflow-x: auto;
					}

					details:not([open]) summary,
					details:not([open]) summary a {
						color: gray;
					}

					details summary a:before {
						display: none;
					}

					dl dt {
						font-weight: bold;
					}

					dl dt:not(:first-child) {
						margin-top: 0.5rem;
					}

					@media(prefers-color-scheme:dark) {
						html {
							background-color: #111;
							color: #eee;
						}

						blockquote {
							background-color: #000;
						}

						pre {
							background-color: #222;
						}

						a {
							color: #0087BD;
						}

						a:visited {
							color: #333399;
						}
					}

					label {
						display: block;
						font-weight: bold;
						margin-bottom: 0.5rem;
					}

					input {
						display: block;
						border: 1px solid #888;
						padding: .375rem;
						line-height: 1.25rem;
						transition: border-color .15s ease-in-out,box-shadow .15s ease-in-out;
						width: 100%;
					}

					input:focus {
						outline: 0;
						border-color: #80bdff;
						box-shadow: 0 0 0 0.2rem rgba(0,123,255,.25);
					}
				</style>
				<link rel="stylesheet" type="text/css" href="/style.css" />
				<title><xsl:value-of select="atom:feed/atom:title"/> (rss feed)</title>
			</head>
			<body>

M html.awk => html.awk +2 -0
@@ 7,7 7,9 @@ function escape(text) {
}

BEGIN { FS = "[ \t]" }
END { if (ul) print "</ul>" }
/^```/ {
	if (ul) { print "</ul>"; ul = 0 }
	preformatted = !preformatted;
	print preformatted ? "<pre>" : "</pre>";
	next;