MediaWiki:Gadget-wikt.remove-pronunciation-links.js

Remarque: après avoir sauvegardé, vous devez vider le cache de votre navigateur pour que les changements prennent effet. Mozilla, cliquez sur Actualiser (ou ctrl-r). Internet Explorer / Opera: ctrl-f5. Safari: cmd-r. Konqueror ctrl-r.

"use strict";

console.log("Chargement de Gadget-wikt.remove-pronunciation-links.js…");

window.wikt.gadgets.removePronunciationLinks = {
  init: function () {
    $("a span[class='API']").each(function (_, e) {
      var $link = $(e).parent();
      if ($link.attr("href").includes("Annexe:Prononciation")) {
        $link.after($link.children());
        $link.remove();
      }
    });
  },
};

wikt.gadgets.removePronunciationLinks.init();