I have a column in my SQL table called Content which contains full HTML templates, for example:
Error: Optos is not covered by VSP.
? Save order.
? Select Price Order.
? Save the order and proceed as usual.
When I display this column in a Metabase table, it shows the raw HTML tags, not the rendered HTML.
I would like the table cell to show the formatted HTML exactly as a browser would render it (e.g., red heading, line breaks, paragraphs, etc.).
My questions are:
Is there any way to make Metabase table cells render HTML content instead of escaping it?
If not, is there a recommended workaround for showing formatted HTML from a SQL field inside Metabase?
Is this feature available in Enterprise Edition, or planned in future versions?
I am aware of Text Cards in dashboards, but I specifically need HTML rendering inside table cells, not dashboard cards.
A big difficulty with this is compatibility issues between Metabase CSS/styling and the imported HTML unless the imported HTML is very vanilla. It works for iframe cards as it creates a whole new CSS context.
You can use variables on iframe cards. If you have a way to make a web service/CGI script that can output the HTML column, here’s a potential solution. Put a click action on the row that sets a filter to the row ID and switches to another tab. That tab has an iframe card on it that picks up the row ID and sends it to a web service that returns the HTML of the template column for that ID. You then get the template in the iframe.
This feature request from GitHub is tangentially related: