aboutsummaryrefslogtreecommitdiffstats
path: root/app/index.moon
diff options
context:
space:
mode:
authors-ol <s-ol@users.noreply.github.com>2018-06-30 14:03:41 +0000
committers-ol <s-ol@users.noreply.github.com>2018-06-30 14:03:41 +0000
commitd2fe6d6c82b30e704c2fd87df6d5d37aa8d7ba52 (patch)
tree48fc9c3e68b3f64c20a814afdf6617de9378686b /app/index.moon
parentoptimization for center-of-mass (diff)
downloadmmm-d2fe6d6c82b30e704c2fd87df6d5d37aa8d7ba52.tar.gz
mmm-d2fe6d6c82b30e704c2fd87df6d5d37aa8d7ba52.zip
add realities
Diffstat (limited to 'app/index.moon')
-rw-r--r--app/index.moon14
1 files changed, 12 insertions, 2 deletions
diff --git a/app/index.moon b/app/index.moon
index c05edcd..d566ed1 100644
--- a/app/index.moon
+++ b/app/index.moon
@@ -4,6 +4,13 @@ document = window.document
import h1, p, a, br, ul, tt, li from require './html.moon'
moon = '\xe2\x98\xbd'
+demos =
+ twisted: 'canvas animation',
+ todo: 'Todo demo of a simple reactive UI framework',
+ realities: 'SVG graphics for a paper on VR and realities',
+ 'center-of-mass': 'aligning characters by their centers of mass',
+ 'test-component': 'Test suite for the UI framework',
+
back_button = ->
document.body\appendChild p a { '< back', href: '/' }
@@ -20,6 +27,9 @@ switch window.location.search
when '?test-component' then
back_button!
require './test_component.moon'
+ when '?realities' then
+ back_button!
+ require './realities.moon'
else
document.body\appendChild h1 'mmm'
document.body\appendChild p {
@@ -35,8 +45,8 @@ switch window.location.search
'.'
}
document.body\appendChild p 'current demos:'
- document.body\appendChild ul for name in *{'twisted', 'center-of-mass', 'todo', 'test-component'}
- li a { name, href: "/?#{name}" }
+ document.body\appendChild ul for name, desc in pairs demos
+ li (a name, href: "/?#{name}"), ': ', desc
document.body\appendChild p {
"made with #{moon} by "