diff --git a/render.go b/render.go
index b4c0a66..ccfc783 100644
--- a/render.go
+++ b/render.go
@@ -224,11 +224,14 @@ func render(w http.ResponseWriter, r *http.Request) {
}
useTextImage := (event.Kind == 1 || event.Kind == 30023) &&
- image == "" && video == "" && len(event.Content) > 120
+ image == "" && video == "" && len(event.Content) > 133
if style == "telegram" {
- if event.Kind == 30023 ||
- (event.Kind == 1 && len(event.Content) > 650) {
+ // do telegram instant preview (only works on telegram mobile apps, not desktop)
+ if event.Kind == 30023 || // do it for longform articles
+ (event.Kind == 1 && len(event.Content) > 650) || // or very long notes
+ // or shorter notes that should be using text-to-image stuff but are not because they have video or images
+ (event.Kind == 1 && len(event.Content) > 133 && !useTextImage) {
typ = "telegram_instant_view"
useTextImage = false
}
diff --git a/templates/telegram_instant_view.html b/templates/telegram_instant_view.html
index 0ed0e1d..d80f27b 100644
--- a/templates/telegram_instant_view.html
+++ b/templates/telegram_instant_view.html
@@ -14,6 +14,12 @@
{{ if .image }}
{{ end }}
+
+{{ if .video }}
+
+
+
+{{ end }}