demobite 1.9.0 → 1.9.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "demobite",
3
- "version": "1.9.0",
3
+ "version": "1.9.1",
4
4
  "description": "The DemoBites agentic recorder — you prompt, it films a real browser, and DemoBites turns the take into an editable demo bite.",
5
5
  "bin": {
6
6
  "demobite": "launcher/index.mjs"
@@ -86,6 +86,31 @@ if (probe) {
86
86
  process.exit(state === "failed" ? 1 : 0);
87
87
  }
88
88
 
89
+ // NO WALL? (founder 2026-10-14: "open the page and look"; the first listening
90
+ // run waited four minutes on a public site). Give the page a few seconds; if
91
+ // nothing on it asks for a sign-in — no password field, no sign-in path, no
92
+ // bot check — remember the address as open and leave without a word.
93
+ const wallCheck = async () => {
94
+ try {
95
+ return await page.evaluate(() => {
96
+ const pw = document.querySelector('input[type="password"]');
97
+ const path = location.pathname.toLowerCase();
98
+ const loginPath = /sign-?in|log-?in|login|auth\b|sso|signup|register/.test(path);
99
+ const bot = !!document.querySelector('input[name="cf-turnstile-response"], iframe[src*="challenges.cloudflare"], iframe[src*="recaptcha"], iframe[src*="hcaptcha"]');
100
+ return { wall: !!pw || loginPath || bot };
101
+ });
102
+ } catch { return { wall: true }; }
103
+ };
104
+ await page.waitForTimeout(4000);
105
+ const first = await wallCheck();
106
+ if (!first.wall) {
107
+ const origin = new URL(page.url()).origin;
108
+ console.log(`✓ No sign-in needed for ${origin}.`);
109
+ try { const l = readLedger(); l.origins = { ...(l.origins ?? {}), [origin]: new Date().toISOString() }; fs.mkdirSync(path.dirname(ledgerPath), { recursive: true }); fs.writeFileSync(ledgerPath, JSON.stringify(l, null, 2) + "\n"); } catch { /* fine */ }
110
+ await postEvent("signed_in", { origin, none: true });
111
+ await ctx.close();
112
+ process.exit(0);
113
+ }
89
114
  console.log("⏳ Waiting for you — sign in in the Chrome window that just opened. Your hands only; nothing you type is seen.");
90
115
  await postEvent("signin_wait", { url });
91
116
  const started = Date.now();