Cross posted on community.wolfram.com
Example
choices = {
"label 1" -> 1
, Column[{"label", 2}] -> 2
, Framed[3] -> 3
, HoldForm @ Sum[i, {i, 0, ∞}] -> 4
};
CloudDeploy @ FormFunction[
{ "a" -> <|
"Interpreter" -> choices
, "Control" -> (RadioButtonBar[##, Appearance -> "Vertical"] &)|>
}
]
So by default StandardForm is not supported (though e.g. Column
is).
My attempts to fix it
I tried to force
"HTMLCloudCDF"
as an export form for those elements:... "Interpreter" -> MapAt[ExportForm[#, "HTMLCloudCDF"] &, choices, {All, 1}] ...
But it is not supported.
At the end I am using:
ExportForm[#, "SVG"] &
but it makes fonts inconsistent with the rest of the form and selected item's label gets an ugly red frame if it is an image:
Question
How to use arbitrary expressions in form functions layout? Is there a better way than SVG? Shouldn't it work out of the box?