Holding tank in the Control Room menu (Marty 2026-11-11): shown only to members who can adopt (eligible, or at the cap), badge = people adoptable right now, title says you can adopt up to <tankAdoptCap> at a time, opens More > My line; GET /api/my/tank/summary (cached waiting list, no full list); tank card says the cap; chatbot knows where the tank lives and the 10-at-a-time rule; cr-shell ?v=20261111tank, my.js ?v=20261111tank. qa/btc4hits-bridge 28/28 (incl. browser checks)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
+1
-1
@@ -75,7 +75,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/ads-screen.js?v=20261104lf"></script>
|
||||
<script src="/assets/fuel.js?v=20261025ff"></script>
|
||||
<script src="/assets/engine-room.js?v=20261101t"></script>
|
||||
|
||||
@@ -19,6 +19,7 @@ window.CR = (function () {
|
||||
['reports', 'Reports', '/reports', '<path d="M4 19V9M10 19V5M16 19v-8M22 19H2"/>'],
|
||||
['conversions', 'Conversions', '/conversions', '<circle cx="12" cy="12" r="8"/><circle cx="12" cy="12" r="4"/><circle cx="12" cy="12" r="0.8"/>'], // conversion pixel goals (2026-10-23)
|
||||
['team', 'Team', '/team', '<circle cx="9" cy="8" r="3"/><circle cx="17" cy="9" r="2.5"/><path d="M3 19c0-3 3-5 6-5s6 2 6 5M15 15c3 0 6 1.5 6 4"/>'],
|
||||
['tank', 'Holding tank', '/tools#line', '<path d="M4 9h16l-1.5 10h-13z"/><path d="M7 9V7a5 5 0 0 1 10 0v2"/><path d="M9.5 14h5"/>'], // adopters only (2026-11-11): shown by tankItem()
|
||||
['wallet', 'Wallet', '/wallet', '<rect x="3" y="6" width="18" height="12" rx="2"/><path d="M16 12h3"/>'],
|
||||
['promo', 'Promo tools', '/tools#promo', '<path d="M7 10s5-1 9-5v14c-4-4-9-5-9-5H5a2 2 0 0 1-2-2v0a2 2 0 0 1 2-2h2z"/><path d="M8 15l1 5h2l-1-5"/>'],
|
||||
['training', 'Training', '/tools#training', '<rect x="3" y="5" width="18" height="13" rx="2"/><path d="M10 9l5 2.5-5 2.5z"/>', 1],
|
||||
@@ -30,7 +31,7 @@ window.CR = (function () {
|
||||
];
|
||||
// screens not built yet fall back to the classic dashboard pane so nothing is a dead end
|
||||
const FALLBACK = {}; // the classic /my dashboard is retired (2026-10-08); its leftover panes live at /tools
|
||||
const BUILT = new Set(['forum', 'links', 'sources', 'pages', 'zones', 'ads', 'credits', 'refuel', 'reports', 'conversions', 'team', 'wallet', 'tools', 'promo', 'training', 'pipeline', 'profile', 'help']); // Training, Pipeline and Profile on the rail, not behind More (Marty 2026-10-11); Help = support tickets (2026-10-16)
|
||||
const BUILT = new Set(['tank', 'forum', 'links', 'sources', 'pages', 'zones', 'ads', 'credits', 'refuel', 'reports', 'conversions', 'team', 'wallet', 'tools', 'promo', 'training', 'pipeline', 'profile', 'help']); // Training, Pipeline and Profile on the rail, not behind More (Marty 2026-10-11); Help = support tickets (2026-10-16)
|
||||
let ME = null, toastT;
|
||||
// Deep links (2026-10-25): /credits#refuel, /credits#buy and /ads#engine scroll to their panel once it has loaded (and any
|
||||
// sign-in or sponsor pop-up is closed) and flash it, so a button that says "Refuel" lands ON the Refuel panel.
|
||||
@@ -108,7 +109,7 @@ window.CR = (function () {
|
||||
const act = railActive(o);
|
||||
const app = document.createElement('div'); app.className = 'app'; let railWide = true; try { railWide = localStorage.getItem('cr.rail') !== 'narrow'; } catch (e) {} if (railWide) app.classList.add('wide'); // expanded by default (Marty 2026-10-08), the choice remembered per browser
|
||||
app.innerHTML = '<nav class="rail" aria-label="LinkSpin"><a class="mark" href="/" aria-label="LinkSpin home" title="LinkSpin"></a>'
|
||||
+ NAV.map(([k, label, href, svg, sec]) => '<a ' + (k === 'help' ? 'id="crHelp" ' : '') + (/^https?:/.test(href) ? 'target="_blank" rel="noopener" ' : '') + 'href="' + (BUILT.has(k) ? href : FALLBACK[k]) + '"' + (k === act ? ' class="on' + (sec ? ' rsec' : '') + '" aria-current="page"' : (sec ? ' class="rsec"' : '')) + ' title="' + label + '" aria-label="' + label + '"><svg viewBox="0 0 24 24">' + svg + '</svg><span class="lbl">' + label + '</span></a>').join('')
|
||||
+ NAV.map(([k, label, href, svg, sec]) => '<a ' + (k === 'help' ? 'id="crHelp" ' : k === 'tank' ? 'id="crTank" hidden ' : '') + (/^https?:/.test(href) ? 'target="_blank" rel="noopener" ' : '') + 'href="' + (BUILT.has(k) ? href : FALLBACK[k]) + '"' + (k === act ? ' class="on' + (sec ? ' rsec' : '') + '" aria-current="page"' : (sec ? ' class="rsec"' : '')) + ' title="' + label + '" aria-label="' + label + '"><svg viewBox="0 0 24 24">' + svg + '</svg><span class="lbl">' + label + '</span></a>').join('')
|
||||
+ '<span class="sp"></span><button class="railtog" type="button" id="crRailTog" title="Collapse or expand the menu" aria-label="Collapse or expand the menu"><svg viewBox="0 0 24 24"><path d="M15 6l-6 6 6 6"/></svg><span class="lbl">Collapse</span></button></nav>'
|
||||
+ '<div class="main"><div class="topbar"><div><div class="crumb">' + esc(o.crumb || 'Control room') + '</div><h1>' + esc(o.title || '') + '</h1></div><span class="readout" id="crSub">' + esc(o.sub || '') + '</span><span class="grow"></span><span id="crActions">' + (o.actions || '') + '</span>' + themeSeg('crTheme') + '<button class="who" type="button" id="crUserBtn" title="Account"><i id="crAv"></i><span id="crWho">Sign in</span></button></div>'
|
||||
// pre-launch notice (Marty, 2026-10-17): open to everyone from today, official launch November 15; date-driven since 2026-11-02 so it drops off by itself at midnight Central on launch day
|
||||
@@ -213,11 +214,27 @@ window.CR = (function () {
|
||||
}
|
||||
return m;
|
||||
}
|
||||
// Holding tank on the rail (Marty 2026-11-11): only for members who can adopt (their own qualifying package, payouts on),
|
||||
// a badge with how many can be adopted right now, and the at-one-time cap from the site setting in its title and on the card
|
||||
function badgeCss() {
|
||||
if (!document.getElementById('crHelpCss')) { const st = document.createElement('style'); st.id = 'crHelpCss'; st.textContent = '.rail a .rbadge{position:absolute;top:3px;right:3px;min-width:16px;height:16px;padding:0 4px;border-radius:999px;background:var(--sig);color:#fff;font:700 10px/16px var(--mono);text-align:center;box-sizing:border-box}.rail.wide a .rbadge,.app.wide .rail a .rbadge{right:8px;top:50%;transform:translateY(-50%)}'; document.head.appendChild(st); }
|
||||
}
|
||||
async function tankItem() {
|
||||
const a = $('crTank'); if (!a) return null;
|
||||
let r = null; try { r = await get('/api/my/tank/summary'); } catch (e) { return null; }
|
||||
if (!r || !r.adopter) { a.hidden = true; return r; }
|
||||
a.hidden = false; const cap = Number(r.cap) || 0;
|
||||
const t = 'Holding tank: ' + (r.waiting ? fmt(r.waiting) + ' waiting for a sponsor' : 'nobody waiting right now') + '. You can adopt up to ' + cap + ' people at a time.';
|
||||
a.title = t; a.setAttribute('aria-label', t);
|
||||
badgeCss();
|
||||
let b = a.querySelector('.rbadge'); if (!r.waiting) { if (b) b.remove(); } else { if (!b) { b = document.createElement('b'); b.className = 'rbadge'; a.appendChild(b); } b.textContent = r.waiting > 999 ? '999+' : String(r.waiting); }
|
||||
return r;
|
||||
}
|
||||
// Help badge on the rail: how many of the member's tickets have a reply from Marty they have not opened (helpdesk.js)
|
||||
async function helpBadge() {
|
||||
const a = $('crHelp'); if (!a) return 0;
|
||||
let n = 0; try { n = Number((await get('/api/my/support/unread')).unread) || 0; } catch (e) { return 0; }
|
||||
if (!document.getElementById('crHelpCss')) { const st = document.createElement('style'); st.id = 'crHelpCss'; st.textContent = '.rail a .rbadge{position:absolute;top:3px;right:3px;min-width:16px;height:16px;padding:0 4px;border-radius:999px;background:var(--sig);color:#fff;font:700 10px/16px var(--mono);text-align:center;box-sizing:border-box}.rail.wide a .rbadge,.app.wide .rail a .rbadge{right:8px;top:50%;transform:translateY(-50%)}'; document.head.appendChild(st); }
|
||||
badgeCss();
|
||||
let b = a.querySelector('.rbadge'); if (!n) { if (b) b.remove(); return 0; }
|
||||
if (!b) { b = document.createElement('b'); b.className = 'rbadge'; a.appendChild(b); }
|
||||
b.textContent = n > 9 ? '9+' : String(n); a.title = 'Help: ' + n + ' new repl' + (n === 1 ? 'y' : 'ies'); return n;
|
||||
@@ -253,7 +270,7 @@ window.CR = (function () {
|
||||
const small = () => { box.innerHTML = '<span class="ink2">Remembered who invited you? <a href="#" id="inviteBack">Tell us</a></span>'; $('inviteBack').addEventListener('click', e => { e.preventDefault(); full(); $('inviteWho').focus(); }); };
|
||||
if (ask.dismissed) small(); else full();
|
||||
}
|
||||
async function requireSession(onReady) { let m = await me(); whoPaint(m); themeSync(m); if (m && m.signedIn) { strip(); helpBadge(); m = await ensureUsername(m); await loginAd(); inviteCard(m); return onReady(m); } signInFlow(async r => { whoPaint(r); themeSync(r); strip(); helpBadge(); await loginAd(); me(true).then(inviteCard); onReady(r); }); }
|
||||
async function requireSession(onReady) { let m = await me(); whoPaint(m); themeSync(m); if (m && m.signedIn) { strip(); helpBadge(); tankItem(); m = await ensureUsername(m); await loginAd(); inviteCard(m); return onReady(m); } signInFlow(async r => { whoPaint(r); themeSync(r); strip(); helpBadge(); await loginAd(); me(true).then(inviteCard); onReady(r); }); }
|
||||
// tiles with a sparkline and a delta chip (Instrument scheme, 2026-09-29): series = numbers oldest first
|
||||
function sparkline(series) {
|
||||
const s = (series || []).map(Number); if (s.length < 2 || !s.some(Boolean)) return '';
|
||||
@@ -272,5 +289,5 @@ window.CR = (function () {
|
||||
return '<div class="tile' + (o.hi ? ' hi' : '') + '"><span class="k">' + esc(o.k) + '</span><div class="row"><span class="v">' + o.v + (o.unit ? '<small>' + esc(o.unit) + '</small>' : '') + '</span>' + sparkline(o.series) + '</div>'
|
||||
+ (o.delta ? '<span class="delta' + (o.delta.cls ? ' ' + o.delta.cls : '') + '">' + esc(o.delta.text) + '</span>' : '') + (o.note ? '<span class="muted mono" style="font-size:11px">' + esc(o.note) + '</span>' : '') + '</div>';
|
||||
}
|
||||
return { esc, fmt, api, get, copy, dialog, toast, mount, sub, me, requireSession, signInFlow, tile, sparkline, delta, helpBadge };
|
||||
return { esc, fmt, api, get, copy, dialog, toast, mount, sub, me, requireSession, signInFlow, tile, sparkline, delta, helpBadge, tankItem };
|
||||
})();
|
||||
|
||||
+1
-1
@@ -1277,7 +1277,7 @@
|
||||
const r = await (await fetch('/api/my/tank')).json();
|
||||
if (r.error) { el.innerHTML = ''; return; }
|
||||
$('tankCap').textContent = r.cap; $('tankTtl').textContent = r.ttlDays;
|
||||
$('tankSub').textContent = r.waiting.length ? r.waiting.length + ' waiting' : 'nobody waiting right now';
|
||||
$('tankSub').textContent = (r.waiting.length ? r.waiting.length + ' waiting' : 'nobody waiting right now') + (r.cap ? ' · you can adopt up to ' + r.cap + ' at a time' : '');
|
||||
const why = $('tankWhy'); why.hidden = r.eligible; why.innerHTML = r.eligible ? '' : '<span class="badge amber">not yet</span> ' + esc(r.reason);
|
||||
$('tankMine').innerHTML = r.mine.length ? '<p class="small" style="margin:0 0 6px"><b>Your open adoptions</b></p>' + r.mine.map(m => '<div class="lin-row own"><span class="nm">' + esc(m.name) + '</span>'
|
||||
+ '<span class="em">' + (m.bought ? 'bought' : m.wallet ? 'wallet linked' : 'free, no wallet yet') + ' · last seen ' + ago(m.lastSeen) + '</span>'
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
<div id="goalReports"></div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/conversions.js?v=20261026a"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -83,7 +83,7 @@
|
||||
</div>
|
||||
<script src="/assets/common.js?v=20261107tg"></script>
|
||||
<script src="/assets/wallet.js?v=20261021a"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/credits-screen.js?v=20261107tg"></script>
|
||||
<script src="/assets/fuel.js?v=20261025ff"></script>
|
||||
</body>
|
||||
|
||||
+1
-1
@@ -30,7 +30,7 @@
|
||||
<div id="page">
|
||||
<div class="body" id="helpBody"><div class="panel"><span class="muted">loading</span></div></div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/help-screen.js?v=20261016a"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -270,7 +270,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/links.js?v=20261111big"></script>
|
||||
<script src="/assets/banner-spin.js?v=20261105sz"></script>
|
||||
</body>
|
||||
|
||||
+2
-2
@@ -1016,11 +1016,11 @@
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/common.js?v=20261107tg"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/tools.js?v=20261011a"></script>
|
||||
<script src="/assets/wallet.js?v=20261021a"></script>
|
||||
<script src="/assets/promo.js?v=20261020bs3"></script>
|
||||
<script src="/assets/my.js?v=20261107tg"></script>
|
||||
<script src="/assets/my.js?v=20261111tank"></script>
|
||||
<script src="/assets/chat.js?v=20261016a"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -73,7 +73,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/pages-screen.js?v=20261021t"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -90,7 +90,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/reports.js?v=20261107nc"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -128,7 +128,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/traffic-guide-data.js?v=20261028a"></script>
|
||||
<script src="/assets/sources-screen.js?v=20261028a"></script>
|
||||
</body>
|
||||
|
||||
+1
-1
@@ -38,7 +38,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/team.js?v=20261105fd"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
<div class="rules" id="rules"></div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/traffic-guide-data.js?v=20261028a"></script>
|
||||
<script src="/assets/traffic-guide.js?v=20261029b"></script>
|
||||
</body>
|
||||
|
||||
+1
-1
@@ -36,7 +36,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/wallet-screen.js?v=20261023ov"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+1
-1
@@ -42,7 +42,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script src="/assets/cr-shell.js?v=20261110forum"></script>
|
||||
<script src="/assets/cr-shell.js?v=20261111tank"></script>
|
||||
<script src="/assets/zones-screen.js?v=20261010a"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user