瀏覽代碼

add attribut dangerouslySetInnerHTML to fix the wysiwyg comment in the timeline

AlexiCauvin 7 年之前
父節點
當前提交
1c74424b56
共有 1 個文件被更改,包括 2 次插入6 次删除
  1. 2 6
      frontend_lib/src/component/Timeline/Comment.jsx

+ 2 - 6
frontend_lib/src/component/Timeline/Comment.jsx 查看文件

35
       <div
35
       <div
36
         className={classnames(`${props.customClass}__messagelist__item__content`, 'timeline__body__messagelist__item__content')}
36
         className={classnames(`${props.customClass}__messagelist__item__content`, 'timeline__body__messagelist__item__content')}
37
         style={props.fromMe ? styleSent : styleReceived}
37
         style={props.fromMe ? styleSent : styleReceived}
38
-
39
-      >
40
-        <div className='timeline__body__messagelist__item__content__text'>
41
-          {props.text}
42
-        </div>
43
-      </div>
38
+        dangerouslySetInnerHTML={{__html: props.text}}
39
+      />
44
     </li>
40
     </li>
45
   )
41
   )
46
 }
42
 }