Reality has types and identity. Static types just make sense.
That all being said, the JVM has never broken into local apps, even with JavaFx. I think the thought of installing a JVM, plus then installing an app is no longer a workflow most users will tolerate. Electron has proved though people don't mind downloading a multi-gig app anymore however, so maybe this is no longer an issue.
MCPs and complex CLI tools running locally/native via graalvm might be a great usecase for Java. https://quarkus.io/blog/mcp-server/