Skip to content
This repository was archived by the owner on Apr 11, 2020. It is now read-only.

Improved theme meta and formatting. Implemented GA-Support, Additional Links & much more #2

Open
wants to merge 17 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ Create a new Hugo site with:
hugo new site
```

With your new site created, [download the presskit-static ZIP](https://github.com/RedpointGames/presskit-static/archive/master.zip) and place it in the `themes/` directory such that `themes/presskit-static/theme.toml` exists.
With your new site created, [download the presskit-static ZIP](https://github.com/RedpointGames/presskit-static/archive/master.zip) and place it in the `themes/` directory such that `themes/presskit-static/theme.yaml` exists.

Add the line `theme = "presskit-static"` to your `config.toml` file.
Add the line `theme = "presskit-static"` to your `config.toml` or `theme: "presskit-static"` to your `config.yaml` file.

You can run Hugo as a server locally while you're writing content to preview it by running `hugo server -t presskit-static` in the directory where your project is located.

Expand Down
1 change: 1 addition & 0 deletions layouts/404.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
<title>Not Found!</title>
<link href="https://cdnjs.cloudflare.com/ajax/libs/uikit/1.2.0/css/uikit.gradient.min.css" rel="stylesheet" type="text/css">
<link href="{{ $.Site.BaseURL }}/asset/style.css" rel="stylesheet" type="text/css">
{{ template "_internal/google_analytics_async.html" . }}
</head>

<body>
Expand Down
4 changes: 2 additions & 2 deletions layouts/_default/baseof.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{ if (eq $.Page.Type "company") }}
{{ partial "company.html" . }}
{{ partial "company.html" . }}
{{ else }}
{{ partial "game.html" . }}
{{ partial "game.html" . }}
{{ end }}
4 changes: 2 additions & 2 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{ if (eq $.Page.Type "company") }}
{{ partial "../company/single.html" . }}
{{ partial "../company/single.html" . }}
{{ else }}
{{ partial "../game/single.html" . }}
{{ partial "../game/single.html" . }}
{{ end }}
13 changes: 13 additions & 0 deletions layouts/partials/additionals.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{{ range $.Params.additionals }}
<p>
<strong>{{ .title }}</strong><br/>
{{ .description }} <br/>
{{ if (ne .link nil) }}
{{ if (ne .linkText nil) }}
<a href="{{ .link }}">{{ .linkText }}</a>
{{ else }}
<a href="{{ .link }}">{{ .link }}</a>
{{ end }}
{{ end }}
</p>
{{ end }}
239 changes: 122 additions & 117 deletions layouts/partials/bootstrap/company.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,146 +4,151 @@
{{ $urlImages := printf "%s/images" $urlStatic }}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" content="{{ .Description }}">
<meta name="author" content="{{ $.Title }}">
<title>{{ $.Title }}</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.css">
<link href="{{ trim $.Site.BaseURL "/" }}/asset/style-bootstrap.css" rel="stylesheet" type="text/css">
{{ $styles := (readDir $pathStyles) }}
{{ range $styles }}
{{ $ext := (substr .Name (sub (len .Name) 4)) }}
{{ if (eq $ext ".css") }}
<link href="{{ printf "%s/%s" $urlStatic .Name }}" rel="stylesheet" type="text/css">
{{ end }}

<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" content="{{ .Description }}">
<meta name="author" content="{{ $.Title }}">
<title>{{ $.Title }}</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.css">
<link href="{{ trim $.Site.BaseURL "/" }}/asset/style-bootstrap.css" rel="stylesheet" type="text/css">
{{ $styles := (readDir $pathStyles) }}
{{ range $styles }}
{{ $ext := (substr .Name (sub (len .Name) 4)) }}
{{ if (eq $ext ".css") }}
<link href="{{ printf "%s/%s" $urlStatic .Name }}" rel="stylesheet" type="text/css">
{{ end }}
</head>
<body>
<div class="container">
<div class="row">
<div class="col-12 col-sm-3" id="navigation">
<h1 class="nav-up">{{ $.Title }}</h1>
<a class="nav-up" href="{{ $.Params.website.link }}" target="_self">{{ $.Params.website.name }}</a></strong>
<ul class="nav flex-column mt-4">
<li class="nav-item"><a class="nav-link" href="#factsheet">Factsheet</a></li>
<li class="nav-item"><a class="nav-link" href="#description">Description</a></li>
<li class="nav-item"><a class="nav-link" href="#history">History</a></li>
<li class="nav-item"><a class="nav-link" href="#projects">Projects</a></li>
<li class="nav-item"><a class="nav-link" href="#trailers">Videos</a></li>
<li class="nav-item"><a class="nav-link" href="#images">Images</a></li>
<li class="nav-item"><a class="nav-link" href="#logo">Logo &amp; Icon</a></li>
<li class="nav-item"><a class="nav-link" href="#credits">Team</a></li>
<li class="nav-item"><a class="nav-link" href="#contact">Contact</a></li>
</ul>
</div>
<div class="col-12 col-sm-9 p-0" id="main">
{{ $header := (readDir $pathImages) }}
{{ if (where $header "Name" "header.png") }}
<img src="{{ $urlImages }}/header.png" class="img-fluid" />
{{ end }}
<div class="col-12">
<div class="row mt-0">
<div class="col-12 col-md-5 col-lg-4 col-xl-3">
<h2 id="factsheet">Factsheet</h2>
<p>
<strong>Developer:</strong><br/>
<a href="{{ $.Params.website.link }}">{{ $.Params.title }}</a><br/>
Based in {{ $.Params.basedin }}
</p>
<p>
<strong>Founding date:</strong><br/>
{{ $.Params.foundingdate }}
</p>
{{ end }}
{{ template "_internal/google_analytics_async.html" . }}
</head>

<body>
<div class="container">
<div class="row">
<div class="col-12 col-sm-3" id="navigation">
<h1 class="nav-up">{{ $.Title }}</h1>
<a class="nav-up" href="{{ $.Params.website.link }}" target="_self">{{ $.Params.website.name }}</a></strong>
<ul class="nav flex-column mt-4">
<li class="nav-item"><a class="nav-link" href="#factsheet">Factsheet</a></li>
<li class="nav-item"><a class="nav-link" href="#description">Description</a></li>
<li class="nav-item"><a class="nav-link" href="#history">History</a></li>
<li class="nav-item"><a class="nav-link" href="#projects">Projects</a></li>
<li class="nav-item"><a class="nav-link" href="#trailers">Videos</a></li>
<li class="nav-item"><a class="nav-link" href="#images">Images</a></li>
<li class="nav-item"><a class="nav-link" href="#logo">Logo &amp; Icon</a></li>
<li class="nav-item"><a class="nav-link" href="#credits">Team</a></li>
<li class="nav-item"><a class="nav-link" href="#contact">Contact</a></li>
</ul>
</div>
<div class="col-12 col-sm-9 p-0" id="main">
{{ $header := (readDir $pathImages) }}
{{ if (where $header "Name" "header.png") }}
<img src="{{ $urlImages }}/header.png" class="img-fluid" />
{{ end }}
<div class="col-12">
<div class="row mt-0">
<div class="col-12 col-md-5 col-lg-4 col-xl-3">
<h2 id="factsheet">Factsheet</h2>
<p>
<strong>Developer:</strong><br />
<a href="{{ $.Params.website.link }}">{{ $.Params.title }}</a><br />
Based in {{ $.Params.basedin }}
</p>
<p>
<strong>Founding date:</strong><br />
{{ $.Params.foundingdate }}
</p>
<p>
<strong>Website:</strong><br />
<a href="{{ $.Params.website.link }}">{{ $.Params.website.name }}</a>
</p>
<p>
<strong>Press / Business contact:</strong><br />
<a href="mailto:{{ $.Params.pressContact }}">{{ $.Params.pressContact }}</a>
</p>
{{ if (gt $.Params.social 0 ) }}
<p>
<strong>Website:</strong><br/>
<a href="{{ $.Params.website.link }}">{{ $.Params.website.name }}</a>
<strong>Social:</strong><br />
{{ range $.Params.social }}
<a href="{{ .link }}">{{ .name }}</a><br />
{{ end }}
</p>
{{ end }}
{{ if (gt $.Params.releases 0 ) }}
<p>
<strong>Press / Business contact:</strong><br/>
<a href="mailto:{{ $.Params.pressContact }}">{{ $.Params.pressContact }}</a>
<strong>Releases:</strong><br />
{{ range $.Params.releases }}
<a href="{{ relref $.Page . }}">{{ ($.Site.GetPage "page" .).Title }}</a><br />
{{ end }}
</p>
{{ if (gt $.Params.social 0 ) }}
<p>
<strong>Social:</strong><br/>
{{ range $.Params.social }}
<a href="{{ .link }}">{{ .name }}</a><br/>
{{ end }}
</p>
{{ end }}
{{ if (gt $.Params.releases 0 ) }}
<p>
<strong>Releases:</strong><br />
{{ range $.Params.releases }}
<a href="{{ relref $.Page . }}">{{ ($.Site.GetPage "page" .).Title }}</a><br />
{{ end }}
</p>
{{ end }}
</div>
<div class="col-12 col-md-7 col-lg-8 col-xl-9">
{{ .Content }}
{{ if (gt $.Params.releases 0 ) }}
{{ end }}
</div>
<div class="col-12 col-md-7 col-lg-8 col-xl-9">
{{ .Content }}
{{ if (gt $.Params.releases 0 ) }}
<h2 id="projects">Projects</h2>
<ul>
<ul>
{{ range $.Params.releases }}
<li><a href="{{ relref $.Page . }}">{{ ($.Site.GetPage "page" .).Title }}</a></li>
{{ end }}
</ul>
{{ end }}
</div>
</ul>
{{ end }}
</div>
</div>

<hr>
<hr>

<h2 id="trailers">Videos</h2>
{{ partial "videos.html" . }}
<hr>
<h2 id="trailers">Videos</h2>
{{ partial "videos.html" . }}
<hr>

<h2 id="images">Images</h2>
{{ partial "images.html" . }}
<hr>
<h2 id="images">Images</h2>
{{ partial "images.html" . }}
<hr>

<h2 id="logo">Logo &amp; Icon</h2>
{{ partial "logos.html" . }}
<hr>
<div class="row">
<div class="col-12 col-sm-6">
<h2 id="credits">Members</h2>
{{ range $.Params.team }}
<h2 id="logo">Logo &amp; Icon</h2>
{{ partial "logos.html" . }}
<hr>

<div class="row">
<div class="col-12 col-sm-6">
<h2 id="credits">Members</h2>
{{ range $.Params.team }}
<p>
<strong>{{ .person }}{{ if .mail }} (<a href="mailto:{{ .mail }}">Email</a>){{ end }}</strong><br/>
<strong>{{ .person }}{{ if .mail }} (<a href="mailto:{{ .mail }}">Email</a>){{ end }}</strong><br />
{{ .role }}
</p>
{{ end }}
</div>
<div class="col-12 col-sm-6">
<h2 id="contact">Contact</h2>
{{ partial "contacts.html" . }}
</div>
{{ end }}
</div>
<div class="col-12 col-sm-6">
<h2 id="contact">Contact</h2>
{{ partial "contacts.html" . }}
</div>
</div>

<hr>
<hr>

<p>{{ partial "footer.html" . }}</p>
</div>
<p>{{ partial "footer.html" . }}</p>
</div>
</div>
</div>

<script type="text/javascript" src="http://cdnjs.cloudflare.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript" src="http://cdnjs.cloudflare.com/ajax/libs/jquery.imagesloaded/3.0.4/jquery.imagesloaded.js"></script>
<script type="text/javascript" src="http://cdnjs.cloudflare.com/ajax/libs/masonry/3.1.2/masonry.pkgd.min.js"></script>
<script type="text/javascript">
$( document ).ready(function() {
var container = $('.images');
</div>

container.imagesLoaded( function() {
container.masonry({
itemSelector: '.image',
});
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/jquery.imagesloaded/3.0.4/jquery.imagesloaded.js"></script>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/masonry/3.1.2/masonry.pkgd.min.js"></script>
<script type="text/javascript">
$(document).ready(function () {
var container = $('.images');

container.imagesLoaded(function () {
container.masonry({
itemSelector: '.image',
});
});
</script> </body>
</html>
});
</script>
</body>

</html>
Loading