🎉 Hello World

This commit is contained in:
2020-03-03 18:56:59 +01:00
commit 94877013bd
55 changed files with 1479 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
<!--
for user-side override
-->

View File

@@ -0,0 +1,11 @@
{{- if and (not (eq .Params.single true)) (or .PrevInSection .NextInSection) -}}
<hr>
<section class="article navigation">
{{- with .NextInSection -}}
<p><a class="link" href="{{- .RelPermalink -}}"><span class="li">&larr;</span>{{- .Title | safeHTML -}}</a></p>
{{- end -}}
{{- with .PrevInSection -}}
<p><a class="link" href="{{- .RelPermalink -}}"><span class="li">&rarr;</span>{{- .Title | safeHTML -}}</a></p>
{{- end -}}
</section>
{{- end -}}

View File

@@ -0,0 +1,7 @@
{{- if gt (len site.DisqusShortname) 0 -}}
{{- if or (eq .Params.comments true) (and (ne .Params.comments false) (eq site.Params.comments.enable true)) -}}
<section class="article discussion">
{{- template "_internal/disqus.html" . -}}
</section>
{{- end -}}
{{- end -}}

View File

@@ -0,0 +1,30 @@
<!--<p><img src="img/user.png" width="50px" height="50px">
<ba>Stanley Stinson</ba>
</p>-->
{{- $dateFormat := site.Params.dateFormat -}}
{{- if not $dateFormat -}}{{- $dateFormat = "2006-01-02" -}}{{- end -}}
{{- $lastmodFormat := "" -}}
{{- $lastmod := .Lastmod -}}
{{- if $lastmod -}}
{{- $lastmodFormat = $lastmod.Format $dateFormat -}}
{{- end -}}
{{- if .Date -}}
{{- $dateFormat := .Date.Format $dateFormat -}}
<p class="article date">
<bd>{{- $dateFormat -}}</bd>
{{- if and ($lastmod.After .Date) (ne $lastmodFormat $dateFormat) -}}
<span class="lastmod">{{- printf (T "edited") $lastmodFormat -}}</span>
{{- end -}}
{{- if or (eq .Params.readingTime true) (and (not (eq .Params.readingTime false)) (eq site.Params.readingTime true)) -}}
<span class="reading-time">{{ T "readingTime" .ReadingTime }}</span>
{{- end -}}
{{- if .IsTranslated -}}
<span class="langs">
{{- range .Translations -}}
<span class="lang"><a href="{{- .RelPermalink -}}">{{- .Lang -}}</a></span>
{{- end -}}
</span>
{{- end -}}
</p>
{{- end -}}

View File

@@ -0,0 +1,16 @@
{{- if or .Params.categories .Params.tags -}}
<p>
<bt>CATÉGORIES :&nbsp;
{{- range .Params.categories -}}
{{- $url := print "/categories/" (. | urlize) "/" -}}
<a class="category" href={{- $url | relLangURL -}}>{{- . -}}</a> -
{{- end -}}
</bt>
<bt>TAGS :&nbsp;
{{- range .Params.tags -}}
{{- $url := print "/tags/" (. | urlize) "/" -}}
<a class="tag" href={{- $url | relLangURL -}}>{{- . -}}</a>
{{- end -}}
</bt>
</p>
{{- end -}}

View File

@@ -0,0 +1,12 @@
{{- $license := "" -}}
{{- if and (isset .Params "license") (ne .Params.license "") -}}
{{- $license = .Params.license -}}
{{- else if and (isset site.Params "license") (ne site.Params.license "") -}}
{{- $license = site.Params.license -}}
{{- end -}}
{{- if ne $license "" -}}
<section class="article license">
LICENSE :&nbsp;{{- $license | safeHTML -}}
</section>
{{- end -}}

View File

@@ -0,0 +1,13 @@
{{- $copyright := . -}}
<div class="footer-wrap">
<p class="copyright">{{- $copyright -}}</p>
<div class="credits">
<!--
You are NOT allowed to delete the credit link to TemplateMag with free version.
You can delete the credit link only if you bought the pro version.
Buy the pro version with working PHP/AJAX contact form: https://templatemag.com/stanley-bootstrap-freelancer-template/
Licensing information: https://templatemag.com/license/
-->
Created with Stanley template by <a href="https://templatemag.com/" rel="nofollow">TemplateMag</a>
</div>
</div>

View File

@@ -0,0 +1,16 @@
{{- $css := "" -}}
{{- range site.Params.assets.css -}}
{{- $customCSS := resources.Get . -}}
{{- if $customCSS -}}
{{- $scss := false -}}
{{- $filePath := . | lower -}}
{{- if or (strings.HasSuffix $filePath ".scss") (strings.HasSuffix $filePath ".sass") -}}{{- $scss = true -}}{{- end -}}
{{- if $scss -}}{{- $customCSS = $customCSS | resources.ToCSS -}}{{- end -}}
{{- if eq $css "" -}}
{{- $css = $customCSS -}}
{{- else -}}
{{- $css = slice $css $customCSS | resources.Concat (printf "%s.tmp_custom.css" .) -}}
{{- end -}}
{{- end -}}
{{- end -}}
{{- return $css -}}

View File

@@ -0,0 +1,19 @@
{{- $js := "" -}}
{{- range site.Params.assets.js -}}
{{- $customJS := resources.Get . -}}
{{- if $customJS -}}
{{- if eq $js "" -}}
{{- $js = $customJS -}}
{{- else -}}
{{- $js = slice $js $customJS | resources.Concat (printf "%s.tmp_custom.js" .) -}}
{{- end -}}
{{- end -}}
{{- end -}}
{{- if ne $js "" -}}
{{- $coreJS := slice $js ("" | resources.FromString "js/_core.js") | resources.Concat "js/core.js" -}}
{{- $coreJS = $coreJS | resources.Minify | resources.Fingerprint "sha384" -}}
<script src="{{- $coreJS.RelPermalink -}}" integrity="{{- $coreJS.Data.Integrity -}}"></script>
{{- end -}}
{{- partial "js.html" . -}}

View File

@@ -0,0 +1,40 @@
<div id="footer">
<div class="container">
<div class="row">
<div class="col-lg-4">
<h4>My Bunker</h4>
<p>
Some Address 987,<br/> +34 9054 5455, <br/> Madrid, Spain.
</p>
</div>
<!-- /col-lg-4 -->
<div class="col-lg-4">
<h4>My Links</h4>
<p>
<a href="#">Dribbble</a><br/>
<a href="#">Twitter</a><br/>
<a href="#">Facebook</a>
</p>
</div>
<!-- /col-lg-4 -->
<div class="col-lg-4">
<h4>À propos de pow pow pw</h4>
<p>Un résumé à écrire ici</p>
</div>
<!-- /col-lg-4 -->
</div>
</div>
</div>
<div id="copyrights">
<div class="container">
{{- $copyright := site.Copyright -}}
{{- if not $copyright -}}
{{- $copyright = site.Title | safeHTML -}}
{{- end -}}
{{- partial "copyright.html" ($copyright | safeHTML) -}}
</div>
</div>
{{- partial "syntax.html" . -}}

View File

@@ -0,0 +1,3 @@
<!--
for user-side override
-->

View File

@@ -0,0 +1,22 @@
<meta charset="utf-8">
{{- hugo.Generator -}}
<meta content="width=device-width, initial-scale=1.0" name="viewport">
<meta name="color-scheme" content="light dark">
<meta name="supported-color-schemes" content="light dark">
{{- define "title" -}}
{{- $title := .Title -}}
{{- if and (ne $title "") (ne $title site.Title) -}}
<title>{{- $title | safeHTML -}} &nbsp;&ndash;&nbsp; {{- site.Title | safeHTML -}}</title>
{{- else -}}
{{- $slogan := site.Params.slogan -}}
<title>{{- site.Title | safeHTML -}}{{- if and (isset site.Params "slogan") (ne $slogan "") -}} &nbsp;&ndash;&nbsp;
{{- $slogan | safeHTML -}}{{- end -}}</title>
{{- end -}}
{{- end -}}
{{- block "title" . -}}{{- end -}}
{{- partial "style.html" . -}}
{{- partial "rss-feed.html" . -}}
{{- partial "head-extra.html" . -}}

View File

@@ -0,0 +1,31 @@
{{- $nav := site.Params.nav -}}
{{- if or $nav.showCategories $nav.showTags $nav.custom -}}
<div class="navbar navbar-inverse navbar-static-top">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="{{- .Site.BaseURL -}}">{{- .Site.Title -}}</a>
</div>
<div class="navbar-collapse collapse">
<ul class="nav navbar-nav navbar-right">
{{- if $nav.showCategories -}}
<li><a class="nav item" href="{{- `/categories/` | relLangURL -}}">{{- T "Categories" -}}</a></li>
{{- end -}}
{{- if $nav.showTags -}}
<li><a class="nav item" href="{{- `/tags/` | relLangURL -}}">{{- T "Tags" -}}</a></li>
{{- end -}}
{{- range $nav.custom -}}
{{- $url := .url | safeURL -}}
{{- if strings.HasPrefix $url "/" -}}{{- $url = $url | relLangURL -}}{{- end -}}
<li><a class="nav item" href="{{- $url -}}"{{- if strings.HasPrefix $url "http" -}} target="_blank"{{- end -}}>{{- .title -}}</a></li>
{{- end -}}
</ul>
</div>
<!--/.nav-collapse -->
</div>
</div>
{{- end -}}

View File

@@ -0,0 +1,5 @@
{{- if .Content -}}
<article class="article markdown-body">
{{- .Content -}}
</article>
{{- end -}}

View File

@@ -0,0 +1,8 @@
{{- if or .Params.categories .Params.tags -}}
<p class="note labels">
{{- range .Params.tags -}}
{{- $url := print "/tags/" (. | urlize) "/" -}}
<a class="tag" href="{{- $url | relLangURL -}}">{{- . -}}</a>
{{- end -}}
</p>
{{- end -}}

View File

@@ -0,0 +1,40 @@
{{- $paginator := . -}}
{{- if gt $paginator.TotalPages 0 -}}
{{- $dateFormat := site.Params.dateFormat -}}
{{- if not $dateFormat -}}{{- $dateFormat = "2006-01-02" -}}{{- end -}}
{{- range $index, $page := $paginator.Pages -}}
<div id="{{ if eq (mod $index 2) 0}}grey{{ else }}white{{ end }}">
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2">
<!-- <p><img src="img/user.png" width="50px" height="50px">
<ba>Stanley Stinson</ba>
</p>-->
{{- if $page.Date -}}
<bd>{{- $page.Date.Format $dateFormat -}}</bd>
{{- end -}}
<h4>{{- $page.Title | safeHTML -}}</h4>
{{- if $page.Summary -}}<p class="note content">{{- $page.Summary | plainify | safeHTML -}}{{- if $page.Truncated -}}<span class="mldr">&mldr;{{- T "more" -}}</span>{{- end -}}</p>{{- end -}}
{{- $relURL := $page.RelPermalink -}}
{{- $imgs := $page.Params.imgs -}}
{{- with $page.Params.imgs -}}
<span class="note imgs">
{{- $imgCount := len $imgs -}}
{{- range $imgs -}}
{{- $imgurl := lower $page -}}
{{- if and (not (hasPrefix $imgurl "http://")) (not (hasPrefix $imgurl "https://")) -}}
{{- $imgurl = path.Join $relURL $page -}}
{{- end -}}
<img class="img" src="{{- $imgurl -}}" alt />
{{- end -}}
</span>
{{- end -}}
<p><a href="{{- $page.RelPermalink -}}">Continue Reading...</a></p>
{{- partial "note-labels.html" $page -}}
</div>
</div>
</div>
</div>
{{ end }}
{{ end }}

View File

@@ -0,0 +1,34 @@
{{- $paginator := . -}}
{{- if gt $paginator.TotalPages 1 -}}
{{- $pageIndex := $paginator.PageNumber -}}
{{- $totalPages := $paginator.TotalPages -}}
{{- $cols := 5.0 -}}
{{- $rows := math.Ceil (div $totalPages $cols) -}}
{{- $row := math.Ceil (div $pageIndex $cols) -}}
{{- $startPage := sub (mul $row $cols) $cols -}}
{{- $endPage := add $startPage $cols -}}
<div class="pagination">
<ul>
{{- if gt $row 1 -}}
<li><a href="{{- $paginator.Prev.URL -}}" class="previous_page">&laquo;</a></li>
{{- end -}}
{{- range $paginator.Pagers -}}
{{- if and (gt .PageNumber $startPage) (le .PageNumber $endPage) -}}
{{- $active := "" -}}
{{- if eq .PageNumber $paginator.PageNumber -}}
{{- $active = "active" -}}
{{- end -}}
<li><a class="{{- $active -}}" href="{{- .URL -}}">{{- .PageNumber -}}</a></li>
{{- end -}}
{{- end -}}
{{- if lt $row $rows -}}
<li><a href="{{- $paginator.Next.URL -}}" class="next_page">&raquo;</a></li>
{{- end -}}
</ul>
</div>
{{- end -}}

View File

@@ -0,0 +1,3 @@
{{- range .AlternativeOutputFormats -}}
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .RelPermalink $.Site.Title | safeHTML }}
{{- end -}}

View File

@@ -0,0 +1,5 @@
{{- if .Content -}}
<article class="article markdown-body">
{{- .Content -}}
</article>
{{- end -}}

View File

@@ -0,0 +1,6 @@
{{- $bootstrapCSS := resources.Get "css/bootstrap.min.css" -}}
{{- $styleCSS := resources.Get "css/style.css" -}}
{{- $finalCSS := slice $bootstrapCSS $styleCSS | resources.Concat "css/style.min.css" -}}
{{- $finalCSS = $finalCSS | resources.Minify | resources.Fingerprint "sha384" -}}
<link rel="stylesheet" href="{{- $finalCSS.RelPermalink -}}" integrity="{{- $finalCSS.Data.Integrity -}}">

View File

@@ -0,0 +1,21 @@
{{- with site.Params.syntax -}}
{{- $use := "none" -}}
{{- if and (isset . "use") (ne .use "") -}}
{{- $use = .use | lower -}}
{{- end -}}
{{- $syntaxJS := "" -}}
{{- if eq $use "hljs" -}}
{{- $syntaxJS = "js/hljs.js" -}}
{{- else if eq $use "prismjs" -}}
{{- $syntaxJS = "js/prism.js" -}}
{{- end -}}
{{- if ne $syntaxJS "" -}}
{{- $js := resources.Get $syntaxJS | resources.Minify | resources.Fingerprint "sha384" -}}
<script src="{{- $js.RelPermalink -}}" integrity="{{- $js.Data.Integrity -}}"></script>
{{- if eq $use "hljs" -}}
<script>hljs.initHighlightingOnLoad();</script>
{{- end -}}
{{- end -}}
{{- end -}}