Totally true! I would love to see that. In practice, I doubt that will happen because contributing to GnuCash seems to require a lot of nuanced understanding of their very old codebase and build system. OP's PDF generator is a web app, while GnuCash has basically no way to run in a browser.
That's actually why I built GnuCash-Helper[0]. It's a web-based personal finance tool written with Python and Flask that works with GnuCash files. It's not nearly ready for prime time, but I use it daily, and I don't even open GnuCash anymore.
In general, I really wish that GnuCash would get a visual refresh and some more modern features. It's amazing, but it looks very 2006, and it has bad stories for mobile and web. Obviously, HN readers are a different breed, but good luck convincing most people to run desktop-only software in 2023.
Refs:
0. https://github.com/bxbrenden/gnucash-helper