]> git.openstreetmap.org Git - rails.git/commitdiff
Merge remote-tracking branch 'upstream/pull/5614'
authorTom Hughes <tom@compton.nu>
Thu, 6 Feb 2025 17:19:32 +0000 (17:19 +0000)
committerTom Hughes <tom@compton.nu>
Thu, 6 Feb 2025 17:19:32 +0000 (17:19 +0000)
app/assets/javascripts/edit/id.js.erb
app/assets/javascripts/index.js
app/assets/javascripts/index/directions-endpoint.js
config/eslint.js

index 3af6fd3dc6339784fd23118b43495e438ed7b4f5..588aa1e86ae2918318518d6acc438771899f88fe 100644 (file)
@@ -2,6 +2,7 @@ $(document).ready(function () {
   const id = $("#id-embed");
 
   if (id.data("configured") === false) {
+    // eslint-disable-next-line no-alert
     alert(I18n.t("site.edit.id_not_configured"));
     return;
   }
index 8ef067740d6025bc6ad0f0f988d69cfcb18f3baa..4555553ee7fb6868950d208a1b0233d2928d73f2 100644 (file)
@@ -255,6 +255,7 @@ $(document).ready(function () {
       fetch(url, { mode: "no-cors", signal: AbortSignal.timeout(5000) })
         .then(callback)
         .catch(function () {
+          // eslint-disable-next-line no-alert
           alert(I18n.t("site.index.remote_failed"));
         });
     }
index 30d499ad731707b404dc1ca3448af2e215cfb7d7..3fdae7c5413560139ada1e4150957d84523da2c5 100644 (file)
@@ -108,6 +108,7 @@ OSM.DirectionsEndpoint = function Endpoint(map, input, iconUrl, dragCallback, ch
       delete endpoint.geocodeRequest;
       if (json.length === 0) {
         input.addClass("is-invalid");
+        // eslint-disable-next-line no-alert
         alert(I18n.t("javascripts.directions.errors.no_place", { place: endpoint.value }));
         return;
       }
index cb421a9920ce3874ab151c49e340c4ce189fdb1e..f70cbc6c057d9eaf8cdeca902d7a9a6d3a6172a7 100644 (file)
@@ -86,7 +86,7 @@ module.exports = [
       "curly": ["error", "multi-line", "consistent"],
       "dot-notation": "error",
       "eqeqeq": ["error", "smart"],
-      "no-alert": "warn",
+      "no-alert": "error",
       "no-array-constructor": "error",
       "no-caller": "error",
       "no-console": "warn",