mirror of
https://github.com/astuto/astuto.git
synced 2025-12-16 03:37:56 +01:00
Add markdown support (#115)
This commit is contained in:
committed by
GitHub
parent
78049a820c
commit
35c427d9f6
@@ -1,10 +1,10 @@
|
||||
import * as React from 'react';
|
||||
import ReactMarkdown from 'react-markdown';
|
||||
import I18n from 'i18n-js';
|
||||
|
||||
import NewPostForm from './NewPostForm';
|
||||
import Spinner from '../shared/Spinner';
|
||||
import {
|
||||
MutedText,
|
||||
DangerText,
|
||||
SuccessText,
|
||||
} from '../shared/CustomTexts';
|
||||
@@ -145,7 +145,15 @@ class NewPost extends React.Component<Props, State> {
|
||||
return (
|
||||
<div className="newPostContainer sidebarCard">
|
||||
<span className="boardTitle">{board.name}</span>
|
||||
<p><MutedText>{board.description}</MutedText></p>
|
||||
|
||||
<ReactMarkdown
|
||||
className="boardDescription"
|
||||
disallowedTypes={['heading', 'image', 'html']}
|
||||
unwrapDisallowed
|
||||
>
|
||||
{board.description}
|
||||
</ReactMarkdown>
|
||||
|
||||
{
|
||||
isLoggedIn ?
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user