Fix maxVisibleLevels to have be optional.