Skip to content

Commit acb5aff

Browse files
kaitlinnewsonwickr
authored andcommitted
#1 -- header logo (#8)
* add header image and center both logo and nav * don't hardcode the logo alt text
1 parent 646f95a commit acb5aff

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

_config.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@ description: >- # this means to ignore newlines until "baseurl:"
2020
being a diverse and inclusive community, seeking to share ideas and build collaboration.
2121
baseurl: "" # the subpath of your site, e.g. /blog
2222
url: "http://code4lib.org" # the base hostname & protocol for your site, e.g. http://example.com
23+
logo: "/files/logo/c4l_logo/c4l_logo.RGB_400px.png"
24+
logo_alt: "Code4Lib"
2325

2426
header_pages:
2527
- about.md

_includes/header.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<div class="wrapper">
44
{%- assign default_paths = site.pages | map: "path" -%}
55
{%- assign page_paths = site.header_pages | default: default_paths -%}
6-
<a class="site-title" rel="author" href="{{ "/" | relative_url }}">{{ site.title | escape }}</a>
6+
<a class="site-title" rel="author" href="{{ "/" | relative_url }}"><img class="site-logo" src="{{ site.logo }}" alt="{{ site.logo_alt }}"></a>
77

88
{%- if page_paths -%}
99
<nav class="site-nav">

_sass/minima.scss

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,23 @@ $content-width: 800px !default;
2626
$on-palm: 600px !default;
2727
$on-laptop: 800px !default;
2828

29+
// Header logo
30+
31+
.site-title {
32+
float: none !important;
33+
}
34+
35+
.site-logo {
36+
display:block;
37+
margin:auto;
38+
padding: 0.5em;
39+
}
40+
41+
.site-nav {
42+
float: none !important;
43+
text-align: center;
44+
}
45+
2946
// Use media queries like this:
3047
// @include media-query($on-palm) {
3148
// .wrapper {

0 commit comments

Comments
 (0)