comparison tests/dynClass.ur @ 2012:2b2d07946e65

Fix dynClass for non-<body> contexts
author Adam Chlipala <adam@chlipala.net>
date Sun, 04 May 2014 12:33:44 -0400
parents acadf9d1214a
children
comparison
equal deleted inserted replaced
2011:cfd604842006 2012:2b2d07946e65
13 dynStyle={b <- signal toggle; 13 dynStyle={b <- signal toggle;
14 return (if b then 14 return (if b then
15 STYLE "width: 500px" 15 STYLE "width: 500px"
16 else 16 else
17 STYLE "width: 200px")} 17 STYLE "width: 200px")}
18 onclick={b <- get toggle; set toggle (not b)}/> 18 onclick={fn _ => b <- get toggle; set toggle (not b)}/>
19 19
20 <button dynStyle={b <- signal toggle; 20 <button dynStyle={b <- signal toggle;
21 return (if b then 21 return (if b then
22 STYLE "width: 200px" 22 STYLE "width: 200px"
23 else 23 else