summaryrefslogtreecommitdiff
path: root/tests/normalizeTable.ur
diff options
context:
space:
mode:
authorGravatar Benjamin Barenblat <bbaren@mit.edu>2016-08-05 20:06:17 -0400
committerGravatar Benjamin Barenblat <bbaren@mit.edu>2016-08-05 20:06:17 -0400
commitc921d0df325c803fed8c7742eb088cb3d030d541 (patch)
tree16d374660aa9adb92c2f08317a20d61ae995ef9a /tests/normalizeTable.ur
parenta3e471e933945dcfb54873cb20c691a193b55671 (diff)
parentbd6f549a527856db3878f1586c6666646a45d8ee (diff)
Merge branch 'upstream' into dfsg_clean20160805+dfsg
Diffstat (limited to 'tests/normalizeTable.ur')
-rw-r--r--tests/normalizeTable.ur50
1 files changed, 50 insertions, 0 deletions
diff --git a/tests/normalizeTable.ur b/tests/normalizeTable.ur
new file mode 100644
index 00000000..be16d935
--- /dev/null
+++ b/tests/normalizeTable.ur
@@ -0,0 +1,50 @@
+fun main () =
+visible <- source True;
+return
+ <xml>
+ <body>
+ <section>
+ <h1>Static table</h1>
+ <table border=1>
+ <thead>
+ <tr>
+ <th>Column 0</th>
+ <th>Column 1</th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr>
+ <td>A</td>
+ <td>B</td>
+ </tr>
+ </tbody>
+ </table>
+ </section>
+
+ <section>
+ <h1>Dynamic table</h1>
+ <table border=1>
+ <thead>
+ <tr>
+ <th>Column 0</th>
+ <th>Column 1</th>
+ </tr>
+ </thead>
+ <tbody>
+ <dyn signal={
+ visible <- signal visible;
+ return (if visible then
+ <xml>
+ <tr>
+ <td>A</td>
+ <td>B</td>
+ </tr>
+ </xml>
+ else
+ <xml></xml>)
+ }/>
+ </tbody>
+ </table>
+ </section>
+ </body>
+ </xml>