Adds a workaround to fix the styling problem when adding header and footer.