Gergő Tisza has uploaded a new change for review.

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

Change subject: Finish rename to PageViewInfo
......................................................................

Finish rename to PageViewInfo

Change-Id: Iaf83d2fafd09c8ba4509649d51ca94f1003dd75d
---
M extension.json
M i18n/qqq.json
M includes/PageViewInfo.hooks.php
R resources/ext.pageviewinfo.js
4 files changed, 7 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/PageViewInfo 
refs/changes/14/320314/1

diff --git a/extension.json b/extension.json
index b84b862..11a3ac3 100644
--- a/extension.json
+++ b/extension.json
@@ -1,10 +1,10 @@
 {
-       "name": "WikimediaPageViewInfo",
+       "name": "PageViewInfo",
        "license-name": "GPL-3.0+",
        "author": [
                "Kunal Mehta"
        ],
-       "url": "https://www.mediawiki.org/wiki/Extension:WikimediaPageViewInfo";,
+       "url": "https://www.mediawiki.org/wiki/Extension:PageViewInfo";,
        "descriptionmsg": "pvi-desc",
        "Hooks": {
                "InfoAction": [
@@ -22,7 +22,7 @@
        "ResourceModules": {
                "ext.wmpageviewinfo": {
                        "scripts": [
-                               "ext.wmpageviewinfo.js"
+                               "ext.pageviewinfo.js"
                        ],
                        "messages": [
                                "pvi-close",
diff --git a/i18n/qqq.json b/i18n/qqq.json
index 368d699..85b449e 100644
--- a/i18n/qqq.json
+++ b/i18n/qqq.json
@@ -5,7 +5,7 @@
                        "Liuxinyu970226"
                ]
        },
-       "pvi-desc": 
"{{desc|name=WikimediaPageViewInfo|url=https://www.mediawiki.org/wiki/Extension:WikimediaPageViewInfo}}";,
+       "pvi-desc": 
"{{desc|name=PageViewInfo|url=https://www.mediawiki.org/wiki/Extension:PageViewInfo}}";,
        "pvi-month-count": "Label for table cell containing page views in past 
30 days",
        "pvi-close": "Text on button to close a dialog\n{{Identical|Close}}",
        "pvi-range": "Title of dialog, which is the date range the graph is 
for. $1 is the starting date, $2 is the ending date."
diff --git a/includes/PageViewInfo.hooks.php b/includes/PageViewInfo.hooks.php
index 0f87f45..af4cdda 100644
--- a/includes/PageViewInfo.hooks.php
+++ b/includes/PageViewInfo.hooks.php
@@ -37,12 +37,12 @@
                );
                $info['data'][0]['values'] = $views['items'];
 
-               $ctx->getOutput()->addModules( 'ext.wmpageviewinfo' );
+               $ctx->getOutput()->addModules( 'ext.pageviewinfo' );
                // Ymd -> YmdHis
                $plus = '000000';
                $user = $ctx->getUser();
                $ctx->getOutput()->addJsConfigVars( [
-                       'wgWMPageViewInfo' => [
+                       'wgPageViewInfo' => [
                                'graph' => $info,
                                'start' => $lang->userDate( $views['start'] . 
$plus, $user ),
                                'end' => $lang->userDate( $views['end'] . 
$plus, $user ),
diff --git a/resources/ext.wmpageviewinfo.js b/resources/ext.pageviewinfo.js
similarity index 96%
rename from resources/ext.wmpageviewinfo.js
rename to resources/ext.pageviewinfo.js
index 300522d..486d68c 100644
--- a/resources/ext.wmpageviewinfo.js
+++ b/resources/ext.pageviewinfo.js
@@ -2,7 +2,7 @@
        $( function () {
                var $count = $( '.mw-pvi-month' ),
                        count = $count.text(),
-                       info = mw.config.get( 'wgWMPageViewInfo' );
+                       info = mw.config.get( 'wgPageViewInfo' );
 
                // Turn it into an <a> tag so it's obvious you can click on it
                $count.html( mw.html.element( 'a', { href: '#' }, count ) );

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaf83d2fafd09c8ba4509649d51ca94f1003dd75d
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/PageViewInfo
Gerrit-Branch: master
Gerrit-Owner: Gergő Tisza <gti...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to