Skip to content

Commit 3c79301

Browse files
Various improvements
- new mono font - copy updates - simpler logic for header section
1 parent d120bf0 commit 3c79301

15 files changed

+66
-75
lines changed

assets/built/screen.css

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/built/screen.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/css/screen.css

+37-29
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,7 @@ production stylesheet in assets/built/screen.css
6565
--font-sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
6666
--font-serif: "EB Garamond", Georgia, Times, serif;
6767
--font-serif-alt: Georgia, Times, serif;
68-
--font-slab: "Roboto Slab", Georgia, Times, serif;
69-
--font-mono: Menlo, Courier, monospace;
68+
--font-mono: "JetBrains Mono", Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace;
7069
--container-width: 1320px;
7170
--container-gap: clamp(24px, 1.7032rem + 1.9355vw, 48px);
7271
--grid-gap: 42px;
@@ -112,11 +111,20 @@ production stylesheet in assets/built/screen.css
112111
}
113112

114113
@font-face {
115-
font-family: "Roboto Slab";
114+
font-family: "JetBrains Mono";
116115
font-style: normal;
117-
font-weight: 100 900;
116+
font-weight: 100 800;
117+
font-display: swap;
118+
src: url(/assets/fonts/jetbrains-mono-roman.woff2) format("woff2");
119+
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
120+
}
121+
122+
@font-face {
123+
font-family: "JetBrains Mono";
124+
font-style: italic;
125+
font-weight: 100 800;
118126
font-display: swap;
119-
src: url(/assets/fonts/roboto-slab-roman.woff2) format("woff2");
127+
src: url(/assets/fonts/jetbrains-mono-italic.woff2) format("woff2");
120128
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
121129
}
122130

@@ -279,7 +287,7 @@ button.gh-form-input {
279287
color: rgb(0 0 0 / 0.3);
280288
}
281289

282-
:is(.has-serif-title, .has-slab-title) .gh-form-input {
290+
:is(.has-serif-title, .has-mono-title) .gh-form-input {
283291
padding-inline: 20px;
284292
}
285293

@@ -315,7 +323,7 @@ button.gh-form-input {
315323
cursor: pointer;
316324
}
317325

318-
:is(.has-serif-title,.has-slab-title) button.gh-form-input {
326+
:is(.has-serif-title,.has-mono-title) button.gh-form-input {
319327
padding-inline-start: 50px;
320328
}
321329

@@ -335,7 +343,7 @@ button.gh-form-input {
335343
color: var(--color-secondary-text);
336344
}
337345

338-
:is(.has-serif-title,.has-slab-title) .gh-form > svg {
346+
:is(.has-serif-title,.has-mono-title) .gh-form > svg {
339347
left: 16px;
340348
}
341349

@@ -975,6 +983,7 @@ Search LOGO Login Subscribe
975983
display: flex;
976984
gap: 4px;
977985
flex-wrap: wrap;
986+
padding-bottom: 1px;
978987
font-size: 1.25rem;
979988
font-weight: 500;
980989
line-height: 1.05;
@@ -1686,7 +1695,7 @@ Search LOGO Login Subscribe
16861695
border-bottom: 1px solid var(--color-border);
16871696
}
16881697

1689-
.gh-container-title:has(+ .gh-main:not(:has(.gh-card))) {
1698+
.gh-container:not(:has(.gh-card)) .gh-container-title {
16901699
display: none;
16911700
}
16921701

@@ -2193,8 +2202,8 @@ unless a heading is the very first element in the post content */
21932202
font-family: var(--font-serif);
21942203
}
21952204

2196-
.has-slab-title .kg-toggle-card .kg-toggle-heading-text {
2197-
font-family: var(--font-slab);
2205+
.has-mono-title .kg-toggle-card .kg-toggle-heading-text {
2206+
font-family: var(--font-mono);
21982207
}
21992208

22002209
/* Callout */
@@ -2232,8 +2241,8 @@ blockquote.kg-blockquote-alt {
22322241
font-family: var(--font-serif);
22332242
}
22342243

2235-
.has-slab-title .kg-card.kg-header-card h2.kg-header-card-header {
2236-
font-family: var(--font-slab);
2244+
.has-mono-title .kg-card.kg-header-card h2.kg-header-card-header {
2245+
font-family: var(--font-mono);
22372246
}
22382247

22392248
.has-serif-body .kg-header-card h3.kg-header-card-subheader {
@@ -2287,8 +2296,8 @@ blockquote.kg-blockquote-alt {
22872296
font-family: var(--font-serif);
22882297
}
22892298

2290-
.has-slab-title .kg-product-card.kg-card .kg-product-card-title {
2291-
font-family: var(--font-slab);
2299+
.has-mono-title .kg-product-card.kg-card .kg-product-card-title {
2300+
font-family: var(--font-mono);
22922301
}
22932302

22942303
.has-serif-body .kg-product-card-description :is(p, ul, ol) {
@@ -2466,7 +2475,7 @@ figcaption a {
24662475
--factor: 1.15;
24672476
}
24682477

2469-
.has-slab-title {
2478+
.has-mono-title {
24702479
--factor: 1.1;
24712480
}
24722481

@@ -2479,9 +2488,8 @@ figcaption a {
24792488
font-weight: 550;
24802489
}
24812490

2482-
.has-slab-title :is(.is-title, .gh-content :is(h2, h3)) {
2483-
font-family: var(--font-slab);
2484-
font-weight: 650;
2491+
.has-mono-title :is(.is-title, .gh-content :is(h2, h3)) {
2492+
font-family: var(--font-mono);
24852493
}
24862494

24872495
.has-sans-body .is-body {
@@ -2497,7 +2505,7 @@ figcaption a {
24972505
letter-spacing: -0.015em;
24982506
}
24992507

2500-
.has-slab-title .gh-header.is-classic .gh-header-title {
2508+
.has-mono-title .gh-header.is-classic .gh-header-title {
25012509
letter-spacing: -0.01em;
25022510
}
25032511

@@ -2515,7 +2523,7 @@ figcaption a {
25152523
font-size: calc(1.6rem*var(--factor, 1))
25162524
}
25172525

2518-
.has-slab-title .gh-featured-feed .gh-card-title {
2526+
.has-mono-title .gh-featured-feed .gh-card-title {
25192527
font-size: calc(1.5rem*var(--factor, 1));
25202528
letter-spacing: 0;
25212529
}
@@ -2524,12 +2532,12 @@ figcaption a {
25242532
font-size: clamp(1.6rem, 0.23vw + 1.51rem, 1.8rem);
25252533
}
25262534

2527-
.has-slab-title .gh-card-title {
2535+
.has-mono-title .gh-card-title {
25282536
font-size: calc(1.8rem*var(--factor, 1));
25292537
}
25302538

2531-
.has-slab-title .gh-header.gh-header.is-highlight .gh-card-title,
2532-
.has-slab-title .gh-header.gh-header.gh-header.is-magazine .gh-card-title {
2539+
.has-mono-title .gh-header.gh-header.is-highlight .gh-card-title,
2540+
.has-mono-title .gh-header.gh-header.gh-header.is-magazine .gh-card-title {
25332541
line-height: 1.15;
25342542
}
25352543

@@ -2583,12 +2591,12 @@ figcaption a {
25832591
border-radius: 0;
25842592
}
25852593

2586-
.has-slab-title :is(.gh-button) {
2587-
border-radius: 6px;
2594+
.has-mono-title :is(.gh-button) {
2595+
border-radius: 0;
25882596
}
25892597

2590-
.has-slab-title :is(.gh-form) {
2591-
border-radius: 8px;
2598+
.has-mono-title :is(.gh-form) {
2599+
border-radius: 0;
25922600
}
25932601

25942602
.has-serif-title .gh-cta-title {
@@ -2599,7 +2607,7 @@ figcaption a {
25992607
/* ---------------------------------------------------------- */
26002608

26012609
.gh-footer {
2602-
margin-top: 6vw;
2610+
margin-top: 12vw;
26032611
font-size: 1.5rem;
26042612
color: var(--color-darker-gray);
26052613
}
41.4 KB
Binary file not shown.
39 KB
Binary file not shown.

assets/fonts/roboto-slab-roman.woff2

-34 KB
Binary file not shown.

author.hbs

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<main class="gh-main gh-outer">
55

66
{{#author}}
7-
<section class="gh-archive{{#if @custom.show_site_in_sidebar}} has-sidebar{{/if}} gh-inner">
7+
<section class="gh-archive{{#if @custom.show_publication_info_sidebar}} has-sidebar{{/if}} gh-inner">
88
<div class="gh-archive-inner">
99
<div class="gh-archive-wrapper">
1010
<h1 class="gh-article-title is-title">
@@ -38,6 +38,6 @@
3838
</section>
3939
{{/author}}
4040

41-
{{> "components/post-list" feed="archive" postFeedStyle=@custom.post_feed_style showTitle=false showSidebar=@custom.show_site_in_sidebar}}
41+
{{> "components/post-list" feed="archive" postFeedStyle=@custom.post_feed_style showTitle=false showSidebar=@custom.show_publication_info_sidebar}}
4242

4343
</main>

default.hbs

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
{{ghost_head}}
4242

4343
</head>
44-
<body class="{{body_class}} has-{{#match @custom.title_font "Elegant serif"}}serif{{else match @custom.title_font "Clean slab"}}slab{{else}}sans{{/match}}-title has-{{#match @custom.body_font "Elegant serif"}}serif{{else}}sans{{/match}}-body">
44+
<body class="{{body_class}} has-{{#match @custom.title_font "Elegant serif"}}serif{{else match @custom.title_font "Consistent mono"}}mono{{else}}sans{{/match}}-title has-{{#match @custom.body_font "Elegant serif"}}serif{{else}}sans{{/match}}-body">
4545

4646
<div class="gh-viewport">
4747

home.hbs

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
{{> "components/header" headerStyle=@custom.header_style}}
55

66
{{#match @custom.header_style "!=" "Highlight"}}
7-
{{> "components/featured" showFeatured=@custom.highlight_featured_posts limit=4}}
7+
{{> "components/featured" showFeatured=@custom.show_featured_posts limit=4}}
88
{{/match}}
99

1010
{{> "components/cta"}}
1111

12-
{{> "components/post-list" feed="home" postFeedStyle=@custom.post_feed_style showTitle=true showSidebar=@custom.show_site_in_sidebar}}
12+
{{> "components/post-list" feed="home" postFeedStyle=@custom.post_feed_style showTitle=true showSidebar=@custom.show_publication_info_sidebar}}

index.hbs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
{{!-- The tag above means: insert everything in this file into the body of the default.hbs template --}}
33

44
<main class="gh-main">
5-
{{> "components/post-list" feed="index" postFeedStyle=@custom.post_feed_style showTitle=true showSidebar=@custom.show_site_in_sidebar}}
5+
{{> "components/post-list" feed="index" postFeedStyle=@custom.post_feed_style showTitle=true showSidebar=@custom.show_publication_info_sidebar}}
66
</main>

package.json

+8-11
Original file line numberDiff line numberDiff line change
@@ -100,17 +100,17 @@
100100
"header_and_footer_color": {
101101
"type": "select",
102102
"options": [
103-
"Accent color",
104-
"Background color"
103+
"Background color",
104+
"Accent color"
105105
],
106-
"default": "Accent color"
106+
"default": "Background color"
107107
},
108108
"title_font": {
109109
"type": "select",
110110
"options": [
111111
"Modern sans-serif",
112112
"Elegant serif",
113-
"Clean slab"
113+
"Consistent mono"
114114
],
115115
"default": "Modern sans-serif"
116116
},
@@ -139,17 +139,18 @@
139139
"Search",
140140
"Off"
141141
],
142-
"description": "Highlight & Magazine styles will default to Landing until 7 posts have been published",
142+
"description": "Landing is recommended for all sites, Highlight & Magazine are ideal for those with more content",
143143
"default": "Landing",
144144
"group": "homepage"
145145
},
146146
"use_publication_cover_as_background": {
147147
"type": "boolean",
148148
"default": false,
149+
"description": "A cover image can be uploaded in Brand settings",
149150
"group": "homepage",
150151
"visibility": "header_style:[Landing, Search]"
151152
},
152-
"highlight_featured_posts": {
153+
"show_featured_posts": {
153154
"type": "boolean",
154155
"default": false,
155156
"group": "homepage",
@@ -167,26 +168,22 @@
167168
"show_images_in_feed": {
168169
"type": "boolean",
169170
"default": true,
170-
"description": "Toggles thumbnails of the post cards when the post feed style is List",
171171
"group": "homepage",
172172
"visibility": "post_feed_style:List"
173173
},
174174
"show_author": {
175175
"type": "boolean",
176176
"default": true,
177-
"description": "Show the author below each post",
178177
"group": "homepage"
179178
},
180179
"show_publish_date": {
181180
"type": "boolean",
182181
"default": true,
183-
"description": "Show the date published below each post",
184182
"group": "homepage"
185183
},
186-
"show_site_in_sidebar": {
184+
"show_publication_info_sidebar": {
187185
"type": "boolean",
188186
"default": false,
189-
"description": "Include your site info on the side of the post feed",
190187
"group": "homepage"
191188
}
192189
}

partials/components/header-content.hbs

+2-2
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@
2626
{{/foreach}}
2727
</div>
2828
<div class="gh-header-right">
29-
{{#if @custom.highlight_featured_posts}}
30-
{{> "components/featured" showFeatured=@custom.highlight_featured_posts limit=6}}
29+
{{#if @custom.show_featured_posts}}
30+
{{> "components/featured" showFeatured=@custom.show_featured_posts limit=6}}
3131
{{else}}
3232
<div class="gh-featured-feed">
3333
{{#foreach posts from="5" limit="6"}}

partials/components/header.hbs

+2-6
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
11
{{#match headerStyle "!=" "Off"}}
22

33
{{#match headerStyle "Highlight"}}
4-
{{#match posts.length ">=" 7}}
5-
{{> "components/header-content"}}
6-
{{/match}}
4+
{{> "components/header-content"}}
75
{{else match headerStyle "Magazine"}}
8-
{{#match posts.length ">=" 7}}
9-
{{> "components/header-content"}}
10-
{{/match}}
6+
{{> "components/header-content"}}
117
{{else}}
128
{{#match headerStyle "Landing"}}
139
{{#if @site.members_enabled}}

partials/components/post-list.hbs

+7-17
Original file line numberDiff line numberDiff line change
@@ -21,40 +21,30 @@
2121
{{!-- Homepage --}}
2222
{{#match feed "home"}}
2323
{{#match @custom.header_style "Highlight"}}
24-
{{#match posts.length ">=" 7}}
25-
{{#if @custom.highlight_featured_posts}}
24+
{{#if @custom.show_featured_posts}}
25+
{{#match posts.length ">=" 4}}
2626
{{#get "posts" include="authors" limit="16"}}
2727
{{#foreach posts from="5" limit="12"}}
2828
{{> "post-card"}}
2929
{{/foreach}}
3030
{{/get}}
31-
{{else}}
31+
{{/match}}
32+
{{else}}
33+
{{#match posts.length ">=" 10}}
3234
{{#get "posts" include="authors" limit="22"}}
3335
{{#foreach posts from="11" limit="12"}}
3436
{{> "post-card"}}
3537
{{/foreach}}
3638
{{/get}}
37-
{{/if}}
38-
{{else}}
39-
{{#get "posts" include="authors" limit="12"}}
40-
{{#foreach posts}}
41-
{{> "post-card"}}
42-
{{/foreach}}
43-
{{/get}}
44-
{{/match}}
39+
{{/match}}
40+
{{/if}}
4541
{{else match @custom.header_style "Magazine"}}
4642
{{#match posts.length ">=" 7}}
4743
{{#get "posts" include="authors" limit="19"}}
4844
{{#foreach posts from="8" limit="12"}}
4945
{{> "post-card"}}
5046
{{/foreach}}
5147
{{/get}}
52-
{{else}}
53-
{{#get "posts" include="authors" limit="12"}}
54-
{{#foreach posts}}
55-
{{> "post-card"}}
56-
{{/foreach}}
57-
{{/get}}
5848
{{/match}}
5949
{{else}}
6050
{{#get "posts" include="authors" limit="12"}}

0 commit comments

Comments
 (0)