From 2a0af148c883120d3dab0cd878df9846a4e4bb3e Mon Sep 17 00:00:00 2001 From: Your Name Date: Mon, 30 Mar 2026 08:21:13 -0300 Subject: [PATCH] block --- dasshboard.html | 577 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 577 insertions(+) create mode 100644 dasshboard.html diff --git a/dasshboard.html b/dasshboard.html new file mode 100644 index 0000000..736ea47 --- /dev/null +++ b/dasshboard.html @@ -0,0 +1,577 @@ + + + + +Dashboard + + + + +
+ + + + +``` + +Here's what changed and why: + +**Puppeteer fix — `window.__dashboardReady` flag** +Instead of relying on `networkidle` (which races against the async fetch), Puppeteer should now wait for this flag: +```/dev/null/puppeteer-example.js#L1-4 +await page.goto('file:///.../dasshboard.html'); +await page.waitForFunction(() => window.__dashboardReady === true); +await page.screenshot({ path: 'dashboard.png' }); +``` +The flag is set to `true` at the end of `render()` (and also in the catch block), so Puppeteer only screenshots once the DOM is fully painted — never the loading screen. + +**Latest Signups fix** +The code now tries three key names — `Latest Signups`, `Signups`, `signups` — and handles both an **array** and a **single object** (wraps it in an array). Once your webhook returns the signups as an array under one of those keys, all items will render. Right now the webhook has no array of signups, only `Current Tests` as a single object, so the box will show "No signups" until the correct key is available in the webhook response.