← back to Sublease Agentabrams
tmp-shot-tx.js
17 lines
const { chromium } = require('playwright-core');
(async () => {
const b = await chromium.launch();
const ctx = await b.newContext({ httpCredentials:{username:'admin',password:'DW2024!'}, viewport:{width:1400,height:1000} });
const p = await ctx.newPage();
await p.goto('https://sublease-admin.agentabrams.com/', { waitUntil:'networkidle', timeout:45000 });
await p.waitForTimeout(2500);
await p.evaluate(()=>document.querySelector('#brokers').scrollIntoView());
await p.waitForTimeout(800);
// pick a state to show national coverage
await p.selectOption("#bstate","TX").catch(()=>{});
await p.waitForTimeout(1500);
await p.evaluate(()=>document.querySelector('#brokers').scrollIntoView());
await p.screenshot({ path:'tmp-brokers.png' });
await b.close();
})();