Skip to content

Commit

Permalink
Added version badge in footer. Closes #9
Browse files Browse the repository at this point in the history
  • Loading branch information
lmammino committed Sep 16, 2017
1 parent 50a30aa commit b532192
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 1 deletion.
1 change: 1 addition & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ jobs:
command: |
if [ "${CIRCLE_BRANCH}" == "master" ]; then
echo "$DOMAIN" > CNAME
cp -rf .circleci build
git config --global user.email "$GH_EMAIL"
git config --global user.name "$GH_NAME"
NODE_DEBUG=gh-pages npm run deploy
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "serverlesslab.com",
"version": "1.0.3",
"version": "1.0.4",
"versionDate": "2017-09-16",
"description": "Source code for serverlesslab.com website",
"private": true,
Expand Down
10 changes: 10 additions & 0 deletions src/components/Footer/VersionBadge.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { h } from 'preact'
import { version, versionDate } from '../../../package.json'

const VersionBadge = () => (
<a href='https://github.com/lucpod/serverlesslab.com' className='versionBadge'>
<span className='version'>v{version}</span><span className='date'>{versionDate}</span>
</a>
)

export default VersionBadge
2 changes: 2 additions & 0 deletions src/components/Footer/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { h } from 'preact'
import VersionBadge from './VersionBadge'
import logo from '../images/logo-color.svg'

const Footer = () => (
Expand Down Expand Up @@ -29,6 +30,7 @@ const Footer = () => (
Built with <strong>♥︎</strong> in <strong>Dublin</strong><br />
by a <strong>Corkonian</strong> and a <strong>Sicilian</strong>
</p>
<p className='has-text-centered'><VersionBadge /></p>
</div>
</div>
</div>
Expand Down
17 changes: 17 additions & 0 deletions src/style.sass
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,23 @@ $family-primary: $family-serif

@import "../node_modules/bulma/bulma"

.versionBadge
span
padding: .25rem
font-size: .75rem

.version
border-radius: .25rem 0 0 .25rem
background: $color1light
color: $neutral
font-weight: bold

.date
color: $color1light
border-radius: 0 .25rem .25rem 0
background: $neutral


label.radio.is-medium
font-size: 1.25rem

Expand Down

0 comments on commit b532192

Please sign in to comment.