From a428f9d84d7aa4042d3764c70907050e0ed82617 Mon Sep 17 00:00:00 2001 From: Robert Kaussow Date: Sun, 31 May 2020 18:20:39 +0200 Subject: [PATCH] configure npm --- .drone.yml | 23 +++++++++++++++++++---- .npmrc | 1 + exampleSite/static/example.html | 13 ------------- exampleSite/static/table.md | 5 ----- layouts/_default/baseof.html | 4 ++-- layouts/posts/list.html | 9 ++------- layouts/shortcodes/expand.html | 17 ++++++++--------- src/sass/_base.scss | 2 +- src/sass/_markdown.scss | 2 +- src/sass/_shortcodes.scss | 4 ++++ 10 files changed, 38 insertions(+), 42 deletions(-) create mode 100644 .npmrc delete mode 100644 exampleSite/static/example.html delete mode 100644 exampleSite/static/table.md diff --git a/.drone.yml b/.drone.yml index a9d9cf6..64cfaeb 100644 --- a/.drone.yml +++ b/.drone.yml @@ -10,9 +10,11 @@ steps: - name: assets image: node commands: - - npm install -g gulp -s - - npm install -s + - npm install -g gulp + - npm install - gulp default + environment: + FORCE_COLOR: true - name: test image: klakegg/hugo:0.69.0-ext-alpine @@ -20,6 +22,19 @@ steps: - cd exampleSite/ - mkdir themes/ && ln -s ../../. themes/hugo-geekdoc && hugo-official +- name: spellcheck + image: node:lts-alpine + commands: + - npm install -g spellchecker-cli + - spellchecker --files 'exampleSite/content/**/*.md' 'README.md' -d .dictionary -p spell indefinite-article syntax-urls --no-suggestions + environment: + FORCE_COLOR: true + +- name: html-validation + image: validator/validator + commands: + - vnu --skip-non-html --also-check-css --errors-only exampleSite/public + - name: build image: alpine commands: @@ -71,7 +86,7 @@ steps: - mkdir -p exampleSite/themes/hugo-geekdoc/ - curl -L https://github.com/xoxys/hugo-geekdoc/releases/latest/download/hugo-geekdoc.tar.gz | tar -xz -C exampleSite/themes/hugo-geekdoc/ --strip-components=1 -- name: test +- name: build image: klakegg/hugo:0.69.0-ext-alpine commands: - cd exampleSite/ && hugo-official @@ -138,6 +153,6 @@ depends_on: --- kind: signature -hmac: c78faf65f2d038c8daa5b56c592a1fa6264b40633cd2375d61257a3027897c3c +hmac: 708f32a4284b33fb9606b8304637d426cdb38260a6123ca23b4a387ad2bf6654 ... diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000..a64a8e6 --- /dev/null +++ b/.npmrc @@ -0,0 +1 @@ +loglevel = error diff --git a/exampleSite/static/example.html b/exampleSite/static/example.html deleted file mode 100644 index a59b90a..0000000 --- a/exampleSite/static/example.html +++ /dev/null @@ -1,13 +0,0 @@ - - - - -

This is heading 1

-

This is heading 2

-

This is heading 3

-

This is heading 4

-
This is heading 5
-
This is heading 6
- - - diff --git a/exampleSite/static/table.md b/exampleSite/static/table.md deleted file mode 100644 index 4bf79a3..0000000 --- a/exampleSite/static/table.md +++ /dev/null @@ -1,5 +0,0 @@ -#### Test Table - -| Head 1 | Head 2 | Head 3 | -|---|---|---| -| 1 | 2 | 3 | \ No newline at end of file diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index cecbbdb..5aa6934 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -25,7 +25,7 @@ {{ partial "site-footer" . }} - -{{ partial "foot" . }} + {{ partial "foot" . }} + diff --git a/layouts/posts/list.html b/layouts/posts/list.html index 8465862..f197591 100644 --- a/layouts/posts/list.html +++ b/layouts/posts/list.html @@ -1,7 +1,5 @@ {{ define "main" }} {{ $dateFormat := default "January 2, 2006" .Site.Params.GeekdocDateFormat }} - {{ $paginator := .Paginate (where .Pages "Params.hidden" "ne" true) }} - {{ range sort .Paginator.Pages }}
@@ -12,17 +10,14 @@
{{ .Date.Format $dateFormat }}
-
+
{{ .Summary }} {{ if .Truncated }} Read more {{ end }} -
+
{{ end }} - - - {{ template "_internal/pagination.html" . }} {{ end }} diff --git a/layouts/shortcodes/expand.html b/layouts/shortcodes/expand.html index f3b67c9..c2540bc 100644 --- a/layouts/shortcodes/expand.html +++ b/layouts/shortcodes/expand.html @@ -1,12 +1,11 @@ +{{ $id := substr (sha1 .Inner) 0 8 }}
-
diff --git a/src/sass/_base.scss b/src/sass/_base.scss index f2d327a..8144489 100644 --- a/src/sass/_base.scss +++ b/src/sass/_base.scss @@ -461,7 +461,7 @@ img { .markdown { transition: 0.2s ease-in-out; transition-property: transform, margin-left, opacity; - will-change: transform!important, margin-left !important; + will-change: transform, margin-left; } @media screen and (max-width: $sm-breakpoint) { diff --git a/src/sass/_markdown.scss b/src/sass/_markdown.scss index 640bbd5..8b56468 100644 --- a/src/sass/_markdown.scss +++ b/src/sass/_markdown.scss @@ -6,7 +6,7 @@ } &--nested { - > :first-child { + :first-child { margin-top: 0; } > :last-child { diff --git a/src/sass/_shortcodes.scss b/src/sass/_shortcodes.scss index 1d7b821..908e003 100644 --- a/src/sass/_shortcodes.scss +++ b/src/sass/_shortcodes.scss @@ -22,6 +22,10 @@ &__control:checked + &__content { display: block; } + + .gdoc-page__anchor { + display: none; + } } // {{< tabs >}}