Skip to content

Commit a726b3a

Browse files
committed
wip: switch docs to shayu
Zola is unfortunately not very flexible. And the Tera syntax is terrible.
1 parent 243ceb1 commit a726b3a

File tree

34 files changed

+17894
-267
lines changed

34 files changed

+17894
-267
lines changed

docs/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
build/
File renamed without changes.

docs/config.toml

Lines changed: 0 additions & 12 deletions
This file was deleted.

docs/content/docs/_index.md

Lines changed: 0 additions & 4 deletions
This file was deleted.

docs/content/docs/administration/_index.md

Lines changed: 0 additions & 4 deletions
This file was deleted.

docs/content/docs/customization/_index.md

Lines changed: 0 additions & 4 deletions
This file was deleted.

docs/content/docs/development/_index.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

docs/content/docs/usage/_index.md

Lines changed: 0 additions & 4 deletions
This file was deleted.

docs/index.js

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
'use strict';
2+
3+
const shayu = require('shayu');
4+
5+
const config = {
6+
basePath: __dirname, // easy way to get the path where this index.js is in, all directories will be based from here
7+
assets: {
8+
postcssModules: [
9+
require('postcss-import')(),
10+
require('postcss-mixins')(),
11+
require('postcss-nested')(),
12+
require('postcss-simple-vars')(),
13+
require('postcss-color-function')(),
14+
require('autoprefixer')(),
15+
require('postcss-math')()
16+
]
17+
},
18+
livereload: 'env'
19+
};
20+
21+
shayu(config);

docs/layouts/default.jsx

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
'use strict';
2+
3+
const React = require('react');
4+
5+
function Layout({
6+
title,
7+
postHeader,
8+
side,
9+
scripts,
10+
mdxContent,
11+
meta,
12+
pageContext,
13+
}) {
14+
return (
15+
<html lang="en">
16+
<head>
17+
<title>{title ?? config.title}</title>
18+
19+
<meta charset="utf-8">
20+
<meta name="copyright" content={config.extra.author}>
21+
<meta name="keywords" content="selfoss rss reader webbased mashup aggregator tobias zeising aditu">
22+
<meta name="description" content="selfoss the web based open source rss reader and multi source mashup aggregator">
23+
<meta name="robots" content="all">
24+
25+
<link rel="alternate" type="application/atom+xml" title="RSS Feed" href="https://github.com/fossar/selfoss/releases.atom">
26+
27+
<link rel="shortcut icon" href={get_url('favicon.ico')} type="image/x-icon">
28+
29+
<link rel="stylesheet" type="text/css" media="screen" href={get_url('style.css')}>
30+
<link rel="stylesheet" type="text/css" media="screen" href={get_url('javascript/jquery.fancybox.min.css')}>
31+
</head>
32+
<body class={current_path == '/' ? 'homepage' : ''}>
33+
34+
<!-- header -->
35+
<div id="header" class={current_path === '/' ? 'header-homepage' : ''}>
36+
<h1 id="header-name"><a href="/"><span>selfoss</span></a></h1>
37+
38+
<ul id="header-navigation">
39+
<li><a href={get_url('@/_index.md#screenshots')}>screenshots</a></li>
40+
<li><a href={get_url('@/_index.md#documentation')}>documentation</a></li>
41+
<li><a href={get_url('@/docs/project/credits.md')}>about</a></li>
42+
<li><a href="/forum">forum</a></li>
43+
<li><a href={`https://github.com/fossar/selfoss/releases/download/${config.extra.current_version}/selfoss-${config.extra.current_version}.zip`}>download</a></li>
44+
</ul>
45+
46+
<a id="header-fork" href="https://github.com/fossar/selfoss"></a>
47+
</div>
48+
49+
{postHeader}
50+
51+
<!-- Documentations -->
52+
<div class="wrapper-bright">
53+
{current_path !== '/' && (
54+
<aside>
55+
{side}
56+
</aside>
57+
)}
58+
59+
<div class="main">
60+
{mdxContent}
61+
</div>
62+
</div>
63+
64+
65+
<div id="footer">
66+
<p>
67+
<a href="https://github.com/fossar/selfoss">Github</a>
68+
|
69+
<a href="/forum">Forum</a>
70+
|
71+
<a href="https://www.aditu.de">About me</a>
72+
|
73+
logo by <a href="http://blackbooze.com/">Artcore</a>
74+
</p>
75+
<p>
76+
&copy; by {config.extra.author} &sdot; <a href={`mailto:${config.extra.author_address}`}>{config.extra.author_address}</a> &sdot; <a href="https://www.aditu.de">www.aditu.de</a>
77+
</p>
78+
</div>
79+
80+
{scripts}
81+
<script type="text/javascript" src={get_url('javascript/jquery-3.2.1.min.js')}></script>
82+
<script type="text/javascript" src={get_url('javascript/jquery.fancybox.min.js')}></script>
83+
<script type="text/javascript" src={get_url('javascript/base.js')}></script>
84+
85+
86+
{/* Piwik */}
87+
<script type="text/javascript">
88+
var pkBaseURL = (("https:" == document.location.protocol) ? "https://piwik.aditu.de/" : "http://piwik.aditu.de/");
89+
document.write(unescape("%3Cscript src='" + pkBaseURL + "piwik.js' type='text/javascript'%3E%3C/script%3E"));
90+
</script><script type="text/javascript">
91+
try {
92+
var piwikTracker = Piwik.getTracker(pkBaseURL + "piwik.php", 7);
93+
piwikTracker.trackPageView();
94+
piwikTracker.enableLinkTracking();
95+
} catch( err ) {}
96+
</script><noscript><p><img src="http://piwik.aditu.de/piwik.php?idsite=7" style="border:0" alt=""></p></noscript>
97+
<!-- End Piwik Tracking Code -->
98+
</body>
99+
</html>
100+
);
101+
}
102+
103+
module.exports = Layout;

0 commit comments

Comments
 (0)