Tinaj1234 has uploaded a new change for review.

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

Change subject: Add Newsletter extension to translatewiki.net
......................................................................

Add Newsletter extension to translatewiki.net

Added prefix, 'newsletter-' to all the i18n keys.

Bug: T102945
Change-Id: I504a29b2de43c19356a3b452f537188da4dda186
---
M Newsletter.hooks.php
M i18n/en.json
M i18n/qqq.json
M includes/SpecialNewsletterCreate.php
M includes/SpecialNewsletterManage.php
M includes/SpecialNewsletters.php
6 files changed, 47 insertions(+), 47 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Newsletter 
refs/changes/56/231756/1

diff --git a/Newsletter.hooks.php b/Newsletter.hooks.php
index 390b6c4..3e97278 100755
--- a/Newsletter.hooks.php
+++ b/Newsletter.hooks.php
@@ -17,13 +17,13 @@
                );
                $notifications['subscribe-newsletter'] = array(
                        'primary-link' => array(
-                               'message' => 'notification-link-text-new-issue',
+                               'message' => 
'newsletter-notification-link-text-new-issue',
                                'destination' => 'new-issue'
                        ),
                        'formatter-class' => 'EchoNewsletterFormatter',
-                       'title-message' => 'notification-newsletter-title',
+                       'title-message' => 'newsletter-notification-title',
                        'title-params' => array( 'newsletter', 'title' ),
-                       'flyout-message' => 'notification-newsletter-flyout',
+                       'flyout-message' => 'newsletter-notification-flyout',
                        'flyout-params' => array( 'newsletter', 'title' ),
 
                );
diff --git a/i18n/en.json b/i18n/en.json
index dda5810..5e1c851 100755
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -7,34 +7,34 @@
        "newsletter-desc": "Adds a preference for users to subscribe to a 
newsletter",
        "newslettercreate": "Create newsletters",
        "newslettermanage": "Manage newsletters",
-       "announceissueform-announceissue-section": "Announce new issue",
-       "announceissueform-addpublisher-section": "Add Publishers",
-       "createnewsletter-section": "Create newsletter",
+       "newsletter-announceissueform-announceissue-section": "Announce new 
issue",
+       "newsletter-announceissueform-addpublisher-section": "Add Publishers",
+       "newsletter-create-section": "Create newsletter",
        "newsletter-create-confirmation": "Good job! You just created a new 
newsletter.",
-       "issue-announce-confirmation": "Good job! You just announced a new 
issue of your newsletter.",
+       "newsletter-issue-announce-confirmation": "Good job! You just announced 
a new issue of your newsletter.",
        "newsletters": "Newsletters",
        "newsletter-subscribe-section": "Subscribe newsletters",
        "newsletter-unsubscribe-section": "Unsubscribe newsletters",
        "newsletter-subscribe-confirmation": "You are now subscribed to the 
newsletter.",
        "newsletter-unsubscribe-confirmation": "You are now unsubscribed from 
the newsletter.",
-       "subscribe-button-label": "Yes",
-       "unsubscribe-button-label": "No",
-       "available-newsletters-field-label": "Available newsletters",
-       "subscribed-newsletters-field-label": "Subscribed newsletters",
+       "newsletter-subscribe-button-label": "Yes",
+       "newsletter-unsubscribe-button-label": "No",
+       "newsletter-available-newsletters-field-label": "Available newsletters",
+       "newsletter-subscribed-newsletters-field-label": "Subscribed 
newsletters",
        "echo-category-title-newsletter": "Newsletters",
        "echo-pref-tooltip-newsletter": "Notify me when any of the newsletters 
to which I have subscribed to announces a new issue.",
-       "notification-newsletter-title": "$1 has announced an issue. In this 
issue: [[:$2]]",
-       "notification-newsletter-flyout": "$1 has announced a new issue. \n\nIn 
this issue: [[:$2]]",
-       "notification-link-text-new-issue": "View new issue",
+       "newsletter-notification-title": "$1 has announced an issue",
+       "newsletter-notification-flyout": "$1 has announced a new issue",
+       "newsletter-notification-link-text-new-issue": "View new issue",
        "newsletter-header-name": "Name of Newsletter",
        "newsletter-header-description": "Description",
        "newsletter-header-action": "Subscribed ?",
        "newsletter-header-subscriber_count": "Subscriber count",
-       "new-publisher-confirmation": "A new publisher has just been added to 
your newsletter !",
-       "newslettermanage-header-name": "Newsletter",
-       "newslettermanage-header-publisher": "Contributors",
-       "newslettermanage-header-permissions": "Permissions",
-       "newslettermanage-header-action": "Action",
-       "owner-radiobutton-label": "Owner",
-       "publisher-radiobutton-label": "Publisher"
+       "newsletter-new-publisher-confirmation": "A new publisher has just been 
added to your newsletter !",
+       "newsletter-manage-header-name": "Newsletter",
+       "newsletter-manage-header-publisher": "Contributors",
+       "newsletter-manage-header-permissions": "Permissions",
+       "newsletter-manage-header-action": "Action",
+       "newsletter-owner-radiobutton-label": "Owner",
+       "newsletter-publisher-radiobutton-label": "Publisher"
 }
diff --git a/i18n/qqq.json b/i18n/qqq.json
index b93a594..b4b8cc7 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -7,33 +7,33 @@
        "newsletter-desc": 
"{{desc|name=Newsletter|url=https://www.mediawiki.org/wiki/Extension:Newsletter}}";,
        "newslettercreate": "Name of special page which creates newsletters as 
seen in URLs and links",
        "newslettermanage": "Name of special page which announces issues as 
seen in URLs and links",
-       "announceissueform-announceissue-section": "Header of section in 
[[Special:NewsletterManage]] which announces issues",
-       "announceissueform-addpublisher-section": "Header of section in 
[[Special:NewsletterManage]] which adds publishers",
-       "createnewsletter-section": "Section header of 
[[Special:NewsletterCreate]]",
+       "newsletter-announceissueform-announceissue-section": "Header of 
section in [[Special:NewsletterManage]] which announces issues",
+       "newsletter-announceissueform-addpublisher-section": "Header of section 
in [[Special:NewsletterManage]] which adds publishers",
+       "newsletter-create-section": "Section header of 
[[Special:NewsletterCreate]]",
        "newsletter-create-confirmation": "Confirmation message displayed after 
creation of a newsletter",
-       "issue-announce-confirmation": "Confirmation message displayed after 
announcing a new issue",
+       "newsletter-issue-announce-confirmation": "Confirmation message 
displayed after announcing a new issue",
        "newsletters": "Name of special page for user to subscribe to or 
unsubscribe from newsletters",
        "newsletter-subscribe-section": "Section header of HTML form in 
[[Special:Newsletters]] which allows users to subscribe.",
        "newsletter-unsubscribe-section": "Section header of HTML form in 
[[Special:Newsletters]] which allows users to un-subscribe.",
        "newsletter-subscribe-confirmation": "Confirmation message displayed 
after subscribing to a newsletter",
        "newsletter-unsubscribe-confirmation": "Confirmation message displayed 
after un-subscribing from a newsletter",
-       "subscribe-button-label": "Label of submit button of HTML form which 
allows users to subscribe.",
-       "unsubscribe-button-label": "Label of submit button of HTML form which 
allows users to un-subscribe.",
-       "available-newsletters-field-label": "Label of HTML form field which 
lists all available newsletters in wiki",
-       "subscribed-newsletters-field-label": "Label of HTML form field which 
lists all newsletters to which user is subscribed to.",
+       "newsletter-subscribe-button-label": "Label of submit button of HTML 
form which allows users to subscribe.",
+       "newsletter-unsubscribe-button-label": "Label of submit button of HTML 
form which allows users to un-subscribe.",
+       "newsletter-available-newsletters-field-label": "Label of HTML form 
field which lists all available newsletters in wiki",
+       "newsletter-subscribed-newsletters-field-label": "Label of HTML form 
field which lists all newsletters to which user is subscribed to.",
        "echo-category-title-newsletter": "Title of the notification category 
used by Newsletter extension.\n{{Related|Echo-category-title}}",
        "echo-pref-tooltip-newsletter": "Short description of the newsletter 
notification category.\n{{Related|Echo-pref-tooltip}}",
-       "notification-newsletter-title": "Title message of Echo notification to 
notify a user of a new issue from a newsletter he/she has subscribed to. 
Parameters:\n* $1 is is the name of the newsletter \n* $2 is a link to the main 
page of the issue.",
-       "notification-newsletter-flyout": "Flyout message of Echo notification 
to notify the user of a new issue from a newsletter he/she has subscribed to. 
Parameters:\n* $1 is the name of the newsletter \n* $2 is a link to the main 
page of the issue.",
-       "notification-link-text-new-issue": "Label of the primary link of the 
notification-newsletter-flyout, which on clicking navigates the user to the 
newly announced issue of a newsletter.",
+       "newsletter-notification-newsletter-title": "Title message of Echo 
notification to notify a user of a new issue from a newsletter he/she has 
subscribed to. Parameters:\n* $1 is is the name of the newsletter.",
+       "newsletter-notification-newsletter-flyout": "Flyout message of Echo 
notification to notify the user of a new issue from a newsletter he/she has 
subscribed to. Parameters:\n* $1 is the name of the newsletter.",
+       "newsletter-notification-link-text-new-issue": "Label of the primary 
link of the notification-newsletter-flyout, which on clicking navigates the 
user to the newly announced issue of a newsletter.",
        "newsletter-header-name": "Label of the first column of table in 
[[Special:Newsletters]] which lists the names of newsletters",
        "newsletter-header-description": "Label of the second column of table 
in [[Special:Newsletters]] which displays a description about the newsletter",
        "newsletter-header-subscriber_count": "Label of the third column of 
table in [[Special:Newsletters]] which gives the subscriber count of 
corresponding newsletter",
        "newsletter-header-action": "Label of the fourth column of table in 
[[Special:Newsletters]] which provides radio buttons to subscribe/unsubscribe 
newsletters",
-       "new-publisher-confirmation": "Confirmation message displayed after a 
new publisher is added for a newsletter through the 
[[Special:NewsletterManage]] page",
-       "newslettermanage-header-name": "Label of the first column of table in 
[[Special:NewsletterManage]] which lists the names of newsletters",
-       "newslettermanage-header-publisher": "Label of the second column of 
table in [[Special:NewsletterManage]] which lists the names of all publishers 
of a newsletter",
-       "newslettermanage-header-permissions": "Label of the third column of 
table in [[Special:NewsletterManage]] which lists the roles of a user",
-       "owner-radiobutton-label": "Label of radio button in 'Permissions' 
column in [[Special:NewsletterManage]] which is checked if the user is the 
owner of the newsletter",
-       "publisher-radiobutton-label": "Label of radio button in 'Permissions' 
column in [[Special:NewsletterManage]] which is checked if the user is a 
publisher of the newsletter"
+       "newsletter-new-publisher-confirmation": "Confirmation message 
displayed after a new publisher is added for a newsletter through the 
[[Special:NewsletterManage]] page",
+       "newsletter-manage-header-name": "Label of the first column of table in 
[[Special:NewsletterManage]] which lists the names of newsletters",
+       "newsletter-manage-header-publisher": "Label of the second column of 
table in [[Special:NewsletterManage]] which lists the names of all publishers 
of a newsletter",
+       "newsletter-manage-header-permissions": "Label of the third column of 
table in [[Special:NewsletterManage]] which lists the roles of a user",
+       "newsletter-owner-radiobutton-label": "Label of radio button in 
'Permissions' column in [[Special:NewsletterManage]] which is checked if the 
user is the owner of the newsletter",
+       "newsletter-publisher-radiobutton-label": "Label of radio button in 
'Permissions' column in [[Special:NewsletterManage]] which is checked if the 
user is a publisher of the newsletter"
 }
\ No newline at end of file
diff --git a/includes/SpecialNewsletterCreate.php 
b/includes/SpecialNewsletterCreate.php
index 9ba56ec..fe2d829 100644
--- a/includes/SpecialNewsletterCreate.php
+++ b/includes/SpecialNewsletterCreate.php
@@ -18,7 +18,7 @@
                $createNewsletterForm = new HTMLForm( $createNewsletterArray, 
$this->getContext(), 'createnewsletterform' );
                $createNewsletterForm->setSubmitText( 'Create newsletter' );
                $createNewsletterForm->setSubmitCallback( array( 
'SpecialNewsletterCreate', 'onSubmitNewsletter' ) );
-               $createNewsletterForm->setWrapperLegendMsg( 
'createnewsletter-section' );
+               $createNewsletterForm->setWrapperLegendMsg( 
'newsletter-create-section' );
                # Show HTML forms
                $createNewsletterForm->show();
                $output->returnToMain();
diff --git a/includes/SpecialNewsletterManage.php 
b/includes/SpecialNewsletterManage.php
index e41e43e..4589cf2 100644
--- a/includes/SpecialNewsletterManage.php
+++ b/includes/SpecialNewsletterManage.php
@@ -24,7 +24,7 @@
                $announceIssueArray = $this->getAnnounceFormFields();
 
                # Create HTML forms
-               $announceIssueForm = new HTMLForm( $announceIssueArray, 
$this->getContext(), 'announceissueform' );
+               $announceIssueForm = new HTMLForm( $announceIssueArray, 
$this->getContext(), 'newsletter-announceissueform' );
                $announceIssueForm->setSubmitCallback( array( 
'SpecialNewsletterManage', 'onSubmitIssue' ) );
 
                $table = new NewsletterManageTable();
@@ -162,7 +162,7 @@
                                        'issue_publisher_id' => 
$formData['publisher']
                                );
                                $dbw->insert( 'nl_issues', $rowData, __METHOD__ 
);
-                               
RequestContext::getMain()->getOutput()->addWikiMsg( 
'issue-announce-confirmation' );
+                               
RequestContext::getMain()->getOutput()->addWikiMsg( 
'newsletter-issue-announce-confirmation' );
                                //trigger notifications
                                $res = $dbr->select(
                                        'nl_newsletters',
@@ -205,7 +205,7 @@
                                );
                                try {
                                        $dbww->insert('nl_publishers', 
$rowData, __METHOD__);
-                                       
RequestContext::getMain()->getOutput()->addWikiMsg( 
'new-publisher-confirmation' );
+                                       
RequestContext::getMain()->getOutput()->addWikiMsg( 
'newsletter-new-publisher-confirmation' );
 
                                        return true;
                                } catch ( DBQueryError $e ) {
@@ -230,7 +230,7 @@
                if ( is_null( $header ) ) {
                        $header = array();
                        foreach ( SpecialNewsletterManage::$fields as $key => 
$value ) {
-                               $header[$key]= $this->msg( 
"newslettermanage-header-$value" )->text();
+                               $header[$key]= $this->msg( 
"newsletter-manage-header-$value" )->text();
                        }
                }
 
@@ -301,7 +301,7 @@
                                                        'id' => 
'newslettermanage',
                                                        'checked' => 
self::$newsletterOwners[$this->mCurrentRow->newsletter_id]
                                                                === 
$this->mCurrentRow->publisher_id ? true : false,                                
            )
-                                       ) . $this->msg( 
'owner-radiobutton-label' );
+                                       ) . $this->msg( 
'newsletter-owner-radiobutton-label' );
 
                                        $radioPublisher = HTML::element(
                                                'input',
@@ -311,7 +311,7 @@
                                                        'id' => 
'newslettermanage',
                                                        'checked' => 
self::$newsletterOwners[$this->mCurrentRow->newsletter_id]
                                                                === 
$this->mCurrentRow->publisher_id ? false : true,                                
            )
-                                       ) . $this->msg( 
'publisher-radiobutton-label' );
+                                       ) . $this->msg( 
'newsletter-publisher-radiobutton-label' );
 
                                        return $radioOwner . $radioPublisher;
                        case 'action' :
diff --git a/includes/SpecialNewsletters.php b/includes/SpecialNewsletters.php
index 52ce13c..a98796e 100644
--- a/includes/SpecialNewsletters.php
+++ b/includes/SpecialNewsletters.php
@@ -144,7 +144,7 @@
                                                        'checked' => in_array( 
$this->mCurrentRow->nl_id,
                                                                        
SpecialNewsletters::$subscribedNewsletterId ) ? true : false,
                                                        )
-                                       ).$this->msg( 'subscribe-button-label' 
);
+                                       ).$this->msg( 
'newsletter-subscribe-button-label' );
                                $radioUnSubscribe = Html::element(
                                                        'input',
                                                        array(
@@ -154,7 +154,7 @@
                                                        'checked' => in_array( 
$this->mCurrentRow->nl_id,
                                                                        
SpecialNewsletters::$subscribedNewsletterId ) ? false : true,
                                                        )
-                               ).$this->msg( 'unsubscribe-button-label' );
+                               ).$this->msg( 
'newsletter-unsubscribe-button-label' );
 
                                return $radioSubscribe . $radioUnSubscribe;
                }

-- 
To view, visit https://gerrit.wikimedia.org/r/231756
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I504a29b2de43c19356a3b452f537188da4dda186
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Newsletter
Gerrit-Branch: master
Gerrit-Owner: Tinaj1234 <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to