Do not track click link

try track me click on forum.dobreprogramy.pl, remove redirect.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

ستحتاج إلى تثبيت إضافة مثل Stylus لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتتمكن من تثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

ستحتاج إلى تثبيت إضافة لإدارة أنماط المستخدم لتثبيت هذا النمط.

(لدي بالفعل مثبت أنماط للمستخدم، دعني أقم بتثبيته!)

// ==UserScript==
// @name         Do not track click link 
// @description  try track me click on forum.dobreprogramy.pl, remove redirect.
// @match        https://forum.dobreprogramy.pl/
// @include      https://forum.dobreprogramy.pl/*
// @icon         https://i.imgur.com/aoGUAKi.png
// @homepageURL  https://greasyfork.org/pl/scripts/37660-do-not-track-click-link
// @version      1.1.2
// @author       krystian3w
// @run-at       document-idle
// @grant        none
// @compatible   firefox Firefox
// @compatible   chrome Chrome
// @compatible   edge Edge
// @compatible   opera Opera
// @compatible   safari Safari
// @namespace https://greasyfork.org/users/167625
// ==/UserScript==

(function() {
    'use strict';

    function addNoTrackLinks() {
        document.querySelectorAll('.regular.contents .cooked a[href*="//"], .regular.contents .cooked a[href^="/uploads/"], .excerpt a[href*="//"], .excerpt a[href^="/uploads/"]').forEach(function(link) {
            link.classList.add('no-track-link');
        });
    }

    window.addEventListener("DOMContentLoaded", addNoTrackLinks);

    const observer = new MutationObserver(function(mutations) {
        mutations.forEach(function(mutation) {
            mutation.addedNodes.forEach(function(node) {
                if (node.nodeType === 1 && node.tagName === 'A') {
                    addNoTrackLinks();
                }
            });
        });
    });

    observer.observe(document.body, { childList: true, subtree: true });

    document.body.addEventListener("mouseover", function(event) {
        if (event.target.tagName === 'A') {
            addNoTrackLinks();
        }
    });
})();