Refactor partials for docs pages