[MediaWiki-commits] [Gerrit] Distingush debit cards with text under logo - change (mediawiki...DonationInterface)

2016-03-08 Thread jenkins-bot (Code Review)
jenkins-bot has submitted this change and it was merged.

Change subject: Distingush debit cards with text under logo
..


Distingush debit cards with text under logo

Not the most beautiful solution, but it translates.

Bug: T124320
Change-Id: I319f41c393bab37982d7baa2704a2ceb9576a6c9
---
M astropay_gateway/astropay.adapter.php
M gateway_common/i18n/interface/en.json
M gateway_common/i18n/interface/es.json
M gateway_common/i18n/interface/qqq.json
M gateway_forms/Mustache.php
D gateway_forms/includes/card-visa-debit.png
M gateway_forms/mustache/forms.css
M gateway_forms/mustache/payment_method.html.mustache
8 files changed, 31 insertions(+), 4 deletions(-)

Approvals:
  AndyRussG: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/astropay_gateway/astropay.adapter.php 
b/astropay_gateway/astropay.adapter.php
index 3584f52..f3f2105 100644
--- a/astropay_gateway/astropay.adapter.php
+++ b/astropay_gateway/astropay.adapter.php
@@ -343,7 +343,8 @@
'countries' => array(
'MX' => true,
),
-   'logo' => 'card-visa-debit.png',
+   'logo' => 'card-visa-lg.png',
+   'sub_text_key' => 'donate_interface-debit',
);
 
// MasterCard debit
@@ -354,6 +355,8 @@
'countries' => array(
'MX' => true,
),
+   'logo' => 'card-mc-lg.png',
+   'sub_text_key' => 'donate_interface-debit',
);
 
// Elo (Brazil-only)
diff --git a/gateway_common/i18n/interface/en.json 
b/gateway_common/i18n/interface/en.json
index 141222e..217ede6 100644
--- a/gateway_common/i18n/interface/en.json
+++ b/gateway_common/i18n/interface/en.json
@@ -307,6 +307,7 @@
"donate_interface-cvv-number": "CVV number",
"donate_interface-verification-number": "Verification number",
"donate_interface-what-is-this": "What is this?",
+   "donate_interface-debit": "debit",
"donate_interface-do-not-include-dashes": "Please do not include 
dashes",
"donate_interface-please-donate-today": "Please donate today",
"donate_interface-donate-now": "Donate now",
diff --git a/gateway_common/i18n/interface/es.json 
b/gateway_common/i18n/interface/es.json
index 4dd87e6..43d68fb 100644
--- a/gateway_common/i18n/interface/es.json
+++ b/gateway_common/i18n/interface/es.json
@@ -315,6 +315,7 @@
"donate_interface-cvv-number": "Número CVV",
"donate_interface-verification-number": "Número de verificación",
"donate_interface-what-is-this": "¿Qué es esto?",
+   "donate_interface-debit": "débito",
"donate_interface-do-not-include-dashes": "No incluyas guiones",
"donate_interface-please-donate-today": "Haz una donación hoy",
"donate_interface-donate-now": "Dona ahora",
diff --git a/gateway_common/i18n/interface/qqq.json 
b/gateway_common/i18n/interface/qqq.json
index 06ca161..85ccd8e 100644
--- a/gateway_common/i18n/interface/qqq.json
+++ b/gateway_common/i18n/interface/qqq.json
@@ -332,6 +332,7 @@
"donate_interface-cvv-number": "Abbreviation of 'Card Verification 
Value' + 'Number' (unabbreviated)",
"donate_interface-verification-number": "Prompt for the card's 
verification number",
"donate_interface-what-is-this": "{{Identical|What is this}}",
+   "donate_interface-debit": "Text to indicate that the choice is a debit 
card as distinct from a credit card. Maximum width is 8em.",
"donate_interface-do-not-include-dashes": "Reminder to exclude dashes 
from entries",
"donate_interface-please-donate-today": "Label for request urging 
donation",
"donate_interface-donate-now": "Label for button to donate",
diff --git a/gateway_forms/Mustache.php b/gateway_forms/Mustache.php
index 7f22936..1ea1f91 100644
--- a/gateway_forms/Mustache.php
+++ b/gateway_forms/Mustache.php
@@ -98,6 +98,9 @@
if ( isset( $submethod['logo'] ) ) {
$submethod['logo'] = 
"{$data['script_path']}/extensions/DonationInterface/gateway_forms/includes/{$submethod['logo']}";
}
+   if ( isset( $submethod['sub_text_key'] ) ) {
+   $submethod['has_sub_text'] = true;
+   }
$data['submethods'][] = $submethod;
}
 
diff --git a/gateway_forms/includes/card-visa-debit.png 
b/gateway_forms/includes/card-visa-debit.png
deleted file mode 100644
index 5480719..000
--- a/gateway_forms/includes/card-visa-debit.png
+++ /dev/null
Binary files differ
diff --git a/gateway_forms/mustache/forms.css b/gateway_forms/mustache/forms.css
index 4d065b9..dc26aa9

[MediaWiki-commits] [Gerrit] Distingush debit cards with text under logo - change (mediawiki...DonationInterface)

2016-03-07 Thread Ejegg (Code Review)
Ejegg has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/275742

Change subject: Distingush debit cards with text under logo
..

Distingush debit cards with text under logo

Not the most beautiful solution, but it translates.

Bug: T124320
Change-Id: I319f41c393bab37982d7baa2704a2ceb9576a6c9
---
M astropay_gateway/astropay.adapter.php
M gateway_common/i18n/interface/en.json
M gateway_common/i18n/interface/es.json
M gateway_common/i18n/interface/qqq.json
M gateway_forms/Mustache.php
D gateway_forms/includes/card-visa-debit.png
M gateway_forms/mustache/forms.css
M gateway_forms/mustache/payment_method.html.mustache
8 files changed, 32 insertions(+), 3 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface 
refs/changes/42/275742/1

diff --git a/astropay_gateway/astropay.adapter.php 
b/astropay_gateway/astropay.adapter.php
index 3584f52..0f5fd62 100644
--- a/astropay_gateway/astropay.adapter.php
+++ b/astropay_gateway/astropay.adapter.php
@@ -343,7 +343,8 @@
'countries' => array(
'MX' => true,
),
-   'logo' => 'card-visa-debit.png',
+   'logo' => 'card-visa-lg.png',
+   'sub_message' => 'donate_interface-debit',
);
 
// MasterCard debit
@@ -354,6 +355,8 @@
'countries' => array(
'MX' => true,
),
+   'logo' => 'card-mc-lg.png',
+   'sub_message' => 'donate_interface-debit',
);
 
// Elo (Brazil-only)
diff --git a/gateway_common/i18n/interface/en.json 
b/gateway_common/i18n/interface/en.json
index 141222e..46409e1 100644
--- a/gateway_common/i18n/interface/en.json
+++ b/gateway_common/i18n/interface/en.json
@@ -307,6 +307,7 @@
"donate_interface-cvv-number": "CVV number",
"donate_interface-verification-number": "Verification number",
"donate_interface-what-is-this": "What is this?",
+   "donate_interface-debit": "(debit)",
"donate_interface-do-not-include-dashes": "Please do not include 
dashes",
"donate_interface-please-donate-today": "Please donate today",
"donate_interface-donate-now": "Donate now",
diff --git a/gateway_common/i18n/interface/es.json 
b/gateway_common/i18n/interface/es.json
index 4dd87e6..86f1927 100644
--- a/gateway_common/i18n/interface/es.json
+++ b/gateway_common/i18n/interface/es.json
@@ -315,6 +315,7 @@
"donate_interface-cvv-number": "Número CVV",
"donate_interface-verification-number": "Número de verificación",
"donate_interface-what-is-this": "¿Qué es esto?",
+   "donate_interface-debit": "(débito)",
"donate_interface-do-not-include-dashes": "No incluyas guiones",
"donate_interface-please-donate-today": "Haz una donación hoy",
"donate_interface-donate-now": "Dona ahora",
diff --git a/gateway_common/i18n/interface/qqq.json 
b/gateway_common/i18n/interface/qqq.json
index 06ca161..088135a 100644
--- a/gateway_common/i18n/interface/qqq.json
+++ b/gateway_common/i18n/interface/qqq.json
@@ -332,6 +332,7 @@
"donate_interface-cvv-number": "Abbreviation of 'Card Verification 
Value' + 'Number' (unabbreviated)",
"donate_interface-verification-number": "Prompt for the card's 
verification number",
"donate_interface-what-is-this": "{{Identical|What is this}}",
+   "donate_interface-debit": "Text to indicate that the choice is a debit 
card as distinct from a credit card, displayed in parentheses",
"donate_interface-do-not-include-dashes": "Reminder to exclude dashes 
from entries",
"donate_interface-please-donate-today": "Label for request urging 
donation",
"donate_interface-donate-now": "Label for button to donate",
diff --git a/gateway_forms/Mustache.php b/gateway_forms/Mustache.php
index 7f22936..8f0a3b3 100644
--- a/gateway_forms/Mustache.php
+++ b/gateway_forms/Mustache.php
@@ -98,6 +98,9 @@
if ( isset( $submethod['logo'] ) ) {
$submethod['logo'] = 
"{$data['script_path']}/extensions/DonationInterface/gateway_forms/includes/{$submethod['logo']}";
}
+   if ( isset( $submethod['sub_message'] ) ) {
+   $submethod['has_subtext'] = true;
+   }
$data['submethods'][] = $submethod;
}
 
diff --git a/gateway_forms/includes/card-visa-debit.png 
b/gateway_forms/includes/card-visa-debit.png
deleted file mode 100644
index 5480719..000
--- a/gateway_forms/includes/card-visa-debit.png
+++ /dev/null
Binary files differ
diff --git a/gateway_forms/mustache/for