Open-source platform for 3D AI agents. Turn text or a photo into a rigged, animated GLB avatar, give it an LLM brain, memory and a wallet, and embed it anywhere with one web component. Remote MCP server, x402 payments, Three.js, browser-native.
JavaScript 3d-generationai-agentsanimationavatardigital-humangenerative-aiglbgltfimage-to-3dllmmcpmcp-servermodel-context-protocolsolanatext-to-3dthreejsweb-componentswebglwebxrx402
feat: add animation thumbnails and category classifier
fudjia5ecffd6e03d9
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 550cdecc2..b3f00f7a6 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -9,6 +9,8 @@ Public history for [three.ws](https://three.ws), newest first. New pages come fr- **@three-ws/retarget — the animation engine behind every avatar, now a standalone package** — The rig-agnostic animation system that powers all three.ws avatars is now on npm as @three-ws/retarget. It maps bone names from Mixamo, VRM/VRoid, Avaturn, Daz, MakeHuman, Unreal, and Blender rigs onto one canonical skeleton, retargets any clip onto any humanoid with rest-pose and hip-axis correction, and ships the crossfading runtime that keeps characters from ever freezing in a T-pose. Only dependency: your own copy of Three.js. Same engine, same tests (2,800 lines of them) — now usable in any Three.js project. `[sdk, feature]`- **2,000+ new motion-capture animations in the library** — The animation library just grew from around 100 curated clips to over 2,000 — the full professional motion-capture set, every one retargeted to the universal three.ws skeleton so it plays on any humanoid avatar. Walks, runs, dances, combat, idles, reactions, sports, and hundreds more are all searchable in the animations gallery, previewable on a live avatar, and one click away from the pose studio or any embed. The clips are served from the CDN, so the site stays fast no matter how big the library gets. (`/animations`) `[feature, improvement]`- **Agent creation now tells you what to do when your avatar library is full** — If you hit your plan's avatar limit while creating an agent, the wizard used to fail with a bare error and leave you stuck. It now explains what happened and gives you three ways forward, right in the form: connect an avatar you already own (one click jumps you to your library), free up a slot by deleting an old avatar, or upgrade your plan. Oversized model files get a clearer message too. (`/create-agent`) `[fix, improvement]`+- **Go Pro with SOL or $THREE — 20% off in the platform coin** — The Pro plan is now a real self-serve upgrade you can buy on-chain. The pricing page checkout accepts USDC, SOL, or $THREE on Solana: pick your asset, scan a Solana Pay QR (or open it straight in your wallet), and your account upgrades the moment the payment finalizes. SOL and $THREE amounts are quoted at the live market price and pinned for the session, and paying in $THREE takes 20% off the sticker price — holding the coin already earns discounts, and now spending it does too. (`/pricing`) `[feature]`+- **Payments a wallet silently rewrites now explain themselves instead of bouncing** — Some Solana wallets modify a payment transaction before signing it — injecting their own fee or guard instructions — and the platform's payment verifier rightly refuses anything that isn't the exact transfer it prepared. Until now that refusal looked like a dead end: the pay button bounced with a payment-required error no matter how many times you retried. The checkout now detects the rewrite the moment the wallet hands the transaction back and says plainly that the wallet altered it and nothing was charged, so you can switch wallets instead of retrying in circles. Verify rejections and settle failures are also now counted by reason on the public health endpoint, so a streak of refused payments is visible at a glance instead of hiding in admin logs. (`/club`) `[fix, improvement]`- **Status page no longer reports a phantom outage — and graduation tracking runs clean** — The public status page had been showing the x402 paid-API discovery feed and the 3D viewer as down for days while both were actually healthy: the uptime monitor was probing two URLs that never existed. The probes now hit the real public paths, and the falsely-recorded downtime history is purged so the 90-day uptime bars reflect the services, not the monitor bug. The pump.fun graduation tracker was also timing out on every heartbeat tick because it listened longer than the heartbeat allows — it now fits its budget and reports a clean run. (`/status`) `[fix, infra]`- **The agent economy now watches itself and pages the team** — After weeks of the agent-to-agent economy silently stalling and being diagnosed hours late, the platform now monitors it as a system: every 5 minutes it checks that the per-minute heartbeat is alive, that no engine is failing or stuck on a fixable problem (missing config, an unfundable payment, a full database), and that real on-chain agent activity is still flowing. Any of those pages the ops channel immediately, keeps re-paging hourly until fixed, and announces recovery. The status page's JSON feed also keeps 24 hours of health history so anyone can see exactly when a stall began. `[improvement, infra]`- **The sniper engine now pages us when it goes down — and restarts itself** — The on-chain sniper worker went quiet on July 3 and nothing noticed: the status page showed the engine offline and zero launches scored, but no alert fired. The platform's watchdog now checks the sniper's own heartbeat every 5 minutes and pages the ops channel within 10 minutes of a stall, with hourly re-pages until it recovers. The worker also gained a dead-man switch: if it loses its database for 15 minutes straight it restarts itself instead of running as a zombie that scores nothing. (`/status`) `[fix, infra]`diff --git a/api/healthz.js b/api/healthz.jsindex 7ca4c2d0c..f4f2dc095 100644--- a/api/healthz.js+++ b/api/healthz.js@@ -213,6 +213,44 @@ async function probeX402() {// Recent payments from audit logresult.recent_payments = await countRecentPayments(60);+ // Self-facilitator verify/settle outcomes (last 24h), grouped by reason+ // class. A paying buyer whose wallet mutates the prepared transaction gets a+ // deterministic verify 402 with everything else on this endpoint green —+ // without this block that failure mode is invisible outside the admin+ // dashboards. Only the reason prefix (before ':') is exposed: suffixes can+ // carry wallet addresses, the prefix is a fixed validator code.+ try {+ const { sql } = await import('./_lib/db.js');+ const rows = await sql`+ SELECT action, ok, split_part(coalesce(reject_reason, ''), ':', 1) AS reason,+ count(*)::int AS n+ FROM x402_self_facilitator_log+ WHERE ts > now() - interval '24 hours'+ GROUP BY 1, 2, 3+ ORDER BY n DESC+ LIMIT 20+ `;+ const block = {+ verify: { ok: 0, rejected: 0, reject_reasons: {} },+ settle: { ok: 0, failed: 0, fail_reasons: {} },+ };+ for (const r of rows) {+ const side = r.action === 'settle' ? block.settle : block.verify;+ if (r.ok) {+ side.ok += r.n;+ } else if (r.action === 'settle') {+ side.failed += r.n;+ if (r.reason) side.fail_reasons[r.reason] = (side.fail_reasons[r.reason] || 0) + r.n;+ } else {+ side.rejected += r.n;+ if (r.reason) side.reject_reasons[r.reason] = (side.reject_reasons[r.reason] || 0) + r.n;+ }+ }+ result.self_facilitator = block;+ } catch {+ result.self_facilitator = 'unavailable';+ }+// SIWX reachability (just check if the table exists)try {await (await import('./_lib/db.js')).sql`diff --git a/api/payments/_config.js b/api/payments/_config.jsindex 78de0a2b0..71c68dd8a 100644--- a/api/payments/_config.js+++ b/api/payments/_config.js@@ -19,8 +19,11 @@ export const PLAN_ASSETS = ['USDC', 'SOL', 'THREE'];// platform's coin and plan revenue in it feeds the treasury loop directly.// Basis points; 2000 = 20% off. Override with THREE_PLAN_DISCOUNT_BPS.export function threePlanDiscountBps() {- const raw = Number(process.env.THREE_PLAN_DISCOUNT_BPS);- if (Number.isFinite(raw) && raw >= 0 && raw <= 5000) return Math.floor(raw);+ const raw = (process.env.THREE_PLAN_DISCOUNT_BPS ?? '').trim();+ if (raw !== '') {+ const n = Number(raw);+ if (Number.isFinite(n) && n >= 0 && n <= 5000) return Math.floor(n);+ }return 2000;}diff --git a/data/changelog.json b/data/changelog.jsonindex e77846fa3..42e442dc0 100644--- a/data/changelog.json+++ b/data/changelog.json@@ -11266,6 +11266,25 @@"infra"],"link": "/status"+ },+ {+ "date": "2026-07-05",+ "title": "Payments a wallet silently rewrites now explain themselves instead of bouncing",+ "summary": "Some Solana wallets modify a payment transaction before signing it — injecting their own fee or guard instructions — and the platform's payment verifier rightly refuses anything that isn't the exact transfer it prepared. Until now that refusal looked like a dead end: the pay button bounced with a payment-required error no matter how many times you retried. The checkout now detects the rewrite the moment the wallet hands the transaction back and says plainly that the wallet altered it and nothing was charged, so you can switch wallets instead of retrying in circles. Verify rejections and settle failures are also now counted by reason on the public health endpoint, so a streak of refused payments is visible at a glance instead of hiding in admin logs.",+ "tags": [+ "fix",+ "improvement"+ ],+ "link": "/club"+ },+ {+ "date": "2026-07-05",+ "title": "Go Pro with SOL or $THREE — 20% off in the platform coin",+ "summary": "The Pro plan is now a real self-serve upgrade you can buy on-chain. The pricing page checkout accepts USDC, SOL, or $THREE on Solana: pick your asset, scan a Solana Pay QR (or open it straight in your wallet), and your account upgrades the moment the payment finalizes. SOL and $THREE amounts are quoted at the live market price and pinned for the session, and paying in $THREE takes 20% off the sticker price — holding the coin already earns discounts, and now spending it does too.",+ "tags": [+ "feature"+ ],+ "link": "/pricing"}]}diff --git a/docs/plan-checkout.md b/docs/plan-checkout.mdnew file mode 100644index 000000000..4c3430c7d--- /dev/null+++ b/docs/plan-checkout.md@@ -0,0 +1,120 @@+# Paid plans — pay in USDC, SOL, or $THREE++three.ws has a self-serve paid tier. Upgrading to **Pro** (or Team / Enterprise) is a single on-chain payment on Solana — no card, no billing processor. Three assets are accepted:++| Asset | What you pay | Notes |+|---|---|---|+| **USDC** | The sticker price, 1:1 | Stable — the default |+| **SOL** | USD price converted at the live SOL price | Amount pinned when the quote is created |+| **$THREE** | USD price **minus the platform-coin discount** (20% by default) | The platform's own coin, mint `FeMbDoX7R1Psc4GEcvJdsbNbZA3bfztcyDCatJVJpump` |++Where to use it: the Pro card on [three.ws/pricing](https://three.ws/pricing) opens the checkout when you're signed in. Confirmed payments set `users.plan`, light up the Pro badge everywhere ([api/_lib/account-tier.js](../api/_lib/account-tier.js)), and grant 30 days per payment.++This is separate from (and complementary to) [hold-to-access](./hold-to-access.md), which derives holder tiers from $THREE you *hold*; the plan checkout is $THREE you *spend*.++---++## Flow++Three endpoints, all under `/api/payments/solana` ([api/payments/solana/[action].js](../api/payments/solana/%5Baction%5D.js)):++```+GET /api/payments/solana?action=plans → prices + accepted assets (public)+POST /api/payments/solana?action=checkout → create a payment intent (session required)+POST /api/payments/solana?action=confirm → verify the tx on-chain, activate the plan+```++### 1. Read the plans (public)++```js+const d = await fetch('/api/payments/solana?action=plans').then(r => r.json());+// → {+// plans: { pro: { label: 'Pro', price_usd: 49, three_price_usd: 39.2, duration_days: 30 }, ... },+// assets: ['USDC', 'SOL', 'THREE'],+// three_discount_bps: 2000,+// three_mint: 'FeMbDoX7R1Psc4GEcvJdsbNbZA3bfztcyDCatJVJpump',+// }+```++Pricing UIs render from this endpoint so a displayed price can never drift from what checkout charges.++### 2. Create a checkout++```js+const intent = await fetch('/api/payments/solana?action=checkout', {+ method: 'POST',+ credentials: 'include',+ headers: { 'content-type': 'application/json' },+ body: JSON.stringify({ plan: 'pro', asset: 'THREE' }), // asset: USDC | SOL | THREE+}).then(r => r.json());++// → {+// intent_id, plan, asset, network,+// solana_pay_url, // scan/open with any Solana wallet+// recipient, // treasury pubkey+// mint, // spl-token mint (null for native SOL)+// amount_asset: '32891.4', // exact on-chain amount owed, human units+// amount_usd: 39.2, // USD value charged ($THREE discount applied)+// asset_price_usd, // live quote price used (null for USDC)+// discount_bps, // 2000 when paying in $THREE+// nonce, // carried as the payment's memo+// expires_at,+// }+```++For SOL and $THREE the USD price is converted at the **live market price** (Jupiter, with the Birdeye → DexScreener → GeckoTerminal fallback chain) and the exact on-chain amount is **pinned on the intent** — a price move during the session can't change what you owe. Live-priced quotes expire after **10 minutes** (USDC: 30); expired quotes are simply re-created.++The wallet payment **must include the `nonce` as a memo instruction** — the `solana_pay_url` already encodes it. A transfer without the matching memo will not confirm.++### 3. Pay, then confirm++Pay via the `solana_pay_url` (QR / deep link) or any wallet, then post the signature:++```js+const r = await fetch('/api/payments/solana?action=confirm', {+ method: 'POST',+ credentials: 'include',+ headers: { 'content-type': 'application/json' },+ body: JSON.stringify({ intent_id: intent.intent_id, tx_signature: sig }),+}).then(r => r.json());+// → { ok: true, plan: 'pro', asset: 'THREE', active_until: '2026-08-04T…', tx_signature }+```++The server verifies, at **finalized** commitment (reorg-safe):++1. the transaction exists and did not error;+2. the memo instruction equals the intent's nonce (binds the tx to this checkout, blocks replay);+3. the treasury actually received ≥ the pinned amount of the right asset — SPL transfers are matched by instruction **and** by pre/post token-balance delta with an explicit mint check; native SOL by the recipient's lamport delta;+4. one on-chain tx confirms at most one intent (unique index on `tx_hash`).++On success, one atomic transaction claims the intent, upserts `subscriptions`, and sets `users.plan`.++`tx_not_found` (422) usually means the tx hasn't finalized yet (~10–30 s) — retry; the built-in pricing UIs poll automatically. A payment sent just before the quote expired is still honored within a 1-hour grace window.++### Error codes++| Status | `error` | When |+|---|---|---|+| 401 | `unauthorized` | No session |+| 400 | `bad_request` | `$THREE` requested on devnet |+| 503 | `price_unavailable` | No live price feed for SOL/$THREE right now — retry shortly |+| 503 | `not_configured` | `PAYMENT_RECIPIENT_SOLANA` unset |+| 422 | `tx_not_found` | Not finalized yet — retry in a few seconds |+| 422 | `memo_mismatch` | Payment is missing the intent nonce memo |+| 422 | `transfer_not_found` | Right memo, wrong asset/amount/recipient |+| 410 | `intent_expired` | Quote lapsed beyond the grace window — create a new checkout |+| 409 | `already_confirmed` | Intent (or tx) already used |++---++## Configuration++| Var | Purpose |+|---|---|+| `PAYMENT_RECIPIENT_SOLANA` | Treasury pubkey that receives plan payments (**required**) |+| `THREE_PLAN_DISCOUNT_BPS` | Pay-in-$THREE discount, basis points (default `2000` = 20%, max 5000) |+| `THREE_TOKEN_MINT` | $THREE mint (defaults to the canonical CA) |+| `SOLANA_RPC_URL` / `SOLANA_RPC_URL_DEVNET` | RPC endpoints — set a paid RPC in production |+| `SOLANA_USDC_MINT` | Override the USDC mint (defaults to mainnet USDC) |++Plan prices live in [api/payments/_config.js](../api/payments/_config.js) (`PLANS`) — the single source of truth; both pricing pages and the `plans` action read from it. The EVM (USDC-only) sibling path is [api/payments/evm/[action].js](../api/payments/evm/%5Baction%5D.js).diff --git a/docs/start-here.md b/docs/start-here.mdindex 60c387270..6fabfbb36 100644--- a/docs/start-here.md+++ b/docs/start-here.md@@ -67,5 +67,6 @@ If you're here to create and share agents rather than write code, follow this pa- **Meeting avatars in the worlds?** → Press <kbd>I</kbd> on anyone in `/play`, `/city`, a coin world, or `/agora` to see who they are — the [avatar inspector](./avatar-inspector.md) shows their reputation, wallet, and profile- **Trading?** → [The trading surfaces](./trading-surfaces.md) maps the solo stack (Radar, Coin Intelligence, Live Trade Feed, Watchlist, Mission Control); [trading arenas](./trading-arenas.md) covers tournaments, the theater, vaults, and swarms; [Oracle](./oracle.md) is the conviction engine underneath all of it- **Trusting an agent with money?** → [Custody you can verify](./custody.md) — spend limits, freeze, Merkle proof-of-custody, and social recovery; [claim your wallet](./trader-card.md) turns any pump.fun track record into a public, provable Trader Card. Every real-funds feature sits behind the [risk acknowledgment](./risk-acknowledgment.md) — read the [Risk Disclosure](https://three.ws/legal/risk) before committing anything+- **Going Pro?** → [Paid plans](./plan-checkout.md) — upgrade with a single on-chain payment in USDC, SOL, or $THREE (the platform coin takes 20% off); [hold-to-access](./hold-to-access.md) covers the separate hold-$THREE tier ladder- **Developer docs** → Read the [Introduction](./introduction.md) for the full technical picture- **Building UI?** → [ui-juice](./ui-juice.md) is the shared game-feel library (count-ups, sparklines, ring gauges, live dots, the "it shipped" ripple) every surface animates withdiff --git a/pages/x-pricing.html b/pages/x-pricing.htmlindex 5551aa2c1..43e713484 100644--- a/pages/x-pricing.html+++ b/pages/x-pricing.html@@ -45,6 +45,10 @@.btn { padding:12px 16px; border-radius:10px; border:0; background:var(--accent); color:#fff; font-size:14px; font-weight:600; cursor:pointer; margin-top:auto; }.btn:hover { filter:brightness(1.1); }.btn.sec { background:#222222; color:#ddd; }+ .asset-btn { margin-top:0; padding:8px 14px; }+ .asset-btn[aria-pressed="true"] { background:var(--accent); color:#000; }+ #three-off { color:#4ade80; font-weight:600; }+ .asset-btn[aria-pressed="true"] #three-off { color:#05610f; }.btn:disabled { opacity:0.5; cursor:not-allowed; }.checkout { display:none; margin-top:36px; padding:24px; border:1px solid var(--accent); border-radius:14px; background:rgba(255,255,255,0.04); }.checkout.show { display:block; }@@ -83,7 +87,8 @@<div class="card pro"><div class="tag">Recommended</div><div class="tier">Pro</div>- <div class="price">$19<small> /month</small></div>+ <div class="price"><span id="pro-price">$49</span><small> /month</small></div>+ <div class="muted" id="three-note" style="font-size:12px"></div><ul class="feat"><li>100 X posts per month</li><li>1 post every 5 min</li>@@ -92,12 +97,17 @@<li>Multi-draft picker (3 options)</li><li>Priority support</li></ul>- <button class="btn" id="upgrade-btn">Upgrade with USDC</button>+ <button class="btn" id="upgrade-btn">Upgrade — pay in USDC, SOL, or $THREE</button></div></div><div class="checkout" id="checkout">- <h3 style="margin:0 0 8px">Pay $19 USDC on Solana</h3>+ <h3 style="margin:0 0 8px" id="checkout-title">Pay on Solana</h3>+ <div id="asset-row" style="display:flex; gap:8px; margin:2px 0 12px; flex-wrap:wrap">+ <button class="btn sec asset-btn" data-asset="USDC" aria-pressed="true">USDC</button>+ <button class="btn sec asset-btn" data-asset="SOL" aria-pressed="false">SOL</button>+ <button class="btn sec asset-btn" data-asset="THREE" aria-pressed="false">$THREE <span id="three-off"></span></button>+ </div><p class="muted">Scan with Phantom or any Solana wallet, or open the link on the device with your wallet.</p><img class="qr" id="qr" alt="Solana Pay QR" /><code class="payurl" id="payurl"></code>@@ -114,6 +124,25 @@const setStatus = (text, cls = '') => { $('status').textContent = text; $('status').className = 'status ' + cls; };let currentIntent = null;+ let selectedAsset = 'USDC';+ const assetLabel = (a) => (a === 'THREE' ? '$THREE' : a);++ // Server-truth plan prices + the $THREE discount.+ try {+ const r = await fetch('/api/payments/solana?action=plans');+ if (r.ok) {+ const d = await r.json();+ const pro = d.plans?.pro;+ if (pro) {+ $('pro-price').textContent = `$${pro.price_usd}`;+ if (d.three_discount_bps > 0) {+ const pct = (d.three_discount_bps / 100).toFixed(0);+ $('three-note').textContent = `or $${pro.three_price_usd} in $THREE (${pct}% off)`;+ $('three-off').textContent = `−${pct}%`;+ }+ }+ }+ } catch {}// Show current plan if signed in.try {@@ -125,19 +154,21 @@}} catch {}- $('upgrade-btn').addEventListener('click', async () => {+ async function createCheckout() {$('upgrade-btn').disabled = true;$('upgrade-btn').textContent = 'Creating checkout…';+ setStatus('');try {const r = await fetch('/api/payments/solana?action=checkout', {method: 'POST',credentials: 'include',headers: { 'content-type': 'application/json' },- body: JSON.stringify({ plan: 'pro', network: 'mainnet' }),+ body: JSON.stringify({ plan: 'pro', asset: selectedAsset, network: 'mainnet' }),});const d = await r.json();if (!r.ok) throw new Error(d.error_description || 'checkout failed');currentIntent = d;+ $('checkout-title').textContent = `Pay ${d.amount_asset} ${assetLabel(d.asset)} on Solana`;$('payurl').textContent = d.solana_pay_url;$('qr').src = `https://api.qrserver.com/v1/create-qr-code/?size=400x400&data=${encodeURIComponent(d.solana_pay_url)}`;$('open-link').href = d.solana_pay_url;@@ -145,12 +176,29 @@$('upgrade-btn').textContent = 'Pay below ↓';} catch (err) {$('upgrade-btn').disabled = false;- $('upgrade-btn').textContent = 'Upgrade with USDC';+ $('upgrade-btn').textContent = 'Upgrade — pay in USDC, SOL, or $THREE';alert(err.message);}- });+ }++ $('upgrade-btn').addEventListener('click', createCheckout);++ // Switching the asset re-quotes: SOL and $THREE amounts are pinned per+ // checkout session, so a new asset always needs a fresh intent.+ for (const btn of document.querySelectorAll('.asset-btn')) {+ btn.addEventListener('click', () => {+ if (btn.dataset.asset === selectedAsset) return;+ selectedAsset = btn.dataset.asset;+ for (const b of document.querySelectorAll('.asset-btn'))+ b.setAttribute('aria-pressed', String(b === btn));+ if ($('checkout').classList.contains('show')) createCheckout();+ });+ }- $('confirm-btn').addEventListener('click', async () => {+ // Confirm, retrying while the tx finalizes — the API only accepts+ // finalized transactions, which takes ~10-30s after landing.+ let confirmTries = 0;+ async function confirmPayment() {const txsig = $('txsig').value.trim();if (!txsig) return setStatus('Paste the transaction signature first.', 'err');if (!currentIntent) return setStatus('No active checkout — click Upgrade first.', 'err');@@ -164,14 +212,24 @@body: JSON.stringify({ intent_id: currentIntent.intent_id, tx_signature: txsig, network: 'mainnet' }),});const d = await r.json();- if (!r.ok) throw new Error(d.error_description || 'confirm failed');- setStatus(`You're Pro until ${new Date(d.active_until).toLocaleDateString()}. Redirecting…`, 'ok');- setTimeout(() => { location.href = '/dashboard'; }, 1800);+ if (r.ok) {+ setStatus(`You're Pro until ${new Date(d.active_until).toLocaleDateString()}. Redirecting…`, 'ok');+ setTimeout(() => { location.href = '/dashboard'; }, 1800);+ return;+ }+ if (d.error === 'tx_not_found' && confirmTries < 30) {+ confirmTries += 1;+ setStatus('Waiting for the transaction to finalize… retrying automatically.');+ setTimeout(confirmPayment, 6000);+ return;+ }+ throw new Error(d.error_description || 'confirm failed');} catch (err) {setStatus(err.message, 'err');$('confirm-btn').disabled = false;}- });+ }+ $('confirm-btn').addEventListener('click', () => { confirmTries = 0; confirmPayment(); });</script><script src="/brand.js" defer></script></body>diff --git a/public/animations/thumbs/angry.webp b/public/animations/thumbs/angry.webpnew file mode 100644index 000000000..b90d49025Binary files /dev/null and b/public/animations/thumbs/angry.webp differdiff --git a/public/animations/thumbs/av-arm-flex.webp b/public/animations/thumbs/av-arm-flex.webpnew file mode 100644index 000000000..688bc24eaBinary files /dev/null and b/public/animations/thumbs/av-arm-flex.webp differdiff --git a/public/animations/thumbs/av-back-flip.webp b/public/animations/thumbs/av-back-flip.webpnew file mode 100644index 000000000..731a6d195Binary files /dev/null and b/public/animations/thumbs/av-back-flip.webp differdiff --git a/public/animations/thumbs/av-banging-tunes.webp b/public/animations/thumbs/av-banging-tunes.webpnew file mode 100644index 000000000..636ebb0a6Binary files /dev/null and b/public/animations/thumbs/av-banging-tunes.webp differdiff --git a/public/animations/thumbs/av-boxer-dance.webp b/public/animations/thumbs/av-boxer-dance.webpnew file mode 100644index 000000000..92d8f72a7Binary files /dev/null and b/public/animations/thumbs/av-boxer-dance.webp differdiff --git a/public/animations/thumbs/av-brag-claps.webp b/public/animations/thumbs/av-brag-claps.webpnew file mode 100644index 000000000..fcc8b1510Binary files /dev/null and b/public/animations/thumbs/av-brag-claps.webp differdiff --git a/public/animations/thumbs/av-call-me.webp b/public/animations/thumbs/av-call-me.webpnew file mode 100644index 000000000..abe7577c3Binary files /dev/null and b/public/animations/thumbs/av-call-me.webp differdiff --git a/public/animations/thumbs/av-celebrating.webp b/public/animations/thumbs/av-celebrating.webpnew file mode 100644index 000000000..222bc12a8Binary files /dev/null and b/public/animations/thumbs/av-celebrating.webp differdiff --git a/public/animations/thumbs/av-cheering.webp b/public/animations/thumbs/av-cheering.webpnew file mode 100644index 000000000..8539d1b70Binary files /dev/null and b/public/animations/thumbs/av-cheering.webp differdiff --git a/public/animations/thumbs/av-chest-bump.webp b/public/animations/thumbs/av-chest-bump.webpnew file mode 100644index 000000000..2d440157aBinary files /dev/null and b/public/animations/thumbs/av-chest-bump.webp differdiff --git a/public/animations/thumbs/av-chilling.webp b/public/animations/thumbs/av-chilling.webpnew file mode 100644index 000000000..daaa6d8dfBinary files /dev/null and b/public/animations/thumbs/av-chilling.webp differdiff --git a/public/animations/thumbs/av-conductor.webp b/public/animations/thumbs/av-conductor.webpnew file mode 100644index 000000000..dcdeeaf68Binary files /dev/null and b/public/animations/thumbs/av-conductor.webp differdiff --git a/public/animations/thumbs/av-dance-shuffle.webp b/public/animations/thumbs/av-dance-shuffle.webpnew file mode 100644index 000000000..8d46e8a0eBinary files /dev/null and b/public/animations/thumbs/av-dance-shuffle.webp differdiff --git a/public/animations/thumbs/av-flexing-arm.webp b/public/animations/thumbs/av-flexing-arm.webpnew file mode 100644index 000000000..324065d7dBinary files /dev/null and b/public/animations/thumbs/av-flexing-arm.webp differdiff --git a/public/animations/thumbs/av-gymnastics-aerial.webp b/public/animations/thumbs/av-gymnastics-aerial.webpnew file mode 100644index 000000000..30ff8a0deBinary files /dev/null and b/public/animations/thumbs/av-gymnastics-aerial.webp differdiff --git a/public/animations/thumbs/av-headbang.webp b/public/animations/thumbs/av-headbang.webpnew file mode 100644index 000000000..4669812a1Binary files /dev/null and b/public/animations/thumbs/av-headbang.webp differdiff --git a/public/animations/thumbs/av-idle-anim.webp b/public/animations/thumbs/av-idle-anim.webpnew file mode 100644index 000000000..52c8fd28bBinary files /dev/null and b/public/animations/thumbs/av-idle-anim.webp differdiff --git a/public/animations/thumbs/av-idle-female.webp b/public/animations/thumbs/av-idle-female.webpnew file mode 100644index 000000000..a82bc7b19Binary files /dev/null and b/public/animations/thumbs/av-idle-female.webp differdiff --git a/public/animations/thumbs/av-idle-male.webp b/public/animations/thumbs/av-idle-male.webpnew file mode 100644index 000000000..f0e9b93a6Binary files /dev/null and b/public/animations/thumbs/av-idle-male.webp differdiff --git a/public/animations/thumbs/av-joy.webp b/public/animations/thumbs/av-joy.webpnew file mode 100644index 000000000..3382d4dfdBinary files /dev/null and b/public/animations/thumbs/av-joy.webp differdiff --git a/public/animations/thumbs/av-leaning-wall.webp b/public/animations/thumbs/av-leaning-wall.webpnew file mode 100644index 000000000..45141f8afBinary files /dev/null and b/public/animations/thumbs/av-leaning-wall.webp differdiff --git a/public/animations/thumbs/av-listening-music.webp b/public/animations/thumbs/av-listening-music.webpnew file mode 100644index 000000000..843b8ff08Binary files /dev/null and b/public/animations/thumbs/av-listening-music.webp differdiff --git a/public/animations/thumbs/av-muay-thai.webp b/public/animations/thumbs/av-muay-thai.webpnew file mode 100644index 000000000..5d31e62fbBinary files /dev/null and b/public/animations/thumbs/av-muay-thai.webp differdiff --git a/public/animations/thumbs/av-pose1.webp b/public/animations/thumbs/av-pose1.webpnew file mode 100644index 000000000..6df620bbaBinary files /dev/null and b/public/animations/thumbs/av-pose1.webp differdiff --git a/public/animations/thumbs/av-push-block.webp b/public/animations/thumbs/av-push-block.webpnew file mode 100644index 000000000..8602b33aaBinary files /dev/null and b/public/animations/thumbs/av-push-block.webp differdiff --git a/public/animations/thumbs/av-rap-dance.webp b/public/animations/thumbs/av-rap-dance.webpnew file mode 100644index 000000000..d8cb0c2dbBinary files /dev/null and b/public/animations/thumbs/av-rap-dance.webp differdiff --git a/public/animations/thumbs/av-smoking.webp b/public/animations/thumbs/av-smoking.webpnew file mode 100644index 000000000..838d56cb3Binary files /dev/null and b/public/animations/thumbs/av-smoking.webp differdiff --git a/public/animations/thumbs/av-spy.webp b/public/animations/thumbs/av-spy.webpnew file mode 100644index 000000000..137b22d07Binary files /dev/null and b/public/animations/thumbs/av-spy.webp differdiff --git a/public/animations/thumbs/av-stand-crouch-stand.webp b/public/animations/thumbs/av-stand-crouch-stand.webpnew file mode 100644index 000000000..e719ccf75Binary files /dev/null and b/public/animations/thumbs/av-stand-crouch-stand.webp differdiff --git a/public/animations/thumbs/av-superhero-jump.webp b/public/animations/thumbs/av-superhero-jump.webpnew file mode 100644index 000000000..9000ca65bBinary files /dev/null and b/public/animations/thumbs/av-superhero-jump.webp differdiff --git a/public/animations/thumbs/av-vtubing.webp b/public/animations/thumbs/av-vtubing.webpnew file mode 100644index 000000000..390075348Binary files /dev/null and b/public/animations/thumbs/av-vtubing.webp differdiff --git a/public/animations/thumbs/av-walk-crouching.webp b/public/animations/thumbs/av-walk-crouching.webpnew file mode 100644index 000000000..d639d581dBinary files /dev/null and b/public/animations/thumbs/av-walk-crouching.webp differdiff --git a/public/animations/thumbs/av-walk-feminine.webp b/public/animations/thumbs/av-walk-feminine.webpnew file mode 100644index 000000000..ad6d93436Binary files /dev/null and b/public/animations/thumbs/av-walk-feminine.webp differdiff --git a/public/animations/thumbs/capoeira.webp b/public/animations/thumbs/capoeira.webpnew file mode 100644index 000000000..df4ce6ef3Binary files /dev/null and b/public/animations/thumbs/capoeira.webp differdiff --git a/public/animations/thumbs/celebrate.webp b/public/animations/thumbs/celebrate.webpnew file mode 100644index 000000000..6dde45b01Binary files /dev/null and b/public/animations/thumbs/celebrate.webp differdiff --git a/public/animations/thumbs/coverstand.webp b/public/animations/thumbs/coverstand.webpnew file mode 100644index 000000000..6dd8cf256Binary files /dev/null and b/public/animations/thumbs/coverstand.webp differdiff --git a/public/animations/thumbs/dance.webp b/public/animations/thumbs/dance.webpnew file mode 100644index 000000000..202a7129bBinary files /dev/null and b/public/animations/thumbs/dance.webp differdiff --git a/public/animations/thumbs/defeated.webp b/public/animations/thumbs/defeated.webpnew file mode 100644index 000000000..c5f81eb72Binary files /dev/null and b/public/animations/thumbs/defeated.webp differdiff --git a/public/animations/thumbs/digging.webp b/public/animations/thumbs/digging.webpnew file mode 100644index 000000000..2597bad47Binary files /dev/null and b/public/animations/thumbs/digging.webp differdiff --git a/public/animations/thumbs/dodge.webp b/public/animations/thumbs/dodge.webpnew file mode 100644index 000000000..b20f6aab4Binary files /dev/null and b/public/animations/thumbs/dodge.webp differdiff --git a/public/animations/thumbs/downdog.webp b/public/animations/thumbs/downdog.webpnew file mode 100644index 000000000..ab35ebd38Binary files /dev/null and b/public/animations/thumbs/downdog.webp differdiff --git a/public/animations/thumbs/dying.webp b/public/animations/thumbs/dying.webpnew file mode 100644index 000000000..51c7e5a3eBinary files /dev/null and b/public/animations/thumbs/dying.webp differdiff --git a/public/animations/thumbs/falling.webp b/public/animations/thumbs/falling.webpnew file mode 100644index 000000000..9bfd0b0b2Binary files /dev/null and b/public/animations/thumbs/falling.webp differdiff --git a/public/animations/thumbs/falltolanding.webp b/public/animations/thumbs/falltolanding.webpnew file mode 100644index 000000000..c682d37e9Binary files /dev/null and b/public/animations/thumbs/falltolanding.webp differdiff --git a/public/animations/thumbs/farm-box-idle.webp b/public/animations/thumbs/farm-box-idle.webpnew file mode 100644index 000000000..d7cf221d0Binary files /dev/null and b/public/animations/thumbs/farm-box-idle.webp differdiff --git a/public/animations/thumbs/farm-box-turn.webp b/public/animations/thumbs/farm-box-turn.webpnew file mode 100644index 000000000..a625a49beBinary files /dev/null and b/public/animations/thumbs/farm-box-turn.webp differdiff --git a/public/animations/thumbs/farm-box-walk.webp b/public/animations/thumbs/farm-box-walk.webpnew file mode 100644index 000000000..d930d5110Binary files /dev/null and b/public/animations/thumbs/farm-box-walk.webp differdiff --git a/public/animations/thumbs/farm-cow-milking.webp b/public/animations/thumbs/farm-cow-milking.webpnew file mode 100644index 000000000..f80aeedb3Binary files /dev/null and b/public/animations/thumbs/farm-cow-milking.webp differdiff --git a/public/animations/thumbs/farm-dig-plant.webp b/public/animations/thumbs/farm-dig-plant.webpnew file mode 100644index 000000000..69d253eb1Binary files /dev/null and b/public/animations/thumbs/farm-dig-plant.webp differdiff --git a/public/animations/thumbs/farm-holding-turn-left.webp b/public/animations/thumbs/farm-holding-turn-left.webpnew file mode 100644index 000000000..987206c84Binary files /dev/null and b/public/animations/thumbs/farm-holding-turn-left.webp differdiff --git a/public/animations/thumbs/farm-holding-turn-right.webp b/public/animations/thumbs/farm-holding-turn-right.webpnew file mode 100644index 000000000..d39c3f08bBinary files /dev/null and b/public/animations/thumbs/farm-holding-turn-right.webp differdiff --git a/public/animations/thumbs/farm-holding-walk.webp b/public/animations/thumbs/farm-holding-walk.webpnew file mode 100644index 000000000..a6ae8e476Binary files /dev/null and b/public/animations/thumbs/farm-holding-walk.webp differdiff --git a/public/animations/thumbs/farm-kneeling-idle.webp b/public/animations/thumbs/farm-kneeling-idle.webpnew file mode 100644index 000000000..771a59850Binary files /dev/null and b/public/animations/thumbs/farm-kneeling-idle.webp differdiff --git a/public/animations/thumbs/farm-pick-fruit.webp b/public/animations/thumbs/farm-pick-fruit.webpnew file mode 100644index 000000000..016754507Binary files /dev/null and b/public/animations/thumbs/farm-pick-fruit.webp differdiff --git a/public/animations/thumbs/farm-plant-a-plant.webp b/public/animations/thumbs/farm-plant-a-plant.webpnew file mode 100644index 000000000..9b6b25d63Binary files /dev/null and b/public/animations/thumbs/farm-plant-a-plant.webp differdiff --git a/public/animations/thumbs/farm-plant-tree.webp b/public/animations/thumbs/farm-plant-tree.webpnew file mode 100644index 000000000..9b4f7a7a3Binary files /dev/null and b/public/animations/thumbs/farm-plant-tree.webp differdiff --git a/public/animations/thumbs/farm-pull-plant.webp b/public/animations/thumbs/farm-pull-plant.webpnew file mode 100644index 000000000..a3801714fBinary files /dev/null and b/public/animations/thumbs/farm-pull-plant.webp differdiff --git a/public/animations/thumbs/farm-watering.webp b/public/animations/thumbs/farm-watering.webpnew file mode 100644index 000000000..bda11dc4eBinary files /dev/null and b/public/animations/thumbs/farm-watering.webp differdiff --git a/public/animations/thumbs/farm-wheelbarrow-dump.webp b/public/animations/thumbs/farm-wheelbarrow-dump.webpnew file mode 100644index 000000000..25a706189Binary files /dev/null and b/public/animations/thumbs/farm-wheelbarrow-dump.webp differdiff --git a/public/animations/thumbs/farm-wheelbarrow-idle.webp b/public/animations/thumbs/farm-wheelbarrow-idle.webpnew file mode 100644index 000000000..c0a77631fBinary files /dev/null and b/public/animations/thumbs/farm-wheelbarrow-idle.webp differdiff --git a/public/animations/thumbs/farm-wheelbarrow-turn.webp b/public/animations/thumbs/farm-wheelbarrow-turn.webpnew file mode 100644index 000000000..8afaaca04Binary files /dev/null and b/public/animations/thumbs/farm-wheelbarrow-turn.webp differdiff --git a/public/animations/thumbs/farm-wheelbarrow-walk.webp b/public/animations/thumbs/farm-wheelbarrow-walk.webpnew file mode 100644index 000000000..09bd5fb35Binary files /dev/null and b/public/animations/thumbs/farm-wheelbarrow-walk.webp differdiff --git a/public/animations/thumbs/goalkeeper.webp b/public/animations/thumbs/goalkeeper.webpnew file mode 100644index 000000000..ea01654b4Binary files /dev/null and b/public/animations/thumbs/goalkeeper.webp differdiff --git a/public/animations/thumbs/header.webp b/public/animations/thumbs/header.webpnew file mode 100644index 000000000..344a76db5Binary files /dev/null and b/public/animations/thumbs/header.webp differdiff --git a/public/animations/thumbs/jump.webp b/public/animations/thumbs/jump.webpnew file mode 100644index 000000000..6dde45b01Binary files /dev/null and b/public/animations/thumbs/jump.webp differdiff --git a/public/animations/thumbs/jumpdown.webp b/public/animations/thumbs/jumpdown.webpnew file mode 100644index 000000000..93fc465b9Binary files /dev/null and b/public/animations/thumbs/jumpdown.webp differdiff --git a/public/animations/thumbs/jumpdown2.webp b/public/animations/thumbs/jumpdown2.webpnew file mode 100644index 000000000..32f11076cBinary files /dev/null and b/public/animations/thumbs/jumpdown2.webp differdiff --git a/public/animations/thumbs/jumpdown3.webp b/public/animations/thumbs/jumpdown3.webpnew file mode 100644index 000000000..61f04f68dBinary files /dev/null and b/public/animations/thumbs/jumpdown3.webp differdiff --git a/public/animations/thumbs/kiss.webp b/public/animations/thumbs/kiss.webpnew file mode 100644index 000000000..90eba8acbBinary files /dev/null and b/public/animations/thumbs/kiss.webp differdiff --git a/public/animations/thumbs/michelle-samba-dance.webp b/public/animations/thumbs/michelle-samba-dance.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/michelle-samba-dance.webp differdiff --git a/public/animations/thumbs/pray.webp b/public/animations/thumbs/pray.webpnew file mode 100644index 000000000..2b89c56c0Binary files /dev/null and b/public/animations/thumbs/pray.webp differdiff --git a/public/animations/thumbs/reaction.webp b/public/animations/thumbs/reaction.webpnew file mode 100644index 000000000..4756d6af4Binary files /dev/null and b/public/animations/thumbs/reaction.webp differdiff --git a/public/animations/thumbs/removing.webp b/public/animations/thumbs/removing.webpnew file mode 100644index 000000000..2a7e004abBinary files /dev/null and b/public/animations/thumbs/removing.webp differdiff --git a/public/animations/thumbs/rumba.webp b/public/animations/thumbs/rumba.webpnew file mode 100644index 000000000..2403574b8Binary files /dev/null and b/public/animations/thumbs/rumba.webp differdiff --git a/public/animations/thumbs/shoved.webp b/public/animations/thumbs/shoved.webpnew file mode 100644index 000000000..791812224Binary files /dev/null and b/public/animations/thumbs/shoved.webp differdiff --git a/public/animations/thumbs/silly.webp b/public/animations/thumbs/silly.webpnew file mode 100644index 000000000..83c82879bBinary files /dev/null and b/public/animations/thumbs/silly.webp differdiff --git a/public/animations/thumbs/sitclap.webp b/public/animations/thumbs/sitclap.webpnew file mode 100644index 000000000..976de5147Binary files /dev/null and b/public/animations/thumbs/sitclap.webp differdiff --git a/public/animations/thumbs/sitlaugh.webp b/public/animations/thumbs/sitlaugh.webpnew file mode 100644index 000000000..2c9e931b3Binary files /dev/null and b/public/animations/thumbs/sitlaugh.webp differdiff --git a/public/animations/thumbs/soldier-idle.webp b/public/animations/thumbs/soldier-idle.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/soldier-idle.webp differdiff --git a/public/animations/thumbs/soldier-run.webp b/public/animations/thumbs/soldier-run.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/soldier-run.webp differdiff --git a/public/animations/thumbs/soldier-walk.webp b/public/animations/thumbs/soldier-walk.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/soldier-walk.webp differdiff --git a/public/animations/thumbs/standup.webp b/public/animations/thumbs/standup.webpnew file mode 100644index 000000000..ec9bb0e70Binary files /dev/null and b/public/animations/thumbs/standup.webp differdiff --git a/public/animations/thumbs/stepback.webp b/public/animations/thumbs/stepback.webpnew file mode 100644index 000000000..5e8750271Binary files /dev/null and b/public/animations/thumbs/stepback.webp differdiff --git a/public/animations/thumbs/taunt.webp b/public/animations/thumbs/taunt.webpnew file mode 100644index 000000000..a7ec147d6Binary files /dev/null and b/public/animations/thumbs/taunt.webp differdiff --git a/public/animations/thumbs/thriller.webp b/public/animations/thumbs/thriller.webpnew file mode 100644index 000000000..35212e255Binary files /dev/null and b/public/animations/thumbs/thriller.webp differdiff --git a/public/animations/thumbs/torch-light-wall.webp b/public/animations/thumbs/torch-light-wall.webpnew file mode 100644index 000000000..c66bc1aa0Binary files /dev/null and b/public/animations/thumbs/torch-light-wall.webp differdiff --git a/public/animations/thumbs/torch-light.webp b/public/animations/thumbs/torch-light.webpnew file mode 100644index 000000000..2a333055eBinary files /dev/null and b/public/animations/thumbs/torch-light.webp differdiff --git a/public/animations/thumbs/twerk.webp b/public/animations/thumbs/twerk.webpnew file mode 100644index 000000000..768320071Binary files /dev/null and b/public/animations/thumbs/twerk.webp differdiff --git a/public/animations/thumbs/walk.webp b/public/animations/thumbs/walk.webpnew file mode 100644index 000000000..e1806dd4aBinary files /dev/null and b/public/animations/thumbs/walk.webp differdiff --git a/public/animations/thumbs/wave.webp b/public/animations/thumbs/wave.webpnew file mode 100644index 000000000..125ae1e95Binary files /dev/null and b/public/animations/thumbs/wave.webp differdiff --git a/public/animations/thumbs/xbot-agree.webp b/public/animations/thumbs/xbot-agree.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-agree.webp differdiff --git a/public/animations/thumbs/xbot-head-shake.webp b/public/animations/thumbs/xbot-head-shake.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-head-shake.webp differdiff --git a/public/animations/thumbs/xbot-idle.webp b/public/animations/thumbs/xbot-idle.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-idle.webp differdiff --git a/public/animations/thumbs/xbot-run.webp b/public/animations/thumbs/xbot-run.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-run.webp differdiff --git a/public/animations/thumbs/xbot-sad-pose.webp b/public/animations/thumbs/xbot-sad-pose.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-sad-pose.webp differdiff --git a/public/animations/thumbs/xbot-sneak-pose.webp b/public/animations/thumbs/xbot-sneak-pose.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-sneak-pose.webp differdiff --git a/public/animations/thumbs/xbot-walk.webp b/public/animations/thumbs/xbot-walk.webpnew file mode 100644index 000000000..b92424115Binary files /dev/null and b/public/animations/thumbs/xbot-walk.webp differdiff --git a/public/changelog.json b/public/changelog.jsonindex 80a7cc396..3a08cf56f 100644--- a/public/changelog.json+++ b/public/changelog.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-05T08:35:14.324Z",+ "generated_at": "2026-07-05T08:41:49.006Z","generated_by": "scripts/build-page-index.mjs from data/pages.json + data/changelog.json","site": {"name": "three.ws",@@ -39,6 +39,27 @@"improvement"]},+ {+ "date": "2026-07-05",+ "type": "update",+ "title": "Go Pro with SOL or $THREE — 20% off in the platform coin",+ "summary": "The Pro plan is now a real self-serve upgrade you can buy on-chain. The pricing page checkout accepts USDC, SOL, or $THREE on Solana: pick your asset, scan a Solana Pay QR (or open it straight in your wallet), and your account upgrades the moment the payment finalizes. SOL and $THREE amounts are quoted at the live market price and pinned for the session, and paying in $THREE takes 20% off the sticker price — holding the coin already earns discounts, and now spending it does too.",+ "link": "/pricing",+ "tags": [+ "feature"+ ]+ },+ {+ "date": "2026-07-05",+ "type": "update",+ "title": "Payments a wallet silently rewrites now explain themselves instead of bouncing",+ "summary": "Some Solana wallets modify a payment transaction before signing it — injecting their own fee or guard instructions — and the platform's payment verifier rightly refuses anything that isn't the exact transfer it prepared. Until now that refusal looked like a dead end: the pay button bounced with a payment-required error no matter how many times you retried. The checkout now detects the rewrite the moment the wallet hands the transaction back and says plainly that the wallet altered it and nothing was charged, so you can switch wallets instead of retrying in circles. Verify rejections and settle failures are also now counted by reason on the public health endpoint, so a streak of refused payments is visible at a glance instead of hiding in admin logs.",+ "link": "/club",+ "tags": [+ "fix",+ "improvement"+ ]+ },{"date": "2026-07-05","type": "update",diff --git a/public/changelog.xml b/public/changelog.xmlindex e9614cbac..5f65649dc 100644--- a/public/changelog.xml+++ b/public/changelog.xml@@ -30,6 +30,22 @@<category>fix</category><description>If you hit your plan's avatar limit while creating an agent, the wizard used to fail with a bare error and leave you stuck. It now explains what happened and gives you three ways forward, right in the form: connect an avatar you already own (one click jumps you to your library), free up a slot by deleting an old avatar, or upgrade your plan. Oversized model files get a clearer message too.</description></item>+ <item>+ <title>Go Pro with SOL or $THREE — 20% off in the platform coin</title>+ <link>https://three.ws/pricing</link>+ <guid isPermaLink="false">2026-07-05:Go Pro with SOL or $THREE — 20% off in the platform coin</guid>+ <pubDate>Sun, 05 Jul 2026 12:00:00 GMT</pubDate>+ <category>feature</category>+ <description>The Pro plan is now a real self-serve upgrade you can buy on-chain. The pricing page checkout accepts USDC, SOL, or $THREE on Solana: pick your asset, scan a Solana Pay QR (or open it straight in your wallet), and your account upgrades the moment the payment finalizes. SOL and $THREE amounts are quoted at the live market price and pinned for the session, and paying in $THREE takes 20% off the sticker price — holding the coin already earns discounts, and now spending it does too.</description>+ </item>+ <item>+ <title>Payments a wallet silently rewrites now explain themselves instead of bouncing</title>+ <link>https://three.ws/club</link>+ <guid isPermaLink="false">2026-07-05:Payments a wallet silently rewrites now explain themselves instead of bouncing</guid>+ <pubDate>Sun, 05 Jul 2026 12:00:00 GMT</pubDate>+ <category>fix</category>+ <description>Some Solana wallets modify a payment transaction before signing it — injecting their own fee or guard instructions — and the platform's payment verifier rightly refuses anything that isn't the exact transfer it prepared. Until now that refusal looked like a dead end: the pay button bounced with a payment-required error no matter how many times you retried. The checkout now detects the rewrite the moment the wallet hands the transaction back and says plainly that the wallet altered it and nothing was charged, so you can switch wallets instead of retrying in circles. Verify rejections and settle failures are also now counted by reason on the public health endpoint, so a streak of refused payments is visible at a glance instead of hiding in admin logs.</description>+ </item><item><title>Status page no longer reports a phantom outage — and graduation tracking runs clean</title><link>https://three.ws/status</link>diff --git a/public/features.json b/public/features.jsonindex cf7a7b0e3..e32c0dfe8 100644--- a/public/features.json+++ b/public/features.json@@ -1,5 +1,5 @@{- "generated_at": "2026-07-05T08:35:14.312Z",+ "generated_at": "2026-07-05T08:41:48.993Z","generated_by": "scripts/build-page-index.mjs from data/pages.json","site": {"name": "three.ws",diff --git a/public/pricing.css b/public/pricing.cssindex a5d2b5523..7b4cade06 100644--- a/public/pricing.css+++ b/public/pricing.css@@ -1250,3 +1250,303 @@grid-template-columns: 1fr;}}++/* ── Pro checkout modal — pay in USDC, SOL, or $THREE ─────────────────── */++.pricing-pay-assets {+ margin-top: 12px;+ font-size: 12px;+ color: rgba(255, 255, 255, 0.45);+ text-align: center;+}++.pricing-pay-assets strong {+ color: rgba(255, 255, 255, 0.75);+ font-weight: 600;+}++.pricing-three-discount {+ color: #4ade80;+ font-weight: 600;+}++.pc-overlay {+ position: fixed;+ inset: 0;+ z-index: 1000;+ display: flex;+ align-items: center;+ justify-content: center;+ padding: 20px;+ background: rgba(0, 0, 0, 0.72);+ backdrop-filter: blur(6px);+ animation: pc-fade var(--duration-fast, 140ms) var(--ease-standard, ease);+}++@keyframes pc-fade {+ from { opacity: 0; }+ to { opacity: 1; }+}++.pc-dialog {+ position: relative;+ width: min(560px, 100%);+ max-height: calc(100vh - 40px);+ overflow-y: auto;+ background: #0d0d0f;+ border: 1px solid rgba(255, 255, 255, 0.14);+ border-radius: 18px;+ padding: 30px 28px 26px;+ color: #eee;+ box-shadow: 0 24px 80px rgba(0, 0, 0, 0.6);+ animation: pc-rise var(--duration-fast, 180ms) var(--ease-standard, ease);+ outline: none;+}++@keyframes pc-rise {+ from { opacity: 0; transform: translateY(14px); }+ to { opacity: 1; transform: translateY(0); }+}++@media (prefers-reduced-motion: reduce) {+ .pc-overlay, .pc-dialog { animation: none; }+}++.pc-dialog h3 {+ font-family: var(--font-display, 'Space Grotesk', 'Inter', sans-serif);+ font-size: 24px;+ margin: 0 0 6px;+ letter-spacing: -0.02em;+}++.pc-sub {+ color: rgba(255, 255, 255, 0.55);+ font-size: 14px;+ margin: 0 0 22px;+}++.pc-close {+ position: absolute;+ top: 16px;+ right: 16px;+ width: 32px;+ height: 32px;+ display: flex;+ align-items: center;+ justify-content: center;+ background: rgba(255, 255, 255, 0.06);+ border: 1px solid rgba(255, 255, 255, 0.12);+ border-radius: 50%;+ color: rgba(255, 255, 255, 0.7);+ cursor: pointer;+ transition: background var(--duration-fast, 140ms) ease, color var(--duration-fast, 140ms) ease;+}++.pc-close:hover, .pc-close:focus-visible {+ background: rgba(255, 255, 255, 0.14);+ color: #fff;+}++.pc-close svg { width: 14px; height: 14px; }++.pc-assets {+ display: grid;+ grid-template-columns: repeat(3, 1fr);+ gap: 10px;+ margin-bottom: 18px;+}++@media (max-width: 520px) {+ .pc-assets { grid-template-columns: 1fr; }+}++.pc-asset {+ position: relative;+ display: flex;+ flex-direction: column;+ gap: 4px;+ padding: 16px 14px;+ background: rgba(255, 255, 255, 0.03);+ border: 1px solid rgba(255, 255, 255, 0.12);+ border-radius: 12px;+ color: #eee;+ text-align: left;+ cursor: pointer;+ transition: border-color var(--duration-fast, 140ms) ease, background var(--duration-fast, 140ms) ease, transform var(--duration-fast, 140ms) ease;+}++.pc-asset:hover { border-color: rgba(255, 255, 255, 0.35); transform: translateY(-1px); }++.pc-asset:focus-visible {+ outline: 2px solid #fff;+ outline-offset: 2px;+}++.pc-asset.is-selected {+ border-color: #fff;+ background: rgba(255, 255, 255, 0.07);+ box-shadow: 0 0 0 1px #fff inset;+}++.pc-asset-name {+ font-weight: 700;+ font-size: 15px;+ letter-spacing: -0.01em;+}++.pc-asset-price { font-size: 20px; font-weight: 600; }++.pc-asset-note {+ font-size: 11.5px;+ color: rgba(255, 255, 255, 0.5);+ line-height: 1.4;+}++.pc-asset-badge {+ position: absolute;+ top: -9px;+ right: 10px;+ background: #4ade80;+ color: #05240f;+ font-size: 10.5px;+ font-weight: 700;+ padding: 2px 8px;+ border-radius: 99px;+ letter-spacing: 0.03em;+}++.pc-continue { width: 100%; text-align: center; }++.pc-fineprint {+ font-size: 12px;+ color: rgba(255, 255, 255, 0.4);+ margin: 14px 0 0;+ line-height: 1.5;+}++.pc-quote {+ text-align: center;+ margin-bottom: 18px;+}++.pc-quote-amount {+ font-family: var(--font-display, 'Space Grotesk', 'Inter', sans-serif);+ font-size: 26px;+ font-weight: 700;+ letter-spacing: -0.02em;+ word-break: break-all;+}++.pc-quote-meta {+ font-size: 13px;+ color: rgba(255, 255, 255, 0.55);+ margin-top: 4px;+}++.pc-pay-grid {+ display: flex;+ gap: 18px;+ align-items: center;+ margin-bottom: 18px;+}++@media (max-width: 520px) {+ .pc-pay-grid { flex-direction: column; }+}++.pc-qr-wrap {+ background: #fff;+ border-radius: 12px;+ padding: 8px;+ line-height: 0;+ flex-shrink: 0;+ transition: opacity var(--duration-fast, 140ms) ease;+}++.pc-pay-actions {+ display: flex;+ flex-direction: column;+ gap: 8px;+ flex: 1;+ width: 100%;+}++.pc-pay-actions .pricing-cta { text-align: center; }++.pc-sig-label {+ display: block;+ font-size: 12.5px;+ color: rgba(255, 255, 255, 0.55);+ margin-bottom: 6px;+}++.pc-sig-row { display: flex; gap: 8px; }++.pc-sig-row input {+ flex: 1;+ min-width: 0;+ padding: 10px 12px;+ background: rgba(255, 255, 255, 0.04);+ border: 1px solid rgba(255, 255, 255, 0.14);+ border-radius: 10px;+ color: #eee;+ font-size: 13px;+ font-family: inherit;+ transition: border-color var(--duration-fast, 140ms) ease;+}++.pc-sig-row input:focus-visible {+ outline: none;+ border-color: #fff;+}++.pc-back {+ margin-top: 14px;+ background: none;+ border: 0;+ color: rgba(255, 255, 255, 0.5);+ font-size: 13px;+ cursor: pointer;+ padding: 4px 0;+}++.pc-back:hover, .pc-back:focus-visible { color: #fff; }++.pc-status {+ margin-top: 12px;+ font-size: 13px;+ color: rgba(255, 255, 255, 0.65);+ min-height: 1.2em;+ line-height: 1.5;+}++.pc-status.is-err { color: #ffb3b3; }++.pc-success { text-align: center; padding: 12px 0 4px; }++.pc-success-mark {+ width: 54px;+ height: 54px;+ margin: 0 auto 14px;+ display: flex;+ align-items: center;+ justify-content: center;+ border-radius: 50%;+ background: rgba(74, 222, 128, 0.14);+ border: 1px solid rgba(74, 222, 128, 0.45);+ color: #4ade80;+ font-size: 24px;+ font-weight: 700;+}++.pc-success h4 {+ font-family: var(--font-display, 'Space Grotesk', 'Inter', sans-serif);+ font-size: 20px;+ margin: 0 0 6px;+}++.pc-success p {+ color: rgba(255, 255, 255, 0.6);+ font-size: 14px;+ margin: 0 0 18px;+}diff --git a/public/x402.js b/public/x402.jsindex 38482b78f..62b9152e4 100644--- a/public/x402.js+++ b/public/x402.js@@ -1435,7 +1435,21 @@ class CheckoutModal {// PayAI during /settle.const SolanaWeb3 = await loadSolanaWeb3();const tx = SolanaWeb3.VersionedTransaction.deserialize(txBytes);+ // The merchant's facilitator only settles the exact transaction that+ // /prepare built — a wallet that rewrites it before signing (injected+ // priority-fee or guard instructions) produces a payment the verifier+ // deterministically rejects. Snapshot the message bytes before the+ // wallet touches the object (some wallets mutate in place), then+ // compare after signing: a mismatch becomes an immediate, named+ // explanation instead of a silent 402-retry loop.+ const preparedMsg = tx.message.serialize();const signed = await provider.signTransaction(tx);+ const signedMsg = signed?.message?.serialize?.();+ if (signedMsg && !bytesEqual(preparedMsg, signedMsg)) {+ throw new Error(+ `${walletName} altered the payment transaction before signing (wallets sometimes inject fee or guard instructions). Nothing was sent or charged. Turn off transaction modification in the wallet settings, or pay with a different Solana wallet.`,+ );+ }const signedB64 = uint8ArrayToBase64(signed.serialize());const builderCodeBlock = buildBuilderCodeEcho(this.challenge);@@ -1871,6 +1885,11 @@ function uint8ArrayToBase64(arr) {for (let i = 0; i < arr.length; i++) bin += String.fromCharCode(arr[i]);return btoa(bin);}+function bytesEqual(a, b) {+ if (a.length !== b.length) return false;+ for (let i = 0; i < a.length; i++) if (a[i] !== b[i]) return false;+ return true;+}function randomHex(bytes) {const arr = new Uint8Array(bytes);crypto.getRandomValues(arr);diff --git a/scripts/build-animation-thumbnails.mjs b/scripts/build-animation-thumbnails.mjsindex 6cbacd71d..53f3f34bb 100644--- a/scripts/build-animation-thumbnails.mjs+++ b/scripts/build-animation-thumbnails.mjs@@ -98,7 +98,10 @@ function loadJobs() {jobs.push({name: entry.name,loop: entry.loop !== false,- clipPath: join(LIBRARY_CLIPS_DIR, entry.url),+ // Staged manifest urls are library-root-relative (R2 layout,+ // `clips/<name>.json`); the staged files themselves sit flat in the+ // stage dir — same resolution mixamo-all.mjs's upload phase uses.+ clipPath: join(LIBRARY_CLIPS_DIR, `${entry.name}.json`),outPath: join(LIBRARY_OUT, `${entry.name}.webp`),});}@@ -169,4 +172,7 @@ function loadJobs() {await browser.close();if (server) server.kill();}+ // The spawned dev server's stdio pipes would otherwise keep the event loop+ // alive after the work is done.+ process.exit(process.exitCode ?? 0);})();diff --git a/src/animation-categories.js b/src/animation-categories.jsnew file mode 100644index 000000000..47130a1cb--- /dev/null+++ b/src/animation-categories.js@@ -0,0 +1,115 @@+// Category classifier for the full motion library.+//+// The Mixamo catalog ships no category metadata (every product's `category` is+// an empty string), so the /animations gallery derives one from the clip label.+// Rules are ordered — the first match wins — because labels routinely span+// several concepts ("Zombie Walk" is a zombie clip, not locomotion; "Rifle Run"+// is a weapons clip). Curated studio clips keep their hand-assigned category+// from animation-presets.js; this module is the fallback for everything else.+//+// Used by src/animations-gallery.js (filter chips) and covered by+// tests/animation-categories.test.js.++import { categoryOf as curatedCategoryOf } from './animation-presets.js';++/** Ordered gallery categories. `key` is stable (URL state); label/icon are UI. */+export const GALLERY_CATEGORIES = [+ { key: 'idle', label: 'Idle', icon: '🧍' },+ { key: 'locomotion', label: 'Locomotion', icon: '🚶' },+ { key: 'dance', label: 'Dance', icon: '💃' },+ { key: 'combat', label: 'Combat', icon: '🥊' },+ { key: 'weapons', label: 'Weapons', icon: '🏹' },+ { key: 'sport', label: 'Sports', icon: '⚽' },+ { key: 'acrobatics', label: 'Acrobatics', icon: '🤸' },+ { key: 'gesture', label: 'Gestures', icon: '👋' },+ { key: 'reaction', label: 'Reactions', icon: '😲' },+ { key: 'death', label: 'Deaths & Falls', icon: '💀' },+ { key: 'sit', label: 'Sit & Lie', icon: '🪑' },+ { key: 'fitness', label: 'Fitness', icon: '🏋️' },+ { key: 'interaction', label: 'Interaction', icon: '📦' },+ { key: 'creature', label: 'Creature', icon: '🧟' },+ { key: 'farming', label: 'Farming', icon: '🌱' },+ { key: 'more', label: 'More', icon: '✨' },+];++// Curated studio keys that differ from gallery keys.+const CURATED_KEY_MAP = { action: 'combat' };++// First match wins. Keep creature/weapons/dance ahead of movement words so+// "Zombie Run", "Pistol Walk", "Swing Dancing" land where a human would file them.+const RULES = [+ ['creature', /\bzombie|mutant|goblin|orc|monster|creature|werewolf|vampire\b/],+ [+ 'weapons',+ /\brifle|pistol|gun(?!ner)|shoot|firing|reload|sword|katana|saber|blade|bow(?:\s|$)|arrow|archer|shield|axe|spear|knife|dagger|grenade|toss grenade|machine ?gun|shotgun|sniper|crossbow|great ?sword|mace|staff|halberd|musket|revolver|holster|unsheathe|sheathe?\b/,+ ],+ [+ 'dance',+ /\bdanc|breakdance|hip ?hop|salsa|samba|rumba|swing|twist(?!ing torso)|shuffl|twerk|ballet|bboy|b-boy|robot(?:ic)? dance|macarena|charleston|cabbage patch|gangnam|moonwalk|locking|popping|krump|house dance|tut(?:ting)?|wave dance|belly ?dance|flair|footwork|thriller|disco|cancan|can-can\b/,+ ],+ [+ 'sport',+ /\bsoccer|football|goalkeeper|goalie|basketball|baseball|golf|tennis|volleyball|bowling|boxing bag|dribbl|free throw|penalty|header|batting|pitch(?:ing)?\b|catcher|quarterback|touchdown|swim|ski(?:ing)?\b|skat(?:e|ing)|surf|climb(?:ing)? (?:rope|ladder|wall)|baseball/,+ ],+ [+ 'acrobatics',+ /\bflip|cartwheel|handstand|somersault|gymnast|aerial|backflip|front ?flip|tumbl|vault|parkour|freerun|breakfall|roll(?:ing)? (?:forward|backward|left|right)|kip[- ]?up|braced hang|hang(?:ing)? (?:from|drop)\b/,+ ],+ [+ 'death',+ /\bdeath|dying|die[sd]?\b|falling(?! to roll)|fall(?:s)? (?:over|down|back|flat)|knocked (?:out|down)|collaps|defeat|shot (?:to|in) |flying back|face ?plant|drop dead|ko\b|unconscious\b/,+ ],+ [+ 'combat',+ /\bpunch|kick|jab|hook(?:ing)?\b|uppercut|boxing|mma|martial|karate|kung ?fu|taekwondo|muay ?thai|fight|attack|combo|block(?:ing)?\b|dodge|parry|counter|elbow|knee strike|headbutt|brawl|melee|spar(?:ring)?|cross punch|roundhouse|haymaker|takedown|chokehold|wrestl|capoeira|body blow|leg sweep|spell|casting|magic\b/,+ ],+ [+ 'reaction',+ /\breaction|react(?:ing|s)?\b|hit (?:to|by|from)|receiving|getting (?:hit|clipped|shoved|pushed)|shoved|stagger|stumbl|stunned|dazed|shocked|surprised|scared|terrified|flinch|dodg(?:e|ing) reaction|pain|hurt|electrocut|sneez|shiver|drunk\b/,+ ],+ [+ 'sit',+ /\bsit(?:ting|s)?\b|laying|lying|lie (?:down|on)|sleep|nap\b|crouch(?:ed|ing)? idle|kneel|stand(?:ing)? (?:up )?from (?:ground|chair|sit)|chair\b|seated|couch|floor idle\b/,+ ],+ [+ 'fitness',+ /\byoga|plank|push ?up|sit ?up|pull ?up|squat|burpee|jumping jacks|exercis|workout|stretch|warm ?up|lunge|crunch|air squat|treadmill|downward dog|downdog\b/,+ ],+ [+ 'farming',+ /\bfarm|dig(?:ging)?\b|plant(?:ing)?\b|water(?:ing)? (?:can|plant)|harvest|milk(?:ing)?\b|hoe\b|rake|shovel|sow(?:ing)?\b|fishing\b/,+ ],+ [+ 'gesture',+ /\bwav(?:e|ing)|clap|point(?:ing)?\b|thumbs|salute|bow(?:ing)\b|greet|hello|goodbye|talk(?:ing)?|yell(?:ing)?|shout|argu|agree|disagree|nod|shak(?:e|ing) head|counting|whatever|shrug|taunt|cheer|celebrat|excited|happy|joy|angry|frustrat|sad\b|cry(?:ing)?|laugh|facepalm|pray(?:ing)?|kiss|blow(?:ing)? kiss|look(?:ing)? (?:around|behind|down|up|over)|listening|smoking|call(?:ing)? ?(?:me|out)?\b|whistl|hand ?signal|beckon|clapping|golf clap|air guitar|conduct(?:ing|or)|gestur|asking|shaking hands|handshake|roar|fist on table|acknowledg\b/,+ ],+ [+ 'idle',+ /\bidle|waiting|breath(?:ing)?|stand(?:ing)?(?: (?:w|around|by|pose|relaxed))?$|bored|impatient|lean(?:ing)?\b|chilling|relax|thinking|pondering|bashful|nervous(?:ly)?|weight shift|arms? (?:down|raised|behind|resting|slightly|spread|supporting|crossed)|pose\b/,+ ],+ [+ 'interaction',+ /\bcarry|lift(?:ing)?|pick(?:ing)? ?up|put(?:ting)? ?down|push(?:ing)?\b|pull(?:ing)?\b|open(?:ing)?\b|clos(?:e|ing)\b|door|button|lever|drink|eat(?:ing)?|phone|type|typing|keyboard|search(?:ing)?|inspect|grab(?:bing)?|throw(?:ing)?|toss(?:ing)?|catch(?:ing)?\b|hold(?:ing)?\b|torch|box(?:es)?\b|object|crate|drag(?:ging)?|hand ?off|give|take|steal|pay(?:ing)?|swipe|cpr|carried|carrying|picked up|placed|hostage|dice\b/,+ ],+ [+ 'locomotion',+ /\bwalk|run(?:ning|s)?\b|jog|sprint|strafe|sneak|crawl|crouch|turn(?:ing)?\b|step(?:ping)?\b|jump|hop(?:ping)?\b|leap|skip(?:ping)?\b|climb|ladder|stairs?\b|swimming|treading|dive|vault|slide|start (?:walking|running)|stop (?:walking|running)|pivot|u-turn|backpedal|march|patrol|wander|limp|injured walk|balanc(?:e|ing)|tip ?toe|zigzag|circle\b|left|right|forward|backward/,+ ],+];++/**+ * Classify a clip into a gallery category key.+ *+ * @param {string} name manifest clip name (e.g. "av-boxer-dance", "mx-…")+ * @param {string} label human label (e.g. "135 Degree Left Turn")+ * @returns {string} a GALLERY_CATEGORIES key+ */+export function galleryCategoryOf(name, label) {+ const curated = curatedCategoryOf(name);+ if (curated && curated !== 'more') return CURATED_KEY_MAP[curated] || curated;+ const text = String(label || name || '').toLowerCase();+ for (const [key, re] of RULES) {+ if (re.test(text)) return key;+ }+ return 'more';+}diff --git a/src/animations-live-preview.js b/src/animations-live-preview.jsnew file mode 100644index 000000000..edc371ca8--- /dev/null+++ b/src/animations-live-preview.js@@ -0,0 +1,361 @@+// Shared live-preview engine for the /animations gallery.+//+// One WebGL renderer + one preview avatar serve every card and the detail+// modal. The canvas is *moved* into whichever container is previewing (hover a+// card, open the modal) and a RAF loop runs only while something is mounted —+// the page never holds more than a single GL context, where the previous+// gallery booted a full embed-viewer iframe (renderer, avatar, clip fetch) per+// hovered card.+//+// Everything heavy (three.js, the retarget engine, the avatar GLB) loads+// lazily on the first preview, so the gallery's initial paint ships no 3D at+// all. Clip JSONs and retargeted clips are cached by name, so re-hovering a+// card replays instantly.++const MODEL_URL = '/avatars/cz.glb';++export class AnimationLivePreview {+ constructor() {+ this._bootPromise = null;+ this._three = null; // three module namespace+ this._renderer = null;+ this._scene = null;+ this._camera = null;+ this._model = null;+ this._mixer = null;+ this._bones = [];+ this._restPose = new Map();+ this._maps = null; // canonical maps captured at bind pose+ this._retargetMod = null;++ this._clipJsonCache = new Map(); // clip name → raw clip JSON promise+ this._boundClipCache = new Map(); // clip name → retargeted AnimationClip++ this._container = null;+ this._action = null;+ this._activeDef = null;+ this._raf = 0;+ this._lastT = 0;+ this._playToken = 0;+ this._paused = false;+ this._onFrame = null; // (timeSec, durationSec) => void — modal scrubber hook+ }++ /** True once the engine has booted (first preview finished loading). */+ get ready() {+ return !!this._model;+ }++ /** Currently previewing def (or null). */+ get active() {+ return this._activeDef;+ }++ async _boot() {+ if (this._bootPromise) return this._bootPromise;+ this._bootPromise = (async () => {+ const [THREE, { GLTFLoader }, { RoomEnvironment }, retarget, { getMeshoptDecoder }] =+ await Promise.all([+ import('three'),+ import('three/addons/loaders/GLTFLoader.js'),+ import('three/addons/environments/RoomEnvironment.js'),+ import('./animation-retarget.js'),+ import('./viewer/internal.js'),+ ]);+ this._three = THREE;+ this._retargetMod = retarget;++ const renderer = new THREE.WebGLRenderer({ antialias: true, alpha: true });+ renderer.setPixelRatio(Math.min(window.devicePixelRatio || 1, 2));+ renderer.shadowMap.enabled = true;+ renderer.shadowMap.type = THREE.PCFSoftShadowMap;+ renderer.toneMapping = THREE.ACESFilmicToneMapping;+ renderer.toneMappingExposure = 1.05;+ renderer.domElement.className = 'alp-canvas';+ renderer.domElement.setAttribute('aria-hidden', 'true');+ this._renderer = renderer;++ const scene = new THREE.Scene();+ const pmrem = new THREE.PMREMGenerator(renderer);+ scene.environment = pmrem.fromScene(new RoomEnvironment(), 0.04).texture;+ this._scene = scene;++ const key = new THREE.DirectionalLight(0xffffff, 1.6);+ key.position.set(2.2, 4.5, 3.2);+ key.castShadow = true;+ key.shadow.mapSize.set(1024, 1024);+ key.shadow.camera.left = -3;+ key.shadow.camera.right = 3;+ key.shadow.camera.top = 3;+ key.shadow.camera.bottom = -3;+ key.shadow.bias = -0.0004;+ scene.add(key);+ scene.add(key.target);+ this._keyLight = key;+ const rim = new THREE.DirectionalLight(0x99bbff, 0.7);+ rim.position.set(-2.5, 2.5, -2.5);+ scene.add(rim);++ const ground = new THREE.Mesh(+ new THREE.PlaneGeometry(40, 40),+ new THREE.ShadowMaterial({ opacity: 0.28 }),+ );+ ground.rotation.x = -Math.PI / 2;+ ground.receiveShadow = true;+ scene.add(ground);++ this._camera = new THREE.PerspectiveCamera(33, 3 / 4, 0.05, 100);++ const loader = new GLTFLoader();+ loader.setMeshoptDecoder(await getMeshoptDecoder());+ const gltf = await loader.loadAsync(MODEL_URL);+ const model = gltf.scene;+ model.traverse((o) => {+ if (o.isMesh || o.isSkinnedMesh) {+ o.castShadow = true;+ o.frustumCulled = false;+ }+ if (o.isBone) this._bones.push(o);+ this._restPose.set(o, {+ p: o.position.clone(),+ q: o.quaternion.clone(),+ s: o.scale.clone(),+ });+ });+ scene.add(model);+ model.updateMatrixWorld(true);+ this._model = model;+ // Same bind-pose capture recipe as AnimationManager.attach(), so previews+ // play exactly what the studio and embeds play.+ this._maps = {+ canonicalToNode: retarget.canonicalNodeMapFromObject(model),+ targetRest: retarget.canonicalRestMapFromObject(model),+ targetWorldRest: retarget.canonicalWorldRestMapFromObject(model),+ hipsParentWorldQuat: retarget.hipsParentWorldQuat(model),+ hipTargetLocalY: retarget.hipRestLocalHeight(model),+ };+ this._mixer = new THREE.AnimationMixer(model);+ })();+ return this._bootPromise;+ }++ async _fetchClipJson(def) {+ if (this._clipJsonCache.has(def.id)) return this._clipJsonCache.get(def.id);+ const promise = (async () => {+ if (def.source === 'community') {+ const res = await fetch(+ `/api/animations/clips/${encodeURIComponent(def.id)}?play=1`,+ { credentials: 'include' },+ );+ if (!res.ok) throw new Error(`HTTP ${res.status}`);+ const data = await res.json();+ if (!data?.clip?.clip) throw new Error('clip payload missing');+ return data.clip.clip;+ }+ // Curated manifest clips carry a site-relative url; library clips carry an+ // absolute CDN url (or none — resolve via the library manifest by name).+ let url = def.url;+ if (!url) throw new Error('clip has no source url');+ const res = await fetch(url);+ if (!res.ok) throw new Error(`HTTP ${res.status}`);+ return res.json();+ })();+ this._clipJsonCache.set(def.id, promise);+ promise.catch(() => this._clipJsonCache.delete(def.id));+ return promise;+ }++ _restoreRestPose() {+ this._mixer.stopAllAction();+ for (const [node, t] of this._restPose) {+ node.position.copy(t.p);+ node.quaternion.copy(t.q);+ node.scale.copy(t.s);+ }+ this._model.updateMatrixWorld(true);+ }++ async _bindClip(def) {+ if (this._boundClipCache.has(def.id)) return this._boundClipCache.get(def.id);+ const json = await this._fetchClipJson(def);+ const r = this._retargetMod;+ this._restoreRestPose();+ const clip = r.parseClipJSON(json, def.id);+ let hipScale = 1;+ const baseline = r.clipHipBaselineY(clip);+ if (this._maps.hipTargetLocalY > 0.05 && baseline > 0.05) {+ hipScale = Math.min(200, Math.max(0.2, this._maps.hipTargetLocalY / baseline));+ }+ const { clip: bound } = r.retargetClip(clip, this._maps.canonicalToNode, {+ ...this._maps,+ hipScale,+ minCoverage: 0.3,+ });+ if (!bound) throw new Error('clip does not fit the preview avatar');+ this._boundClipCache.set(def.id, bound);+ // A page-lifetime cache of every hovered clip would grow unbounded on a+ // 2,000-card grid; keep the most recent ~40.+ if (this._boundClipCache.size > 40) {+ const oldest = this._boundClipCache.keys().next().value;+ if (oldest !== def.id) this._boundClipCache.delete(oldest);+ }+ return bound;+ }++ // Frame the figure's full motion envelope: sample the clip at a few points,+ // union the bone boxes, and lock the camera for the whole loop so walks and+ // flips stay in frame without camera chase.+ _frameCamera(bound) {+ const THREE = this._three;+ const box = new THREE.Box3();+ const v = new THREE.Vector3();+ const probe = this._mixer.clipAction(bound);+ probe.play();+ const samples = [0.05, 0.3, 0.55, 0.8];+ for (const s of samples) {+ this._mixer.setTime(bound.duration * s);+ this._model.updateMatrixWorld(true);+ for (const b of this._bones) box.expandByPoint(b.getWorldPosition(v));+ }+ this._mixer.setTime(0);+ box.expandByVector(new THREE.Vector3(0.24, 0.15, 0.24));+ box.min.y = Math.min(box.min.y, 0);+ const center = box.getCenter(new THREE.Vector3());+ const size = box.getSize(new THREE.Vector3());+ const cam = this._camera;+ const fovV = THREE.MathUtils.degToRad(cam.fov);+ const fovH = 2 * Math.atan(Math.tan(fovV / 2) * cam.aspect);+ const distV = size.y / 2 / Math.tan(fovV / 2);+ const distH = Math.max(size.x, size.z) / 2 / Math.tan(fovH / 2);+ const dist = Math.max(distV, distH) * 1.15 + Math.max(size.z, size.x) / 2;+ const azimuth = THREE.MathUtils.degToRad(24);+ const elevation = THREE.MathUtils.degToRad(11);+ cam.position.set(+ center.x + dist * Math.cos(elevation) * Math.sin(azimuth),+ center.y + dist * Math.sin(elevation),+ center.z + dist * Math.cos(elevation) * Math.cos(azimuth),+ );+ cam.lookAt(center);+ this._keyLight.target.position.copy(center);+ this._keyLight.target.updateMatrixWorld();+ }++ _resizeToContainer() {+ if (!this._container || !this._renderer) return;+ const w = this._container.clientWidth || 300;+ const h = this._container.clientHeight || 400;+ this._renderer.setSize(w, h, false);+ this._renderer.domElement.style.width = '100%';+ this._renderer.domElement.style.height = '100%';+ this._camera.aspect = w / h;+ this._camera.updateProjectionMatrix();+ }++ _loop = () => {+ this._raf = requestAnimationFrame(this._loop);+ const now = performance.now();+ const dt = Math.min(0.1, (now - this._lastT) / 1000);+ this._lastT = now;+ if (!this._paused) this._mixer.update(dt);+ if (this._onFrame && this._action) {+ this._onFrame(this._action.time, this._action.getClip().duration);+ }+ this._renderer.render(this._scene, this._camera);+ };++ /**+ * Mount the shared canvas into `container` and play `def`'s clip.+ * Any previous preview stops. Resolves once playing; rejects on load or+ * retarget failure (the caller shows its fallback).+ *+ * @param {HTMLElement} container+ * @param {{id:string, source:string, url?:string, loop?:boolean}} def+ * @param {{ speed?: number, onFrame?: (t:number,d:number)=>void }} [opts]+ */+ async play(container, def, opts = {}) {+ const token = ++this._playToken;+ await this._boot();+ const bound = await this._bindClip(def);+ if (token !== this._playToken) return; // superseded while loading++ this.stop({ keepBoot: true });+ this._container = container;+ container.appendChild(this._renderer.domElement);+ this._resizeToContainer();++ this._restoreRestPose();+ const action = this._mixer.clipAction(bound);+ const THREE = this._three;+ if (def.loop === false) {+ action.setLoop(THREE.LoopOnce, 0);+ action.clampWhenFinished = true;+ // One-shots replay on a beat so a hovering user sees the motion again.+ this._mixer.removeEventListener?.('finished', this._replay);+ this._replay = () => {+ action.reset().play();+ };+ this._mixer.addEventListener('finished', this._replay);+ } else {+ action.setLoop(THREE.LoopRepeat, Infinity);+ }+ action.timeScale = opts.speed ?? 1;+ action.play();+ this._action = action;+ this._activeDef = def;+ this._paused = false;+ this._onFrame = opts.onFrame || null;+ this._frameCamera(bound);+ this._lastT = performance.now();+ cancelAnimationFrame(this._raf);+ this._raf = requestAnimationFrame(this._loop);+ }++ /** Detach the canvas and halt rendering. Cheap — the engine stays warm. */+ stop() {+ this._playToken++;+ cancelAnimationFrame(this._raf);+ this._raf = 0;+ if (this._mixer && this._replay) {+ this._mixer.removeEventListener('finished', this._replay);+ this._replay = null;+ }+ if (this._mixer) this._mixer.stopAllAction();+ this._action = null;+ this._activeDef = null;+ this._onFrame = null;+ if (this._renderer?.domElement?.parentNode) {+ this._renderer.domElement.parentNode.removeChild(this._renderer.domElement);+ }+ this._container = null;+ }++ /** Modal transport controls. No-ops when nothing is playing. */+ setPaused(paused) {+ this._paused = !!paused;+ }+ isPaused() {+ return this._paused;+ }+ setSpeed(factor) {+ if (this._action) this._action.timeScale = factor;+ }+ /** Seek to a 0..1 position in the clip. */+ seek(t01) {+ if (!this._action) return;+ const d = this._action.getClip().duration;+ this._action.time = Math.max(0, Math.min(0.999, t01)) * d;+ this._mixer.update(0);+ }+ /** Re-fit renderer + camera after the container was resized (modal open). */+ refit() {+ this._resizeToContainer();+ if (this._action) this._frameCamera(this._action.getClip());+ }+}++/** Page-singleton accessor. */+let _instance = null;+export function getLivePreview() {+ if (!_instance) _instance = new AnimationLivePreview();+ return _instance;+}diff --git a/tests/api/healthz-self-facilitator.test.js b/tests/api/healthz-self-facilitator.test.jsnew file mode 100644index 000000000..b24a718c7--- /dev/null+++ b/tests/api/healthz-self-facilitator.test.js@@ -0,0 +1,67 @@+// /api/healthz — self_facilitator block: aggregates the last 24h of+// x402_self_facilitator_log verify/settle outcomes by reason class so a+// buyer-facing verify-rejection streak (e.g. a wallet mutating the prepared+// transaction) is visible on the public health surface instead of only in+// admin dashboards.++import { describe, it, expect, vi, beforeEach } from 'vitest';++vi.mock('../../api/_lib/zauth.js', () => ({ instrument: () => {}, drain: async () => {} }));+vi.mock('../../api/_lib/sentry.js', () => ({ captureException: () => {} }));++// sql template-tag mock: answer the self-facilitator aggregate with canned+// rows; every other query (siwx probe, monitor heartbeat) fails so those+// blocks take their degraded paths, same as the main healthz suite.+const FAC_ROWS = [+ { action: 'verify', ok: true, reason: '', n: 12 },+ { action: 'verify', ok: false, reason: 'program_not_allowed', n: 3 },+ { action: 'verify', ok: false, reason: 'cu_price_too_high', n: 1 },+ { action: 'settle', ok: true, reason: '', n: 11 },+ { action: 'settle', ok: false, reason: 'broadcast_failed', n: 2 },+];+vi.mock('../../api/_lib/db.js', () => ({+ sql: (strings) => {+ if (strings.join('').includes('x402_self_facilitator_log')) {+ return Promise.resolve(FAC_ROWS);+ }+ throw new Error('no database in test');+ },+ isDbUnavailableError: () => false,+ isDbCapacityError: () => false,+}));++import healthz, { _resetX402Cache } from '../../api/healthz.js';++function makeRes() {+ return {+ statusCode: 200,+ _h: {},+ setHeader(k, v) { this._h[k.toLowerCase()] = v; },+ getHeader(k) { return this._h[k.toLowerCase()]; },+ end(body) { this._body = body; },+ };+}++beforeEach(() => {+ _resetX402Cache();+});++describe('GET /api/healthz — self_facilitator outcomes', () => {+ it('aggregates verify/settle counts and reason classes from the log', async () => {+ const res = makeRes();+ await healthz({ url: '/api/healthz', method: 'GET', headers: {} }, res);+ const body = JSON.parse(res._body);+ expect(body.x402.self_facilitator).toEqual({+ verify: {+ ok: 12,+ rejected: 4,+ reject_reasons: { program_not_allowed: 3, cu_price_too_high: 1 },+ },+ settle: {+ ok: 11,+ failed: 2,+ fail_reasons: { broadcast_failed: 2 },+ },+ });+ });+});diff --git a/tests/plan-checkout-config.test.js b/tests/plan-checkout-config.test.jsnew file mode 100644index 000000000..31c768384--- /dev/null+++ b/tests/plan-checkout-config.test.js@@ -0,0 +1,72 @@+import { describe, it, expect, afterEach } from 'vitest';+import {+ PLANS,+ PLAN_ASSETS,+ planPriceUsd,+ threePlanDiscountBps,+ INTENT_TTL_MINUTES,+ QUOTED_INTENT_TTL_MINUTES,+} from '../api/payments/_config.js';++afterEach(() => {+ delete process.env.THREE_PLAN_DISCOUNT_BPS;+});++describe('PLAN_ASSETS', () => {+ it('accepts USDC, SOL, and THREE', () => {+ expect(PLAN_ASSETS).toEqual(['USDC', 'SOL', 'THREE']);+ });+});++describe('threePlanDiscountBps', () => {+ it('defaults to 20%', () => {+ expect(threePlanDiscountBps()).toBe(2000);+ });++ it('honors the env override', () => {+ process.env.THREE_PLAN_DISCOUNT_BPS = '1500';+ expect(threePlanDiscountBps()).toBe(1500);+ });++ it('allows disabling the discount entirely', () => {+ process.env.THREE_PLAN_DISCOUNT_BPS = '0';+ expect(threePlanDiscountBps()).toBe(0);+ });++ it('falls back to the default on garbage or out-of-range values', () => {+ for (const bad of ['nope', '-100', '9000', '']) {+ process.env.THREE_PLAN_DISCOUNT_BPS = bad;+ expect(threePlanDiscountBps()).toBe(2000);+ }+ });+});++describe('planPriceUsd', () => {+ it('charges the sticker price for USDC and SOL', () => {+ for (const plan of Object.keys(PLANS)) {+ expect(planPriceUsd(plan, 'USDC')).toBe(PLANS[plan].price_usd);+ expect(planPriceUsd(plan, 'SOL')).toBe(PLANS[plan].price_usd);+ expect(planPriceUsd(plan)).toBe(PLANS[plan].price_usd);+ }+ });++ it('applies the $THREE discount, rounded to cents', () => {+ expect(planPriceUsd('pro', 'THREE')).toBe(+ Math.round(PLANS.pro.price_usd * 0.8 * 100) / 100,+ );+ });++ it('never discounts below zero or above the sticker price', () => {+ for (const plan of Object.keys(PLANS)) {+ const three = planPriceUsd(plan, 'THREE');+ expect(three).toBeGreaterThan(0);+ expect(three).toBeLessThanOrEqual(PLANS[plan].price_usd);+ }+ });+});++describe('intent TTLs', () => {+ it('gives live-priced quotes a shorter session than USDC', () => {+ expect(QUOTED_INTENT_TTL_MINUTES).toBeLessThan(INTENT_TTL_MINUTES);+ });+});