Promo tools: hook video cards (matched links, downloads, captions, share buttons)

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
martbost
2026-09-10 08:55:29 -05:00
parent 276618dd73
commit f6490c9444
16 changed files with 55 additions and 17 deletions
+36 -1
View File
@@ -81,6 +81,15 @@ window.IAPPromo = (function () {
return a;
}
// hook videos: one per angle; the matched link continues the same hook on the join page
const VID_BASE = 'https://coolify-saasytop.nyc3.digitaloceanspaces.com/promo/';
const VIDEOS = [
{ angle: 'instant', title: 'Paid before the page reloads', hook: 'What if your commission landed before the thank-you page finished loading?', caption: 'What if your commission landed before the thank-you page finished loading? On InstantAdPay a smart contract splits every ad package the second it sells, straight to wallets, on a public ledger. Free to join by email: {{LINK:instant}}' },
{ angle: 'adspend', title: 'You were buying traffic anyway', hook: 'Every ad dollar you have ever spent went one direction. Out.', caption: 'Every ad dollar you have ever spent went one direction. Out. Here the ad spend in your line pays you back in the same transaction. Seven formats, packages from $5, free to join: {{LINK:adspend}}' },
{ angle: 'free', title: 'Watch first, spend never', hook: 'You can run your first ad campaign here for exactly zero dollars.', caption: 'Run your first ad campaign for exactly zero dollars. Join free by email, earn credits by viewing ads, launch a real campaign, and watch real payouts land on a public ledger before you spend a cent: {{LINK:free}}' },
{ angle: 'ledger', title: 'No back office. No payday.', hook: 'Your last affiliate program paid you on the fifteenth. If it paid you.', caption: 'Your last affiliate program paid you on the fifteenth. If it paid you. Here the payroll is the blockchain: every payout is a public transaction, nothing is held, nobody can change the split. Open the ledger, then join free: {{LINK:ledger}}' },
{ angle: 'two', title: 'Two buyers open level two', hook: 'Two buyers. Then five. That is the whole ladder.', caption: 'Two buyers. Then five. That is the whole ladder. Level 1 pays from your first buyer, two qualifying buyers open level 2, five open level 3, all in the same transaction, straight to your wallet. Free to join: {{LINK:two}}' }
];
function fill(link, me) {
const token = (me && (me.username || me.refCode || me.memberId)) || '';
// invite strip
@@ -128,6 +137,32 @@ window.IAPPromo = (function () {
sw.appendChild(block(text, '<span class="pb-net">' + esc(s.tier) + '</span> <b>' + esc(s.subject) + '</b>'));
}
}
// hook videos
const vw = $('promoVideos');
if (vw && vw.dataset.filled !== link) {
vw.dataset.filled = link; vw.innerHTML = '';
for (const v of VIDEOS) {
const mlink = angleLink(link, v.angle);
const card = document.createElement('div'); card.className = 'pv';
card.innerHTML = '<div class="pv-head"><span class="pb-net">' + esc(v.angle) + ' angle</span> <b>' + esc(v.title) + '</b><div class="muted small">' + esc(v.hook) + '</div></div>'
+ '<video src="' + VID_BASE + v.angle + '.mp4" poster="' + VID_BASE + v.angle + '.jpg" preload="none" controls playsinline style="width:100%;max-width:640px;border-radius:12px;background:#000;margin:10px 0"></video>'
+ '<p class="small"><span class="muted">Matched link:</span> <span class="mono" style="overflow-wrap:anywhere">' + esc(mlink) + '</span></p>';
const row = document.createElement('p'); row.className = 'pb-actions';
row.appendChild(copyBtn(mlink, 'Copy matched link'));
row.appendChild(linkBtn(VID_BASE + v.angle + '.mp4', 'Download 16:9'));
row.appendChild(linkBtn(VID_BASE + v.angle + '-portrait.mp4', 'Download 9:16'));
card.appendChild(row);
const cap = fillLink(v.caption, link);
const extras = [
linkBtn('https://twitter.com/intent/tweet?text=' + encodeURIComponent(cap), 'Post on X'),
linkBtn('https://www.facebook.com/sharer/sharer.php?u=' + encodeURIComponent(mlink), 'Share on Facebook'),
linkBtn('https://t.me/share/url?url=' + encodeURIComponent(mlink) + '&text=' + encodeURIComponent(cap.replace(/https?:\/\/\S+$/, '').trim()), 'Telegram'),
linkBtn('https://wa.me/?text=' + encodeURIComponent(cap), 'WhatsApp')
];
card.appendChild(block(cap, '<span class="lab">Caption</span>', extras));
vw.appendChild(card);
}
}
// objections
const ob = $('promoObjections');
if (ob && ob.dataset.filled !== link) {
@@ -146,5 +181,5 @@ window.IAPPromo = (function () {
}
}
return { fill, POSTS, TEXTS, SWIPES, OBJECTIONS };
return { fill, POSTS, TEXTS, SWIPES, OBJECTIONS, VIDEOS };
})();