Vous avez reçu un message "Your GitLab account has been locked ..." ? Pas d'inquiétude : lisez cet article https://docs.gricad-pages.univ-grenoble-alpes.fr/help/unlock/

Commit 3965b0a0 authored by Sylvain Coulange's avatar Sylvain Coulange
Browse files

traduction interface

parent 7a787c62
var langJson = {
"sp_header": {
"fr":"Cette application est un prototype en cours de conception. <a href='https://groups.google.com/d/forum/alem-app' target='_blank'><b>Accéder au forum</b></a> pour échanger avec la communauté et faire vos suggestions.",
"en":"This application still is a prototype under development. <a href='https://groups.google.com/d/forum/alem-app' target='_blank'><b>Access to the forum</b></a> to share and make suggestions."
},
"sp_footcode": {
"fr":"Code source",
"en":"Source code"
},
"sp_footjournal": {
"fr":"Journal des modifications",
"en":"Modifications log"
},
"sp_footlicence": {
"fr":"Code open source sous licence CC BY-NC-SA 4.0",
"en":"Open source code under CC BY-NC-SA 4.0 licence"
},
"sp_subtitle": {
"fr": '<span class="phon_k">C</span><span class="phon_o_maj">o</span><span class="phon_l">l</span><span class="phon_o_maj">o</span><span class="phon_r_maj">r</span><span class="phon_i">i</span><span class="phon_z">s</span><span class="phon_9">eu</span><span class="phon_r_maj">r</span><span> </span><span class="phon_f">Ph</span><span class="phon_o_maj">o</span><span class="phon_n">n</span><span class="phon_o_maj">o</span><span class="phon_g">g</span><span class="phon_r_maj">r</span><span class="phon_a">a</span><span class="phon_f">ph</span><span class="phon_e">é</span><span class="phon_m">m</span><span class="phon_i">i</span><span class="phon_k">que</span>',
"en": '<span class="phon_f">ph</span><span class="phon_arobase schwa">o</span><span class="phon_n">n</span><span class="phon_q_maj stress2">o</span><span class="phon_g">g</span><span class="phon_r_slash">r</span><span class="phon_cbrack">a</span><span class="phon_f">ph</span><span class="phon_i_long stress1">e</span><span class="phon_m">m</span><span class="phon_i_maj schwa">i</span><span class="phon_k">c</span><span> </span><span class="phon_k">c</span><span class="phon_v_maj stress2">o</span><span class="phon_l">l</span><span class="phon_arobase schwa">o</span><span class="phon_r_slash">r</span><span class="phon_ai_maj stress1">i</span><span class="phon_z">s</span><span class="phon_arobase schwa">e</span><span class="phon_r_slash">r</span>'
},
"sp_bicolor": {
"fr": '<span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">B</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">i</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">c</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">l</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">re</span>',
"en": '<span class="phon_b" style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">B</span><span class="phon_ai_maj stress1" style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">i</span><span class="phon_k" style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">c</span><span class="phon_arobase schwa" style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span class="phon_l" style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">l</span><span class="phon_arobase schwa" style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span class="phon_r_slash" style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">r</span>'
},
"sp_silentWay": {
"fr": '<span style="-webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;"><span class="text phon_s">S</span><span style="background:-webkit-linear-gradient(white 60%, #e7236d 75%);-webkit-background-clip: text;background-clip: text;-webkit-text-fill-color: transparent;">i</span><span class="text phon_l">l</span><span class="text phon_e_maj ">e</span><span class="text phon_n">n</span><span class="text phon_t">t</span><span class="text punct "> </span><span class="text phon_w">W</span><span class="text phon_ei_maj">ay</span></span>',
"en": '<span style="-webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;"><span class="text phon_s">S</span><span class="stress1" style="background:-webkit-linear-gradient(white 60%, #e7236d 75%);-webkit-background-clip: text;background-clip: text;-webkit-text-fill-color: transparent;">i</span><span class="text phon_l">l</span><span class="text phon_e_maj schwa">e</span><span class="text phon_n">n</span><span class="text phon_t">t</span><span class="text punct "> </span><span class="text phon_w">W</span><span class="text phon_ei_maj">ay</span></span>'
},
"sp_consigne": {
"fr": "Entrer du texte à coloriser :",
"en": "Enter some text to colorize:"
},
"sp_btnColoriser": {
"fr": "Coloriser",
"en": "Colorize"
},
"sp_btnErase": {
"fr": "Effacer",
"en": "Erase"
},
"sp_output": {
"fr": "Résultat :",
"en": "Output:"
},
"sp_btnEditDico": {
"fr": "Consulter/éditer le dictionnaire",
"en": "Search/edit WikiColor's dictionary"
},
"sp_footDic": {
"fr": "Dictionnaire (issu du Wiktionnaire) : ",
"en": "Dictionary (from Wiktionary's database): "
},
"sp_footAli": {
"fr": "Aligneur phonographémique : ",
"en": "Phonographemic aligner: "
},
"sp_tuto": {
"fr": "Accéder aux tutoriels WikiColor",
"en": "Access WikiColor's tutorials"
}
}
\ No newline at end of file
......@@ -6,13 +6,45 @@ $(document).ready(function(){
function selectLang(lang){
if (lang=="en"){
window.alert('English version still experimental :)');
interface("en");
document.getElementById('output').classList.remove('outputBold');
document.getElementById('monochromeLabel').style.display="";
document.getElementById('monochrome').style.display="";
document.getElementById('silentWayLabel').style.margin = "-20px 0px";
document.getElementById('bicolorLabel').style.margin = "-10px 0px";
document.getElementById('subtitle').style.marginTop = "-20px";
} else if (lang=="fr"){
interface("fr");
document.getElementById('output').classList.add('outputBold');
document.getElementById('monochromeLabel').style.display="none";
document.getElementById('monochrome').style.display="none";
document.getElementById('silentWayLabel').style.margin = "0px 0px";
document.getElementById('bicolorLabel').style.margin = "0px 0px";
document.getElementById('subtitle').style.marginTop = "0px";
}
}
interface("fr"); // default, temporary
function interface(lang) {
console.log("Langue d'interface:",lang);
thisPageLang = lang;
var langspanList = document.getElementsByClassName("langspan");
if (lang == "en") {
for (i=0; i<langspanList.length; i++) {
span = langspanList[i];
span.innerHTML = langJson[span.id]["en"];
}
} else { // "fr" par défaut
for (i=0; i<langspanList.length; i++) {
span = langspanList[i];
span.innerHTML = langJson[span.id]["fr"];
}
}
}
var dicoTok = {};
var dicoId = {};
......
......@@ -11,7 +11,6 @@ body {
}
h2 {
padding: 10px;
font-size: 2em;
font-weight: bold;
margin: auto;
......@@ -50,7 +49,8 @@ h2 {
.inputDiv h2 {
position: absolute;
top: 0;
top: 10px;
left: 15px;
text-align: left;
}
......
......@@ -16,12 +16,10 @@
</head>
<body>
{% include 'header.html' %}
<img src="{% static 'im/logo_wikicolor6b.png'%}" width="40%" title="WikiColor">
<h2>
<span class="phon_k">C</span><span class="phon_o_maj">o</span><span class="phon_l">l</span><span class="phon_o_maj">o</span><span class="phon_r_maj">r</span><span class="phon_i">i</span><span class="phon_z">s</span><span class="phon_9">eu</span><span class="phon_r_maj">r</span>
<span> </span><span class="phon_f">Ph</span><span class="phon_o_maj">o</span><span class="phon_n">n</span><span class="phon_o_maj">o</span><span class="phon_g">g</span><span class="phon_r_maj">r</span><span class="phon_a">a</span><span class="phon_f">ph</span><span class="phon_e">é</span><span class="phon_m">m</span><span class="phon_i">i</span><span class="phon_k">que</span>
</h2>
<div class="header"><span id="sp_header" class="langspan"></span></div>
<a href="https://alem.hypotheses.org/outils-alem-app/wikicolor" target="_blank"><img src="{% static 'im/logo_wikicolor6b.png'%}" width="40%" title="WikiColor"></a>
<h2 id="subtitle"><span id="sp_subtitle" class="langspan"></span></h2>
<div class="choixLang">
<select id="choixLang" onchange="selectLang(this.value)">
......@@ -32,14 +30,14 @@
<div class="inputDiv">
<div class="param">
<input id="monochrome" type="radio" name="colorType" onclick="toMonochrome()" value="mono"> <label for="monochrome"><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_m monochrome">M</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_q_maj stress1 monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_n monochrome">n</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_arobase schwa monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_k monochrome">ch</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_r_slash monochrome">r</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_arobaseu_maj monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_m monochrome">me</span></label><br/>
<input id="swcolor" type="radio" name="colorType" onclick="toSilentWay()" value="sw" checked> <label for="swcolor"><span style="-webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;"><span class="text phon_s">S</span><span style="background:-webkit-linear-gradient(white 60%, #e7236d 75%);-webkit-background-clip: text;background-clip: text;-webkit-text-fill-color: transparent;">i</span><span class="text phon_l">l</span><span class="text phon_e_maj ">e</span><span class="text phon_n">n</span><span class="text phon_t">t</span><span class="text punct "> </span><span class="text phon_w">W</span><span class="text phon_ei_maj">ay</span></span></label><br/>
<input id="bicolor" type="radio" name="colorType" onclick="toBicolor()" value="bi"> <label for="bicolor"><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">B</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">i</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">c</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">l</span><span style="color: #40b9ff; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">o</span><span style="color: #ff0000; -webkit-text-stroke-width: 0.5px; -webkit-text-stroke-color: #000000;">re</span></label>
<input id="monochrome" style="display: none;" type="radio" name="colorType" onclick="toMonochrome()" value="mono"> <label id="monochromeLabel" style="display: none;" for="monochrome"><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_m monochrome">M</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_q_maj stress1 monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_n monochrome">n</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_arobase schwa monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_k monochrome">ch</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_r_slash monochrome">r</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_arobaseu_maj monochrome">o</span><span style="color:black;background: transparent;-webkit-background-clip: unset;background-clip: unset;-webkit-text-fill-color: black;text-decoration: unset;" class="phon_m monochrome">me</span></label><br/>
<input id="swcolor" type="radio" name="colorType" onclick="toSilentWay()" value="sw" checked> <label id="silentWayLabel" for="swcolor"><span id="sp_silentWay" class="langspan"></span></label><br/>
<input id="bicolor" type="radio" name="colorType" onclick="toBicolor()" value="bi"> <label id="bicolorLabel" for="bicolor"><span id="sp_bicolor" class="langspan"></span></label>
</div>
<h2>Entrer du texte à coloriser :</h2>
<h2><span id="sp_consigne" class="langspan"></span></h2>
<textarea id="inText" class="inText"></textarea><br/>
<button id="coloriser" onclick="getColorisation()">Coloriser</button>
<button id="delInText" onclick="delInText()">Effacer</button>
<button id="coloriser" onclick="getColorisation()"><span id="sp_btnColoriser" class="langspan"></span></button>
<button id="delInText" onclick="delInText()"><span id="sp_btnErase" class="langspan"></span></button>
</div>
<div id="outputDiv" class="win-black outputMainDiv">
......@@ -48,12 +46,12 @@
<span class="glyphicon glyphicon-duplicate" aria-hidden="true" title="Copier/Coller le contenu" onclick="getPopUp()"></span><br>
<span class="glyphicon glyphicon-bold" aria-hidden="true" title="Activer/désactiver la police en gras" onclick="toggleBold()"></span>
</div>
<h2>Résultat :</h2>
<h2><span id="sp_output" class="langspan"></span></h2>
<div id="output" class="output outputBold"></div>
</div>
<div>
<a href="/app/dico/"><button>Consulter/éditer le dictionnaire</button></a>
<a href="/app/dico/"><button><span id="sp_btnEditDico" class="langspan"></span></button></a>
</div>
<!-- Modal PopUp qui apparaît lors de l'enregistrement -->
......@@ -99,6 +97,7 @@
{% include 'footer.html' %}
<script type="text/javascript" src="{% static 'languages/languages.js' %}"></script>
<script src="{% static 'scripts/loc2stand.js' %}"></script>
<script src="{% static 'scripts/main.js' %}"></script>
<script src="{% static 'scripts/keyboard.js' %}"></script>
......
{% load static %}
<footer>
<div style="font-size: 20pt;"><a href="https://alem.hypotheses.org/outils-alem-app/wikicolor" target="_blank"><span id="sp_tuto" class="langspan"></span></a></div>
<div>S.Coulange, {{data.update}} |
<a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikicolor">Code source</a>
- <a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikicolor/commits/master">Journal des modifications</a>
<a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikicolor"><span id="sp_footcode" class="langspan"></span></a>
- <a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikicolor/commits/master"><span id="sp_footjournal" class="langspan"></span></a>
</div>
<div class="licence-div">
<div>Code open source sous licence CC BY-NC-SA 4.0</div>
<div><span id="sp_footlicence" class="langspan"></span></div>
<div><a href="https://creativecommons.org/licenses/by-nc-sa/4.0/" title="Attribution-NonCommercial-ShareAlike 4.0 International"><img height="30px" src="{% static 'im/cc-by-nc-sa.png' %}" title="Attribution-NonCommercial-ShareAlike 4.0 International" class="licence-element licence-img"/></a></div>
<div>Dictionnaire (issu du Wiktionnaire) : <a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikiphon">wikiPhon</a></div>
<div>Aligneur phonographémique : <a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/phon2graph">phon2graph</a></div>
<div><span id="sp_footDic" class="langspan"></span><a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/wikiphon">wikiPhon</a></div>
<div><span id="sp_footAli" class="langspan"></span><a href="https://gricad-gitlab.univ-grenoble-alpes.fr/pedagogies-multimodales/phon2graph">phon2graph</a></div>
</div>
</footer>
\ No newline at end of file
<div class="header">Cette application est un prototype en cours de conception. <a href="https://groups.google.com/d/forum/alem-app" target="_blank"><b>Accéder au forum</b></a> pour échanger avec la communauté et faire vos suggestions.</div>
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment