Add the `dir="rtl"` attribute if the page language is RTL (see #7171)