diff --git a/config.toml b/config.toml index f15989e..42364c5 100644 --- a/config.toml +++ b/config.toml @@ -1,28 +1,41 @@ -# The URL the site will be built for base_url = "https://mat.services" title = "mat.services" +description = "the personal website of matthew ess" + +default_language = "en" -# Whether to automatically compile all Sass files in the sass directory compile_sass = true -# Whether to build a search index to be used later on by a JavaScript library build_search_index = false +generate_feed = true + theme = "apollo" [markdown] -# Whether to do syntax highlighting highlight_code = true +render_emoji = false +external_links_target_blank = true +external_links_no_referrer = true [extra] theme = "auto" favicon = "/favicon.svg" -stylesheets = ["extra.css"] +stylesheets = [] + +use_cdn = true +cdns = [ + "https://cdn.jsdelivr.net/npm/firacode@6.2.0/distr/fira_code.min.css", + "https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.5/dist/web/static/pretendard-std-dynamic-subset.min.css", + "https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.5/dist/web/variable/pretendardvariable-std.min.css", + "https://cdn.jsdelivr.net/gh/codex-src/iA-Fonts@master/iA%20Writer%20Quattro/Webfonts/index.min.css", + "https://cdn.jsdelivr.net/gh/codex-src/iA-Fonts@master/iA%20Writer%20Quattro/Variable/index.min.css", +] menu = [ - { name = "/posts", url = "/posts", external = false }, - { name = "/projects", url = "/projects", external = false }, - { name = "/about", url = "/about", external = false }, + { name = "/posts", url = "/posts" }, + { name = "/projects", url = "/projects" }, + { name = "/about", url = "/about" }, { name = "git", url = "https://git.mat.services/explore/repos", external = true }, ] diff --git a/sass/extra.scss b/sass/extra.scss deleted file mode 100644 index c1a0116..0000000 --- a/sass/extra.scss +++ /dev/null @@ -1,43 +0,0 @@ -// Logo -div.brand>* { - padding: 0 0.25em; -} - -div.brand:hover img.logo { - filter: brightness(0) invert(1); -} - -img.logo { - border: none; - height: 0.75em; - width: 0.75em; - padding-right: 0.25em; -} - -// Nav links -nav a { - margin-left: 0.7em; -} - -// Footer -.content { - display: flex; - flex-direction: column; - min-height: 100vh; -} - -div.inner { - flex-grow: 1; -} - -header, -footer { - flex-grow: 0; - flex-shrink: 0; -} - -footer { - margin: 2em; - color: grey; - font-size: 0.75em; -} \ No newline at end of file diff --git a/sass/main.scss b/sass/main.scss new file mode 100644 index 0000000..1a080c4 --- /dev/null +++ b/sass/main.scss @@ -0,0 +1,141 @@ +@import "../themes/apollo/sass/parts/_code.scss"; +@import "../themes/apollo/sass/parts/_header.scss"; +@import "../themes/apollo/sass/parts/_image.scss"; +@import "../themes/apollo/sass/parts/misc.scss"; +@import "../themes/apollo/sass/parts/table.scss"; +@import "../themes/apollo/sass/parts/tags.scss"; + +:root { + /* Used for: block comment, hr, ... */ + --border-color: var(--bg-1); + + /* Fonts */ + --text-font: 'iA Writer Quattro'; + --header-font: 'Pretendard Std'; + --code-font: 'Fira Code'; + + @supports(font-variation-settings: normal) { + /* Variable fonts */ + --text-font: 'iA Writer Quattro var'; + --header-font: 'Pretendard Std Variable'; + --code-font: 'Fira Code VF'; + } +} + +html { + background-color: var(--bg-0); + color: var(--text-0); + font-family: var(--text-font); + line-height: 1.6em; +} + +.content { + max-width: 944px; + margin: 0 auto; + padding: 0 24px; + word-wrap: break-word; +} + +@media all and (min-width:640px) { + html { + font-size: 16.5px; + } +} + +@media all and (min-width:720px) { + html { + font-size: 17px; + } +} + +@media all and (min-width:960px) { + html { + font-size: 18px; + } +} + +div.brand>* { + padding: 0 0.25em; +} + +div.brand:hover img.logo { + filter: brightness(0) invert(1); +} + +img.logo { + border: none; + height: 0.75em; + width: 0.75em; + padding-right: 0.25em; +} + +// Nav links +nav a { + margin-left: 0.7em; + font-family: var(--code-font); +} + +// Footer +.content { + display: flex; + flex-direction: column; + min-height: 100vh; +} + +div.inner { + flex-grow: 1; +} + +header, +footer { + flex-grow: 0; + flex-shrink: 0; +} + +footer { + margin: 2em; + color: grey; + font-size: 0.75em; +} + +// Different sized headers +h1 { + font-size: 1.5rem; + margin-top: 1.5em; +} + +h2 { + font-size: 1.4rem; + margin-top: 1.4em; +} + +h3 { + font-size: 1.3rem; + margin-top: 1.3em; +} + +h4 { + font-size: 1.2rem; + margin-top: 1.2em; +} + +h5 { + font-size: 1.1rem; + margin-top: 1.1em; +} + +h6 { + font-size: 1rem; + margin-top: 1em; +} + +// Code fonts +pre, +code { + font-family: var(--code-font); +} + +// Page title width +.page-header { + max-width: 720px; +} \ No newline at end of file diff --git a/sass/theme/dark.scss b/sass/theme/dark.scss index 9bfc76c..47b4aaf 100644 --- a/sass/theme/dark.scss +++ b/sass/theme/dark.scss @@ -3,7 +3,7 @@ --text-1: rgba(255, 255, 255, 60%); --bg-0: #121212; - --bg-1: rgba(255, 255, 255, 5%); + --bg-1: rgba(255, 255, 255, 15%); --primary-color: lightcoral; --hover-color: white; diff --git a/sass/theme/light.scss b/sass/theme/light.scss index dd395ce..b26db5b 100644 --- a/sass/theme/light.scss +++ b/sass/theme/light.scss @@ -3,7 +3,7 @@ --text-1: rgba(0, 0, 0, 66%); --bg-0: #fff; - --bg-1: #f2f2f2; + --bg-1: rgba(169, 169, 169, 30%); --primary-color: lightcoral; --hover-color: white; diff --git a/templates/partials/header.html b/templates/partials/header.html new file mode 100644 index 0000000..3cf3a5a --- /dev/null +++ b/templates/partials/header.html @@ -0,0 +1,52 @@ +{% import "macros/macros.html" as post_macros %} + +
+ + + + + {# Site title #} + {% set current_path = current_path | default(value="/") %} + {% if current_path == "/" %} +