jenkins-bot has submitted this change and it was merged.

Change subject: Add a link to Commons:Geocoding page in location entry tooltip
......................................................................


Add a link to Commons:Geocoding page in location entry tooltip

Changed 'mwe-upwiz-tooltip-location' (i18n)
and defined 'var location' for the url of Commons:Geocoding.

Bug: T36336
Change-Id: I8566299a0a84e9d506767dc854194f9e2318ffd7
---
M i18n/en.json
M resources/mw.UploadWizardDetails.js
2 files changed, 13 insertions(+), 4 deletions(-)

Approvals:
  MarkTraceur: Looks good to me, approved
  Bartosz Dziewoński: Looks good to me, but someone else must approve
  jenkins-bot: Verified



diff --git a/i18n/en.json b/i18n/en.json
index 3600500..5d85b5f 100644
--- a/i18n/en.json
+++ b/i18n/en.json
@@ -191,7 +191,7 @@
        "mwe-upwiz-tooltip-date": "Date this work was created or first 
published (YYYY-MM-DD format).",
        "mwe-upwiz-tooltip-categories": "Add your file to [$1 categories] so as 
to make it easier to find.",
        "mwe-upwiz-tooltip-other": "Any other information you want to include 
about this work — geographic coordinates, links to other versions, etc.",
-       "mwe-upwiz-tooltip-location": "Coordinates of the location where this 
media file was created.",
+       "mwe-upwiz-tooltip-location": "[$1 Geocode your file] to identify where 
the media was recorded (it is not always useful to enter a location for every 
kind of media).",
        "mwe-upwiz-tooltip-more-info": "Learn more.",
        "mwe-upwiz-file-need-file": "Please add an upload first.",
        "mwe-upwiz-deeds-need-license": "Please select a license.",
diff --git a/resources/mw.UploadWizardDetails.js 
b/resources/mw.UploadWizardDetails.js
index 8344dea..df1c406 100644
--- a/resources/mw.UploadWizardDetails.js
+++ b/resources/mw.UploadWizardDetails.js
@@ -21,7 +21,7 @@
                        categoriesId, dateInputId, dateErrorDiv, dateInputDiv,
                        moreDetailsCtrlDiv, moreDetailsDiv, otherInformationId,
                        otherInformationDiv, latitudeDiv, longitudeDiv, 
headingDiv,
-                       showMap, linkDiv, locationDiv, hiddenCats, 
missingCatsWikiText,
+                       showMap, linkDiv, locationHinter, locationDiv, 
hiddenCats, missingCatsWikiText,
                        $list,
                        details = this;
 
@@ -190,10 +190,19 @@
                        .append( $( '<div 
class="mwe-upwiz-details-more-label"></div>' ).text( mw.message( 
'mwe-upwiz-other' ).text() ).addHint( 'other' ) )
                        .append( this.otherInformationInput );
 
+               locationHinter = function () {
+                       var location = $( '<a>' ).attr( {
+                               target: '_blank',
+                               href: 
'//commons.wikimedia.org/wiki/Commons:Geocoding'
+                       } );
+                       return $( '<span>' ).msg( 'mwe-upwiz-tooltip-location', 
location ).html();
+               };
+
                locationDiv = $( '<div class="mwe-location 
mwe-upwiz-details-fieldname-input ui-helper-clearfix"></div>' )
                        .append( $ ('<div class="mwe-location-label"></div>' )
-                       .append( mw.message( 'mwe-upwiz-location' ).escaped() )
-                       .addHint( 'location' ) )
+                               .append( mw.message( 'mwe-upwiz-location' 
).escaped() )
+                               .addHint( 'location', locationHinter )
+                       )
                        .append(
                                $( '<div 
class="mwe-upwiz-details-input-error"><label class="mwe-validator-error" for="' 
+ 'location-lat' + this.upload.index + '" generated="true"/></div>' ),
                                $( '<div 
class="mwe-upwiz-details-input-error"><label class="mwe-validator-error" for="' 
+ 'location-lon' + this.upload.index + '" generated="true"/></div>' ),

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

Gerrit-MessageType: merged
Gerrit-Change-Id: I8566299a0a84e9d506767dc854194f9e2318ffd7
Gerrit-PatchSet: 11
Gerrit-Project: mediawiki/extensions/UploadWizard
Gerrit-Branch: master
Gerrit-Owner: Rjain <[email protected]>
Gerrit-Reviewer: Alex Monk <[email protected]>
Gerrit-Reviewer: Bartosz Dziewoński <[email protected]>
Gerrit-Reviewer: Gilles <[email protected]>
Gerrit-Reviewer: Kaldari <[email protected]>
Gerrit-Reviewer: MarkTraceur <[email protected]>
Gerrit-Reviewer: Nischayn22 <[email protected]>
Gerrit-Reviewer: Rasel160 <[email protected]>
Gerrit-Reviewer: Rjain <[email protected]>
Gerrit-Reviewer: Sumanah <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

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

Reply via email to