Rework css
This commit is contained in:
parent
c96f003767
commit
8063067f53
4 changed files with 19 additions and 8 deletions
|
@ -193,8 +193,8 @@ const do_pug = (prt, root) => async tree => {
|
|||
if (tree.generate && tree.generate.cmd == 'pug') {
|
||||
const html = pug.renderFile(tree.generate.src, {
|
||||
markdown: tree.generate.markdown ? marked(await fs.readFile(tree.generate.markdown, 'utf-8')) : null,
|
||||
prt: prt,
|
||||
root: root,
|
||||
prt: prt,
|
||||
element: tree
|
||||
})
|
||||
await fs.writeFile(tree.generate.out, html)
|
||||
|
|
|
@ -22,7 +22,7 @@ block root
|
|||
img(src="/img/flower.svg", width="40")
|
||||
|
|
||||
img(src="/img/flower.svg", width="40")
|
||||
+menu(root)
|
||||
+menu(root, element)
|
||||
|
||||
main
|
||||
block content
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
mixin menu(o)
|
||||
mixin menu(o, element)
|
||||
ul
|
||||
each val in o.children
|
||||
- if (val.type == 'folder' && val.tags.includes('document'))
|
||||
li
|
||||
- if (val.tags.includes('has_index'))
|
||||
a(href=val.url)= val.nice_name
|
||||
a(href=val.url, class=val.index.url == element.url ? 'selected' : null)= val.nice_name
|
||||
- else
|
||||
span= val.nice_name
|
||||
+menu(val)
|
||||
+menu(val, element)
|
||||
- else if (val.type == 'file' && val.tags.includes('document') && !val.tags.includes('is_index'))
|
||||
li
|
||||
a(href=val.url)= val.nice_name
|
||||
a(href=val.url, class=val.url == element.url ? 'selected' : null)= val.nice_name
|
||||
|
|
|
@ -31,7 +31,7 @@ body {
|
|||
*/
|
||||
.mobile_block, .mobile_inline { display: none }
|
||||
|
||||
@media screen and (max-width: 640px) {
|
||||
@media screen and (max-width: 800px) {
|
||||
body { flex-direction: column }
|
||||
.computer_block { display: none }
|
||||
.mobile_block { display: block }
|
||||
|
@ -62,11 +62,21 @@ body > header a {
|
|||
text-decoration: none;
|
||||
}
|
||||
|
||||
body > header > nav ul {
|
||||
list-style-type: none;
|
||||
padding-left: 1em;
|
||||
}
|
||||
body > header > nav > ul { padding-left: 0px }
|
||||
body > header > nav a:hover { text-decoration: underline }
|
||||
body > header > nav .selected { font-weight: bold }
|
||||
body > header > nav .selected::before { content: "» " }
|
||||
|
||||
body > main {
|
||||
padding: 1.5rem;
|
||||
max-width: 1200px;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* TEXT CORE (think markdown)
|
||||
*/
|
||||
|
@ -77,7 +87,8 @@ h3 { font-size: 1.75rem }
|
|||
h4 { font-size: 1.50rem }
|
||||
h5 { font-size: 1.25rem }
|
||||
h6 { font-size: 1.10rem }
|
||||
section, p { margin-bottom: 1rem }
|
||||
section, p, ul, ol { margin-bottom: 1rem }
|
||||
ul, ol { padding-left: 1.5em }
|
||||
|
||||
/*
|
||||
* UTILS
|
||||
|
|
Loading…
Reference in a new issue