VBB v1: Marty's approved numbers as config defaults (1 free credit/day; packs 10 for $3, 40 for $10; look $2; split 30/70 kept for later; 150 views per cycle; weekly prizes $15/$7/$3 per leaderboard, display only); packages page shows planned prices as coming soon; smoke test (99/99); OG image + icon; env example + compose (not deployed)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -2,6 +2,14 @@
|
||||
(async function () {
|
||||
VBB.renderNav('/leaders'); VBB.renderFooter();
|
||||
const $ = VBB.$, esc = VBB.esc;
|
||||
// weekly prizes from config (Marty 2026-11-13): displayed only, no payout code yet
|
||||
const c = await VBB.getConfig().catch(() => ({}));
|
||||
const pz = c.prizes || {}; const place = ['1st', '2nd', '3rd', '4th', '5th', '6th', '7th', '8th', '9th', '10th'];
|
||||
const plist = (title, arr) => '<div><h3>' + title + '</h3><ul class="pk-list">' + arr.map((v, i) => '<li>' + place[i] + ': $' + VBB.n(v) + ' in POL</li>').join('') + '</ul></div>';
|
||||
if ((pz.visitors || []).length || (pz.sources || []).length) {
|
||||
$('pz').innerHTML = ((pz.visitors || []).length ? plist('Most visitors sent', pz.visitors) : '') + ((pz.sources || []).length ? plist('Most traffic sources', pz.sources) : '');
|
||||
$('prizes').hidden = false;
|
||||
}
|
||||
const d = await VBB.getJSON('/api/leaders');
|
||||
if (d.error) return VBB.status(d.error, 'err');
|
||||
const wk = new Date(d.week + 'T12:00:00Z').toLocaleDateString('en-US', { month: 'long', day: 'numeric', timeZone: 'UTC' });
|
||||
|
||||
Reference in New Issue
Block a user