From bbf802793a55dada6c31ee827f53e55056630975 Mon Sep 17 00:00:00 2001 From: sneakers-the-rat Date: Wed, 16 Nov 2022 20:50:17 -0800 Subject: [PATCH] initial without assets to not bloat the repo --- .gitignore | 5 + Gemfile | 37 ++++ Gemfile.lock | 86 ++++++++++ _config.yml | 66 ++++++++ _includes/analytics.html | 6 + _includes/disqus_comments.html | 11 ++ _includes/footer.html | 6 + _includes/head.html | 37 ++++ _includes/navigation.html | 12 ++ _layouts/default.html | 16 ++ _layouts/home.html | 29 ++++ _layouts/post.html | 54 ++++++ _pages/403.html | 15 ++ _pages/404.html | 15 ++ _pages/about.md | 15 ++ _pages/posts.md | 50 ++++++ _pages/tags.md | 54 ++++++ _posts/2022-11-16-welcome-to-jekyll.markdown | 30 ++++ _sass/details.scss | 17 ++ _sass/fonts.scss | 167 +++++++++++++++++++ _sass/stlviewer.scss | 25 +++ _sass/tale.scss | 16 ++ _sass/tale/_404.scss | 22 +++ _sass/tale/_base.scss | 66 ++++++++ _sass/tale/_catalogue.scss | 39 +++++ _sass/tale/_code.scss | 46 +++++ _sass/tale/_footnotes.scss | 12 ++ _sass/tale/_layout.scss | 92 ++++++++++ _sass/tale/_navigation.scss | 5 + _sass/tale/_pagination.scss | 44 +++++ _sass/tale/_post.scss | 67 ++++++++ _sass/tale/_sidenote.scss | 34 ++++ _sass/tale/_syntax.scss | 65 ++++++++ _sass/tale/_tags.scss | 89 ++++++++++ _sass/tale/_variables.scss | 30 ++++ index.markdown | 6 + 36 files changed, 1386 insertions(+) create mode 100644 .gitignore create mode 100644 Gemfile create mode 100644 Gemfile.lock create mode 100644 _config.yml create mode 100644 _includes/analytics.html create mode 100644 _includes/disqus_comments.html create mode 100644 _includes/footer.html create mode 100644 _includes/head.html create mode 100644 _includes/navigation.html create mode 100644 _layouts/default.html create mode 100644 _layouts/home.html create mode 100644 _layouts/post.html create mode 100644 _pages/403.html create mode 100644 _pages/404.html create mode 100644 _pages/about.md create mode 100644 _pages/posts.md create mode 100644 _pages/tags.md create mode 100644 _posts/2022-11-16-welcome-to-jekyll.markdown create mode 100644 _sass/details.scss create mode 100644 _sass/fonts.scss create mode 100644 _sass/stlviewer.scss create mode 100644 _sass/tale.scss create mode 100644 _sass/tale/_404.scss create mode 100644 _sass/tale/_base.scss create mode 100644 _sass/tale/_catalogue.scss create mode 100644 _sass/tale/_code.scss create mode 100644 _sass/tale/_footnotes.scss create mode 100644 _sass/tale/_layout.scss create mode 100644 _sass/tale/_navigation.scss create mode 100644 _sass/tale/_pagination.scss create mode 100644 _sass/tale/_post.scss create mode 100644 _sass/tale/_sidenote.scss create mode 100644 _sass/tale/_syntax.scss create mode 100644 _sass/tale/_tags.scss create mode 100644 _sass/tale/_variables.scss create mode 100644 index.markdown diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f40fbd8 --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +_site +.sass-cache +.jekyll-cache +.jekyll-metadata +vendor diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..3085dac --- /dev/null +++ b/Gemfile @@ -0,0 +1,37 @@ +source "https://rubygems.org" +# Hello! This is where you manage which Jekyll version is used to run. +# When you want to use a different version, change it below, save the +# file and run `bundle install`. Run Jekyll with `bundle exec`, like so: +# +# bundle exec jekyll serve +# +# This will help ensure the proper Jekyll version is running. +# Happy Jekylling! +gem "jekyll", "~> 4.3.1" +# This is the default theme for new Jekyll sites. You may change this to anything you like. +gem "minima", "~> 2.5" +# If you want to use GitHub Pages, remove the "gem "jekyll"" above and +# uncomment the line below. To upgrade, run `bundle update github-pages`. +# gem "github-pages", group: :jekyll_plugins +# If you have any plugins, put them here! +group :jekyll_plugins do + gem "jekyll-feed", "~> 0.12" + gem "jekyll-paginate", "~> 1.1" + gem "jekyll-seo-tag", "~> 2.8" +end + +# Windows and JRuby does not include zoneinfo files, so bundle the tzinfo-data gem +# and associated library. +platforms :mingw, :x64_mingw, :mswin, :jruby do + gem "tzinfo", ">= 1", "< 3" + gem "tzinfo-data" +end + +# Performance-booster for watching directories on Windows +gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin] + +# Lock `http_parser.rb` gem to `v0.6.x` on JRuby builds since newer versions of the gem +# do not have a Java counterpart. +gem "http_parser.rb", "~> 0.6.0", :platforms => [:jruby] + + diff --git a/Gemfile.lock b/Gemfile.lock new file mode 100644 index 0000000..d37e599 --- /dev/null +++ b/Gemfile.lock @@ -0,0 +1,86 @@ +GEM + remote: https://rubygems.org/ + specs: + addressable (2.8.1) + public_suffix (>= 2.0.2, < 6.0) + colorator (1.1.0) + concurrent-ruby (1.1.10) + em-websocket (0.5.3) + eventmachine (>= 0.12.9) + http_parser.rb (~> 0) + eventmachine (1.2.7) + ffi (1.15.5) + forwardable-extended (2.6.0) + http_parser.rb (0.8.0) + i18n (1.12.0) + concurrent-ruby (~> 1.0) + jekyll (4.3.1) + addressable (~> 2.4) + colorator (~> 1.0) + em-websocket (~> 0.5) + i18n (~> 1.0) + jekyll-sass-converter (>= 2.0, < 4.0) + jekyll-watch (~> 2.0) + kramdown (~> 2.3, >= 2.3.1) + kramdown-parser-gfm (~> 1.0) + liquid (~> 4.0) + mercenary (>= 0.3.6, < 0.5) + pathutil (~> 0.9) + rouge (>= 3.0, < 5.0) + safe_yaml (~> 1.0) + terminal-table (>= 1.8, < 4.0) + webrick (~> 1.7) + jekyll-feed (0.17.0) + jekyll (>= 3.7, < 5.0) + jekyll-paginate (1.1.0) + jekyll-sass-converter (2.2.0) + sassc (> 2.0.1, < 3.0) + jekyll-seo-tag (2.8.0) + jekyll (>= 3.8, < 5.0) + jekyll-watch (2.2.1) + listen (~> 3.0) + kramdown (2.4.0) + rexml + kramdown-parser-gfm (1.1.0) + kramdown (~> 2.0) + liquid (4.0.3) + listen (3.7.1) + rb-fsevent (~> 0.10, >= 0.10.3) + rb-inotify (~> 0.9, >= 0.9.10) + mercenary (0.4.0) + minima (2.5.1) + jekyll (>= 3.5, < 5.0) + jekyll-feed (~> 0.9) + jekyll-seo-tag (~> 2.1) + pathutil (0.16.2) + forwardable-extended (~> 2.6) + public_suffix (5.0.0) + rb-fsevent (0.11.2) + rb-inotify (0.10.1) + ffi (~> 1.0) + rexml (3.2.5) + rouge (4.0.0) + safe_yaml (1.0.5) + sassc (2.4.0) + ffi (~> 1.9) + terminal-table (3.0.2) + unicode-display_width (>= 1.1.1, < 3) + unicode-display_width (2.3.0) + webrick (1.7.0) + +PLATFORMS + x86_64-darwin-21 + +DEPENDENCIES + http_parser.rb (~> 0.6.0) + jekyll (~> 4.3.1) + jekyll-feed (~> 0.12) + jekyll-paginate (~> 1.1) + jekyll-seo-tag (~> 2.8) + minima (~> 2.5) + tzinfo (>= 1, < 3) + tzinfo-data + wdm (~> 0.1.1) + +BUNDLED WITH + 2.3.25 diff --git a/_config.yml b/_config.yml new file mode 100644 index 0000000..bd4d926 --- /dev/null +++ b/_config.yml @@ -0,0 +1,66 @@ +# Welcome to Jekyll! +# +# This config file is meant for settings that affect your whole blog, values +# which you are expected to set up once and rarely edit after that. If you find +# yourself editing this file very often, consider using Jekyll's data files +# feature for the data you need to update frequently. +# +# For technical reasons, this file is *NOT* reloaded automatically when you use +# 'bundle exec jekyll serve'. If you change this file, please restart the server process. +# +# If you need help with YAML syntax, here are some quick references for you: +# https://learn-the-web.algonquindesign.ca/topics/markdown-yaml-cheat-sheet/#yaml +# https://learnxinyminutes.com/docs/yaml/ +# +# Site settings +# These are used to personalize your new site. If you look in the HTML files, +# you will see them accessed via {{ site.title }}, {{ site.email }}, and so on. +# You can create any custom variable you would like, and they will be accessible +# in the templates via {{ site.myvariable }}. + +title: jon-e.net +email: j@nny.fyi +description: >- # this means to ignore newlines until "baseurl:" + jon-e.net - Internet Website +baseurl: "" # the subpath of your site, e.g. /blog +url: "https://jon-e.net" # the base hostname & protocol for your site, e.g. http://example.com +twitter_username: json_dirs +github_username: sneakers-the-rat + +include: + - _pages + +# Build settings +plugins: + - jekyll-feed + - jekyll-seo-tag + +markdown: kramdown + +# assets +sass: + sass_dir: _sass + style: compressed + +# Permalinks +permalink: /:year-:month-:day/:title + +# Exclude from processing. +# The following items will not be processed, by default. +# Any item listed under the `exclude:` key here will be automatically added to +# the internal "default list". +# +# Excluded items can be processed by explicitly listing the directories or +# their entries' file path in the `include:` list. +# +# exclude: +# - .sass-cache/ +# - .jekyll-cache/ +# - gemfiles/ +# - Gemfile +# - Gemfile.lock +# - node_modules/ +# - vendor/bundle/ +# - vendor/cache/ +# - vendor/gems/ +# - vendor/ruby/ diff --git a/_includes/analytics.html b/_includes/analytics.html new file mode 100644 index 0000000..743d1fc --- /dev/null +++ b/_includes/analytics.html @@ -0,0 +1,6 @@ + + diff --git a/_includes/disqus_comments.html b/_includes/disqus_comments.html new file mode 100644 index 0000000..4b06c13 --- /dev/null +++ b/_includes/disqus_comments.html @@ -0,0 +1,11 @@ + + +

Discussion and feedback

+
+ + + \ No newline at end of file diff --git a/_includes/footer.html b/_includes/footer.html new file mode 100644 index 0000000..53b3c22 --- /dev/null +++ b/_includes/footer.html @@ -0,0 +1,6 @@ + diff --git a/_includes/head.html b/_includes/head.html new file mode 100644 index 0000000..c802858 --- /dev/null +++ b/_includes/head.html @@ -0,0 +1,37 @@ + + + + + {% seo %} + + + + + + + +{% if page.include_stl_viewer_js -%} + + + + + +{% endif -%} + + +{% for file in site.static_files -%} +{% if file.path contains '/assets/favicon-' -%} +{% assign parts = file.basename | split: '-' %} +{% endif -%} +{% endfor %} + + + + + {% feed_meta %} + + + {% if site.google_analytics and jekyll.environment == 'production' %} + {% include analytics.html %} + {% endif %} + diff --git a/_includes/navigation.html b/_includes/navigation.html new file mode 100644 index 0000000..7a1b1dd --- /dev/null +++ b/_includes/navigation.html @@ -0,0 +1,12 @@ + diff --git a/_layouts/default.html b/_layouts/default.html new file mode 100644 index 0000000..8c8261e --- /dev/null +++ b/_layouts/default.html @@ -0,0 +1,16 @@ + + + + {% include head.html %} + + + + {% include navigation.html %} + +
+ {{ content }} +
+ + {% include footer.html %} + + diff --git a/_layouts/home.html b/_layouts/home.html new file mode 100644 index 0000000..ba35adf --- /dev/null +++ b/_layouts/home.html @@ -0,0 +1,29 @@ +--- +layout: default +--- + +
+ {% for post in paginator.posts %} + +
+ +

{{ post.title }}

+
+ +

{% if post.perex -%}{{ post.perex }}{% else -%}{{ post.content | strip_html | truncatewords: 30 }}{% endif -%}

+ +
+
+ {% endfor %} +
+ + diff --git a/_layouts/post.html b/_layouts/post.html new file mode 100644 index 0000000..f742457 --- /dev/null +++ b/_layouts/post.html @@ -0,0 +1,54 @@ +--- +layout: default +--- + +
+ + +

{{ page.title }}

+ + {% if page.tags %} +
+ {% assign pt = page.tags | sort -%} + {% for tag in pt -%} + {{ tag }} + {% endfor %} +

+ {% endif %} + +
+ + {{ content }} +
+ +{% if page.comments %} + {% include disqus_comments.html %} +{% endif %} + + diff --git a/_pages/403.html b/_pages/403.html new file mode 100644 index 0000000..570ffa4 --- /dev/null +++ b/_pages/403.html @@ -0,0 +1,15 @@ +--- +layout: default +title: "403" +permalink: /403.html +--- + +
+

403: Das ist verboten

+
+

+ Oops! I'm afraid I can't do that, Dave. Let's + head back home. +

+

+
diff --git a/_pages/404.html b/_pages/404.html new file mode 100644 index 0000000..0402467 --- /dev/null +++ b/_pages/404.html @@ -0,0 +1,15 @@ +--- +layout: default +title: "404" +permalink: /404.html +--- + +
+

404: Page not found

+
+

+ Oops! We can't seem to find the page you are looking for. Let's + head back home. +

+

+
diff --git a/_pages/about.md b/_pages/about.md new file mode 100644 index 0000000..bfd8158 --- /dev/null +++ b/_pages/about.md @@ -0,0 +1,15 @@ +--- +layout: post +title: "About" +author: "Chester" +permalink: /about/ +--- + +A friend of mine writes short stories. One sunny day, I asked if he wanted a website to showcase his works and he agreed. I decided to use GitHub Pages to host his site. That way he wouldn't have to buy a domain and a server. + +While doing some research up on GitHub Pages, I accidentally chanced upon this _simple, blog-aware, static site generator_ called [Jekyll](https://jekyllrb.com/) which works really well with GitHub Pages. I figured it would do just fine for my friend and I set about searching for a pretty theme. I wanted a theme with a _book-ish_ vibe. Unfortunately, most of the themes were too modern. Eventually, I caved and begun working on my own theme. With the help of [Poole](https://github.com/poole/poole), the Jekyll Butler, I was able to build **Tale**. + +## Contribute +Feel free to create an issue or make a pull request on [GitHub](https://github.com/chesterhow/tale). + +Thanks for reading! diff --git a/_pages/posts.md b/_pages/posts.md new file mode 100644 index 0000000..8ea9bc1 --- /dev/null +++ b/_pages/posts.md @@ -0,0 +1,50 @@ +--- +layout: default +title: "Posts" +permalink: /posts/ +--- + +
+
+

{{ page.title }}

+
+
+
+ {% for post in site.posts -%} + {% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture -%} + {% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture -%} + {% if forloop.first %}{{ this_year }}{% endif -%} + {% unless forloop.last -%} + {% if this_year != next_year %}{{ next_year }}{% endif -%} + {% endunless -%} + {% endfor -%} +
+ {% for post in site.posts -%} + {% capture this_year %}{{ post.date | date: "%Y" }}{% endcapture -%} + {% capture next_year %}{{ post.previous.date | date: "%Y" }}{% endcapture -%} + {% if forloop.first -%} +
+

{{ this_year }}

+ {% endif -%} + +
+ {{ post.title }} +
+
+ +
+ {% if forloop.last -%} +
+ {% else -%} + {% if this_year != next_year -%} +
+
+

{{ next_year }}

+ {% endif -%} + {% endif -%} + {% endfor -%} +
diff --git a/_pages/tags.md b/_pages/tags.md new file mode 100644 index 0000000..8f1b4a0 --- /dev/null +++ b/_pages/tags.md @@ -0,0 +1,54 @@ +--- +layout: default +title: "Tags" +permalink: /tags/ +--- + +
+
+

{{ page.title }}

+
+
+
+ {% assign st = site.tags | sort -%} + {% for tag in st -%} + {{ tag[0] | replace: '_', ' ' }} + {% endfor %} +
+ {% for tag in st -%} +
+ + + + +

{{ tag[0] | replace: '_', ' ' }} {feed}

+ {% for post in tag[1] -%} + +
+ {{ post.title }} +
+
+ +
+ {% endfor %} +
+ {% endfor %} +
diff --git a/_posts/2022-11-16-welcome-to-jekyll.markdown b/_posts/2022-11-16-welcome-to-jekyll.markdown new file mode 100644 index 0000000..a662aa5 --- /dev/null +++ b/_posts/2022-11-16-welcome-to-jekyll.markdown @@ -0,0 +1,30 @@ +--- +layout: post +title: "Welcome to Jekyll!" +author: Jonny +date: 2022-11-16 20:28:54 -0800 +tags: jekyll update +--- +You’ll find this post in your `_posts` directory. Go ahead and edit it and re-build the site to see your changes. You can rebuild the site in many different ways, but the most common way is to run `jekyll serve`, which launches a web server and auto-regenerates your site when a file is updated. + +Jekyll requires blog post files to be named according to the following format: + +`YEAR-MONTH-DAY-title.MARKUP` + +Where `YEAR` is a four-digit number, `MONTH` and `DAY` are both two-digit numbers, and `MARKUP` is the file extension representing the format used in the file. After that, include the necessary front matter. Take a look at the source for this post to get an idea about how it works. + +Jekyll also offers powerful support for code snippets: + +{% highlight ruby %} +def print_hi(name) + puts "Hi, #{name}" +end +print_hi('Tom') +#=> prints 'Hi, Tom' to STDOUT. +{% endhighlight %} + +Check out the [Jekyll docs][jekyll-docs] for more info on how to get the most out of Jekyll. File all bugs/feature requests at [Jekyll’s GitHub repo][jekyll-gh]. If you have questions, you can ask them on [Jekyll Talk][jekyll-talk]. + +[jekyll-docs]: https://jekyllrb.com/docs/home +[jekyll-gh]: https://github.com/jekyll/jekyll +[jekyll-talk]: https://talk.jekyllrb.com/ diff --git a/_sass/details.scss b/_sass/details.scss new file mode 100644 index 0000000..0790056 --- /dev/null +++ b/_sass/details.scss @@ -0,0 +1,17 @@ +details summary { + cursor: pointer; + color: $blue; + + &:hover { + text-decoration: underline; + } +} + +details[open] summary { + color: $default-color; + + &:hover { + text-decoration: none; + } +} + diff --git a/_sass/fonts.scss b/_sass/fonts.scss new file mode 100644 index 0000000..e982cc9 --- /dev/null +++ b/_sass/fonts.scss @@ -0,0 +1,167 @@ +/* merriweather-regular - latin-ext_latin */ +@font-face { + font-family: 'Merriweather'; + font-style: normal; + font-weight: 400; + src: url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-regular.svg#Merriweather') format('svg'); /* Legacy iOS */ +} + +/* merriweather-italic - latin-ext_latin */ +@font-face { + font-family: 'Merriweather'; + font-style: italic; + font-weight: 400; + src: url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-italic.svg#Merriweather') format('svg'); /* Legacy iOS */ +} + +/* merriweather-700italic - latin-ext_latin */ +@font-face { + font-family: 'Merriweather'; + font-style: italic; + font-weight: 700; + src: url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700italic.svg#Merriweather') format('svg'); /* Legacy iOS */ +} + +/* merriweather-700 - latin-ext_latin */ +@font-face { + font-family: 'Merriweather'; + font-style: normal; + font-weight: 700; + src: url('/assets/fonts/merriweather-v22-latin-ext_latin-700.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/merriweather-v22-latin-ext_latin-700.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/merriweather-v22-latin-ext_latin-700.svg#Merriweather') format('svg'); /* Legacy iOS */ +} + +/* source-sans-pro-italic - latin-ext_latin */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: italic; + font-weight: 400; + src: url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-italic.svg#SourceSansPro') format('svg'); /* Legacy iOS */ +} + +/* source-sans-pro-regular - latin-ext_latin */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 400; + src: url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-regular.svg#SourceSansPro') format('svg'); /* Legacy iOS */ +} + +/* source-sans-pro-700italic - latin-ext_latin */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: italic; + font-weight: 700; + src: url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700italic.svg#SourceSansPro') format('svg'); /* Legacy iOS */ +} + +/* source-sans-pro-700 - latin-ext_latin */ +@font-face { + font-family: 'Source Sans Pro'; + font-style: normal; + font-weight: 700; + src: url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-sans-pro-v14-latin-ext_latin-700.svg#SourceSansPro') format('svg'); /* Legacy iOS */ +} + +/* source-code-pro-regular - latin-ext_latin */ +@font-face { + font-family: 'Source Code Pro'; + font-style: normal; + font-weight: 400; + src: url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-regular.svg#SourceCodePro') format('svg'); /* Legacy iOS */ +} + +/* source-code-pro-italic - latin-ext_latin */ +@font-face { + font-family: 'Source Code Pro'; + font-style: italic; + font-weight: 400; + src: url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-italic.svg#SourceCodePro') format('svg'); /* Legacy iOS */ +} + +/* source-code-pro-700 - latin-ext_latin */ +@font-face { + font-family: 'Source Code Pro'; + font-style: normal; + font-weight: 700; + src: url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700.svg#SourceCodePro') format('svg'); /* Legacy iOS */ +} + +/* source-code-pro-700italic - latin-ext_latin */ +@font-face { + font-family: 'Source Code Pro'; + font-style: italic; + font-weight: 700; + src: url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.eot'); /* IE9 Compat Modes */ + src: local(''), + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.eot?#iefix') format('embedded-opentype'), /* IE6-IE8 */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.woff2') format('woff2'), /* Super Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.woff') format('woff'), /* Modern Browsers */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.ttf') format('truetype'), /* Safari, Android, iOS */ + url('/assets/fonts/source-code-pro-v13-latin-ext_latin-700italic.svg#SourceCodePro') format('svg'); /* Legacy iOS */ +} diff --git a/_sass/stlviewer.scss b/_sass/stlviewer.scss new file mode 100644 index 0000000..11d644c --- /dev/null +++ b/_sass/stlviewer.scss @@ -0,0 +1,25 @@ +.stl-viewer { + width: 100%; + padding-top: 100%; + position: relative; + text-align: center; + vertical-align: middle; + + canvas { + position: absolute; + top: 0; + left: 0; + bottom: 0; + right: 0; + } +} + +.svs-custom { padding-top: 0% !important; margin: 0 auto; } +.svs-4-3 { padding-top: 100% !important; } +.svs-16-9 { padding-top: 100% !important; } + +@media (min-width: 600px) { + .stl-viewer { padding-top: 56.25%; } + .svs-4-3 { padding-top: 75% !important; } + .svs-16-9 { padding-top: 56.25% !important; } +} diff --git a/_sass/tale.scss b/_sass/tale.scss new file mode 100644 index 0000000..35367cb --- /dev/null +++ b/_sass/tale.scss @@ -0,0 +1,16 @@ +@import 'fonts'; +@import 'tale/variables'; +@import 'tale/base'; +@import 'tale/code'; +@import 'tale/post'; +@import 'tale/syntax'; +@import 'tale/layout'; +@import 'tale/pagination'; +@import 'tale/catalogue'; +@import 'tale/404'; +@import 'tale/tags'; +@import 'tale/sidenote'; +@import 'tale/footnotes'; +@import 'tale/navigation'; +@import 'stlviewer'; +@import 'details'; diff --git a/_sass/tale/_404.scss b/_sass/tale/_404.scss new file mode 100644 index 0000000..4b8fce3 --- /dev/null +++ b/_sass/tale/_404.scss @@ -0,0 +1,22 @@ +.notfound { + position: relative; + text-align: center; + margin: 4rem 0; + + &-error { + font-size: 4rem; + margin: 1rem 0; + } + + &-line { + border-top: 0.4rem solid $default-shade; + display: block; + margin: 0 auto 3rem; + width: 4rem; + } + + &-message { + max-width: 25rem; + margin: 0 auto; + } +} diff --git a/_sass/tale/_base.scss b/_sass/tale/_base.scss new file mode 100644 index 0000000..a513579 --- /dev/null +++ b/_sass/tale/_base.scss @@ -0,0 +1,66 @@ +* { + @include box-sizing; + line-height: 1.5; +} + +html, +body { + color: $default-color; + margin: 0; + padding: 0; +} + +html { + font-family: $serif-primary; + font-size: 14px; + overflow-y: scroll; + + @media (min-width: 600px) { + font-size: 16px; + } +} + +body { + -webkit-text-size-adjust: 100%; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + color: $default-shade; + font-family: $sans-serif; + line-height: normal; +} + +a { + color: $blue; + text-decoration: none; +} + +blockquote { + border-left: .25rem solid $grey-2; + color: $grey-1; + margin: .8rem 0; + padding: .5rem 1rem; + + p:last-child { + margin-bottom: 0; + } + + @media (min-width: 600px) { + padding: 0 5rem 0 1.25rem; + } +} + +img { + display: block; + margin: 0 0 1rem; + max-width: 100%; +} + +td { + vertical-align: top; +} diff --git a/_sass/tale/_catalogue.scss b/_sass/tale/_catalogue.scss new file mode 100644 index 0000000..0587bc5 --- /dev/null +++ b/_sass/tale/_catalogue.scss @@ -0,0 +1,39 @@ +.catalogue { + &-item { + border-bottom: 1px solid $grey-2; + color: $default-color; + display: block; + padding: 2rem 0; + + &:hover .catalogue-line, + &:focus .catalogue-line { + width: 5rem; + } + + &:last-child { + border: 0; + } + } + + &-time { + color: $default-tint; + font-family: $serif-secondary; + letter-spacing: .5px; + } + + &-title { + color: $default-shade; + display: block; + font-family: $sans-serif; + font-size: 2rem; + font-weight: 700; + margin: .5rem 0; + } + + &-line { + @include transition(all .3s ease-out); + border-top: .2rem solid $default-shade; + display: block; + width: 2rem; + } +} diff --git a/_sass/tale/_code.scss b/_sass/tale/_code.scss new file mode 100644 index 0000000..2e0d180 --- /dev/null +++ b/_sass/tale/_code.scss @@ -0,0 +1,46 @@ +pre, +code { + font-family: $monospaced; +} + +code { + background-color: $grey-3; + border-radius: 3px; + color: $code-color; + font-size: 85%; + padding: .25em .5em; +} + +pre { + margin: 0 0 1rem; +} + +pre code { + background-color: transparent; + color: inherit; + font-size: 85%; + padding: 0; +} + +.highlight { + background-color: $grey-3; + border-radius: 3px; + line-height: 1.2; + margin: 0 0 1rem; + padding: 0.5rem; + + pre { + margin-bottom: 0; + overflow-x: auto; + } + + .lineno { + color: $default-tint; + display: inline-block; // Ensures the null space also isn't selectable + padding: 0 .75rem 0 .25rem; + // Make sure numbers aren't selectable + -webkit-user-select: none; + -moz-user-select: none; + user-select: none; + } +} diff --git a/_sass/tale/_footnotes.scss b/_sass/tale/_footnotes.scss new file mode 100644 index 0000000..abe20a5 --- /dev/null +++ b/_sass/tale/_footnotes.scss @@ -0,0 +1,12 @@ +.footnotes { + border-top: .5px solid $grey-2; + font-size: 80%; + + li { + padding: 0 1em 0 0; + + p { + margin-bottom: 0; + } + } +} diff --git a/_sass/tale/_layout.scss b/_sass/tale/_layout.scss new file mode 100644 index 0000000..ba4a7b0 --- /dev/null +++ b/_sass/tale/_layout.scss @@ -0,0 +1,92 @@ +.container { + margin: 0 auto; + max-width: 800px; + width: 80%; +} + +main, +footer, +.nav-container { + display: block; + margin: 0 auto; + max-width: 800px; + width: 80%; +} + +.nav { + box-shadow: 0 2px 2px -2px $shadow-color; + overflow: auto; + + &-container { + margin: 1rem auto; + position: relative; + text-align: center; + } + + &-title { + @include transition(all .2s ease-out); + color: $default-color; + display: inline-block; + margin: 0; + padding-right: .2rem; + + &:hover, + &:focus { + opacity: .6; + } + } + + ul { + list-style-type: none; + margin: 1rem 0 0; + padding: 0; + text-align: center; + } + + li { + @include transition(all .2s ease-out); + color: $default-color; + display: inline-block; + opacity: .6; + padding: 0 2rem 0 0; + + &:last-child { + padding-right: 0; + } + + &:hover, + &:focus { + opacity: 1; + } + } + + a { + color: $default-color; + font-family: $sans-serif; + } +} + +@media (min-width: 600px) { + .nav { + &-container { + text-align: left; + } + + ul { + bottom: 0; + position: absolute; + right: 0; + } + } +} + +footer { + font-family: $serif-secondary; + padding: 2rem 0; + text-align: center; + + span { + color: $default-color; + font-size: .8rem; + } +} diff --git a/_sass/tale/_navigation.scss b/_sass/tale/_navigation.scss new file mode 100644 index 0000000..f65cf06 --- /dev/null +++ b/_sass/tale/_navigation.scss @@ -0,0 +1,5 @@ +.nav-container img { + display: inline; + margin: 0; + vertical-align: middle; +} diff --git a/_sass/tale/_pagination.scss b/_sass/tale/_pagination.scss new file mode 100644 index 0000000..3700e15 --- /dev/null +++ b/_sass/tale/_pagination.scss @@ -0,0 +1,44 @@ +.pagination { + border-top: .5px solid $grey-2; + font-family: $serif-secondary; + padding-top: 2rem; + position: relative; + text-align: center; + + span { + color: $default-shade; + font-size: 1.1rem; + } + + .top { + @include transition(all .3s ease-out); + color: $default-color; + font-family: $sans-serif; + font-size: 1.1rem; + opacity: .6; + + &:hover { + opacity: 1; + } + } + + .arrow { + @include transition(all .3s ease-out); + color: $default-color; + position: absolute; + + &:hover, + &:focus { + opacity: .6; + text-decoration: none; + } + } + + .left { + left: 0; + } + + .right { + right: 0; + } +} diff --git a/_sass/tale/_post.scss b/_sass/tale/_post.scss new file mode 100644 index 0000000..e291451 --- /dev/null +++ b/_sass/tale/_post.scss @@ -0,0 +1,67 @@ +.post { + padding: 3rem 0; + + &-info { + color: $default-tint; + font-family: $serif-secondary; + letter-spacing: 0.5px; + text-align: center; + + span { + font-style: italic; + } + } + + &-title { + color: $default-shade; + font-family: $sans-serif; + font-size: 2rem; + margin: 1rem 0; + text-align: center; + } + + &-line { + border-top: 0.4rem solid $default-shade; + display: block; + margin: 0 auto 3rem; + width: 4rem; + } + + p { + margin: 0 0 1rem; + text-align: justify; + } + + .tags-clouds a:hover { + text-decoration: none; + } + + a:hover { + text-decoration: underline; + } + + img { + margin: 0 auto 0.5rem; + } + + img + em { + color: $default-tint; + display: block; + font-family: $sans-serif; + font-size: 0.9rem; + font-style: normal; + text-align: center; + } + + // CSS for making emoji inline + img.emoji { + display: inline-block; + left: 0; + transform: none; + width: 1rem; + height: 1rem; + vertical-align: text-top; + padding: 0; + margin: 0; + } +} diff --git a/_sass/tale/_sidenote.scss b/_sass/tale/_sidenote.scss new file mode 100644 index 0000000..d2d0382 --- /dev/null +++ b/_sass/tale/_sidenote.scss @@ -0,0 +1,34 @@ +.sidenote { + position: absolute; + text-align: left; + padding-left: 20px; + margin-left: 20px; + margin-bottom: 1.5em; + border-left: 1px solid $default-color; + color: $default-color; + font-style: italic; + font-size: 0.8em; + + &-header { + font-weight: 700; + } + + &-hover { + color: $highlight-color; + border-color: $highlight-color; + } + + p { + display: inline; + } + + /* kramdown */ + .reversefootnote { + display: none; + } + + /* commonmark */ + .footnote-backref { + display: none; + } +} diff --git a/_sass/tale/_syntax.scss b/_sass/tale/_syntax.scss new file mode 100644 index 0000000..15ad797 --- /dev/null +++ b/_sass/tale/_syntax.scss @@ -0,0 +1,65 @@ +.highlight .hll { background-color: #ffc; } +.highlight .c { color: #999; } /* Comment */ +.highlight .err { color: #a00; background-color: #faa } /* Error */ +.highlight .k { color: #069; } /* Keyword */ +.highlight .o { color: #555 } /* Operator */ +.highlight .cm { color: #09f; font-style: italic } /* Comment.Multiline */ +.highlight .cp { color: #099 } /* Comment.Preproc */ +.highlight .c1 { color: #999; } /* Comment.Single */ +.highlight .cs { color: #999; } /* Comment.Special */ +.highlight .gd { background-color: #fcc; border: 1px solid #c00 } /* Generic.Deleted */ +.highlight .ge { font-style: italic } /* Generic.Emph */ +.highlight .gr { color: #f00 } /* Generic.Error */ +.highlight .gh { color: #030; } /* Generic.Heading */ +.highlight .gi { background-color: #cfc; border: 1px solid #0c0 } /* Generic.Inserted */ +.highlight .go { color: #aaa } /* Generic.Output */ +.highlight .gp { color: #009; } /* Generic.Prompt */ +.highlight .gs { } /* Generic.Strong */ +.highlight .gu { color: #030; } /* Generic.Subheading */ +.highlight .gt { color: #9c6 } /* Generic.Traceback */ +.highlight .kc { color: #069; } /* Keyword.Constant */ +.highlight .kd { color: #069; } /* Keyword.Declaration */ +.highlight .kn { color: #069; } /* Keyword.Namespace */ +.highlight .kp { color: #069 } /* Keyword.Pseudo */ +.highlight .kr { color: #069; } /* Keyword.Reserved */ +.highlight .kt { color: #078; } /* Keyword.Type */ +.highlight .m { color: #f60 } /* Literal.Number */ +.highlight .s { color: #d44950 } /* Literal.String */ +.highlight .na { color: #4f9fcf } /* Name.Attribute */ +.highlight .nb { color: #366 } /* Name.Builtin */ +.highlight .nc { color: #0a8; } /* Name.Class */ +.highlight .no { color: #360 } /* Name.Constant */ +.highlight .nd { color: #99f } /* Name.Decorator */ +.highlight .ni { color: #999; } /* Name.Entity */ +.highlight .ne { color: #c00; } /* Name.Exception */ +.highlight .nf { color: #c0f } /* Name.Function */ +.highlight .nl { color: #99f } /* Name.Label */ +.highlight .nn { color: #0cf; } /* Name.Namespace */ +.highlight .nt { color: #2f6f9f; } /* Name.Tag */ +.highlight .nv { color: #033 } /* Name.Variable */ +.highlight .ow { color: #000; } /* Operator.Word */ +.highlight .w { color: #bbb } /* Text.Whitespace */ +.highlight .mf { color: #f60 } /* Literal.Number.Float */ +.highlight .mh { color: #f60 } /* Literal.Number.Hex */ +.highlight .mi { color: #f60 } /* Literal.Number.Integer */ +.highlight .mo { color: #f60 } /* Literal.Number.Oct */ +.highlight .sb { color: #c30 } /* Literal.String.Backtick */ +.highlight .sc { color: #c30 } /* Literal.String.Char */ +.highlight .sd { color: #c30; font-style: italic } /* Literal.String.Doc */ +.highlight .s2 { color: #c30 } /* Literal.String.Double */ +.highlight .se { color: #c30; } /* Literal.String.Escape */ +.highlight .sh { color: #c30 } /* Literal.String.Heredoc */ +.highlight .si { color: #a00 } /* Literal.String.Interpol */ +.highlight .sx { color: #c30 } /* Literal.String.Other */ +.highlight .sr { color: #3aa } /* Literal.String.Regex */ +.highlight .s1 { color: #c30 } /* Literal.String.Single */ +.highlight .ss { color: #fc3 } /* Literal.String.Symbol */ +.highlight .bp { color: #366 } /* Name.Builtin.Pseudo */ +.highlight .vc { color: #033 } /* Name.Variable.Class */ +.highlight .vg { color: #033 } /* Name.Variable.Global */ +.highlight .vi { color: #033 } /* Name.Variable.Instance */ +.highlight .il { color: #f60 } /* Literal.Number.Integer.Long */ + +.css .o, +.css .o + .nt, +.css .nt + .nt { color: #999; } diff --git a/_sass/tale/_tags.scss b/_sass/tale/_tags.scss new file mode 100644 index 0000000..9e61cdf --- /dev/null +++ b/_sass/tale/_tags.scss @@ -0,0 +1,89 @@ +.tags { + &-header { + &-title { + color: $default-shade; + font-family: $sans-serif; + font-size: 4rem; + margin: 1rem 0; + text-align: center; + } + + &-line { + border-top: 0.4rem solid $default-shade; + display: block; + margin: 0 auto 3rem; + width: 4rem; + } + } + + &-clouds { + text-align: center; + font-family: $sans-serif; + + a { + display: inline-block; + margin: 0 0.1rem 0.2rem; + padding: 0.2rem 0.5rem; + background: rgba(0, 0, 0, 0.05); + border-radius: 5px; + color: $default-color; + text-decoration: none; + + &:hover, + &:active { + background: rgba(0, 0, 0, 0.1); + } + } + } + + &-item { + &-icon { + height: 1rem; + } + + &-label { + display: inline-block; + margin: 2rem 0 0.5rem; + font-family: $sans-serif; + color: $default-color; + } + } + + &-post { + display: flex; + justify-content: space-between; + padding: 5px 0; + + &-title { + color: $default-color; + text-decoration: none; + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } + + &-line { + @include transition(all 0.3s ease-out); + border-top: 0.1rem solid $default-shade; + display: block; + width: 0; + } + + &-meta { + color: $default-tint; + text-align: right; + white-space: nowrap; + } + + &:hover, + &:active { + .tags-post-line { + width: 3rem; + } + + .tags-post-meta { + color: $default-shade; + } + } + } +} diff --git a/_sass/tale/_variables.scss b/_sass/tale/_variables.scss new file mode 100644 index 0000000..1fca48d --- /dev/null +++ b/_sass/tale/_variables.scss @@ -0,0 +1,30 @@ +// Colors +$default-color: #111 !default; +$default-shade: #333 !default; +$default-tint: #aaa !default; +$grey-1: #979797 !default; +$grey-2: #e5e5e5 !default; +$grey-3: #f9f9f9 !default; +$white: #fff !default; +$blue: #5ae !default; +$shadow-color: rgba(0, 0, 0, .2) !default; +$code-color: #b67 !default; +$highlight-color: #f80 !default; + +// Fonts +$serif-primary: 'Merriweather', 'Georgia', 'Times New Roman', Times, serif !default; +$serif-secondary: $serif-primary; +$sans-serif: 'Source Sans Pro', 'Segoe UI', Helvetica, Arial, sans-serif !default; +$monospaced: 'Source Code Pro', Menlo, Monaco, monospace !default; + +@mixin box-sizing($type: border-box) { + -webkit-box-sizing: $type; + -moz-box-sizing: $type; + box-sizing: $type; +} + +@mixin transition($args...) { + -webkit-transition: $args; + -moz-transition: $args; + transition: $args; +} diff --git a/index.markdown b/index.markdown new file mode 100644 index 0000000..0671507 --- /dev/null +++ b/index.markdown @@ -0,0 +1,6 @@ +--- +# Feel free to add content and custom Front Matter to this file. +# To modify the layout, see https://jekyllrb.com/docs/themes/#overriding-theme-defaults + +layout: home +---