configure npm

uci-hugo-doc
Robert Kaussow 2020-05-31 18:20:39 +02:00
parent 701bab896d
commit a428f9d84d
10 changed files with 38 additions and 42 deletions

View File

@ -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
...

1
.npmrc Normal file
View File

@ -0,0 +1 @@
loglevel = error

View File

@ -1,13 +0,0 @@
<!DOCTYPE html>
<html>
<body>
<h1>This is heading 1</h1>
<h2>This is heading 2</h2>
<h3>This is heading 3</h3>
<h4>This is heading 4</h4>
<h5>This is heading 5</h5>
<h6>This is heading 6</h6>
</body>
</html>

View File

@ -1,5 +0,0 @@
#### Test Table
| Head 1 | Head 2 | Head 3 |
|---|---|---|
| 1 | 2 | 3 |

View File

@ -25,7 +25,7 @@
{{ partial "site-footer" . }}
</div>
</body>
{{ partial "foot" . }}
{{ partial "foot" . }}
</body>
</html>

View File

@ -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 }}
<article class="gdoc-markdown gdoc-post">
<header>
@ -12,17 +10,14 @@
<h5>
<strong>{{ .Date.Format $dateFormat }}</strong>
</h5>
<section>
<div>
{{ .Summary }}
{{ if .Truncated }}
<a class="gdoc-post__readmore" title="Read full post" href="{{ .RelPermalink }}">
Read more
</a>
{{ end }}
</section>
</div>
</article>
{{ end }}
<!-- TODO: FIXME -->
{{ template "_internal/pagination.html" . }}
{{ end }}

View File

@ -1,12 +1,11 @@
{{ $id := substr (sha1 .Inner) 0 8 }}
<div class="gdoc-expand">
<label>
<div class="gdoc-expand__head flex justify-between">
<span>{{ default "Expand" (.Get 0) }}</span>
<span>{{ default "↕" (.Get 1) }}</span>
</div>
<input type="checkbox" class="gdoc-expand__control hidden" />
<div class="gdoc-markdown--nested gdoc-expand__content">
{{ .Inner | markdownify }}
</div>
<label class="gdoc-expand__head flex justify-between" for="{{ $id }}-{{ .Ordinal }}">
<span>{{ default "Expand" (.Get 0) }}</span>
<span>{{ default "↕" (.Get 1) }}</span>
</label>
<input id="{{ $id }}-{{ .Ordinal }}" type="checkbox" class="gdoc-expand__control hidden" />
<div class="gdoc-markdown--nested gdoc-expand__content">
{{ .Inner | markdownify }}
</div>
</div>

View File

@ -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) {

View File

@ -6,7 +6,7 @@
}
&--nested {
> :first-child {
:first-child {
margin-top: 0;
}
> :last-child {

View File

@ -22,6 +22,10 @@
&__control:checked + &__content {
display: block;
}
.gdoc-page__anchor {
display: none;
}
}
// {{< tabs >}}