From d18a7da044b8fdb4ded49e05865b3dc743c4fb58 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Wed, 27 Sep 2017 20:07:58 -0400 Subject: Continued working on design, added moves MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Still a very early design Also, for Pokémon that have Natures that don't benefit and hinder the same stat, there is now a + next to the stat that the Nature benefits, and a - next to the stat it hinders. --- app/views/layouts/pokeviewer/application.html.erb | 14 ---- app/views/layouts/pokeviewer/application.html.haml | 15 ++++ app/views/pokeviewer/pokemon/show.html.haml | 95 +++++++++++++++------- 3 files changed, 82 insertions(+), 42 deletions(-) delete mode 100644 app/views/layouts/pokeviewer/application.html.erb create mode 100644 app/views/layouts/pokeviewer/application.html.haml (limited to 'app/views') diff --git a/app/views/layouts/pokeviewer/application.html.erb b/app/views/layouts/pokeviewer/application.html.erb deleted file mode 100644 index 192490c..0000000 --- a/app/views/layouts/pokeviewer/application.html.erb +++ /dev/null @@ -1,14 +0,0 @@ - - - - Pokeviewer - <%= stylesheet_link_tag "pokeviewer/application", media: "all" %> - <%= javascript_include_tag "pokeviewer/application" %> - <%= csrf_meta_tags %> - - - -<%= yield %> - - - diff --git a/app/views/layouts/pokeviewer/application.html.haml b/app/views/layouts/pokeviewer/application.html.haml new file mode 100644 index 0000000..6bce8b9 --- /dev/null +++ b/app/views/layouts/pokeviewer/application.html.haml @@ -0,0 +1,15 @@ +!!! 5 +%html + %head + %title Pokeviewer + = stylesheet_link_tag "pokeviewer/application", media: "all" + = javascript_include_tag "pokeviewer/application" + = csrf_meta_tags + %body + %header#banner Pokéviewer + #container + #left-sidebar + Sidebar stuff + #content= yield + #right-sidebar + Sidebar stuff diff --git a/app/views/pokeviewer/pokemon/show.html.haml b/app/views/pokeviewer/pokemon/show.html.haml index 18a6788..232d6bc 100644 --- a/app/views/pokeviewer/pokemon/show.html.haml +++ b/app/views/pokeviewer/pokemon/show.html.haml @@ -9,31 +9,70 @@ %span{ class: @pokemon.ot_gender }>= @pokemon.ot_name .pokemon-id= "ID/#{@pokemon.display_ot_number}" .pokemon-level= "Lv. #{@pokemon.revisions.last.level}" - .pokemon-memo - .pd-details Trainer Memo - .pd-contents - %p - %span.pokemon-nature<= @pokemon.nature.titlecase - nature. - %p= @pokemon.display_met - .pokemon-stats - .pd-details Stats - %table.pd-contents - %tr - %th HP - %td= @pokemon.revisions.last.hp - %tr - %th Attack - %td= @pokemon.revisions.last.attack - %tr - %th Defense - %td= @pokemon.revisions.last.defense - %tr - %th Sp. Atk - %td= @pokemon.revisions.last.special_attack - %tr - %th Sp. Def - %td= @pokemon.revisions.last.special_defense - %tr - %th Speed - %td= @pokemon.revisions.last.speed + .pokemon-column + .pokemon-stats + .pd-details Stats + %table.pd-contents + %tr + %th HP + %th + Attack + - if @pokemon.nature_benefits?(:attack) + %span.nature-benefit + + - if @pokemon.nature_hinders?(:attack) + %span.nature-hinder - + %th + Defense + - if @pokemon.nature_benefits?(:defense) + %span.nature-benefit + + - if @pokemon.nature_hinders?(:defense) + %span.nature-hinder - + %th + Sp. Atk + - if @pokemon.nature_benefits?(:special_attack) + %span.nature-benefit + + - if @pokemon.nature_hinders?(:special_attack) + %span.nature-hinder - + %th + Sp. Def + - if @pokemon.nature_benefits?(:special_defense) + %span.nature-benefit + + - if @pokemon.nature_hinders?(:special_defense) + %span.nature-hinder - + %th + Speed + - if @pokemon.nature_benefits?(:speed) + %span.nature-benefit + + - if @pokemon.nature_hinders?(:speed) + %span.nature-hinder - + %tr + %td= @pokemon.revisions.last.hp + %td= @pokemon.revisions.last.attack + %td= @pokemon.revisions.last.defense + %td= @pokemon.revisions.last.special_attack + %td= @pokemon.revisions.last.special_defense + %td= @pokemon.revisions.last.speed + .pokemon-row + .pokemon-moves + .pd-details Moves + %ul + %li= @pokemon.revisions.last.move_1.name + - if @pokemon.revisions.last.move_2 + %li= @pokemon.revisions.last.move_2.name + - else + %li - + - if @pokemon.revisions.last.move_3 + %li= @pokemon.revisions.last.move_3.name + - else + %li - + - if @pokemon.revisions.last.move_4 + %li= @pokemon.revisions.last.move_4.name + - else + %li - + .pokemon-memo + .pd-details Trainer Memo + .pd-contents + %p + %span.pokemon-nature<= @pokemon.nature.titlecase + nature. + %p= @pokemon.display_met -- cgit 1.4.1