I think of this book as Elephants Play. Ed and Kip, by Kay Chorao, is a Holiday House I Like to Read book, published in 2014.
It is about two child elephants who are playing ball. They wake up a bug, who is not happy, and then instantly become friends. The jump there was a bit too big for me. The crocodile was well set up, however. When the bug becomes the hero and rescues the elephant… I guess it is the mouse and the lion, but it seemed a bit ridiculous. On the other hand, the elephants pitching the rock they’d been playing with into the croc’s mouth was brilliant.
Overall it was a fun book.