Merge "Open all commentlink-specified links in new tabs"

This commit is contained in:
Wyatt Allen
2017-02-17 23:33:13 +00:00
committed by Gerrit Code Review

View File

@@ -65,6 +65,13 @@
}
}, this.removeZeroWidthSpace);
parser.parse(content);
// Ensure that links originating from HTML commentlink configs open in a
// new tab. @see Issue 5567
output.querySelectorAll('a').forEach(function(anchor) {
anchor.setAttribute('target', '_blank');
anchor.setAttribute('rel', 'noopener');
});
},
});
})();