mirror of
https://github.com/privacyguides/privacyguides.org.git
synced 2025-01-02 03:16:32 -05:00
Use flag for language selector icon (#2062)
This commit is contained in:
parent
aaec10b83e
commit
e336699480
@ -16,15 +16,19 @@ extra:
|
|||||||
- name: English
|
- name: English
|
||||||
link: /en/
|
link: /en/
|
||||||
lang: en
|
lang: en
|
||||||
|
icon: https://raw.githubusercontent.com/twitter/twemoji/master/assets/svg/1f1fa-1f1f8.svg
|
||||||
- name: Français
|
- name: Français
|
||||||
link: /fr/
|
link: /fr/
|
||||||
lang: fr
|
lang: fr
|
||||||
|
icon: https://raw.githubusercontent.com/twitter/twemoji/master/assets/svg/1f1eb-1f1f7.svg
|
||||||
- name: עִברִית
|
- name: עִברִית
|
||||||
link: /he/
|
link: /he/
|
||||||
lang: he
|
lang: he
|
||||||
|
icon: https://raw.githubusercontent.com/twitter/twemoji/master/assets/svg/1f1ee-1f1f1.svg
|
||||||
- name: Nederlands
|
- name: Nederlands
|
||||||
link: /nl/
|
link: /nl/
|
||||||
lang: nl
|
lang: nl
|
||||||
|
icon: https://raw.githubusercontent.com/twitter/twemoji/master/assets/svg/1f1f3-1f1f1.svg
|
||||||
|
|
||||||
repo_url: https://github.com/privacyguides/privacyguides.org
|
repo_url: https://github.com/privacyguides/privacyguides.org
|
||||||
repo_name: ""
|
repo_name: ""
|
||||||
|
@ -325,6 +325,18 @@ details[class="downloads annotate"] > p .md-annotation span span::before {
|
|||||||
width: 1rem;
|
width: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* override language selector */
|
||||||
|
.md-select button img.twemoji {
|
||||||
|
height: 1rem;
|
||||||
|
vertical-align: middle;
|
||||||
|
}
|
||||||
|
|
||||||
|
.md-select__link img.twemoji {
|
||||||
|
height: 1rem;
|
||||||
|
vertical-align: text-bottom;
|
||||||
|
margin-right: 1%;
|
||||||
|
}
|
||||||
|
|
||||||
/* Custom header + nav */
|
/* Custom header + nav */
|
||||||
.md-header >*, .md-tabs {
|
.md-header >*, .md-tabs {
|
||||||
background: none;
|
background: none;
|
||||||
|
@ -44,15 +44,19 @@
|
|||||||
{% if config.extra.alternate %}
|
{% if config.extra.alternate %}
|
||||||
<div class="md-header__option">
|
<div class="md-header__option">
|
||||||
<div class="md-select">
|
<div class="md-select">
|
||||||
{% set icon = config.theme.icon.alternate or "material/translate" %}
|
{% for alt in config.extra.alternate %}
|
||||||
<button class="md-header__button md-icon" aria-label="{{ lang.t('select.language') }}">
|
{% if alt.lang == config.theme.language %}
|
||||||
{% include ".icons/" ~ icon ~ ".svg" %}
|
<button class="md-header__button md-icon" aria-label="{{ lang.t('select.language') }}">
|
||||||
</button>
|
<img alt="{{ config.theme.language }}" class="twemoji" src="{{ alt.icon }}">
|
||||||
|
</button>
|
||||||
|
{% endif %}
|
||||||
|
{% endfor %}
|
||||||
<div class="md-select__inner">
|
<div class="md-select__inner">
|
||||||
<ul class="md-select__list">
|
<ul class="md-select__list">
|
||||||
{% for alt in config.extra.alternate %}
|
{% for alt in config.extra.alternate %}
|
||||||
<li class="md-select__item">
|
<li class="md-select__item">
|
||||||
<a href="{{ alt.link | url }}" hreflang="{{ alt.lang }}" class="md-select__link">
|
<a href="{{ alt.link | url }}" hreflang="{{ alt.lang }}" class="md-select__link">
|
||||||
|
<img alt="{{ config.theme.language }}" class="twemoji" src="{{ alt.icon }}">
|
||||||
{{ alt.name }}
|
{{ alt.name }}
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
Loading…
Reference in New Issue
Block a user