summaryrefslogtreecommitdiff
path: root/tree/public/assets/js/lib/view
diff options
context:
space:
mode:
Diffstat (limited to 'tree/public/assets/js/lib/view')
-rw-r--r--tree/public/assets/js/lib/view/AboutView.js28
-rw-r--r--tree/public/assets/js/lib/view/HomeView.js59
-rw-r--r--tree/public/assets/js/lib/view/PressView.js28
3 files changed, 115 insertions, 0 deletions
diff --git a/tree/public/assets/js/lib/view/AboutView.js b/tree/public/assets/js/lib/view/AboutView.js
new file mode 100644
index 0000000..c2daf70
--- /dev/null
+++ b/tree/public/assets/js/lib/view/AboutView.js
@@ -0,0 +1,28 @@
+var AboutView = View.extend({
+
+ el: "#about",
+
+ // template: liquid($('#tmpl-about').html()),
+
+ events: {
+ },
+
+ initialize: function(options){
+ options = options || {}
+ var data = this.data = options.data
+ },
+
+ render: function(){
+ if (this.rendered) return
+ this.rendered = true
+ },
+
+ show: function(){
+ document.body.className = "about"
+ this.render(this.data)
+ },
+
+ hide: function(){
+ },
+
+})
diff --git a/tree/public/assets/js/lib/view/HomeView.js b/tree/public/assets/js/lib/view/HomeView.js
new file mode 100644
index 0000000..a235dc5
--- /dev/null
+++ b/tree/public/assets/js/lib/view/HomeView.js
@@ -0,0 +1,59 @@
+var HomeView = View.extend({
+
+ el: "#home",
+
+ // template: liquid($('#tmpl-home').html()),
+
+ events: {
+ },
+
+ initialize: function(options){
+ options = options || {}
+ var data = this.data = options.data
+ },
+
+ render: function(){
+ if (this.rendered) return
+ this.rendered = true
+ },
+
+ show: function(){
+ document.body.className = "home"
+ this.render(this.data)
+ environment.load({
+ module: 'welcome',
+ })
+ corner.animate({
+ to: 'zeroes',
+ tween: 'gradient_diagonal',
+ delay: 1000,
+ duration: 200,
+ }).then({
+ to: corner.ascii.snake,
+ tween: 'ascii',
+ duration: 600,
+ }).then({
+ from: corner.ascii.snake,
+ to: 'zeroes',
+ tween: 'ascii_from',
+ }).then({
+ to: corner.ascii.snake,
+ tween: 'ascii',
+ duration: 600,
+ }).then({
+ from: corner.ascii.snake,
+ to: 'zeroes',
+ tween: 'ascii_from',
+ }).then({
+ to: corner.ascii.letter_v,
+ tween: 'ascii',
+ })
+ },
+
+ hide: function(){
+ },
+
+ corner: function(){
+ },
+
+})
diff --git a/tree/public/assets/js/lib/view/PressView.js b/tree/public/assets/js/lib/view/PressView.js
new file mode 100644
index 0000000..2bc574d
--- /dev/null
+++ b/tree/public/assets/js/lib/view/PressView.js
@@ -0,0 +1,28 @@
+var PressView = View.extend({
+
+ el: "#press",
+
+ // template: liquid($('#tmpl-home').html()),
+
+ events: {
+ },
+
+ initialize: function(options){
+ options = options || {}
+ var data = this.data = options.data
+ },
+
+ render: function(){
+ if (this.rendered) return
+ this.rendered = true
+ },
+
+ show: function(){
+ document.body.className = "press"
+ this.render(this.data)
+ },
+
+ hide: function(){
+ },
+
+})