Skip to content

Commit

Permalink
pia call tool added
Browse files Browse the repository at this point in the history
  • Loading branch information
rubbingalcoholic committed Feb 11, 2015
1 parent ba0c574 commit 7af9582
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 3 deletions.
4 changes: 4 additions & 0 deletions _src/js/Modals.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ Modals.prototype.render = function() {

if (location.href.match(/committees=1/))
document.getElementById('call_script').textContent = 'Congress shouldn\'t politicize the issue of Net Neutrality in an attempt to score partisan points on an issue so crucial to the future of the Internet, and our country. Millions of people have called on the FCC to adopt strong rules backed by strong legal authority. Congress should not try to block strong rules by pushing bad legislation, or hauling the FCC into hearings to defend the plan those millions of people called for. Thank you.';
if (location.href.match(/pia=1/)) {
document.getElementById('call_header').textContent = 'We\'ll connect you with Congress. When they answer, say:';
document.getElementById('call_script').textContent = '"Let the FCC do its job and implement net neutrality rules. And do not support the Thune / Upton Proposal, which is just meant to confuse and undermine this process."';
}
};

Modals.prototype.display = function(id) {
Expand Down
8 changes: 7 additions & 1 deletion _src/js/PetitionForm.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,11 @@ PetitionForm.prototype.addEventListeners = function() {
// bindPoliticianEvents(politicians[i]);
// }

if (location.href.match(/call_tool=1/) || location.href.match(/committees=1/)) {
if (
location.href.match(/call_tool=1/)
|| location.href.match(/committees=1/)
|| location.href.match(/pia=1/)
) {
petitionFormNode.style.display = 'none';
// politiciansNode.style.display = 'none';
if (location.href.match(/call_tool=1/))
Expand Down Expand Up @@ -117,6 +121,8 @@ PetitionForm.prototype.addEventListeners = function() {
var campaignId = 'stop-gop-fcc-investigation';
var postalCode = '55419';
}
else if (location.href.match(/pia=1/))
var campaignId = 'title-x-committees-pia';
else
var campaignId = 'jan14th';

Expand Down
12 changes: 11 additions & 1 deletion js/battle.js
Original file line number Diff line number Diff line change
Expand Up @@ -634,6 +634,10 @@ Modals.prototype.render = function() {

if (location.href.match(/committees=1/))
document.getElementById('call_script').textContent = 'Congress shouldn\'t politicize the issue of Net Neutrality in an attempt to score partisan points on an issue so crucial to the future of the Internet, and our country. Millions of people have called on the FCC to adopt strong rules backed by strong legal authority. Congress should not try to block strong rules by pushing bad legislation, or hauling the FCC into hearings to defend the plan those millions of people called for. Thank you.';
if (location.href.match(/pia=1/)) {
document.getElementById('call_header').textContent = 'We\'ll connect you with Congress. When they answer, say:';
document.getElementById('call_script').textContent = '"Let the FCC do its job and implement net neutrality rules. And do not support the Thune / Upton Proposal, which is just meant to confuse and undermine this process."';
}
};

Modals.prototype.display = function(id) {
Expand Down Expand Up @@ -808,7 +812,11 @@ PetitionForm.prototype.addEventListeners = function() {
// bindPoliticianEvents(politicians[i]);
// }

if (location.href.match(/call_tool=1/) || location.href.match(/committees=1/)) {
if (
location.href.match(/call_tool=1/)
|| location.href.match(/committees=1/)
|| location.href.match(/pia=1/)
) {
petitionFormNode.style.display = 'none';
// politiciansNode.style.display = 'none';
if (location.href.match(/call_tool=1/))
Expand Down Expand Up @@ -866,6 +874,8 @@ PetitionForm.prototype.addEventListeners = function() {
var campaignId = 'stop-gop-fcc-investigation';
var postalCode = '55419';
}
else if (location.href.match(/pia=1/))
var campaignId = 'title-x-committees-pia';
else
var campaignId = 'jan14th';

Expand Down
2 changes: 1 addition & 1 deletion templates/Modals.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<div class="modal">
<a class="close" href="#">×</a>
<h1>We are calling you now!</h1>
<h2>
<h2 id="call_header">
We'll connect you with Congress and the FCC. When they
answer, be polite and say:
</h2>
Expand Down

0 comments on commit 7af9582

Please sign in to comment.