Liam neesan
Liam neesan

Reputation: 2571

Brackets inverted in Arabic text when passing them to TanstackTable

The arabic text which contains brackets not formatting correctly. A text without bracket is no issue:

eg: صابون ديتول اوريجنال عرض خاص (6×165)جم

When I print in console or directly in HTML element, it is printed with correct format as above.

But when I pass the data to TanstackTable, it will print as below:

text with brackets inverted

So far I unsuccessfully tried in column_def the following:

columnHelper.accessor("extendedDescription", {
  header: theme.isArabic ? "وصف" : "Extended Description",
  cell: (info) => {
    console.log('column Extended Description =>',info.getValue() )
    return (
      <Box width={"350px"}>
        // JSON.stringify(info.getValue())  -- I tried this also
        // <Typography>{info.getValue()}</Typography> -- tried
        <p>{info.getValue()}</p>
      </Box>
    );
  },
  size: 350,
  enableSorting: false,
}),

Upvotes: 1

Views: 39

Answers (0)

Related Questions