aboutsummaryrefslogtreecommitdiffstats
path: root/webui/src/pages/bug/MessageHistoryDialog.tsx
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2021-04-12 19:26:29 +0200
committerGitHub <noreply@github.com>2021-04-12 19:26:29 +0200
commit62fb09a53cc626ac581f33b466a1cdf14eb6ed89 (patch)
treec887d96fab77a6c312cf7047daa4d6944b53c89e /webui/src/pages/bug/MessageHistoryDialog.tsx
parent491f0ea9513e8080f6b38885b1a05f47fb56d9dc (diff)
parentacfaf6b50f2ecb16add94874c0f8dfc401788d9b (diff)
downloadgit-bug-62fb09a53cc626ac581f33b466a1cdf14eb6ed89.tar.gz
Merge pull request #624 from GlancingMind/upstream-fix-and-improve-rendering-of-markdown-elements
WebUI: Fix and improve rendering of markdown elements
Diffstat (limited to 'webui/src/pages/bug/MessageHistoryDialog.tsx')
-rw-r--r--webui/src/pages/bug/MessageHistoryDialog.tsx8
1 files changed, 7 insertions, 1 deletions
diff --git a/webui/src/pages/bug/MessageHistoryDialog.tsx b/webui/src/pages/bug/MessageHistoryDialog.tsx
index 0ed33642..5879a373 100644
--- a/webui/src/pages/bug/MessageHistoryDialog.tsx
+++ b/webui/src/pages/bug/MessageHistoryDialog.tsx
@@ -22,6 +22,8 @@ import {
import CloseIcon from '@material-ui/icons/Close';
import ExpandMoreIcon from '@material-ui/icons/ExpandMore';
+import Content from '../../components/Content';
+
import { AddCommentFragment } from './MessageCommentFragment.generated';
import { CreateFragment } from './MessageCreateFragment.generated';
import { useMessageHistoryQuery } from './MessageHistory.generated';
@@ -108,6 +110,7 @@ const AccordionSummary = withStyles((theme) => ({
const AccordionDetails = withStyles((theme) => ({
root: {
+ display: 'block',
padding: theme.spacing(2),
},
}))(MuiAccordionDetails);
@@ -214,6 +217,7 @@ function MessageHistoryDialog({ bugId, commentId, open, onClose }: Props) {
{history?.map((edit, index) => (
<Accordion
square
+ key={index}
expanded={expanded === 'panel' + index}
onChange={handleChange('panel' + index)}
>
@@ -224,7 +228,9 @@ function MessageHistoryDialog({ bugId, commentId, open, onClose }: Props) {
>
<Typography>{getSummary(index, edit.date)}</Typography>
</AccordionSummary>
- <AccordionDetails>{edit.message}</AccordionDetails>
+ <AccordionDetails>
+ <Content markdown={edit.message} />
+ </AccordionDetails>
</Accordion>
))}
</DialogContent>