Skip to content

Commit

Permalink
Add Linkedin link (#364)
Browse files Browse the repository at this point in the history
  • Loading branch information
clementbiron authored Nov 20, 2024
2 parents 134824b + 93befd4 commit 56064cf
Show file tree
Hide file tree
Showing 18 changed files with 158 additions and 181 deletions.
12 changes: 7 additions & 5 deletions config/_default/menus.en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ footer:
- name: About
pageRef: /about
weight: 7
first_subfooter:
- name: Contact-us
identifier: mailto
weight: 8
footer_sub:
- name: Services status
url: https://stats.uptimerobot.com/nXvrBcl0wx
weight: 1
Expand All @@ -53,13 +56,12 @@ first_subfooter:
weight: 4
params:
target: _blank
second_subfooter:
- name: Legal notice
pageRef: /legal-notice
weight: 1
weight: 5
- name: Privacy policy
pageRef: /privacy-policy
weight: 2
weight: 6
- name: 'Accessibility: not compliant'
pageRef: /accessibility
weight: 3
weight: 7
12 changes: 7 additions & 5 deletions config/_default/menus.fr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@ footer:
- name: À propos
pageRef: /about
weight: 7
first_subfooter:
- name: Contactez-nous
identifier: mailto
weight: 8
footer_sub:
- name: État des services
url: https://stats.uptimerobot.com/nXvrBcl0wx
weight: 1
Expand All @@ -53,13 +56,12 @@ first_subfooter:
weight: 4
params:
target: _blank
second_subfooter:
- name: Mentions légales
pageRef: /legal-notice
weight: 1
weight: 5
- name: Politique de confidentialité
pageRef: /privacy-policy
weight: 2
weight: 6
- name: 'Accessibilité : non conforme'
pageRef: /accessibility
weight: 3
weight: 7
2 changes: 2 additions & 0 deletions config/_default/params.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ mastodon:
username: "@[email protected]"
github:
url: https://github.com/OpenTermsArchive
linkedin:
url: https://www.linkedin.com/company/opentermsarchive/
contributors:
local_source: allcontributorsrc.json
additional_sources:
Expand Down
3 changes: 0 additions & 3 deletions i18n/en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ header:
menu:
open: Menu
close: Close
footer:
mastodon: Follow us
mail: Contact us
new_reuse:
title: Your Tool
subtitle: If you want to build a tool with Open Terms Archive, contact us!
Expand Down
3 changes: 0 additions & 3 deletions i18n/fr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ header:
menu:
open: Menu
close: Fermer
footer:
mastodon: Suivez-nous
mail: Contactez-nous
new_reuse:
title: Votre outil
subtitle: Si vous souhaitez développer un outil basé sur Open Terms Archive, contactez-nous !
Expand Down
14 changes: 14 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
"postcss-import": "^16.0.1",
"postcss-mixins": "^9.0.4",
"postcss-preset-env": "^9.4.0",
"simple-icons": "^13.17.0",
"stylelint": "^16.2.1",
"stylelint-config-recess-order": "^5.0.0",
"stylelint-config-standard": "^36.0.0",
Expand Down
3 changes: 2 additions & 1 deletion themes/opentermsarchive/assets/css/components/divider.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
.divider {
& > hr {
border: 1px solid var(--colorBlack400);
border: none;
border-top: 1px solid var(--colorBlack300);
}
}
113 changes: 36 additions & 77 deletions themes/opentermsarchive/assets/css/components/footer.css
Original file line number Diff line number Diff line change
@@ -1,99 +1,58 @@
.footer {
width: 100%;
padding: 0 0 var(--pL) 0;
}
display: flex;
flex-direction: column;
gap: var(--mM);
align-items: center;
margin: 0 auto;
text-align: center;

.version {
font-size: 0.8em;
font-style: italic;
color: var(--colorBlack400);
text-align: right;
}
& ul {
display: flex;
flex-flow: row wrap;
justify-content: center;

@media (--tabletLarge) {
.footer {
text-align: center;
& li {
& a {
display: inline-flex;
color: var(--colorBlack600);
}
}
}
}

.footer__menus {
display: flex;
gap: var(--mXL);
justify-content: space-between;
width: 100%;
margin-top: var(--mM);

& div {
max-width: 45%;

@media (--mobileExtraLarge) {
& ul {
display: flex;
flex-flow: row wrap;
gap: var(--mS);

& li {
& a {
color: var(--colorBlack600);
}
}

& + ul {
margin-top: var(--mS);
width: 100%;
}
}
}
}

@media (--gridPlus) {
.footer {
padding-right: var(--pL);
padding-left: var(--pL);
}
.footer__main-menu {
gap: var(--m2XS) var(--mS);
}

@media (--tabletLarge) {
.footer {
display: flex;
flex-direction: column;
align-items: center;
}

.footer__menus {
align-items: flex-start;
justify-content: center;

& div {
max-width: 100%;

& ul {
flex-direction: column;
.footer__sub-menu {
gap: var(--m2XS) var(--mS);
}

& li {
text-align: left;
}
.footer__logo {
margin-top: var(--mL);
margin-bottom: var(--mM);

& + ul {
margin-top: var(--mM);
}
}
}
@media (--mobileExtraLarge) {
margin-top: var(--mS);
margin-bottom: var(--mS);
}
}

@media (--mobileExtraLarge) {
.footer__menus {
flex-wrap: wrap;
gap: var(--mXL);
justify-content: flex-start;

& div {
width: 100%;
.footer__socials {
gap: var(--mXS);
margin-top: var(--mM);
margin-bottom: var(--mM);

& ul {
& li {
text-align: center;
}
}
}
@media (--mobileExtraLarge) {
margin-top: var(--mS);
margin-bottom: var(--mS);
}
}
11 changes: 0 additions & 11 deletions themes/opentermsarchive/assets/css/components/footer__menu.css

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,7 @@

.header__menu-secondary {
& ul {
& li:not(:last-child) {
margin: 0 var(--m2XS);
}
gap: var(--m2XS);
}
}

Expand Down
1 change: 0 additions & 1 deletion themes/opentermsarchive/assets/css/loader.css
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
@import "themes/opentermsarchive/assets/css/components/divider.css";
@import "themes/opentermsarchive/assets/css/components/featureitem.css";
@import "themes/opentermsarchive/assets/css/components/footer.css";
@import "themes/opentermsarchive/assets/css/components/footer__menu.css";
@import "themes/opentermsarchive/assets/css/components/header.css";
@import "themes/opentermsarchive/assets/css/components/header__menu.css";
@import "themes/opentermsarchive/assets/css/components/hero.css";
Expand Down
30 changes: 30 additions & 0 deletions themes/opentermsarchive/assets/js/brands.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import { siMastodon, siLinkedin, siGithub } from 'simple-icons';

const ICONS = {
mastodon: siMastodon,
linkedin: siLinkedin,
github: siGithub,
};

async function applyBrandsIcons() {
const elements = document.querySelectorAll('[data-simple-icon]');

elements.forEach(element => {
const attribute = element.getAttribute('data-simple-icon').toLowerCase();
const icon = ICONS[attribute];

if (icon) {
const svgDoc = new DOMParser().parseFromString(icon.svg, 'image/svg+xml');
const svgElement = svgDoc.querySelector('svg');
const existingClasses = element.getAttribute('class');

if (existingClasses) {
svgElement.setAttribute('class', existingClasses);
}
svgElement.setAttribute('fill', 'var(--svgfill)');
element.replaceWith(svgElement);
}
});
}

document.addEventListener('DOMContentLoaded', applyBrandsIcons);
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import {
Github,
ChevronDown,
ChevronRight,
ChevronLeft,
Expand Down Expand Up @@ -38,7 +37,6 @@ createIcons({
ChevronDown,
ChevronRight,
ChevronLeft,
Github,
Hash,
Mail,
Folder,
Expand Down
4 changes: 1 addition & 3 deletions themes/opentermsarchive/layouts/partials/follow-us.html
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ <h3 class="column__title h3--light">{{ i18n "follow_us.title" }}</h3>
<p class="mt--m mb--l">{{ i18n "follow_us.subtitle" }}</p>
<div class="container container--fluid container--flex container--has-no-padding-x container--has-no-padding-y">
<a href="{{ site.Params.mastodon.url }}" target="_blank" rel="noopener" class="button">
<svg class="icon icon--fill-white">
<use href="#mastodon"></use>
</svg>
<i class="icon icon--fill-white" data-simple-icon="mastodon"></i>
<span class="ml--xs">{{ i18n "follow_us.mastodon" }}</span>
</a>
</div>
Expand Down
Loading

0 comments on commit 56064cf

Please sign in to comment.