From 8f236d2759784408637ecb4f0c7a8978b97df9bb Mon Sep 17 00:00:00 2001 From: Tony Date: Wed, 29 Nov 2023 20:08:27 +0000 Subject: [PATCH] feat(route): authless instagram (#13920) * feat(route): authless instagram * docs: prefer instagram gen2 route --- lib/v2/instagram/templates/images.art | 10 ++- lib/v2/instagram/templates/video.art | 5 +- lib/v2/instagram/web-api/index.js | 32 +++++--- lib/v2/instagram/web-api/utils.js | 103 ++++++++++++++++++++++---- website/docs/routes/social-media.mdx | 40 +++++----- 5 files changed, 141 insertions(+), 49 deletions(-) diff --git a/lib/v2/instagram/templates/images.art b/lib/v2/instagram/templates/images.art index 67c6654c3..3af7e6ea5 100644 --- a/lib/v2/instagram/templates/images.art +++ b/lib/v2/instagram/templates/images.art @@ -1,5 +1,11 @@ -{{@ summary.replace(/\n/g, '
') }} +{{ if summary }} + {{@ summary.replace(/\n/g, '
') }} +
+{{ /if }} {{ each images i }} - + {{ /each }} diff --git a/lib/v2/instagram/templates/video.art b/lib/v2/instagram/templates/video.art index 62d466ec4..f89b9b5c0 100644 --- a/lib/v2/instagram/templates/video.art +++ b/lib/v2/instagram/templates/video.art @@ -1,4 +1,7 @@ -{{@ summary.replace(/\n/g, '
') }} +{{ if summary }} + {{@ summary.replace(/\n/g, '
') }} +
+{{ /if }}