summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Benjamin Barenblat <benjamin@barenblat.name>2016-08-02 21:35:09 -0400
committerGravatar Benjamin Barenblat <benjamin@barenblat.name>2016-08-02 21:35:09 -0400
commita5e0977ba856e49384475f9e054054edbc0fabe0 (patch)
treec39014b077b41955a7fa62e1394c6d184b8be097
parenta65627739750834127c58fd0fd701cdc6aea0cbc (diff)
Create basic next action list
-rw-r--r--main.ur35
-rw-r--r--ugtd.urp1
2 files changed, 30 insertions, 6 deletions
diff --git a/main.ur b/main.ur
index 87db169..fa8cf7e 100644
--- a/main.ur
+++ b/main.ur
@@ -14,10 +14,29 @@ specific language governing permissions and limitations under the License. *)
open Mdl
+type nextAction = string
+
+val actionsForTesting =
+ Cons ("Print cover for TPS report",
+ Cons ("Collect information for TPS report",
+ Cons ("Generate charts for TPS report",
+ Cons ("Lorem ipsum dolor sit amet",
+ Nil))))
+
(* Forces JavaScript to be enabled on the given page, so as to pull in external
scripts specified in the .urp file. *)
val forceJavaScript = <xml><script code={return ()} /></xml>
+fun renderNextAction action =
+ <xml>
+ <li class="mdl-list__item">
+ <span class="mdl-list__item-primary-content">
+ {[action]}
+ </span>
+ </li>
+ </xml>
+
+
val main =
setHeader (blessResponseHeader "X-UA-Compatible") "IE=edge";
return <xml>
@@ -41,13 +60,17 @@ val main =
{forceJavaScript}
</head>
<body>
- <div class="mdl-layout__header mdl-layout__header--waterfall mdl-layout__header--waterfall-hide-top">
- <div class="mdl-layout__header-row">
- <span class="mdl-layout-title">Next actions</span>
+ <div class="mdl-layout mdl-js-layout mdl-layout--fixed-header">
+ <div class="mdl-layout__header mdl-layout__header--waterfall mdl-layout__header--waterfall-hide-top">
+ <div class="mdl-layout__header-row">
+ <span class="mdl-layout-title">Next actions</span>
+ </div>
+ </div>
+ <div class="mdl-layout__content">
+ <ul class="mdl-list">
+ {List.mapX renderNextAction actionsForTesting}
+ </ul>
</div>
- </div>
- <div class="mdl-layout__content">
- Hello, world!
</div>
</body>
</xml>
diff --git a/ugtd.urp b/ugtd.urp
index c41a216..32f5e0e 100644
--- a/ugtd.urp
+++ b/ugtd.urp
@@ -8,4 +8,5 @@ library mdl
script https://storage.googleapis.com/code.getmdl.io/1.1.3/material.min.js
rewrite url Main/main
+$/list
main