I'm not sure how it works, maybe there's some metadata in the HTML. You can see the same thing in action with the Jira app on Cataline now - any Jira link you click will load up and render in the native app.
That said, it's definitely a problem when you're redirecting these links to things you don't actually support any more, without any way to opt out.