mirror of
https://github.com/LemmyNet/lemmy-ui.git
synced 2024-11-25 07:36:37 +00:00
Hide WYSIWYG buttons when previewing markdown (#2366)
Co-authored-by: SleeplessOne1917 <insomnia-void@protonmail.com>
This commit is contained in:
parent
77cd46b35b
commit
40ade7df88
|
@ -156,6 +156,7 @@ export class MarkdownTextArea extends Component<
|
|||
<div className="mb-3 row">
|
||||
<div className="col-12">
|
||||
<div className="rounded bg-light border">
|
||||
{!this.state.previewMode && (
|
||||
<div
|
||||
className={classNames("d-flex flex-wrap border-bottom", {
|
||||
"no-click": this.isDisabled,
|
||||
|
@ -206,7 +207,10 @@ export class MarkdownTextArea extends Component<
|
|||
{this.getFormatButton("quote", this.handleInsertQuote)}
|
||||
{this.getFormatButton("list", this.handleInsertList)}
|
||||
{this.getFormatButton("code", this.handleInsertCode)}
|
||||
{this.getFormatButton("subscript", this.handleInsertSubscript)}
|
||||
{this.getFormatButton(
|
||||
"subscript",
|
||||
this.handleInsertSubscript,
|
||||
)}
|
||||
{this.getFormatButton(
|
||||
"superscript",
|
||||
this.handleInsertSuperscript,
|
||||
|
@ -221,7 +225,7 @@ export class MarkdownTextArea extends Component<
|
|||
<Icon icon="help-circle" classes="icon-inline" />
|
||||
</a>
|
||||
</div>
|
||||
|
||||
)}
|
||||
<div>
|
||||
<textarea
|
||||
id={this.id}
|
||||
|
|
Loading…
Reference in a new issue