Permalink
Browse files

Made the theme translatable

Inserted lang attribute on html element and insertet translation helper tags where the theme provides strings. Generated English and Norwegian translation files
  • Loading branch information...
arthurnoerve committed Mar 17, 2018
1 parent c99e449 commit 56258b47d06ec0d312342b202b6f0aba87a7abd3
Showing with 4,328 additions and 49 deletions.
  1. +1,738 −2 assets/css/style.css
  2. +1 −1 assets/js/script.js
  3. +5 −5 author.hbs
  4. +7 −7 default.hbs
  5. +5 −5 index.hbs
  6. +21 −0 locales/en.json
  7. +21 −0 locales/no.json
  8. +2,501 −0 package-lock.json
  9. +5 −5 page.hbs
  10. +2 −2 partials/loop.hbs
  11. +5 −5 partials/navigation.hbs
  12. +3 −3 partials/pagination.hbs
  13. +7 −7 post.hbs
  14. +7 −7 tag.hbs

Large diffs are not rendered by default.

Oops, something went wrong.

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -6,16 +6,16 @@
<nav id="navigation">
{{#if @blog.logo}}
<span class="blog-logo">
<a href="{{@blog.url}}"><img src="{{@blog.logo}}" alt="Blog Logo" /></a>
<a href="{{@blog.url}}"><img src="{{@blog.logo}}" alt="{{t "Blog Logo"}}" /></a>
</span>
{{else}}
<span id="home-button" class="nav-button">
<a class="home-button" href="{{@blog.url}}" title="Home"><i class="ic ic-arrow-left"></i> Home</a>
<a class="home-button" href="{{@blog.url}}" title="{{t "Home"}}"><i class="ic ic-arrow-left"></i> {{t "Home"}}</a>
</span>
{{/if}}
{{#if @blog.navigation}}
<span id="menu-button" class="nav-button">
<a class="menu-button"><i class="ic ic-menu"></i> Menu</a>
<a class="menu-button"><i class="ic ic-menu"></i> {{t "Menu"}}</a>
</span>
{{/if}}
</nav>
@@ -43,12 +43,12 @@
{{#if bio}}
<p class="post-author-about">{{{bio}}}</p>
{{/if}}
<span class="post-author-stats"><i class="ic ic-pencil"></i> {{plural ../pagination.total empty='No Posts' singular='% Post' plural='% Posts'}}</span>
<span class="post-author-stats"><i class="ic ic-pencil"></i> {{plural ../pagination.total empty=(t 'No Posts') singular=(t '% Post') plural=(t '% Posts')}}</span>
{{#if location}}
<span class="post-author-location"><i class="ic ic-location"></i> {{location}}</span>
{{/if}}
{{#if website}}
<span class="post-author-website"><i class="ic ic-link"></i> <a href="{{website}}">Website</a></span>
<span class="post-author-website"><i class="ic ic-link"></i> <a href="{{website}}">{{t "Website"}}</a></span>
{{/if}}
{{#if twitter}}
<span class="post-author-twitter"><i class="ic ic-twitter"></i> <a target="_blank" href="https://twitter.com/{{twitter}}">Twitter</a></span>
@@ -1,5 +1,5 @@
<!DOCTYPE html>
<html>
<html lang="{{lang}}">
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
@@ -15,19 +15,19 @@
</head>
<body class="{{body_class}}">
{{navigation}}
<section id="wrapper">
<a class="hidden-close"></a>
{{{body}}}
<div id="body-class" style="display: none;" class="{{body_class}}"></div>
<footer id="footer">
<div class="inner">
<section class="credits">
<span class="credits-theme">Theme <a href="https://github.com/zutrinken/attila">Attila</a> by <a href="http://zutrinken.com" rel="nofollow">zutrinken</a></span>
<span class="credits-software">Published with <a href="http://ghost.org">Ghost</a></span>
<span class="credits-theme">{{t "Theme" }} <a href="https://github.com/zutrinken/attila">Attila</a> {{t "by"}} <a href="http://zutrinken.com" rel="nofollow">zutrinken</a></span>
<span class="credits-software">{{t "Published with"}} <a href="http://ghost.org">Ghost</a></span>
</section>
</div>
</footer>
@@ -38,4 +38,4 @@
{{ghost_foot}}
</body>
</html>
</html>
@@ -4,12 +4,12 @@
<nav id="navigation">
{{#if @blog.logo}}
<span class="blog-logo">
<a href="{{@blog.url}}"><img src="{{@blog.logo}}" alt="Blog Logo" /></a>
<a href="{{@blog.url}}"><img src="{{@blog.logo}}" alt="{{t "Blog Logo"}}" /></a>
</span>
{{/if}}
{{#if @blog.navigation}}
<span id="menu-button" class="nav-button">
<a class="menu-button"><i class="ic ic-menu"></i> Menu</a>
<a class="menu-button"><i class="ic ic-menu"></i> {{t "Menu"}}</a>
</span>
{{/if}}
</nav>
@@ -26,9 +26,9 @@
<div id="index" class="container">
<main class="content" role="main">
{{> "loop"}}
</main>
</div>
</div>
@@ -0,0 +1,21 @@
{
"% Post": "% Post",
"% Posts": "% Posts",
"Blog Logo": "Blog Logo",
"Close": "Close",
"Get the latest posts delivered right to your inbox.": "Get the latest posts delivered right to your inbox.",
"Home": "Home",
"Menu": "Menu",
"Newer Posts": "Newer Posts",
"No Posts": "No Posts",
"Older Posts": "Older Posts",
"Posts": "Posts",
"Published with": "Published with",
"Show Comments": "Show Comments",
"Subscribe": "Subscribe",
"Theme": "Theme",
"Website": "Website",
"Your email address": "Your email address",
"by": "by",
"on ": "on "
}
@@ -0,0 +1,21 @@
{
"% Post": "% innlegg",
"% Posts": "% innlegg",
"Blog Logo": "Blogg logo",
"Close": "Lukk",
"Get the latest posts delivered right to your inbox.": "Få de siste innleggene rett i innboksen",
"Home": "Hjem",
"Menu": "Meny",
"Newer Posts": "Nyere",
"No Posts": "Ingen innlegg",
"Older Posts": "Gamlere",
"Posts": "Innlegg",
"Published with": "Publisert med",
"Show Comments": "Vis kommentarer",
"Subscribe": "Abonner",
"Theme": "Tema",
"Website": "Nettside",
"Your email address": "Din e-post adresse",
"by": "av",
"on ": "i "
}
Oops, something went wrong.

0 comments on commit 56258b4

Please sign in to comment.