mirror of
https://github.com/GenZmeY/casper-i18n.git
synced 2025-07-13 17:26:08 +00:00
Compare commits
79 Commits
Author | SHA1 | Date | |
---|---|---|---|
a6a5d1eba1 | |||
fa8cc4cf2e | |||
e4faa3141a | |||
1e0e813931 | |||
0d1cf89cc0 | |||
9ac38156da | |||
fc8cf0b2f4 | |||
7e3e891338 | |||
69f5108a39 | |||
44fa55be19 | |||
df4bfbffb2 | |||
bcfbc21b8e | |||
41330614cd | |||
069280eea2 | |||
52f763859a | |||
e3fd4d707e | |||
854880747d | |||
6b9df8bb51 | |||
1360ed83bd | |||
adfb47009e | |||
4752bf03c9 | |||
a17155a3b6 | |||
a1bf3f3823 | |||
d063fb2806 | |||
4a6dfa8e04 | |||
e4a5e96d06 | |||
35e68f6d3f | |||
f631f874f7 | |||
74d787831e | |||
739deb3e4d | |||
bc3e072d31 | |||
838c4ecca2 | |||
7a61bf55ed | |||
9baffdd03f | |||
30ccbca28a | |||
def78b102b | |||
dfb6444b25 | |||
4c298b97cf | |||
6c8a048bad | |||
fd02a6c722 | |||
493da38cff | |||
19cf4adb74 | |||
daa69cbd31 | |||
267fd00802 | |||
8fefeca41b | |||
45f5c83118 | |||
c3cb51711a | |||
3d189760a8 | |||
8087366537 | |||
7748f8c781 | |||
8783bd4ee8 | |||
006b056adc | |||
fe690d4048 | |||
c3c0374ca6 | |||
0429f85774 | |||
1f8df12a7c | |||
75e68ce5b7 | |||
fa15a48192 | |||
0c36dc5235 | |||
aa3c83ec35 | |||
38481aac9a | |||
0052c2ddc3 | |||
9d12bc32f0 | |||
cb674ab56c | |||
c86ee63b86 | |||
b92f18e55a | |||
827940c836 | |||
db0af7f759 | |||
af87b9b3b0 | |||
ec03acff02 | |||
fa48995326 | |||
6350790798 | |||
ab521da23a | |||
91185016eb | |||
0af8d2d8bc | |||
f50f663ef7 | |||
a467e31457 | |||
807018ca97 | |||
ce9918de2f |
7
.github/workflows/deploy-theme.yml
vendored
7
.github/workflows/deploy-theme.yml
vendored
@ -1,14 +1,15 @@
|
|||||||
name: Deploy Theme
|
name: Deploy Theme
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
|
- main
|
||||||
jobs:
|
jobs:
|
||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: TryGhost/action-deploy-theme@v1.2.1
|
- uses: TryGhost/action-deploy-theme@v1.4.1
|
||||||
with:
|
with:
|
||||||
api-url: ${{ secrets.GHOST_ADMIN_API_URL }}
|
api-url: ${{ secrets.GHOST_ADMIN_API_URL }}
|
||||||
api-key: ${{ secrets.GHOST_ADMIN_API_KEY }}
|
api-key: ${{ secrets.GHOST_ADMIN_API_KEY }}
|
||||||
|
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@ -10,6 +10,6 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.event_name == 'push' || (github.event_name == 'pull_request' && !startsWith(github.head_ref, 'renovate/'))
|
if: github.event_name == 'push' || (github.event_name == 'pull_request' && !startsWith(github.head_ref, 'renovate/'))
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v1
|
- uses: actions/checkout@v2
|
||||||
- run: yarn
|
- run: yarn
|
||||||
- run: yarn test:ci
|
- run: yarn test:ci
|
||||||
|
2
LICENSE
2
LICENSE
@ -1,4 +1,4 @@
|
|||||||
Copyright (c) 2013-2020 Ghost Foundation
|
Copyright (c) 2013-2021 Ghost Foundation
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person
|
Permission is hereby granted, free of charge, to any person
|
||||||
obtaining a copy of this software and associated documentation
|
obtaining a copy of this software and associated documentation
|
||||||
|
@ -12,7 +12,7 @@ The default theme for [Ghost](http://github.com/tryghost/ghost/). This is the la
|
|||||||
|
|
||||||
Ghost uses a simple templating language called [Handlebars](http://handlebarsjs.com/) for its themes.
|
Ghost uses a simple templating language called [Handlebars](http://handlebarsjs.com/) for its themes.
|
||||||
|
|
||||||
This theme has lots of code comments to help explain what's going on just by reading the code. Once you feel comfortable with how everything works, we also have full [theme API documentation](https://ghost.org/docs/api/handlebars-themes/) which explains every possible Handlebars helper and template.
|
This theme has lots of code comments to help explain what's going on just by reading the code. Once you feel comfortable with how everything works, we also have full [theme API documentation](https://ghost.org/docs/themes/) which explains every possible Handlebars helper and template.
|
||||||
|
|
||||||
**The main files are:**
|
**The main files are:**
|
||||||
|
|
||||||
@ -66,4 +66,4 @@ You can add your own SVG icons in the same manner.
|
|||||||
|
|
||||||
# Copyright & License
|
# Copyright & License
|
||||||
|
|
||||||
Copyright (c) 2013-2020 Ghost Foundation - Released under the [MIT license](LICENSE).
|
Copyright (c) 2013-2021 Ghost Foundation - Released under the [MIT license](LICENSE).
|
||||||
|
@ -4,6 +4,6 @@ Potential security vulnerabilities can be reported directly us at `security@ghos
|
|||||||
|
|
||||||
The full, up-to-date details of our security policy and procedure can always be found in our documentation:
|
The full, up-to-date details of our security policy and procedure can always be found in our documentation:
|
||||||
|
|
||||||
https://ghost.org/docs/concepts/security/
|
https://ghost.org/docs/security/
|
||||||
|
|
||||||
Please refer to this before emailing us. Thanks for helping make Ghost safe for everyone 🙏.
|
Please refer to this before emailing us. Thanks for helping make Ghost safe for everyone 🙏.
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
!function(o){"use strict";o.fn.fitVids=function(e){var t,i,n={customSelector:null,ignore:null};return document.getElementById("fit-vids-style")||(t=document.head||document.getElementsByTagName("head")[0],(i=document.createElement("div")).innerHTML='<p>x</p><style id="fit-vids-style">.fluid-width-video-container{flex-grow: 1;width:100%;}.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}</style>',t.appendChild(i.childNodes[1])),e&&o.extend(n,e),this.each(function(){var e=['iframe[src*="player.vimeo.com"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="kickstarter.com"][src*="video.html"]',"object","embed"];n.customSelector&&e.push(n.customSelector);var r=".fitvidsignore";n.ignore&&(r=r+", "+n.ignore);var t=o(this).find(e.join(","));(t=(t=t.not("object object")).not(r)).each(function(){var e,t,i=o(this);0<i.parents(r).length||"embed"===this.tagName.toLowerCase()&&i.parent("object").length||i.parent(".fluid-width-video-wrapper").length||(i.css("height")||i.css("width")||!isNaN(i.attr("height"))&&!isNaN(i.attr("width"))||(i.attr("height",9),i.attr("width",16)),e=("object"===this.tagName.toLowerCase()||i.attr("height")&&!isNaN(parseInt(i.attr("height"),10))?parseInt(i.attr("height"),10):i.height())/(isNaN(parseInt(i.attr("width"),10))?i.width():parseInt(i.attr("width"),10)),i.attr("name")||(t="fitvid"+o.fn.fitVids._count,i.attr("name",t),o.fn.fitVids._count++),i.wrap('<div class="fluid-width-video-container"><div class="fluid-width-video-wrapper"></div></div>').parent(".fluid-width-video-wrapper").css("padding-top",100*e+"%"),i.removeAttr("height").removeAttr("width"))})})},o.fn.fitVids._count=0}(window.jQuery||window.Zepto),function(e){e.addEventListener("DOMContentLoaded",function(){e.querySelectorAll(".kg-gallery-image img").forEach(function(e){var t=e.closest(".kg-gallery-image"),i=e.attributes.width.value/e.attributes.height.value;t.style.flex=i+" 1 0%"})})}((window,document)),function(t,i){var r,n,o,s,a,d,l,c=i.querySelector("link[rel=next]");function u(){if(404===this.status)return t.removeEventListener("scroll",f),void t.removeEventListener("resize",v);this.response.querySelectorAll(".post-card").forEach(function(e){r.appendChild(i.importNode(e,!0))});var e=this.response.querySelector("link[rel=next]");e?c.href=e.href:(t.removeEventListener("scroll",f),t.removeEventListener("resize",v)),l=i.documentElement.scrollHeight,s=o=!1}function e(){var e;s||(a+d<=l-n?o=!1:(s=!0,(e=new t.XMLHttpRequest).responseType="document",e.addEventListener("load",u),e.open("GET",c.href),e.send(null)))}function h(){o||t.requestAnimationFrame(e),o=!0}function f(){a=t.scrollY,h()}function v(){d=t.innerHeight,l=i.documentElement.scrollHeight,h()}!c||(r=i.querySelector(".post-feed"))&&(s=o=!(n=300),a=t.scrollY,d=t.innerHeight,l=i.documentElement.scrollHeight,t.addEventListener("scroll",f,{passive:!0}),t.addEventListener("resize",v),h())}(window,document),function(s,a){s.Casper||(s.Casper={}),s.Casper.stickyNavTitle=function(e){var t=a.querySelector(e.navSelector),i=a.querySelector(e.titleSelector),r=s.scrollY,n=!1;function o(){i.getBoundingClientRect().top+s.scrollY+(i.offsetHeight+35)<=r?t.classList.add(e.activeClass):t.classList.remove(e.activeClass),n=!1}s.addEventListener("scroll",function(){r=s.scrollY,function(){n||requestAnimationFrame(o);n=!0}()},{passive:!0}),o()}}(window,document);
|
!function(o){"use strict";o.fn.fitVids=function(e){var t,i,n={customSelector:null,ignore:null};return document.getElementById("fit-vids-style")||(t=document.head||document.getElementsByTagName("head")[0],(i=document.createElement("div")).innerHTML='<p>x</p><style id="fit-vids-style">.fluid-width-video-container{flex-grow: 1;width:100%;}.fluid-width-video-wrapper{width:100%;position:relative;padding:0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position:absolute;top:0;left:0;width:100%;height:100%;}</style>',t.appendChild(i.childNodes[1])),e&&o.extend(n,e),this.each(function(){var e=['iframe[src*="player.vimeo.com"]','iframe[src*="youtube.com"]','iframe[src*="youtube-nocookie.com"]','iframe[src*="kickstarter.com"][src*="video.html"]',"object","embed"];n.customSelector&&e.push(n.customSelector);var r=".fitvidsignore";n.ignore&&(r=r+", "+n.ignore);e=o(this).find(e.join(","));(e=(e=e.not("object object")).not(r)).each(function(){var e,t,i=o(this);0<i.parents(r).length||"embed"===this.tagName.toLowerCase()&&i.parent("object").length||i.parent(".fluid-width-video-wrapper").length||(i.css("height")||i.css("width")||!isNaN(i.attr("height"))&&!isNaN(i.attr("width"))||(i.attr("height",9),i.attr("width",16)),e=("object"===this.tagName.toLowerCase()||i.attr("height")&&!isNaN(parseInt(i.attr("height"),10))?parseInt(i.attr("height"),10):i.height())/(isNaN(parseInt(i.attr("width"),10))?i.width():parseInt(i.attr("width"),10)),i.attr("name")||(t="fitvid"+o.fn.fitVids._count,i.attr("name",t),o.fn.fitVids._count++),i.wrap('<div class="fluid-width-video-container"><div class="fluid-width-video-wrapper"></div></div>').parent(".fluid-width-video-wrapper").css("padding-top",100*e+"%"),i.removeAttr("height").removeAttr("width"))})})},o.fn.fitVids._count=0}(window.jQuery||window.Zepto),function(e){e.addEventListener("DOMContentLoaded",function(){e.querySelectorAll(".kg-gallery-image img").forEach(function(e){var t=e.closest(".kg-gallery-image"),e=e.attributes.width.value/e.attributes.height.value;t.style.flex=e+" 1 0%"})})}((window,document)),function(t,i){var r,n,o,s,a,d,l,c=i.querySelector("link[rel=next]");function u(){if(404===this.status)return t.removeEventListener("scroll",f),void t.removeEventListener("resize",v);this.response.querySelectorAll(".post-card").forEach(function(e){r.appendChild(i.importNode(e,!0))});var e=this.response.querySelector("link[rel=next]");e?c.href=e.href:(t.removeEventListener("scroll",f),t.removeEventListener("resize",v)),l=i.documentElement.scrollHeight,s=o=!1}function e(){var e;s||(a+d<=l-n?o=!1:(s=!0,(e=new t.XMLHttpRequest).responseType="document",e.addEventListener("load",u),e.open("GET",c.href),e.send(null)))}function h(){o||t.requestAnimationFrame(e),o=!0}function f(){a=t.scrollY,h()}function v(){d=t.innerHeight,l=i.documentElement.scrollHeight,h()}!c||(r=i.querySelector(".post-feed"))&&(s=o=!(n=300),a=t.scrollY,d=t.innerHeight,l=i.documentElement.scrollHeight,t.addEventListener("scroll",f,{passive:!0}),t.addEventListener("resize",v),h())}(window,document),function(s,a){s.Casper||(s.Casper={}),s.Casper.stickyNavTitle=function(e){var t=a.querySelector(e.navSelector),i=a.querySelector(e.titleSelector),r=s.scrollY,n=!1;function o(){i.getBoundingClientRect().top+s.scrollY+(i.offsetHeight+35)<=r?t.classList.add(e.activeClass):t.classList.remove(e.activeClass),n=!1}s.addEventListener("scroll",function(){r=s.scrollY,n||requestAnimationFrame(o),n=!0},{passive:!0}),o()}}(window,document);
|
||||||
//# sourceMappingURL=casper.js.map
|
//# sourceMappingURL=casper.js.map
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1256,6 +1256,10 @@ Usage (In Ghost editor):
|
|||||||
margin-top: 1.2em;
|
margin-top: 1.2em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.post-full-content [id] {
|
||||||
|
scroll-margin-top: 110px;
|
||||||
|
}
|
||||||
|
|
||||||
.post-full-content h1,
|
.post-full-content h1,
|
||||||
.post-full-content h2,
|
.post-full-content h2,
|
||||||
.post-full-content h3,
|
.post-full-content h3,
|
||||||
@ -2263,9 +2267,9 @@ Usage (In Ghost editor):
|
|||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
margin-top: 14px;
|
margin-top: 14px;
|
||||||
color: color-mod(var(--midgrey) l(-10%));
|
color: var(--darkgrey);
|
||||||
font-size: 1.5rem;
|
font-size: 1.5rem;
|
||||||
font-weight: 400;
|
font-weight: 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content .kg-bookmark-icon {
|
.post-full-content .kg-bookmark-icon {
|
||||||
@ -2289,6 +2293,8 @@ Usage (In Ghost editor):
|
|||||||
line-height: 1.5em;
|
line-height: 1.5em;
|
||||||
text-overflow: ellipsis;
|
text-overflow: ellipsis;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
|
color: color-mod(var(--midgrey) l(-10%));
|
||||||
|
font-weight: 400;
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (max-width: 800px) {
|
@media (max-width: 800px) {
|
||||||
@ -2584,7 +2590,7 @@ Usage (In Ghost editor):
|
|||||||
/* 10. Subscribe Message and Overlay
|
/* 10. Subscribe Message and Overlay
|
||||||
/* ---------------------------------------------------------- */
|
/* ---------------------------------------------------------- */
|
||||||
|
|
||||||
.subscribe-success-message {
|
.subscribe-notification {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
@ -2598,17 +2604,41 @@ Usage (In Ghost editor):
|
|||||||
transform: translateY(-175%);
|
transform: translateY(-175%);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.subscribe-notification.subscribe-failure-message {
|
||||||
|
background: var(--red);
|
||||||
|
}
|
||||||
|
|
||||||
.subscribe-success .subscribe-success-message {
|
.subscribe-success .subscribe-success-message {
|
||||||
visibility: visible;
|
visibility: visible;
|
||||||
transform: translateY(0);
|
transform: translateY(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-success-message.close {
|
.subscribe-failure .subscribe-failure-message {
|
||||||
|
visibility: visible;
|
||||||
|
transform: translateY(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
.subscribe-notification.close {
|
||||||
visibility: hidden;
|
visibility: hidden;
|
||||||
transition: all 1.35s cubic-bezier(0.19, 1, 0.22, 1);
|
transition: all 1.35s cubic-bezier(0.19, 1, 0.22, 1);
|
||||||
transform: translateY(-175%);
|
transform: translateY(-175%);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.subscribe-notification .subscribe-close-button {
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.subscribe-notification .subscribe-close-button:before,
|
||||||
|
.subscribe-notification .subscribe-close-button:after {
|
||||||
|
top: 31px;
|
||||||
|
right: 20px;
|
||||||
|
width: 18px;
|
||||||
|
height: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
.subscribe-close-overlay {
|
.subscribe-close-overlay {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
@ -2860,220 +2890,229 @@ Usage (In Ghost editor):
|
|||||||
/* 12. Dark Mode
|
/* 12. Dark Mode
|
||||||
/* ---------------------------------------------------------- */
|
/* ---------------------------------------------------------- */
|
||||||
@media (prefers-color-scheme: dark) {
|
@media (prefers-color-scheme: dark) {
|
||||||
body {
|
html:not(.no-dark) body {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
html:not(.no-dark) img {
|
||||||
opacity: 0.9;
|
opacity: 0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
.site-header-background:before {
|
html:not(.no-dark) .site-header-background:before {
|
||||||
background: rgba(0,0,0,0.6);
|
background: rgba(0,0,0,0.6);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-feed {
|
html:not(.no-dark) .post-feed {
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card,
|
html:not(.no-dark) .post-card,
|
||||||
.post-card:hover {
|
html:not(.no-dark) .post-card:hover {
|
||||||
border-bottom-color: color-mod(var(--darkmode) l(+8%));
|
border-bottom-color: color-mod(var(--darkmode) l(+8%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.author-profile-image {
|
html:not(.no-dark) .author-profile-image {
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card-byline-content a {
|
html:not(.no-dark) .post-card-byline-content a {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card-byline-content a:hover {
|
html:not(.no-dark) .post-card-byline-content a:hover {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card-image {
|
html:not(.no-dark) .post-card-image {
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card-title {
|
html:not(.no-dark) .post-card-title {
|
||||||
color: rgba(255, 255, 255, 0.85);
|
color: rgba(255, 255, 255, 0.85);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-card-excerpt {
|
html:not(.no-dark) .post-card-excerpt {
|
||||||
color: color-mod(var(--midgrey) l(+10%));
|
color: color-mod(var(--midgrey) l(+10%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.author-avatar,
|
html:not(.no-dark) .author-avatar,
|
||||||
.static-avatar {
|
html:not(.no-dark) .static-avatar {
|
||||||
border-color: color-mod(var(--darkgrey) l(+2%));
|
border-color: color-mod(var(--darkgrey) l(+2%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.site-main,
|
html:not(.no-dark) .site-main,
|
||||||
.post-template .site-main,
|
html:not(.no-dark) .post-template .site-main,
|
||||||
.page-template .site-main {
|
html:not(.no-dark) .page-template .site-main {
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content {
|
html:not(.no-dark) .post-full-content {
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-title {
|
html:not(.no-dark) .post-full-title {
|
||||||
color: rgba(255, 255, 255, 0.9);
|
color: rgba(255, 255, 255, 0.9);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-custom-excerpt {
|
html:not(.no-dark) .post-full-custom-excerpt {
|
||||||
color: color-mod(var(--midgrey) l(+10%));
|
color: color-mod(var(--midgrey) l(+10%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-image {
|
html:not(.no-dark) .post-full-image {
|
||||||
background-color: color-mod(var(--darkmode) l(+8%));
|
background-color: color-mod(var(--darkmode) l(+8%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-byline {
|
html:not(.no-dark) .post-full-byline {
|
||||||
border-top-color: color-mod(var(--darkmode) l(+15%));
|
border-top-color: color-mod(var(--darkmode) l(+15%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-byline-meta h4 a {
|
html:not(.no-dark) .post-full-byline-meta h4 a {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-byline-meta h4 a:hover {
|
html:not(.no-dark) .post-full-byline-meta h4 a:hover {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.author-list-item .author-card {
|
html:not(.no-dark) .author-list-item .author-card {
|
||||||
background: color-mod(var(--darkmode) l(+4%));
|
background: color-mod(var(--darkmode) l(+4%));
|
||||||
box-shadow: 0 12px 26px rgba(0,0,0,0.4);
|
box-shadow: 0 12px 26px rgba(0,0,0,0.4);
|
||||||
}
|
}
|
||||||
|
|
||||||
.author-list-item .author-card:before {
|
html:not(.no-dark) .author-list-item .author-card:before {
|
||||||
border-top-color: color-mod(var(--darkmode) l(+4%));
|
border-top-color: color-mod(var(--darkmode) l(+4%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.no-image .author-social-link a {
|
html:not(.no-dark) .no-image .author-social-link a {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content h1,
|
html:not(.no-dark) .post-full-content h1,
|
||||||
.post-full-content h2,
|
html:not(.no-dark) .post-full-content h2,
|
||||||
.post-full-content h3,
|
html:not(.no-dark) .post-full-content h3,
|
||||||
.post-full-content h4,
|
html:not(.no-dark) .post-full-content h4,
|
||||||
.post-full-content h6 {
|
html:not(.no-dark) .post-full-content h6 {
|
||||||
color: rgba(255, 255, 255, 0.9);
|
color: rgba(255, 255, 255, 0.9);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content a {
|
html:not(.no-dark) .post-full-content a {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
box-shadow: inset 0 -1px 0 #fff;
|
box-shadow: inset 0 -1px 0 #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content strong {
|
html:not(.no-dark) .post-full-content strong {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content em {
|
html:not(.no-dark) .post-full-content em {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content code {
|
html:not(.no-dark) .post-full-content code {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
background: #000;
|
background: #000;
|
||||||
}
|
}
|
||||||
|
|
||||||
hr {
|
html:not(.no-dark) hr {
|
||||||
border-top-color: color-mod(var(--darkmode) l(+8%));
|
border-top-color: color-mod(var(--darkmode) l(+8%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content figcaption {
|
html:not(.no-dark) .post-full-content hr:after {
|
||||||
|
background: color-mod(var(--darkmode) l(+8%));
|
||||||
|
box-shadow: var(--darkmode) 0 0 0 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
html:not(.no-dark) .post-full-content figcaption {
|
||||||
color: rgba(255, 255, 255, 0.6);
|
color: rgba(255, 255, 255, 0.6);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content table td:first-child {
|
html:not(.no-dark) .post-full-content table td:first-child {
|
||||||
background-image: linear-gradient(to right, var(--darkmode) 50%, color-mod(var(--darkmode) a(0%)) 100%);
|
background-image: linear-gradient(to right, var(--darkmode) 50%, color-mod(var(--darkmode) a(0%)) 100%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content table td:last-child {
|
html:not(.no-dark) .post-full-content table td:last-child {
|
||||||
background-image: linear-gradient(to left, var(--darkmode) 50%, color-mod(var(--darkmode) a(0%)) 100%);
|
background-image: linear-gradient(to left, var(--darkmode) 50%, color-mod(var(--darkmode) a(0%)) 100%);
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content table th {
|
html:not(.no-dark) .post-full-content table th {
|
||||||
color: rgba(255, 255, 255, 0.85);
|
color: rgba(255, 255, 255, 0.85);
|
||||||
background-color: color-mod(var(--darkmode) l(+8%));
|
background-color: color-mod(var(--darkmode) l(+8%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content table th,
|
html:not(.no-dark) .post-full-content table th,
|
||||||
.post-full-content table td {
|
html:not(.no-dark) .post-full-content table td {
|
||||||
border: color-mod(var(--darkmode) l(+8%)) 1px solid;
|
border: color-mod(var(--darkmode) l(+8%)) 1px solid;
|
||||||
}
|
}
|
||||||
|
|
||||||
.post-full-content .kg-bookmark-container,
|
html:not(.no-dark) .post-full-content .kg-bookmark-container,
|
||||||
.post-full-content .kg-bookmark-container:hover {
|
html:not(.no-dark) .post-full-content .kg-bookmark-container:hover {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
box-shadow: 0 0 1px rgba(255,255,255,0.9);
|
box-shadow: 0 0 1px rgba(255,255,255,0.9);
|
||||||
}
|
}
|
||||||
|
|
||||||
.kg-bookmark-title {
|
html:not(.no-dark) .post-full-content input {
|
||||||
|
color: color-mod(var(--midgrey) l(-30%));
|
||||||
|
}
|
||||||
|
|
||||||
|
html:not(.no-dark) .kg-bookmark-title {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.kg-bookmark-description {
|
html:not(.no-dark) .kg-bookmark-description {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.kg-bookmark-metadata {
|
html:not(.no-dark) .kg-bookmark-metadata {
|
||||||
color: rgba(255, 255, 255, 0.75);
|
color: rgba(255, 255, 255, 0.75);
|
||||||
}
|
}
|
||||||
|
|
||||||
.site-archive-header .no-image {
|
html:not(.no-dark) .site-archive-header .no-image {
|
||||||
color: rgba(255, 255, 255, 0.9);
|
color: rgba(255, 255, 255, 0.9);
|
||||||
background: var(--darkmode);
|
background: var(--darkmode);
|
||||||
}
|
}
|
||||||
|
|
||||||
.site-archive-header .no-image .site-header-content {
|
html:not(.no-dark) .site-archive-header .no-image .site-header-content {
|
||||||
border-bottom-color: color-mod(var(--darkmode) l(+15%));
|
border-bottom-color: color-mod(var(--darkmode) l(+15%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.site-header-content .author-profile-image {
|
html:not(.no-dark) .site-header-content .author-profile-image {
|
||||||
box-shadow: 0 0 0 6px hsla(0,0%,100%,0.04);
|
box-shadow: 0 0 0 6px hsla(0,0%,100%,0.04);
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form {
|
html:not(.no-dark) .subscribe-form {
|
||||||
border: none;
|
border: none;
|
||||||
background: linear-gradient(color-mod(var(--darkmode) l(-6%)), color-mod(var(--darkmode) l(-3%)));
|
background: linear-gradient(color-mod(var(--darkmode) l(-6%)), color-mod(var(--darkmode) l(-3%)));
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form-title {
|
html:not(.no-dark) .subscribe-form-title {
|
||||||
color: rgba(255, 255, 255, 0.9);
|
color: rgba(255, 255, 255, 0.9);
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form p {
|
html:not(.no-dark) .subscribe-form p {
|
||||||
color: rgba(255, 255, 255, 0.7);
|
color: rgba(255, 255, 255, 0.7);
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-email {
|
html:not(.no-dark) .subscribe-email {
|
||||||
border-color: color-mod(var(--darkmode) l(+6%));
|
border-color: color-mod(var(--darkmode) l(+6%));
|
||||||
color: rgba(255, 255, 255, 0.9);
|
color: rgba(255, 255, 255, 0.9);
|
||||||
background: color-mod(var(--darkmode) l(+3%));
|
background: color-mod(var(--darkmode) l(+3%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-email:focus {
|
html:not(.no-dark) .subscribe-email:focus {
|
||||||
border-color: color-mod(var(--darkmode) l(+25%));
|
border-color: color-mod(var(--darkmode) l(+25%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form button {
|
html:not(.no-dark) .subscribe-form button {
|
||||||
opacity: 0.9;
|
opacity: 0.9;
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form .invalid .message-error,
|
html:not(.no-dark) .subscribe-form .invalid .message-error,
|
||||||
.subscribe-form .error .message-error {
|
html:not(.no-dark) .subscribe-form .error .message-error {
|
||||||
color: color-mod(var(--red) l(+5%) s(-5%));
|
color: color-mod(var(--red) l(+5%) s(-5%));
|
||||||
}
|
}
|
||||||
|
|
||||||
.subscribe-form .success .message-success {
|
html:not(.no-dark) .subscribe-form .success .message-success {
|
||||||
color: color-mod(var(--green) l(+5%) s(-5%));
|
color: color-mod(var(--green) l(+5%) s(-5%));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -49,7 +49,7 @@
|
|||||||
<div class="inner posts">
|
<div class="inner posts">
|
||||||
|
|
||||||
<div class="post-feed">
|
<div class="post-feed">
|
||||||
{{#foreach posts}}
|
{{#foreach posts visibility="all"}}
|
||||||
|
|
||||||
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
||||||
{{> "post-card"}}
|
{{> "post-card"}}
|
||||||
|
27
default.hbs
27
default.hbs
@ -33,7 +33,7 @@
|
|||||||
<a href="{{@site.url}}">Latest Posts</a>
|
<a href="{{@site.url}}">Latest Posts</a>
|
||||||
{{#if @site.facebook}}<a href="{{facebook_url @site.facebook}}" target="_blank" rel="noopener">Facebook</a>{{/if}}
|
{{#if @site.facebook}}<a href="{{facebook_url @site.facebook}}" target="_blank" rel="noopener">Facebook</a>{{/if}}
|
||||||
{{#if @site.twitter}}<a href="{{twitter_url @site.twitter}}" target="_blank" rel="noopener">Twitter</a>{{/if}}
|
{{#if @site.twitter}}<a href="{{twitter_url @site.twitter}}" target="_blank" rel="noopener">Twitter</a>{{/if}}
|
||||||
<a href="https://ghost.org" target="_blank" rel="noopener">Ghost</a>
|
<a href="https://ghost.org/" target="_blank" rel="noopener">Ghost</a>
|
||||||
</nav>
|
</nav>
|
||||||
</div>
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
@ -42,10 +42,14 @@
|
|||||||
|
|
||||||
{{!-- The big email subscribe modal content --}}
|
{{!-- The big email subscribe modal content --}}
|
||||||
{{#if @labs.members}}
|
{{#if @labs.members}}
|
||||||
<div class="subscribe-success-message">
|
<div class="subscribe-notification subscribe-success-message">
|
||||||
<a class="subscribe-close" href="javascript:;"></a>
|
<a class="subscribe-close-button" href="javascript:;"></a>
|
||||||
You've successfully subscribed to {{@site.title}}!
|
You've successfully subscribed to {{@site.title}}!
|
||||||
</div>
|
</div>
|
||||||
|
<div class="subscribe-notification subscribe-failure-message">
|
||||||
|
<a class="subscribe-close-button" href="javascript:;"></a>
|
||||||
|
Could not sign up! Invalid sign up link.
|
||||||
|
</div>
|
||||||
|
|
||||||
<div id="subscribe" class="subscribe-overlay">
|
<div id="subscribe" class="subscribe-overlay">
|
||||||
<a class="subscribe-close-overlay" href="#"></a>
|
<a class="subscribe-close-overlay" href="#"></a>
|
||||||
@ -80,8 +84,8 @@
|
|||||||
|
|
||||||
{{!-- jQuery, required for fitvids --}}
|
{{!-- jQuery, required for fitvids --}}
|
||||||
<script
|
<script
|
||||||
src="https://code.jquery.com/jquery-3.4.1.min.js"
|
src="https://code.jquery.com/jquery-3.5.1.min.js"
|
||||||
integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo="
|
integrity="sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0="
|
||||||
crossorigin="anonymous">
|
crossorigin="anonymous">
|
||||||
</script>
|
</script>
|
||||||
{{!-- Fitvids (for responsive video embeds), infinite scroll, floating header, and gallery card support --}}
|
{{!-- Fitvids (for responsive video embeds), infinite scroll, floating header, and gallery card support --}}
|
||||||
@ -102,14 +106,19 @@
|
|||||||
|
|
||||||
// Give the parameter a variable name
|
// Give the parameter a variable name
|
||||||
var action = getParameterByName('action');
|
var action = getParameterByName('action');
|
||||||
|
var success = getParameterByName('success');
|
||||||
|
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
if (action == 'subscribe') {
|
if (action == 'subscribe' && (success === null || success === 'true')) {
|
||||||
$('body').addClass("subscribe-success");
|
$('body').addClass('subscribe-success');
|
||||||
}
|
}
|
||||||
|
|
||||||
$('.subscribe-success-message .subscribe-close').click(function () {
|
if (action == 'subscribe' && success === 'false') {
|
||||||
$('.subscribe-success-message').addClass('close');
|
$('body').addClass('subscribe-failure');
|
||||||
|
}
|
||||||
|
|
||||||
|
$('.subscribe-notification .subscribe-close-button').click(function () {
|
||||||
|
$('.subscribe-notification').addClass('close');
|
||||||
});
|
});
|
||||||
|
|
||||||
// Reset form on opening subscrion overlay
|
// Reset form on opening subscrion overlay
|
||||||
|
@ -25,7 +25,7 @@ into the {body} of the default.hbs template --}}
|
|||||||
<div class="inner posts">
|
<div class="inner posts">
|
||||||
|
|
||||||
<div class="post-feed">
|
<div class="post-feed">
|
||||||
{{#foreach posts}}
|
{{#foreach posts visibility="all"}}
|
||||||
|
|
||||||
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
||||||
{{> "post-card"}}
|
{{> "post-card"}}
|
||||||
@ -47,7 +47,7 @@ into the {body} of the default.hbs template --}}
|
|||||||
// Dropping the scroll event and using only a raf loop results in smoother
|
// Dropping the scroll event and using only a raf loop results in smoother
|
||||||
// scrolling but continuous processing even when not scrolling
|
// scrolling but continuous processing even when not scrolling
|
||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
|
|
||||||
var nav = document.querySelector('.site-nav-main .site-nav');
|
var nav = document.querySelector('.site-nav-main .site-nav');
|
||||||
var feed = document.querySelector('.post-feed');
|
var feed = document.querySelector('.post-feed');
|
||||||
|
|
||||||
|
19
package.json
19
package.json
@ -2,7 +2,7 @@
|
|||||||
"name": "casper",
|
"name": "casper",
|
||||||
"description": "A clean, minimal default theme for the Ghost publishing platform",
|
"description": "A clean, minimal default theme for the Ghost publishing platform",
|
||||||
"demo": "https://demo.ghost.io",
|
"demo": "https://demo.ghost.io",
|
||||||
"version": "3.1.0",
|
"version": "3.1.3",
|
||||||
"engines": {
|
"engines": {
|
||||||
"ghost": ">=3.0.0",
|
"ghost": ">=3.0.0",
|
||||||
"ghost-api": "v3"
|
"ghost-api": "v3"
|
||||||
@ -25,7 +25,7 @@
|
|||||||
"author": {
|
"author": {
|
||||||
"name": "Ghost Foundation",
|
"name": "Ghost Foundation",
|
||||||
"email": "hello@ghost.org",
|
"email": "hello@ghost.org",
|
||||||
"url": "https://ghost.org"
|
"url": "https://ghost.org/"
|
||||||
},
|
},
|
||||||
"gpm": {
|
"gpm": {
|
||||||
"type": "theme",
|
"type": "theme",
|
||||||
@ -46,18 +46,19 @@
|
|||||||
"bugs": "https://github.com/TryGhost/Casper/issues",
|
"bugs": "https://github.com/TryGhost/Casper/issues",
|
||||||
"contributors": "https://github.com/TryGhost/Casper/graphs/contributors",
|
"contributors": "https://github.com/TryGhost/Casper/graphs/contributors",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@tryghost/release-utils": "0.6.3",
|
"@tryghost/release-utils": "0.6.12",
|
||||||
"autoprefixer": "9.8.6",
|
"autoprefixer": "10.2.5",
|
||||||
"beeper": "2.0.0",
|
"beeper": "2.1.0",
|
||||||
"cssnano": "4.1.10",
|
"cssnano": "4.1.10",
|
||||||
"gscan": "3.5.5",
|
"gscan": "3.6.1",
|
||||||
"gulp": "4.0.2",
|
"gulp": "4.0.2",
|
||||||
"gulp-concat": "2.6.1",
|
"gulp-concat": "2.6.1",
|
||||||
"gulp-livereload": "4.0.2",
|
"gulp-livereload": "4.0.2",
|
||||||
"gulp-postcss": "8.0.0",
|
"gulp-postcss": "9.0.0",
|
||||||
"gulp-uglify": "3.0.2",
|
"gulp-uglify": "3.0.2",
|
||||||
"gulp-zip": "5.0.2",
|
"gulp-zip": "5.1.0",
|
||||||
"inquirer": "7.3.3",
|
"inquirer": "8.0.0",
|
||||||
|
"postcss": "8.2.8",
|
||||||
"postcss-color-mod-function": "3.0.3",
|
"postcss-color-mod-function": "3.0.3",
|
||||||
"postcss-easy-import": "3.0.0",
|
"postcss-easy-import": "3.0.0",
|
||||||
"pump": "3.0.0"
|
"pump": "3.0.0"
|
||||||
|
@ -34,7 +34,11 @@
|
|||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
{{#if @labs.members}}
|
{{#if @labs.members}}
|
||||||
<a class="subscribe-button" href="#subscribe">Subscribe</a>
|
{{#unless @member}}
|
||||||
|
<a class="subscribe-button" href="#subscribe">Subscribe</a>
|
||||||
|
{{else}}
|
||||||
|
<a class="subscribe-button" href="#/portal/account">Account</a>
|
||||||
|
{{/unless}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
2
tag.hbs
2
tag.hbs
@ -23,7 +23,7 @@
|
|||||||
<main id="site-main" class="site-main outer">
|
<main id="site-main" class="site-main outer">
|
||||||
<div class="inner posts">
|
<div class="inner posts">
|
||||||
<div class="post-feed">
|
<div class="post-feed">
|
||||||
{{#foreach posts}}
|
{{#foreach posts visibility="all"}}
|
||||||
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
{{!-- The tag below includes the markup for each post - partials/post-card.hbs --}}
|
||||||
{{> "post-card"}}
|
{{> "post-card"}}
|
||||||
{{/foreach}}
|
{{/foreach}}
|
||||||
|
Reference in New Issue
Block a user