It's an annoying thing, but it can happen, that other authors have exactly the same idea as you at exactly the same time. They call it zeitgeist.
I had a bad case of zeitgeist in 1979 with my third picture book, Fly Home McDoo, a story about a racing pigeon. Within a week or so of publication two other racing pigeon stories had appeared: Mr Potter's Pigeon illustrated by Reg Cartwright
and Bertha and the Racing Pigeon written and illustrated by Pam Ayres. Needless to say, McDoo lost the race.
There's not much you can do about zeitgeist - when an idea is 'in the air' we're all tapping into it.
It was donkeys not pigeons in 1993. I did The Christmas Donkey embellished with gold
and Jan Ormerod illustrated Father Christmas and the Donkey embellished with silver.
That bit of zeitgeist worked to both Jan's and my advantage when, in December 1999, I was unable to give a Christmas Donkey talk to some librarians because I had to go into hospital. At short notice Jan kindly gave the talk for me and was able to give the librarians value for money by adding an extra bit on her Christmas donkey book and selling lots of copies of both.