diff --git a/JQueryPlugin/data/System/JQueryMigrate.txt b/JQueryPlugin/data/System/JQueryMigrate.txt index 5d4f5f8997..0a6c7b7cc4 100644 --- a/JQueryPlugin/data/System/JQueryMigrate.txt +++ b/JQueryPlugin/data/System/JQueryMigrate.txt @@ -1,4 +1,4 @@ -%META:TOPICINFO{author="ProjectContributor" date="1258386347" format="1.1" version="1"}% +%META:TOPICINFO{author="ProjectContributor" date="1456220586" format="1.1" version="1"}% %META:TOPICPARENT{name="JQueryPlugin"}% ---+ %TOPIC% %JQPLUGINS{"migrate" diff --git a/JQueryPlugin/lib/Foswiki/Plugins/JQueryPlugin/MIGRATE.pm b/JQueryPlugin/lib/Foswiki/Plugins/JQueryPlugin/MIGRATE.pm index fd2f0deda2..a4aa332363 100644 --- a/JQueryPlugin/lib/Foswiki/Plugins/JQueryPlugin/MIGRATE.pm +++ b/JQueryPlugin/lib/Foswiki/Plugins/JQueryPlugin/MIGRATE.pm @@ -28,7 +28,7 @@ sub new { my $this = bless( $class->SUPER::new( name => 'Migrate', - version => '1.2.1', + version => '1.3.0', author => 'jQuery Foundation, Inc. and other contributors', homepage => 'https://github.com/jquery/jquery-migrate/', javascript => ['jquery.migrate.js'], @@ -44,7 +44,7 @@ sub new { __END__ Foswiki - The Free and Open Source Wiki, http://foswiki.org/ -Copyright (C) 2010-2015 Foswiki Contributors. Foswiki Contributors +Copyright (C) 2010-2016 Foswiki Contributors. Foswiki Contributors are listed in the AUTHORS file in the root of this distribution. NOTE: Please extend that file, not this notice. diff --git a/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.patch b/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.patch new file mode 100644 index 0000000000..e8580fa4b6 --- /dev/null +++ b/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.patch @@ -0,0 +1,36 @@ +--- jquery-migrate-1.3.0.js 2016-01-13 15:50:20.000000000 +0100 ++++ jquery.migrate.uncompressed.js 2016-02-15 14:11:12.370463388 +0100 +@@ -16,7 +16,8 @@ + jQuery.migrateWarnings = []; + + // Set to true to prevent console output; migrateWarnings still maintained +-// jQuery.migrateMute = false; ++jQuery.migrateMute = true; ++jQuery.migrateTrace = false; + + // Show a message on the console so devs know we're active + if ( !jQuery.migrateMute && window.console && window.console.log ) { +@@ -269,9 +270,14 @@ + /(webkit)[ \/]([\w.]+)/.exec( ua ) || + /(opera)(?:.*version|)[ \/]([\w.]+)/.exec( ua ) || + /(msie) ([\w.]+)/.exec( ua ) || ++ /(trident).*; rv:([\w.]+)/.exec( ua ) || + ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec( ua ) || + []; + ++ if (match[1] === 'trident') { ++ match[1] = 'msie'; ++ } ++ + return { + browser: match[ 1 ] || "", + version: match[ 2 ] || "0" +@@ -299,7 +305,7 @@ + } + + // Warn if the code tries to get jQuery.browser +-migrateWarnProp( jQuery, "browser", jQuery.browser, "jQuery.browser is deprecated" ); ++//migrateWarnProp( jQuery, "browser", jQuery.browser, "jQuery.browser is deprecated" ); + + // jQuery.boxModel deprecated in 1.3, jQuery.support.boxModel deprecated in 1.7 + jQuery.boxModel = jQuery.support.boxModel = (document.compatMode === "CSS1Compat"); diff --git a/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.uncompressed.js b/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.uncompressed.js index 82bea83106..72cdd03d5c 100644 --- a/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.uncompressed.js +++ b/JQueryPlugin/pub/System/JQueryPlugin/plugins/migrate/jquery.migrate.uncompressed.js @@ -1,527 +1,708 @@ -/*! - * jQuery Migrate - v1.2.1 - 2013-05-08 - * https://github.com/jquery/jquery-migrate - * Copyright 2005, 2013 jQuery Foundation, Inc. and other contributors; Licensed MIT - */ -(function( jQuery, window, undefined ) { -// See http://bugs.jquery.com/ticket/13335 -// "use strict"; - - -var warnedAbout = {}; - -// List of warnings already given; public read only -jQuery.migrateWarnings = []; - -// Set to true to prevent console output; migrateWarnings still maintained -jQuery.migrateMute = true; -jQuery.migrateTrace = false; - -// Show a message on the console so devs know we're active -if ( !jQuery.migrateMute && window.console && window.console.log ) { - window.console.log("JQMIGRATE: Logging is active"); -} - -// Set to false to disable traces that appear with warnings -if ( jQuery.migrateTrace === undefined ) { - jQuery.migrateTrace = true; -} - -// Forget any warnings we've already given; public -jQuery.migrateReset = function() { - warnedAbout = {}; - jQuery.migrateWarnings.length = 0; -}; - -function migrateWarn( msg) { - var console = window.console; - if ( !warnedAbout[ msg ] ) { - warnedAbout[ msg ] = true; - jQuery.migrateWarnings.push( msg ); - if ( console && console.warn && !jQuery.migrateMute ) { - console.warn( "JQMIGRATE: " + msg ); - if ( jQuery.migrateTrace && console.trace ) { - console.trace(); - } - } - } -} - -function migrateWarnProp( obj, prop, value, msg ) { - if ( Object.defineProperty ) { - // On ES5 browsers (non-oldIE), warn if the code tries to get prop; - // allow property to be overwritten in case some other plugin wants it - try { - Object.defineProperty( obj, prop, { - configurable: true, - enumerable: true, - get: function() { - migrateWarn( msg ); - return value; - }, - set: function( newValue ) { - migrateWarn( msg ); - value = newValue; - } - }); - return; - } catch( err ) { - // IE8 is a dope about Object.defineProperty, can't warn there - } - } - - // Non-ES5 (or broken) browser; just set the property - jQuery._definePropertyBroken = true; - obj[ prop ] = value; -} - -if ( document.compatMode === "BackCompat" ) { - // jQuery has never supported or tested Quirks Mode - migrateWarn( "jQuery is not compatible with Quirks Mode" ); -} - - -var attrFn = jQuery( "", { size: 1 } ).attr("size") && jQuery.attrFn, - oldAttr = jQuery.attr, - valueAttrGet = jQuery.attrHooks.value && jQuery.attrHooks.value.get || - function() { return null; }, - valueAttrSet = jQuery.attrHooks.value && jQuery.attrHooks.value.set || - function() { return undefined; }, - rnoType = /^(?:input|button)$/i, - rnoAttrNodeType = /^[238]$/, - rboolean = /^(?:autofocus|autoplay|async|checked|controls|defer|disabled|hidden|loop|multiple|open|readonly|required|scoped|selected)$/i, - ruseDefault = /^(?:checked|selected)$/i; - -// jQuery.attrFn -migrateWarnProp( jQuery, "attrFn", attrFn || {}, "jQuery.attrFn is deprecated" ); - -jQuery.attr = function( elem, name, value, pass ) { - var lowerName = name.toLowerCase(), - nType = elem && elem.nodeType; - - if ( pass ) { - // Since pass is used internally, we only warn for new jQuery - // versions where there isn't a pass arg in the formal params - if ( oldAttr.length < 4 ) { - migrateWarn("jQuery.fn.attr( props, pass ) is deprecated"); - } - if ( elem && !rnoAttrNodeType.test( nType ) && - (attrFn ? name in attrFn : jQuery.isFunction(jQuery.fn[name])) ) { - return jQuery( elem )[ name ]( value ); - } - } - - // Warn if user tries to set `type`, since it breaks on IE 6/7/8; by checking - // for disconnected elements we don't warn on $( "