Revert the usage of JsonObject. It increases pub build warnings (and possibly
the generated code size), and make the dialog not working.