The violence came after the United States and Israel attacked Iran and killed the country’s supreme leader, Ayatollah Ali Khamenei.