From 84fc2284063bde9daf306801a54bf7e64bdef21e Mon Sep 17 00:00:00 2001 From: Aqua Date: Thu, 12 Nov 2026 23:41:51 +0000 Subject: [PATCH 1/6] aqua-listen: export shows a read-only textarea with copy, share and one-download-per-tap buttons Android Chrome allows one scripted download per tap and gives no sign when the second is dropped; export was two back-to-back anchor clicks. Answers already autosave to localStorage and survive a reload; the smoke now checks the textarea, clipboard and reload in desktop and mobile-emulated Chromium. Co-Authored-By: Claude Sonnet 5.5 --- tools/aqua-listen/README.md | 4 ++-- tools/aqua-listen/smoke.mjs | 28 +++++++++++++++++++--------- tools/aqua-listen/web/page.js | 30 ++++++++++++++++++++++++------ tools/aqua-listen/web/styles.css | 1 + 4 files changed, 46 insertions(+), 17 deletions(-) diff --git a/tools/aqua-listen/README.md b/tools/aqua-listen/README.md index eb3886e..a3cdc4d 100644 --- a/tools/aqua-listen/README.md +++ b/tools/aqua-listen/README.md @@ -2,7 +2,7 @@ A listening-test kit: a folder of sound clips and a manifest become **one HTML file** you can send to a listener. They open it, listen, say keep / fix / drop for each sound, and send back two small files. -**Status:** the page was driven in headless Chromium (consent gate, autosave across reload, export, zero network requests) and `node test.mjs` covers validation, ordering and the export shape. Nobody has listened with it yet, and the headless browser played nothing audibly; real playback on a phone or other browser is untried. +**Status:** the page was driven in headless Chromium, desktop and a mobile-emulated context (touch, 412 px viewport, Android Chrome user agent; `MOBILE=1 node smoke.mjs`): consent gate, autosave across reload, the export panel with its copy button and read-only textarea, zero network requests. It has not run on a real Android device and `node test.mjs` covers validation, ordering and the export shape. Nobody has listened with it yet, and the headless browser played nothing audibly; real playback on a phone or other browser is untried. ## For the listener (no technical knowledge needed) @@ -16,7 +16,7 @@ A listening-test kit: a folder of sound clips and a manifest become **one HTML f 5. Some sounds come as a pair, **A** and **B**. Rate both, then say which you prefer, or that there is no difference. 6. The sounds are in a random order and their names are hidden on purpose. Please don't hunt for them. 7. Your answers save themselves in your browser as you go. You can close the tab and come back to the same file later. -8. When done, press **Export**. Two files land in your downloads: `verdict.json` and `verdict.md`. Send both to whoever gave you the page. That is the only way anything leaves your computer. +8. When done, press **Export my answers**. Your answers appear in a text box. Press **Copy answers (JSON)** and paste them into a message to whoever gave you the page (or press **Share**, or **Select all** and use your phone's Copy). **Download verdict.json** and **Download verdict.md** are separate buttons, one file per tap, for browsers that allow downloads. Copying or sharing is the only way anything leaves your computer. Privacy: the page has no network access at all (the browser is told to refuse it), no account, no tracking. "Erase my answers" at the bottom wipes what the page saved. diff --git a/tools/aqua-listen/smoke.mjs b/tools/aqua-listen/smoke.mjs index 471eb0c..aa13ba8 100644 --- a/tools/aqua-listen/smoke.mjs +++ b/tools/aqua-listen/smoke.mjs @@ -6,7 +6,12 @@ import { resolve } from "node:path"; const { chromium } = createRequire(import.meta.url)(process.env.PLAYWRIGHT_CORE ?? "playwright-core"); const file = resolve(process.argv[2]); const browser = await chromium.launch({ executablePath: process.env.CHROME || undefined }); -const ctx = await browser.newContext({ acceptDownloads: true }), page = await ctx.newPage(); +// MOBILE=1 drives an Android-Chrome-shaped context (touch, small viewport, mobile UA) with no downloads accepted. +const mobile = !!process.env.MOBILE; +const ctx = await browser.newContext(mobile + ? { acceptDownloads: false, viewport: { width: 412, height: 915 }, hasTouch: true, isMobile: true, deviceScaleFactor: 2.6, permissions: ["clipboard-read", "clipboard-write"], + userAgent: "Mozilla/5.0 (Linux; Android 14; Pixel 8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Mobile Safari/537.36" } + : { acceptDownloads: true, permissions: ["clipboard-read", "clipboard-write"] }), page = await ctx.newPage(); const requests = [], errors = []; page.on("request", (r) => { if (!r.url().startsWith("file:") && !r.url().startsWith("blob:") && !r.url().startsWith("data:")) requests.push(r.url()); }); page.on("pageerror", (e) => errors.push(e.message)); @@ -24,15 +29,20 @@ await first.locator("input[value=fix]").check(); await first.locator("input[type await page.reload(); check(await page.locator("section.card").first().locator("input[value=fix]").isChecked(), "answers survive a reload (localStorage autosave)"); check((await page.locator("section.card").first().locator("input[type=text]").inputValue()) === "a bit thin", "reason survives a reload"); -const got = []; -page.on("download", (d) => got.push(d)); -await page.click("button:has-text('Export')"); -for (let i = 0; i < 50 && got.length < 2; i++) await page.waitForTimeout(100); -const names = got.map((d) => d.suggestedFilename()).sort(); -check(names.join() === "verdict.json,verdict.md", "export downloads verdict.json and verdict.md"); -const v = JSON.parse(readFileSync(await got.find((d) => d.suggestedFilename() === "verdict.json").path(), "utf8")); -check(v.listener === "Tester" && v.device === "headphones" && v.clips[0].verdict === "fix" && v.clips[0].landed === 4 && v.clips[0].device === "headphones", "verdict.json carries the answers"); +await page.click("#export"); +const text = await page.inputValue("#export-text"); +check(await page.locator("#export-text").evaluate((e) => e.readOnly), "export textarea is read-only"); +const v = JSON.parse(text); +check(v.listener === "Tester" && v.device === "headphones" && v.clips[0].verdict === "fix" && v.clips[0].landed === 4 && v.clips[0].device === "headphones", "textarea carries the verdict JSON"); check(v.consent === true && v.clips.length === total, "consent recorded, every clip present"); +await page.click("#copy-json"); +check((await page.evaluate(() => navigator.clipboard.readText())) === text, "Copy button puts the full JSON on the clipboard"); +await page.evaluate(() => { navigator.clipboard.writeText = () => Promise.reject(new Error("denied")); }); +await page.click("#copy-json"); +check(/Copied|blocked/.test(await page.textContent("#export-msg")), "copy falls back to execCommand without throwing"); +await page.reload(); +await page.click("#export"); +check((await page.inputValue("#export-text")).includes('"verdict": "fix"'), "reload loses nothing: export after reload still has the answers"); check(requests.length === 0, `no network requests (${requests.join(", ")})`); check(errors.length === 0, `no page errors (${errors.join("; ")})`); await browser.close(); diff --git a/tools/aqua-listen/web/page.js b/tools/aqua-listen/web/page.js index e232f3a..48eafe3 100644 --- a/tools/aqua-listen/web/page.js +++ b/tools/aqua-listen/web/page.js @@ -29,7 +29,7 @@ h("ul", {}, h("li", {}, "This page works on its own. It talks to no server, has no account and no tracking, and sends nothing anywhere."), h("li", {}, "Your answers are saved in this browser only, so you can close the tab and come back. Clearing your browser data erases them."), - h("li", {}, "Nothing leaves your computer until you press Export, which saves two files. Sending those files to the person who gave you this page is your choice."), + h("li", {}, "Nothing leaves your computer until you press Export, which shows your answers as text to copy, share or save. Sending those files to the person who gave you this page is your choice."), h("li", {}, "You can stay anonymous. A name or nickname is optional.")), h("p", {}, h("label", {}, box, " I understand, and I'm happy to take part.")), h("p", {}, h("label", {}, "Name or nickname (optional) ", h("input", { type: "text", id: "alias", maxlength: "60" }))), @@ -88,20 +88,38 @@ h("div", { class: "bar" }, h("div", { class: "row" }, dev, prog)), ...cards, h("div", { class: "card" }, h("h2", {}, "Finished?"), notes, - h("p", { class: "hint" }, "Export saves verdict.json and verdict.md to your downloads. Unanswered sounds are exported as blank."), - h("div", { class: "row" }, h("button", { onclick: exportAll }, "Export verdict.json + verdict.md"), h("button", { class: "quiet", onclick: reset }, "Erase my answers")))); + h("p", { class: "hint" }, "Export shows your answers as text you can copy, share or download. Unanswered sounds are exported as blank. Your answers stay saved in this browser until you erase them."), + h("div", { class: "row" }, h("button", { id: "export", onclick: exportAll }, "Export my answers"), h("button", { class: "quiet", onclick: reset }, "Erase my answers")), h("div", { id: "export-panel" }))); progress(); } function progress() { const e = document.getElementById("progress"); if (e) e.textContent = `${kit.manifest.clips.filter((c) => answered(c.id)).length} of ${kit.manifest.clips.length} answered`; } + // Export is a visible panel, not a silent download: Android Chrome blocks the second of two scripted downloads and + // gives no sign, so the verdict is also shown in a read-only textarea with copy, share and one-download-per-tap buttons. + function verdictNow() { return L.buildVerdict(kit.manifest, order, state, new Date().toISOString()); } function download(name, text, type) { const a = h("a", { href: URL.createObjectURL(new Blob([text], { type })), download: name }); document.body.append(a); a.click(); a.remove(); } + async function copyText(text, area) { + try { await navigator.clipboard.writeText(text); return true; } catch (e) { /* no clipboard API or not allowed: fall through */ } + try { area.focus(); area.select(); area.setSelectionRange(0, text.length); return document.execCommand("copy"); } catch (e) { return false; } + } function exportAll() { - const v = L.buildVerdict(kit.manifest, order, state, new Date().toISOString()); - download("verdict.json", JSON.stringify(v, null, 2) + "\n", "application/json"); - download("verdict.md", L.verdictMarkdown(v), "text/markdown"); + const v = verdictNow(), json = JSON.stringify(v, null, 2) + "\n", md = L.verdictMarkdown(v); + const area = h("textarea", { id: "export-text", rows: "10", readonly: true, "aria-label": "Your answers as verdict.json" }, json); + const msg = h("p", { class: "hint", id: "export-msg", role: "status" }, "Your answers are below. Copy them and paste them into a message to whoever sent you this page."); + const say = (t) => { msg.textContent = t; }; + const buttons = [ + h("button", { id: "copy-json", onclick: async () => say((await copyText(json, area)) ? "Copied verdict.json. Paste it into your message." : "Copy was blocked. The text box is selected: use your phone's Copy.") }, "Copy answers (JSON)"), + h("button", { class: "quiet", id: "copy-md", onclick: async () => { const t = h("textarea", {}, md); document.body.append(t); const ok = await copyText(md, t); t.remove(); say(ok ? "Copied the readable table." : "Copy was blocked."); } }, "Copy as table"), + h("button", { class: "quiet", onclick: () => { area.focus(); area.select(); area.setSelectionRange(0, json.length); say("Selected. Use your phone's Copy."); } }, "Select all"), + h("button", { class: "quiet", onclick: () => download("verdict.json", json, "application/json") }, "Download verdict.json"), + h("button", { class: "quiet", onclick: () => download("verdict.md", md, "text/markdown") }, "Download verdict.md")]; + if (navigator.share) buttons.splice(2, 0, h("button", { class: "quiet", id: "share", onclick: () => navigator.share({ title: "Listening verdict", text: json }).catch(() => say("Sharing was cancelled or unavailable.")) }, "Share")); + const panel = document.getElementById("export-panel"); + panel.replaceChildren(h("h3", {}, "Your answers"), msg, area, h("div", { class: "row" }, buttons)); + area.focus(); area.select(); panel.scrollIntoView(); } function reset() { if (confirm("Erase every answer you've given in this browser?")) { try { localStorage.removeItem(KEY); } catch (e) {} location.reload(); } } diff --git a/tools/aqua-listen/web/styles.css b/tools/aqua-listen/web/styles.css index 00652d8..929821e 100644 --- a/tools/aqua-listen/web/styles.css +++ b/tools/aqua-listen/web/styles.css @@ -16,3 +16,4 @@ button:disabled { opacity: 0.4; cursor: default; } .bar { position: sticky; top: 0; background: var(--bg); padding: 0.5rem 0; border-bottom: 1px solid var(--line); z-index: 1; } .pair { border: 2px dashed var(--line); border-radius: 10px; padding: 0 0.75rem; margin: 1rem 0; } small, .hint { opacity: 0.75; } +textarea[readonly] { font: 0.8rem/1.3 ui-monospace, monospace; } -- 2.47.3 From 889b018c641c2c7e27f14c91f0972c80277378f1 Mon Sep 17 00:00:00 2001 From: Aqua Date: Thu, 12 Nov 2026 23:44:08 +0000 Subject: [PATCH 2/6] aqua-listen smoke: the copy fallback is tested with the clipboard API removed; README export wording Co-Authored-By: Claude Sonnet 5.5 --- tools/aqua-listen/README.md | 4 ++-- tools/aqua-listen/smoke.mjs | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/tools/aqua-listen/README.md b/tools/aqua-listen/README.md index a3cdc4d..855b828 100644 --- a/tools/aqua-listen/README.md +++ b/tools/aqua-listen/README.md @@ -1,6 +1,6 @@ # aqua-listen -A listening-test kit: a folder of sound clips and a manifest become **one HTML file** you can send to a listener. They open it, listen, say keep / fix / drop for each sound, and send back two small files. +A listening-test kit: a folder of sound clips and a manifest become **one HTML file** you can send to a listener. They open it, listen, say keep / fix / drop for each sound, and send back your answers. **Status:** the page was driven in headless Chromium, desktop and a mobile-emulated context (touch, 412 px viewport, Android Chrome user agent; `MOBILE=1 node smoke.mjs`): consent gate, autosave across reload, the export panel with its copy button and read-only textarea, zero network requests. It has not run on a real Android device and `node test.mjs` covers validation, ordering and the export shape. Nobody has listened with it yet, and the headless browser played nothing audibly; real playback on a phone or other browser is untried. @@ -16,7 +16,7 @@ A listening-test kit: a folder of sound clips and a manifest become **one HTML f 5. Some sounds come as a pair, **A** and **B**. Rate both, then say which you prefer, or that there is no difference. 6. The sounds are in a random order and their names are hidden on purpose. Please don't hunt for them. 7. Your answers save themselves in your browser as you go. You can close the tab and come back to the same file later. -8. When done, press **Export my answers**. Your answers appear in a text box. Press **Copy answers (JSON)** and paste them into a message to whoever gave you the page (or press **Share**, or **Select all** and use your phone's Copy). **Download verdict.json** and **Download verdict.md** are separate buttons, one file per tap, for browsers that allow downloads. Copying or sharing is the only way anything leaves your computer. +8. When done, press **Export my answers**. Your answers appear in a text box. Press **Copy answers (JSON)** and paste them into a message to whoever gave you the page (or press **Share**, or **Select all** and use your phone's Copy). **Download verdict.json** and **Download verdict.md** are separate buttons, one file per tap, for browsers that allow downloads. Nothing leaves your computer except what you copy, share or download. Privacy: the page has no network access at all (the browser is told to refuse it), no account, no tracking. "Erase my answers" at the bottom wipes what the page saved. diff --git a/tools/aqua-listen/smoke.mjs b/tools/aqua-listen/smoke.mjs index aa13ba8..91bd3d0 100644 --- a/tools/aqua-listen/smoke.mjs +++ b/tools/aqua-listen/smoke.mjs @@ -37,9 +37,10 @@ check(v.listener === "Tester" && v.device === "headphones" && v.clips[0].verdict check(v.consent === true && v.clips.length === total, "consent recorded, every clip present"); await page.click("#copy-json"); check((await page.evaluate(() => navigator.clipboard.readText())) === text, "Copy button puts the full JSON on the clipboard"); -await page.evaluate(() => { navigator.clipboard.writeText = () => Promise.reject(new Error("denied")); }); +// http-Android shape: no async clipboard API at all, so only the execCommand path can copy +await page.evaluate(() => { Object.defineProperty(navigator, "clipboard", { value: undefined, configurable: true }); window.__copied = null; document.execCommand = (c) => { window.__copied = document.activeElement.value; return c === "copy"; }; }); await page.click("#copy-json"); -check(/Copied|blocked/.test(await page.textContent("#export-msg")), "copy falls back to execCommand without throwing"); +check((await page.textContent("#export-msg")).startsWith("Copied") && (await page.evaluate(() => window.__copied)) === text, "without the clipboard API, the execCommand fallback copies the full JSON"); await page.reload(); await page.click("#export"); check((await page.inputValue("#export-text")).includes('"verdict": "fix"'), "reload loses nothing: export after reload still has the answers"); -- 2.47.3 From c210dc9d8602fd7df476273321d892984be75fb3 Mon Sep 17 00:00:00 2001 From: Aqua Date: Fri, 13 Nov 2026 11:41:12 +0000 Subject: [PATCH 3/6] aqua-listen: autosave keyed on kit id and clip ids, not the content hash; hash-keyed saves are adopted A rebuilt page changed kit.hash and orphaned the listener's answers. The key is now aqua-listen.v2::; pickLegacySave adopts the fullest earlier hash-keyed save of the same kit that names only this kit's clips. Erase also removes adoptable legacy saves. Browser smoke covers reload, rebuild, migration and erase. Co-Authored-By: Claude Sonnet 5.5 --- tools/aqua-listen/README.md | 4 +-- tools/aqua-listen/logic.cjs | 29 ++++++++++++++++++- tools/aqua-listen/smoke.mjs | 52 +++++++++++++++++++++++++++++++++-- tools/aqua-listen/test.mjs | 30 ++++++++++++++++++++ tools/aqua-listen/web/page.js | 13 +++++++-- 5 files changed, 120 insertions(+), 8 deletions(-) diff --git a/tools/aqua-listen/README.md b/tools/aqua-listen/README.md index 44b9f5a..eceb2b0 100644 --- a/tools/aqua-listen/README.md +++ b/tools/aqua-listen/README.md @@ -42,7 +42,7 @@ node smoke.mjs dist/listen.html # optional - Title, id and group are hidden from the listener and appear only in the export. The intended feel is shown, since "did it land" needs it. - Order is shuffled from a random seed kept with the listener's answers (it is in the export). A pair is shuffled as one unit, with A/B position shuffled inside it. - Audio is embedded as-is (base64), so the page is about 1.4x the clip bytes. The build warns over 100 MB. -- Autosave key is the kit id plus a hash of the manifest and clip bytes: a rebuilt kit with changed clips starts fresh instead of mixing answers. +- Autosave key is the kit id plus the sorted clip ids (`aqua-listen.v2::`), not the content hash: a rebuilt page (edited note, re-rendered clip) keeps the listener's answers, and a kit with a different clip-id set starts fresh while the old entry stays in the browser. Saved state is the shuffle seed, answers by clip id and pair choices by `idA|idB`; a pair's A/B/same value is positional (A is the first of the pair in the seed's order), so it holds only while the manifest's clip order is unchanged. When the new key is empty, the page adopts the fullest earlier `aqua-listen::` save whose answers name only this kit's clips; a save already under the new key is never overwritten. "Erase my answers" removes the new key and any adoptable hash-keyed save. ### Export @@ -52,7 +52,7 @@ The blank verdict files this was meant to match were not found under `/opt/commo ### Browser smoke -`PLAYWRIGHT_CORE=/path/to/playwright-core CHROME=/path/to/chrome node smoke.mjs dist/listen.html` ticks through consent, answers a clip, reloads, exports, and fails on any network request or page error. It is not in `node test.mjs` because the repo carries no browser dependency. +`PLAYWRIGHT_CORE=/path/to/playwright-core CHROME=/path/to/chrome node smoke.mjs dist/listen.html` ticks through consent, answers a clip, reloads, exports, then serves the page over a local http server, rebuilds it with a different content hash and checks that answers survive, that a hash-keyed save is adopted, and that erase leaves nothing to resurrect; it fails on any network request or page error. It is not in `node test.mjs` because the repo carries no browser dependency. ### Kits in the repo diff --git a/tools/aqua-listen/logic.cjs b/tools/aqua-listen/logic.cjs index e7aec25..95440db 100644 --- a/tools/aqua-listen/logic.cjs +++ b/tools/aqua-listen/logic.cjs @@ -100,4 +100,31 @@ function verdictMarkdown(v) { return L.join("\n") + "\n"; } -module.exports = { SCHEMA, VERDICTS, DEVICES, AUDIO_EXT, validateManifest, planOrder, buildVerdict, verdictMarkdown, rng }; +// Autosave. The key names the kit by its id and its clip-id set, not by the content hash: a rebuild that fixes a note or +// re-renders a clip is the same kit and keeps the listener's answers; a different clip-id set is a different kit and starts +// fresh (the old entry is left untouched in the browser). Saved state is answers by clip id and pairs by "idA|idB", plus the +// seed; the A/B/same value of a pair is positional (A is the first of the pair in the seed's order), so it stays meaningful +// only while the manifest's clip order is unchanged. +const SAVE_PREFIX = "aqua-listen.v2:"; +function saveKey(manifest) { return `${SAVE_PREFIX}${manifest.kit.id}:${manifest.clips.map((c) => c.id).sort().join(",")}`; } + +// Earlier pages keyed the save by `aqua-listen::<8-hex content hash>`. Given every localStorage entry as +// [{key, state}] (state already parsed, null if unparseable), returns the key of the legacy entry to adopt, or null: +// same kit id, a seed, and answers/pairs that mention only clip ids of this kit. Fullest entry wins (most answered fields); +// ties go to the later key so the choice is deterministic. +function pickLegacySave(manifest, entries) { + const ids = new Set(manifest.clips.map((c) => c.id)), prefix = `aqua-listen:${manifest.kit.id}:`; + let best = null, bestScore = -1; + for (const { key, state } of entries) { + if (typeof key !== "string" || !key.startsWith(prefix) || !/^[0-9a-f]{8}$/.test(key.slice(prefix.length))) continue; + if (!state || typeof state !== "object" || !state.seed || typeof state.answers !== "object" || !state.answers) continue; + const pairs = state.pairs && typeof state.pairs === "object" ? state.pairs : {}; + if (!Object.keys(state.answers).every((id) => ids.has(id))) continue; + if (!Object.keys(pairs).every((k) => k.split("|").every((id) => ids.has(id)))) continue; + const score = Object.values(state.answers).reduce((n, a) => n + (a ? ["verdict", "landed", "reason"].filter((f) => a[f]).length : 0), 0) + Object.keys(pairs).length; + if (score > bestScore || (score === bestScore && key > best)) { best = key; bestScore = score; } + } + return best; +} + +module.exports = { SCHEMA, VERDICTS, DEVICES, AUDIO_EXT, validateManifest, planOrder, buildVerdict, verdictMarkdown, rng, saveKey, pickLegacySave }; diff --git a/tools/aqua-listen/smoke.mjs b/tools/aqua-listen/smoke.mjs index 91bd3d0..22ffd07 100644 --- a/tools/aqua-listen/smoke.mjs +++ b/tools/aqua-listen/smoke.mjs @@ -1,8 +1,11 @@ // Browser smoke for a built page: node smoke.mjs listen.html (needs playwright-core and a Chromium; set PLAYWRIGHT_CORE=/path/to/playwright-core // and optionally CHROME=/path/to/chrome). Not part of `node test.mjs`: the repo has no browser dependency. import { createRequire } from "node:module"; -import { readFileSync } from "node:fs"; -import { resolve } from "node:path"; +import { readFileSync, writeFileSync, mkdtempSync } from "node:fs"; +import { createServer } from "node:http"; +import { tmpdir } from "node:os"; +import { buildKit } from "./build.mjs"; +import { resolve, join } from "node:path"; const { chromium } = createRequire(import.meta.url)(process.env.PLAYWRIGHT_CORE ?? "playwright-core"); const file = resolve(process.argv[2]); const browser = await chromium.launch({ executablePath: process.env.CHROME || undefined }); @@ -46,4 +49,49 @@ await page.click("#export"); check((await page.inputValue("#export-text")).includes('"verdict": "fix"'), "reload loses nothing: export after reload still has the answers"); check(requests.length === 0, `no network requests (${requests.join(", ")})`); check(errors.length === 0, `no page errors (${errors.join("; ")})`); +// ---- Autosave persistence across a rebuild. Served over http at one fixed path so the origin (and localStorage) is the same for +// the page as given (A) and a rebuild of the same kit with a different content hash (B: a note edit and one byte appended to a clip). +const html = readFileSync(file, "utf8"), kit = JSON.parse(html.match(/