Pro-democracy lawmaker to resign from HK legislature