Factor out text link parser