Connected components of compact matrix quantum groups and finiteness conditions