diff --git a/data/css/contrast-finder-addon.css b/data/css/contrast-finder-addon.css
index 32db19f..f071b28 100644
--- a/data/css/contrast-finder-addon.css
+++ b/data/css/contrast-finder-addon.css
@@ -68,6 +68,7 @@ a {
border-color: #656565;
text-align: left;
margin-bottom: 10px;
+ margin-right: 6px;
}
.bs-callout-danger {
@@ -105,6 +106,7 @@ a {
#submit {
margin-top: 10px;
width: 100%;
+ white-space: normal;
}
.my-fieldset legend {
diff --git a/data/js/form.js b/data/js/form.js
index 70d749f..7c25925 100644
--- a/data/js/form.js
+++ b/data/js/form.js
@@ -53,7 +53,7 @@ addon.port.on("click-components", function(tabResult) {
var openUrl = "http://contrast-finder.tanaguru.com/result.html?foreground=%23"
+ foreground.textContent.replace("#", "") + "&background=%23" + background.textContent.replace("#", "")
- + "&isBackgroundTested=" + backgroundIsTested + "&ratio= "
+ + "&isBackgroundTested=" + backgroundIsTested + "&ratio="
+ ratio + "&algo=HSV";
submit.href = openUrl;
@@ -77,8 +77,7 @@ function initializeHtmlElements() {
document.getElementById("invalid-ratio").style.display = "none";
document.getElementById("channel-alpha").style.display = "none";
document.getElementById("valid-ratio").style.display = "none";
- var languageReference = document.getElementById("language-reference").textContent;
- if (languageReference == "Avant plan") {
+ if (document.getElementById("language-reference").textContent == "Avant plan") {
submit.title = "Trouver des couleurs valides (vous emmenera sur Tanaguru Contrast-Finder dans un nouvel onglet)";
}
}
diff --git a/lib/main.js b/lib/main.js
index c04cec5..e3201c8 100644
--- a/lib/main.js
+++ b/lib/main.js
@@ -23,6 +23,7 @@ var sidebar = require("sdk/ui/sidebar").Sidebar({
title: 'Tanaguru Contrast Finder',
url: data.url("contrast-finder-module.html"),
onAttach: function (worker) {
+ worker.port.emit("lang");
var tabWorker = null;
workers.push(worker);
tabs.on("open", function() {