From: Date: Mon, 12 May 2008 23:44:22 +0000 (-0400) Subject: Embeddable elctions now scale based on how many candidates in the election there... X-Git-Url: https://projects.mako.cc/source/selectricity-live/commitdiff_plain/81fbc45191a8c9bc5b23e3a997783af59321ff4f?ds=inline Embeddable elctions now scale based on how many candidates in the election there are. However, the iframe adds a scroolbar if there's more than 5 candidates, and shows whitespace at the bottom when there's less than five. --- diff --git a/app/views/embed/full_vote.rhtml b/app/views/embed/full_vote.rhtml index 170b1f5..69eed9c 100644 --- a/app/views/embed/full_vote.rhtml +++ b/app/views/embed/full_vote.rhtml @@ -2,9 +2,22 @@ <%= link_to '', {:controller => 'front'}, {:target => "_parent"} %>

Vote Now

-
+ +
+ <%@election.candidates.length.times do |count|%> + <% if (count%2)==0%> + + <% else %> + + <% end %> + <%end%>
    + + + <% @voter.vote.rankings.each do |ranking| %>
  • <%= white_list ranking.candidate.name %>
-
+

Submit Vote

Drag and drop to rank the choices.

diff --git a/public/images/bottom_dark.png b/public/images/bottom_dark.png new file mode 100644 index 0000000..94dd72f Binary files /dev/null and b/public/images/bottom_dark.png differ diff --git a/public/images/bottom_light.png b/public/images/bottom_light.png new file mode 100644 index 0000000..4c50e4b Binary files /dev/null and b/public/images/bottom_light.png differ diff --git a/public/stylesheets/embed.css b/public/stylesheets/embed.css index fe0b7f2..90e1a21 100644 --- a/public/stylesheets/embed.css +++ b/public/stylesheets/embed.css @@ -104,8 +104,6 @@ a { #voting-box { width: 330px; - height: 317px; - background: transparent url(/images/embed_voting_bg.png) top left no-repeat; margin: 0px; padding: 0px; overflow: hidden; @@ -113,7 +111,7 @@ a { ul { margin: 0 0 0 40px; - padding: 0 0 0 0; + padding: 0 0 0 0px; list-style: none; } @@ -148,8 +146,8 @@ ul { #voting-bottom { color: #464646; position: absolute; - top: 318px; width: 330px; + height:53px; } #container {