Skip to content
Snippets Groups Projects
Commit bde1373c authored by Guillaume ROUSSE's avatar Guillaume ROUSSE
Browse files

add language selection menu on renater templates

parent 5b890dd6
No related branches found
No related tags found
No related merge requests found
......@@ -72,6 +72,9 @@ nobase_www_DATA = \
images/logo_renater_blanc.png \
images/facebook.svg \
images/twitter.svg \
images/lang.svg \
images/en.png \
images/fr.png \
jquery-3.3.1.min.js \
jquery-ui-1.12.1/images/ui-icons_444444_256x240.png \
jquery-ui-1.12.1/images/ui-icons_555555_256x240.png \
......
......@@ -267,6 +267,19 @@ td.label {
border: 1px solid #41494c;
}
.nocursor{
cursor: default!important;
opacity:0.6;
}
.nocursor label{
cursor: default!important;
color:#aaa!important;
}
.nocursor [class*=" fa-"]:before{
text-align: right;
font-size: 1rem;
}
/* Small screens */
/* Define mobile styles */
......
resources/images/en.png

1.72 KiB

resources/images/fr.png

1.18 KiB

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="7.9434972mm"
height="11.258333mm"
viewBox="0 0 28.14625 39.891732"
id="svg20079"
version="1.1"
inkscape:version="0.91 r13725"
sodipodi:docname="lang.svg">
<defs
id="defs20081">
<clipPath
clipPathUnits="userSpaceOnUse"
id="clipPath4527">
<path
d="m 0,838.007 1024,0 L 1024,0 0,0 0,838.007 Z"
id="path4529"
inkscape:connector-curvature="0" />
</clipPath>
</defs>
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="5.6"
inkscape:cx="21.797157"
inkscape:cy="19.410157"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:window-width="1280"
inkscape:window-height="778"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1" />
<metadata
id="metadata20084">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(1073.4043,124.72652)">
<g
transform="matrix(1.25,0,0,-1.25,-1936.9683,859.18611)"
id="g4523">
<g
id="g4525"
clip-path="url(#clipPath4527)">
<g
id="g4531"
transform="translate(712.9932,775.8171)">
<path
d="m 0,0 c 0,-6.041 -4.873,-10.938 -10.884,-10.938 -6.011,0 -10.883,4.897 -10.883,10.938 0,6.041 4.872,10.938 10.883,10.938 C -4.873,10.938 0,6.041 0,0 Z"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4533"
inkscape:connector-curvature="0" />
</g>
<g
id="g4535"
transform="translate(702.1631,786.7546)">
<path
d="m 0,0 c 3.849,0 2.362,-4.357 2.365,-4.358 -0.688,0 -1.818,-0.619 -2.243,-1.415 -0.261,-0.489 -0.239,-1.007 0.06,-1.457 0.204,-0.309 0.38,-0.652 0.551,-0.984 0.361,-0.703 0.762,-1.483 1.391,-1.483 0.133,0 0.276,0.035 0.432,0.113 0.495,0.249 0.85,0.957 1.193,1.641 0.151,0.301 0.374,0.744 0.505,0.884 0.432,-0.059 0.642,-0.451 0.928,-1.071 0.21,-0.457 0.426,-0.929 0.853,-1.143 0.718,-0.361 3.078,0.017 4.383,0.573"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4537"
inkscape:connector-curvature="0" />
</g>
<g
id="g4539"
transform="translate(707.2578,775.4328)">
<path
d="m 0,0 c -0.122,-0.035 -0.29,-0.083 -0.335,-0.087 -0.587,0 -0.959,-0.457 -1.23,-0.79 -0.104,-0.127 -0.291,-0.355 -0.411,-0.359 -0.192,0.096 -0.393,0.145 -0.599,0.145 -0.501,0 -0.935,-0.299 -1.031,-0.713 -0.069,-0.29 0.032,-0.687 0.518,-0.932 0.69,-0.347 1.403,-0.704 1.72,-1.024 0.219,-0.219 0.597,-0.345 1.037,-0.345 0.669,0 1.559,0.327 1.863,1.248 0.121,0.363 0.409,0.64 0.689,0.908 0.324,0.312 0.63,0.607 0.633,1.029 0.003,0.249 -0.106,0.487 -0.326,0.708 C 2.229,0.088 1.823,0.24 1.319,0.24 0.837,0.24 0.354,0.102 0,0 Z"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4541"
inkscape:connector-curvature="0" />
</g>
<g
id="g4543"
transform="translate(702.2852,764.8796)">
<path
d="m 0,0 c -1.537,0 -2.927,2.688 -2.296,4.167 1.133,2.656 0.079,3.646 -0.371,4.069 l -0.085,0.081 c -0.129,0.129 -0.273,0.217 -0.401,0.294 -0.312,0.188 -0.396,0.238 -0.229,0.742 0.111,0.334 0.258,0.49 0.428,0.67 0.392,0.417 0.692,0.833 0.692,2.04 0,0.703 -0.354,1.264 -0.972,1.538 -0.702,0.312 -1.638,0.202 -2.133,-0.25 -0.31,-0.283 -0.414,-0.667 -0.285,-1.055 0.302,-0.911 -0.39,-2.228 -1.683,-3.203 -0.342,-0.258 -0.444,-0.139 -0.505,-0.069 -0.38,0.439 -0.35,1.689 -0.039,2.001 0.209,0.21 0.271,0.477 0.165,0.716 -0.344,0.784 -2.538,0.724 -2.974,0.703"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4545"
inkscape:connector-curvature="0" />
</g>
<g
id="g4547"
transform="translate(702.4873,769.4577)">
<path
d="m 0,0 c -0.529,0 -1.151,-0.613 -1.379,-1.163 -0.177,-0.43 -0.124,-0.831 0.146,-1.102 0.253,-0.255 0.629,-0.401 1.032,-0.401 0.402,0 0.779,0.146 1.033,0.401 0.282,0.284 0.351,0.701 0.193,1.173 C 0.92,-0.773 0.71,-0.435 0.466,-0.188 0.344,-0.067 0.179,0 0,0 Z"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4549"
inkscape:connector-curvature="0" />
</g>
<g
id="g4551"
transform="translate(706.1422,759.6247)">
<path
d="M 0,0 -4.033,-4.033 -8.065,0"
style="fill:none;stroke:#ffffff;stroke-width:0.75;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:10;stroke-dasharray:none;stroke-opacity:1"
id="path4553"
inkscape:connector-curvature="0" />
</g>
</g>
</g>
</g>
</svg>
......@@ -55,6 +55,40 @@
<label class="show-for-small-only">Accueil</label>
</a>
</li>
<li class="has-submenu" data-action="select_language">
<a href="#" title="[% lh.maketext("Language") %]">
<img class="lang_img" src="images/lang.svg" alt="[% lh.maketext("Language") %]" data-options="disable_for_touch:true"/>
<label class="show-for-small-only">[% lh.maketext("Language") %]</label>
</a>
<ul class="submenu vertical" data-submenu>
<li>
<a
[% IF lh.language_tag() == "en" %]
class="nocursor"
[% ELSE %]
href="[% app.url %]?action=[% action %]&federation=[% federation %]&entityid=[% entityid %]&email=[% email %]&token=[% token %]&lang=en"
[% END %]
data-lang="en" title="English">
<img src="images/en.png" />
<label>English</label>
[% IF lh.language_tag() == "en" %]<span class="fa fa-check"></span>[% END %]
</a>
</li>
<li>
<a
[% IF lh.language_tag() == "fr" %]
class="nocursor"
[% ELSE %]
href="[% app.url %]?action=[% action %]&federation=[% federation %]&entityid=[% entityid %]&email=[% email %]&token=[% token %]&lang=fr"
[% END %]
data-lang="fr" title="Français">
<img src="images/fr.png" />
<label>Français</label>
[% IF lh.language_tag() == "fr" %]<span class="fa fa-check"></span>[% END %]
</a>
</li>
</ul>
</li>
</ul>
</menu>
</nav>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment