mirror of
https://github.com/flarum/core.git
synced 2025-08-05 07:57:46 +02:00
Rename CommentPostPreview -> TextFormatterPreview
The idea is to be a bit more precise as to what this component does. Also, there's already the `PostPreview` component which is actually a link *to* a preview. Very confusing.
This commit is contained in:
@@ -7,7 +7,7 @@ import EditPostComposer from './EditPostComposer';
|
||||
import ItemList from '../../common/utils/ItemList';
|
||||
import listItems from '../../common/helpers/listItems';
|
||||
import Button from '../../common/components/Button';
|
||||
import CommentPostPreview from './CommentPostPreview';
|
||||
import TextFormatterPreview from './TextFormatterPreview';
|
||||
|
||||
/**
|
||||
* The `CommentPost` component displays a standard `comment`-typed post. This
|
||||
@@ -50,7 +50,7 @@ export default class CommentPost extends Post {
|
||||
<header className="Post-header">
|
||||
<ul>{listItems(this.headerItems().toArray())}</ul>
|
||||
</header>,
|
||||
<div className="Post-body">{this.isEditing() ? <CommentPostPreview /> : m.trust(this.attrs.post.contentHtml())}</div>,
|
||||
<div className="Post-body">{this.isEditing() ? <TextFormatterPreview /> : m.trust(this.attrs.post.contentHtml())}</div>,
|
||||
]);
|
||||
}
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
|
||||
import Component from '../../common/Component';
|
||||
|
||||
export default class CommentPostPreview extends Component {
|
||||
export default class TextFormatterPreview extends Component {
|
||||
view() {
|
||||
return <div className="Post-preview" />;
|
||||
}
|
Reference in New Issue
Block a user