Duality between the deconfined quantum-critical point and the bosonic topological transition