diff --git a/assets/js/components/EcoIndexDialog.js b/assets/js/components/EcoIndexDialog.js index ba663f9e..e19e1de3 100644 --- a/assets/js/components/EcoIndexDialog.js +++ b/assets/js/components/EcoIndexDialog.js @@ -17,6 +17,12 @@ const ERROR_MESSAGES = { `, 504: ` {{- i18n "Error504" | markdownify -}} +`, + 520: ` +{{- i18n "Error520" | markdownify -}} +`, + 521: ` +{{- i18n "Error521" | markdownify -}} `, }; @@ -47,8 +53,8 @@ class EcoIndexDialog { // prettier-ignore a11yDialog - .on("show", () => (html.style.overflowY = "hidden")) - .on("hide", () => (html.style.overflowY = "")); + .on("show", () => (html.style.overflowY = "hidden")) + .on("hide", () => (html.style.overflowY = "")); return this; } diff --git a/i18n/en.toml b/i18n/en.toml index 0f9d7f8f..ba8c351c 100644 --- a/i18n/en.toml +++ b/i18n/en.toml @@ -76,6 +76,10 @@ More information on page [How it works](/how-it-works/).""" other = "The URL you provided is not valid. Please check the URL and try again." [Error504] other = "The page you want to test does not respond. Please try again later." +[Error520] + other = "This resource you want to test is not a standard HTML page with mimeType 'text/html'" +[Error521] + other = "The page you want to test can not be analyzed because its response status code is not 200" [BetaMessage] other = "This site is in **beta** version. Feel free to give us feedback on [Github discussions](https://github.com/cnumr/EcoIndex/discussions/)" [NoJSMessage] diff --git a/i18n/fr.toml b/i18n/fr.toml index f8bf793b..62e143f0 100644 --- a/i18n/fr.toml +++ b/i18n/fr.toml @@ -76,6 +76,10 @@ Pour en savoir plus, veuiller consulter la page [Comment ça marche ?](/commen other = "L’url demandée n’est pas valide. Veuillez vérifier l’URL et réessayer." [Error504] other = "La page web indiquée ne semble pas répondre. Pouvez vous réessayer plus tard ?" +[Error520] + other = "La ressource que vous essayez d'analyser n'est pas une page HTML standard avec un mimetype 'text/html'" +[Error521] + other = "La page que vous essayez de tester ne peut pas être analysée car elle est en erreur (son code réponse n'est pas 200)" [BetaMessage] other = "Ce site est en version **beta**. N’hésitez pas à nous faire part de vos commentaires sur [les discussions Github](https://github.com/cnumr/EcoIndex/discussions/)" [NoJSMessage]