feat(build): type generated event constants

Generate EventName constants for data-slhx-on metadata and exercise them through typed event emission in techdemo.

req: codegen/006
This commit is contained in:
slhx agent
2026-05-26 00:09:07 +02:00
parent 0b6ad64d98
commit 5364135c5e
5 changed files with 45 additions and 6 deletions
+5 -1
View File
@@ -74,6 +74,10 @@ mod tests {
// req: codegen/006
#[test]
fn techdemo_exports_generated_event_constants() {
assert_eq!(ui::issue_lane::events::drop, "drop");
assert_eq!(ui::issue_lane::events::drop.as_str(), "drop");
assert!(matches!(
slhx::event(ui::issue_lane::events::drop, "card-1"),
Effect::Emit { name, payload } if name == "drop" && payload == "card-1"
));
}
}