Compare commits

...

12 Commits

Author SHA1 Message Date
9f9348544e v5.6.0 2023-07-31 13:51:45 -05:00
840b1b9c50 Switched from padding to margin for page card spacing 2023-07-24 16:58:30 +08:00
cc3fca004f Fixed cards not having space below 2023-07-22 00:08:12 +08:00
f8b34f9786 Fixed article header spacing on post template 2023-07-19 19:05:22 +08:00
b9f5d591d3 Rebuilt assets 2023-07-19 10:14:41 +08:00
a60e3e976a Updated hiding page title and feature image implementation (#946)
https://github.com/TryGhost/Product/issues/3568
2023-07-17 20:31:26 +08:00
d9c9390e17 Removed padding between navigation and full width content (#944) 2023-07-17 16:26:18 +08:00
84f201d293 Updated class to 'kg-card-hascaption'
Refs https://github.com/TryGhost/Product/issues/3589
2023-07-13 18:32:48 +08:00
c7fdfb7479 Removed spacing between full-width cards
Refs https://github.com/TryGhost/Product/issues/3589
2023-07-13 18:32:48 +08:00
d3483498d4 Added support for hidden title and feature image on pages (#943)
* Added support for hidden title and feature image on pages

Refs https://github.com/TryGhost/Product/issues/3568

* Switched from match to if helper for show_title_and_feature_image

Refs https://github.com/TryGhost/Product/issues/3568
2023-07-10 12:19:00 +02:00
4ae190c1a6 v5.5.3 2023-07-06 09:46:25 +08:00
22c83f9128 Fixed tag and author description character limit 2023-07-06 09:46:03 +08:00
5 changed files with 53 additions and 32 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1025,6 +1025,11 @@ production stylesheet in assets/built/screen.css
margin-top: 6px;
}
:is(.tag-template, .author-template) .post-card-large .post-card-excerpt {
display: block;
overflow-y: auto;
}
.post-card-meta {
display: flex;
align-items: center;
@ -1213,20 +1218,19 @@ html.no-infinite-scroll .pagination {
/* ---------------------------------------------------------- */
.article {
padding: max(8vmin, 40px) 0 max(8vmin, 64px);
word-break: break-word;
}
.page-template .article {
padding-top: max(12vmin, 64px);
.post-template .article {
padding: max(8vmin, 40px) 0 max(8vmin, 64px);
}
.article-header {
padding: 0 0 max(6.4vmin, 40px) 0;
.post-template .article-header {
padding: 0 0 max(6.4vmin, 40px);
}
.page-template .article-header {
padding-bottom: max(3.2vmin, 28px);
padding: max(12vmin, 64px) 0 max(3.2vmin, 28px);
}
.article-tag {
@ -1342,6 +1346,11 @@ headings, text, images and lists. We deal with cards lower down. */
margin-bottom: 0;
}
/* Remove space between full-width cards */
.gh-content > .kg-width-full + .kg-width-full:not(.kg-width-full.kg-card-hascaption + .kg-width-full) {
margin-top: 0;
}
/* [id] represents all headings h1-h6, reset all margins */
.gh-content > [id] {
margin: 0;
@ -1392,6 +1401,14 @@ is the very first element in the post content */
line-height: 1.6em;
}
.page-template .gh-content:only-child > *:first-child:not(.kg-width-full) {
margin-top: max(12vmin, 64px);
}
.page-template .gh-content > *:last-child:not(.kg-width-full) {
margin-bottom: max(12vmin, 64px);
}
.gh-content .kg-callout-card .kg-callout-text,
.gh-content .kg-toggle-card .kg-toggle-content > ol,
.gh-content .kg-toggle-card .kg-toggle-content > ul,
@ -1524,11 +1541,9 @@ make sure they look good, and are given a bit of extra spacing. */
except for when immediately preceeded by a heading */
.gh-content :not(.kg-card):not([id]) + .kg-card {
margin-top: 6vmin;
margin-bottom: 0;
}
.gh-content .kg-card + :not(.kg-card) {
margin-top: 6vmin;
margin-bottom: 0;
}
/* This keeps small embeds centered */
@ -2032,6 +2047,10 @@ iframe.instagram-media + script + :not([id]) {
background: color-mod(var(--color-darkgrey) l(-5%));
}
.page-template .site-footer {
margin-top: 0;
}
.site-footer .inner {
display: grid;
grid-gap: 40px;

View File

@ -2,7 +2,7 @@
"name": "casper",
"description": "A clean, minimal default theme for the Ghost publishing platform",
"demo": "https://demo.ghost.io",
"version": "5.5.2",
"version": "5.6.0",
"engines": {
"ghost": ">=5.0.0"
},

View File

@ -10,30 +10,32 @@ into the {body} tag of the default.hbs template --}}
<main id="site-main" class="site-main">
<article class="article {{post_class}}">
<header class="article-header gh-canvas">
{{#match @page.show_title_and_feature_image}}
<header class="article-header gh-canvas">
<h1 class="article-title">{{title}}</h1>
<h1 class="article-title">{{title}}</h1>
{{#if feature_image}}
<figure class="article-image">
{{!-- This is a responsive image, it loads different sizes depending on device
https://medium.freecodecamp.org/a-guide-to-responsive-images-with-ready-to-use-templates-c400bd65c433 --}}
<img
srcset="{{img_url feature_image size="s"}} 300w,
{{img_url feature_image size="m"}} 600w,
{{img_url feature_image size="l"}} 1000w,
{{img_url feature_image size="xl"}} 2000w"
sizes="(min-width: 1400px) 1400px, 92vw"
src="{{img_url feature_image size="xl"}}"
alt="{{#if feature_image_alt}}{{feature_image_alt}}{{else}}{{title}}{{/if}}"
/>
{{#if feature_image_caption}}
<figcaption>{{feature_image_caption}}</figcaption>
{{/if}}
</figure>
{{/if}}
{{#if feature_image}}
<figure class="article-image">
{{!-- This is a responsive image, it loads different sizes depending on device
https://medium.freecodecamp.org/a-guide-to-responsive-images-with-ready-to-use-templates-c400bd65c433 --}}
<img
srcset="{{img_url feature_image size="s"}} 300w,
{{img_url feature_image size="m"}} 600w,
{{img_url feature_image size="l"}} 1000w,
{{img_url feature_image size="xl"}} 2000w"
sizes="(min-width: 1400px) 1400px, 92vw"
src="{{img_url feature_image size="xl"}}"
alt="{{#if feature_image_alt}}{{feature_image_alt}}{{else}}{{title}}{{/if}}"
/>
{{#if feature_image_caption}}
<figcaption>{{feature_image_caption}}</figcaption>
{{/if}}
</figure>
{{/if}}
</header>
</header>
{{/match}}
<section class="gh-content gh-canvas">
{{content}}