I have, but not while I had a child of my own, and a former relationship. It was a serious relationship, he was one of the big loves of my life, and he loved me passionately. But it was in the 80' / 90s, we worked in the arts, and it was normal for people to have 'understanding' and non-jealous (to a point ) open relationships.
But there was an understanding that he and I were the main item, and we mostly lived together - but he (and I ) had other relationships - friendships that sometimes turned sexual, occasional flings. One of his 'occasionally sexual friendships' resulted in her having a baby. I knew / know her.
To begin with i was wild, furious and jealous. Then it was a bit hostile - but then I came to really love the child. She lived with us for about a third of the time, we took her on hol, he would sometimes spend time alone with her, with her and her Mum, or with me. All v bohemian. I never wanted to do anything that would undermine his relationship with the child as I felt that she didn't deserve that.
Eventually we broke up. He has issues, and was always pushing me to prove that I didn't love him. "now look what i've done - now we'll see that you don't truly love me". I did love him, but his doubt that he could be loved was terribly destructive to him and abusive to me.
I still maintain contact with the child. Now grown up).
Could I have done that had i had a child of my own? I don't know. Maybe. I was free of the 'usual morals and judgements' at the time. Maybe I would have accommodated it because I had to - maybe it would have been easier to leave him since I had no dependency on him as co-parent, or feeling that I had to preserve a relationship for my own child with it's father.