From ce41e8bc55d6d282dce31db2ae4e8a4896984b1f Mon Sep 17 00:00:00 2001 From: Starbeamrainbowlabs Date: Mon, 14 Jun 2021 02:25:45 +0100 Subject: [PATCH] Add getting started section Todo: Completely revise the changelog / reference to use data & dynamicness, because we want to group headings into
elements. That way it makes it *much* easier to implement a search feature, and also style it nicely too --- .docs/.eleventy.js | 7 ++++--- .docs/_includes/theme.njk | 2 +- .docs/css/theme.css | 27 ++++++++++++++++++++------- .docs/images/github.svg | 6 ++++++ .docs/index.html | 19 +++++++++++++++++-- 5 files changed, 48 insertions(+), 13 deletions(-) create mode 100644 .docs/images/github.svg diff --git a/.docs/.eleventy.js b/.docs/.eleventy.js index f15ce2c..2d52aa7 100644 --- a/.docs/.eleventy.js +++ b/.docs/.eleventy.js @@ -46,7 +46,7 @@ async function shortcode_image_url(src) { return data.url; } -async function shortcode_image_urlpng(src) { +async function shortcode_image_urlpass(src) { let target_dir = `./_site/img`; if(!fs.existsSync(target_dir)) await fs.promises.mkdir(target_dir, { recursive: true }); @@ -74,7 +74,8 @@ module.exports = function(eleventyConfig) { // eleventyConfig.addPassthroughCopy("css"); eleventyConfig.addShortcode("image", shortcode_image); eleventyConfig.addJavaScriptFunction("image", shortcode_image); - eleventyConfig.addShortcode("image_url", shortcode_image_url); - eleventyConfig.addNunjucksAsyncShortcode("image_urlpng", shortcode_image_urlpng); + // eleventyConfig.addNunjucksAsyncShortcode("image_url", shortcode_image_url); + eleventyConfig.addAsyncShortcode("image_url", shortcode_image_url); + eleventyConfig.addNunjucksAsyncShortcode("image_urlpass", shortcode_image_urlpass); eleventyConfig.addPairedShortcode("gallerybox", shortcode_gallerybox); } diff --git a/.docs/_includes/theme.njk b/.docs/_includes/theme.njk index 2336b61..c2a37dc 100644 --- a/.docs/_includes/theme.njk +++ b/.docs/_includes/theme.njk @@ -21,7 +21,7 @@ {{ navitem.data.title }} {% endfor %} -
  • GitHub
  • +
  • GitHub
  • {{ content | safe }} diff --git a/.docs/css/theme.css b/.docs/css/theme.css index e1fa748..b8f65be 100644 --- a/.docs/css/theme.css +++ b/.docs/css/theme.css @@ -43,14 +43,14 @@ } */ /* rem is relative to the html element, and em is relative to the current element. */ -html { font-size: 100%; } +html { font-size: 100%; scroll-behavior: smooth; } body { margin: 0; font-family: sans-serif; /* Serif is awful :( */ - background: url('{% image_urlpng "images/clouds.png" %}') center / cover fixed, + background: url('{% image_urlpass "images/clouds.png" %}') center / cover fixed, var(--bg-main); /* Don't forget to update the @page one too for paged media */ color: var(--text-main); } @@ -96,16 +96,18 @@ nav ul { display: flex; justify-content: space-evenly; } -nav ul li { - background: var(--bg-transcluscent-slight); -} nav a { + background: var(--bg-transcluscent-slight); display: inline-block; padding: 1.2em 3em; text-decoration: none; font-weight: bold; color: var(--text-main); } +nav a.image { + padding: 0.75em 1em 0.5em 1em; +} +nav img { max-height: 2em; } /* A small tweak to things more responsive */ @@ -227,16 +229,27 @@ footer { flex-direction: column; justify-content: flex-start; } -.features-item.wide > :last-child { +/* .features-item.wide > :last-child { flex: 1; display: flex; justify-content: flex-end; flex-direction: column; align-items: center; +} */ + +.panel-generic { + background: var(--bg-transcluscent); + margin: 2em; + padding: 1em; + box-shadow: 0.25em 0.25em 0.5em var(--shadow); } -.cssbox-gallery { +.bigbutton-list { + list-style-type: none; + margin: 0; + padding: 1em 0; display: flex; + justify-content: space-around; } .bigbutton { diff --git a/.docs/images/github.svg b/.docs/images/github.svg new file mode 100644 index 0000000..58721c7 --- /dev/null +++ b/.docs/images/github.svg @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/.docs/index.html b/.docs/index.html index ff74ab4..446379c 100644 --- a/.docs/index.html +++ b/.docs/index.html @@ -9,12 +9,13 @@ date: 2000-01-01

    WorldEditAdditions

    WorldEditAdditions on ContentDB + WorldEditAdditions on the Minetest Forums Latest release on GitHub View the changelog

    Extra tools and commands to extend WorldEdit for Minetest

    If you can dream of it, it probably belongs here!

    -

    Get Started

    +

    Get Started

    @@ -70,7 +71,7 @@ date: 2000-01-01
    -

    Download

    +

    Download

    ContentDB

    @@ -91,3 +92,17 @@ git clone https://github.com/sbrl/Minetest-WorldEditAdditions.git;
    + +
    +

    Getting Started

    + +
    +

    If you're familiar with WorldEdit already, then WorldEditAdditions will follow the existing expectations you're used to. For players new to WorldEdit / WorldEditAdditions, we have a tutorial that will get you up to speed in no time!

    + + +
    +