Massachusetts voters have approved a ballot measure allowing ride-share drivers for app-based companies like Uber and Lyft to unionize.