Surveys provide some evidence and can influence our judgment. It is certainly far less convincing than a full study but, given the recency of the election, we don't have the luxury of scientific studies.
That said, I agree there were likely more folks on the left who chose not to vote because of the Democrats' stance on Gaza. But we genuinely cannot know exactly how the magnitude of each compare. Both are probably sufficient to swing the election, imo.