mw.Upload.BookletLayout: Add help text for name and description fields
authorPrateek Saxena <prtksxna@gmail.com>
Tue, 17 Nov 2015 06:27:21 +0000 (11:57 +0530)
committerJforrester <jforrester@wikimedia.org>
Fri, 1 Jan 2016 19:44:30 +0000 (19:44 +0000)
Copied the following string from UploadWizard into core to be shown as
help text near the input fields:
 * mwe-upwiz-tooltip-title
 * mwe-upwiz-tooltip-description

Bug: T116086
Change-Id: Iaaac4908c71b416888921a4e45de66fa87ab448d

languages/i18n/en.json
languages/i18n/qqq.json
resources/Resources.php
resources/src/mediawiki/mediawiki.ForeignStructuredUpload.BookletLayout.js
resources/src/mediawiki/mediawiki.Upload.BookletLayout.js

index 349cac6..a34a597 100644 (file)
        "upload-form-label-select-file": "Select file",
        "upload-form-label-infoform-title": "Details",
        "upload-form-label-infoform-name": "Name",
+       "upload-form-label-infoform-name-tooltip": "A unique descriptive title for the file, which will serve as a filename. You may use plain language with spaces. Do not include the file extension.",
        "upload-form-label-infoform-description": "Description",
+       "upload-form-label-infoform-description-tooltip": "Briefly describe everything notable about the work.\nFor a photo, mention the main things that are depicted, the occasion, or the place.",
        "upload-form-label-usage-title": "Usage",
        "upload-form-label-usage-filename": "File name",
        "foreign-structured-upload-form-label-own-work": "This is my own work",
index 87470bf..4f2a005 100644 (file)
        "upload-form-label-select-file": "Label for the select file widget\n{{Identical|Select file}}",
        "upload-form-label-infoform-title": "Title for the information form\n{{Identical|Detail}}",
        "upload-form-label-infoform-name": "Label for the file name input\n{{Identical|Name}}",
+       "upload-form-label-infoform-name-tooltip": "The tooltip documenting the title field for the file - used as the filename on-wiki.",
        "upload-form-label-infoform-description": "Label for the file description input\n{{Identical|Description}}",
+       "upload-form-label-infoform-description-tooltip": "The tooltip documenting the description fields on the details page.",
        "upload-form-label-usage-title": "Title for the insert form showing how to use the uploaded item.\n{{Identical|Usage}}",
        "upload-form-label-usage-filename": "Label for the file name input\n{{Identical|Filename}}",
        "foreign-structured-upload-form-label-own-work": "[[File:Cross-wiki media upload dialog, December 2015 AB test option 1.png|thumb]] Label for own work confirmation checkbox",
index ca82c84..8dd78ab 100644 (file)
@@ -1195,7 +1195,9 @@ return array(
                        'upload-form-label-select-file',
                        'upload-form-label-infoform-title',
                        'upload-form-label-infoform-name',
+                       'upload-form-label-infoform-name-tooltip',
                        'upload-form-label-infoform-description',
+                       'upload-form-label-infoform-description-tooltip',
                        'upload-form-label-usage-title',
                        'upload-form-label-usage-filename',
                        'api-error-unknownerror',
index d896756..ddf7f2b 100644 (file)
                fieldset.addItems( [
                        new OO.ui.FieldLayout( this.filenameWidget, {
                                label: mw.msg( 'upload-form-label-infoform-name' ),
-                               align: 'top'
+                               align: 'top',
+                               help: mw.msg( 'upload-form-label-infoform-name-tooltip' )
                        } ),
                        new OO.ui.FieldLayout( this.descriptionWidget, {
                                label: mw.msg( 'upload-form-label-infoform-description' ),
-                               align: 'top'
+                               align: 'top',
+                               help: mw.msg( 'upload-form-label-infoform-description-tooltip' )
                        } ),
                        new OO.ui.FieldLayout( this.categoriesWidget, {
                                label: mw.msg( 'foreign-structured-upload-form-label-infoform-categories' ),
index 3f04bb1..26eabc7 100644 (file)
                fieldset.addItems( [
                        new OO.ui.FieldLayout( this.filenameWidget, {
                                label: mw.msg( 'upload-form-label-infoform-name' ),
-                               align: 'top'
+                               align: 'top',
+                               help: mw.msg( 'upload-form-label-infoform-name-tooltip' )
                        } ),
                        new OO.ui.FieldLayout( this.descriptionWidget, {
                                label: mw.msg( 'upload-form-label-infoform-description' ),
-                               align: 'top'
+                               align: 'top',
+                               help: mw.msg( 'upload-form-label-infoform-description-tooltip' )
                        } )
                ] );
                this.infoForm = new OO.ui.FormLayout( { items: [ fieldset ] } );