mediawiki.util: Drop jsMessage(), deprecated since 1.20 and mostly unused
authorJames D. Forrester <jforrester@wikimedia.org>
Fri, 4 May 2018 18:39:47 +0000 (11:39 -0700)
committerKrinkle <krinklemail@gmail.com>
Mon, 3 Dec 2018 03:05:34 +0000 (03:05 +0000)
This also means that mediawiki.notify is no longer loaded.

Bug: T193901
Change-Id: Ifa222ca05ec913c140284ee0113c0d7827215130

RELEASE-NOTES-1.33
resources/Resources.php
resources/src/mediawiki.util.js

index 677b1c1..628227e 100644 (file)
@@ -152,6 +152,7 @@ because of Phabricator reports.
   * filterIntval()
   * filterTimezoneInput()
   * getTimeZoneList()
+* mw.util.jsMessage(), deprecated in 1.20, was removed. Use mw.notify instead.
 
 === Deprecations in 1.33 ===
 * The configuration option $wgUseESI has been deprecated, and is expected
index cb1f2bd..0385d80 100644 (file)
@@ -1372,7 +1372,6 @@ return [
                'dependencies' => [
                        'jquery.accessKeyLabel',
                        'mediawiki.RegExp',
-                       'mediawiki.notify',
                ],
                'targets' => [ 'desktop', 'mobile' ],
        ],
index 27031f1..65fe3d3 100644 (file)
                }
        };
 
-       /**
-        * Add a little box at the top of the screen to inform the user of
-        * something, replacing any previous message.
-        * Calling with no arguments, with an empty string or null will hide the message
-        *
-        * @method jsMessage
-        * @deprecated since 1.20 Use mw#notify
-        * @param {Mixed} message The DOM-element, jQuery object or HTML-string to be put inside the message box.
-        *  to allow CSS/JS to hide different boxes. null = no class used.
-        */
-       mw.log.deprecate( util, 'jsMessage', function ( message ) {
-               if ( !arguments.length || message === '' || message === null ) {
-                       return true;
-               }
-               if ( typeof message !== 'object' ) {
-                       message = $.parseHTML( message );
-               }
-               mw.notify( message, { autoHide: true, tag: 'legacy' } );
-               return true;
-       }, 'Use mw.notify instead.', 'mw.util.jsMessage' );
-
        /**
         * Initialisation of mw.util.$content
         */