Ruling on a woman divorced by khul‘ remarrying the one who divorced her when she is still observing ‘iddah
Question

I had been married to my husband for two years and we have one child together. I am now 4 months pregnant and about 2 months ago I was granted a Khulah. Now me and my ex regret this choice and I feel as though I could have been more patient with him in our marriage. do I have to wait until I give birth and clean from my bleeding before I can remarry him or can I do it while I am pregnant
Praise be to Allah.Khul‘ means that the wife is completely divorced from the husband in the sense of minor divorce, and she is not permissible for the one who divorced her by khul‘ except with a new marriage contract.
What is required of the woman who has been divorced by khul‘ is to observe ‘iddah for one menstrual cycle, according to the correct scholarly view, unless she is pregnant, in which case her ‘iddah ends when she gives birth.
It is permissible for her former husband to do a new marriage contract with her and consummate the marriage with her during her ‘iddah; what is prohibited is for someone else to marry her during her ‘iddah.
Ibn Qudamah (may Allah have mercy on him) said: If a man divorces his wife by khul‘ or annuls the marriage, he may remarry her during her ‘iddah according to the view of the majority of jurists. This is the view of Sa‘id ibn al-Musayyab, ‘Ata’, Tawus, az-Zuhri, al-Hasan, Qatadah, Malik, ash-Shafa‘i and ashab ar-ra’y.
Some of the later scholars had an odd view and said: it is not permissible for him to marry her or propose to her, because she is observing ‘iddah.
Our view is that the purpose of the ‘iddah is to preserve his lineage and protect his semen [from being mixed with that of another man, if she were to marry someone else during her ‘iddah] and there is no point in protecting his own semen from his semen, if their initial marriage was valid."(Al-Mughni  8/127).
Ibn Kathir (may Allah have mercy on him) said in his Tafsir (1/620): All scholars are agreed that the one who divorced his wife by khul‘ may remarry her during her ‘iddah. Shaykh Abu ‘Umar ibn ‘Abd al-Barr narrated from a group that it is not permissible for him to do that, just as it is not permissible for anyone else, but this is an odd view and is to be rejected. End quote.
Based on that:
There is nothing wrong with you doing a new marriage contract now, before giving birth.
And Allah knows best.