Type safety for total- and visiblePages options (issue#17)