import { getUrlForIframe } from '../../../Utils/IframeUtils' import { IContentType } from '../../ContentTypes/ContentType.interface' import { Block } from '../Block' type EmbedContentType = { caption: any[], url: string } export class Embed extends Block { static tagName:string = 'iframe' toHTML(): string { const embedContent:EmbedContentType = this.content as EmbedContentType const classTag = ['notion', 'embed'] if (/https:\/\/gist.github.com/.test(embedContent.url)) { return ` ` } return `<${Embed.tagName} class="${classTag.join(' ')}" src="${embedContent.url}">` } }