Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

finishing up posters

  • Loading branch information...
commit dc69924dd9126dffbd123df85d2e70f83729478d 2 parents 5db2069 + 39534a0
@danmelton authored
View
15 main.rb
@@ -42,18 +42,9 @@
language = params[:language]
size = params[:size]
translations = YAML.load(open('files/translations.yml'))
- data = {}
- data[:page_1] = {}
- data[:page_1][:vote] = { :value => translations[language]["vote"] }
- data[:page_1][:election_date] = { :value => translations[language]["election_date"] }
- data[:page_1][:polling_place] = { :value => translations[language]["polling_place"]}
- data[:page_1][:polling_place_value1] = { :value => session[:polling_name]}
- data[:page_1][:polling_place_value2] = { :value => session[:polling_address1]}
- data[:page_1][:more_info] = { :value => translations[language]["more_info"] + " rockthevote.org" }
- data[:page_1][:sms] = { :value => translations[language]["sms"] + " 1-800-000-0000" }
pdf = Prawn::Document.generate "poster_#{language}_#{size}.pdf", :template => "public/pdfs/#{size}.pdf" do |pdf|
- pdf.text translations[language]["vote"], size: 150, style: :bold, :text_color => 'FFFFFF', :align => :center
+ pdf.text translations[language]["vote"], size: 120, style: :bold, :text_color => 'FFFFFF', :align => :center
pdf.text translations[language]["election_date"] + ": " + session[:date], size: 25, style: :bold, :text_color => 'FFFFFF', :align => :center
pdf.move_down 10
pdf.text translations[language]["polling_place"], size: 25, style: :bold, :text_color => 'FFFFFF', :align => :center
@@ -61,11 +52,13 @@
pdf.text session[:polling_address1], size: 20, style: :bold, :text_color => 'FFFFFF', :align => :center
pdf.move_down 10
pdf.image open(google_map(session[:polling_coordinates])), :fit => [250, 250], :position => :center
- pdf.move_down 50
+ pdf.move_down 70
pdf.text translations[language]["more_info"] + " rockthevote.org", size: 20, style: :bold, :text_color => 'FFFFFF', :align => :center
pdf.text translations[language]["sms"] + " 1-800-000-0000", size: 20, style: :bold, :text_color => 'FFFFFF', :align => :center
end
+ response.headers['Content-Type'] = "application/pdf"
+ send_file "poster_#{language}_large.pdf"
end
def vip_object(geocoder_object)
View
BIN  poster_english_large.pdf
Binary file not shown
View
91 public/css/Site.css
@@ -2072,19 +2072,19 @@ button {
}
h2.step1 {
- background: url(/images/step1.png) top left no-repeat;
+ background: url(/images/step1.png);
width: 880px;
height: 81px;
}
h2.step2 {
- background: url(/images/step2.png) top left no-repeat;
+ background: url(/images/step2.png);
width: 880px;
height: 81px;
}
h2.step3 {
- background: url(/images/step3.png) top left no-repeat;
+ background: url(/images/step3.png);
width: 880px;
height: 81px;
}
@@ -2103,25 +2103,45 @@ div.formholder {
}
+.css3button {
+ font-family: Arial, Helvetica, sans-serif;
+ font-size: 14px;
+ color: #ffffff;
+ padding: 10px 20px;
+ background: -moz-linear-gradient(
+ top,
+ #f50e0e 0%,
+ #ed0e0e 25%,
+ #661212);
+ background: -webkit-gradient(
+ linear, left top, left bottom,
+ from(#f50e0e),
+ color-stop(0.25, #ed0e0e),
+ to(#661212));
+ border-radius: 30px;
+ -moz-border-radius: 30px;
+ -webkit-border-radius: 30px;
+ border: 0px solid #ffffff;
+ -moz-box-shadow:
+ 0px 3px 11px rgba(000,000,000,0.5),
+ inset 0px 0px 1px rgba(255,000,217,1);
+ -webkit-box-shadow:
+ 0px 3px 11px rgba(000,000,000,0.5),
+ inset 0px 0px 1px rgba(255,000,217,1);
+ text-shadow:
+ 0px -1px 0px rgba(000,000,000,0.2),
+ 0px 1px 0px rgba(255,255,255,0.3);
+}
+
/*
- Posters
+ Posters - Step 3 (Download)
*/
-.module {
- background: #ffffff;
- border: 1px solid #DEE1E5;
- padding: 24px;
- margin-top: 40px;
-}
-.selectLanguages form li ul{
- -moz-column-count: 3;
- -moz-column-gap: 20px;
- -webkit-column-count: 3;
- -webkit-column-gap: 20px;
- column-count: 3;
- column-gap: 20px;
- margin-bottom: 20px;
-}
+h2.step3 {
+ background: url(/images/step3.png) top left no-repeat;
+ width: 880px;
+ height: 89px;
+}
.download h2{
text-indent: -9999em;
}
@@ -2151,36 +2171,3 @@ div.formholder {
margin-left: 20px;
}
-.selectLanguages input[type="submit"]{
- background-color: #386097;
- display: block;
- border: none;
- color: #ffffff;
- text-transform: lowercase;
- -webkit-border-radius: 3px;
- -moz-border-radius: 3px;
- border-radius: 3px;
- margin-top: 20px;
- clear: both;
- padding: 3px 15px 6px 15px;
-}
-.selectLanguages .time{
- width: 45%;
- float: left;
- margin-right: 5%;
-}
-.selectLanguages .time input{
- width: 100%;
-}
-.selectLanguages .clear {
- clear: both;
-}
-
-.selectLanguages legend{
- border-bottom: none;
- font: bold 0.916666666666667em/1.454545454545455em "Helvetica Neue", Helvetica, Arial, sans-serif;
- letter-spacing: 0.2em;
- margin: 0 0 10px;
- padding-top: 30px;
- text-transform: uppercase;
-}
View
BIN  public/pdfs/large.pdf
Binary file not shown
View
2  views/step1.erb
@@ -8,7 +8,7 @@
<form action="step2" method="get" accept-charset="utf-8">
<input type="text" name="address" style="width: 500px;" class="biginputfield" placeholder="Enter Your Address Here" id="address">
- <input type="submit" value="Go!">
+ <input type="submit" class="css3button" value="Go!">
</form>
</div>
Please sign in to comment.
Something went wrong with that request. Please try again.