There was definitely a period of (at least subjective) declining battery life in the 2010s but IMO things are shifting the other way. Some devices these days have much improved battery life over what came before, like Apple silicon, the Steam Deck, and most flagship phones. They're not always an order of magnitude better than the past, but better enough to unluck many use cases (doing a long work session away from a charger, being able to game for several hours anywhere, and not worrying about having to charge my phone until I get home, respectively).
If I had to describe it loosely, we've had 3 "eras" of battery-powered computing:
- Relatively simple devices (like the Gameboy) that lasted forever, because they just didn't do much
- Full-featured personal computing finally becoming "viable" on mobile devices, but with a clear cost (I remember <1 hour battery life laptops)
- More power-efficient HW and kinda-sorta-maybe-starting-to-be optimized SW that makes full-fat mobile computing much more bearable