jekyll-theme-morph 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (45) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +189 -0
  4. data/_includes/bread-bar.html +9 -0
  5. data/_includes/catalogue.html +26 -0
  6. data/_includes/footer.html +7 -0
  7. data/_includes/head.html +37 -0
  8. data/_includes/header.html +45 -0
  9. data/_includes/paginator.html +27 -0
  10. data/_includes/post-info.html +31 -0
  11. data/_includes/simple-post-info.html +14 -0
  12. data/_includes/trending-article-item.html +25 -0
  13. data/_layouts/classify.html +55 -0
  14. data/_layouts/default.html +16 -0
  15. data/_layouts/home.html +82 -0
  16. data/_layouts/page.html +8 -0
  17. data/_layouts/post.html +84 -0
  18. data/_layouts/search.html +36 -0
  19. data/_sass/classify.scss +58 -0
  20. data/_sass/home.scss +67 -0
  21. data/_sass/morph.scss +7 -0
  22. data/_sass/morph/_base.scss +62 -0
  23. data/_sass/morph/_colors.scss +42 -0
  24. data/_sass/morph/_functions.scss +57 -0
  25. data/_sass/morph/_utilities.scss +196 -0
  26. data/_sass/morph/_variables.scss +50 -0
  27. data/_sass/morph/components/_catalogue.scss +68 -0
  28. data/_sass/morph/components/_footer.sass +9 -0
  29. data/_sass/morph/components/_header.scss +80 -0
  30. data/_sass/morph/components/_highlight.scss +66 -0
  31. data/_sass/morph/components/_nano-compo.scss +23 -0
  32. data/_sass/morph/components/_paginator.scss +19 -0
  33. data/_sass/morph/components/_post-info.scss +30 -0
  34. data/_sass/morph/themes/obsidian.scss +86 -0
  35. data/_sass/morph/themes/silver.scss +79 -0
  36. data/_sass/post.scss +194 -0
  37. data/_sass/search.scss +68 -0
  38. data/assets/javascript/post.js +52 -0
  39. data/assets/javascript/search.js +51 -0
  40. data/assets/style/classify.scss +4 -0
  41. data/assets/style/home.scss +4 -0
  42. data/assets/style/main.scss +4 -0
  43. data/assets/style/post.scss +5 -0
  44. data/assets/style/search.scss +4 -0
  45. metadata +156 -0
@@ -0,0 +1,42 @@
1
+ @import "variables";
2
+
3
+ $grays: (
4
+ "100": $gray-100,
5
+ "200": $gray-200,
6
+ "300": $gray-300,
7
+ "400": $gray-400,
8
+ "500": $gray-500,
9
+ "600": $gray-600,
10
+ "700": $gray-700,
11
+ "800": $gray-800,
12
+ "900": $gray-900
13
+ ) !default;
14
+
15
+ $colors: (
16
+ "base": $color-base,
17
+ "primary-light": $color-primary-light,
18
+ "primary": $color-primary,
19
+ "primary-dark": $color-primary-dark,
20
+ "secondary-light": $color-secondary-light,
21
+ "secondary": $color-secondary,
22
+ "secondary-dark": $color-secondary-dark,
23
+ "link-light": $color-link-light,
24
+ "link": $color-link,
25
+ "link-dark": $color-link-dark,
26
+ "rang1": $color-rang1,
27
+ "rang2": $color-rang2,
28
+ "logo": $color-logo
29
+ ) !default;
30
+
31
+
32
+ // .color-gray-[level]
33
+ // .bg-gray-[level]
34
+ @each $key, $value in $grays {
35
+ .color-gray-#{$key} {color: $value}
36
+ .bg-gray-#{$key} {background-color: $value}
37
+ }
38
+
39
+ @each $key, $value in $colors {
40
+ .color-#{$key} {color: $value}
41
+ .bg-#{$key} {background-color: $value}
42
+ }
@@ -0,0 +1,57 @@
1
+ @import "variables";
2
+
3
+ // Functions
4
+ @mixin media-xs() {
5
+ @media
6
+ (max-width: map-get($grid-breakpoints, 'xs'))
7
+ {
8
+ @content;
9
+ }
10
+ }
11
+
12
+ @mixin media-sm() {
13
+ @media
14
+ (max-width: map-get($grid-breakpoints, 'sm'))
15
+ {
16
+ @content;
17
+ }
18
+ }
19
+
20
+ @mixin media-md() {
21
+ @media
22
+ (max-width: map-get($grid-breakpoints, 'md'))
23
+ {
24
+ @content;
25
+ }
26
+ }
27
+
28
+ @mixin media($utilities, $infix: '') {
29
+ @each $utility in map-values($utilities) {
30
+ $p: map-get($utility, "property");
31
+ $c: map-get($utility, "class");
32
+ $values: map-get($utility, "values");
33
+
34
+ @if type-of($values) == "map" {
35
+ @each $k, $v in $values {
36
+ .#{$c}#{$infix}-#{$k} {
37
+ #{$p}: $v
38
+ }
39
+ }
40
+ }
41
+ @else {
42
+ @each $v in $values {
43
+ .#{$c}#{$infix}-#{$v} {
44
+ #{$p}: $v
45
+ }
46
+ }
47
+ }
48
+ }
49
+ }
50
+
51
+ @function tint-color($color, $weight) {
52
+ @return mix(white, $color, $weight);
53
+ }
54
+
55
+ @function shade-color($color, $weight) {
56
+ @return mix(black, $color, $weight);
57
+ }
@@ -0,0 +1,196 @@
1
+ @import "variables";
2
+ @import "functions";
3
+
4
+ $utilities: () !default;
5
+
6
+ $utilities: map-merge(
7
+ (
8
+ "align": (
9
+ property: vertical-align,
10
+ class: align,
11
+ values: baseline top middle bottom text-bottom text-top
12
+ ),
13
+ "float": (
14
+ property: float,
15
+ class: float,
16
+ values: (
17
+ start: left,
18
+ end: right,
19
+ none: none,
20
+ )
21
+ ),
22
+ "overflow": (
23
+ property: overflow,
24
+ class: overflow,
25
+ values: auto hidden visible scroll,
26
+ ),
27
+ "display": (
28
+ property: display,
29
+ class: d,
30
+ values: inline inline-block block grid table table-row table-cell flex inline-flex none
31
+ ),
32
+ "flex": (
33
+ property: flex,
34
+ class: flex,
35
+ values: 1 auto none
36
+ ),
37
+ "flex-grow": (
38
+ property: flex-grow,
39
+ class: flex,
40
+ values: (
41
+ grow-0: 0,
42
+ grow-1: 1,
43
+ )
44
+ ),
45
+ "flex-direction": (
46
+ property: flex-direction,
47
+ class: flex,
48
+ values: row column row-reverse column-reverse
49
+ ),
50
+ "justify-content": (
51
+ property: justify-content,
52
+ class: justify-content,
53
+ values: (
54
+ start: flex-start,
55
+ end: flex-end,
56
+ center: center,
57
+ between: space-between,
58
+ around: space-around,
59
+ evenly: space-evenly,
60
+ )
61
+ ),
62
+ "align-items": (
63
+ property: align-items,
64
+ class: align-items,
65
+ values: (
66
+ start: flex-start,
67
+ end: flex-end,
68
+ center: center,
69
+ baseline: baseline,
70
+ stretch: stretch,
71
+ )
72
+ ),
73
+ "align-content": (
74
+ property: align-content,
75
+ class: align-content,
76
+ values: (
77
+ start: flex-start,
78
+ end: flex-end,
79
+ center: center,
80
+ between: space-between,
81
+ around: space-around,
82
+ stretch: stretch,
83
+ )
84
+ ),
85
+ "align-self": (
86
+ property: align-self,
87
+ class: align-self,
88
+ values: (
89
+ auto: auto,
90
+ start: flex-start,
91
+ end: flex-end,
92
+ center: center,
93
+ baseline: baseline,
94
+ stretch: stretch,
95
+ )
96
+ ),
97
+ "font-weight": (
98
+ property: font-weight,
99
+ class: fw,
100
+ values: (
101
+ light: $font-weight-light,
102
+ lighter: $font-weight-lighter,
103
+ normal: $font-weight-normal,
104
+ bold: $font-weight-bold,
105
+ bolder: $font-weight-bolder
106
+ )
107
+ ),
108
+ "text-align": (
109
+ property: text-align,
110
+ class: text,
111
+ values: (
112
+ start: left,
113
+ end: right,
114
+ center: center,
115
+ )
116
+ ),
117
+ "text-decoration": (
118
+ property: text-decoration,
119
+ class: text-decoration,
120
+ values: none underline line-through
121
+ ),
122
+ "user-select": (
123
+ property: user-select,
124
+ class: user-select,
125
+ values: all auto none
126
+ ),
127
+ "margin": (
128
+ property: margin,
129
+ class: m,
130
+ values: (auto: auto)
131
+ ),
132
+ "white-space": (
133
+ property: white-space,
134
+ class: white-space,
135
+ values: normal nowrap pre pre-wrap pre-line break-spaces
136
+ ),
137
+ "cursor": (
138
+ property: cursor,
139
+ class: cursor,
140
+ values: default pointer auto text crosshair move help wait
141
+ ),
142
+ "width": (
143
+ property: width,
144
+ class: w,
145
+ values: (
146
+ 25: 25%,
147
+ 50: 50%,
148
+ 75: 75%,
149
+ 100: 100%
150
+ )
151
+ ),
152
+ "height": (
153
+ property: height,
154
+ class: h,
155
+ values: (
156
+ 25: 25%,
157
+ 50: 50%,
158
+ 75: 75%,
159
+ 100: 100%
160
+ )
161
+ ),
162
+ "list-style-type": (
163
+ property: list-style-type,
164
+ class: list-style,
165
+ values: none disc circle square decimal
166
+ ),
167
+ "position": (
168
+ property: position,
169
+ class: position,
170
+ values: absolute fixed relative static sticky inherit initial
171
+ ),
172
+ ),
173
+ $utilities
174
+ );
175
+
176
+ // Build utilities
177
+ @include media($utilities);
178
+ @each $key in map-keys($grid-breakpoints) {
179
+ @if $key == 'xs' {
180
+ @include media-xs() {
181
+ @include media($utilities, -#{$key})
182
+ }
183
+ }
184
+
185
+ @if $key == 'sm' {
186
+ @include media-sm() {
187
+ @include media($utilities, -#{$key})
188
+ }
189
+ }
190
+
191
+ @if $key == 'md' {
192
+ @include media-md() {
193
+ @include media($utilities, -#{$key})
194
+ }
195
+ }
196
+ }
@@ -0,0 +1,50 @@
1
+ // gray colors
2
+ $white: #fff !default;
3
+ $gray-100: #f8f9fa !default;
4
+ $gray-200: #e9ecef !default;
5
+ $gray-300: #dee2e6 !default;
6
+ $gray-400: #ced4da !default;
7
+ $gray-500: #adb5bd !default;
8
+ $gray-600: #6c757d !default;
9
+ $gray-700: #495057 !default;
10
+ $gray-800: #343a40 !default;
11
+ $gray-900: #212529 !default;
12
+ $black: #000 !default;
13
+
14
+ // skin colors
15
+ $color-base: white !default;
16
+
17
+ $color-primary-light: #f8f8f8 !default;
18
+ $color-primary: #f4f4f4 !default;
19
+ $color-primary-dark: #e5e5e5 !default;
20
+
21
+ $color-secondary-light: #7a7a7a !default;
22
+ $color-secondary: #515151 !default;
23
+ $color-secondary-dark: #303030 !default;
24
+
25
+ $color-link-light: #729fcf !default;
26
+ $color-link: #3465a4 !default;
27
+ $color-link-dark: #204a87 !default;
28
+
29
+ $color-rang1: #e9b96e !default;
30
+ $color-rang2: #75507b !default;
31
+ $color-logo: $color-link-dark !default;
32
+
33
+ // Fonts
34
+ $serif-primary: -apple-system,BlinkMacSystemFont,Helvetica Neue,Helvetica,Arial,"PT Sans",PingFang SC,Microsoft YaHei,Source Han Sans SC,Noto Sans CJK SC,WenQuanYi Micro Hei,sans-serif !default;
35
+ $sans-serif: $serif-primary !default;
36
+ $monospaced: Source Code Pro, Courier New, Courier, monospace, sans-serif !default;
37
+
38
+ $font-weight-lighter: lighter !default;
39
+ $font-weight-light: 300 !default;
40
+ $font-weight-normal: 400 !default;
41
+ $font-weight-bold: 700 !default;
42
+ $font-weight-bolder: bolder !default;
43
+
44
+ // Contents
45
+ $content-max-width: 1140px;
46
+ $grid-breakpoints: (
47
+ 'xs': 540px,
48
+ 'sm': 720px,
49
+ 'md': 960px
50
+ ) !default;
@@ -0,0 +1,68 @@
1
+ @import "../variables";
2
+ @import "../functions";
3
+
4
+ .component {
5
+ &.catalogue {
6
+ margin-top: 3rem;
7
+ width: 85%;
8
+
9
+ header.header {
10
+ border-bottom: 1px solid $color-primary-dark;
11
+
12
+ .header-text {
13
+ padding: 1em 0;
14
+ }
15
+ }
16
+
17
+ ul.body {
18
+ padding: 1rem;
19
+ overflow: scroll;
20
+ white-space: nowrap;
21
+ border-left: 1px solid $color-primary-dark;
22
+ @include media-xs() {
23
+ max-height: 25rem;
24
+ }
25
+
26
+ &::-webkit-scrollbar {
27
+ display: none !important;
28
+ }
29
+
30
+ li {
31
+ list-style-type: none;
32
+ padding: 4px 0;
33
+
34
+ &.h2, &.h3, &.h4, &.h5, &.h6 {
35
+ &::before {
36
+ color: $color-primary;
37
+ }
38
+ }
39
+
40
+ &.h2::before {
41
+ content: '-- '
42
+ }
43
+
44
+ &.h3::before {
45
+ content: '---- '
46
+ }
47
+
48
+ &.h4::before {
49
+ content: '------ '
50
+ }
51
+
52
+ &.h5::before {
53
+ content: '-------- '
54
+ }
55
+
56
+ &.h6::before {
57
+ content: '---------- '
58
+ }
59
+
60
+ a {
61
+ display: inline-block;
62
+ width: 100%;
63
+ height: 100%;
64
+ }
65
+ }
66
+ }
67
+ }
68
+ }
@@ -0,0 +1,9 @@
1
+ @import "../variables"
2
+
3
+ footer.footer
4
+ padding: 1rem 0
5
+ .content
6
+ padding: 1rem
7
+ font-size: .9rem
8
+ line-height: 1.5rem
9
+ border-top: 1px dashed $color-primary-dark
@@ -0,0 +1,80 @@
1
+ @import "../functions";
2
+ @import "../variables";
3
+
4
+ .header {
5
+ .border-bottom {
6
+ border-bottom: 1px solid $color-primary-dark;
7
+ }
8
+
9
+ .logo {
10
+ font-size: 28px;
11
+ height: 115px;
12
+
13
+ a {
14
+ font-family: Arial, PingFangSC-Regular, "Microsoft YaHei-Regular", "Microsoft YaHei", serif;
15
+ color: $color-logo;
16
+
17
+ &:hover {
18
+ color: tint-color($color-logo, 15%);
19
+ }
20
+ }
21
+ }
22
+
23
+ .search-box {
24
+ margin-left: 30px;
25
+ .search {
26
+ position: relative;
27
+ @include media-md() {width: 50%}
28
+ @include media-sm() {width: 65%}
29
+ @include media-xs() {width: 75%}
30
+ width: 35%;
31
+ }
32
+
33
+ $search-box-radius: 2px;
34
+ $search-box-border-color: $color-primary-dark;
35
+ input {
36
+ font-size: 13px;
37
+ padding: 8px 10px;
38
+ -webkit-appearance: none;
39
+ outline: none;
40
+ border: 1px solid $search-box-border-color;
41
+ border-right: 0;
42
+ border-top-left-radius: $search-box-radius;
43
+ border-bottom-left-radius: $search-box-radius;
44
+ color: $color-secondary;
45
+ background-color: $color-base;
46
+ }
47
+
48
+ button.search-button {
49
+ border: 1px solid $search-box-border-color;
50
+ border-left: 0;
51
+ border-top-right-radius: $search-box-radius;
52
+ border-bottom-right-radius: $search-box-radius;
53
+ padding: 6px 8px;
54
+ margin-left: -5px;
55
+ color: $color-secondary-light;
56
+ }
57
+ }
58
+
59
+ .nav-bar {
60
+ ul {
61
+ line-height: 250%;
62
+ overflow-x: auto;
63
+
64
+ &::-webkit-scrollbar {
65
+ display: none !important;
66
+ }
67
+
68
+ li {
69
+ list-style-type: none;
70
+ margin-right: 25px;
71
+
72
+ a {
73
+ color: $color-secondary;
74
+ font-size: 14px;
75
+ padding: 4px 6px;
76
+ }
77
+ }
78
+ }
79
+ }
80
+ }