Hamas is taking part in the Palestinian legislative elections for the first time .