There is a known bug with Snaps that osk is not properly called up with them. From my understanding Mir 2.x integration is needed to fix this, and while this is something the core dev team is working on, it might be a few months before it arrives for UT. A possoble work around is to use bluetooth keyboard with these apps.
For Firefox, I would suggest installing the version built for UT by Fuseteam, it features osk working, along with touch scrolling, pinch to zoom, as well as some tweaks to the gui better optimizong it for mobile use. Just download the most recent build for arm64, unzip, and then open the click in Open Store to install - https://gitlab.com/debclick/uFirefox/-/artifacts
Best regards,
Steve Berson