@bettercms-ai/astro 0.28.0 → 0.28.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.
|
@@ -311,10 +311,14 @@ const STEPS_CSS = ".bcms-step{border:0;margin:0 0 14px;padding:0;min-width:0}.bc
|
|
|
311
311
|
val = input?.value;
|
|
312
312
|
}
|
|
313
313
|
el.style.display = val === equals ? "" : "none";
|
|
314
|
+
// Disabled, not just hidden: a disabled control posts nothing and native validation
|
|
315
|
+
// skips it, so a hidden required field cannot block the submit or leak its answer.
|
|
316
|
+
el.querySelectorAll("input,select,textarea").forEach((c) => { c.disabled = val !== equals; });
|
|
314
317
|
} catch {}
|
|
315
318
|
});
|
|
316
319
|
};
|
|
317
320
|
form.addEventListener("input", applyConds);
|
|
321
|
+
form.addEventListener("change", applyConds);
|
|
318
322
|
applyConds();
|
|
319
323
|
|
|
320
324
|
form.addEventListener("submit", async (e) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bettercms-ai/astro",
|
|
3
|
-
"version": "0.28.
|
|
3
|
+
"version": "0.28.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "The BetterCMS adapter for Astro — a `bettercms()` integration, a `bettercms:client` virtual module, typed content loaders, draft preview, and native .astro rendering components.",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -61,11 +61,11 @@
|
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
63
|
"@bettercms-ai/image-url": "^0.4.0",
|
|
64
|
-
"@bettercms-ai/next": "^0.27.
|
|
65
|
-
"@bettercms-ai/richtext": "^0.
|
|
64
|
+
"@bettercms-ai/next": "^0.27.1",
|
|
65
|
+
"@bettercms-ai/richtext": "^0.12.0",
|
|
66
66
|
"@bettercms-ai/sdk": "^1.31.0",
|
|
67
67
|
"@bettercms-ai/types": "^1.48.0",
|
|
68
|
-
"@bettercms-ai/ui": "^0.
|
|
68
|
+
"@bettercms-ai/ui": "^0.20.0",
|
|
69
69
|
"libphonenumber-js": "^1.13.13"
|
|
70
70
|
},
|
|
71
71
|
"peerDependencies": {
|