Sophivorus has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/351117 )
Change subject: Make sure the dependencies are loaded ...................................................................... Make sure the dependencies are loaded Don't init ProveIt until all the dependencies are loaded Also minor comment update And update of my username Change-Id: Ib0ce8079c62ddc327c2ec19195081429837202e7 --- M README.md M i18n/de.json M i18n/en.json M i18n/es.json M i18n/it.json M i18n/pt.json M i18n/qqq.json M proveit.js 8 files changed, 31 insertions(+), 26 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/wikipedia/gadgets/ProveIt refs/changes/17/351117/1 diff --git a/README.md b/README.md index d615074..fb1c206 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # ProveIt -ProveIt is a Wikipedia gadget that makes it easy to find, edit, add and delete references when editing articles. +ProveIt is powerful reference manager for Wikipedia Documentation at https://commons.wikimedia.org/wiki/Help:Gadget-ProveIt \ No newline at end of file diff --git a/i18n/de.json b/i18n/de.json index 0c2d9a3..68c29dd 100644 --- a/i18n/de.json +++ b/i18n/de.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone", + "Sophivorus", "Metalhead64" ] }, diff --git a/i18n/en.json b/i18n/en.json index 9680617..f2903c8 100644 --- a/i18n/en.json +++ b/i18n/en.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone" + "Sophivorus" ] }, "proveit-list-tab": "List ($1)", diff --git a/i18n/es.json b/i18n/es.json index c076ed1..8823f73 100644 --- a/i18n/es.json +++ b/i18n/es.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone", + "Sophivorus", "Macofe" ] }, diff --git a/i18n/it.json b/i18n/it.json index 44b4867..ca6c868 100644 --- a/i18n/it.json +++ b/i18n/it.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone", + "Sophivorus", "Beta16" ] }, diff --git a/i18n/pt.json b/i18n/pt.json index c3531df..efc86f1 100644 --- a/i18n/pt.json +++ b/i18n/pt.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone", + "Sophivorus", "He7d3r" ] }, diff --git a/i18n/qqq.json b/i18n/qqq.json index 87a0a46..dc0dae2 100644 --- a/i18n/qqq.json +++ b/i18n/qqq.json @@ -1,7 +1,7 @@ { "@metadata": { "authors": [ - "Felipe Schenone", + "Sophivorus", "Liuxinyu970226", "Robby" ] diff --git a/proveit.js b/proveit.js index fe3818a..d845724 100755 --- a/proveit.js +++ b/proveit.js @@ -1,10 +1,10 @@ /** - * ProveIt is a Wikipedia gadget that makes it easy to find, edit, add and delete references when editing articles. + * ProveIt is a powerful reference manager for Wikipedia * Documentation at https://commons.wikimedia.org/wiki/Help:Gadget-ProveIt * * Copyright 2008-2011 Georgia Tech Research Corporation, Atlanta, GA 30332-0415, ALL RIGHTS RESERVED * Copyright 2011- Matthew Flaschen - * Rewritten, internationalized, enhanced and maintained by Felipe Schenone since 2014 + * Rewritten, internationalized, enhanced and maintained by Sophivorus since 2014 * * ProveIt is available under the GNU Free Documentation License (http://www.gnu.org/copyleft/fdl.html), * the Creative Commons Attribution/Share-Alike License 3.0 (http://creativecommons.org/licenses/by-sa/3.0/), @@ -204,20 +204,18 @@ // Make the GUI draggable var dragged = false; - mw.loader.using( 'jquery.ui.draggable' ).then( function () { - gui.draggable({ - handle: header, - containment: 'window', - start: function ( event ) { - if ( event.originalEvent.target.id !== 'proveit-header' ) { - dragged = true; - } - gui.css({ - 'right': 'auto', - 'bottom': 'auto' - }); + gui.draggable({ + handle: header, + containment: 'window', + start: function ( event ) { + if ( event.originalEvent.target.id !== 'proveit-header' ) { + dragged = true; } - }); + gui.css({ + 'right': 'auto', + 'bottom': 'auto' + }); + } }); // Lastly, bind events @@ -430,8 +428,7 @@ * Insert this citation into the textbox */ this.insert = function () { - var textbox = proveit.getTextbox(); - textbox.textSelection( 'encapsulateSelection', { + proveit.getTextbox().textSelection( 'encapsulateSelection', { 'peri': this.toString(), 'replace': true }); @@ -482,7 +479,10 @@ // Highlight the string var start = this.index, end = start + this.string.length; - $( textbox ).focus().textSelection( 'setSelection', { 'start': start, 'end': end } ); + $( textbox ).focus().textSelection( 'setSelection', { + 'start': start, + 'end': end + }); }; }, @@ -1175,6 +1175,11 @@ } }; -$( proveit.init ); +mw.loader.using([ + 'mediawiki.api', + 'jquery.cookie', + 'jquery.textSelection', + 'jquery.ui.draggable' +], proveit.init ); }( mw, jQuery ) ); -- To view, visit https://gerrit.wikimedia.org/r/351117 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ib0ce8079c62ddc327c2ec19195081429837202e7 Gerrit-PatchSet: 1 Gerrit-Project: wikipedia/gadgets/ProveIt Gerrit-Branch: master Gerrit-Owner: Sophivorus <[email protected]> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
