I normally always score in favor of the striker over the wrestler in close fights, but I can see how one could give this to Gadelha. Gadelha would have won a unanimous decision had she not been dropped in the 1st.
Most of the 1st and the 3rd were Gadelha controlling JJ. She couldn't hold her down at all but she did get her down repeatedly and landed some GNP during the grappling exchanges. In these rounds, when they were separated, JJ didn't have any period of prolonged success on the feet, making it easy to give round 3 to Gadelha. Round 1 would be the same if it wasn't for the uppercut that dropped Gadelha.
More time was spent on the feet in round 2 than in the other rounds. JJ had an edge on the feet but it wasn't huge. She didn't show even nearly the dominance that she did against Esparza and Penne. While she only had a small edge, Gadelha was again able to get takedowns. Overall, you could give the round to either fighter.
Round 3 was the only round that was easy to give to Gadelha. There's reasons to give both fighters either round 1 or round 2. It's why scores range from 29-28 JJ to 30-27 Gadelha. I personally prefer to give both rounds to JJ, but I admit I'm biased.
You'd expect a 5-round fight to favor JJ for sure, as Gadelha gasses herself out spending all the time trying to take JJ down. But if either fighter makes a significant improvement and is able to impose their game better than they did in the first fight, it's likely that they'll win.