Hamas never had a chance against IDF in a military clash. They try to erode international support for Israel instead, by dragging the giant into a long and dirty fight.
They also need to take care about their domestic support. In both cases, it is good for Hamas when IDF does cruel things.
So the strategic goal of continued fighting is to show everyone, abroad and at home, how evil Israel is, to stay in power.