commit 3e882d86e63cc8f6517ca2b382e92d675b549628 Author: Lukas Joswiak Date: Thu May 14 23:48:11 2020 -0700 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e43b0f9 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.DS_Store diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..37209a9 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2020 Lukas Joswiak + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/archetypes/default.md b/archetypes/default.md new file mode 100644 index 0000000..ac36e06 --- /dev/null +++ b/archetypes/default.md @@ -0,0 +1,2 @@ ++++ ++++ diff --git a/assets/css/syntax.css b/assets/css/syntax.css new file mode 100644 index 0000000..350286e --- /dev/null +++ b/assets/css/syntax.css @@ -0,0 +1,59 @@ +/* Background */ .chroma { color: #f8f8f2; background-color: #272822 } +/* Error */ .chroma .err { color: #960050; background-color: #1e0010 } +/* LineTableTD */ .chroma .lntd { vertical-align: top; padding: 0; margin: 0; border: 0; } +/* LineTable */ .chroma .lntable { border-spacing: 0; padding: 0; margin: 0; border: 0; width: auto; overflow: auto; display: block; } +/* LineHighlight */ .chroma .hl { display: block; width: 100%;background-color: #ffffcc } +/* LineNumbersTable */ .chroma .lnt { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } +/* LineNumbers */ .chroma .ln { margin-right: 0.4em; padding: 0 0.4em 0 0.4em;color: #7f7f7f } +/* Keyword */ .chroma .k { color: #66d9ef } +/* KeywordConstant */ .chroma .kc { color: #66d9ef } +/* KeywordDeclaration */ .chroma .kd { color: #66d9ef } +/* KeywordNamespace */ .chroma .kn { color: #f92672 } +/* KeywordPseudo */ .chroma .kp { color: #66d9ef } +/* KeywordReserved */ .chroma .kr { color: #66d9ef } +/* KeywordType */ .chroma .kt { color: #66d9ef } +/* NameAttribute */ .chroma .na { color: #a6e22e } +/* NameClass */ .chroma .nc { color: #a6e22e } +/* NameConstant */ .chroma .no { color: #66d9ef } +/* NameDecorator */ .chroma .nd { color: #a6e22e } +/* NameException */ .chroma .ne { color: #a6e22e } +/* NameFunction */ .chroma .nf { color: #a6e22e } +/* NameOther */ .chroma .nx { color: #a6e22e } +/* NameTag */ .chroma .nt { color: #f92672 } +/* Literal */ .chroma .l { color: #ae81ff } +/* LiteralDate */ .chroma .ld { color: #e6db74 } +/* LiteralString */ .chroma .s { color: #e6db74 } +/* LiteralStringAffix */ .chroma .sa { color: #e6db74 } +/* LiteralStringBacktick */ .chroma .sb { color: #e6db74 } +/* LiteralStringChar */ .chroma .sc { color: #e6db74 } +/* LiteralStringDelimiter */ .chroma .dl { color: #e6db74 } +/* LiteralStringDoc */ .chroma .sd { color: #e6db74 } +/* LiteralStringDouble */ .chroma .s2 { color: #e6db74 } +/* LiteralStringEscape */ .chroma .se { color: #ae81ff } +/* LiteralStringHeredoc */ .chroma .sh { color: #e6db74 } +/* LiteralStringInterpol */ .chroma .si { color: #e6db74 } +/* LiteralStringOther */ .chroma .sx { color: #e6db74 } +/* LiteralStringRegex */ .chroma .sr { color: #e6db74 } +/* LiteralStringSingle */ .chroma .s1 { color: #e6db74 } +/* LiteralStringSymbol */ .chroma .ss { color: #e6db74 } +/* LiteralNumber */ .chroma .m { color: #ae81ff } +/* LiteralNumberBin */ .chroma .mb { color: #ae81ff } +/* LiteralNumberFloat */ .chroma .mf { color: #ae81ff } +/* LiteralNumberHex */ .chroma .mh { color: #ae81ff } +/* LiteralNumberInteger */ .chroma .mi { color: #ae81ff } +/* LiteralNumberIntegerLong */ .chroma .il { color: #ae81ff } +/* LiteralNumberOct */ .chroma .mo { color: #ae81ff } +/* Operator */ .chroma .o { color: #f92672 } +/* OperatorWord */ .chroma .ow { color: #f92672 } +/* Comment */ .chroma .c { color: #75715e } +/* CommentHashbang */ .chroma .ch { color: #75715e } +/* CommentMultiline */ .chroma .cm { color: #75715e } +/* CommentSingle */ .chroma .c1 { color: #75715e } +/* CommentSpecial */ .chroma .cs { color: #75715e } +/* CommentPreproc */ .chroma .cp { color: #75715e } +/* CommentPreprocFile */ .chroma .cpf { color: #75715e } +/* GenericDeleted */ .chroma .gd { color: #f92672 } +/* GenericEmph */ .chroma .ge { font-style: italic } +/* GenericInserted */ .chroma .gi { color: #a6e22e } +/* GenericStrong */ .chroma .gs { font-weight: bold } +/* GenericSubheading */ .chroma .gu { color: #75715e } diff --git a/layouts/404.html b/layouts/404.html new file mode 100644 index 0000000..e69de29 diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html new file mode 100644 index 0000000..d663ad3 --- /dev/null +++ b/layouts/_default/baseof.html @@ -0,0 +1,11 @@ + + + {{- partial "head.html" . -}} + + {{- partial "header.html" . -}} +
+ {{- block "main" . }}{{- end }} +
+ {{- partial "footer.html" . -}} + + diff --git a/layouts/_default/list.html b/layouts/_default/list.html new file mode 100644 index 0000000..97af0e3 --- /dev/null +++ b/layouts/_default/list.html @@ -0,0 +1,3 @@ +{{ define "main" }} +{{- partial "posts.html" . -}} +{{ end }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html new file mode 100644 index 0000000..4f3835e --- /dev/null +++ b/layouts/_default/single.html @@ -0,0 +1,6 @@ +{{ define "main" }} +
+

{{ .Title }}

+ {{- .Content -}} +
+{{ end }} diff --git a/layouts/index.html b/layouts/index.html new file mode 100644 index 0000000..859b9b8 --- /dev/null +++ b/layouts/index.html @@ -0,0 +1,4 @@ +{{ define "main" }} +{{ .Content }} +{{- partial "posts.html" . -}} +{{ end }} diff --git a/layouts/partials/css/main.css b/layouts/partials/css/main.css new file mode 100644 index 0000000..a28961d --- /dev/null +++ b/layouts/partials/css/main.css @@ -0,0 +1,208 @@ +*, *:before, *:after { + box-sizing: border-box; +} + +html { + font-size: 62.5%; +} + +body { + font-size: 16px; + font-size: 1.6rem; + font-family: 'Helvetica Neue', 'Arial', sans-serif; + color: #282828; + width: 100%; + margin: 0 auto; + padding: 0 16px; + line-height: 1.6; +} + +@media (prefers-color-scheme: dark) { + body { + color: #ebebeb; + background: #121212; + } +} + +header#banner { + margin: 25px 0; +} + +header#banner a { + color: #323232; + text-decoration: none; +} + +header#banner a:hover { + text-decoration: underline; +} + +header#banner h2 { + display: inline; + font-size: 21px; + font-size: 2.1rem; + margin: 0 8px 0 0; +} + +header#banner nav { + display: inline-block; +} + +header#banner nav ul { + list-style-type: none; + font-size: 1.05em; + text-transform: lowercase; + margin: 0; + padding: 0; +} + +header#banner nav ul li { + display: inline; + margin: 0 3px; +} + +header#banner nav ul li a { + color: #454545; +} + +@media (prefers-color-scheme: dark) { + header#banner a { + color: #e0e0e0; + text-decoration: none; + } + + header#banner nav ul li a { + color: #cccccc; + } +} + +main#content a { + color: #007dfa; + text-decoration: none; +} + +@media (prefers-color-scheme: dark) { + main#content a { + color: #00b1ed; + } +} + +main#content a:hover { + text-decoration: underline; +} + +main#content p { + color: #323232; + margin: 16px 0; +} + +@media (prefers-color-scheme: dark) { + main#content p { + color: #f5f5f5; + } +} + +main#content h1, +main#content h2, +main#content h3, +main#content h4, +main#content h5, +main#content h6 { + margin-bottom: 0; +} + +main#content h1 + p, +main#content h2 + p, +main#content h3 + p, +main#content h4 + p, +main#content h5 + p, +main#content h6 + p { + margin-top: 5px; +} + +main#content h3 { + font-size: 19px; + font-size: 1.9rem; +} + +/* index.html styles */ +main#content ul#posts { + list-style-type: none; + font-size: 16px; + font-size: 1.6rem; + margin-top: 0; + padding: 0; +} + +main#content ul#posts li { + margin: 5px 0; + padding: 0; +} + +main#content ul#posts small { + font-size: 0.8em; + color: #767676; + margin-left: 10px; +} + +main#content ul#posts li a { + text-decoration: none; +} + +main#content ul#posts li a:hover { + color: #369aff; +} + +main#content ul#posts li a:hover small { + color: inherit; +} + +@media (prefers-color-scheme: dark) { + main#content ul#posts li a:hover { + color: #21c7ff; + } +} + +/* single.html styles */ +main#content header#post-title { + font-size: 16px; + font-size: 1.6rem; +} + +main#content img { + max-width: 100%; + margin: 0 auto; +} + +main#content code, +main#content pre { + font-family: 'Menlo', monospace; +} + +main#content code { + font-size: 0.96em; + padding: 0 5px; +} + +main#content pre { + display: block; + overflow-x: auto; + font-size 14px; + font-size: 1.4rem; + white-space: pre; + margin: 20px 0; + padding: 1.5rem 1.5rem; + line-height: 1.4; +} + +main#content pre code { + padding: 0; +} + +footer#footer { + font-size: 14px; + font-size: 1.4rem; + font-weight: 300; + color: #949494; + margin: 40px 0; +} diff --git a/layouts/partials/css/min770px.css b/layouts/partials/css/min770px.css new file mode 100644 index 0000000..c78b46d --- /dev/null +++ b/layouts/partials/css/min770px.css @@ -0,0 +1,37 @@ +body { + width: 600px; + line-height: 1.5; +} + +/* index.html styles */ +header#banner h2 { + font-size: 25px; + font-size: 2.5rem; +} + +main#content h3 { + font-size: 20px; + font-size: 2rem; +} + +main#content ul#posts { + font-size: 18px; + font-size: 1.8rem; +} + +/* single.html styles */ +main#content header#post-title { + font-size: 20px; + font-size: 2rem; +} + +main#content img { + max-width: 108%; + margin-left: -4%; +} + +main#content pre { + width: 108%; + margin-left: -4%; + padding: 1.5rem 2.2rem; +} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..73420ef --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,3 @@ + diff --git a/layouts/partials/head.html b/layouts/partials/head.html new file mode 100644 index 0000000..134e59e --- /dev/null +++ b/layouts/partials/head.html @@ -0,0 +1,17 @@ + + {{ .Title }} + + + + + + + + + {{ $syntax := resources.Get "css/syntax.css" | minify }} + + diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..1bc308e --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,12 @@ + diff --git a/layouts/partials/posts.html b/layouts/partials/posts.html new file mode 100644 index 0000000..8c012c4 --- /dev/null +++ b/layouts/partials/posts.html @@ -0,0 +1,13 @@ +

Posts

+{{ range where .Pages "Section" "posts" }} + +{{ end }} diff --git a/theme.toml b/theme.toml new file mode 100644 index 0000000..ea55293 --- /dev/null +++ b/theme.toml @@ -0,0 +1,12 @@ +name = "Etch" +license = "MIT" +licenselink = "https://github.com/LukasJoswiak/etch/blob/master/LICENSE" +description = "" +homepage = "http://example.com/" +tags = ["simple", "clean", "fast", "responsive", "dark mode"] +features = ["fast", "syntax highlighting", "dark mode"] +min_version = "0.41" + +[author] + name = "Lukas Joswiak" + homepage = "https://lukasjoswiak.com"