← back to Marketing Command Center
ig-activity: honest banner when Norma delete-host unreachable (e.g. from Kamatera); disable delete buttons there
679a39e219ca35bebb8c9b08c731671e84c07386 · 2026-08-17 07:38:38 -0700 · Steve Abrams
Files touched
M public/panels/ig-activity.htmlM public/panels/ig-activity.js
Diff
commit 679a39e219ca35bebb8c9b08c731671e84c07386
Author: Steve Abrams <steve@designerwallcoverings.com>
Date: Mon Aug 17 07:38:38 2026 -0700
ig-activity: honest banner when Norma delete-host unreachable (e.g. from Kamatera); disable delete buttons there
---
public/panels/ig-activity.html | 2 ++
public/panels/ig-activity.js | 24 ++++++++++++++++++++++--
2 files changed, 24 insertions(+), 2 deletions(-)
diff --git a/public/panels/ig-activity.html b/public/panels/ig-activity.html
index 191e862..01587cc 100644
--- a/public/panels/ig-activity.html
+++ b/public/panels/ig-activity.html
@@ -1,3 +1,5 @@
+<div id="ig-banner"></div>
+
<div class="card">
<div class="row" style="justify-content:space-between;align-items:baseline;gap:12px;flex-wrap:wrap">
<div>
diff --git a/public/panels/ig-activity.js b/public/panels/ig-activity.js
index 1c004f3..8f5d80f 100644
--- a/public/panels/ig-activity.js
+++ b/public/panels/ig-activity.js
@@ -16,7 +16,8 @@ window.MCC_PANELS['ig-activity'] = {
let DATA = [];
let SORT = localStorage.getItem('ig_sort') || 'ts|desc';
let ACCT = localStorage.getItem('ig_acct') || '';
- let target = null; // the post being deleted (modal context)
+ let target = null; // the post being deleted (modal context)
+ let normaUp = true; // is the Norma delete host reachable from this server?
$('#ig-sort').value = SORT;
const den = localStorage.getItem('ig_density') || '4';
@@ -75,6 +76,21 @@ window.MCC_PANELS['ig-activity'] = {
sel.value = ACCT;
}
+ // Delete of any kind proxies to Norma (the Instagram automation host). Norma
+ // is a Mac2-local service, so on hosts that can't reach it (e.g. Kamatera)
+ // delete is unavailable — say so honestly rather than fail per-click.
+ async function checkNorma() {
+ try { const s = await api('/delete-status'); normaUp = !!(s && s.ok); }
+ catch { normaUp = false; }
+ $('#ig-banner').innerHTML = normaUp ? '' :
+ `<div class="card" style="border-color:#e3b7b3;background:#fbf1f0">
+ <b>Delete is unavailable from this server.</b>
+ <span class="muted" style="font-size:12.5px">Deleting an Instagram post runs through Norma
+ (the automation host on Mac2), which this server can’t reach. Posts are shown for reference;
+ run delete from the local command center where Norma is reachable.</span>
+ </div>`;
+ }
+
// ── delete modal ──────────────────────────────────────────────────────────
function openModal(key) {
target = DATA.find(x => (x.permalink || x.media_id) === key);
@@ -86,8 +102,11 @@ window.MCC_PANELS['ig-activity'] = {
`<b>Remove from board</b> hides it here only (Instagram untouched). ` +
`<b>Delete on Instagram</b> is the real, permanent delete — it runs through ` +
`Norma's serialized real-Chrome flow and only fires if live delete is armed on Norma.`;
- $('#ig-modal-status').textContent = '';
+ $('#ig-modal-status').innerHTML = normaUp ? '' :
+ '<span style="color:#b3261e">Norma (delete host) is not reachable from this server — delete is disabled here.</span>';
setBusy(false);
+ $('#ig-remove').disabled = !normaUp;
+ $('#ig-live').disabled = !normaUp;
$('#ig-modal').style.display = 'flex';
}
function closeModal() { $('#ig-modal').style.display = 'none'; target = null; }
@@ -151,6 +170,7 @@ window.MCC_PANELS['ig-activity'] = {
} catch (e) {
$('#ig-grid').innerHTML = `<div class="loading">Failed to load: ${esc(e.message)}</div>`;
}
+ checkNorma();
}
load();
},
← 4fd1cb4 ig-activity: IG Posts panel — show all fleet IG posts + per-
·
back to Marketing Command Center
·
snapshot before restart: preserve in-flight work c2bf2e6 →