NSW will enforce a lockdown for four Sydney council areas as the state records 22 new local cases of COVID-19.