diff --git a/promokit.js b/promokit.js index fe1144c..8e60100 100644 --- a/promokit.js +++ b/promokit.js @@ -11,7 +11,8 @@ const netsites = require('./netsites'); const KIT_DIR = path.join(__dirname, 'public', 'art', 'kit'); const SHAPES = { tile: [125, 125, 'Square button'], strip: [468, 60, 'Strip'], leader: [728, 90, 'Leaderboard'], box: [300, 250, 'Box'], panel: [336, 280, 'Large box'], - tower: [160, 600, 'Skyscraper'], social: [1200, 630, 'Social share'], square: [1080, 1080, 'Square post'] }; + tower: [160, 600, 'Skyscraper'], social: [1200, 630, 'Social share'], square: [1080, 1080, 'Square post'], + wide: [600, 300, 'Wide card'], small: [250, 250, 'Small square'] }; const ANGLES = { free: 'Post a free text ad', tree: 'Watch your ad travel', boost: 'Boost the source' }; function copy() { diff --git a/public/art/kit/vas-boost-small.png b/public/art/kit/vas-boost-small.png new file mode 100644 index 0000000..1b2ef92 Binary files /dev/null and b/public/art/kit/vas-boost-small.png differ diff --git a/public/art/kit/vas-boost-wide.png b/public/art/kit/vas-boost-wide.png new file mode 100644 index 0000000..18ff975 Binary files /dev/null and b/public/art/kit/vas-boost-wide.png differ diff --git a/public/art/kit/vas-free-small.png b/public/art/kit/vas-free-small.png new file mode 100644 index 0000000..beb980a Binary files /dev/null and b/public/art/kit/vas-free-small.png differ diff --git a/public/art/kit/vas-free-wide.png b/public/art/kit/vas-free-wide.png new file mode 100644 index 0000000..2ba32ad Binary files /dev/null and b/public/art/kit/vas-free-wide.png differ diff --git a/public/art/kit/vas-tree-small.png b/public/art/kit/vas-tree-small.png new file mode 100644 index 0000000..05a6cb8 Binary files /dev/null and b/public/art/kit/vas-tree-small.png differ diff --git a/public/art/kit/vas-tree-wide.png b/public/art/kit/vas-tree-wide.png new file mode 100644 index 0000000..dfa1daf Binary files /dev/null and b/public/art/kit/vas-tree-wide.png differ diff --git a/tools/art.mjs b/tools/art.mjs index b5eb459..a4c3040 100644 --- a/tools/art.mjs +++ b/tools/art.mjs @@ -44,6 +44,13 @@ function kit(angle, shape) { const tall = h > w * 2; return page(w, h, `
${mk(tall ? 54 : 34)}
${a.t}
${tall ? `
${a.s}
` : ''}
ViralAdSource
${tall ? `${a.cta}` : ''}
`, cls === 'ink' ? 'ink' : ''); } + if (shape === 'small') return page(w, h, `
+
${mk(24)}ViralAdSource
+
${a.t}
${a.cta}
`, cls === 'ink' ? 'ink' : ''); + if (shape === 'wide') return page(w, h, `
+
${mk(28)}ViralAdSource
+
${a.k}
${a.t}
${a.s}
+
${a.cta}
`, cls); const big = Math.min(w, h); const pad = Math.round(big * .07); return page(w, h, `
${mk(Math.round(big * .09))}ViralAdSource
@@ -56,7 +63,9 @@ const shots = [ ['proof/vas-proof-river.png', 1200, 630, page(1200, 630, `
${MARK(54)}ViralAdSource
Paid on chain
A Boost flowed back to the branch that sold it.
Resharer, sponsor line, reward pot: one transaction. Verify it on Polygonscan.
`, 'river')], ['proof/vas-proof-ink.png', 1200, 630, page(1200, 630, `
${MARKL(54)}ViralAdSource
Live ledger
Every ad has a source.
Every payment has a proof.
Results are rewarded, never a bare share.
`, 'ink')] ]; -for (const angle of Object.keys(ANG)) for (const shape of Object.keys(SHAPES)) { const [w, h] = SHAPES[shape]; shots.push(['kit/vas-' + angle + '-' + shape + '.png', w, h, kit(angle, shape)]); } +const ONLY = (process.env.ONLY || '').split(',').filter(Boolean); // render just these kit shapes +if (ONLY.length) shots.length = 0; +for (const angle of Object.keys(ANG)) for (const shape of Object.keys(SHAPES)) { if (ONLY.length && !ONLY.includes(shape)) continue; const [w, h] = SHAPES[shape]; shots.push(['kit/vas-' + angle + '-' + shape + '.png', w, h, kit(angle, shape)]); } const browser = await chromium.launch(); const pg = await browser.newPage(); for (const [file, w, h, html] of shots) {