James Spigelman has told the ABC's Stephen Dzieczic that China's national security law was a factor in his resignation.