Japan's top government spokesman says China's passage of a national security law for Hong Kong is regrettable.