r93130 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r93129‎ | r93130 | r93131 >
Date:21:56, 25 July 2011
Author:krinkle
Status:deferred
Tags:
Comment:
MoodBar i18n + front-end:
- Some message changes have been send to us, implementing here.
- Passing sitename as first parameters and caching the resulting config-call and array to be used 4 times.
Modified paths:
  • /trunk/extensions/MoodBar/MoodBar.i18n.php (modified) (history)
  • /trunk/extensions/MoodBar/modules/ext.moodBar/ext.moodBar.core.js (modified) (history)

Diff [purge]

Index: trunk/extensions/MoodBar/MoodBar.i18n.php
@@ -50,7 +50,7 @@
5151 'moodbar-success-title' => 'Thanks!',
5252 'moodbar-error-title' => 'Oops!',
5353 'moodbar-loading-subtitle' => 'We are sharing your feedback…',
54 - 'moodbar-success-subtitle' => 'Sharing your mood helps us make Wikipedia better.',
 54+ 'moodbar-success-subtitle' => 'Sharing your editing experience helps us improve $1.',
5555 'moodbar-error-subtitle' => 'Something went wrong! Please try sharing your mood again later.',
5656 // Special:MoodBar
5757 'right-moodbar-view' => 'View and export MoodBar feedback',
@@ -111,6 +111,12 @@
112112
113113 See also:
114114 * {{msg|moodbar-form-policy-text}}',
 115+ 'moodbar-loading-title' => 'Title of the screen when the widget is loading.',
 116+ 'moodbar-success-title' => 'Title of the screen after the feedback was successfullyully submitted.',
 117+ 'moodbar-error-title' => 'Title of the screen when after an error occurred and submission aborted.',
 118+ 'moodbar-loading-subtitle' => 'Subtitle of Loading-screen. $1 is the SITENAME',
 119+ 'moodbar-success-subtitle' => 'Subtitle of screen when feedback was successfullyully submitted. $1 is the SITENAME',
 120+ 'moodbar-error-subtitle' => 'Subtitle of screen when an error occurred. $1 is the SITENAME',
115121 );
116122
117123 /** Message documentation (Message documentation)
Index: trunk/extensions/MoodBar/modules/ext.moodBar/ext.moodBar.core.js
@@ -238,14 +238,18 @@
239239 },
240240
241241 swapContent: function( tpl ) {
242 - var msgOptions = {
243 - keys: {
244 - INTROTITLE: 'moodbar-intro-' + mb.conf.bucketKey
245 - },
246 - params: {
247 - INTROTITLE: [mw.config.get( 'wgSiteName' )]
248 - }
249 - };
 242+ var sitenameParams = [mw.config.get( 'wgSiteName' )], // Cache common params
 243+ msgOptions = {
 244+ keys: {
 245+ INTROTITLE: 'moodbar-intro-' + mb.conf.bucketKey
 246+ },
 247+ params: {
 248+ INTROTITLE: sitenameParams,
 249+ 'moodbar-loading-subtitle': sitenameParams,
 250+ 'moodbar-success-subtitle': sitenameParams,
 251+ 'moodbar-error-subtitle': sitenameParams
 252+ }
 253+ };
250254
251255 mb.ui.overlay
252256 .find( '.mw-moodBar-overlayContent' )

Status & tagging log