2020-07-27 09:40:30 +00:00
|
|
|
import * as debug from 'debug'
|
|
|
|
import truncate from 'lodash-es/truncate'
|
|
|
|
import { SortMeta } from 'primeng/api'
|
2020-08-12 08:40:04 +00:00
|
|
|
import { buildVideoLink, buildVideoOrPlaylistEmbed } from 'src/assets/player/utils'
|
2020-07-27 09:40:30 +00:00
|
|
|
import { environment } from 'src/environments/environment'
|
2020-08-12 08:40:04 +00:00
|
|
|
import { AfterViewInit, Component, Input, OnInit, ViewChild } from '@angular/core'
|
2020-07-27 09:40:30 +00:00
|
|
|
import { DomSanitizer } from '@angular/platform-browser'
|
2020-11-16 13:47:05 +00:00
|
|
|
import { ActivatedRoute, Router } from '@angular/router'
|
2020-07-27 09:40:30 +00:00
|
|
|
import { ConfirmService, MarkdownService, Notifier, RestPagination, RestTable } from '@app/core'
|
|
|
|
import { Account, Actor, DropdownAction, Video, VideoService } from '@app/shared/shared-main'
|
|
|
|
import { AbuseService, BlocklistService, VideoBlockService } from '@app/shared/shared-moderation'
|
|
|
|
import { VideoCommentService } from '@app/shared/shared-video-comment'
|
|
|
|
import { AbuseState, AdminAbuse } from '@shared/models'
|
|
|
|
import { AbuseMessageModalComponent } from './abuse-message-modal.component'
|
|
|
|
import { ModerationCommentModalComponent } from './moderation-comment-modal.component'
|
|
|
|
import { ProcessedAbuse } from './processed-abuse.model'
|
|
|
|
|
|
|
|
const logger = debug('peertube:moderation:AbuseListTableComponent')
|
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'my-abuse-list-table',
|
|
|
|
templateUrl: './abuse-list-table.component.html',
|
|
|
|
styleUrls: [ '../shared-moderation/moderation.scss', './abuse-list-table.component.scss' ]
|
|
|
|
})
|
|
|
|
export class AbuseListTableComponent extends RestTable implements OnInit, AfterViewInit {
|
|
|
|
@Input() viewType: 'admin' | 'user'
|
|
|
|
@Input() baseRoute: string
|
|
|
|
|
|
|
|
@ViewChild('abuseMessagesModal', { static: true }) abuseMessagesModal: AbuseMessageModalComponent
|
|
|
|
@ViewChild('moderationCommentModal', { static: true }) moderationCommentModal: ModerationCommentModalComponent
|
|
|
|
|
|
|
|
abuses: ProcessedAbuse[] = []
|
|
|
|
totalRecords = 0
|
|
|
|
sort: SortMeta = { field: 'createdAt', order: 1 }
|
|
|
|
pagination: RestPagination = { count: this.rowsPerPage, start: 0 }
|
|
|
|
|
|
|
|
abuseActions: DropdownAction<ProcessedAbuse>[][] = []
|
|
|
|
|
|
|
|
constructor (
|
2020-11-16 13:47:05 +00:00
|
|
|
protected route: ActivatedRoute,
|
|
|
|
protected router: Router,
|
2020-07-27 09:40:30 +00:00
|
|
|
private notifier: Notifier,
|
|
|
|
private abuseService: AbuseService,
|
|
|
|
private blocklistService: BlocklistService,
|
|
|
|
private commentService: VideoCommentService,
|
|
|
|
private videoService: VideoService,
|
|
|
|
private videoBlocklistService: VideoBlockService,
|
|
|
|
private confirmService: ConfirmService,
|
|
|
|
private markdownRenderer: MarkdownService,
|
2020-11-16 13:47:05 +00:00
|
|
|
private sanitizer: DomSanitizer
|
2020-07-27 09:40:30 +00:00
|
|
|
) {
|
|
|
|
super()
|
|
|
|
}
|
|
|
|
|
|
|
|
ngOnInit () {
|
|
|
|
this.abuseActions = [
|
|
|
|
this.buildInternalActions(),
|
|
|
|
|
|
|
|
this.buildFlaggedAccountActions(),
|
|
|
|
|
|
|
|
this.buildCommentActions(),
|
|
|
|
|
|
|
|
this.buildVideoActions(),
|
|
|
|
|
|
|
|
this.buildAccountActions()
|
|
|
|
]
|
|
|
|
|
|
|
|
this.initialize()
|
2020-11-16 13:47:05 +00:00
|
|
|
this.listenToSearchChange()
|
2020-07-27 09:40:30 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
ngAfterViewInit () {
|
2020-12-17 14:48:54 +00:00
|
|
|
if (this.search) this.setTableFilter(this.search, false)
|
2020-07-27 09:40:30 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
isAdminView () {
|
|
|
|
return this.viewType === 'admin'
|
|
|
|
}
|
|
|
|
|
|
|
|
getIdentifier () {
|
|
|
|
return 'AbuseListTableComponent'
|
|
|
|
}
|
|
|
|
|
|
|
|
openModerationCommentModal (abuse: AdminAbuse) {
|
|
|
|
this.moderationCommentModal.openModal(abuse)
|
|
|
|
}
|
|
|
|
|
|
|
|
onModerationCommentUpdated () {
|
|
|
|
this.loadData()
|
|
|
|
}
|
|
|
|
|
|
|
|
isAbuseAccepted (abuse: AdminAbuse) {
|
|
|
|
return abuse.state.id === AbuseState.ACCEPTED
|
|
|
|
}
|
|
|
|
|
|
|
|
isAbuseRejected (abuse: AdminAbuse) {
|
|
|
|
return abuse.state.id === AbuseState.REJECTED
|
|
|
|
}
|
|
|
|
|
|
|
|
getVideoUrl (abuse: AdminAbuse) {
|
|
|
|
return Video.buildClientUrl(abuse.video.uuid)
|
|
|
|
}
|
|
|
|
|
|
|
|
getCommentUrl (abuse: AdminAbuse) {
|
|
|
|
return Video.buildClientUrl(abuse.comment.video.uuid) + ';threadId=' + abuse.comment.threadId
|
|
|
|
}
|
|
|
|
|
|
|
|
getAccountUrl (abuse: ProcessedAbuse) {
|
|
|
|
return '/accounts/' + abuse.flaggedAccount.nameWithHost
|
|
|
|
}
|
|
|
|
|
|
|
|
getVideoEmbed (abuse: AdminAbuse) {
|
2020-08-07 11:43:48 +00:00
|
|
|
return buildVideoOrPlaylistEmbed(
|
2020-07-27 09:40:30 +00:00
|
|
|
buildVideoLink({
|
2020-11-09 15:25:27 +00:00
|
|
|
baseUrl: `${environment.originServerUrl}/videos/embed/${abuse.video.uuid}`,
|
2020-07-27 09:40:30 +00:00
|
|
|
title: false,
|
|
|
|
warningTitle: false,
|
2020-11-10 13:41:20 +00:00
|
|
|
startTime: abuse.video.startAt,
|
|
|
|
stopTime: abuse.video.endAt
|
2021-03-31 06:32:05 +00:00
|
|
|
}),
|
|
|
|
abuse.video.name
|
2020-07-27 09:40:30 +00:00
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
async removeAbuse (abuse: AdminAbuse) {
|
2020-08-12 08:40:04 +00:00
|
|
|
const res = await this.confirmService.confirm($localize`Do you really want to delete this abuse report?`, $localize`Delete`)
|
2020-07-27 09:40:30 +00:00
|
|
|
if (res === false) return
|
|
|
|
|
|
|
|
this.abuseService.removeAbuse(abuse).subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Abuse deleted.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
this.loadData()
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
updateAbuseState (abuse: AdminAbuse, state: AbuseState) {
|
|
|
|
this.abuseService.updateAbuse(abuse, { state })
|
|
|
|
.subscribe(
|
|
|
|
() => this.loadData(),
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
onCountMessagesUpdated (event: { abuseId: number, countMessages: number }) {
|
|
|
|
const abuse = this.abuses.find(a => a.id === event.abuseId)
|
|
|
|
|
|
|
|
if (!abuse) {
|
|
|
|
console.error('Cannot find abuse %d.', event.abuseId)
|
|
|
|
return
|
|
|
|
}
|
|
|
|
|
|
|
|
abuse.countMessages = event.countMessages
|
|
|
|
}
|
|
|
|
|
|
|
|
openAbuseMessagesModal (abuse: AdminAbuse) {
|
|
|
|
this.abuseMessagesModal.openModal(abuse)
|
|
|
|
}
|
|
|
|
|
|
|
|
isLocalAbuse (abuse: AdminAbuse) {
|
|
|
|
if (this.viewType === 'user') return true
|
|
|
|
|
|
|
|
return Actor.IS_LOCAL(abuse.reporterAccount.host)
|
|
|
|
}
|
|
|
|
|
|
|
|
protected loadData () {
|
|
|
|
logger('Loading data.')
|
|
|
|
|
|
|
|
const options = {
|
|
|
|
pagination: this.pagination,
|
|
|
|
sort: this.sort,
|
|
|
|
search: this.search
|
|
|
|
}
|
|
|
|
|
|
|
|
const observable = this.viewType === 'admin'
|
|
|
|
? this.abuseService.getAdminAbuses(options)
|
|
|
|
: this.abuseService.getUserAbuses(options)
|
|
|
|
|
|
|
|
return observable.subscribe(
|
|
|
|
async resultList => {
|
|
|
|
this.totalRecords = resultList.total
|
|
|
|
|
|
|
|
this.abuses = []
|
|
|
|
|
|
|
|
for (const a of resultList.data) {
|
|
|
|
const abuse = a as ProcessedAbuse
|
|
|
|
|
|
|
|
abuse.reasonHtml = await this.toHtml(abuse.reason)
|
|
|
|
|
|
|
|
if (abuse.moderationComment) {
|
|
|
|
abuse.moderationCommentHtml = await this.toHtml(abuse.moderationComment)
|
|
|
|
}
|
|
|
|
|
|
|
|
if (abuse.video) {
|
|
|
|
abuse.embedHtml = this.sanitizer.bypassSecurityTrustHtml(this.getVideoEmbed(abuse))
|
|
|
|
|
|
|
|
if (abuse.video.channel?.ownerAccount) {
|
|
|
|
abuse.video.channel.ownerAccount = new Account(abuse.video.channel.ownerAccount)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if (abuse.comment) {
|
|
|
|
if (abuse.comment.deleted) {
|
2020-08-12 08:40:04 +00:00
|
|
|
abuse.truncatedCommentHtml = abuse.commentHtml = $localize`Deleted comment`
|
2020-07-27 09:40:30 +00:00
|
|
|
} else {
|
|
|
|
const truncated = truncate(abuse.comment.text, { length: 100 })
|
|
|
|
abuse.truncatedCommentHtml = await this.markdownRenderer.textMarkdownToHTML(truncated, true)
|
|
|
|
abuse.commentHtml = await this.markdownRenderer.textMarkdownToHTML(abuse.comment.text, true)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
if (abuse.reporterAccount) {
|
|
|
|
abuse.reporterAccount = new Account(abuse.reporterAccount)
|
|
|
|
}
|
|
|
|
|
|
|
|
if (abuse.flaggedAccount) {
|
|
|
|
abuse.flaggedAccount = new Account(abuse.flaggedAccount)
|
|
|
|
}
|
|
|
|
|
|
|
|
if (abuse.updatedAt === abuse.createdAt) delete abuse.updatedAt
|
|
|
|
|
|
|
|
this.abuses.push(abuse)
|
|
|
|
}
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
private buildInternalActions (): DropdownAction<ProcessedAbuse>[] {
|
|
|
|
return [
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Internal actions`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isHeader: true
|
|
|
|
},
|
|
|
|
{
|
|
|
|
label: this.isAdminView()
|
2020-08-12 08:40:04 +00:00
|
|
|
? $localize`Messages with reporter`
|
|
|
|
: $localize`Messages with moderators`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.openAbuseMessagesModal(abuse),
|
|
|
|
isDisplayed: abuse => this.isLocalAbuse(abuse)
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Update internal note`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.openModerationCommentModal(abuse),
|
|
|
|
isDisplayed: abuse => this.isAdminView() && !!abuse.moderationComment
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mark as accepted`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.updateAbuseState(abuse, AbuseState.ACCEPTED),
|
|
|
|
isDisplayed: abuse => this.isAdminView() && !this.isAbuseAccepted(abuse)
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mark as rejected`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.updateAbuseState(abuse, AbuseState.REJECTED),
|
|
|
|
isDisplayed: abuse => this.isAdminView() && !this.isAbuseRejected(abuse)
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Add internal note`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.openModerationCommentModal(abuse),
|
|
|
|
isDisplayed: abuse => this.isAdminView() && !abuse.moderationComment
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Delete report`,
|
2020-07-27 09:40:30 +00:00
|
|
|
handler: abuse => this.isAdminView() && this.removeAbuse(abuse)
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
private buildFlaggedAccountActions (): DropdownAction<ProcessedAbuse>[] {
|
|
|
|
if (!this.isAdminView()) return []
|
|
|
|
|
|
|
|
return [
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Actions for the flagged account`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isHeader: true,
|
|
|
|
isDisplayed: abuse => abuse.flaggedAccount && !abuse.comment && !abuse.video
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mute account`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.flaggedAccount && !abuse.comment && !abuse.video,
|
|
|
|
handler: abuse => this.muteAccountHelper(abuse.flaggedAccount)
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mute server account`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.flaggedAccount && !abuse.comment && !abuse.video,
|
|
|
|
handler: abuse => this.muteServerHelper(abuse.flaggedAccount.host)
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
private buildAccountActions (): DropdownAction<ProcessedAbuse>[] {
|
|
|
|
if (!this.isAdminView()) return []
|
|
|
|
|
|
|
|
return [
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Actions for the reporter`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isHeader: true,
|
|
|
|
isDisplayed: abuse => !!abuse.reporterAccount
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mute reporter`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => !!abuse.reporterAccount,
|
|
|
|
handler: abuse => this.muteAccountHelper(abuse.reporterAccount)
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Mute server`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.reporterAccount && !abuse.reporterAccount.userId,
|
|
|
|
handler: abuse => this.muteServerHelper(abuse.reporterAccount.host)
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
private buildVideoActions (): DropdownAction<ProcessedAbuse>[] {
|
|
|
|
if (!this.isAdminView()) return []
|
|
|
|
|
|
|
|
return [
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Actions for the video`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isHeader: true,
|
|
|
|
isDisplayed: abuse => abuse.video && !abuse.video.deleted
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Block video`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.video && !abuse.video.deleted && !abuse.video.blacklisted,
|
|
|
|
handler: abuse => {
|
2020-08-26 06:45:48 +00:00
|
|
|
this.videoBlocklistService.blockVideo(abuse.video.id, undefined, abuse.video.channel.isLocal)
|
2020-07-27 09:40:30 +00:00
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Video blocked.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
|
|
|
|
this.updateAbuseState(abuse, AbuseState.ACCEPTED)
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Unblock video`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.video && !abuse.video.deleted && abuse.video.blacklisted,
|
|
|
|
handler: abuse => {
|
|
|
|
this.videoBlocklistService.unblockVideo(abuse.video.id)
|
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Video unblocked.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
|
|
|
|
this.updateAbuseState(abuse, AbuseState.ACCEPTED)
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Delete video`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.video && !abuse.video.deleted,
|
|
|
|
handler: async abuse => {
|
|
|
|
const res = await this.confirmService.confirm(
|
2020-08-12 08:40:04 +00:00
|
|
|
$localize`Do you really want to delete this video?`,
|
|
|
|
$localize`Delete`
|
2020-07-27 09:40:30 +00:00
|
|
|
)
|
|
|
|
if (res === false) return
|
|
|
|
|
|
|
|
this.videoService.removeVideo(abuse.video.id)
|
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Video deleted.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
|
|
|
|
this.updateAbuseState(abuse, AbuseState.ACCEPTED)
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
private buildCommentActions (): DropdownAction<ProcessedAbuse>[] {
|
|
|
|
if (!this.isAdminView()) return []
|
|
|
|
|
|
|
|
return [
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Actions for the comment`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isHeader: true,
|
|
|
|
isDisplayed: abuse => abuse.comment && !abuse.comment.deleted
|
|
|
|
},
|
|
|
|
|
|
|
|
{
|
2020-08-12 08:40:04 +00:00
|
|
|
label: $localize`Delete comment`,
|
2020-07-27 09:40:30 +00:00
|
|
|
isDisplayed: abuse => abuse.comment && !abuse.comment.deleted,
|
|
|
|
handler: async abuse => {
|
|
|
|
const res = await this.confirmService.confirm(
|
2020-08-12 08:40:04 +00:00
|
|
|
$localize`Do you really want to delete this comment?`,
|
|
|
|
$localize`Delete`
|
2020-07-27 09:40:30 +00:00
|
|
|
)
|
|
|
|
if (res === false) return
|
|
|
|
|
|
|
|
this.commentService.deleteVideoComment(abuse.comment.video.id, abuse.comment.id)
|
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Comment deleted.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
|
|
|
|
this.updateAbuseState(abuse, AbuseState.ACCEPTED)
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
private muteAccountHelper (account: Account) {
|
|
|
|
this.blocklistService.blockAccountByInstance(account)
|
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Account ${account.nameWithHost} muted by the instance.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
account.mutedByInstance = true
|
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
private muteServerHelper (host: string) {
|
|
|
|
this.blocklistService.blockServerByInstance(host)
|
|
|
|
.subscribe(
|
|
|
|
() => {
|
2020-08-12 08:40:04 +00:00
|
|
|
this.notifier.success($localize`Server ${host} muted by the instance.`)
|
2020-07-27 09:40:30 +00:00
|
|
|
},
|
|
|
|
|
|
|
|
err => this.notifier.error(err.message)
|
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
private toHtml (text: string) {
|
|
|
|
return this.markdownRenderer.textMarkdownToHTML(text)
|
|
|
|
}
|
|
|
|
}
|