// List every book entry button on the LAWnB 주석서 main page with its sid. // The sid prefix (before "_") identifies the book; the suffix is a TOC node id. // Run (sandbox disabled): ego-browser nodejs < find_books.js const task = await taskSpace("lawnb find books " + Date.now()); const page = task.page("p1"); await page.goto("https://academynext-lawnb-com.libra.cnu.ac.kr/Info/ContentMain/Jusuk", { timeout: 30000 }); await page.waitForTimeout(3000); const rows = await page.evaluate(() => [...document.querySelectorAll('[onclick]')] .filter(e => /showOriginalView/.test(e.getAttribute('onclick'))) .map((e, i) => i + ': ' + e.textContent.trim().replace(/\s+/g, ' ') + ' | ' + (e.getAttribute('onclick').match(/sid=([^']+)/) || [])[1])); console.log(rows.join('\n')); await task.finish({ keep: [] });