N°5621 Move jquery-migrate 3.1.0 to NPM

This commit is contained in:
Pierre Goiffon
2024-03-07 15:19:35 +01:00
parent c24c1ba73c
commit 9fa036df7e
71 changed files with 14252 additions and 4 deletions

55
node_modules/jquery-migrate/test/event-props.html generated vendored Normal file
View File

@@ -0,0 +1,55 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>jQuery Migrate event props iframe test</title>
<!-- Load a jQuery and jquery-migrate plugin file based on URL -->
<script src="testinit.js"></script>
<script>
TestManager.loadProject( "jquery", "git" );
</script>
<script src="iframeTest.js"></script>
<script>
jQuery.noConflict();
TestManager.loadProject( "jquery-migrate", "dev", true );
</script>
<script>
function dispatchEvent( elem, type ) {
var e = document.createEvent( "HTMLEvents" );
e.initEvent( type, true, true );
elem.dispatchEvent( e );
}
function runTest() {
var test1, test2,
div = document.createElement( "div" ),
$div = jQuery( div ).appendTo( document.body );
$div.on( "blend", function( event ) {
test1 = ( "whip" in event ) && ( "chop" in event );
// Props added later are also processed
jQuery.event.props.push( "frappe" );
dispatchEvent( div, "puree" );
} );
$div.on( "puree", function( event ) {
test2 = ( "whip" in event ) && ( "frappe" in event );
// 2 prop warnings ( chop+whip and frappe )
startIframeTest( test1, test2 );
} );
// Multiple props, processed with a single warning
jQuery.event.props.push( "chop", "whip" );
dispatchEvent( div, "blend" );
}
jQuery( runTest );
</script>
</head>
<body>
<p>jQuery Migrate</p>
</body>
</html>