The west bank isn't at war with Israel. There wasn't some conflict or event that has justified these actions.
I wish people understood this better. Even if you could manage to justify what's happening in gaza as "this is war", Gaza and the west bank are separate entities with separate governments. The west bank, in particular, is more like an Indian reservation in the US, with the Israeli government effectively exercising supremacy over all aspects of the government.
Theoretically, the IDF is supposed to be the police force for the west bank. That's why they occupy it.
Except this situation has been going on like this for 60 years - with Israel, or the other western states having absolutely no plans to change anything about it (except making it even worse).
genocide 101