The story of Shrek and its sequels contain and reference many different fairy/folk tales. However, I am not familiar with the story of Fiona - a woman imprisoned in a dragon-guarded castle who is cursed to transform into an ogre every night, and will only settle on a form after true love's first kiss.
Is this based on a preexisting story or were Fiona and her story written just for the movie?