diff --git a/.bundle/config b/.bundle/config deleted file mode 100644 index 9bc01b4c3..000000000 --- a/.bundle/config +++ /dev/null @@ -1,3 +0,0 @@ ---- -BUNDLE_PATH: "vendor/bundle" -BUNDLE_DISABLE_SHARED_GEMS: "true" diff --git a/.gitattributes b/.gitattributes index a12b5fb4e..4d536e4ab 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,6 +1,10 @@ -assets/fonts/* linguist-vendored -assets/js/main.min.js linguist-vendored -assets/js/lunr/* linguist-vendored -assets/js/plugins/* linguist-vendored -assets/js/vendor/* linguist-vendored +assets/fonts/* linguist-vendored +assets/js/main.min.js linguist-vendored +assets/js/lunr/* linguist-vendored +assets/js/plugins/* linguist-vendored +assets/js/vendor/* linguist-vendored _sass/minimal-mistakes/vendor/* linguist-vendored +CHANGELOG.md text merge=union +docs/_docs/18-history.md text merge=union + +*.md text diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 000000000..ecc464788 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Some issue with your console after/during following the guide? + url: https://discord.gg/MWxPgEp + about: "Please join the Nintendo Homebrew Discord server to for support-related questions" diff --git a/.github/ISSUE_TEMPLATE/guide-issue.md b/.github/ISSUE_TEMPLATE/guide-issue.md new file mode 100644 index 000000000..e267151ae --- /dev/null +++ b/.github/ISSUE_TEMPLATE/guide-issue.md @@ -0,0 +1,12 @@ +--- +name: Guide Issue +about: Did you find some issue with the guide? +--- + +**Pages with issue(s)** + + + +**Description of the issue(s)** + + diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 000000000..c606235a1 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,3 @@ +**Description** + + diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 000000000..2c67f3ab1 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,40 @@ +name: Deploy site + +on: + push: + branches: [ master ] + workflow_dispatch: + +jobs: + doc-deploy: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + with: + persist-credentials: false + + - uses: ruby/setup-ruby@v1 + with: + ruby-version: '3.2' + + - name: Install dependencies + run: bundle install + + - name: Run Jekyll + # Build the site using Jekyll + run: JEKYLL_ENV=production bundle exec jekyll build + + # Copy (or touch) other needed files + # .nojekyll: to tell GH Pages to not rebuild (lol) + # CNAME: to tell GH Pages about the domain name + - name: Post-Jekyll build copy files + run: | + touch _site/.nojekyll + + - name: Deploy 🚀 + uses: JamesIves/github-pages-deploy-action@v4.4.1 + with: + branch: gh-pages # The branch the action should deploy to. + folder: _site # The folder the action should deploy. + clean: true # Automatically remove deleted files from the deploy branch diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 000000000..a20069d11 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,24 @@ +name: Test site build + +on: + pull_request: + +jobs: + doc-test: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + with: + persist-credentials: false + + - uses: ruby/setup-ruby@v1 + with: + ruby-version: '3.2' + + - name: Install dependencies + run: bundle install + + - name: Run Jekyll + # Build the site using Jekyll + run: JEKYLL_ENV=production bundle exec jekyll build diff --git a/.gitignore b/.gitignore index 9db24fb77..5c5a91f8f 100644 --- a/.gitignore +++ b/.gitignore @@ -1,17 +1,29 @@ -*.gem +# Vim +*~ +*.sw[p_] + +# Sublime Text *.sublime-project *.sublime-workspace + +# Ruby Gem +*.gem .bundle +Gemfile.lock +**/vendor/bundle + +# Node.js and NPM +node_modules +npm-debug.log* +package-lock.json +codekit-config.json + +# macOS .DS_Store -.jekyll-metadata + +# Jekyll generated files .jekyll-cache +.jekyll-metadata .sass-cache _asset_bundler_cache _site -codekit-config.json -example/_site -node_modules -npm-debug.log* -/vendor -/.idea -Gemfile.lock \ No newline at end of file diff --git a/Gemfile b/Gemfile index ee970a2b0..129149897 100644 --- a/Gemfile +++ b/Gemfile @@ -1,10 +1,2 @@ source "https://rubygems.org" - -gem "jekyll", "~> 3.9" -gem "jekyll-sitemap", "~> 1.4" -gem "jekyll-gist", "~> 1.5" -gem "jekyll-feed", "~> 0.16.0" -gem "jekyll-data", "~> 1.1" -gem "kramdown-parser-gfm", "~> 1.1" -gem "webrick", "~> 1.7" gemspec \ No newline at end of file diff --git a/LICENSE.txt b/LICENSE.txt index 536ab071e..c1f64a62a 100755 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -1,6 +1,10 @@ The MIT License (MIT) -Copyright (c) 2017 Michael Rose +Copyright (c) 2013-2020 Michael Rose and contributors +Copyright (c) 2016-2017 Plailect +Copyright (c) 2017-2023 RiiConnect24 +Copyright (c) 2023 Nintendo Homebrew + Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md deleted file mode 100644 index f41b00abb..000000000 --- a/README.md +++ /dev/null @@ -1,48 +0,0 @@ -# Wii Guide - -[![License](https://img.shields.io/github/license/riiconnect24/wii-guide.svg?style=flat-square)](LICENSE.txt) -![Production List](https://img.shields.io/discord/206934458954153984.svg?style=flat-square) - -Wii.guide is the complete guide to modding your Nintendo Wii console. -We're here to help people installing Homebrew Channel and many other mods to their consoles, allowing for doing pretty much anything with your console. - -The site: [wii.guide](https://wii.guide) - -## Would you like to contribute? - -You can translate the site by using Crowdin, a site created to translate projects. -You can join here: [Wii.guide's Crowdin Page](https://crowdin.com/project/wii-guide) - -## Running Wii-Guide locally - -### Installing on Windows: - -1. Download the latest RubyInstaller **with devkit** from -1. Run the installer and on the last screen make sure to have the `ridk install` step _checked_ -1. A command prompt window should appear, choose the number for `MSYS2 and MINGW development tool chain` and press enter. -1. Open a new command prompt window then continue to Running Jekyll - -### Installing on Linux: - -1. Install Ruby with `sudo apt install ruby ruby-dev build-essentials git -y` (Or your package manager equivalent) -1. Run `gem install jekyll bundler` -1. Continue to Running Jekyll - -### Running Jekyll: - -1. Please follow the installation steps for your platform if you haven't in the past -1. Navigate to a directory for git to create the Wii-Guide folder in -1. Run `git clone https://github.com/RiiConnect24/Wii-Guide` (Or the url of the fork you want to clone) -1. If you want to use another branch, now run `git checkout ` -1. Next run `bundle install` -1. Finally, run `bundle exec jekyll serve --incremental` -1. Navigate to https://localhost:4000, your server should be running! - -### Notes: - -- From now on you can just run `bundle exec jekyll serve --incremental` from the Wii-Guide directory -- When (re)cloning a repository or updating the `Gemfile` file, run `bundle install` first -- If a page isn't updating correctly after making local changes, try removing the `--incremental` argument first - - You can also hard refresh the website with `Ctrl + Shift + R` usually - - If this doesn't help close your web browser entirely (All windows!) and try again -- Making a change to a file will regenerate the local webview automatically if jekyll is running diff --git a/_config.yml b/_config.yml index 693e7ab3b..ebb9321c9 100755 --- a/_config.yml +++ b/_config.yml @@ -5,23 +5,33 @@ # For technical reasons, this file is *NOT* reloaded automatically when you use # `jekyll serve`. If you change this file, please restart the server process. -minimal_mistakes_skin : "nord" +# Theme Settings +# +# Review documentation to determine if you should use `theme` or `remote_theme` +# https://mmistakes.github.io/minimal-mistakes/docs/quick-start-guide/#installing-the-theme + +# theme : "minimal-mistakes-jekyll" +# remote_theme : "mmistakes/minimal-mistakes" +minimal_mistakes_skin : "nord" # "default" # "air", "aqua", "contrast", "dark", "dirt", "neon", "mint", "plum", "sunrise" # Site Settings locale : "en-US" -title : "Wii Guide" +title : "Wii Hacks Guide" title_separator : "-" -name : "RiiConnect24" -description : "Wii modding guide" -url : "https://wii.guide" # the base hostname & protocol for your site e.g. "https://mmistakes.github.io" -enforce_ssl : "wii.guide" +subtitle : # site tagline that appears below site title in masthead +name : "Nintendo Homebrew" +description : "A complete guide to Wii custom firmware" +url : "https://wii.hacks.guide" # the base hostname & protocol for your site e.g. "https://mmistakes.github.io" +enforce_ssl : "wii.hacks.guide" baseurl : # the subpath of your site, e.g. "/blog" -repository : "RiiConnect24/Wii-Guide" # GitHub username/repo-name e.g. "mmistakes/minimal-mistakes" -teaser : # filename of teaser fallback teaser image placed in /images/, .e.g. "500x300.png" -breadcrumbs : # true, false (default) +repository : "hacks-guide/Guide_Wii" # GitHub username/repo-name e.g. "mmistakes/minimal-mistakes" +teaser : # path of fallback teaser image, e.g. "/assets/images/500x300.png" +logo : # path of logo image to display in the masthead, e.g. "/assets/images/88x88.png" +masthead_title : # overrides the website title displayed in the masthead, use " " for no title +# breadcrumbs : false # true, false (default) words_per_minute : 200 comments: - provider : # false (default), "disqus", "discourse", "facebook", "google-plus", "staticman", "custom" + provider : # false (default), "disqus", "discourse", "facebook", "staticman", "staticman_v2", "utterances", "giscus", "custom" disqus: shortname : # https://help.disqus.com/customer/portal/articles/466208-what-s-a-shortname- discourse: @@ -31,36 +41,47 @@ comments: appid : num_posts : # 5 (default) colorscheme : # "light" (default), "dark" -staticman: - allowedFields : ['name', 'email', 'url', 'message'] - branch : "master" - commitMessage : "New comment." - filename : comment-{@timestamp} - format : "yml" - moderation : true - path : "_data/comments/{options.slug}" - requiredFields : ['name', 'email', 'message'] - transforms: - email : "md5" - generatedFields: - date: - type : "date" - options: - format : "iso8601" # "iso8601" (default), "timestamp-seconds", "timestamp-milliseconds" + utterances: + theme : # "github-light" (default), "github-dark" + issue_term : # "pathname" (default) + giscus: + repo_id : # Shown during giscus setup at https://giscus.app + category_name : # Full text name of the category + category_id : # Shown during giscus setup at https://giscus.app + discussion_term : # "pathname" (default), "url", "title", "og:title" + reactions_enabled : # '1' for enabled (default), '0' for disabled + theme : # "light" (default), "dark", "dark_dimmed", "transparent_dark", "preferred_color_scheme" + staticman: + branch : # "master" + endpoint : # "https://{your Staticman v3 API}/v3/entry/github/" +reCaptcha: + siteKey : + secret : atom_feed: path : # blank (default) uses feed.xml - + hide : # true, false (default) +search : # true, false (default) +search_full_content : # true, false (default) +search_provider : # lunr (default), algolia, google +algolia: + application_id : # YOUR_APPLICATION_ID + index_name : # YOUR_INDEX_NAME + search_only_api_key : # YOUR_SEARCH_ONLY_API_KEY + powered_by : # true (default), false +google: + search_engine_id : # YOUR_SEARCH_ENGINE_ID + instant_search : # false (default), true # SEO Related -google_site_verification : NJHNJQvHO4NNbW_2IYtDhRIfX5-4kUpwkxsmVfM7S34 -bing_site_verification : 229FBDF9FE2F1A36CEDFAB9F171C6A4E -alexa_site_verification : +google_site_verification : +bing_site_verification : yandex_site_verification : +naver_site_verification : # Social Sharing twitter: - username : "RiiConnect24" + username : facebook: - username : "RiiConnect24" + username : app_id : publisher : og_image : # Open Graph/Twitter default site image @@ -73,48 +94,67 @@ social: # Analytics analytics: - provider : "google-universal" # false (default), "google", "google-universal", "custom" + provider : # false (default), "google", "google-universal", "google-gtag", "custom" google: - tracking_id : "UA-72766480-5" + tracking_id : + anonymize_ip : # true, false (default) # Site Author author: - name : "RiiConnect24" - avatar : "bio-photo.png" - bio : "WiiConnect24 replacement" - location : "United States" - email : "support@riiconnect24.net" - uri : "https://rc24.xyz" - bitbucket : - codepen : - dribbble : - flickr : - facebook : "RiiConnect24" - foursquare : - github : "RiiConnect24" - google_plus : "RiiConnect24" - keybase : - instagram : "RiiConnect24" - lastfm : - linkedin : - pinterest : - soundcloud : - stackoverflow : # "123456/username" (the last part of your profile url, e.g. http://stackoverflow.com/users/123456/username) - steam : - tumblr : - twitter : "RiiConnect24" - vine : - weibo : - xing : - youtube : "RiiConnect24" + name : "Nintendo Homebrew" + avatar : # path of avatar image, e.g. "/assets/images/bio-photo.jpg" + bio : "Nintendo Homebrew Community" + location : "Nullsec" + email : + links: + # - label: "Email" + # icon: "fas fa-fw fa-envelope-square" + # url: "mailto:your.name@email.com" + # - label: "Website" + # icon: "fas fa-fw fa-link" + # url: "https://your-website.com" + # - label: "Twitter" + # icon: "fab fa-fw fa-twitter-square" + # url: "https://twitter.com/" + # - label: "Facebook" + # icon: "fab fa-fw fa-facebook-square" + # url: "https://facebook.com/" + - label: "GitHub" + icon: "fab fa-fw fa-github" + url: "https://github.com/hacks-guide/Guide_Wii" + # - label: "Instagram" + # icon: "fab fa-fw fa-instagram" + # url: "https://instagram.com/" + +# Site Footer +footer: + links: + # - label: "Twitter" + # icon: "fab fa-fw fa-twitter-square" + # url: + # - label: "Facebook" + # icon: "fab fa-fw fa-facebook-square" + # url: + - label: "GitHub" + icon: "fab fa-fw fa-github" + url: "https://github.com/hacks-guide/Guide_Wii" + # - label: "GitLab" + # icon: "fab fa-fw fa-gitlab" + # url: + # - label: "Bitbucket" + # icon: "fab fa-fw fa-bitbucket" + # url: + # - label: "Instagram" + # icon: "fab fa-fw fa-instagram" + # url: # Reading Files include: - - .htaccess - - _pages - - _pages/en_US + - .htaccess + - _pages + - _pages/en_US exclude: [ "*.sublime-project", "*.sublime-workspace", @@ -126,6 +166,7 @@ exclude: [ assets/js/plugins, assets/js/_main.js, assets/js/vendor, + banner.js, Capfile, CHANGELOG, config, @@ -134,20 +175,30 @@ exclude: [ gulpfile.js, LICENSE, log, + minimal-mistakes-jekyll.gemspec, node_modules, package.json, + package-lock.json, Rakefile, README, - tmp, + crowdin.yaml, + staticman.yml, + _pages/af_ZA, + _pages/ar_SA, _pages/ca_ES, _pages/cs_CZ, _pages/da_DK, # _pages/de_DE, - _ pages/el_GR, + _pages/el_GR, + # _pages/en_US, + _pages/es_419, + _pages/es_EM, # _pages/es_ES, + _pages/es_MX, _pages/fi_FI, # _pages/fr_FR, _pages/he_IL, + _pages/hu_HU, # _pages/it_IT, _pages/ja_JP, # _pages/ko_KR, @@ -156,11 +207,15 @@ exclude: [ # _pages/pl_PL, _pages/pt_BR, _pages/pt_PT, + _pages/ro_RO, _pages/ru_RU, + _pages/sr_SP, _pages/sv_SE, # _pages/tr_TR, + _pages/uk_UA, + _pages/vi_VN, # _pages/zh_CN, - _pages/zh_TW + _pages/zh_TW, ] keep_files: @@ -193,19 +248,31 @@ kramdown: # Sass/SCSS sass: sass_dir: _sass - style: compressed # http://sass-lang.com/documentation/file.SASS_REFERENCE.html#output_style + style: compressed # https://sass-lang.com/documentation/file.SASS_REFERENCE.html#output_style -# Plugins + +# Outputting +# permalink: /:categories/:title/ +# paginate: 5 # amount of posts to show +# paginate_path: /page:num/ +# timezone: # https://en.wikipedia.org/wiki/List_of_tz_database_time_zones + + +# Plugins (previously gems:) plugins: + - jekyll-paginate - jekyll-sitemap - jekyll-gist - jekyll-feed + - jekyll-include-cache # mimic GitHub Pages with --safe whitelist: + - jekyll-paginate - jekyll-sitemap - jekyll-gist - jekyll-feed + - jekyll-include-cache # Archives @@ -216,8 +283,8 @@ whitelist: # - Archive page should exist at path when using Liquid method or you can # expect broken links (especially with breadcrumbs enabled) # - /tags/my-awesome-tag/index.html ~> path: /tags/ -# - path: /categories/ -# - path: / +# - /categories/my-awesome-category/index.html ~> path: /categories/ +# - /my-awesome-category/index.html ~> path: / category_archive: type: liquid path: /categories/ @@ -238,12 +305,13 @@ tag_archive: # HTML Compression -# - http://jch.penibelst.de/ +# - https://jch.penibelst.de/ compress_html: clippings: all ignore: envs: development + # Defaults defaults: # _pages @@ -296,18 +364,18 @@ defaults: values: permalink: /el_GR/:basename:output_ext lang: el - - scope: - path: "_pages/en_PT" - type: pages - values: - permalink: /en_PT/:basename:output_ext - lang: en-PT - scope: path: "_pages/en_US" type: pages values: permalink: /:basename:output_ext lang: en + - scope: + path: "_pages/es_MX" + type: pages + values: + permalink: /es_MX/:basename:output_ext + lang: es_MX - scope: path: "_pages/es_ES" type: pages @@ -338,12 +406,6 @@ defaults: values: permalink: /hu_HU/:basename:output_ext lang: hu - - scope: - path: "_pages/id_ID" - type: pages - values: - permalink: /id_ID/:basename:output_ext - lang: id - scope: path: "_pages/it_IT" type: pages @@ -363,35 +425,23 @@ defaults: permalink: /ko_KR/:basename:output_ext lang: ko - scope: - path: "_pages/ms_MY" + path: "_pages/nl_NL" type: pages values: - permalink: /ms_MY/:basename:output_ext - lang: ms + permalink: /nl_NL/:basename:output_ext + lang: nl - scope: path: "_pages/no_NO" type: pages values: permalink: /no_NO/:basename:output_ext lang: no-NO - - scope: - path: "_pages/nl_NL" - type: pages - values: - permalink: /nl_NL/:basename:output_ext - lang: nl - scope: path: "_pages/pl_PL" type: pages values: permalink: /pl_PL/:basename:output_ext lang: pl - - scope: - path: "_pages/es_MX" - type: pages - values: - permalink: /es_MX/:basename:output_ext - lang: es_MX - scope: path: "_pages/pt_BR" type: pages @@ -428,12 +478,6 @@ defaults: values: permalink: /sv_SE/:basename:output_ext lang: sv - - scope: - path: "_pages/th_TH" - type: pages - values: - permalink: /th_TH/:basename:output_ext - lang: th - scope: path: "_pages/tr_TR" type: pages @@ -499,11 +543,6 @@ defaults: type: pages values: permalink: /el_GR/index:output_ext - - scope: - path: "_pages/en_PT/home.md" - type: pages - values: - permalink: /en_PT/index:output_ext - scope: path: "_pages/en_US/home.md" type: pages @@ -514,6 +553,11 @@ defaults: type: pages values: permalink: /es_ES/index:output_ext + - scope: + path: "_pages/es_MX/home.md" + type: pages + values: + permalink: /es_MX/index:output_ext - scope: path: "_pages/fi_FI/home.md" type: pages @@ -534,11 +578,6 @@ defaults: type: pages values: permalink: /hu_HU/index:output_ext - - scope: - path: "_pages/id_ID/home.md" - type: pages - values: - permalink: /id_ID/index:output_ext - scope: path: "_pages/it_IT/home.md" type: pages @@ -555,30 +594,20 @@ defaults: values: permalink: /ko_KR/index:output_ext - scope: - path: "_pages/ms_MY/home.md" + path: "_pages/nl_NL/home.md" type: pages values: - permalink: /ms_MY/index:output_ext + permalink: /nl_NL/index:output_ext - scope: path: "_pages/no_NO/home.md" type: pages values: permalink: /no_NO/index:output_ext - - scope: - path: "_pages/nl_NL/home.md" - type: pages - values: - permalink: /nl_NL/index:output_ext - scope: path: "_pages/pl_PL/home.md" type: pages values: permalink: /pl_PL/index:output_ext - - scope: - path: "_pages/es_MX/home.md" - type: pages - values: - permalink: /es_MX/index:output_ext - scope: path: "_pages/pt_BR/home.md" type: pages @@ -609,11 +638,6 @@ defaults: type: pages values: permalink: /sv_SE/index:output_ext - - scope: - path: "_pages/th_TH/home.md" - type: pages - values: - permalink: /th_TH/index:output_ext - scope: path: "_pages/tr_TR/home.md" type: pages diff --git a/_includes/analytics-providers/google-gtag.html b/_includes/analytics-providers/google-gtag.html new file mode 100644 index 000000000..16d0cf176 --- /dev/null +++ b/_includes/analytics-providers/google-gtag.html @@ -0,0 +1,9 @@ + + + diff --git a/_includes/analytics-providers/google-universal.html b/_includes/analytics-providers/google-universal.html index 10d65b2ee..68c2674ba 100644 --- a/_includes/analytics-providers/google-universal.html +++ b/_includes/analytics-providers/google-universal.html @@ -1,9 +1,7 @@ + diff --git a/_includes/analytics-providers/google.html b/_includes/analytics-providers/google.html index b591b9954..c5742b981 100644 --- a/_includes/analytics-providers/google.html +++ b/_includes/analytics-providers/google.html @@ -1,6 +1,9 @@ - \ No newline at end of file + diff --git a/_includes/analytics.html b/_includes/analytics.html index 64a3359aa..371469f0a 100644 --- a/_includes/analytics.html +++ b/_includes/analytics.html @@ -1,10 +1,12 @@ -{% if site.analytics.provider and page.analytics != false %} +{% if jekyll.environment == 'production' and site.analytics.provider and page.analytics != false %} {% case site.analytics.provider %} {% when "google" %} {% include /analytics-providers/google.html %} {% when "google-universal" %} {% include /analytics-providers/google-universal.html %} +{% when "google-gtag" %} + {% include /analytics-providers/google-gtag.html %} {% when "custom" %} {% include /analytics-providers/custom.html %} {% endcase %} diff --git a/_includes/archive-single.html b/_includes/archive-single.html index dc9ac7375..68174807e 100644 --- a/_includes/archive-single.html +++ b/_includes/archive-single.html @@ -10,29 +10,21 @@ {% assign title = post.title %} {% endif %} -
-
+
+
{% if include.type == "grid" and teaser %}
- +
{% endif %} -

+

{% if post.link %} - {{ title }} Permalink + {{ title }} Permalink {% else %} - {{ title }} + {{ title }} {% endif %}

- {% if post.read_time %} -

{% include read-time.html %}

- {% endif %} + {% include page__meta.html type=include.type %} {% if post.excerpt %}

{{ post.excerpt | markdownify | strip_html | truncate: 160 }}

{% endif %}
diff --git a/_includes/author-profile-custom-links.html b/_includes/author-profile-custom-links.html index 3560e2588..b89ffcb7d 100644 --- a/_includes/author-profile-custom-links.html +++ b/_includes/author-profile-custom-links.html @@ -1,7 +1,7 @@ \ No newline at end of file diff --git a/_includes/author-profile.html b/_includes/author-profile.html index 2d1054312..d384ee734 100644 --- a/_includes/author-profile.html +++ b/_includes/author-profile.html @@ -1,27 +1,30 @@ -{% if page.author and site.data.authors[page.author] %} - {% assign author = site.data.authors[page.author] %} -{% else %} - {% assign author = site.author %} -{% endif %} +{% assign author = page.author | default: page.authors[0] | default: site.author %} +{% assign author = site.data.authors[author] | default: author %} -
+
{% if author.avatar %}
- {% if author.avatar contains "://" %} - {{ author.name }} + {% if author.home %} + + {{ author.name }} + {% else %} - {{ author.name }} + {{ author.name }} {% endif %}
{% endif %}
-

{{ author.name }}

+ {% if author.home %} +

{{ author.name }}

+ {% else %} +

{{ author.name }}

+ {% endif %} {% if author.bio %} -

- {{ author.bio }} -

+
+ {{ author.bio | markdownify }} +
{% endif %}
@@ -29,15 +32,23 @@ - + \ No newline at end of file diff --git a/_includes/page__date.html b/_includes/page__date.html new file mode 100644 index 000000000..4f995ed0a --- /dev/null +++ b/_includes/page__date.html @@ -0,0 +1,6 @@ +{% assign date_format = site.date_format | default: "%B %-d, %Y" %} +{% if page.last_modified_at %} +

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

+{% elsif page.date %} +

{{ site.data.ui-text[site.locale].date_label | default: "Updated:" }}

+{% endif %} diff --git a/_includes/page__hero.html b/_includes/page__hero.html index 93e9155fb..dd1c26fbf 100644 --- a/_includes/page__hero.html +++ b/_includes/page__hero.html @@ -1,25 +1,13 @@ -{% if page.header.image contains "://" %} - {% capture img_path %}{{ page.header.image }}{% endcapture %} -{% else %} - {% capture img_path %}{{ page.header.image | absolute_url }}{% endcapture %} -{% endif %} +{% capture overlay_img_path %}{{ page.header.overlay_image | relative_url }}{% endcapture %} -{% if page.header.cta_url contains "://" %} - {% capture cta_path %}{{ page.header.cta_url }}{% endcapture %} -{% else %} - {% capture cta_path %}{{ page.header.cta_url | absolute_url }}{% endcapture %} -{% endif %} - -{% if page.header.overlay_image contains "://" %} - {% capture overlay_img_path %}{{ page.header.overlay_image }}{% endcapture %} -{% elsif page.header.overlay_image %} - {% capture overlay_img_path %}{{ page.header.overlay_image | absolute_url }}{% endcapture %} -{% endif %} - -{% if page.header.overlay_filter contains "rgba" %} +{% if page.header.overlay_filter contains "gradient" %} {% capture overlay_filter %}{{ page.header.overlay_filter }}{% endcapture %} +{% elsif page.header.overlay_filter contains "rgba" %} + {% capture overlay_filter %}{{ page.header.overlay_filter }}{% endcapture %} + {% capture overlay_filter %}linear-gradient({{ overlay_filter }}, {{ overlay_filter }}){% endcapture %} {% elsif page.header.overlay_filter %} {% capture overlay_filter %}rgba(0, 0, 0, {{ page.header.overlay_filter }}){% endcapture %} + {% capture overlay_filter %}linear-gradient({{ overlay_filter }}, {{ overlay_filter }}){% endcapture %} {% endif %} {% if page.header.image_description %} @@ -31,29 +19,35 @@ {% assign image_description = image_description | markdownify | strip_html | strip_newlines | escape_once %}
{% if page.header.overlay_color or page.header.overlay_image %}
-

+

{% if paginator and site.paginate_show_page_num %} {{ site.title }}{% unless paginator.page == 1 %} {{ site.data.ui-text[site.locale].page | default: "Page" }} {{ paginator.page }}{% endunless %} {% else %} {{ page.title | default: site.title | markdownify | remove: "

" | remove: "

" }} {% endif %}

- {% if page.excerpt %} + {% if page.tagline %} +

{{ page.tagline | markdownify | remove: "

" | remove: "

" }}

+ {% elsif page.header.show_overlay_excerpt != false and page.excerpt %}

{{ page.excerpt | markdownify | remove: "

" | remove: "

" }}

{% endif %} - {% if site.read_time and page.read_time %} -

{% include read-time.html %}

- {% endif %} + {% include page__meta.html %} {% if page.header.cta_url %} -

{{ page.header.cta_label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }}

+

{{ page.header.cta_label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }}

+ {% endif %} + {% if page.header.actions %} +

+ {% for action in page.header.actions %} + {{ action.label | default: site.data.ui-text[site.locale].more_label | default: "Learn More" }} + {% endfor %} {% endif %}

{% else %} - {{ image_description }} + {{ image_description }} {% endif %} {% if page.header.caption %} {{ page.header.caption | markdownify | remove: "

" | remove: "

" }}
diff --git a/_includes/page__hero_video.html b/_includes/page__hero_video.html index 8586a95a2..a313a23d4 100644 --- a/_includes/page__hero_video.html +++ b/_includes/page__hero_video.html @@ -1,4 +1,2 @@ -{% capture video_id %}{{ page.header.video.id }}{% endcapture %} -{% capture video_provider %}{{ page.header.video.provider }}{% endcapture %} - -{% include video id=video_id provider=video_provider %} +{% assign video = page.header.video %} +{% include video id=video.id provider=video.provider danmaku=video.danmaku %} diff --git a/_includes/page__meta.html b/_includes/page__meta.html new file mode 100644 index 000000000..3d228c921 --- /dev/null +++ b/_includes/page__meta.html @@ -0,0 +1,31 @@ +{% assign document = post | default: page %} +{% if document.read_time or document.show_date %} +

+ {% if document.show_date and document.date %} + {% assign date = document.date %} + + + {% assign date_format = site.date_format | default: "%B %-d, %Y" %} + + + {% endif %} + + {% if document.read_time and document.show_date %}{% endif %} + + {% if document.read_time %} + {% assign words_per_minute = document.words_per_minute | default: site.words_per_minute | default: 200 %} + {% assign words = document.content | strip_html | number_of_words %} + + + + {% if words < words_per_minute %} + {{ site.data.ui-text[site.locale].less_than | default: "less than" }} 1 {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} + {% elsif words == words_per_minute %} + 1 {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} + {% else %} + {{ words | divided_by: words_per_minute }} {{ site.data.ui-text[site.locale].minute_read | default: "minute read" }} + {% endif %} + + {% endif %} +

+{% endif %} diff --git a/_includes/page__taxonomy.html b/_includes/page__taxonomy.html index f10b2026a..75c76c81d 100644 --- a/_includes/page__taxonomy.html +++ b/_includes/page__taxonomy.html @@ -4,4 +4,4 @@ {% if site.category_archive.type and page.categories[0] %} {% include category-list.html %} -{% endif %} +{% endif %} \ No newline at end of file diff --git a/_includes/paginator.html b/_includes/paginator.html index cf49ae8a2..bffa07946 100644 --- a/_includes/paginator.html +++ b/_includes/paginator.html @@ -1,13 +1,13 @@ {% if paginator.total_pages > 1 %}