Skip to content

Commit b3d00c4

Browse files
committed
Adds open source tag to CMS cards
1 parent 93f4115 commit b3d00c4

File tree

4 files changed

+15
-2
lines changed

4 files changed

+15
-2
lines changed

src/css/tailwind.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,9 @@ dd a:focus {
5454
p+p {
5555
@apply mt-4;
5656
}
57-
57+
section.cards {
58+
max-width: 66rem;
59+
}
5860

5961
/*
6062
CTA links

src/site/_includes/components/cards.njk

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@
77
{%- elseif loopIndex % 4 === 2 %} bg-gradient-card-seafoam
88
{%- elseif loopIndex % 4 === 3 %} bg-gradient-card-gold
99
{%- endif -%}">
10+
{%- if item.data.opensource -%}
11+
<div class="text-xxs mb-2">
12+
<span class="inline-block uppercase bg-black text-white leading-5 px-2 rounded">Open Source</span>
13+
</div>
14+
{% endif %}
1015
{{ item.data.title }}
1116
</div>
1217
<div class="p-4">

src/site/_includes/layouts/tool.njk

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,10 @@ layout: layouts/base.njk
5454
{%- endif %}
5555
</dl>
5656
<dl class="inline-block mb-4">
57+
{%- if opensource %}
58+
<dt class="inline-block font-bold mr-6">Open Source</dt>
59+
<dd class="inline-block sr-only">Yes</dd>
60+
{%- endif %}
5761
{%- if language %}
5862
<dt class="inline-block font-bold">Language:</dt>
5963
<dd class="inline-block mr-6">{{ language }}</dd>

tailwind.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ module.exports = {
44
'./src/site/**/*.md'
55
],
66
theme: {
7-
87
borderRadius: {
98
'none': '0',
109
'sm': '.125rem',
@@ -14,6 +13,9 @@ module.exports = {
1413
'full': '9999px',
1514
},
1615
extend: {
16+
fontSize: {
17+
xxs: "0.625rem",
18+
},
1719
colors: {
1820
orange: {
1921
500: "#DF4A1F",

0 commit comments

Comments
 (0)