diff options
| author | Ben Beltran <ben@nsovocal.com> | 2010-12-01 12:17:32 -0700 |
|---|---|---|
| committer | Ben Beltran <ben@nsovocal.com> | 2010-12-01 12:17:32 -0700 |
| commit | 0e0a67f4f172e61592d259386aa52f0635249f64 (patch) | |
| tree | aa1ced0805e5dd33d315bb7ee1bdc666f23da9fb /views | |
| parent | 5573b3c2672a04d58a91ce1c74f9c543e14fb423 (diff) | |
Muchas cosas.
Sería la primera copia funcional de la aplicación... Falta por supuesto estilizar las páginas individuales.
Diffstat (limited to 'views')
| -rw-r--r-- | views/grito.haml | 13 | ||||
| -rw-r--r-- | views/index.haml | 16 | ||||
| -rw-r--r-- | views/style.css | 44 | ||||
| -rw-r--r-- | views/style.less | 56 |
4 files changed, 117 insertions, 12 deletions
diff --git a/views/grito.haml b/views/grito.haml index a8e5eb5..1a3bbc2 100644 --- a/views/grito.haml +++ b/views/grito.haml @@ -1,8 +1,5 @@ -%h1 The Sorrows of Young Werther -%p - :markdown - A **wonderful serenity** has taken possession of my entire soul, like these sweet mornings of spring which I enjoy with my whole heart. I am alone, and feel the charm of existence in this spot, which was created for the bliss of souls like mine. - - I am so happy, *my dear friend*, so absorbed in the exquisite sense of mere tranquil existence, that I neglect my talents. I should be incapable of drawing a single stroke at the present moment; and yet I feel that I never was a greater artist than now. - - When, while the lovely valley teems with vapour around me, and the meridian sun strikes the upper surface of the impenetrable foliage of my trees, and but a few stray gleams steal into the inner sanctuary, I throw myself down among the tall grass by the trickling stream; and, as I lie close to the earth, a thousand unknown plants are noticed by me: when I hear the buzz of the little world among the stalks, and grow familiar with the countless indescribable forms of the insects and flies, then I feel the presence of the Almighty, who formed us in his own image,
\ No newline at end of file +%h1= @grito.title +%p= @grito.text +%h2 Share +%p= "http://grita.heroku.com/#{@grito.gethash}" +%img#qrcode{:alt=>"Código QR", :src=>"/qr/#{@grito.gethash}.png"}
\ No newline at end of file diff --git a/views/index.haml b/views/index.haml index 742418d..2b40431 100644 --- a/views/index.haml +++ b/views/index.haml @@ -1,8 +1,18 @@ %form{:method => 'post', :action => '/'} + -unless @grito.nil? + -unless @grito.errors.empty? + #errors + -@grito.errors.each do |e| + %span= e + %br + -else + #success + Su texto ha sido guardado! + %a{:href=>"/#{@grito.gethash}"} De click aquí para verlo. %h1 Título - %input{:type => 'text', :name => 'title', :class => 'title'} + %input.title{:type => 'text', :name => 'title'} %br %h1 Texto - %textarea{:name => 'text', :class => 'text', :cols => '100'} + %textarea.text{:name => 'text', :cols => '76', :rows => '20'} %br - %input{:type => 'submit', :value => 'Gritalo!'}
\ No newline at end of file + %input.submit{:type => 'submit', :value => 'Gritalo!'}
\ No newline at end of file diff --git a/views/style.css b/views/style.css index 35f810c..c082c52 100644 --- a/views/style.css +++ b/views/style.css @@ -47,3 +47,47 @@ hr { border: 0; border-bottom: 1px solid #eeeeee; } +#body #qrcode { + display: block; + margin: 10px 250px; +} +#body input.title { + border: 1px solid #eeeeee; + font-size: 1.6em; + padding: 5px; + margin: 0 90px; + width: 770px; +} +#body textarea.text { + border: 1px solid #eeeeee; + font-size: 1.6em; + padding: 5px; + margin: 0 90px; + resize: vertical; +} +#body input.submit { + width: 150px; + font-size: 4.8em; + margin: 10px 410px; + padding: 20px; +} +#body #errors { + -moz-border-radius: 5px; + border-radius: 5px; + -webkit-border-radius: 5px; + padding: 10px; + font-size: 1.4em; + margin: 0 90px; + width: 760px; + background-color: #ffebe8; +} +#body #success { + -moz-border-radius: 5px; + border-radius: 5px; + -webkit-border-radius: 5px; + padding: 10px; + font-size: 1.4em; + margin: 0 90px; + width: 760px; + background-color: #f0fff0; +} diff --git a/views/style.less b/views/style.less index 0963093..6052c10 100644 --- a/views/style.less +++ b/views/style.less @@ -3,6 +3,10 @@ @emphasis_color: #222; @light_color: #999; @border_color: #eee; +@error_color: #ffebe8; +@success_color: #f0fff0; + +@font_stack: "Helvetica Neue", Helvetica, Arial, sans-serif; *{ margin: 0; @@ -14,7 +18,7 @@ body{ background-color: @background_color; text-align: center; font-size: .625em; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-family: @font_stack; } #wrapper{ @@ -62,4 +66,54 @@ hr{ margin: 10px; border: 0; border-bottom: 1px solid @border_color; +} + +#body #qrcode{ + display: block; + margin: 10px 250px; +} + +#body input.title{ + border: 1px solid @border_color; + font-size: 1.6em; + padding: 5px; + margin: 0 90px; + width: 770px; +} + +#body textarea.text{ + border: 1px solid @border_color; + font-size: 1.6em; + padding: 5px; + margin: 0 90px; + resize: vertical; +} + +#body input.submit{ + width: 150px; + font-size: 4.8em; + margin: 10px 410px; + padding: 20px; +} + +#body #errors{ + -moz-border-radius: 5px; + border-radius: 5px; + -webkit-border-radius: 5px; + padding: 10px; + font-size: 1.4em; + margin: 0 90px; + width: 760px; + background-color: @error_color; +} + +#body #success{ + -moz-border-radius: 5px; + border-radius: 5px; + -webkit-border-radius: 5px; + padding: 10px; + font-size: 1.4em; + margin: 0 90px; + width: 760px; + background-color: @success_color; }
\ No newline at end of file |