The contribution of HI-bearing ultra-diffuse galaxies to the cosmic number density of galaxies