The "principle of proportionality" deals with excessive harm to civilians in relation to the expected military advantage, while recognizing that some civilian casualties may be unavoidable when pursuing legitimate military objectives.
International law assesses proportionality from the standpoint of a "reasonable military commander," and his or her decisions in the field may not be second-guessed in hindsight, based on new information that has come to light.
The IDF always weighed the risk of civilian harm against the importance of military objectives, based on the information available at the time the decisions were required.
Extended Answer