PablocFonseca / streamlit-aggrid

Implementation of Ag-Grid component for Streamlit
https://pypi.org/project/streamlit-aggrid/
MIT License
991 stars 191 forks source link

Cell renderer issues when deployed on linux #208

Open amitmadahar opened 1 year ago

amitmadahar commented 1 year ago

using cell renderer to render a hyperlink column of a dataframe produces different results on windows and linux.

Cell renderer:

jsCodeLink = JsCode("""function(params) {return `<a href="${params.value}" target="_blank"> Source Link </a>`}""") 

Attaching Cell Renderer to ag-grid:

builder.configure_column("Hyperlink",
                                headerName="Link",
                                cellRenderer= jsCodeLink,
                                width=100)

Output in windows is as expected: Hyperlink displayed as hyperlink. image

Output in linux is rendered as text with the same renderer. image

Unescaping in javascript and or in AgGrid does not fix the issue.