Atualiza paywall do Foreign Policy (#7)

master
Rodrigo Orem 2017-02-06 18:34:44 -02:00
parent 715c496e13
commit 974a8990f1
6 changed files with 16 additions and 11 deletions

1
.gitignore vendored
View File

@ -1 +1,2 @@
dist/
.DS_Store

View File

@ -1,9 +1,9 @@
The MIT License (MIT)
Copyright (c) 2016 Rodrigo Orem
Copyright (c) 2016 rodorgas
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@ -1,9 +1,9 @@
The MIT License (MIT)
Copyright (c) 2016 Rodrigo Orem
Copyright (c) 2016 rodorgas
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@ -6,9 +6,12 @@ else if (/www\.economist\.com/.test(document.location.host))
code = 'document.cookie = "ec_limit=allow";';
else if (/foreignpolicy\.com/.test(document.location.host)) {
code = 'window.FPMarketingSettings.__meta.disable_paywall = true;';
code += 'window.Drupal.settings.ec_wallpage.ec_wallpage_paywall_name = ' +
'"article paywall registered"';
code = '\
document.getElementById("paywall_bg").remove();\
document.body.classList.remove("overlay-no-scroll");\
document.body.style.overflow = "visible";\
document.documentElement.classList.remove("overlay-no-scroll");\
';
}
if (code !== null) {

View File

@ -1,10 +1,10 @@
{
"manifest_version": 2,
"name": "burlesco",
"version": "2.8",
"version": "2.9",
"description": "Leia notícias sem ser assinante, burle o paywall",
"homepage_url": "http://burles.co",
"author": "Rodrigo Orem",
"author": "rodorgas",
"icons": {
"128": "icone.png"

View File

@ -1,10 +1,10 @@
{
"manifest_version": 2,
"name": "burlesco",
"version": "2.8",
"version": "2.9",
"description": "Leia notícias sem ser assinante, burle o paywall",
"homepage_url": "http://burles.co",
"author": "Rodrigo Orem",
"author": "rodorgas",
"icons": {
"128": "icone.png"
@ -27,6 +27,7 @@
"permissions": [
"webRequest",
"webRequestBlocking",
"cookies",
"<all_urls>"
],