Dashboard: let members see what a nudge actually says before and after sending
A member sent a nudge to #102, then went looking for what had gone out. The only feedback was a small "Delivered to their dashboard" note, so she checked her clipboard - which still held the unrelated "Copy plain-English summary" text describing her OWN position. She reasonably concluded the nudge had sent her position instead of the recipient's. It had not: the message log shows #34 -> #102 carrying #102's own numbers. The feature was right and the feedback was wrong, which is its own kind of bug - a member who cannot verify what they sent will assume the worst. Every nudge now has a Preview button that names the recipient and shows the exact text before sending, and on success the panel shows what was sent and to whom rather than a bare "Delivered". Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
import pkg from 'file:///D:/Projects/MarketingAgent/qa-tester/node_modules/playwright/index.js';
|
||||
const { chromium } = pkg;
|
||||
const b = await chromium.connectOverCDP('http://127.0.0.1:9222');
|
||||
const page = await b.contexts()[0].newPage();
|
||||
await page.setViewportSize({ width: 1340, height: 1000 });
|
||||
await page.goto('https://adrevsplit.com/login.php', { waitUntil:'domcontentloaded', timeout:45000 });
|
||||
await page.waitForTimeout(3000);
|
||||
console.log(JSON.stringify(await page.evaluate(() => {
|
||||
const col = document.querySelector('.col-lg-10, .custom-col-10');
|
||||
const out = { colTop: col ? Math.round(col.getBoundingClientRect().top) : null, children: [] };
|
||||
if (col) for (const c of col.children) {
|
||||
if (c.getBoundingClientRect().height === 0) continue;
|
||||
const r = c.getBoundingClientRect(); const cs = getComputedStyle(c);
|
||||
out.children.push({
|
||||
tag: c.tagName, cls: (c.className||'').toString().slice(0,30),
|
||||
top: Math.round(r.top), h: Math.round(r.height),
|
||||
mt: cs.marginTop, mb: cs.marginBottom,
|
||||
text: (c.innerText||'').replace(/\s+/g,' ').trim().slice(0,40)
|
||||
});
|
||||
}
|
||||
const ul = document.querySelector('.flexy-menu');
|
||||
out.menuTop = ul ? Math.round(ul.getBoundingClientRect().top) : null;
|
||||
const sec = document.querySelector('section.container');
|
||||
out.sectionTop = sec ? Math.round(sec.getBoundingClientRect().top) : null;
|
||||
out.sectionPadTop = sec ? getComputedStyle(sec).paddingTop : null;
|
||||
return out;
|
||||
}, null), null, 1));
|
||||
await b.close();
|
||||
Reference in New Issue
Block a user