Adds new code to handle RTL in all browser environments