Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zzossig/hugo-theme-zdoc.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorzzossig <zzossig@gmail.com>2020-02-11 18:58:36 +0300
committerzzossig <zzossig@gmail.com>2020-02-11 18:58:36 +0300
commit663d01f47e74aea170d5c2a4cb4ebb3084fda67f (patch)
tree0738d2d148e26f08042348190ff08a32228c071d
parent4d70b0fc6a1294652f7f40cce17535b1b821185d (diff)
title, breadcrumb in post position changed
-rw-r--r--assets/sass/base/_typography.scss4
-rw-r--r--assets/sass/components/_bgcolor.scss11
-rw-r--r--assets/sass/components/_breadcrumb.scss8
-rw-r--r--assets/sass/layout/_header.scss12
-rw-r--r--assets/sass/layout/_navbar.scss2
-rw-r--r--assets/sass/main.scss1
-rw-r--r--assets/sass/pages/_single.scss74
-rw-r--r--assets/sass/themes/_dark.scss7
-rw-r--r--assets/sass/themes/_light.scss6
-rw-r--r--assets/sass/themes/_lightcode.scss6
-rw-r--r--layouts/_default/list.searchindex.json1
-rw-r--r--layouts/_default/section.html3
-rw-r--r--layouts/_default/single.html3
-rw-r--r--layouts/_default/single.searchindex.json1
-rw-r--r--layouts/_default/terms.searchindex.json1
-rw-r--r--layouts/index.json1
-rw-r--r--layouts/partials/main/header.html19
-rw-r--r--layouts/partials/main/list.html3
-rw-r--r--layouts/partials/main/sections/list-main.html2
-rw-r--r--layouts/partials/main/single.html4
20 files changed, 84 insertions, 85 deletions
diff --git a/assets/sass/base/_typography.scss b/assets/sass/base/_typography.scss
index dab7324..beb0856 100644
--- a/assets/sass/base/_typography.scss
+++ b/assets/sass/base/_typography.scss
@@ -9,13 +9,13 @@
}
body {
- font-size: 16px;
+ font-size: 1rem;
font-family: $text-font-stack;
}
code,
pre {
- font-size: 13.8px;
+ font-size: 0.85rem;
font-family: $code-font-stack;
}
diff --git a/assets/sass/components/_bgcolor.scss b/assets/sass/components/_bgcolor.scss
new file mode 100644
index 0000000..8fd5f68
--- /dev/null
+++ b/assets/sass/components/_bgcolor.scss
@@ -0,0 +1,11 @@
+.bgcolor {
+ @include themify($themes) {
+ &__header {
+ background-color: themed('single-header-title-background-color');
+ }
+
+ &__breadcrumb {
+ background-color: themed('breadcrumb-background-color');
+ }
+ }
+} \ No newline at end of file
diff --git a/assets/sass/components/_breadcrumb.scss b/assets/sass/components/_breadcrumb.scss
index 811f89b..f359962 100644
--- a/assets/sass/components/_breadcrumb.scss
+++ b/assets/sass/components/_breadcrumb.scss
@@ -1,12 +1,8 @@
.breadcrumb {
- margin: 1.5rem 1rem 0 1rem;
- padding-bottom: 1.5rem;
+ margin: 0 1rem;
+ padding: 0.5rem 0;
@include truncate($grid-body-width);
- @include themify($themes) {
- border-bottom: 1px solid themed('hr-color');
- background-color: themed('breadcrumb-background-color');
- }
ol {
@include flexbox();
diff --git a/assets/sass/layout/_header.scss b/assets/sass/layout/_header.scss
index a398046..389fbc9 100644
--- a/assets/sass/layout/_header.scss
+++ b/assets/sass/layout/_header.scss
@@ -1,3 +1,9 @@
+.top {
+ @include themify($themes) {
+ background-color: themed('single-header-title-background-color');
+ }
+}
+
.header {
@include flexbox();
@include justify-content(center);
@@ -8,6 +14,12 @@
font-family: $title-font;
font-weight: 900;
}
+
+ &__wrapper {
+ @include themify($themes) {
+ border-bottom: 1px solid themed('border-line-color');
+ }
+ }
}
.blog-header {
diff --git a/assets/sass/layout/_navbar.scss b/assets/sass/layout/_navbar.scss
index 5edb230..ae2f167 100644
--- a/assets/sass/layout/_navbar.scss
+++ b/assets/sass/layout/_navbar.scss
@@ -197,7 +197,7 @@
@include align-items(center);
@include justify-content(center);
@include themify($themes) {
- color: themed('body-color');
+ color: themed('landing-button-default');
@include on-event {
background-color: themed('dropdown-hover-background-color');
}
diff --git a/assets/sass/main.scss b/assets/sass/main.scss
index 8bf4e8b..77ea2ca 100644
--- a/assets/sass/main.scss
+++ b/assets/sass/main.scss
@@ -35,6 +35,7 @@ $light-link-hover-color: {{ .Site.Data.color.light_link_hover_color }};
@import 'components/button';
@import 'components/summary';
@import 'components/expand';
+@import 'components/bgcolor';
@import 'layout/grid';
@import 'layout/footer';
diff --git a/assets/sass/pages/_single.scss b/assets/sass/pages/_single.scss
index ce5df1c..e953234 100644
--- a/assets/sass/pages/_single.scss
+++ b/assets/sass/pages/_single.scss
@@ -5,7 +5,6 @@
}
.single {
- padding: 0 1rem;
position: relative;
width: 100%;
overflow-wrap: break-word;
@@ -19,13 +18,13 @@
}
&__title {
- font-size: 2.5rem;
+ font-size: 3rem;
font-weight: 900;
font-family: $title-font;
line-height: 3rem;
overflow-wrap: break-word;
- margin-top: 1.5rem;
- margin-bottom: 0.5rem;
+ padding: 1rem;
+ margin: 1rem 0;
@include themify($themes) {
color: themed("single-header-title-color");
@@ -76,12 +75,12 @@
h6 {
position: relative;
line-height: 1.25;
+ padding: 0 1rem;
font-family: $title-font;
}
h1,
h2 {
- padding: 0;
color: inherit;
font-weight: 900;
text-rendering: optimizeLegibility;
@@ -136,8 +135,8 @@
line-height: 1.5;
@include themify($themes) {
- border-top: 1px solid themed('hr-color');
- border-bottom: 1px solid themed('hr-color');
+ border-top: 1px solid themed('border-line-color');
+ border-bottom: 1px solid themed('border-line-color');
@include webkit-scrollbars(themed('custom-scrollbar-foreground-color'), themed('custom-scrollbar-background-color'));
@include moz-scrollbars(themed('custom-scrollbar-foreground-color'), themed('custom-scrollbar-background-color'));
@@ -166,59 +165,6 @@
}
}
- code + .copy-to-clipboard {
- position: absolute;
- right: 4px;
- top: 5px;
- border-radius: 2px;
- z-index: z('clipboard');
- @include transition(all, 0.2s, ease);
- }
-
- .copy-to-clipboard {
- background-position: 50% 50%;
- background-size: 16px 16px;
- background-repeat: no-repeat;
- width: 27px;
- height: 1.45rem;
- top: -1px;
- vertical-align: middle;
- position: relative;
- margin-left: -0.2rem;
- cursor: pointer;
- border-radius: 0 2px 2px 0;
- margin-bottom: 1px;
- opacity: 0;
-
- @include clippy();
- @include transition(all, 0.2s, ease);
- }
- .copy-to-clipboard:hover {
- @include translateY(-0.1rem);
- }
- .chroma .copy-to-clipboard {
- position: absolute;
- right: 4px;
- top: 5px;
- border-radius: 2px;
- z-index: z('clipboard');
- @include transition(all, 0.2s, ease);
- }
- .chroma .copy-to-clipboard:hover {
- @include translateY(-0.1rem);
- }
- .language-code .copy-to-clipboard {
- position: absolute;
- right: 4px;
- top: 5px;
- border-radius: 2px;
- z-index: z('clipboard');
- @include transition(all, 0.2s, ease);
- }
- .language-code .copy-to-clipboard:hover {
- @include translateY(-0.1rem);
- }
-
blockquote {
margin: 0 1.75rem 1.75rem 1.5rem;
padding: 0 0 0 1.42188rem;
@@ -248,8 +194,8 @@
}
p {
- margin: 0 0 1rem 0;
- padding: 0;
+ margin: 0 0 10px 0;
+ padding: 0 1rem;
code:not([class^=language]) {
padding: 3px 7px;
@@ -269,7 +215,6 @@
li {
margin-left: 2rem;
- margin-bottom: calc(1rem / 2);
& > code {
padding: 2px 7px;
@@ -283,8 +228,7 @@
}
hr {
- margin: 0 0 calc(1.25rem - 1px) 0;
- padding: 0;
+ margin: 10px 1rem;
border: none;
height: 1px;
@include themify($themes) {
diff --git a/assets/sass/themes/_dark.scss b/assets/sass/themes/_dark.scss
index 44e336c..bdafd28 100644
--- a/assets/sass/themes/_dark.scss
+++ b/assets/sass/themes/_dark.scss
@@ -32,4 +32,11 @@ $dark: (
pagination-link-color: #82aaff,
pagination-disabled-color: #757575,
pagination-number-color: #FCFCFA,
+ breadcrumb-background-color: #2D2A2E,
+ single-hr-background-color: #727072,
+ single-blockquote-border-color: #FCFCFA,
+ single-header-title-color: #FCFCFA,
+ single-contents-title-color: #ccc,
+ single-header-title-background-color: #212121,
+ single-contents-subtitle-color: #FCFCFA,
); \ No newline at end of file
diff --git a/assets/sass/themes/_light.scss b/assets/sass/themes/_light.scss
index dccbee1..36dd682 100644
--- a/assets/sass/themes/_light.scss
+++ b/assets/sass/themes/_light.scss
@@ -33,4 +33,10 @@ $light: (
pagination-background-color: #eee,
pagination-disabled-color: #bdbdbd,
pagination-number-color: #757575,
+ breadcrumb-background-color: #fff,
+ single-hr-background-color: #bdbdbd,
+ single-blockquote-border-color: #bdbdbd,
+ single-header-title-color: #424242,
+ single-header-title-background-color: #eee,
+ single-contents-title-color: #607d8b,
); \ No newline at end of file
diff --git a/assets/sass/themes/_lightcode.scss b/assets/sass/themes/_lightcode.scss
index e90a426..5374c99 100644
--- a/assets/sass/themes/_lightcode.scss
+++ b/assets/sass/themes/_lightcode.scss
@@ -3,8 +3,8 @@ $lightcode: (
content-pre-main-color: #607d8b,
content-pre-color: #344952,
content-pre-number-color: #aaa,
- content-pre-background-color: #eceff1,
- content-pre-border-background-color: darken(#eceff1, 7%),
- content-pre-header-background-color: darken(#eceff1, 3.5%),
+ content-pre-background-color: #f7f8f9,
+ content-pre-border-background-color: darken(#f7f8f9, 7%),
+ content-pre-header-background-color: darken(#f7f8f9, 3.5%),
content-pre-header-color: #344952,
); \ No newline at end of file
diff --git a/layouts/_default/list.searchindex.json b/layouts/_default/list.searchindex.json
index b29edc3..a1870fa 100644
--- a/layouts/_default/list.searchindex.json
+++ b/layouts/_default/list.searchindex.json
@@ -1,3 +1,4 @@
+{{ .Scratch.Delete "searchindex" }}
{{- $.Scratch.Add "searchindex" slice -}}
{{- range $index, $element := (where .Site.Pages "Kind" "page") -}}
{{ with $element.Plain }}
diff --git a/layouts/_default/section.html b/layouts/_default/section.html
index 895b47e..18e584a 100644
--- a/layouts/_default/section.html
+++ b/layouts/_default/section.html
@@ -1,3 +1,6 @@
+{{ define "header" }}
+ {{ partial "main/header.html" . }}
+{{ end }}
{{ define "main" }}
{{ partial "main/list.html" . }}
{{ end }}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 33945ea..e553375 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -1,3 +1,6 @@
+{{ define "header" }}
+ {{ partial "main/header.html" . }}
+{{ end }}
{{ define "main" }}
{{ partial "main/single.html" . }}
{{ end }} \ No newline at end of file
diff --git a/layouts/_default/single.searchindex.json b/layouts/_default/single.searchindex.json
index b29edc3..a1870fa 100644
--- a/layouts/_default/single.searchindex.json
+++ b/layouts/_default/single.searchindex.json
@@ -1,3 +1,4 @@
+{{ .Scratch.Delete "searchindex" }}
{{- $.Scratch.Add "searchindex" slice -}}
{{- range $index, $element := (where .Site.Pages "Kind" "page") -}}
{{ with $element.Plain }}
diff --git a/layouts/_default/terms.searchindex.json b/layouts/_default/terms.searchindex.json
index b29edc3..a1870fa 100644
--- a/layouts/_default/terms.searchindex.json
+++ b/layouts/_default/terms.searchindex.json
@@ -1,3 +1,4 @@
+{{ .Scratch.Delete "searchindex" }}
{{- $.Scratch.Add "searchindex" slice -}}
{{- range $index, $element := (where .Site.Pages "Kind" "page") -}}
{{ with $element.Plain }}
diff --git a/layouts/index.json b/layouts/index.json
index 0a96038..f807f0b 100644
--- a/layouts/index.json
+++ b/layouts/index.json
@@ -1,3 +1,4 @@
+{{ .Scratch.Delete "searchindex" }}
{{- $.Scratch.Add "searchindex" slice -}}
{{- range $index, $element := (where .Site.Pages "Kind" "page") -}}
{{ with $element.Plain }}
diff --git a/layouts/partials/main/header.html b/layouts/partials/main/header.html
new file mode 100644
index 0000000..c171e29
--- /dev/null
+++ b/layouts/partials/main/header.html
@@ -0,0 +1,19 @@
+<div class="top">
+ <div class="header__wrapper bgcolor__header">
+ <div class="divider">
+ <div class="lmr">
+ <h2 class="single__title">{{ .Title }}</h2>
+ </div>
+ </div>
+ </div>
+
+ <div class="header__wrapper bgcolor__breadcrumb">
+ <div class="divider">
+ <div class="lmr">
+ {{ if $.Param "enableBreadcrumb" }}
+ {{ partial "main/component/breadcrumb.html" . }}
+ {{ end }}
+ </div>
+ </div>
+ </div>
+</div> \ No newline at end of file
diff --git a/layouts/partials/main/list.html b/layouts/partials/main/list.html
index 9e714d3..5f454e9 100644
--- a/layouts/partials/main/list.html
+++ b/layouts/partials/main/list.html
@@ -8,9 +8,6 @@
</nav>
<article id="list-main" class="m">
- {{ if $.Param "enableBreadcrumb" }}
- {{ partial "main/component/breadcrumb.html" . }}
- {{ end }}
{{ partial "main/sections/list-main.html" . }}
{{ partial "main/component/pagination-single.html" . }}
</article>
diff --git a/layouts/partials/main/sections/list-main.html b/layouts/partials/main/sections/list-main.html
index c740ab9..90b3c9b 100644
--- a/layouts/partials/main/sections/list-main.html
+++ b/layouts/partials/main/sections/list-main.html
@@ -1,10 +1,10 @@
<div class="single" data-display="block">
- <h2 class="single__title">{{ .Title }}</h2>
{{ if eq .Type "blog" }}
<div class="single__meta">
{{ partial "main/component/article-meta.html" . }}
</div>
{{ end }}
+
<article class="single__contents">
{{ .Content }}
</article>
diff --git a/layouts/partials/main/single.html b/layouts/partials/main/single.html
index 469d671..f1f48ee 100644
--- a/layouts/partials/main/single.html
+++ b/layouts/partials/main/single.html
@@ -8,10 +8,6 @@
</nav>
<article id="list-main" class="m">
- {{ if $.Param "enableBreadcrumb" }}
- {{ partial "main/component/breadcrumb.html" . }}
- {{ end }}
-
{{ partial "main/sections/list-main.html" . }}
{{ partial "main/component/pagination-single.html" . }}
{{ partial "comments/comments.html" . }}