kaschber 0.2.2 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 63b91b1a955fb374d4a7369078b4a0a870acbefbb9536b742971e5ded7776bd3
4
- data.tar.gz: 9c63be8fefb9b4fd129e07a48a084578581c3c937701f2a6680ba3854863de49
3
+ metadata.gz: cd63cb3e1cd989b191cd3395427c0fc9a7f351e38372f9723482540a94f04795
4
+ data.tar.gz: 76c26c0f6baec1af2e269b583b48c60c657c34febef7a7a6a31a4174c01c698a
5
5
  SHA512:
6
- metadata.gz: 7a549469e15f72cdb5ad340dbaa5c8dcec10c2e628d4fc1f239e8f7bbc0fb419d0ffe9bdaa56769ae200635c19e92fc5d8d4d912d4f43b4a8645da6d2bb7fa8d
7
- data.tar.gz: 4d4640dc48a077c639ba380083d59f97b63a8fd722487a0d905c400c35d95bd009da7c02ee7cd75dd37044af24f0a05711f804380cfa0bdbdd091aee490ba6df
6
+ metadata.gz: fc8e9e2ef38b5abbf14cdb1eba96df97cd4b52fe2ea0e83fc1fe38d9ce7e11727772897c6f705f8705f40b70e953a9881b30292a7a5e6f70cc71ed1aa5fc3946
7
+ data.tar.gz: c04f043bb634ee31e9c2cfb7d069e9a0fdb40e4d5f9811a9f5e0797f6782bd773e6c65ed0dc198c7903adcfa58cf43de926da233858af24f5b02981dd379be7d
data/README.md CHANGED
@@ -46,14 +46,14 @@ You can specifiy these customisation options in your `_config.yml` for site-wide
46
46
 
47
47
  | Config | Default | Options |
48
48
  |-------------------------|-------------------|-----------------------------------|
49
- | title_font | Modern sans-serif | Modern sans-serif, Elegant serif |
50
- | body_font | Modern sans-serif | Modern sans-serif, Elegant serif |
49
+ | title_font | System default | Elegant serif |
50
+ | body_font | System default | Modern sans-serif |
51
51
  | header_style | Center aligned | Center aligned, Left, aligned, Hidden |
52
52
  | show_logo_in_navigation | false | True, False |
53
53
  | feed_layout | Classic | Classic, Grid, List |
54
54
  | color_scheme | Auto | Light, Dark, Auto |
55
55
  | post_image_style | Wide | Wide, Full, Small, Hidden |
56
-
56
+ | navigation_layout | Logo on cover | Logo on cover, Logo in the middle, stacked |
57
57
 
58
58
  You can specifiy these additional customisation options per post or in the default section for posts `_config.yml`
59
59
  | Config | Default | Options |
@@ -67,6 +67,26 @@ Kaschber also features several points to inject your custom code into the templa
67
67
  - `_includes/custom-js.html` to include any additional Javascript at the bottom of your page
68
68
  - `_includes/custom-post-content.html` to include any custom post-specific content which gets inserted in every post. E.g. a table of content tag
69
69
 
70
+ ### Navigation
71
+ Per default, Kaschber will include all files in your root folder in the header navigation bar. You can customise this with the setting `header_pages` in your `_config.yml`. E.g.
72
+
73
+ ```
74
+ header_pages:
75
+ - my_page.md
76
+ - about.md
77
+ ```
78
+
79
+ ### Colours
80
+ You can overwrite any colours and styles by just adding css files and include them in your `custom-head.html`. To overwrite the default accent colour #ff0095, do the following
81
+ 1. Create a file in your assets folder with the following content
82
+ ```css
83
+ :root {
84
+ --ghost-accent-color: #6D7C86;
85
+ }
86
+ ```
87
+ 2. Create `custom-head.html` in your `_includes` folder
88
+ 3. Include the new css file in your `custom-head.html`
89
+
70
90
  ## Authors
71
91
  To include author information, just create a folder called `_authors` and create your author information via markdown or html files. E.g.
72
92
  ```
data/_config.yml CHANGED
@@ -1,6 +1,7 @@
1
1
  feed_layout: "Classic"
2
2
  color_scheme: "Auto"
3
3
  language: 'en-uk'
4
+ navigation_layout: "Logo on cover"
4
5
 
5
6
  # gems and other configs
6
7
  plugins:
data/_includes/head.html CHANGED
@@ -1,13 +1,24 @@
1
1
  <head>
2
- <meta charset="utf-8">
2
+
3
+ <meta charset="utf-8" />
4
+ <meta http-equiv="X-UA-Compatible" content="IE=edge" />
5
+ <meta name="HandheldFriendly" content="True" />
6
+ <meta name="viewport" content="width=device-width, initial-scale=1.0" />
7
+
3
8
  {%- include dynamic_title.html -%}
4
9
 
5
10
  {%- seo -%}
6
11
 
7
12
  {%- feed_meta -%}
8
13
 
9
- <link rel="stylesheet" type="text/css" href="{{ "/assets/built/global.css" | relative_url }}">
10
- <link rel="stylesheet" type="text/css" href="{{ "/assets/built/screen.css" | relative_url }}">
14
+ <link
15
+ rel="stylesheet"
16
+ type="text/css"
17
+ href="{{ "/assets/built/global.css" | relative_url }}">
18
+ <link
19
+ rel="stylesheet"
20
+ type="text/css"
21
+ href="{{ "/assets/built/screen.css" | relative_url }}">
11
22
 
12
23
  {%- include custom-head.html -%}
13
24
 
data/_layouts/author.html CHANGED
@@ -1,64 +1,66 @@
1
1
  ---
2
2
  layout: default
3
3
  ---
4
-
5
4
  <main id="site-main" class="site-main outer">
6
- <div class="post-feed inner">
5
+ <div class="inner posts">
7
6
 
8
- <section class="post-card post-card-large">
9
- {%if page.feature_image %}
10
- <div class="post-card-image-link">
11
- <img class="post-card-image" src="{{ site.baseurl }}{{ page.feature_image }}" alt="{{ page.name }}">
12
- </div>
13
- {% endif %}
7
+ <div class="post-feed">
8
+ <section class="post-card post-card-large">
14
9
 
15
- <div class="post-card-content">
16
- <div class="post-card-content-link">
10
+ {%if page.feature_image %}
11
+ <div class="post-card-image-link">
12
+ <img class="post-card-image" src="{{ site.baseurl }}{{ page.feature_image }}" alt="{{ page.name }}">
13
+ </div>
14
+ {% endif %}
17
15
 
18
- {%if page.picture %}
19
- <img class="author-profile-pic" src="{{ site.baseurl }}{{ page.picture }}" alt="{{page.name}}"/>
20
- {% endif %}
16
+ <div class="post-card-content">
17
+ <div class="post-card-content-link">
21
18
 
22
- <header class="post-card-header">
23
- <h2 class="post-card-title">{{page.name}}</h2>
24
- </header>
19
+ {%if page.picture %}
20
+ <img class="author-profile-pic" src="{{ site.baseurl }}{{ page.picture }}" alt="{{page.name}}"/>
21
+ {% endif %}
25
22
 
26
- {%if page.bio %}
27
- <div class="post-card-excerpt">{{page.bio}}</div>
28
- {% endif %}
23
+ <header class="post-card-header">
24
+ <h2 class="post-card-title">{{page.name}}</h2>
25
+ </header>
29
26
 
30
- <footer class="author-profile-footer">
31
- {%if page.location %}
32
- <div class="author-profile-location">{{page.location}}</div>
27
+ {%if page.bio %}
28
+ <div class="post-card-excerpt">{{page.bio}}</div>
33
29
  {% endif %}
34
- <div class="author-profile-meta">
35
- {%if page.website %}
36
- <a class="author-profile-social-link" href="{{page.website}}" target="_blank" rel="noopener">{{page.website}}</a>
37
- {% endif %}
38
- {%if page.twitter_url %}
39
- <a class="author-profile-social-link" href="{{page.twitter_url}}" target="_blank" rel="noopener">{% include icons/twitter.html %}</a>
40
- {% endif %}
41
- {%if page.facebook_url %}
42
- <a class="author-profile-social-link" href="{{page.facebook_url}}" target="_blank" rel="noopener">{% include icons/facebook.html %}</a>
43
- {% endif %}
44
30
 
45
- {% if page.location %}
46
- <div class="author-location">{{ page.location }}
47
- <span class="bull">&bull;</span>
48
- </div>
31
+ <footer class="author-profile-footer">
32
+ {%if page.location %}
33
+ <div class="author-profile-location">{{page.location}}</div>
49
34
  {% endif %}
50
- </div>
51
- </footer>
35
+ <div class="author-profile-meta">
36
+ {%if page.website %}
37
+ <a class="author-profile-social-link" href="{{page.website}}" target="_blank" rel="noopener">{{page.website}}</a>
38
+ {% endif %}
39
+ {%if page.twitter_url %}
40
+ <a class="author-profile-social-link" href="{{page.twitter_url}}" target="_blank" rel="noopener">{% include icons/twitter.html %}</a>
41
+ {% endif %}
42
+ {%if page.facebook_url %}
43
+ <a class="author-profile-social-link" href="{{page.facebook_url}}" target="_blank" rel="noopener">{% include icons/facebook.html %}</a>
44
+ {% endif %}
45
+
46
+ {% if page.location %}
47
+ <div class="author-location">{{ page.location }}
48
+ <span class="bull">&bull;</span>
49
+ </div>
50
+ {% endif %}
51
+ </div>
52
+ </footer>
52
53
 
54
+ </div>
53
55
  </div>
54
- </div>
55
56
 
56
- </section>
57
+ </section>
57
58
 
58
- {% assign filtered_posts = site.posts | where: 'author', page.username %}
59
- {% for post in filtered_posts %}
60
- {% include post-card.html post=post %}
61
- {% endfor %}
59
+ {% assign filtered_posts = site.posts | where: 'author', page.username %}
60
+ {% for post in filtered_posts %}
61
+ {% include post-card.html post=post %}
62
+ {% endfor %}
62
63
 
64
+ </div>
63
65
  </div>
64
66
  </main>
@@ -4,40 +4,36 @@
4
4
  {% include head.html %}
5
5
 
6
6
  <body class="{% if paginator.page > 1 %}paged archive-template{% elsif page.class %}{{ page.class }}{% else %}home-template{% endif %}
7
- {% if site.title_font == 'Elegant serif' %} has-serif-title{% endif %}{% if site.body_font == 'Modern sans-serif' %} has-sans-body{% endif %}
8
- {% if site.cover or page.cover %} has-cover {% endif %}{% if page.current == 'home' %}{% unless site.show_logo_in_navigation %} no-logo{% endunless %}{% endif %}">
7
+ is-head-{% if site.navigation_layout == 'Logo on cover' %}left-logo{% elsif site.navigation_layout == 'Logo in the middle' %}middle-logo{% else %}stacked{% endif %}
8
+ {% if site.title_font == 'Elegant serif' %} has-serif-title{% endif %}{% if site.body_font == 'Modern sans-serif' %} has-sans-body{% endif %}
9
+ {% if site.cover or page.cover %} has-cover {% endif %}">
9
10
  <div class="viewport">
10
11
  <header id="gh-head" class="gh-head outer">
11
- <nav class="gh-head-inner inner">
12
+ <div class="gh-head-inner inner">
12
13
  <div class="gh-head-brand">
13
- <a class="gh-head-logo{% unless site.logo %} no-image{% endunless %}" href="{{ site.url }}{{ site.baseurl }}">
14
+ <a class="gh-head-logo" href="{{ site.url }}{{ site.baseurl }}">
14
15
  {% if site.logo %}
15
16
  <img src="{{ site.baseurl }}{{ site.logo }}" alt="{{ site.title }}">
16
17
  {% else %}
17
18
  {{ site.title }}
18
19
  {% endif %}
19
20
  </a>
20
- <div class="gh-head-brand-wrapper">
21
- <a class="gh-burger" role="button">
22
- <div class="gh-burger-box">
23
- <div class="gh-burger-inner"></div>
24
- </div>
25
- </a>
26
- </div>
21
+ <button class="gh-burger"></button>
27
22
  </div>
28
- <div class="gh-head-menu">
23
+ {%- assign default_paths = site.pages | map: "path" -%}
24
+ {%- assign page_paths = site.header_pages | default: default_paths -%}
25
+ <nav class="gh-head-menu">
29
26
  <ul class="nav" role="menu">
30
- <li class="nav-home" role="menuitem">
31
- <a href="{{site.baseurl}}">Home</a>
32
- </li>
33
- <li class="nav-about" role="menuitem">
34
- <a href="{{site.baseurl}}about/">About</a>
35
- </li>
36
- <li class="nav-try-ghost" role="menuitem">
37
- <a href="{{site.baseurl}}impressum/">Impressum/Datenschutz</a>
38
- </li>
27
+ {%- for path in page_paths -%}
28
+ {%- assign my_page = site.pages | where: "path", path | first -%}
29
+ {%- if my_page.title -%}
30
+ <li class="nav-{{ my_page.title | escape }}" role="menuitem">
31
+ <a class="page-link" href="{{ my_page.url | relative_url }}">{{ my_page.title | escape }}</a>
32
+ </li>
33
+ {%- endif -%}
34
+ {%- endfor -%}
39
35
  </ul>
40
- </div>
36
+ </nav>
41
37
  <div class="gh-head-actions">
42
38
  <div class="gh-social">
43
39
  {% if site.facebook %}
@@ -68,7 +64,7 @@
68
64
  </div>
69
65
  {% endif %}
70
66
  </div>
71
- </nav>
67
+ </div>
72
68
  </header>
73
69
 
74
70
 
data/_layouts/home.html CHANGED
@@ -12,13 +12,13 @@ class: 'home-template'
12
12
 
13
13
  {% if site.header_style != "Hidden" %}
14
14
  <div class="site-header-inner inner">
15
- {% unless site.show_logo_in_navigation %}
15
+ {% if site.navigation_layout == "Logo on cover" %}
16
16
  {% if site.logo %}
17
17
  <img class="site-logo" src="{{ site.logo }}" alt="{{ site.title }}">
18
18
  {% else %}
19
19
  <h1 class="site-title">{{ site.title }}</h1>
20
20
  {% endif %}
21
- {% endunless %}
21
+ {% endif %}
22
22
  {% if site.description %}
23
23
  <p class="site-description">{{ site.description }}</p>
24
24
  {% endif %}