by adom
The hero-image lab with a human gate: `hero-studio pose <owner/slug>` opens the studio in front of the human, posed for their package, and blocks until they click Generate, producing the provenance-stamped 2000x1250 PNG the registry's hero gate requires. The image carries the title and artwork; the exported image also bakes the type pill (top right) and full wiki slug (bottom right); the page shows the hero bare, and only the homepage marquee overlays its own dynamic info. Every hero wears its P
master
Colby Knox
Full test suite in the page repo: npm test runs here (the published package carries only test/brand.mjs)
625499c
// hero-studio#77: a re-posed gate for a page generated earlier in the session
// is OPEN, so another thread's pose must not take it over.
import assert from 'assert';
import { gateOpen } from '../gate.mjs';
assert.equal(gateOpen(null), false);
assert.equal(gateOpen({ verify: false, page: 'adom/a' }), false, 'not posed');
assert.equal(gateOpen({ verify: true, page: 'adom/a', posedAt: 10 }), true, 'posed, never generated');
assert.equal(gateOpen({ verify: true, page: 'adom/a', posedAt: 10, approved: { page: 'adom/a', ts: 20 } }), false, 'generated after the pose: closed');
assert.equal(gateOpen({ verify: true, page: 'adom/a', posedAt: 30, approved: { page: 'adom/a', ts: 20 } }), true, 're-posed after a generate: open (the #77 case)');
assert.equal(gateOpen({ verify: true, page: 'adom/a', posedAt: 10, approved: { page: 'adom/b', ts: 20 } }), true, 'the approval was for another page');
console.log('gate: ok');