diff --git a/site/app.hy b/site/app.hy index 130dd49..c308f4c 100644 --- a/site/app.hy +++ b/site/app.hy @@ -28,6 +28,8 @@ ; view routes (route "/" [] (render-template "index.html")) +(route "/repl" [] (render-template "repl.html")) + (post-route "/hy2py" [] (try (hy-to-py (get request.form "code")) (catch LexException (err "Incomplete Code.")) diff --git a/site/less/layout.less b/site/less/layout.less index 347bfce..9d4b86d 100644 --- a/site/less/layout.less +++ b/site/less/layout.less @@ -1,13 +1,29 @@ -body, html { - height: 100%; - padding: 0px; - margin: 0px; +.reset { + padding: 0px; + margin: 0px; } +body, html { + height: 100%; + background-color: #141414; + color: #DCDCDC; + font-family: monospace; + .reset; +} + +a { + color: #DCDCDC; +} + +h1 { + text-align: center; + .reset; +} .repl { width: 49.9%; height: 90%; + .reset; } #python-repl { @@ -21,6 +37,10 @@ body, html { border-left: 1px solid #DCDCDC; } +#hython-target { + display: none; +} + .clear { clear: both; } @@ -28,7 +48,4 @@ body, html { #build-msgs { border-top: 1px solid #DCDCDC; height: 10%; - background-color: #141414; - color: #DCDCDC; - font-family: monospace; } diff --git a/site/templates/index.html b/site/templates/index.html index 72181bb..c0f6dc9 100644 --- a/site/templates/index.html +++ b/site/templates/index.html @@ -3,41 +3,20 @@ {% block title %}Welcome!{% endblock %} {% block head %} - - - - - {% endblock %} -{% block tail %} - -{% endblock %} - -{% block content %}{#{% autoescape off %}{% code "clojure" %} (print "foo bar") {% endcode %}{% endautoescape %}#} -
+Hy is a special Lisp langage. It compiles into a Python AST, and allows for +some pretty awesome stuff (like writing Flask or Django apps in Lisp). +
++It's got an extremely simple Macro system, which will hopefully become +a bit more advanced as the language develops. +
++Want to try it out? Flip on JavaScript and try out the REPL +
{% endblock %} diff --git a/site/templates/repl.html b/site/templates/repl.html new file mode 100644 index 0000000..72181bb --- /dev/null +++ b/site/templates/repl.html @@ -0,0 +1,43 @@ +{% extends "base.html" %} + +{% block title %}Welcome!{% endblock %} + +{% block head %} + + + + + +{% endblock %} + +{% block tail %} + +{% endblock %} + +{% block content %}{#{% autoescape off %}{% code "clojure" %} (print "foo bar") {% endcode %}{% endautoescape %}#} +