From 6f31e545c945e25e82b27e2670f3e5c1a373a843 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oleksis=20Fraga=20Men=C3=A9ndez?= Date: Fri, 13 Oct 2023 21:57:14 -0400 Subject: [PATCH] Update footer, add social links layout Update bpd.css, add SVG social symbols #29 --- .prettierignore | 3 ++ _config.yml | 26 ++++++++++++++ _includes/footer.html | 9 ++++- _includes/social-icons/devto.svg | 1 + _includes/social-icons/dribbble.svg | 1 + _includes/social-icons/facebook.svg | 1 + _includes/social-icons/flickr.svg | 1 + _includes/social-icons/github.svg | 1 + _includes/social-icons/gitlab.svg | 1 + _includes/social-icons/google_scholar.svg | 1 + _includes/social-icons/instagram.svg | 1 + _includes/social-icons/keybase.svg | 4 +++ _includes/social-icons/linkedin.svg | 1 + _includes/social-icons/mastodon.svg | 1 + _includes/social-icons/microdotblog.svg | 1 + _includes/social-icons/pinterest.svg | 1 + _includes/social-icons/rss.svg | 1 + _includes/social-icons/stackoverflow.svg | 1 + _includes/social-icons/telegram.svg | 1 + _includes/social-icons/twitter.svg | 1 + _includes/social-icons/x.svg | 3 ++ _includes/social-icons/youtube.svg | 1 + _includes/social-item.html | 7 ++++ _includes/social.html | 5 +++ _includes/svg_symbol.html | 3 ++ _layouts/default.html | 12 ++++--- assets/css/bpd.css | 43 +++++++++++++++++++++++ assets/minima-social-icons.liquid | 18 ++++++++++ 28 files changed, 145 insertions(+), 5 deletions(-) create mode 100644 _includes/social-icons/devto.svg create mode 100644 _includes/social-icons/dribbble.svg create mode 100644 _includes/social-icons/facebook.svg create mode 100644 _includes/social-icons/flickr.svg create mode 100644 _includes/social-icons/github.svg create mode 100644 _includes/social-icons/gitlab.svg create mode 100644 _includes/social-icons/google_scholar.svg create mode 100644 _includes/social-icons/instagram.svg create mode 100644 _includes/social-icons/keybase.svg create mode 100644 _includes/social-icons/linkedin.svg create mode 100644 _includes/social-icons/mastodon.svg create mode 100644 _includes/social-icons/microdotblog.svg create mode 100644 _includes/social-icons/pinterest.svg create mode 100644 _includes/social-icons/rss.svg create mode 100644 _includes/social-icons/stackoverflow.svg create mode 100644 _includes/social-icons/telegram.svg create mode 100644 _includes/social-icons/twitter.svg create mode 100644 _includes/social-icons/x.svg create mode 100644 _includes/social-icons/youtube.svg create mode 100644 _includes/social-item.html create mode 100644 _includes/social.html create mode 100644 _includes/svg_symbol.html create mode 100644 assets/minima-social-icons.liquid diff --git a/.prettierignore b/.prettierignore index ae885d3..59a7242 100644 --- a/.prettierignore +++ b/.prettierignore @@ -3,3 +3,6 @@ assets/js/index.js _layouts/default.html _layouts/index.html _includes/header.html +_includes/social.html +_includes/social-item.html +_includes/svg_symbol.html diff --git a/_config.yml b/_config.yml index 3e3ca22..f950af1 100644 --- a/_config.yml +++ b/_config.yml @@ -30,6 +30,32 @@ navigation: url: /community/ fa: fa fa-users fa-fw +bpdevs: + # Minima date format. + # Refer to https://shopify.github.io/liquid/filters/date/ if you want to customize this. + # + # date_format: "%b %-d, %Y" + + # Generate social links in footer. + # + #social_links: + # - { platform: devto, user_url: "https://dev.to/jekyll" } + # - { platform: dribbble, user_url: "https://dribbble.com/jekyll" } + # - { platform: facebook, user_url: "https://www.facebook.com/jekyll" } + # - { platform: flickr, user_url: "https://www.flickr.com/photos/jekyll" } + # - { platform: github, user_url: "https://github.com/BlackPythonDevs/blackpythondevs.github.io" } + # - { platform: google_scholar, user_url: "https://scholar.google.com/citations?user=qc6CJjYAAAAJ" } + # - { platform: instagram, user_url: "https://www.instagram.com/jekyll" } + # - { platform: keybase, user_url: "https://keybase.io/jekyll" } + # - { platform: linkedin, user_url: "https://www.linkedin.com/in/jekyll" } + # - { platform: microdotblog, user_url: "https://micro.blog/jekyll" } + # - { platform: pinterest, user_url: "https://www.pinterest.com/jekyll" } + # - { platform: stackoverflow, user_url: "https://stackoverflow.com/users/1234567/jekyll" } + # - { platform: telegram, user_url: "https://t.me/jekyll" } + # - { platform: twitter, user_url: "https://twitter.com/jekyllrb" } + # - { platform: x, user_url: "https://x.com/blackpythondevs" } + # - { platform: youtube, user_url: "https://www.youtube.com/jekyll" } + # Build settings markdown: kramdown highlighter: rouge diff --git a/_includes/footer.html b/_includes/footer.html index 06b7245..1fa5160 100644 --- a/_includes/footer.html +++ b/_includes/footer.html @@ -1,3 +1,10 @@ diff --git a/_includes/social-icons/devto.svg b/_includes/social-icons/devto.svg new file mode 100644 index 0000000..7c7aeb5 --- /dev/null +++ b/_includes/social-icons/devto.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/dribbble.svg b/_includes/social-icons/dribbble.svg new file mode 100644 index 0000000..69398f3 --- /dev/null +++ b/_includes/social-icons/dribbble.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/facebook.svg b/_includes/social-icons/facebook.svg new file mode 100644 index 0000000..2cd4151 --- /dev/null +++ b/_includes/social-icons/facebook.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/flickr.svg b/_includes/social-icons/flickr.svg new file mode 100644 index 0000000..521eec4 --- /dev/null +++ b/_includes/social-icons/flickr.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/github.svg b/_includes/social-icons/github.svg new file mode 100644 index 0000000..ee8d771 --- /dev/null +++ b/_includes/social-icons/github.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/gitlab.svg b/_includes/social-icons/gitlab.svg new file mode 100644 index 0000000..88fd5c6 --- /dev/null +++ b/_includes/social-icons/gitlab.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/google_scholar.svg b/_includes/social-icons/google_scholar.svg new file mode 100644 index 0000000..f258d28 --- /dev/null +++ b/_includes/social-icons/google_scholar.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/instagram.svg b/_includes/social-icons/instagram.svg new file mode 100644 index 0000000..e169118 --- /dev/null +++ b/_includes/social-icons/instagram.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/keybase.svg b/_includes/social-icons/keybase.svg new file mode 100644 index 0000000..7be84c2 --- /dev/null +++ b/_includes/social-icons/keybase.svg @@ -0,0 +1,4 @@ + + + + diff --git a/_includes/social-icons/linkedin.svg b/_includes/social-icons/linkedin.svg new file mode 100644 index 0000000..616b6d5 --- /dev/null +++ b/_includes/social-icons/linkedin.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/mastodon.svg b/_includes/social-icons/mastodon.svg new file mode 100644 index 0000000..31b5f74 --- /dev/null +++ b/_includes/social-icons/mastodon.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/microdotblog.svg b/_includes/social-icons/microdotblog.svg new file mode 100644 index 0000000..c7e024d --- /dev/null +++ b/_includes/social-icons/microdotblog.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/pinterest.svg b/_includes/social-icons/pinterest.svg new file mode 100644 index 0000000..90f2348 --- /dev/null +++ b/_includes/social-icons/pinterest.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/rss.svg b/_includes/social-icons/rss.svg new file mode 100644 index 0000000..7be712d --- /dev/null +++ b/_includes/social-icons/rss.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/stackoverflow.svg b/_includes/social-icons/stackoverflow.svg new file mode 100644 index 0000000..8180f1c --- /dev/null +++ b/_includes/social-icons/stackoverflow.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/telegram.svg b/_includes/social-icons/telegram.svg new file mode 100644 index 0000000..f8866e2 --- /dev/null +++ b/_includes/social-icons/telegram.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/twitter.svg b/_includes/social-icons/twitter.svg new file mode 100644 index 0000000..b1b6247 --- /dev/null +++ b/_includes/social-icons/twitter.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-icons/x.svg b/_includes/social-icons/x.svg new file mode 100644 index 0000000..af3536d --- /dev/null +++ b/_includes/social-icons/x.svg @@ -0,0 +1,3 @@ + diff --git a/_includes/social-icons/youtube.svg b/_includes/social-icons/youtube.svg new file mode 100644 index 0000000..9b0e367 --- /dev/null +++ b/_includes/social-icons/youtube.svg @@ -0,0 +1 @@ + diff --git a/_includes/social-item.html b/_includes/social-item.html new file mode 100644 index 0000000..a3ec91a --- /dev/null +++ b/_includes/social-item.html @@ -0,0 +1,7 @@ +
  • {% assign entry = include.item %} + + + + + +
  • diff --git a/_includes/social.html b/_includes/social.html new file mode 100644 index 0000000..d1806c8 --- /dev/null +++ b/_includes/social.html @@ -0,0 +1,5 @@ + diff --git a/_includes/svg_symbol.html b/_includes/svg_symbol.html new file mode 100644 index 0000000..145b42a --- /dev/null +++ b/_includes/svg_symbol.html @@ -0,0 +1,3 @@ + + {%- include social-icons/{{ include.key }}.svg -%} + diff --git a/_layouts/default.html b/_layouts/default.html index d27f957..828f24a 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -1,5 +1,5 @@ - + @@ -27,9 +27,13 @@ - {% include header.html %} -
    {{ content }}
    - {% include footer.html %} + {%- include header.html -%} +
    +
    + {{ content }} +
    +
    + {%- include footer.html -%} diff --git a/assets/css/bpd.css b/assets/css/bpd.css index 79ce6e3..ef492e2 100644 --- a/assets/css/bpd.css +++ b/assets/css/bpd.css @@ -319,3 +319,46 @@ footer { display: flex; margin-top: 2.5em; } + +.social-media-list { + list-style: none; + margin-left: 0; +} + +.footer-col-wrapper, +.social-links { + font-size: 0.9375rem; + color: var(--minima-brand-color); +} + +.social-media-list { + display: table; + margin: 0 auto; +} + +.social-media-list li { + float: left; + margin: 5px 10px 5px 0; +} + +.social-media-list li:last-of-type { + margin-right: 0; +} + +.social-media-list li a { + display: block; + padding: 10px 12px; + border: 1px solid var(--minima-border-color-01); +} + +.social-media-list li a:hover { + border-color: var(--minima-border-color-02); +} + +.svg-icon { + width: 1.25em; + height: 1.25em; + display: inline-block; + fill: currentColor; + vertical-align: text-bottom; +} diff --git a/assets/minima-social-icons.liquid b/assets/minima-social-icons.liquid new file mode 100644 index 0000000..9239b94 --- /dev/null +++ b/assets/minima-social-icons.liquid @@ -0,0 +1,18 @@ +--- +permalink: /assets/minima-social-icons.svg +--- + + +{% comment %} + Iterate through {{ site.bpdevs.social_links }} and render platform related SVG-symbol + unless the platform is "rss" because we need the "rss" symbol for the `Subscribe` link + in the footer and therefore inject the "rss" icon outside the iteration loop. +{% endcomment %} +{% for entry in site.bpdevs.social_links %} + {%- assign symbol_id = entry.platform -%} + {%- unless symbol_id == "rss" -%} + {%- include svg_symbol.html key = symbol_id -%} + {% endunless %} +{%- endfor -%} + {%- include svg_symbol.html key = "rss" -%} +