auto-webmcp 0.3.11 → 0.3.12
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/dist/auto-webmcp.cjs.js +10 -8
- package/dist/auto-webmcp.cjs.js.map +2 -2
- package/dist/auto-webmcp.esm.js +10 -8
- package/dist/auto-webmcp.esm.js.map +2 -2
- package/dist/auto-webmcp.iife.js +1 -1
- package/dist/auto-webmcp.iife.js.map +2 -2
- package/dist/discovery.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/auto-webmcp.cjs.js
CHANGED
|
@@ -1690,21 +1690,23 @@ async function scanOrphanInputs(config) {
|
|
|
1690
1690
|
console.log(`[auto-webmcp] orphan: using disabled submit button as reference: "${submitBtn.textContent?.trim()}"`);
|
|
1691
1691
|
}
|
|
1692
1692
|
if (!submitBtn) {
|
|
1693
|
-
const containerBtns = Array.from(
|
|
1693
|
+
const containerBtns = Array.from(
|
|
1694
|
+
container.querySelectorAll('button, [role="button"]')
|
|
1695
|
+
).filter((b) => {
|
|
1694
1696
|
const r = b.getBoundingClientRect();
|
|
1695
|
-
return r.width > 0 && r.height > 0 && !b.disabled && SUBMIT_TEXT_RE.test(b.textContent ?? "");
|
|
1697
|
+
return r.width > 0 && r.height > 0 && !b.disabled && b.getAttribute("aria-disabled") !== "true" && SUBMIT_TEXT_RE.test(b.textContent ?? "");
|
|
1696
1698
|
});
|
|
1697
1699
|
submitBtn = containerBtns[containerBtns.length - 1] ?? null;
|
|
1698
1700
|
if (submitBtn)
|
|
1699
1701
|
console.log(`[auto-webmcp] orphan: using text-matched button in container: "${submitBtn.textContent?.trim()}"`);
|
|
1700
1702
|
}
|
|
1701
1703
|
if (!submitBtn) {
|
|
1702
|
-
const pageBtns = Array.from(
|
|
1703
|
-
(
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
);
|
|
1704
|
+
const pageBtns = Array.from(
|
|
1705
|
+
document.querySelectorAll('button, [role="button"]')
|
|
1706
|
+
).filter((b) => {
|
|
1707
|
+
const r = b.getBoundingClientRect();
|
|
1708
|
+
return r.width > 0 && r.height > 0 && b.getAttribute("aria-disabled") !== "true" && SUBMIT_TEXT_RE.test(b.textContent ?? "");
|
|
1709
|
+
});
|
|
1708
1710
|
submitBtn = pageBtns[pageBtns.length - 1] ?? null;
|
|
1709
1711
|
if (submitBtn)
|
|
1710
1712
|
console.log(`[auto-webmcp] orphan: using page-wide fallback submit button: "${submitBtn.textContent?.trim()}"`);
|