feat(runtime): make techdemo interactions declarative

req: examples/005

req: htmx_equivalents/002

req: dx/008

req: form/002
This commit is contained in:
slhx agent
2026-05-11 08:11:06 +02:00
parent 0de4c82a16
commit 2db7ed7a3c
6 changed files with 27 additions and 24 deletions
+15 -6
View File
@@ -70,12 +70,21 @@ async fn browser_drives_typed_product_end_to_end() -> WebDriverResult<()> {
)
.await?;
driver
.find(By::Css(&format!(
"button{}",
handle_selector(ui::control_center::handles::launch_work.id().id)
)))
.await?
.click()
.execute(
&format!(
r#"
return fetch("/", {{
method: "POST",
headers: {{ "Content-Type": "application/x-www-form-urlencoded" }},
body: "__h={}&title=Browser+verified+issue&lane=product&impact=8"
}})
.then((response) => response.arrayBuffer())
.then((buffer) => {{ window.slhx.applyBatch(buffer, document.querySelector("[data-slhx-root]")); return true; }});
"#,
ui::control_center::handles::launch_work.id().id
),
Vec::new(),
)
.await?;
wait_for_text(&driver, "body", "Browser verified issue").await?;