Skip to content

Commit

Permalink
release v3.0.0, support Ghost v1.x
Browse files Browse the repository at this point in the history
  • Loading branch information
serenader2014 committed Aug 24, 2017
1 parent 9ba943d commit a3ac2ab
Show file tree
Hide file tree
Showing 10 changed files with 73 additions and 59 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ Demo: [my blog](https://blog.serenader.me)

![screenshot](screenshot/homepage.jpg)

## Compatibility

Since v3.x this theme is fully support Ghost v1.x, and will no longer compatible with Ghost v0.x version. If you want to use this theme under Ghost v0.x version, please look at previous release, all v2.x and v1.x release should work well under Ghost v0.8 ~ Ghost v0.11. If you want to hack into the source code, please checkout the `ghost-v0.x` branch. The master branch will reflects the latest development.

## Screenshot

Moved to [docs/screenshot.md](docs/screenshot.md)
Expand Down Expand Up @@ -41,10 +45,6 @@ This theme support some custom styles, it enable you to write some cool styles i

See [docs/configuration.md](docs/configuration.md).

## Compatibility

decent theme works great with Ghost `>= v0.8 && < v1.0`. The frontend code works great in modern browser.

## Development

- Fork this project, and clone it to Ghost theme's folder.
Expand Down
6 changes: 3 additions & 3 deletions author.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@

{{! Everything inside the #author tags pulls data from the author }}
{{#author}}
<section class="author-profile" {{#if cover}}style="background-image:url('{{cover}}')"{{/if}}>
<section class="author-profile" {{#if cover_image}}style="background-image:url('{{cover_image}}')"{{/if}}>
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>
<div class="author-info">
<figure class="author-image {{#if cover}}has-cover{{/if}}">
<div class="img image-bg" style="background-image: url({{image}})"><span class="hidden">{{name}}'s Picture</span></div>
<figure class="author-image {{#if cover_image}}has-cover{{/if}}">
<div class="img image-bg" style="background-image: url({{img_url profile_image}})"><span class="hidden">{{name}}'s Picture</span></div>
</figure>
<h1 class="author-title">{{name}}</h1>
{{#if bio}}
Expand Down
1 change: 0 additions & 1 deletion default.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

{{! Page Meta }}
<title>{{meta_title}}</title>
<meta name="description" content="{{meta_description}}" />

<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
Expand Down
2 changes: 1 addition & 1 deletion index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@


{{! The big featured header }}
<header class="main-header detail-page image-bg {{#if @blog.cover}}has-cover" style="background-image: url({{@blog.cover}}){{else}}no-cover{{/if}}">
<header class="main-header detail-page image-bg {{#if @blog.cover_image}}has-cover" style="background-image: url({{@blog.cover_image}}){{else}}no-cover{{/if}}">
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>

<h1 class="page-title"><a href="{{@blog.url}}">{{@blog.title}}</a></h1>
Expand Down
17 changes: 16 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"name": "decent",
"version": "2.1.2",
"version": "3.0.0",
"description": "Simple, responsive, well-designed ghost theme",
"devDependencies": {
"browser-sync": "^2.12.8",
"gulp": "^3.9.1",
Expand All @@ -9,5 +10,19 @@
"gulp-sass": "^2.3.1",
"gulp-uglify": "^1.5.3",
"gulp-zip": "^3.2.0"
},
"scripts": {
"dev": "gulp"
},
"engines": {
"ghost": ">=1.0.0"
},
"license": "MIT",
"author": {
"email": "[email protected]",
"name": "serenader"
},
"config": {
"posts_per_page": 10
}
}
6 changes: 3 additions & 3 deletions page-about.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
{{#post}}
{{! Everything inside the #author tags pulls data from the author }}
{{#author}}
<section class="author-profile" {{#if cover}}style="background-image:url('{{cover}}')"{{/if}}>
<section class="author-profile" {{#if cover_image}}style="background-image:url('{{cover_image}}')"{{/if}}>
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>
<div class="author-info">
<figure class="author-image {{#if cover}}has-cover{{/if}}">
<div class="img image-bg" style="background-image: url({{image}})"><span class="hidden">{{name}}'s Picture</span></div>
<figure class="author-image {{#if cover_image}}has-cover{{/if}}">
<div class="img image-bg" style="background-image: url({{img_url profile_image}})"><span class="hidden">{{name}}'s Picture</span></div>
</figure>
<h1 class="author-title">{{name}}</h1>
{{#if bio}}
Expand Down
8 changes: 4 additions & 4 deletions page.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{{! Everything inside the #post tags pulls data from the page }}
{{#post}}

<header class="main-header detail-page image-bg post-head {{#if image}}has-cover" style="background-image: url({{image}}){{else}}no-cover{{/if}}">
<header class="main-header detail-page image-bg post-head {{#if feature_image}}has-cover" style="background-image: url({{img_url feature_image}}){{else}}no-cover{{/if}}">
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>
<h1 class="page-title"><a href="{{@blog.url}}">{{@blog.title}}</a></h1>
<h2 class="page-description">{{@blog.description}}</h2>
Expand All @@ -30,9 +30,9 @@
{{! Everything inside the #author tags pulls data from the author }}
{{#author}}

{{#if image}}
{{#if profile_image}}
<div class="author-image">
<a class="img image-bg" href="{{url}}" style="background-image: url({{image}})"><span class="hidden">{{name}}'s Picture</span></a>
<a class="img image-bg" href="{{url}}" style="background-image: url({{img_url profile_image}})"><span class="hidden">{{name}}'s Picture</span></a>
</div>
{{/if}}

Expand Down Expand Up @@ -104,7 +104,7 @@
</div>
</div>
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
<div class="pswp__share-tooltip"></div>
<div class="pswp__share-tooltip"></div>
</div>
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
</button>
Expand Down
10 changes: 5 additions & 5 deletions post.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{{! Everything inside the #post tags pulls data from the post }}
{{#post}}

<header class="main-header image-bg detail-page {{#if image}}has-cover" style="background-image: url({{image}}){{else}}no-cover{{/if}}">
<header class="main-header image-bg detail-page {{#if feature_image}}has-cover" style="background-image: url({{img_url feature_image}}){{else}}no-cover{{/if}}">
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>
<h1 class="page-title"><a href="{{@blog.url}}">{{@blog.title}}</a></h1>
<h2 class="page-description">{{@blog.description}}</h2>
Expand All @@ -20,7 +20,7 @@
<header class="post-header short-diver">
<h1 class="post-title">{{title}}</h1>
<section class="post-meta">
Published at <time class="post-date" datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMMM YYYY"}}</time>,
Published at <time class="post-date" datetime="{{date format='YYYY-MM-DD'}}">{{date format="DD MMMM YYYY"}}</time>,
updated at <time class="post-date" datetime="{{date updated_at format='YYYY-MM-DD'}}">{{date updated_at format="DD MMMM YYYY"}}</time>
<br>
{{tags prefix=" on "}}
Expand All @@ -36,9 +36,9 @@
{{! Everything inside the #author tags pulls data from the author }}
{{#author}}

{{#if image}}
{{#if profile_image}}
<div class="author-image">
<a class="img image-bg" href="{{url}}" style="background-image: url({{image}})"><span class="hidden">{{name}}'s Picture</span></a>
<a class="img image-bg" href="{{url}}" style="background-image: url({{img_url profile_image}})"><span class="hidden">{{name}}'s Picture</span></a>
</div>
{{/if}}

Expand Down Expand Up @@ -124,7 +124,7 @@
</div>
</div>
<div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap">
<div class="pswp__share-tooltip"></div>
<div class="pswp__share-tooltip"></div>
</div>
<button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)">
</button>
Expand Down
72 changes: 36 additions & 36 deletions src/style/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -199,42 +199,42 @@
.post-list .post,
.pagination,
.site-footer,
.single-post .post-content > h1,
.single-post .post-content > h2,
.single-post .post-content > h3,
.single-post .post-content > h4,
.single-post .post-content > h5,
.single-post .post-content > h6,
.single-post .post-content > p,
.single-post .post-content > ul,
.single-post .post-content > ol,
.single-post .post-content > blockquote,
.single-post .post-content .single-post-header,
.single-post .post-content > table,
.single-post .post-content > address,
.single-post .post-content > article,
.single-post .post-content > aside,
.single-post .post-content > canvas,
.single-post .post-content > dd,
.single-post .post-content > dl,
.single-post .post-content > fieldset,
.single-post .post-content > figcaption,
.single-post .post-content > figure,
.single-post .post-content > footer,
.single-post .post-content > form,
.single-post .post-content > header,
.single-post .post-content > hgroup,
.single-post .post-content > li,
.single-post .post-content > main,
.single-post .post-content > nav,
.single-post .post-content > noscript,
.single-post .post-content > output,
.single-post .post-content > section,
.single-post .post-content > tfoot,
.single-post .post-content > video,
.single-post .post-content > iframe,
.single-post .post-content > .tip,
.single-post .post-content > .preface,
.single-post .kg-card-markdown > h1,
.single-post .kg-card-markdown > h2,
.single-post .kg-card-markdown > h3,
.single-post .kg-card-markdown > h4,
.single-post .kg-card-markdown > h5,
.single-post .kg-card-markdown > h6,
.single-post .kg-card-markdown > p,
.single-post .kg-card-markdown > ul,
.single-post .kg-card-markdown > ol,
.single-post .kg-card-markdown > blockquote,
.single-post .kg-card-markdown .single-post-header,
.single-post .kg-card-markdown > table,
.single-post .kg-card-markdown > address,
.single-post .kg-card-markdown > article,
.single-post .kg-card-markdown > aside,
.single-post .kg-card-markdown > canvas,
.single-post .kg-card-markdown > dd,
.single-post .kg-card-markdown > dl,
.single-post .kg-card-markdown > fieldset,
.single-post .kg-card-markdown > figcaption,
.single-post .kg-card-markdown > figure,
.single-post .kg-card-markdown > footer,
.single-post .kg-card-markdown > form,
.single-post .kg-card-markdown > header,
.single-post .kg-card-markdown > hgroup,
.single-post .kg-card-markdown > li,
.single-post .kg-card-markdown > main,
.single-post .kg-card-markdown > nav,
.single-post .kg-card-markdown > noscript,
.single-post .kg-card-markdown > output,
.single-post .kg-card-markdown > section,
.single-post .kg-card-markdown > tfoot,
.single-post .kg-card-markdown > video,
.single-post .kg-card-markdown > iframe,
.single-post .kg-card-markdown > .tip,
.single-post .kg-card-markdown > .preface,
.read-next,
.load-comments {
width: 90%;
Expand Down
2 changes: 1 addition & 1 deletion tag.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{{! The tag above means - insert everything in this file into the {body} of the default.hbs template }}

{{! If we have a tag cover, display that - else blog cover - else nothing }}
<header class="main-header tag-head detail-page image-bg {{#if tag.image}}has-cover" style="background-image: url({{tag.image}}){{else}}{{#if @blog.cover}}has-cover" style="background-image: url({{@blog.cover}}){{else}}no-cover{{/if}}{{/if}}">
<header class="main-header tag-head detail-page image-bg {{#if tag.feature_image}}has-cover" style="background-image: url({{tag.feature_image}}){{else}}{{#if @blog.cover_image}}has-cover" style="background-image: url({{@blog.cover_image}}){{else}}no-cover{{/if}}{{/if}}">
<a href="{{@blog.url}}" class="go-home-page" style="background-image:url({{#if @blog.logo}}{{@blog.logo}}{{else}}{{asset "/assets/go-home.png"}}{{/if}}")></a>
<h1 class="page-title">{{tag.name}}</h1>
<h2 class="page-description">
Expand Down

0 comments on commit a3ac2ab

Please sign in to comment.