add preview_mode and pageroot context variables