Browse Source

Add letter index to top of candidates' page. Closes #10

tags/last-sinatra-version
Adrian Short 12 years ago
parent
commit
0d9b08e0d7
2 changed files with 11 additions and 2 deletions
  1. +5
    -1
      public/style.css
  2. +6
    -1
      views/candidates.haml

+ 5
- 1
public/style.css View File

@@ -251,4 +251,8 @@ tr
{
background-color: blue;
color: white;
}
}

.letter_index a {
margin: 0 10px 0 0;
}

+ 6
- 1
views/candidates.haml View File

@@ -1,5 +1,10 @@
%h1= @page_title = "Candidates"

%nav.letter_index
- ("A".."Z").each do |letter|
%a{ :href => "##{letter}" }<
= letter

- @first_letter = ''

%table
@@ -9,7 +14,7 @@
%tr.noborder
%td &nbsp;
%td
%tr.noborder
%tr.noborder{ :name => @first_letter, :id => @first_letter }
%td.strong{ :style => "font-size: 300%;" }= @first_letter.upcase
%td
%tr


Loading…
Cancel
Save