Legoktm has uploaded a new change for review.

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

Change subject: Add WikimediaShopLink's SkinBuildSidebar hook directly
......................................................................

Add WikimediaShopLink's SkinBuildSidebar hook directly

Messages were moved to WikimediaMessages in I7bfca5141458.

Bug: 55678
Change-Id: I2eef13fde9b0d567c92205c4d78d22ea1fa762f1
---
M wmf-config/CommonSettings.php
1 file changed, 14 insertions(+), 12 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config 
refs/changes/87/149787/1

diff --git a/wmf-config/CommonSettings.php b/wmf-config/CommonSettings.php
index d2db7b1..2aa8a0a 100644
--- a/wmf-config/CommonSettings.php
+++ b/wmf-config/CommonSettings.php
@@ -2264,18 +2264,20 @@
 }
 
 if ( $wmgUseWikimediaShopLink ) {
-       require_once( "$IP/extensions/WikimediaShopLink/WikimediaShopLink.php" 
);
-       $wgWikimediaShopEnableLink = true;
-       $wgWikimediaShopShowLinkCountries = array(
-               'US',
-               'VI',
-               'UM',
-               'PR',
-               'CA',
-               'MX',
-               'JP',
-       );
-       $wgWikimediaShopLinkTarget = '//shop.wikimedia.org';
+       /**
+        * @param Skin $skin
+        * @param array $sidebar
+        * @return bool
+        */
+       $wgHooks['SkinBuildSidebar'][] = function ( $skin, &$sidebar ) {
+               $sidebar['navigation'][] = array(
+                       'text'  => $skin->msg( 'wikimediashoplink-linktext' ),
+                       'href'  => '//shop.wikimedia.org',
+                       'title' => $skin->msg( 'wikimediashoplink-link-tooltip' 
),
+                       'id'    => 'n-shoplink',
+               );
+               return true;
+       };
 }
 
 if ( $wmgEnableGeoData

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I2eef13fde9b0d567c92205c4d78d22ea1fa762f1
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Legoktm <legoktm.wikipe...@gmail.com>

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

Reply via email to