Skip to content

Commit 90f8613

Browse files
authored
Merge pull request #131 from stedman/master
Fix meta description
2 parents 2e65a77 + 667ceb0 commit 90f8613

File tree

5 files changed

+13
-8
lines changed

5 files changed

+13
-8
lines changed

_includes/business-card.liquid

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</div>
99
<div class="media-content">
1010
<p class="title is-size-5">{{ person.name }}</p>
11-
<p class="subtitle is-6 has-text-weight-semibold is-marginless-bottom">{{ person.title | markdown | safe }}</p>
11+
<div class="subtitle is-6 has-text-weight-semibold is-marginless-bottom">{{ person.title | markdown | safe }}</div>
1212
<div>
1313
{%- include social-links.liquid -%}
1414
</div>

_includes/filters/regex-replace.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,10 @@
88
*
99
*/
1010
module.exports = (content, rePattern, replacement) => {
11-
if (!(replacement && rePattern)) return content;
11+
if (replacement === undefined || rePattern === undefined) return content;
1212

1313
const re = new RegExp(rePattern, 'g');
1414

15+
1516
return content.replace(re, replacement);
1617
};

_layouts/base.liquid

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,12 @@
44
<meta charset="utf-8">
55
<meta name="viewport" content="width=device-width, initial-scale=1">
66
<title>{%- if title != site.title -%}{{ title }} • {%- endif -%}{{ site.title }}</title>
7-
{%- if meta.description -%}{%- assign desc = meta.description -%}{%- else -%}{%- assign desc = layoutContent -%}{%- endif -%}
8-
<meta name="description" content="{{ desc | striptags(true) | regexReplace('^.+\n\n', '') | truncate(160) }}">
7+
{%- if meta.description -%}
8+
{%- assign desc = meta.description -%}
9+
{%- else -%}
10+
{%- assign desc = layoutContent | regexReplace: '<h1 class="title flex-item">.*</h1>', '' | strip_html | regexReplace: '\s{2,}', ' ' | truncate: 160 -%}
11+
{%- endif %}
12+
<meta name="description" content="{{ desc }}">
913
<link rel=canonical href="{{ site.url }}{{ page.url | url }}">
1014
<link rel=alternate type=application/atom+xml href="{{ site.url }}{{ '/feed.xml' | url }}" title="{{ site.title }} Atom feed" />
1115
<link rel="apple-touch-icon" type="image/png" href="{{ '/assets/icon/favicon-ios.png' | url }}" sizes="180x180">

_sass/_main.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,7 @@ $info: $tetradic1;
228228
display: inline-block;
229229
font-size: 1rem;
230230
height: 50px;
231-
margin: -1px !important;
231+
margin: -2px 4px 0 1px !important;
232232
width: 50px;
233233

234234
img {

about.liquid

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ meta:
2323
<p>If you’d like to get more details on past topics, take a look at the <a href="/posts/meetups/">meetup archives</a>.</p>
2424

2525
<h2>How it usually works</h2>
26-
<p>We typically meet on the 3<sup>rd</sup> Tuesday of each month somewhere in central Austin, Texas — typically downtown. We’ll have a speaker or two, open things up for questions and discussion, and then head to a nearby watering hole to continue the festivities.</p>
26+
<p>We typically meet on the 3<sup>rd</sup> Tuesday of each month somewhere deep in the heart of Austin, Texas — typically downtown. We’ll have a speaker or two, open things up for questions and discussion, and then head to a nearby watering hole to continue the festivities.</p>
2727

2828
<h2>Excellence</h2>
2929
<p>We work hard to build a community of like-minded people that treat each other with <em>excellence</em>. We’ve formalized what this means into our <a href="/code-of-conduct/">Code of Conduct</a>.</p>
@@ -32,7 +32,7 @@ meta:
3232
<div class="has-offset-top-3 has-border-top">
3333
<div class="content">
3434
<h2>Emeriti</h2>
35-
<p>If you come across the following people, kindly open the door for them, help them to their seat, and thank them for their many years of service. They helped make Austin JavaScript what it is today.</p>
35+
<p>If you come across the following people at one of our events, kindly open the door for them, help them to their seat, and thank them for their many years of service. They helped make Austin JavaScript what it is today.</p>
3636
</div>
3737
<div class="bricks-flex">
3838
{%- for key in people -%}
@@ -51,7 +51,7 @@ meta:
5151
<div class="has-offset-top-2">
5252
<div class="content">
5353
<h2>The Organizers</h2>
54-
<p>Austin JavaScript is made possible by the hard work and goodwill of many people, but there are a few in particular that you should feel free to reach out to if you’ve got any questions:</p>
54+
<p>Austin JavaScript is made possible by the hard work and goodwill of many people, but there are a few in particular that you should feel free to reach out to if you’ve got any questions or want to <a href="{{ '/contributing/' | url }}">get involved</a>.</p>
5555
</div>
5656
{%- for key in people -%}
5757
{%- assign person = key[1] -%}

0 commit comments

Comments
 (0)