Clean up embed JS and add Tweet.html compatibility

This commit is contained in:
Zed 2026-08-08 23:00:47 +07:00
commit 3bfbb7b3fd
4 changed files with 13 additions and 10 deletions

View file

@ -3,4 +3,5 @@
#proc renderOembedIframe*(embedUrl: string): string =
# result = ""
<iframe src="$embedUrl" style="width:100%;max-width:550px;height:250px;border:none" scrolling="no" loading="lazy" onload="let c=new MessageChannel;c.port1.onmessage=e=>this.style.height=e.data+'px';this.contentWindow.postMessage('','*',[c.port2])"></iframe>
# result = result.strip()
#end proc