textMarkdownToHTML (options: {
markdown: string
- withHtml?: boolean
- withEmoji?: boolean
+ withHtml?: boolean // default false
+ withEmoji?: boolean // default false
}) {
const { markdown, withHtml = false, withEmoji = false } = options
enhancedMarkdownToHTML (options: {
markdown: string
- withHtml?: boolean
- withEmoji?: boolean
+ withHtml?: boolean // default false
+ withEmoji?: boolean // default false
}) {
const { markdown, withHtml = false, withEmoji = false } = options
return this.render({ name: 'customPageMarkdownIt', markdown, withEmoji: true, additionalAllowedTags })
}
+ // ---------------------------------------------------------------------------
+
processVideoTimestamps (videoShortUUID: string, html: string) {
return html.replace(/((\d{1,2}):)?(\d{1,2}):(\d{1,2})/g, function (str, _, h, m, s) {
const t = (3600 * +(h || 0)) + (60 * +(m || 0)) + (+(s || 0))