Content Tracking is Broken on Matomo v4

I upgraded to Matomo version 4.2.1 from 3.14.1 for numerous reasons. One of the reasons was due to the fact that Content Tracking in the latest version was getting rid of the href redirect rewrite that happens when content interactions are being logged. This was noted in multiple places:

However, after the upgrade, the code is definitely still behaving the same: all content blocks that track interactions on anchor tags are having their href attribute values replaced with a link to the Matomo tracking server address with a https://MATOMO.DOMAIN/matomo.php?redirecturl=https... URL.

Not only that, but the link is actually broken in version 4. In version 3 the redirect at least worked. In Firefox and Chrome the link does not open, so despite clicking on an anchor tag, nothing happens. Opening the link in a new tab just shows nothing. In Chrome, at least visiting the URL in a new tab leaves a message:

This resource is a part of Matomo. Keep full control of your data with the leading free and open source […]

What’s happening here? For one, the behaviour documented in commits and this forum for version 4 are contrary to the actual behaviour. Secondly, the replaced URLs (which should no longer be a thing) are actually broken.

Another supporting link:

It seems that everyone is stating that the behaviour has changed, yet it hasn’t based on the fact my instance of Matomo has been upgraded.

@Lukas