HS: disable-scripting security attribute (+1 test)

Add hs-scripting-disabled? helper that walks the ancestor chain checking
for the disable-scripting attribute. Guard hs-activate! with this check.
Add disable-scripting to generator BOOL_ATTRS so the attribute is emitted
in generated test setup code. Regen'd spec.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-05 04:49:39 +00:00
parent 79190e4dac
commit 7190a8b1d2
3 changed files with 20 additions and 6 deletions

View File

@@ -2526,6 +2526,7 @@
(deftest "on a single div"
(hs-cleanup!)
(let ((_el-div (dom-create-element "div")) (_el-d1 (dom-create-element "div")))
(dom-set-attr _el-div "disable-scripting" "")
(dom-set-attr _el-d1 "id" "d1")
(dom-set-attr _el-d1 "_" "on click add .foo")
(dom-append (dom-body) _el-div)