Well, I am not having Librem 5, neither PinePhone to proof/test this (at the moment). Can someone else show how Web interface control and interact with their Kodi device from Librem 5? Anyway, by thanking you on posting this official link, interaction through local-wi-fi with Kodi looks very promising!
P.S. Optionally, as I believe that Librem 5 have no IR, still might happen that open source community provide us with SW for something like IR blaster on 3.5mm stereo jack plug or even SW for Baseus RO2 Type-C Universal IR remote control (or something alike). The PinePhone have six of gold ‘pogo pins’ that can provide power, I2C, and GPIO to an attached accessory (keyboard case attachment, wireless charging or an IR blaster), so future development on Linux phone is not questionable, IMHO.