aboutsummaryrefslogtreecommitdiffstats
path: root/site/layouts
diff options
context:
space:
mode:
authorMathias Biilmann <info@mathias-biilmann.net>2017-12-07 10:20:11 -0800
committerGitHub <noreply@github.com>2017-12-07 10:20:11 -0800
commit8745627e7d171b4b1fd2062b4328bf23899663e9 (patch)
tree5f0399bf843f5a3055e0bb6d3da6774b1a01f307 /site/layouts
parent2db9a63c54df63e95c1fbf39391d201c98a62b86 (diff)
parenta4bfd44601069a1b054c396ad754c8a2b7ec688c (diff)
Merge pull request #11 from netlify-templates/update-for-cms-1-0
Update for CMS 1.0
Diffstat (limited to 'site/layouts')
-rw-r--r--site/layouts/contact/single.html34
-rw-r--r--site/layouts/index.html8
-rw-r--r--site/layouts/partials/2-up.html23
-rw-r--r--site/layouts/partials/footer.html8
-rw-r--r--site/layouts/partials/head.html10
-rw-r--r--site/layouts/partials/svg.html2
-rw-r--r--site/layouts/partials/text-and-image.html4
-rw-r--r--site/layouts/section/contact.html26
-rw-r--r--site/layouts/section/products.html (renamed from site/layouts/products/single.html)0
-rw-r--r--site/layouts/section/values.html17
-rw-r--r--site/layouts/values/single.html18
11 files changed, 68 insertions, 82 deletions
diff --git a/site/layouts/contact/single.html b/site/layouts/contact/single.html
deleted file mode 100644
index 07e5ce4..0000000
--- a/site/layouts/contact/single.html
+++ /dev/null
@@ -1,34 +0,0 @@
-{{ partial "head" . }}
-
-{{ partial "nav" . }}
-
-<div class="ph3 bg-off-white">
- <div class="center mw6 pv3">
-
- <img src="/img/logo.svg" alt="" class="db w4 center pv4">
-
- <p>We’d love to get in touch with you and hear your ideas and questions. We strive to grow and improve constantly and your feedback is valuable for us.</p>
-
- <h3 class="f4 b lh-title mb2">How can I get…?</h3>
- <p>You can also use the form below for any inquiries about coffee availability, monthly subscriptions and scheduling a 1-on-1 session with our baristas. Don’t be shy, drop us a line!</p>
-
- <div class="flex-ns mb3">
-
- <div>
- <h4 class="f4 b lh-title mb2 primary">Location</h4>
- <p>3153 Lynn Avenue, South San Francisco, California 94080</p>
- </div>
-
- <div>
- <h4 class="f4 b lh-title mb2 primary">Working hours</h4>
- <p>Monday – Saturday: 9AM – 7PM We’re closed on Sundays</p>
- </div>
-
- </div>
-
- {{ partial "contact-form" . }}
-
- </div>
-</div>
-
-{{ partial "footer" . }}
diff --git a/site/layouts/index.html b/site/layouts/index.html
index e57ce45..a21df24 100644
--- a/site/layouts/index.html
+++ b/site/layouts/index.html
@@ -2,13 +2,13 @@
{{ partial "nav" . }}
-{{ partial "jumbotron" (dict "imageUrl" "/img/home/jumbotron.jpg" "title" "Great coffee with a conscience" "subtitle" "Support sustainable farming while enjoying a cup") }}
+{{ partial "jumbotron" (dict "imageUrl" .Params.image "title" .Title "subtitle" .Params.subtitle) }}
-{{ partial "short-text" (dict "heading" "Why Kaldi?" "text" "Kaldi is the coffee store for everyone who believes that great coffee shouldn't just taste good, it should do good too. We source all of our beans directly from small scale sustainable farmers and make sure part of the profits are reinvested in their communities.")}}
+{{ partial "short-text" .Params.blurb}}
-{{ partial "2-up" (dict "heading" "What we offer" "description" "Kaldi is the ultimate spot for coffee lovers who want to learn about their java’s origin and support the farmers that grew it. We take coffee production, roasting and brewing seriously and we’re glad to pass that knowledge to anyone." "svg1" "img/illustrations/coffee.svg" "text1" "We sell green and roasted coffee beans that are sourced directly from independent farmers and farm cooperatives. We’re proud to offer a variety of coffee beans grown with great care for the environment and local communities. Check our post or contact us directly for current availability." "svg2" "/img/illustrations/coffee-gear.svg" "text2" "We offer a small, but carefully curated selection of brewing gear and tools for every taste and experience level. No matter if you roast your own beans or just bought your first french press, you’ll find a gadget to fall in love with in our shop." "buttonText" "See all products" "buttonLink" "/products" ) }}
+{{ partial "2-up" .Params }}
-{{ partial "text-and-image" (dict "heading" "Our values" "text" "Coffee is an amazing part of human culture but it has a dark side too – one of colonialism and mindless abuse of natural resources and human lives. We want to turn this around and return the coffee trade to the drink’s exhilarating, empowering and unifying nature." "buttonText" "Read more" "buttonLink" "/values") }}
+{{ partial "text-and-image" (dict "heading" .Params.values.heading "text" .Params.values.text "buttonText" "Read more" "buttonLink" "/values") }}
{{ partial "blog" . }}
diff --git a/site/layouts/partials/2-up.html b/site/layouts/partials/2-up.html
index 06849f0..ab827b4 100644
--- a/site/layouts/partials/2-up.html
+++ b/site/layouts/partials/2-up.html
@@ -1,24 +1,19 @@
<div class="bg-off-white pv4">
<div class="ph3 mw7 center">
- <h2 class="f2 b lh-title mb2">{{.heading}}</h2>
- <p class="mb4 mw6">{{.description}}</p>
+ <h2 class="f2 b lh-title mb2">{{.intro.heading}}</h2>
+ <p class="mb4 mw6">{{.intro.text}}</p>
<div class="flex-ns mhn2-ns mb3">
+ {{ range .products }}
<div class="ph2-ns w-50-ns">
- <img src="{{.svg1}}" alt="" class="center db mb3" style="width: 240px">
- <p>{{.text1}}</p>
- </div>
-
- <div class="ph2-ns w-50-ns">
- <img src="{{.svg2}}" alt="" class="center db mb3" style="width: 240px">
- <p>{{.text2}}</p>
+ <img src="{{.image}}" alt="" class="center db mb3" style="width: 240px">
+ <p>{{.text}}</p>
</div>
+ {{ end }}
</div>
- {{ if .buttonText }}
- <div class="tc">
- <a href="{{.buttonLink}}" class="btn raise">{{.buttonText}}</a>
- </div>
- {{ end }}
+ <div class="tc">
+ <a href="/products" class="btn raise">See all products</a>
+ </div>
</div>
</div>
diff --git a/site/layouts/partials/footer.html b/site/layouts/partials/footer.html
index b69672e..5547c82 100644
--- a/site/layouts/partials/footer.html
+++ b/site/layouts/partials/footer.html
@@ -36,10 +36,10 @@
<div>
<h3 class="f4 b lh-title mb2 primary">Social media</h3>
<ul class="mhn2">
- {{ partial "social-icon" (dict "link" "#" "svg" "facebook") }}
- {{ partial "social-icon" (dict "link" "#" "svg" "twitter") }}
- {{ partial "social-icon" (dict "link" "#" "svg" "instagram") }}
- {{ partial "social-icon" (dict "link" "#" "svg" "vimeo") }}
+ {{ partial "social-icon" (dict "link" "#" "svg" "icons-facebook") }}
+ {{ partial "social-icon" (dict "link" "#" "svg" "icons-twitter") }}
+ {{ partial "social-icon" (dict "link" "#" "svg" "icons-instagram") }}
+ {{ partial "social-icon" (dict "link" "#" "svg" "icons-vimeo") }}
</ul>
</div>
diff --git a/site/layouts/partials/head.html b/site/layouts/partials/head.html
index b58be17..9e75f44 100644
--- a/site/layouts/partials/head.html
+++ b/site/layouts/partials/head.html
@@ -12,18 +12,18 @@
<link href="https://fonts.googleapis.com/css?family=Nunito+Sans:400,700" rel="stylesheet">
<!-- Favicons -->
- <link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
- <link rel="icon" type="image/png" href="/favicon-32x32.png" sizes="32x32">
- <link rel="icon" type="image/png" href="/favicon-16x16.png" sizes="16x16">
+ <link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
+ <link rel="icon" type="image/png" href="/img/favicon-32x32.png" sizes="32x32">
+ <link rel="icon" type="image/png" href="/img/favicon-16x16.png" sizes="16x16">
<link rel="manifest" href="/manifest.json">
- <link rel="mask-icon" href="/safari-pinned-tab.svg" color="#ff4400">
+ <link rel="mask-icon" href="/img/safari-pinned-tab.svg" color="#ff4400">
<meta name="theme-color" content="#fff">
<!-- Open Graph -->
<meta property="og:type" content="business.business">
<meta property="og:title" content="Kaldi | Great coffee with a conscience">
<meta property="og:url" content="/">
- <meta property="og:image" content="/og-image.jpg">
+ <meta property="og:image" content="/img/og-image.jpg">
<script src="https://identity.netlify.com/v1/netlify-identity-widget.js"></script>
</head>
diff --git a/site/layouts/partials/svg.html b/site/layouts/partials/svg.html
index 5a7068f..25e80a9 100644
--- a/site/layouts/partials/svg.html
+++ b/site/layouts/partials/svg.html
@@ -1,5 +1,5 @@
<div style="height: 0; width: 0; position: absolute; visibility: hidden">
<!-- inject:svg -->
- <svg xmlns="http://www.w3.org/2000/svg"><symbol id="facebook" viewBox="0 0 32 32"><path d="M30.7 0H1.3C.6 0 0 .6 0 1.3v29.3c0 .8.6 1.4 1.3 1.4H17V20h-4v-5h4v-4c0-4.1 2.6-6.2 6.3-6.2 1.8 0 3.3.2 3.7.2v4.3h-2.6c-2 0-2.5 1-2.5 2.4V15h5l-1 5h-4l.1 12h8.6c.7 0 1.3-.6 1.3-1.3V1.3C32 .6 31.4 0 30.7 0z"/></symbol><symbol id="instagram" viewBox="0 0 32 32"><path d="M28.2 0H3.8C1.7 0 0 1.7 0 3.8v24.4C0 30.3 1.7 32 3.8 32h24.4c2.1 0 3.8-1.7 3.8-3.8V3.8C32 1.7 30.3 0 28.2 0zM24 4h3c.6 0 1 .4 1 1v3c0 .6-.4 1-1 1h-3c-.6 0-1-.4-1-1V5c0-.6.4-1 1-1zm-8 5.9c3.4 0 6.2 2.7 6.2 6.1 0 3.4-2.8 6.1-6.2 6.1-3.4 0-6.2-2.7-6.2-6.1.1-3.4 2.8-6.1 6.2-6.1zM28 29H4c-.6 0-1-.4-1-1V13h4c-.5.8-.7 2.1-.7 3 0 5.4 4.4 9.7 9.7 9.7 5.4 0 9.7-4.4 9.7-9.7 0-.9-.1-2.3-.8-3h4v15c.1.6-.3 1-.9 1z"/></symbol><symbol id="twitter" viewBox="0 0 32 32"><path d="M32 6.1c-1.2.5-2.4.9-3.8 1 1.4-.8 2.4-2.1 2.9-3.6-1.3.8-2.7 1.3-4.2 1.6C25.7 3.8 24 3 22.2 3c-3.6 0-6.6 2.9-6.6 6.6 0 .5.1 1 .2 1.5-5.5-.3-10.3-2.9-13.6-6.9-.6 1-.9 2.1-.9 3.3 0 2.3 1.2 4.3 2.9 5.5-1.1 0-2.1-.3-3-.8v.1c0 3.2 2.3 5.8 5.3 6.4-.6.1-1.1.2-1.7.2-.4 0-.8 0-1.2-.1.8 2.6 3.3 4.5 6.1 4.6-2.2 1.8-5.1 2.8-8.2 2.8-.5 0-1.1 0-1.6-.1 3 1.8 6.5 2.9 10.2 2.9 12.1 0 18.7-10 18.7-18.7v-.8c1.2-1 2.3-2.1 3.2-3.4z"/></symbol><symbol id="vimeo" viewBox="0 0 32 32"><path d="M32 8.6c-.1 3.1-2.3 7.4-6.5 12.8-4.4 5.7-8 8.5-11 8.5-1.9 0-3.4-1.7-4.7-5.2-.9-3.2-1.7-6.3-2.6-9.5-1-3.4-2-5.2-3.1-5.2-.2 0-1.1.5-2.5 1.5L0 9.6c1.6-1.4 3.1-2.8 4.7-4.2 2.1-1.8 3.7-2.8 4.7-2.9 2.5-.2 4 1.5 4.6 5.1.6 3.9 1.1 6.4 1.3 7.3.7 3.3 1.5 4.9 2.4 4.9.7 0 1.7-1.1 3-3.2s2.1-3.7 2.2-4.8c.2-1.8-.5-2.7-2.2-2.7-.8 0-1.6.2-2.4.5 1.6-5.2 4.6-7.7 9-7.5 3.3.2 4.9 2.3 4.7 6.5z"/></symbol></svg>
+ <svg xmlns="http://www.w3.org/2000/svg"><symbol id="icons-facebook" viewBox="0 0 32 32"><path d="M30.7 0H1.3C.6 0 0 .6 0 1.3v29.3c0 .8.6 1.4 1.3 1.4H17V20h-4v-5h4v-4c0-4.1 2.6-6.2 6.3-6.2 1.8 0 3.3.2 3.7.2v4.3h-2.6c-2 0-2.5 1-2.5 2.4V15h5l-1 5h-4l.1 12h8.6c.7 0 1.3-.6 1.3-1.3V1.3C32 .6 31.4 0 30.7 0z"/></symbol><symbol id="icons-instagram" viewBox="0 0 32 32"><path d="M28.2 0H3.8C1.7 0 0 1.7 0 3.8v24.4C0 30.3 1.7 32 3.8 32h24.4c2.1 0 3.8-1.7 3.8-3.8V3.8C32 1.7 30.3 0 28.2 0zM24 4h3c.6 0 1 .4 1 1v3c0 .6-.4 1-1 1h-3c-.6 0-1-.4-1-1V5c0-.6.4-1 1-1zm-8 5.9c3.4 0 6.2 2.7 6.2 6.1 0 3.4-2.8 6.1-6.2 6.1-3.4 0-6.2-2.7-6.2-6.1.1-3.4 2.8-6.1 6.2-6.1zM28 29H4c-.6 0-1-.4-1-1V13h4c-.5.8-.7 2.1-.7 3 0 5.4 4.4 9.7 9.7 9.7 5.4 0 9.7-4.4 9.7-9.7 0-.9-.1-2.3-.8-3h4v15c.1.6-.3 1-.9 1z"/></symbol><symbol id="icons-twitter" viewBox="0 0 32 32"><path d="M32 6.1c-1.2.5-2.4.9-3.8 1 1.4-.8 2.4-2.1 2.9-3.6-1.3.8-2.7 1.3-4.2 1.6C25.7 3.8 24 3 22.2 3c-3.6 0-6.6 2.9-6.6 6.6 0 .5.1 1 .2 1.5-5.5-.3-10.3-2.9-13.6-6.9-.6 1-.9 2.1-.9 3.3 0 2.3 1.2 4.3 2.9 5.5-1.1 0-2.1-.3-3-.8v.1c0 3.2 2.3 5.8 5.3 6.4-.6.1-1.1.2-1.7.2-.4 0-.8 0-1.2-.1.8 2.6 3.3 4.5 6.1 4.6-2.2 1.8-5.1 2.8-8.2 2.8-.5 0-1.1 0-1.6-.1 3 1.8 6.5 2.9 10.2 2.9 12.1 0 18.7-10 18.7-18.7v-.8c1.2-1 2.3-2.1 3.2-3.4z"/></symbol><symbol id="icons-vimeo" viewBox="0 0 32 32"><path d="M32 8.6c-.1 3.1-2.3 7.4-6.5 12.8-4.4 5.7-8 8.5-11 8.5-1.9 0-3.4-1.7-4.7-5.2-.9-3.2-1.7-6.3-2.6-9.5-1-3.4-2-5.2-3.1-5.2-.2 0-1.1.5-2.5 1.5L0 9.6c1.6-1.4 3.1-2.8 4.7-4.2 2.1-1.8 3.7-2.8 4.7-2.9 2.5-.2 4 1.5 4.6 5.1.6 3.9 1.1 6.4 1.3 7.3.7 3.3 1.5 4.9 2.4 4.9.7 0 1.7-1.1 3-3.2s2.1-3.7 2.2-4.8c.2-1.8-.5-2.7-2.2-2.7-.8 0-1.6.2-2.4.5 1.6-5.2 4.6-7.7 9-7.5 3.3.2 4.9 2.3 4.7 6.5z"/></symbol></svg>
<!-- endinject -->
</div>
diff --git a/site/layouts/partials/text-and-image.html b/site/layouts/partials/text-and-image.html
index ff3bd7c..7a55f15 100644
--- a/site/layouts/partials/text-and-image.html
+++ b/site/layouts/partials/text-and-image.html
@@ -3,13 +3,13 @@
<div class="flex-l mhn2-l">
<div class="w-40-l ph2-l">
- <h2 class="f2 b lh-title mb2">{{.heading}}</h1>
+ <h2 class="f2 b lh-title mb2">{{.heading}}</h2>
<p>{{.text}}</p>
</div>
<div class="w-60-l ph2-l">
- <img src="img/home/about-section.jpg" alt="" class="mb3">
+ <img src="img/home-about-section.jpg" alt="" class="mb3">
</div>
</div>
diff --git a/site/layouts/section/contact.html b/site/layouts/section/contact.html
new file mode 100644
index 0000000..205d92e
--- /dev/null
+++ b/site/layouts/section/contact.html
@@ -0,0 +1,26 @@
+{{ partial "head" . }}
+
+{{ partial "nav" . }}
+
+<div class="ph3 bg-off-white">
+ <div class="center mw6 pv3">
+
+ <img src="{{ .Params.logo }}" alt="" class="db w4 center pv4">
+
+ {{ .Content }}
+
+ <div class="flex-ns mb3">
+ {{ range .Params.contact_entries }}
+ <div>
+ <h4 class="f4 b lh-title mb2 primary">{{ .heading }}</h4>
+ <p>{{ .text }}</p>
+ </div>
+ {{ end }}
+ </div>
+
+ {{ partial "contact-form" . }}
+
+ </div>
+</div>
+
+{{ partial "footer" . }}
diff --git a/site/layouts/products/single.html b/site/layouts/section/products.html
index bf430ca..bf430ca 100644
--- a/site/layouts/products/single.html
+++ b/site/layouts/section/products.html
diff --git a/site/layouts/section/values.html b/site/layouts/section/values.html
new file mode 100644
index 0000000..9b6fa13
--- /dev/null
+++ b/site/layouts/section/values.html
@@ -0,0 +1,17 @@
+{{ partial "head" . }}
+{{ partial "nav" . }}
+{{ partial "jumbotron" (dict "imageUrl" .Params.image "title" .Title) }}
+
+<div class="mw7 center ph3 pt4">
+
+ {{ range $index, $element := .Params.values }}
+ {{ if modBool $index 2 }}
+ {{ partial "media-block" $element }}
+ {{ else }}
+ {{ partial "media-block-reverse" $element }}
+ {{ end }}
+ {{ end }}
+
+</div>
+
+{{ partial "footer" . }}
diff --git a/site/layouts/values/single.html b/site/layouts/values/single.html
deleted file mode 100644
index 552922a..0000000
--- a/site/layouts/values/single.html
+++ /dev/null
@@ -1,18 +0,0 @@
-{{ partial "head" . }}
-{{ partial "nav" . }}
-{{ partial "jumbotron" (dict "imageUrl" "/img/about/jumbotron.jpg" "title" "Values") }}
-
-<div class="mw7 center ph3 pt4">
-
- {{ partial "media-block" (dict "heading" "Shade-grown coffee" "text" "Coffee is a small tree or shrub that grows in the forest understory in its wild form, and traditionally was grown commercially under other trees that provided shade. The forest-like structure of shade coffee farms provides habitat for a great number of migratory and resident species." "imageUrl" "/img/about/shade-grown.jpg") }}
-
- {{ partial "media-block-reverse" (dict "heading" "Single origin" "text" "Single-origin coffee is coffee grown within a single known geographic origin. Sometimes, this is a single farm or a specific collection of beans from a single country. The name of the coffee is then usually the place it was grown to whatever degree available." "imageUrl" "/img/about/single-origin.jpg") }}
-
- {{ partial "media-block" (dict "heading" "Sustainable farming" "text" "Sustainable agriculture is farming in sustainable ways based on an understanding of ecosystem services, the study of relationships between organisms and their environment. What grows where and how it is grown are a matter of choice and careful consideration for nature and communities." "imageUrl" "/img/about/sustainable-farming.jpg") }}
-
- {{ partial "media-block-reverse" (dict "heading" "Direct sourcing" "text" "Direct trade is a form of sourcing practiced by some coffee roasters. Advocates of direct trade practices promote direct communication and price negotiation between buyer and farmer, along with systems that encourage and incentivize quality." "imageUrl" "/img/about/direct-sourcing.jpg") }}
-
- {{ partial "media-block" (dict "heading" "Reinvest profits" "text" "We want to truly empower the communities that bring amazing coffee to you. That’s why we reinvest 20% of our profits into farms, local businesses and schools everywhere our coffee is grown. You can see the communities grow and learn more about coffee farming on our blog." "imageUrl" "/img/about/reinvest-profits.jpg") }}
-</div>
-
-{{ partial "footer" . }}