Skip to content

Commit

Permalink
fix(discover): break new lines in table cell
Browse files Browse the repository at this point in the history
fixes opensearch-project#7177

Signed-off-by: Joshua Li <joshuali925@gmail.com>
  • Loading branch information
joshuali925 committed Jul 9, 2024
1 parent 3a32191 commit 9a98377
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -95,3 +95,7 @@
font-size: inherit !important;
}
}

.osdDocTableCell__dataField {
white-space: pre-wrap;
}
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,11 @@ const TableCellUI = ({
}: TableCellProps) => {
const content = (
<>
{/* eslint-disable-next-line react/no-danger */}
<span dangerouslySetInnerHTML={{ __html: sanitizedCellValue }} />
<span
className="osdDocTableCell__dataField"
// eslint-disable-next-line react/no-danger
dangerouslySetInnerHTML={{ __html: sanitizedCellValue }}
/>
<span className="osdDocTableCell__filter">
<EuiToolTip
content={i18n.translate('discover.filterForValue', {
Expand Down

0 comments on commit 9a98377

Please sign in to comment.