The Israeli military said the strike, which Palestinian officials said killed at least 29 people, targeted a Hamas fighter who took part in the Oct. 7 raid on Israel.