From 7f859e4c7390e40c41f6789e085f2115d22ce44e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 5 Jul 2012 20:11:52 -0400 Subject: [PATCH 01/47] Initial implementation for generating manifest files. --- build/core.json | 45 +++++++++++++++ build/effects.json | 41 +++++++++++++ build/tasks/build.js | 74 ++++++++++++++++++++++++ build/widgets.json | 135 +++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 295 insertions(+) create mode 100644 build/core.json create mode 100644 build/effects.json create mode 100644 build/widgets.json diff --git a/build/core.json b/build/core.json new file mode 100644 index 000000000..e50a57b42 --- /dev/null +++ b/build/core.json @@ -0,0 +1,45 @@ +{ + "core": { + "description": "The core of jQuery UI, required for all interactions and widgets." + }, + "datepicker": { + "description": "A datepicker than can be toggled from a input or displayed inline.", + "dependencies": [ "core" ], + "keywords": [ + "form", + "calendar", + "date", + "i18n" + ] + }, + "effect": { + "description": "Extends the internal jQuery effects, includes morphing, easing and is required by all other effects.", + "keywords": [ + "animation", + "show", + "hide", + "color", + "class", + "transition", + "easing" + ] + }, + "position": { + "description": "A utility plugin for positioning elements relative to other elements.", + "keywords": [ + "offset", + "relative", + "absolute", + "fixed", + "collision" + ] + }, + "widget": { + "description": "Provides a factory for creating stateful widgets with a common API.", + "keywords": [ + "abstraction", + "state", + "factory" + ] + } +} diff --git a/build/effects.json b/build/effects.json new file mode 100644 index 000000000..ef69ef82b --- /dev/null +++ b/build/effects.json @@ -0,0 +1,41 @@ +{ + "blind": { + "description": "Blinds the element." + }, + "bounce": { + "description": "Bounces an element horizontally or vertically n-times." + }, + "clip": { + "description": "Clips the element on and off like an old TV." + }, + "drop": { + "description": "A Drop out effect by moving the element in one direction and hiding it at the same time." + }, + "explode": { + "description": "The element explodes in all directions into n pieces. Also supports imploding again." + }, + "fade": { + "description": "Fades the element." + }, + "fold": { + "description": "Folds the element first horizontally and then vertically." + }, + "highlight": { + "description": "Highlights the background of the element in a defined color for a custom duration." + }, + "pulsate": { + "description": "The element pulsates n times by changing the opacity to zero and back." + }, + "scale": { + "description": "Grow or shrink any element and its content and restore it again." + }, + "shake": { + "description": "Shakes the element horizontally or vertically n times." + }, + "slide": { + "description": "The element slides in and out of the viewport." + }, + "transfer": { + "description": "Transfer effect from one element to another." + } +} diff --git a/build/tasks/build.js b/build/tasks/build.js index 06a4b98a2..aeacc232d 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -2,6 +2,80 @@ module.exports = function( grunt ) { var path = require( "path" ); +grunt.registerTask( "manifest", "Generate jquery.json manifest files", function() { + var pkg = grunt.config( "pkg" ), + base = { + core: { + name: "ui.{plugin}", + title: "jQuery UI {Plugin}" + }, + widgets: { + name: "ui.{plugin}", + title: "jQuery UI {Plugin}", + dependencies: [ "core", "widget" ] + }, + effects: { + name: "ui.effect-{plugin}", + title: "jQuery UI {Plugin} Effect", + keywords: [ "effect", "show", "hide" ], + // TODO: Will we have individual pages for 1.9? + homepage: "http://jqueryui.com/effect/", + // TODO: Will we have individual pages for 1.9? + demo: "http://jqueryui.com/effect/", + docs: "http://api.jqueryui.com/{plugin}-effect/", + dependencies: [ "effect" ], + file: "ui.effect-{plugin}" + } + }; + + Object.keys( base ).forEach(function( type ) { + var baseManifest = base[ type ], + plugins = grunt.file.readJSON( "build/" + type + ".json" ); + + Object.keys( plugins ).forEach(function( plugin ) { + var manifest, + data = plugins[ plugin ], + name = plugin.charAt( 0 ).toUpperCase() + plugin.substr( 1 ); + + function replace( str ) { + return str.replace( "{plugin}", plugin ).replace( "{Plugin}", name ); + } + + manifest = { + name: replace( baseManifest.name ), + title: replace( baseManifest.title ), + description: data.description, + keywords: [ "ui", plugin ] + .concat( baseManifest.keywords || [] ) + .concat( data.keywords || [] ), + version: pkg.version, + author: pkg.author, + maintainers: pkg.maintainers, + bugs: pkg.bugs, + homepage: data.homepage || replace( baseManifest.homepage || + "http://jqueryui.com/{plugin}/" ), + demo: data.demo || replace( baseManifest.demo || + "http://jqueryui.com/{plugin}/" ), + docs: data.docs || replace( baseManifest.docs || + "http://api.jqueryui.com/{plugin}/" ), + download: "http://jqueryui.com/download/", + dependencies: { + jquery: ">=1.6" + } + }; + + (baseManifest.dependencies || []) + .concat(data.dependencies || []) + .forEach(function( dependency ) { + manifest.dependencies[ "ui." + dependency ] = pkg.version; + }); + + grunt.file.write( replace( baseManifest.file || "ui.{plugin}" ) + ".jquery.json", + JSON.stringify( manifest, null, "\t" ) ); + }); + }); +}); + grunt.registerMultiTask( "copy", "Copy files to destination folder and replace @VERSION with pkg.version", function() { function replaceVersion( source ) { return source.replace( /@VERSION/g, grunt.config( "pkg.version" ) ); diff --git a/build/widgets.json b/build/widgets.json new file mode 100644 index 000000000..e39b046a4 --- /dev/null +++ b/build/widgets.json @@ -0,0 +1,135 @@ +{ + "accordion": { + "dependencies": [], + "description": "Collapsable content panels for displaying information in a limited amount of space.", + "keywords": [ + "navigation", + "panel", + "collapse", + "expand" + ] + }, + "autocomplete": { + "dependencies": [ "menu", "position" ], + "description": "Provides a list of suggested words as the user is typing.", + "keywords": [ + "form", + "word", + "predict", + "suggest" + ] + }, + "button": { + "dependencies": [], + "description": "Enhance your forms with themable buttons.", + "keywords": [ + "form", + "radio", + "checkbox" + ] + }, + "dialog": { + "dependencies": [ "button", "draggable", "position", "resizable" ], + "description": "Customizable dialog windows.", + "keywords": [ + "modal", + "alert", + "popup" + ] + }, + "draggable": { + "dependencies": [ "mouse" ], + "description": "Enable dragging functionality for any element.", + "keywords": [ + "drag", + "drop" + ] + }, + "droppable": { + "dependencies": [ "draggable", "mouse" ], + "description": "Create drop targets for draggable elements.", + "keywords": [ + "drag", + "drop" + ] + }, + "menu": { + "dependencies": [ "position" ], + "description": "Easily create nestable menus.", + "keywords": [ + "dropdown", + "flyout" + ] + }, + "mouse": { + "dependencies": [], + "description": "An abstraction for any mouse-based interactions.", + "keywords": [ + "abstraction" + ] + }, + "progressbar": { + "dependencies": [], + "description": "A status indicator that can be used for a loading state and standard percentage indicators.", + "keywords": [ + "determinate", + "status" + ] + }, + "resizable": { + "dependencies": [ "mouse" ], + "description": "Enable resize functioality for any element.", + "keywords": [ + "resize" + ] + }, + "selectable": { + "dependencies": [ "mouse" ], + "description": "Create groups of elements that can be selected with the mouse.", + "keywords": [ + "selection" + ] + }, + "slider": { + "dependencies": [ "mouse" ], + "description": "A flexible slider with ranges and accessibility via keyboard.", + "keywords": [ + "form", + "number", + "range" + ] + }, + "sortable": { + "dependencies": [ "mouse" ], + "description": "Sort items in a list using the mouse.", + "keywords": [ + "sort", + "list" + ] + }, + "spinner": { + "dependencies": [ "button" ], + "description": "Easily input numbers via the keyboard or mouse.", + "keywords": [ + "form", + "number", + "spinbutton", + "stepper" + ] + }, + "tabs": { + "dependencies": [], + "description": "Transforms a set of container elements into a tab structure.", + "keywords": [ + "navigation", + "panel", + "collapse", + "expand" + ] + }, + "tooltip": { + "dependencies": [ "position" ], + "description": "Show additional information for any element on hover or focus.", + "keywords": [] + } +} From d369417f7eacbf4c7be68d138f3fd05a8adf0314 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Fri, 6 Jul 2012 12:39:17 -0400 Subject: [PATCH 02/47] Minor manifest updates. --- build/core.json | 11 +++++++++-- build/tasks/build.js | 9 ++++----- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/build/core.json b/build/core.json index e50a57b42..366abf8e1 100644 --- a/build/core.json +++ b/build/core.json @@ -1,6 +1,9 @@ { "core": { - "description": "The core of jQuery UI, required for all interactions and widgets." + "description": "The core of jQuery UI, required for all interactions and widgets.", + "homepage": "http://jqueryui.com/", + "demo": "http://jqueryui.com/", + "docs": "http://api.jqueryui.com/category/ui-core" }, "datepicker": { "description": "A datepicker than can be toggled from a input or displayed inline.", @@ -13,6 +16,7 @@ ] }, "effect": { + "title": "jQuery UI Effects Core", "description": "Extends the internal jQuery effects, includes morphing, easing and is required by all other effects.", "keywords": [ "animation", @@ -22,7 +26,10 @@ "class", "transition", "easing" - ] + ], + "homepage": "http://jqueryui.com/", + "demo": "http://jqueryui.com/", + "docs": "http://api.jqueryui.com/category/effects-core" }, "position": { "description": "A utility plugin for positioning elements relative to other elements.", diff --git a/build/tasks/build.js b/build/tasks/build.js index aeacc232d..5f9d33fec 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -4,6 +4,7 @@ var path = require( "path" ); grunt.registerTask( "manifest", "Generate jquery.json manifest files", function() { var pkg = grunt.config( "pkg" ), + // TODO: URLs for UI core and effects core base = { core: { name: "ui.{plugin}", @@ -18,10 +19,8 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( name: "ui.effect-{plugin}", title: "jQuery UI {Plugin} Effect", keywords: [ "effect", "show", "hide" ], - // TODO: Will we have individual pages for 1.9? - homepage: "http://jqueryui.com/effect/", - // TODO: Will we have individual pages for 1.9? - demo: "http://jqueryui.com/effect/", + homepage: "http://jqueryui.com/{plugin}-effect/", + demo: "http://jqueryui.com/{plugin}-effect/", docs: "http://api.jqueryui.com/{plugin}-effect/", dependencies: [ "effect" ], file: "ui.effect-{plugin}" @@ -43,7 +42,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( manifest = { name: replace( baseManifest.name ), - title: replace( baseManifest.title ), + title: data.title || replace( baseManifest.title ), description: data.description, keywords: [ "ui", plugin ] .concat( baseManifest.keywords || [] ) From 10984c012ff541c9bb70f01f366f0fde26fa0d83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Fri, 6 Jul 2012 12:47:44 -0400 Subject: [PATCH 03/47] Accidentally removed licenses. --- build/tasks/build.js | 1 + 1 file changed, 1 insertion(+) diff --git a/build/tasks/build.js b/build/tasks/build.js index 5f9d33fec..dc1b5e5bb 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -50,6 +50,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( version: pkg.version, author: pkg.author, maintainers: pkg.maintainers, + licenses: pkg.licenses, bugs: pkg.bugs, homepage: data.homepage || replace( baseManifest.homepage || "http://jqueryui.com/{plugin}/" ), From 83ec5e2077cffdea1ed9ff1e68b519baf320d6f0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 9 Jul 2012 10:19:17 -0400 Subject: [PATCH 04/47] Let's not pretend that manifest names are configurable... --- build/tasks/build.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/build/tasks/build.js b/build/tasks/build.js index dc1b5e5bb..5dff38f6a 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -22,8 +22,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( homepage: "http://jqueryui.com/{plugin}-effect/", demo: "http://jqueryui.com/{plugin}-effect/", docs: "http://api.jqueryui.com/{plugin}-effect/", - dependencies: [ "effect" ], - file: "ui.effect-{plugin}" + dependencies: [ "effect" ] } }; @@ -70,7 +69,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( manifest.dependencies[ "ui." + dependency ] = pkg.version; }); - grunt.file.write( replace( baseManifest.file || "ui.{plugin}" ) + ".jquery.json", + grunt.file.write( manifest.name + ".jquery.json", JSON.stringify( manifest, null, "\t" ) ); }); }); From 44dda079c0d632ffc97e08a0cc63dc3db0f459a9 Mon Sep 17 00:00:00 2001 From: Karl Swedberg Date: Wed, 11 Jul 2012 08:59:03 -0400 Subject: [PATCH 05/47] Update descriptions of UI components in manifest files. --- build/core.json | 6 +++--- build/effects.json | 22 +++++++++++----------- build/widgets.json | 30 +++++++++++++++--------------- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/build/core.json b/build/core.json index 366abf8e1..5273ebf7a 100644 --- a/build/core.json +++ b/build/core.json @@ -6,7 +6,7 @@ "docs": "http://api.jqueryui.com/category/ui-core" }, "datepicker": { - "description": "A datepicker than can be toggled from a input or displayed inline.", + "description": "Displays a calendar from an input or inline for selecting dates.", "dependencies": [ "core" ], "keywords": [ "form", @@ -17,7 +17,7 @@ }, "effect": { "title": "jQuery UI Effects Core", - "description": "Extends the internal jQuery effects, includes morphing, easing and is required by all other effects.", + "description": "Extends the internal jQuery effects. Includes morphing and easing. Required by all other effects.", "keywords": [ "animation", "show", @@ -32,7 +32,7 @@ "docs": "http://api.jqueryui.com/category/effects-core" }, "position": { - "description": "A utility plugin for positioning elements relative to other elements.", + "description": "Positions elements relative to other elements.", "keywords": [ "offset", "relative", diff --git a/build/effects.json b/build/effects.json index ef69ef82b..b35bbb371 100644 --- a/build/effects.json +++ b/build/effects.json @@ -3,39 +3,39 @@ "description": "Blinds the element." }, "bounce": { - "description": "Bounces an element horizontally or vertically n-times." + "description": "Bounces an element horizontally or vertically n times." }, "clip": { "description": "Clips the element on and off like an old TV." }, "drop": { - "description": "A Drop out effect by moving the element in one direction and hiding it at the same time." + "description": "Moves an element in one direction and hides it at the same time." }, "explode": { - "description": "The element explodes in all directions into n pieces. Also supports imploding again." + "description": "Explodes an element in all directions into n pieces. Implodes an element to its original wholeness." }, "fade": { - "description": "Fades the element." + "description": "Fades an element." }, "fold": { - "description": "Folds the element first horizontally and then vertically." + "description": "Folds an element first horizontally and then vertically." }, "highlight": { - "description": "Highlights the background of the element in a defined color for a custom duration." + "description": "Highlights the background of an element in a defined color for a custom duration." }, "pulsate": { - "description": "The element pulsates n times by changing the opacity to zero and back." + "description": "Pulsates an element n times by changing the opacity to zero and back." }, "scale": { - "description": "Grow or shrink any element and its content and restore it again." + "description": "Grows or shrinks an element and its content. Restores an elemnt to its original size." }, "shake": { - "description": "Shakes the element horizontally or vertically n times." + "description": "Shakes an element horizontally or vertically n times." }, "slide": { - "description": "The element slides in and out of the viewport." + "description": "Slides an element in and out of the viewport." }, "transfer": { - "description": "Transfer effect from one element to another." + "description": "Displays a transfer effect from one element to another." } } diff --git a/build/widgets.json b/build/widgets.json index e39b046a4..b518e6d0b 100644 --- a/build/widgets.json +++ b/build/widgets.json @@ -1,7 +1,7 @@ { "accordion": { "dependencies": [], - "description": "Collapsable content panels for displaying information in a limited amount of space.", + "description": "Displays collapsable content panels for presenting information in a limited amount of space.", "keywords": [ "navigation", "panel", @@ -11,7 +11,7 @@ }, "autocomplete": { "dependencies": [ "menu", "position" ], - "description": "Provides a list of suggested words as the user is typing.", + "description": "Lists suggested words as the user is typing.", "keywords": [ "form", "word", @@ -21,7 +21,7 @@ }, "button": { "dependencies": [], - "description": "Enhance your forms with themable buttons.", + "description": "Enhances a form with themable buttons.", "keywords": [ "form", "radio", @@ -30,7 +30,7 @@ }, "dialog": { "dependencies": [ "button", "draggable", "position", "resizable" ], - "description": "Customizable dialog windows.", + "description": "Displays customizable dialog windows.", "keywords": [ "modal", "alert", @@ -39,7 +39,7 @@ }, "draggable": { "dependencies": [ "mouse" ], - "description": "Enable dragging functionality for any element.", + "description": "Enables dragging functionality for any element.", "keywords": [ "drag", "drop" @@ -47,7 +47,7 @@ }, "droppable": { "dependencies": [ "draggable", "mouse" ], - "description": "Create drop targets for draggable elements.", + "description": "Enables drop targets for draggable elements.", "keywords": [ "drag", "drop" @@ -55,7 +55,7 @@ }, "menu": { "dependencies": [ "position" ], - "description": "Easily create nestable menus.", + "description": "Creates nestable menus.", "keywords": [ "dropdown", "flyout" @@ -63,14 +63,14 @@ }, "mouse": { "dependencies": [], - "description": "An abstraction for any mouse-based interactions.", + "description": "Abstracts mouse-based interactions to assist in creating certain widgets.", "keywords": [ "abstraction" ] }, "progressbar": { "dependencies": [], - "description": "A status indicator that can be used for a loading state and standard percentage indicators.", + "description": "Displays a status indicator for loading state, standard percentage, and other progress indicators.", "keywords": [ "determinate", "status" @@ -78,21 +78,21 @@ }, "resizable": { "dependencies": [ "mouse" ], - "description": "Enable resize functioality for any element.", + "description": "Enables resize functionality for any element.", "keywords": [ "resize" ] }, "selectable": { "dependencies": [ "mouse" ], - "description": "Create groups of elements that can be selected with the mouse.", + "description": "Allows groups of elements to be selected with the mouse.", "keywords": [ "selection" ] }, "slider": { "dependencies": [ "mouse" ], - "description": "A flexible slider with ranges and accessibility via keyboard.", + "description": "Displays a flexible slider with ranges and accessibility via keyboard.", "keywords": [ "form", "number", @@ -101,7 +101,7 @@ }, "sortable": { "dependencies": [ "mouse" ], - "description": "Sort items in a list using the mouse.", + "description": "Enables items in a list to be sorted using the mouse.", "keywords": [ "sort", "list" @@ -109,7 +109,7 @@ }, "spinner": { "dependencies": [ "button" ], - "description": "Easily input numbers via the keyboard or mouse.", + "description": "Displays buttons to easily input numbers via the keyboard or mouse.", "keywords": [ "form", "number", @@ -129,7 +129,7 @@ }, "tooltip": { "dependencies": [ "position" ], - "description": "Show additional information for any element on hover or focus.", + "description": "Shows additional information for any element on hover or focus.", "keywords": [] } } From b8ad711deedab11da1f181b486ee67f259a3ef7c Mon Sep 17 00:00:00 2001 From: kborchers Date: Thu, 12 Jul 2012 22:45:56 -0500 Subject: [PATCH 06/47] Menu: Add a flag and remove previous attempt to prevent select events from being fired by click events bubbling up through nested menus --- ui/jquery.ui.menu.js | 36 ++++++++++++++---------------------- 1 file changed, 14 insertions(+), 22 deletions(-) diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index 81fef2e7c..e8b8ed1fc 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -15,7 +15,7 @@ */ (function( $, undefined ) { -var currentEventTarget = null; +var mouseHandled = false; $.widget( "ui.menu", { version: "@VERSION", @@ -73,24 +73,16 @@ $.widget( "ui.menu", { }, "click .ui-menu-item:has(a)": function( event ) { var target = $( event.target ); - if ( target[0] !== currentEventTarget ) { - currentEventTarget = target[0]; - // TODO: What are we trying to accomplish with this check? - // Clicking a menu item twice results in a select event with - // an empty ui.item. - target.one( "click" + this.eventNamespace, function( event ) { - currentEventTarget = null; - }); - // Don't select disabled menu items - if ( !target.closest( ".ui-menu-item" ).is( ".ui-state-disabled" ) ) { - this.select( event ); - // Redirect focus to the menu with a delay for firefox - this._delay(function() { - if ( !this.element.is(":focus") ) { - this.element.focus(); - } - }, 20 ); - } + if ( !mouseHandled && target.closest( ".ui-menu-item" ).not( ".ui-state-disabled" ).length ) { + mouseHandled = true; + + this.select( event ); + // Redirect focus to the menu with a delay for firefox + this._delay(function() { + if ( !this.element.is(":focus") ) { + this.element.focus(); + } + }, 20 ); } }, "mouseenter .ui-menu-item": function( event ) { @@ -127,6 +119,9 @@ $.widget( "ui.menu", { if ( !$( event.target ).closest( ".ui-menu" ).length ) { this.collapseAll( event ); } + + // Reset the mouseHandled flag + mouseHandled = false; } }); }, @@ -166,9 +161,6 @@ $.widget( "ui.menu", { // Destroy menu dividers this.element.find( ".ui-menu-divider" ).removeClass( "ui-menu-divider ui-widget-content" ); - - // Unbind currentEventTarget click event handler - this._off( $( currentEventTarget ), "click" ); }, _keydown: function( event ) { From be0be892d3a2658f1f4518a7d3346ef356aa89c6 Mon Sep 17 00:00:00 2001 From: kborchers Date: Thu, 12 Jul 2012 23:01:13 -0500 Subject: [PATCH 07/47] Menu: Fix issue with missing active item when clicking a menu item more than once --- ui/jquery.ui.menu.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index e8b8ed1fc..be04fff1c 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -583,7 +583,8 @@ $.widget( "ui.menu", { select: function( event ) { // Save active reference before collapseAll triggers blur var ui = { - item: this.active + // Selecting a menu item removes the active item causing multiple clicks to be missing an item + item: this.active || $( event.target ).closest( ".ui-menu-item" ) }; this.collapseAll( event, true ); this._trigger( "select", event, ui ); From 5eb1aeec4ebba7f1366f355331664098e42dfe49 Mon Sep 17 00:00:00 2001 From: kborchers Date: Fri, 13 Jul 2012 13:36:00 -0500 Subject: [PATCH 08/47] Menu: Remove unnecessary click delay and change focus delay for AT to the default delay --- ui/jquery.ui.menu.js | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index be04fff1c..75cfac40b 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -77,12 +77,10 @@ $.widget( "ui.menu", { mouseHandled = true; this.select( event ); - // Redirect focus to the menu with a delay for firefox - this._delay(function() { - if ( !this.element.is(":focus") ) { - this.element.focus(); - } - }, 20 ); + // Redirect focus to the menu + if ( !this.element.is(":focus") ) { + this.element.focus(); + } } }, "mouseenter .ui-menu-item": function( event ) { @@ -488,7 +486,7 @@ $.widget( "ui.menu", { // Delay so Firefox will not hide activedescendant change in expanding submenu from AT this._delay(function() { this.focus( event, newItem ); - }, 20 ); + }); } }, From b073cda1a5939e79bba1e27df77b7f77d4b29abf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Fri, 13 Jul 2012 15:52:32 -0400 Subject: [PATCH 09/47] Dialog tests: Fixed calls to $.contains() that were passing jQuery objects instead of elements. --- tests/unit/dialog/dialog_tickets.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/unit/dialog/dialog_tickets.js b/tests/unit/dialog/dialog_tickets.js index 201ea3a87..5c3277c2f 100644 --- a/tests/unit/dialog/dialog_tickets.js +++ b/tests/unit/dialog/dialog_tickets.js @@ -10,7 +10,7 @@ asyncTest( "#3123: Prevent tabbing out of modal dialogs", function() { var el = $( "
" ).dialog({ modal: true }), inputs = el.find( "input" ), - widget = el.dialog( "widget" ); + widget = el.dialog( "widget" )[ 0 ]; function checkTab() { ok( $.contains( widget, document.activeElement ), "Tab key event moved focus within the modal" ); From cd82b335a8d6029481383b3da3d920f0658acaf0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Zaefferer?= Date: Mon, 16 Jul 2012 14:08:10 +0200 Subject: [PATCH 10/47] Manifest: Add category field --- build/core.json | 4 +++- build/tasks/build.js | 10 +++++++--- build/widgets.json | 3 ++- 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/build/core.json b/build/core.json index 5273ebf7a..aac41f7aa 100644 --- a/build/core.json +++ b/build/core.json @@ -13,7 +13,8 @@ "calendar", "date", "i18n" - ] + ], + "category": "widget" }, "effect": { "title": "jQuery UI Effects Core", @@ -27,6 +28,7 @@ "transition", "easing" ], + "category": "effect", "homepage": "http://jqueryui.com/", "demo": "http://jqueryui.com/", "docs": "http://api.jqueryui.com/category/effects-core" diff --git a/build/tasks/build.js b/build/tasks/build.js index 5dff38f6a..d1211f60b 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -8,12 +8,14 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( base = { core: { name: "ui.{plugin}", - title: "jQuery UI {Plugin}" + title: "jQuery UI {Plugin}", + category: "core" }, widgets: { name: "ui.{plugin}", title: "jQuery UI {Plugin}", - dependencies: [ "core", "widget" ] + dependencies: [ "core", "widget" ], + category: "widget" }, effects: { name: "ui.effect-{plugin}", @@ -22,7 +24,8 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( homepage: "http://jqueryui.com/{plugin}-effect/", demo: "http://jqueryui.com/{plugin}-effect/", docs: "http://api.jqueryui.com/{plugin}-effect/", - dependencies: [ "effect" ] + dependencies: [ "effect" ], + category: "effect" } }; @@ -46,6 +49,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( keywords: [ "ui", plugin ] .concat( baseManifest.keywords || [] ) .concat( data.keywords || [] ), + category: data.category || baseManifest.category, version: pkg.version, author: pkg.author, maintainers: pkg.maintainers, diff --git a/build/widgets.json b/build/widgets.json index b518e6d0b..9c70726ea 100644 --- a/build/widgets.json +++ b/build/widgets.json @@ -66,7 +66,8 @@ "description": "Abstracts mouse-based interactions to assist in creating certain widgets.", "keywords": [ "abstraction" - ] + ], + "category": "core" }, "progressbar": { "dependencies": [], From 2e385a71e17138a95a9fd2c66049d51206e1e2f8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 16 Jul 2012 08:37:53 -0400 Subject: [PATCH 11/47] Manifests: Fixed typo. --- build/widgets.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/widgets.json b/build/widgets.json index 9c70726ea..12993e828 100644 --- a/build/widgets.json +++ b/build/widgets.json @@ -1,7 +1,7 @@ { "accordion": { "dependencies": [], - "description": "Displays collapsable content panels for presenting information in a limited amount of space.", + "description": "Displays collapsible content panels for presenting information in a limited amount of space.", "keywords": [ "navigation", "panel", From ac44afe4e864aec8e420d7f9ba806be45be1e833 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 16 Jul 2012 08:50:00 -0400 Subject: [PATCH 12/47] Manifest: Use existing data structure to infer categorization. --- build/{effects.json => effect.json} | 0 build/tasks/build.js | 18 ++++++++---------- build/{widgets.json => widget.json} | 0 3 files changed, 8 insertions(+), 10 deletions(-) rename build/{effects.json => effect.json} (100%) rename build/{widgets.json => widget.json} (100%) diff --git a/build/effects.json b/build/effect.json similarity index 100% rename from build/effects.json rename to build/effect.json diff --git a/build/tasks/build.js b/build/tasks/build.js index d1211f60b..1e1795230 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -8,24 +8,21 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( base = { core: { name: "ui.{plugin}", - title: "jQuery UI {Plugin}", - category: "core" + title: "jQuery UI {Plugin}" }, - widgets: { + widget: { name: "ui.{plugin}", title: "jQuery UI {Plugin}", - dependencies: [ "core", "widget" ], - category: "widget" + dependencies: [ "core", "widget" ] }, - effects: { + effect: { name: "ui.effect-{plugin}", title: "jQuery UI {Plugin} Effect", keywords: [ "effect", "show", "hide" ], homepage: "http://jqueryui.com/{plugin}-effect/", demo: "http://jqueryui.com/{plugin}-effect/", docs: "http://api.jqueryui.com/{plugin}-effect/", - dependencies: [ "effect" ], - category: "effect" + dependencies: [ "effect" ] } }; @@ -49,7 +46,6 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( keywords: [ "ui", plugin ] .concat( baseManifest.keywords || [] ) .concat( data.keywords || [] ), - category: data.category || baseManifest.category, version: pkg.version, author: pkg.author, maintainers: pkg.maintainers, @@ -64,7 +60,9 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( download: "http://jqueryui.com/download/", dependencies: { jquery: ">=1.6" - } + }, + // custom + category: data.category || type }; (baseManifest.dependencies || []) diff --git a/build/widgets.json b/build/widget.json similarity index 100% rename from build/widgets.json rename to build/widget.json From 58a199370ed33e71257e863897e29c36fc593316 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 16 Jul 2012 08:53:34 -0400 Subject: [PATCH 13/47] Manifest: Move interactions to their own file. --- build/interaction.json | 36 ++++++++++++++++++++++++++++++++++++ build/tasks/build.js | 5 +++++ build/widget.json | 38 -------------------------------------- 3 files changed, 41 insertions(+), 38 deletions(-) create mode 100644 build/interaction.json diff --git a/build/interaction.json b/build/interaction.json new file mode 100644 index 000000000..d964c4ac3 --- /dev/null +++ b/build/interaction.json @@ -0,0 +1,36 @@ +{ + "draggable": { + "description": "Enables dragging functionality for any element.", + "keywords": [ + "drag", + "drop" + ] + }, + "droppable": { + "dependencies": [ "draggable" ], + "description": "Enables drop targets for draggable elements.", + "keywords": [ + "drag", + "drop" + ] + }, + "resizable": { + "description": "Enables resize functionality for any element.", + "keywords": [ + "resize" + ] + }, + "selectable": { + "description": "Allows groups of elements to be selected with the mouse.", + "keywords": [ + "selection" + ] + }, + "sortable": { + "description": "Enables items in a list to be sorted using the mouse.", + "keywords": [ + "sort", + "list" + ] + } +} \ No newline at end of file diff --git a/build/tasks/build.js b/build/tasks/build.js index 1e1795230..cc663309b 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -15,6 +15,11 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( title: "jQuery UI {Plugin}", dependencies: [ "core", "widget" ] }, + interaction: { + name: "ui.{plugin}", + title: "jQuery UI {Plugin}", + dependencies: [ "core", "widget", "mouse" ] + }, effect: { name: "ui.effect-{plugin}", title: "jQuery UI {Plugin} Effect", diff --git a/build/widget.json b/build/widget.json index 12993e828..6adddb121 100644 --- a/build/widget.json +++ b/build/widget.json @@ -37,22 +37,6 @@ "popup" ] }, - "draggable": { - "dependencies": [ "mouse" ], - "description": "Enables dragging functionality for any element.", - "keywords": [ - "drag", - "drop" - ] - }, - "droppable": { - "dependencies": [ "draggable", "mouse" ], - "description": "Enables drop targets for draggable elements.", - "keywords": [ - "drag", - "drop" - ] - }, "menu": { "dependencies": [ "position" ], "description": "Creates nestable menus.", @@ -77,20 +61,6 @@ "status" ] }, - "resizable": { - "dependencies": [ "mouse" ], - "description": "Enables resize functionality for any element.", - "keywords": [ - "resize" - ] - }, - "selectable": { - "dependencies": [ "mouse" ], - "description": "Allows groups of elements to be selected with the mouse.", - "keywords": [ - "selection" - ] - }, "slider": { "dependencies": [ "mouse" ], "description": "Displays a flexible slider with ranges and accessibility via keyboard.", @@ -100,14 +70,6 @@ "range" ] }, - "sortable": { - "dependencies": [ "mouse" ], - "description": "Enables items in a list to be sorted using the mouse.", - "keywords": [ - "sort", - "list" - ] - }, "spinner": { "dependencies": [ "button" ], "description": "Displays buttons to easily input numbers via the keyboard or mouse.", From 0a1cd9501c01b92a7f007cea1040f50ef4997400 Mon Sep 17 00:00:00 2001 From: TJ VanToll Date: Sun, 15 Jul 2012 07:07:38 -0400 Subject: [PATCH 14/47] Spinner: Trivial spelling fix in demo. --- demos/spinner/currency.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/demos/spinner/currency.html b/demos/spinner/currency.html index ff51b0177..a52f187c1 100644 --- a/demos/spinner/currency.html +++ b/demos/spinner/currency.html @@ -52,7 +52,7 @@
-

Example of a donation form, with currency selection and amout spinner.

+

Example of a donation form, with currency selection and amount spinner.

From dcea4f043adc7f37674feead31ded148d311ab72 Mon Sep 17 00:00:00 2001 From: Baoju Yuan Date: Mon, 16 Jul 2012 10:26:02 -0400 Subject: [PATCH 15/47] Sortable: Reset fromOutside property when canceling helper removal. Fixes #8430 - draggable with sortable makes sortable event receive triggered wrong. --- ui/jquery.ui.sortable.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ui/jquery.ui.sortable.js b/ui/jquery.ui.sortable.js index 7e5875200..db24fed38 100644 --- a/ui/jquery.ui.sortable.js +++ b/ui/jquery.ui.sortable.js @@ -1030,6 +1030,8 @@ $.widget("ui.sortable", $.ui.mouse, { for (var i=0; i < delayedTriggers.length; i++) { delayedTriggers[i].call(this, event); }; //Trigger all delayed events this._trigger("stop", event, this._uiHash()); } + + this.fromOutside = false; return false; } From 328cccdd17f33760b0e5c0a1907655778f91704d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Zaefferer?= Date: Mon, 16 Jul 2012 18:47:43 +0200 Subject: [PATCH 16/47] Manifest: Give interactions their own category --- build/widgets.json | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/build/widgets.json b/build/widgets.json index 9c70726ea..e416880fd 100644 --- a/build/widgets.json +++ b/build/widgets.json @@ -43,7 +43,8 @@ "keywords": [ "drag", "drop" - ] + ], + "category": "interaction" }, "droppable": { "dependencies": [ "draggable", "mouse" ], @@ -51,7 +52,8 @@ "keywords": [ "drag", "drop" - ] + ], + "category": "interaction" }, "menu": { "dependencies": [ "position" ], @@ -82,14 +84,16 @@ "description": "Enables resize functionality for any element.", "keywords": [ "resize" - ] + ], + "category": "interaction" }, "selectable": { "dependencies": [ "mouse" ], "description": "Allows groups of elements to be selected with the mouse.", "keywords": [ "selection" - ] + ], + "category": "interaction" }, "slider": { "dependencies": [ "mouse" ], @@ -106,7 +110,8 @@ "keywords": [ "sort", "list" - ] + ], + "category": "interaction" }, "spinner": { "dependencies": [ "button" ], From c484bc093bf69c23aed79cb951c8898aaec8331f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 16 Jul 2012 15:14:42 -0400 Subject: [PATCH 17/47] Manifest: Move transfer effect to core.json since it's not like other effects (no show/hide). --- build/core.json | 13 +++++++++++++ build/effect.json | 3 --- build/tasks/build.js | 2 +- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/build/core.json b/build/core.json index aac41f7aa..b0ccdfe7a 100644 --- a/build/core.json +++ b/build/core.json @@ -43,6 +43,19 @@ "collision" ] }, + "transfer": { + "name": "ui.effect-transfer", + "title": "jQuery UI Transfer Effect", + "description": "Displays a transfer effect from one element to another.", + "keywords": [ + "effect" + ], + "homepage": "http://jqueryui.com/transfer-effect/", + "demo": "http://jqueryui.com/transfer-effect/", + "docs": "http://api.jqueryui.com/transfer-effect/", + "dependencies": [ "effect" ], + "category": "effect" + }, "widget": { "description": "Provides a factory for creating stateful widgets with a common API.", "keywords": [ diff --git a/build/effect.json b/build/effect.json index b35bbb371..7119f85bc 100644 --- a/build/effect.json +++ b/build/effect.json @@ -34,8 +34,5 @@ }, "slide": { "description": "Slides an element in and out of the viewport." - }, - "transfer": { - "description": "Displays a transfer effect from one element to another." } } diff --git a/build/tasks/build.js b/build/tasks/build.js index cc663309b..9608bdfff 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -45,7 +45,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( } manifest = { - name: replace( baseManifest.name ), + name: data.name || replace( baseManifest.name ), title: data.title || replace( baseManifest.title ), description: data.description, keywords: [ "ui", plugin ] From 99c4dde13059ee8ba6cd4ea18ec121a631896496 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 16 Jul 2012 15:29:13 -0400 Subject: [PATCH 18/47] Manifests: Update URLs for core files. --- build/core.json | 6 +++--- build/tasks/build.js | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/build/core.json b/build/core.json index b0ccdfe7a..deeb2e118 100644 --- a/build/core.json +++ b/build/core.json @@ -3,7 +3,7 @@ "description": "The core of jQuery UI, required for all interactions and widgets.", "homepage": "http://jqueryui.com/", "demo": "http://jqueryui.com/", - "docs": "http://api.jqueryui.com/category/ui-core" + "docs": "http://api.jqueryui.com/category/ui-core/" }, "datepicker": { "description": "Displays a calendar from an input or inline for selecting dates.", @@ -30,8 +30,8 @@ ], "category": "effect", "homepage": "http://jqueryui.com/", - "demo": "http://jqueryui.com/", - "docs": "http://api.jqueryui.com/category/effects-core" + "demo": "http://jqueryui.com/effects/", + "docs": "http://api.jqueryui.com/category/effects-core/" }, "position": { "description": "Positions elements relative to other elements.", diff --git a/build/tasks/build.js b/build/tasks/build.js index 9608bdfff..b746ad712 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -4,7 +4,6 @@ var path = require( "path" ); grunt.registerTask( "manifest", "Generate jquery.json manifest files", function() { var pkg = grunt.config( "pkg" ), - // TODO: URLs for UI core and effects core base = { core: { name: "ui.{plugin}", From f7b32d9a8fec3967b1bb5aafa9cda88cd83cc294 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Tue, 17 Jul 2012 14:08:16 -0400 Subject: [PATCH 19/47] Menu tests: Removed test for key handling when the element doens't have focus (illogical test). --- tests/unit/menu/menu_events.js | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/tests/unit/menu/menu_events.js b/tests/unit/menu/menu_events.js index 8eb8ee8c6..69ae2e14f 100644 --- a/tests/unit/menu/menu_events.js +++ b/tests/unit/menu/menu_events.js @@ -577,22 +577,4 @@ test( "handle keyboard navigation with spelling of menu items", function() { element.focus(); }); -asyncTest( "handle page up and page down before the menu has focus", function() { - expect( 1 ); - var element = $( "#menu1" ).menu({ - focus: function( event, ui ) { - log( $( event.target ).find( ".ui-state-focus" ).parent().index() ); - } - }); - - log( "keydown", true ); - element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_DOWN } ); - element.blur(); - setTimeout( function() { - element.simulate( "keydown", { keyCode: $.ui.keyCode.PAGE_UP } ); - equal( logOutput(), "keydown,0,0", "Page Up and Page Down bring initial focus to first item" ); - start(); - }, 500 ); -}); - })( jQuery ); From 174df61a6e9f50286f595b3fb6af4bd0a6450392 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Tue, 17 Jul 2012 15:04:16 -0400 Subject: [PATCH 20/47] Slider tests: Minor cleanup: added expect() calls, fixed left-over slider that was appended to body. --- tests/unit/slider/slider_core.js | 8 ++++++++ tests/unit/slider/slider_events.js | 6 ++---- tests/unit/slider/slider_methods.js | 19 +++++++------------ tests/unit/slider/slider_options.js | 6 +++++- 4 files changed, 22 insertions(+), 17 deletions(-) diff --git a/tests/unit/slider/slider_core.js b/tests/unit/slider/slider_core.js index e5f21ee1b..86a516875 100644 --- a/tests/unit/slider/slider_core.js +++ b/tests/unit/slider/slider_core.js @@ -16,6 +16,7 @@ function handle() { module("slider: core"); test("keydown HOME on handle sets value to min", function() { + expect( 2 ); el = $('
'); options = { max: 5, @@ -50,6 +51,7 @@ test("keydown HOME on handle sets value to min", function() { }); test("keydown END on handle sets value to max", function() { + expect( 2 ); el = $('
'); options = { max: 5, @@ -84,6 +86,7 @@ test("keydown END on handle sets value to max", function() { }); test("keydown PAGE_UP on handle increases value by 1/5 range, not greater than max", function() { + expect( 4 ); $.each(['horizontal', 'vertical'], function(i, orientation) { el = $('
'); options = { @@ -107,6 +110,7 @@ test("keydown PAGE_UP on handle increases value by 1/5 range, not greater than m }); test("keydown PAGE_DOWN on handle decreases value by 1/5 range, not less than min", function() { + expect( 4 ); $.each(['horizontal', 'vertical'], function(i, orientation) { el = $('
'); options = { @@ -130,6 +134,7 @@ test("keydown PAGE_DOWN on handle decreases value by 1/5 range, not less than mi }); test("keydown UP on handle increases value by step, not greater than max", function() { + expect( 4 ); el = $('
'); options = { max: 5, @@ -170,6 +175,7 @@ test("keydown UP on handle increases value by step, not greater than max", funct }); test("keydown RIGHT on handle increases value by step, not greater than max", function() { + expect( 4 ); el = $('
'); options = { max: 5, @@ -210,6 +216,7 @@ test("keydown RIGHT on handle increases value by step, not greater than max", fu }); test("keydown DOWN on handle decreases value by step, not less than min", function() { + expect( 4 ); el = $('
'); options = { max: 5, @@ -250,6 +257,7 @@ test("keydown DOWN on handle decreases value by step, not less than min", functi }); test("keydown LEFT on handle decreases value by step, not less than min", function() { + expect( 4 ); el = $('
'); options = { max: 5, diff --git a/tests/unit/slider/slider_events.js b/tests/unit/slider/slider_events.js index 9e39d2a3e..4d0896442 100644 --- a/tests/unit/slider/slider_events.js +++ b/tests/unit/slider/slider_events.js @@ -12,8 +12,7 @@ module( "slider: events" ); test( "mouse based interaction", function() { expect(4); - var el = $( "
" ) - .appendTo( "body" ) + var el = $( "#slider1" ) .slider({ start: function(event, ui) { equal( event.originalEvent.type, "mousedown", "start triggered by mousedown" ); @@ -37,8 +36,7 @@ test( "keyboard based interaction", function() { expect(3); // Test keyup at end of handle slide (keyboard) - var el = $( "
" ) - .appendTo( "body" ) + var el = $( "#slider1" ) .slider({ start: function(event, ui) { equal( event.originalEvent.type, "keydown", "start triggered by keydown" ); diff --git a/tests/unit/slider/slider_methods.js b/tests/unit/slider/slider_methods.js index 79f80e868..1a6b493c9 100644 --- a/tests/unit/slider/slider_methods.js +++ b/tests/unit/slider/slider_methods.js @@ -27,21 +27,14 @@ test("init", function() { }); test("destroy", function() { - $("
").appendTo('body').slider().slider("destroy").remove(); - ok(true, '.slider("destroy") called on element'); - - $([]).slider().slider("destroy").remove(); - ok(true, '.slider("destroy") called on empty collection'); - - $('
').appendTo('body').remove().slider().slider("destroy").remove(); - ok(true, '.slider("destroy") called on disconnected DOMElement'); - - var expected = $('
').slider(), - actual = expected.slider('destroy'); - equal(actual, expected, 'destroy is chainable'); + expect( 1 ); + domEqual( "#slider1", function() { + $( "#slider1" ).slider().slider( "destroy" ); + }); }); test("enable", function() { + expect( 5 ); var el, expected = $('
').slider(), actual = expected.slider('enable'); @@ -56,6 +49,7 @@ test("enable", function() { }); test("disable", function() { + expect( 5 ); var el, expected = $('
').slider(), actual = expected.slider('disable'); @@ -70,6 +64,7 @@ test("disable", function() { }); test("value", function() { + expect( 17 ); $([false, 'min', 'max']).each(function() { var el = $('
').slider({ range: this, diff --git a/tests/unit/slider/slider_options.js b/tests/unit/slider/slider_options.js index 09067a3e9..4d1983ec7 100644 --- a/tests/unit/slider/slider_options.js +++ b/tests/unit/slider/slider_options.js @@ -12,6 +12,7 @@ function handle() { module("slider: options"); test("max", function() { + expect( 2 ); el = $('
'); options = { @@ -30,6 +31,7 @@ test("max", function() { }); test("min", function() { + expect( 2 ); el = $('
'); options = { @@ -48,6 +50,7 @@ test("min", function() { }); test("orientation", function() { + expect( 6 ); el = $('
'); options = { @@ -92,6 +95,7 @@ test("orientation", function() { // value option/method: the value option is not restricted by min/max/step. // What is returned by the value method is restricted by min (>=), max (<=), and step (even multiple) test("step", function() { + expect( 9 ); var el = $('
').slider({ min: 0, value: 0, @@ -112,7 +116,7 @@ test("step", function() { el.slider("value", 19); equal( el.slider("value"), 20 ); -el = $('
').slider({ + el = $('
').slider({ min: 0, value: 0, step: 20, From 75105f612c80bac6f3e8150225fdf2da90ff2f33 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Tue, 17 Jul 2012 15:05:05 -0400 Subject: [PATCH 21/47] Slider tests: Fixed style checks for orientation test. --- tests/unit/slider/slider_options.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/unit/slider/slider_options.js b/tests/unit/slider/slider_options.js index 4d1983ec7..96d0d45d0 100644 --- a/tests/unit/slider/slider_options.js +++ b/tests/unit/slider/slider_options.js @@ -51,7 +51,7 @@ test("min", function() { test("orientation", function() { expect( 6 ); - el = $('
'); + el = $('#slider1'); options = { max: 2, @@ -65,7 +65,7 @@ test("orientation", function() { el.slider(options).slider("option", "orientation", "horizontal"); ok(el.is('.ui-slider-horizontal'), "horizontal slider has class .ui-slider-horizontal"); ok(!el.is('.ui-slider-vertical'), "horizontal slider does not have class .ui-slider-vertical"); - equal(handle().css('left'), percentVal + '%', "horizontal slider handle is positioned with left: %"); + equal(handle()[0].style.left, percentVal + '%', "horizontal slider handle is positioned with left: %"); el.slider('destroy'); @@ -81,7 +81,7 @@ test("orientation", function() { el.slider(options).slider("option", "orientation", "vertical"); ok(el.is('.ui-slider-vertical'), "vertical slider has class .ui-slider-vertical"); ok(!el.is('.ui-slider-horizontal'), "vertical slider does not have class .ui-slider-horizontal"); - equal(handle().css('bottom'), percentVal + '%', "vertical slider handle is positioned with bottom: %"); + equal(handle()[0].style.bottom, percentVal + '%', "vertical slider handle is positioned with bottom: %"); el.slider('destroy'); From b4ef2f7ebb1162f75d8fa3276d73e4746bcace84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20Mrozi=C5=84ski?= Date: Mon, 16 Jul 2012 13:09:52 +0200 Subject: [PATCH 22/47] Datepicker: Modified _updateDatepicker to not update display if updated instance is not current instance. Fixed #6814 - datepicker('setDate') incorrectly overwrites current display with two datepickers. --- ui/jquery.ui.datepicker.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 06db79ba7..4c260a1c8 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -708,6 +708,9 @@ $.extend(Datepicker.prototype, { /* Generate the date picker content. */ _updateDatepicker: function(inst) { + if ($.datepicker._curInst && inst != $.datepicker._curInst) { + return; + } this.maxRows = 4; //Reset the max number of rows being displayed (see #7043) var borders = $.datepicker._getBorders(inst.dpDiv); instActive = inst; // for delegate hover events From cb44dc6c2840a77fbb13a398910ca8818d6439e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maciej=20Mrozi=C5=84ski?= Date: Tue, 17 Jul 2012 16:16:27 -0400 Subject: [PATCH 23/47] Datepicker: Deleted z-index style on hidden input. Fixed #7449 - Datepicker dialog has a negative z-index. --- ui/jquery.ui.datepicker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 4c260a1c8..1b80e3bdb 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -309,7 +309,7 @@ $.extend(Datepicker.prototype, { this.uuid += 1; var id = 'dp' + this.uuid; this._dialogInput = $(''); + '" style="position: absolute; top: -100px; width: 0px;"/>'); this._dialogInput.keydown(this._doKeyDown); $('body').append(this._dialogInput); inst = this._dialogInst = this._newInst(this._dialogInput, false); From 147ec7bd624e631fe019973876ad587e85d112bf Mon Sep 17 00:00:00 2001 From: Luis Dalmolin Date: Mon, 16 Jul 2012 09:54:48 -0300 Subject: [PATCH 24/47] Datepicker: Fixed position problem when input is in a fixed element. Fixes #5626 - DatePicker doesn't work inside fixed div. --- ui/jquery.ui.datepicker.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 1b80e3bdb..692832d19 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -766,8 +766,8 @@ $.extend(Datepicker.prototype, { var dpHeight = inst.dpDiv.outerHeight(); var inputWidth = inst.input ? inst.input.outerWidth() : 0; var inputHeight = inst.input ? inst.input.outerHeight() : 0; - var viewWidth = document.documentElement.clientWidth + $(document).scrollLeft(); - var viewHeight = document.documentElement.clientHeight + $(document).scrollTop(); + var viewWidth = document.documentElement.clientWidth + (isFixed ? 0 : $(document).scrollLeft()); + var viewHeight = document.documentElement.clientHeight + (isFixed ? 0 : $(document).scrollTop()); offset.left -= (this._get(inst, 'isRTL') ? (dpWidth - inputWidth) : 0); offset.left -= (isFixed && offset.left == inst.input.offset().left) ? $(document).scrollLeft() : 0; From 763a111552e5c02befd72a03b08cfc9ed06b7855 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Tue, 17 Jul 2012 16:25:38 -0400 Subject: [PATCH 25/47] Update project description. --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index d48520264..1f8223a84 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "jquery-ui", "title": "jQuery UI", - "description": "Abstractions for low-level interaction and animation, advanced effects and high-level, themeable widgets, built on top of the jQuery JavaScript Library, that you can use to build highly interactive web applications.", + "description": "A curated set of user interface interactions, effects, widgets, and themes built on top of the jQuery JavaScript Library.", "version": "1.9.0pre", "homepage": "http://jqueryui.com", "author": { From ebc8210b1f78cb261c4109ef99f3596198780b83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 19 Jul 2012 17:14:47 -0400 Subject: [PATCH 26/47] Build: Add a newline at the end of manifest files. --- build/tasks/build.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tasks/build.js b/build/tasks/build.js index b746ad712..bbe63da2c 100644 --- a/build/tasks/build.js +++ b/build/tasks/build.js @@ -76,7 +76,7 @@ grunt.registerTask( "manifest", "Generate jquery.json manifest files", function( }); grunt.file.write( manifest.name + ".jquery.json", - JSON.stringify( manifest, null, "\t" ) ); + JSON.stringify( manifest, null, "\t" ) + "\n" ); }); }); }); From 6aa2fd89006786ce8a7f2e02cb77dbc0f3eca948 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 19 Jul 2012 17:18:03 -0400 Subject: [PATCH 27/47] Use tabs for package.json. --- package.json | 128 +++++++++++++++++++++++++-------------------------- 1 file changed, 64 insertions(+), 64 deletions(-) diff --git a/package.json b/package.json index 1f8223a84..1f3205192 100644 --- a/package.json +++ b/package.json @@ -1,66 +1,66 @@ { - "name": "jquery-ui", - "title": "jQuery UI", - "description": "A curated set of user interface interactions, effects, widgets, and themes built on top of the jQuery JavaScript Library.", - "version": "1.9.0pre", - "homepage": "http://jqueryui.com", - "author": { - "name": "jQuery Foundation and other contributors", - "url": "http://jqueryui.com" - }, - "maintainers": [ - { - "name": "Scott González", - "email": "scott.gonzalez@gmail.com", - "url": "http://scottgonzalez.com" - }, - { - "name": "Jörn Zaefferer", - "email": "joern.zaefferer@gmail.com", - "url": "http://bassistance.de" - }, - { - "name": "Richard D. Worth", - "email": "rdworth@gmail.com", - "url": "http://rdworth.org" - }, - { - "name": "Kris Borchers", - "email": "kris.borchers@gmail.com", - "url": "http://krisborchers.com" - }, - { - "name": "Corey Frang", - "email": "gnarf37@gmail.com", - "url": "http://gnarf.net" - } - ], - "repository": { - "type": "git", - "url": "git://github.com/jquery/jquery-ui.git" - }, - "bugs": "http://bugs.jqueryui.com/", - "licenses": [ - { - "type": "MIT", - "url": "http://www.opensource.org/licenses/MIT" - }, - { - "type": "GPL", - "url": "http://www.opensource.org/licenses/GPL-2.0" - } - ], - "dependencies": {}, - "devDependencies": { - "grunt": "~0.3.9", - "grunt-css": "0.2.0", - "grunt-compare-size": "0.1.4", - "grunt-html": "0.1.1", - "grunt-junit": "0.1.4", - "grunt-git-authors": "1.0.0", - "request": "2.9.153", - "rimraf": "2.0.1", - "testswarm": "0.2.3" - }, - "keywords": [] + "name": "jquery-ui", + "title": "jQuery UI", + "description": "A curated set of user interface interactions, effects, widgets, and themes built on top of the jQuery JavaScript Library.", + "version": "1.9.0pre", + "homepage": "http://jqueryui.com", + "author": { + "name": "jQuery Foundation and other contributors", + "url": "http://jqueryui.com" + }, + "maintainers": [ + { + "name": "Scott González", + "email": "scott.gonzalez@gmail.com", + "url": "http://scottgonzalez.com" + }, + { + "name": "Jörn Zaefferer", + "email": "joern.zaefferer@gmail.com", + "url": "http://bassistance.de" + }, + { + "name": "Richard D. Worth", + "email": "rdworth@gmail.com", + "url": "http://rdworth.org" + }, + { + "name": "Kris Borchers", + "email": "kris.borchers@gmail.com", + "url": "http://krisborchers.com" + }, + { + "name": "Corey Frang", + "email": "gnarf37@gmail.com", + "url": "http://gnarf.net" + } + ], + "repository": { + "type": "git", + "url": "git://github.com/jquery/jquery-ui.git" + }, + "bugs": "http://bugs.jqueryui.com/", + "licenses": [ + { + "type": "MIT", + "url": "http://www.opensource.org/licenses/MIT" + }, + { + "type": "GPL", + "url": "http://www.opensource.org/licenses/GPL-2.0" + } + ], + "dependencies": {}, + "devDependencies": { + "grunt": "~0.3.9", + "grunt-css": "0.2.0", + "grunt-compare-size": "0.1.4", + "grunt-html": "0.1.1", + "grunt-junit": "0.1.4", + "grunt-git-authors": "1.0.0", + "request": "2.9.153", + "rimraf": "2.0.1", + "testswarm": "0.2.3" + }, + "keywords": [] } From 6888cec62a98b05cc9f09167b2872e7bab180315 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 19 Jul 2012 19:50:38 -0400 Subject: [PATCH 28/47] Updated AUTHORS.txt. --- AUTHORS.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/AUTHORS.txt b/AUTHORS.txt index c2947b2b7..194d5cb60 100644 --- a/AUTHORS.txt +++ b/AUTHORS.txt @@ -194,3 +194,9 @@ Pavel Stetina Mike Stay Steven Roussey Mike Hollis +Lee Rowlands +Timmy Willison +Karl Swedberg +Baoju Yuan +Maciej Mroziński +Luis Dalmolin From f8bdd6e1927c0a08a7397ab57247c3d99cf6f1ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 19 Jul 2012 20:49:07 -0400 Subject: [PATCH 29/47] Build: New release script. --- build/release/prepare-release | 336 ------------------------------ build/release/release.js | 381 ++++++++++++++++++++++++++++++++++ 2 files changed, 381 insertions(+), 336 deletions(-) delete mode 100755 build/release/prepare-release create mode 100644 build/release/release.js diff --git a/build/release/prepare-release b/build/release/prepare-release deleted file mode 100755 index 91665e1eb..000000000 --- a/build/release/prepare-release +++ /dev/null @@ -1,336 +0,0 @@ -#!/bin/sh - -base_dir="`pwd`/jquery-ui-release" -repo_dir="$base_dir/jquery-ui" -release_dir="$repo_dir/build/release" - -github_repo="git@github.com:jquery/jquery-ui.git" -remote_cmd="ssh jqadmin@ui-dev.jquery.com /srv/dev.jqueryui.com/prepare-release" - - - -# -# Setup environment -# - -echo -echo "--------------------------" -echo "| SETTING UP ENVIRONMENT |" -echo "--------------------------" -echo - -mkdir $base_dir -cd $base_dir - -echo "Cloning repo from $github_repo..." -git clone $github_repo -cd $repo_dir - -echo -echo "Environment setup complete." -echo - - - -# -# Figure out which versions we're dealing with -# - -echo -echo "------------------------" -echo "| CALCULATING VERSIONS |" -echo "------------------------" -echo - -# NOTE: this will be different for minor and major releases -version=`$remote_cmd/get-latest-version` -major_minor=${version%.*} -point=${version##*.} -version_new="${major_minor}.$(($point + 1))" -version_next=`cat version.txt` - -echo "We are going from $version to $version_new." -echo "version.txt will be set to $version_next when complete." -echo "Press enter to continue, or ctrl+c to cancel." -read - - -# -# Generate shell for changelog -# - -echo -echo "------------------------" -echo "| GENERATING CHANGELOG |" -echo "------------------------" -echo - -echo "Creating shell for changelog..." -changelog_url="http:\/\/docs.jquery.com\/action\/edit\/UI\/Changelog\/$version_new" -`sed "s/CHANGELOG_URL/$changelog_url/" <$release_dir/changelog-shell >$base_dir/changelog` - - -# find all commits -echo "Adding commits to changelog..." -format_ticket='[http://dev.jqueryui.com/ticket/XXXX #XXXX]' -format_commit='[http://github.com/jquery/jquery-ui/commit/%H %h]' -format_full="* %s ($format_ticket, $format_commit)" -git whatchanged $version... --pretty=format:"$format_full" \ - -- ui themes demos build \ -| sed '/^:/ d' \ -| sed '/^$/ d' \ -| sed 's/\(Fixe[sd] #\)\([0-9][0-9]*\)\(.*\)\(XXXX #XXXX\)/Fixed #\2\3\2 #\2/' \ -| LC_ALL='C' sort -f \ ->> $base_dir/changelog - -# find all fixed tickets -echo "Adding Trac tickets to changelog..." -$remote_cmd/generate-changelog >> $base_dir/changelog - -echo -echo "Changelog complete." -echo - - - -# -# Generate list of contributors -# - -echo -echo "--------------------------" -echo "| GATHERING CONTRIBUTORS |" -echo "--------------------------" -echo - - -# find all committers and authors -echo "Adding commiters and authors..." -format_contributors='%aN%n%cN' -git whatchanged $version... --pretty=format:"$format_contributors" \ -| sed '/^:/ d' \ -| sed '/^$/ d' \ -> $base_dir/thankyou - -# find all reporters and commenters from Trac -echo "Adding reporters and commenters from Trac..." -$remote_cmd/generate-contributors >> $base_dir/thankyou - -# sort names -echo "Sorting contributors..." -LC_ALL='C' sort -f $base_dir/thankyou | uniq > $base_dir/_thankyou -mv $base_dir/_thankyou $base_dir/thankyou - -# find all people that were thanked -echo "Adding people thanked in commits..." -git whatchanged $version... \ -| grep -i thank \ ->> $base_dir/thankyou - -echo -echo "Find contributors from duplicates of fixed tickets and add them to:" -echo "$base_dir/thankyou" -echo "Press enter when done." -read - -echo -echo "Contributors list complete." -echo - - - -# -# Update version -# - -echo -echo "--------------------" -echo "| UPDATING VERSION |" -echo "--------------------" -echo - -echo "Updating version.txt to $version_new..." -echo $version_new > version.txt - -git commit -a -m "Tagging the $version_new release." -version_new_time=`git log -1 --pretty=format:"%ad"` -echo "Committed version.txt at $version_new_time..." - -echo "Tagging $version_new..." -git tag $version_new - -echo "Updating version.txt to $version_next..." -echo $version_next > version.txt - -git commit -a -m "Updating the master version to $version_next" -echo "Committed version.txt..." - -echo -echo "Version update complete." -echo - - - -# -# Push to GitHub -# - -echo -echo "---------------------" -echo "| PUSHING TO GITHUB |" -echo "---------------------" -echo - -echo "Please review the output and generated files as a sanity check." -echo "Press enter to continue or ctrl+c to abort." -read - -git push -git push --tags - -echo -echo "Push to GitHub complete." -echo - - - -# -# Update Trac -# - -echo -echo "-----------------" -echo "| UPDATING TRAC |" -echo "-----------------" -echo - -# TODO: automate this -# NOTE: this will be different for minor and major releases -milestone=`$remote_cmd/get-latest-milestone` - -# Create new milestrone and version -echo "$version_new was tagged at $version_new_time." -echo "Create and close the $version_new Milestone with the above date and time." -echo "Create the $version_new Version with the above date and time." -echo "Press enter when done." -read - -# Update milestone for all fixed tickets -echo "Change all $milestone fixed tickets to $version_new." -echo "Press enter when done." -read - -echo -echo "Trac updates complete." -echo - - - -# -# Build jQuery UI -# - -echo -echo "----------------------" -echo "| BUILDING JQUERY UI |" -echo "----------------------" -echo - -# check out the tagged version -echo "Checking out $version_new..." -git checkout $version_new -cd build - -# Update the link to the docs (never contains the patch version) -echo "Updating URL for API docs..." -sed "s/UI\/API\/\${release\.version}/UI\/API\/$major_minor/" build.xml >build.xml.tmp -mv build.xml.tmp build.xml - -# Run the build -echo "Running build..." -ant - -echo -echo "Build complete." -echo - - - -# -# Upload zip to Google Code -# - -echo -echo "----------------------" -echo "| UPDATE GOOGLE CODE |" -echo "----------------------" -echo - -echo "Upload zip to Google Code." -echo " http://code.google.com/p/jquery-ui/downloads/entry" -echo " Summary: jQuery UI $version_new (Source, demos, docs, themes, tests) STABLE" -echo " Labels: Featured, Type-Source, OpSys-All" -echo "Modify the previous release to no longer say STABLE at the end." -echo "Remove the featured label from the previous release." -echo "Press enter when done." -read - -echo -echo "Google Code update complete." -echo - - - -# -# Update SVN -# - -echo -echo "----------------" -echo "| UPDATING SVN |" -echo "----------------" -echo - -cd $base_dir -mkdir svn -cd svn - -echo "Checking out SVN tags..." -svn co --depth immediates https://jquery-ui.googlecode.com/svn/tags -cd tags - -echo "Unzipping build into tags/$version_new..." -unzip $repo_dir/build/dist/jquery-ui-$version_new.zip -mv jquery-ui-$version_new $version_new - -echo "Adding files to SVN..." -svn add $version_new - -echo "Setting svn:mime-type..." -find $version_new -name \*.js -exec svn propset svn:mime-type text/javascript {} \; -find $version_new -name \*.css -exec svn propset svn:mime-type text/css {} \; -find $version_new -name \*.html -exec svn propset svn:mime-type text/html {} \; -find $version_new -name \*.png -exec svn propset svn:mime-type image/png {} \; -find $version_new -name \*.gif -exec svn propset svn:mime-type image/gif {} \; - -# TODO: commit -echo -echo "svn commit with the following message:" -echo "Created $version_new tag from http://jquery-ui.googlecode.com/files/jquery-ui-$version_new.zip" -echo "Press enter when done." -read - -echo -echo "SVN update complete." -echo - - - -# -# Generate themes -# - - - - -# ruby -e 'puts File.read("thankyou").split("\n").join(", ")' > thankyou2 diff --git a/build/release/release.js b/build/release/release.js new file mode 100644 index 000000000..e86ebef71 --- /dev/null +++ b/build/release/release.js @@ -0,0 +1,381 @@ +#!/usr/bin/env node + +var baseDir, repoDir, prevVersion, newVersion, nextVersion, tagTime, + fs = require( "fs" ), + rnewline = /\r?\n/, + repo = "git@github.com:jquery/jquery-ui.git", + branch = "master"; + +walk([ + bootstrap, + + section( "setting up repo" ), + cloneRepo, + checkState, + + section( "calculating versions" ), + getVersions, + confirm, + + section( "tagging release" ), + tagRelease, + confirm, + pushRelease, + + section( "updating branch version" ), + updateBranchVersion, + confirm, + pushBranch, + + section( "generating changelog" ), + generateChangelog, + + section( "gathering contributors" ), + gatherContributors, + + section( "updating trac" ), + updateTrac, + confirm, + + section( "building release" ), + buildRelease +]); + + + + + +function cloneRepo() { + if ( test( "-d", baseDir ) ) { + abort( "The directory '" + baseDir + "' already exists." ); + } + + echo( "Cloning " + repo + "..." ); + git( "clone " + repo + " " + repoDir, "Error cloning repo." ); + cd( repoDir ); + + echo( "Checking out " + branch + " branch..." ); + git( "checkout " + branch, "Error checking out branch." ); + + echo( "Installing dependencies..." ); + if ( exec( "npm install" ).code !== 0 ) { + abort( "Error installing dependencies." ); + } +} + +function checkState() { + echo( "Checking AUTHORS.txt..." ); + var result, lastActualAuthor, + lastListedAuthor = cat( "AUTHORS.txt" ).trim().split( rnewline ).pop(); + + result = exec( "grunt authors", { silent: true }); + if ( result.code !== 0 ) { + abort( "Error getting list of authors." ); + } + lastActualAuthor = result.output.split( rnewline ).splice( -4, 1 )[ 0 ]; + + if ( lastListedAuthor !== lastActualAuthor ) { + echo( "Last listed author is " + lastListedAuthor + "." ); + echo( "Last actual author is " + lastActualAuthor + "." ); + abort( "Please update AUTHORS.txt." ); + } + + echo( "Last listed author (" + lastListedAuthor + ") is correct." ); +} + +function getVersions() { + // prevVersion, newVersion, nextVersion are defined in the parent scope + var parts, major, minor, patch, + currentVersion = readPackage().version; + + echo( "Validating current version..." ); + if ( currentVersion.substr( -3, 3 ) !== "pre" ) { + echo( "The current version is " + currentVersion + "." ); + abort( "The version must be a pre version." ); + } + + newVersion = currentVersion.substr( 0, currentVersion.length - 3 ); + parts = newVersion.split( "." ); + major = parseInt( parts[ 0 ], 10 ); + minor = parseInt( parts[ 1 ], 10 ); + patch = parseInt( parts[ 2 ], 10 ); + prevVersion = patch === 0 ? + [ major, minor - 1, 0 ].join( "." ) : + [ major, minor, patch - 1 ].join( "." ); + // TODO: Remove version hack after 1.9.0 release + if ( prevVersion === "1.8.0" ) { + prevVersion = "1.8"; + } + nextVersion = [ major, minor, patch + 1 ].join( "." ) + "pre"; + + echo( "We are going from " + prevVersion + " to " + newVersion + "." ); + echo( "After the release, the version will be " + nextVersion + "." ); +} + +function tagRelease() { + var pkg; + + echo( "Creating release branch..." ); + git( "checkout -b release", "Error creating release branch." ); + + echo( "Updating package.json..." ); + pkg = readPackage(); + pkg.version = newVersion; + pkg.licenses.forEach(function( license ) { + license.url = license.url.replace( "master", newVersion ); + }); + writePackage( pkg ); + + echo( "Generating manifest files..." ); + if ( exec( "grunt manifest" ).code !== 0 ) { + abort( "Error generating manifest files." ); + } + + echo( "Committing release artifacts..." ); + git( "add *.jquery.json", "Error adding manifest files to git." ); + git( "commit -am 'Tagging the " + newVersion + " release.'", + "Error committing release changes." ); + + echo( "Tagging release..." ); + git( "tag " + newVersion, "Error tagging " + newVersion + "." ); + tagTime = git( "log -1 --format='%ad'", "Error getting tag timestamp." ).trim(); + + echo(); + echo( "Please review the output and generated files as a sanity check." ); +} + +function pushRelease() { + echo( "Pushing release to GitHub..." ); + git( "push --tags", "Error pushing tags to GitHub." ); +} + +function updateBranchVersion() { + var pkg; + + echo( "Checking out " + branch + " branch..." ); + git( "checkout " + branch, "Error checking out " + branch + " branch." ); + + echo( "Updating package.json..." ); + pkg = readPackage(); + pkg.version = nextVersion; + writePackage( pkg ); + + echo( "Committing version update..." ); + git( "commit -am 'Updating the " + branch + " version to " + nextVersion + ".'", + "Error committing package.json." ); + + echo(); + echo( "Please review the output and generated files as a sanity check." ); +} + +function pushBranch() { + echo( "Pushing " + branch + " to GitHub..." ); + git( "push", "Error pushing to GitHub." ); +} + +function generateChangelog() { + var commits, + changelogPath = baseDir + "/changelog", + changelog = cat( "build/release/changelog-shell" ) + "\n", + fullFormat = "* %s (TICKETREF, [http://github.com/jquery/jquery-ui/commit/%H %h])"; + + echo ( "Adding commits..." ); + commits = gitLog( fullFormat ); + + echo( "Adding links to tickets..." ); + changelog += commits + // Add ticket references + .map(function( commit ) { + var tickets = []; + // TODO: Don't use .replace() since we're not actually replacing + commit.replace( /Fixe[sd] #(\d+)/g, function( match, ticket ) { + tickets.push( ticket ); + }); + return tickets.length ? + commit.replace( "TICKETREF", tickets.map(function( ticket ) { + return "[http://bugs.jqueryui.com/ticket/" + ticket + " #" + ticket + "]"; + }).join( ", " ) ) : + // Leave TICKETREF token in place so it's easy to find commits without tickets + commit; + }) + // Sort commits so that they're grouped by component + .sort() + .join( "\n" ) + "\n"; + + echo( "Adding Trac tickets..." ); + changelog += trac( "/query?milestone=" + newVersion + "&resolution=fixed" + + "&col=id&col=component&col=summary&order=component" ) + "\n"; + + fs.writeFileSync( changelogPath, changelog ); + echo( "Stored changelog in " + changelogPath + "." ); +} + +function gatherContributors() { + var contributors, + contributorsPath = baseDir + "/contributors"; + + echo( "Adding committers and authors..." ); + contributors = gitLog( "%aN%n%cN" ); + + echo( "Adding reporters and commenters from Trac..." ); + contributors = contributors.concat( + trac( "/report/22?V=" + newVersion + "&max=-1" ) + .split( rnewline ) + .slice( 1, -1 ) ); + + echo( "Sorting contributors..." ); + contributors = unique( contributors ).sort(function( a, b ) { + return a.toLowerCase() < b.toLowerCase() ? -1 : 1; + }); + + echo ( "Adding people thanked in commits..." ); + contributors = contributors.concat( + gitLog( "%b%n%s" ).filter(function( line ) { + return /thank/i.test( line ); + })); + + fs.writeFileSync( contributorsPath, contributors.join( "\n" ) ); + echo( "Stored contributors in " + contributorsPath + "." ); +} + +function updateTrac() { + echo( newVersion + " was tagged at " + tagTime + "." ); + echo( "Close the " + newVersion + " Milestone with the above date and time." ); + echo( "Create the " + newVersion + " Version with the above date and time." ); + echo( "Create a Milestone for the next minor release." ); +} + +function buildRelease() { + echo( "Checking out " + newVersion + "..." ); + git( "checkout " + newVersion, "Error checking out " + newVersion + "." ); + + echo( "Building release..." ); + if ( exec( "grunt release" ).code !== 0 ) { + abort( "Error building release." ); + } +} + + + + + +// ===== HELPER FUNCTIONS ====================================================== + +function git( command, errorMessage ) { + var result = exec( "git " + command ); + if ( result.code !== 0 ) { + abort( errorMessage ); + } + + return result.output; +} + +function gitLog( format ) { + var result = exec( "git log " + prevVersion + ".." + newVersion + " " + + "--format='" + format + "'", + { silent: true }); + + if ( result.code !== 0 ) { + abort( "Error getting git log." ); + } + + result = result.output.split( rnewline ); + if ( result[ result.length - 1 ] === "" ) { + result.pop(); + } + + return result; +} + +function trac( path ) { + var result = exec( "curl -s 'http://bugs.jqueryui.com" + path + "&format=tab'", + { silent: true }); + + if ( result.code !== 0 ) { + abort( "Error getting Trac data." ); + } + + return result.output; +} + +function unique( arr ) { + var obj = {}; + arr.forEach(function( item ) { + obj[ item ] = 1; + }); + return Object.keys( obj ); +} + +function readPackage() { + return JSON.parse( fs.readFileSync( repoDir + "/package.json" ) ); +} + +function writePackage( pkg ) { + fs.writeFileSync( repoDir + "/package.json", + JSON.stringify( pkg, null, "\t" ) + "\n" ); +} + +function bootstrap( fn ) { + require( "child_process" ).exec( "npm root -g", function( error, stdout ) { + if ( error ) { + console.log( error ); + return process.exit( 1 ); + } + + var rootDir = stdout.trim(); + require( rootDir + "/shelljs/global" ); + + baseDir = pwd() + "/__release"; + repoDir = baseDir + "/repo"; + + fn(); + }); +} + +function section( name ) { + var line = new Array( name.length + 5 ).join( "-" ); + return function() { + echo(); + // https://github.com/arturadib/shelljs/issues/20 + console.log( line ); + echo( "| " + name.toUpperCase() + " |" ); + console.log( line ); + echo(); + }; +} + +function prompt( fn ) { + process.stdin.once( "data", function( chunk ) { + process.stdin.pause(); + fn( chunk.toString().trim() ); + }); + process.stdin.resume(); +} + +function confirm( fn ) { + echo( "Press enter to continue, or ctrl+c to cancel." ); + prompt( fn ); +} + +function abort( msg ) { + echo( msg ); + echo( "Aborting." ); + exit( 1 ); +} + +function walk( methods ) { + var method = methods.shift(); + + function next( error ) { + if ( methods.length ) { + walk( methods ); + } + } + + if ( !method.length ) { + method(); + next(); + } else { + method( next ); + } +} From 4e3d31e1eeabaf311552b8496936122dae88b69f Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Fri, 20 Jul 2012 18:07:45 -0500 Subject: [PATCH 30/47] Effects: Fixing call to outerHeight/Width in drop effect for compat with 1.8 core --- ui/jquery.ui.effect-drop.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/jquery.ui.effect-drop.js b/ui/jquery.ui.effect-drop.js index 3246c09b0..674ef41ec 100644 --- a/ui/jquery.ui.effect-drop.js +++ b/ui/jquery.ui.effect-drop.js @@ -32,7 +32,7 @@ $.effects.effect.drop = function( o, done ) { el.show(); $.effects.createWrapper( el ); - distance = o.distance || el[ ref === "top" ? "outerHeight": "outerWidth" ]({ margin: true }) / 2; + distance = o.distance || el[ ref === "top" ? "outerHeight": "outerWidth" ]( true ) / 2; if ( show ) { el From 85d259483ebf9a9fddc3c3fb6b191f10d181a1ad Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Fri, 20 Jul 2012 18:35:32 -0500 Subject: [PATCH 31/47] Effects: Fixing bug in blind effect caused by 48659c64 - auto doesn't parse --- ui/jquery.ui.effect-blind.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/jquery.ui.effect-blind.js b/ui/jquery.ui.effect-blind.js index 7cc353525..a5c41325c 100644 --- a/ui/jquery.ui.effect-blind.js +++ b/ui/jquery.ui.effect-blind.js @@ -42,7 +42,7 @@ $.effects.effect.blind = function( o, done ) { }); distance = wrapper[ ref ](); - margin = parseFloat( wrapper.css( ref2 ) ); + margin = parseFloat( wrapper.css( ref2 ) ) || 0; animation[ ref ] = show ? distance : 0; if ( !motion ) { @@ -51,7 +51,7 @@ $.effects.effect.blind = function( o, done ) { .css( vertical ? "top" : "left", "auto" ) .css({ position: "absolute" }); - animation[ ref2 ] = show ? margin : distance + margin; + animation[ ref2 ] = show ? margin : distance + margin; } // start at 0 if we are showing From ed64ccfef4e39ca21152c42e75a5614e2488ae3f Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Fri, 20 Jul 2012 18:50:34 -0500 Subject: [PATCH 32/47] Effects: Fixing call to outerHeight/Width in slide effect for compat with 1.8 core --- ui/jquery.ui.effect-slide.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/ui/jquery.ui.effect-slide.js b/ui/jquery.ui.effect-slide.js index d61047b8b..134b058c7 100644 --- a/ui/jquery.ui.effect-slide.js +++ b/ui/jquery.ui.effect-slide.js @@ -29,9 +29,7 @@ $.effects.effect.slide = function( o, done ) { // Adjust $.effects.save( el, props ); el.show(); - distance = o.distance || el[ ref === "top" ? "outerHeight" : "outerWidth" ]({ - margin: true - }); + distance = o.distance || el[ ref === "top" ? "outerHeight" : "outerWidth" ]( true ); $.effects.createWrapper( el ).css({ overflow: "hidden" From cb41ec798ac945038bc2764329b264d48f61209c Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Mon, 23 Jul 2012 10:54:06 -0500 Subject: [PATCH 33/47] Build: Splitting Release Coverage build into three --- build/tasks/testswarm.js | 59 +++++++++++++++++--------------- demos/effect/default.html | 2 +- tests/visual/effects/all.html | 2 +- tests/visual/effects/effects.css | 4 +-- 4 files changed, 36 insertions(+), 31 deletions(-) diff --git a/build/tasks/testswarm.js b/build/tasks/testswarm.js index c0244ebad..d0ae556a8 100644 --- a/build/tasks/testswarm.js +++ b/build/tasks/testswarm.js @@ -1,31 +1,36 @@ /*jshint node: true */ module.exports = function( grunt ) { -var tests = { - "Accordion": "accordion/accordion.html", - "Accordion_deprecated": "accordion/accordion_deprecated.html", - "Autocomplete": "autocomplete/autocomplete.html", - "Button": "button/button.html", - "Core": "core/core.html", - //"datepicker/datepicker.html", - //"dialog/dialog.html", - //"draggable/draggable.html", - //"droppable/droppable.html", - "Effects": "effects/effects.html", - "Menu": "menu/menu.html", - "Position": "position/position.html", - "Position_deprecated": "position/position_deprecated.html", - "Progressbar": "progressbar/progressbar.html", - //"resizable/resizable.html", - //"selectable/selectable.html", - //"slider/slider.html", - //"sortable/sortable.html", - "Spinner": "spinner/spinner.html", - "Tabs": "tabs/tabs.html", - "Tabs_deprecated": "tabs/tabs_deprecated.html", - "Tooltip": "tooltip/tooltip.html", - "Widget": "widget/widget.html" -}; +var versions = { + "git": "git", + "1.7": "1.7 1.7.1 1.7.2", + "1.6": "1.6 1.6.1 1.6.2 1.6.3 1.6.4" + }, + tests = { + "Accordion": "accordion/accordion.html", + "Accordion_deprecated": "accordion/accordion_deprecated.html", + "Autocomplete": "autocomplete/autocomplete.html", + "Button": "button/button.html", + "Core": "core/core.html", + //"datepicker/datepicker.html", + //"dialog/dialog.html", + //"draggable/draggable.html", + //"droppable/droppable.html", + "Effects": "effects/effects.html", + "Menu": "menu/menu.html", + "Position": "position/position.html", + "Position_deprecated": "position/position_deprecated.html", + "Progressbar": "progressbar/progressbar.html", + //"resizable/resizable.html", + //"selectable/selectable.html", + //"slider/slider.html", + //"sortable/sortable.html", + "Spinner": "spinner/spinner.html", + "Tabs": "tabs/tabs.html", + "Tabs_deprecated": "tabs/tabs_deprecated.html", + "Tooltip": "tooltip/tooltip.html", + "Widget": "widget/widget.html" + }; function submit( commit, tests, configFile, done ) { var test, @@ -61,9 +66,9 @@ grunt.registerTask( "testswarm", function( commit, configFile ) { submit( commit, latestTests, configFile, this.async() ); }); -grunt.registerTask( "testswarm-multi-jquery", function( commit, configFile ) { +grunt.registerTask( "testswarm-multi-jquery", function( commit, configFile, minor ) { var allTests = {}; - "1.6 1.6.1 1.6.2 1.6.3 1.6.4 1.7 1.7.1 1.7.2 git".split(" ").forEach(function( version ) { + versions[ minor ].split(" ").forEach(function( version ) { for ( var test in tests ) { allTests[ test + "-" + version ] = tests[ test ] + "?nojshint=true&jquery=" + version; } diff --git a/demos/effect/default.html b/demos/effect/default.html index b8251d5be..1069c523f 100644 --- a/demos/effect/default.html +++ b/demos/effect/default.html @@ -4,7 +4,7 @@ jQuery UI Effects - Effect demo - + diff --git a/tests/visual/effects/all.html b/tests/visual/effects/all.html index 1797c5715..d075550a5 100644 --- a/tests/visual/effects/all.html +++ b/tests/visual/effects/all.html @@ -4,7 +4,7 @@ jQuery UI Effects Test Suite - + diff --git a/tests/visual/effects/effects.css b/tests/visual/effects/effects.css index 460019f24..8e9ee0ffd 100644 --- a/tests/visual/effects/effects.css +++ b/tests/visual/effects/effects.css @@ -1,8 +1,8 @@ body { margin: 1em; padding: 0; - background: #191919; - color: #fff; + background: #fff; + color: #000; } ul.effects { From 9fb9b6d65c30221f38b1ce15a943a74c0fb2a3c0 Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Mon, 23 Jul 2012 11:50:50 -0500 Subject: [PATCH 34/47] Build: Adding subtitles for release coverage builds to testswarm description --- build/tasks/testswarm.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/build/tasks/testswarm.js b/build/tasks/testswarm.js index d0ae556a8..60b6370d4 100644 --- a/build/tasks/testswarm.js +++ b/build/tasks/testswarm.js @@ -32,7 +32,7 @@ var versions = { "Widget": "widget/widget.html" }; -function submit( commit, tests, configFile, done ) { +function submit( commit, tests, configFile, version, done ) { var test, testswarm = require( "testswarm" ), config = grunt.file.readJSON( configFile ).jqueryui, @@ -49,7 +49,7 @@ function submit( commit, tests, configFile, done ) { }, { authUsername: config.authUsername, authToken: config.authToken, - jobName: 'jQuery UI commit #' + commit.substr( 0, 10 ) + '', + jobName: 'jQuery UI ' + version + '' + commit.substr( 0, 7 ) + '', runMax: config.runMax, "runNames[]": Object.keys(tests), "runUrls[]": testUrls, @@ -63,7 +63,7 @@ grunt.registerTask( "testswarm", function( commit, configFile ) { for ( test in tests ) { latestTests[ test ] = tests[ test ] + "?nojshint=true"; } - submit( commit, latestTests, configFile, this.async() ); + submit( commit, latestTests, configFile, "", this.async() ); }); grunt.registerTask( "testswarm-multi-jquery", function( commit, configFile, minor ) { @@ -73,7 +73,7 @@ grunt.registerTask( "testswarm-multi-jquery", function( commit, configFile, mino allTests[ test + "-" + version ] = tests[ test ] + "?nojshint=true&jquery=" + version; } }); - submit( commit, allTests, configFile, this.async() ); + submit( commit, allTests, configFile, minor + " core", this.async() ); }); }; From 3c2198b226ecfe1333bbf25869edd3439827aaa4 Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Mon, 23 Jul 2012 12:07:35 -0500 Subject: [PATCH 35/47] Tests: Fixining jquery include version --- demos/effect/default.html | 2 +- tests/visual/effects/all.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/demos/effect/default.html b/demos/effect/default.html index 1069c523f..b8251d5be 100644 --- a/demos/effect/default.html +++ b/demos/effect/default.html @@ -4,7 +4,7 @@ jQuery UI Effects - Effect demo - + diff --git a/tests/visual/effects/all.html b/tests/visual/effects/all.html index d075550a5..1797c5715 100644 --- a/tests/visual/effects/all.html +++ b/tests/visual/effects/all.html @@ -4,7 +4,7 @@ jQuery UI Effects Test Suite - + From 7f07f93c28a3139259f02f06772076881eb9c6e7 Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Mon, 23 Jul 2012 12:14:12 -0500 Subject: [PATCH 36/47] Build: Extra whitespace --- build/tasks/testswarm.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tasks/testswarm.js b/build/tasks/testswarm.js index 60b6370d4..759dfcb35 100644 --- a/build/tasks/testswarm.js +++ b/build/tasks/testswarm.js @@ -73,7 +73,7 @@ grunt.registerTask( "testswarm-multi-jquery", function( commit, configFile, mino allTests[ test + "-" + version ] = tests[ test ] + "?nojshint=true&jquery=" + version; } }); - submit( commit, allTests, configFile, minor + " core", this.async() ); + submit( commit, allTests, configFile, minor + " core ", this.async() ); }); }; From 97ec1ddbc6081c05b129be45e5bffc93fdeccec5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 23 Jul 2012 15:39:12 -0400 Subject: [PATCH 37/47] Build: Remove need to install shelljs globally for release script. Colorized output. --- build/release/release.js | 139 ++++++++++++++++++++++----------------- 1 file changed, 79 insertions(+), 60 deletions(-) diff --git a/build/release/release.js b/build/release/release.js index e86ebef71..7dada78c5 100644 --- a/build/release/release.js +++ b/build/release/release.js @@ -2,6 +2,9 @@ var baseDir, repoDir, prevVersion, newVersion, nextVersion, tagTime, fs = require( "fs" ), + path = require( "path" ), + // support: node <0.8 + existsSync = fs.existsSync || path.existsSync, rnewline = /\r?\n/, repo = "git@github.com:jquery/jquery-ui.git", branch = "master"; @@ -17,14 +20,18 @@ walk([ getVersions, confirm, - section( "tagging release" ), - tagRelease, - confirm, + section( "building release" ), + buildRelease, + + section( "pushing tag" ), + confirmReview, pushRelease, section( "updating branch version" ), updateBranchVersion, - confirm, + + section( "pushing " + branch ), + confirmReview, pushBranch, section( "generating changelog" ), @@ -35,10 +42,7 @@ walk([ section( "updating trac" ), updateTrac, - confirm, - - section( "building release" ), - buildRelease + confirm ]); @@ -46,21 +50,19 @@ walk([ function cloneRepo() { - if ( test( "-d", baseDir ) ) { - abort( "The directory '" + baseDir + "' already exists." ); - } - - echo( "Cloning " + repo + "..." ); + echo( "Cloning " + repo.cyan + "..." ); git( "clone " + repo + " " + repoDir, "Error cloning repo." ); cd( repoDir ); - echo( "Checking out " + branch + " branch..." ); + echo( "Checking out " + branch.cyan + " branch..." ); git( "checkout " + branch, "Error checking out branch." ); + echo(); echo( "Installing dependencies..." ); if ( exec( "npm install" ).code !== 0 ) { abort( "Error installing dependencies." ); } + echo(); } function checkState() { @@ -75,12 +77,12 @@ function checkState() { lastActualAuthor = result.output.split( rnewline ).splice( -4, 1 )[ 0 ]; if ( lastListedAuthor !== lastActualAuthor ) { - echo( "Last listed author is " + lastListedAuthor + "." ); - echo( "Last actual author is " + lastActualAuthor + "." ); + echo( "Last listed author is " + lastListedAuthor.red + "." ); + echo( "Last actual author is " + lastActualAuthor.green + "." ); abort( "Please update AUTHORS.txt." ); } - echo( "Last listed author (" + lastListedAuthor + ") is correct." ); + echo( "Last listed author (" + lastListedAuthor.cyan + ") is correct." ); } function getVersions() { @@ -90,7 +92,7 @@ function getVersions() { echo( "Validating current version..." ); if ( currentVersion.substr( -3, 3 ) !== "pre" ) { - echo( "The current version is " + currentVersion + "." ); + echo( "The current version is " + currentVersion.red + "." ); abort( "The version must be a pre version." ); } @@ -99,6 +101,10 @@ function getVersions() { major = parseInt( parts[ 0 ], 10 ); minor = parseInt( parts[ 1 ], 10 ); patch = parseInt( parts[ 2 ], 10 ); + // TODO: handle 2.0.0 + if ( minor === 0 ) { + abort( "This script is not smart enough to handle the 2.0.0 release." ); + } prevVersion = patch === 0 ? [ major, minor - 1, 0 ].join( "." ) : [ major, minor, patch - 1 ].join( "." ); @@ -108,15 +114,16 @@ function getVersions() { } nextVersion = [ major, minor, patch + 1 ].join( "." ) + "pre"; - echo( "We are going from " + prevVersion + " to " + newVersion + "." ); - echo( "After the release, the version will be " + nextVersion + "." ); + echo( "We are going from " + prevVersion.cyan + " to " + newVersion.cyan + "." ); + echo( "After the release, the version will be " + nextVersion.cyan + "." ); } -function tagRelease() { +function buildRelease() { var pkg; - echo( "Creating release branch..." ); + echo( "Creating " + "release".cyan + " branch..." ); git( "checkout -b release", "Error creating release branch." ); + echo(); echo( "Updating package.json..." ); pkg = readPackage(); @@ -130,18 +137,27 @@ function tagRelease() { if ( exec( "grunt manifest" ).code !== 0 ) { abort( "Error generating manifest files." ); } + echo(); + echo( "Building release..." ); + if ( exec( "grunt release" ).code !== 0 ) { + abort( "Error building release." ); + } + echo(); + + // TODO: Build themes + + // TODO: Move build out of dist/ echo( "Committing release artifacts..." ); git( "add *.jquery.json", "Error adding manifest files to git." ); + // TODO: Add built files git( "commit -am 'Tagging the " + newVersion + " release.'", "Error committing release changes." ); + echo(); echo( "Tagging release..." ); git( "tag " + newVersion, "Error tagging " + newVersion + "." ); tagTime = git( "log -1 --format='%ad'", "Error getting tag timestamp." ).trim(); - - echo(); - echo( "Please review the output and generated files as a sanity check." ); } function pushRelease() { @@ -152,7 +168,7 @@ function pushRelease() { function updateBranchVersion() { var pkg; - echo( "Checking out " + branch + " branch..." ); + echo( "Checking out " + branch.cyan + " branch..." ); git( "checkout " + branch, "Error checking out " + branch + " branch." ); echo( "Updating package.json..." ); @@ -163,13 +179,10 @@ function updateBranchVersion() { echo( "Committing version update..." ); git( "commit -am 'Updating the " + branch + " version to " + nextVersion + ".'", "Error committing package.json." ); - - echo(); - echo( "Please review the output and generated files as a sanity check." ); } function pushBranch() { - echo( "Pushing " + branch + " to GitHub..." ); + echo( "Pushing " + branch.cyan + " to GitHub..." ); git( "push", "Error pushing to GitHub." ); } @@ -187,7 +200,6 @@ function generateChangelog() { // Add ticket references .map(function( commit ) { var tickets = []; - // TODO: Don't use .replace() since we're not actually replacing commit.replace( /Fixe[sd] #(\d+)/g, function( match, ticket ) { tickets.push( ticket ); }); @@ -207,7 +219,7 @@ function generateChangelog() { "&col=id&col=component&col=summary&order=component" ) + "\n"; fs.writeFileSync( changelogPath, changelog ); - echo( "Stored changelog in " + changelogPath + "." ); + echo( "Stored changelog in " + changelogPath.cyan + "." ); } function gatherContributors() { @@ -221,6 +233,7 @@ function gatherContributors() { contributors = contributors.concat( trac( "/report/22?V=" + newVersion + "&max=-1" ) .split( rnewline ) + // Remove header and trailing newline .slice( 1, -1 ) ); echo( "Sorting contributors..." ); @@ -235,26 +248,16 @@ function gatherContributors() { })); fs.writeFileSync( contributorsPath, contributors.join( "\n" ) ); - echo( "Stored contributors in " + contributorsPath + "." ); + echo( "Stored contributors in " + contributorsPath.cyan + "." ); } function updateTrac() { - echo( newVersion + " was tagged at " + tagTime + "." ); - echo( "Close the " + newVersion + " Milestone with the above date and time." ); - echo( "Create the " + newVersion + " Version with the above date and time." ); + echo( newVersion.cyan + " was tagged at " + tagTime.cyan + "." ); + echo( "Close the " + newVersion.cyan + " Milestone with the above date and time." ); + echo( "Create the " + newVersion.cyan + " Version with the above date and time." ); echo( "Create a Milestone for the next minor release." ); } -function buildRelease() { - echo( "Checking out " + newVersion + "..." ); - git( "checkout " + newVersion, "Error checking out " + newVersion + "." ); - - echo( "Building release..." ); - if ( exec( "grunt release" ).code !== 0 ) { - abort( "Error building release." ); - } -} - @@ -316,30 +319,41 @@ function writePackage( pkg ) { } function bootstrap( fn ) { - require( "child_process" ).exec( "npm root -g", function( error, stdout ) { + console.log( "Determining directories..." ); + baseDir = process.cwd() + "/__release"; + repoDir = baseDir + "/repo"; + + if ( existsSync( baseDir ) ) { + console.log( "The directory '" + baseDir + "' already exists." ); + console.log( "Aborting." ); + process.exit( 1 ); + } + + console.log( "Creating directory..." ); + fs.mkdirSync( baseDir ); + + console.log( "Installing dependencies..." ); + require( "child_process" ).exec( "npm install shelljs colors", { + cwd: baseDir + }, function( error ) { if ( error ) { console.log( error ); return process.exit( 1 ); } - var rootDir = stdout.trim(); - require( rootDir + "/shelljs/global" ); - - baseDir = pwd() + "/__release"; - repoDir = baseDir + "/repo"; + require( baseDir + "/node_modules/shelljs/global" ); + require( baseDir + "/node_modules/colors" ); fn(); }); } function section( name ) { - var line = new Array( name.length + 5 ).join( "-" ); return function() { echo(); - // https://github.com/arturadib/shelljs/issues/20 - console.log( line ); - echo( "| " + name.toUpperCase() + " |" ); - console.log( line ); + echo( "##" ); + echo( "## " + name.toUpperCase().magenta ); + echo( "##" ); echo(); }; } @@ -353,13 +367,18 @@ function prompt( fn ) { } function confirm( fn ) { - echo( "Press enter to continue, or ctrl+c to cancel." ); + echo( "Press enter to continue, or ctrl+c to cancel.".yellow ); prompt( fn ); } +function confirmReview( fn ) { + echo( "Please review the output and generated files as a sanity check.".yellow ); + confirm( fn ); +} + function abort( msg ) { - echo( msg ); - echo( "Aborting." ); + echo( msg.red ); + echo( "Aborting.".red ); exit( 1 ); } From 548d37bca15c998429f35957f2166577023320bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Wed, 25 Jul 2012 10:53:31 -0400 Subject: [PATCH 38/47] Release: Update TODOs related to publishing generated files. --- build/release/release.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/build/release/release.js b/build/release/release.js index 7dada78c5..27759d4d2 100644 --- a/build/release/release.js +++ b/build/release/release.js @@ -43,6 +43,8 @@ walk([ section( "updating trac" ), updateTrac, confirm + + // TODO: upload release zip to GitHub ]); @@ -140,17 +142,14 @@ function buildRelease() { echo(); echo( "Building release..." ); + // TODO: Build themes if ( exec( "grunt release" ).code !== 0 ) { abort( "Error building release." ); } echo(); - // TODO: Build themes - - // TODO: Move build out of dist/ echo( "Committing release artifacts..." ); git( "add *.jquery.json", "Error adding manifest files to git." ); - // TODO: Add built files git( "commit -am 'Tagging the " + newVersion + " release.'", "Error committing release changes." ); echo(); From bfec28eb0d62148c94e358813ab66962dd566024 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 26 Jul 2012 20:35:48 -0400 Subject: [PATCH 39/47] Tabs tests: Removed workaround for Firefox <13 passing values to setTimeout(). --- tests/unit/tabs/tabs_core.js | 18 +++--------------- 1 file changed, 3 insertions(+), 15 deletions(-) diff --git a/tests/unit/tabs/tabs_core.js b/tests/unit/tabs/tabs_core.js index f1a2d72c1..53dd50a98 100644 --- a/tests/unit/tabs/tabs_core.js +++ b/tests/unit/tabs/tabs_core.js @@ -285,11 +285,7 @@ asyncTest( "keyboard support - LEFT, RIGHT, UP, DOWN, HOME, END, SPACE, ENTER", equal( panels.eq( 2 ).attr( "aria-expanded" ), "false", "third panel has aria-expanded=false" ); equal( panels.eq( 2 ).attr( "aria-hidden" ), "true", "third panel has aria-hidden=true" ); - // support: Firefox 12 - // Firefox <13 passes arguments so we can't use setTimeout( start, 1 ) - setTimeout(function() { - start(); - }, 1 ); + setTimeout( start, 1 ); } setTimeout( step1, 1 ); @@ -482,11 +478,7 @@ asyncTest( "keyboard support - CTRL navigation", function() { equal( panels.eq( 0 ).attr( "aria-expanded" ), "false", "first panel has aria-expanded=false" ); equal( panels.eq( 0 ).attr( "aria-hidden" ), "true", "first panel has aria-hidden=true" ); - // support: Firefox 12 - // Firefox <13 passes arguments so we can't use setTimeout( start, 1 ) - setTimeout(function() { - start(); - }, 1 ); + setTimeout( start, 1 ); } setTimeout( step1, 1 ); @@ -578,11 +570,7 @@ asyncTest( "keyboard support - CTRL+UP, ALT+PAGE_DOWN, ALT+PAGE_UP", function() panels.eq( 1 ).simulate( "keydown", { keyCode: keyCode.UP, ctrlKey: true } ); strictEqual( document.activeElement, tabs[ 1 ], "second tab is activeElement" ); - // support: Firefox 12 - // Firefox <13 passes arguments so we can't use setTimeout( start, 1 ) - setTimeout(function() { - start(); - }, 1 ); + setTimeout( start, 1 ); } setTimeout( step1, 1 ); From 1626c97caa920d72d0bb7501b240e64538ed41cd Mon Sep 17 00:00:00 2001 From: Mark Aaron Shirley Date: Fri, 27 Jul 2012 09:40:11 -0700 Subject: [PATCH 40/47] Datepicker: Changed body selector to document.body. Fixed #8464 - Datepicker does not properly scope the body selector. --- ui/jquery.ui.datepicker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 692832d19..d54c4fb85 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -1818,7 +1818,7 @@ $.fn.datepicker = function(options){ /* Initialise the date picker. */ if (!$.datepicker.initialized) { $(document).mousedown($.datepicker._checkExternalClick). - find('body').append($.datepicker.dpDiv); + find(document.body).append($.datepicker.dpDiv); $.datepicker.initialized = true; } From b68b116adfd48378f1dd6d5b6f0d437a6e8e2d2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Mon, 30 Jul 2012 12:48:47 -0400 Subject: [PATCH 41/47] Autocomplete: Fixed spacing. --- ui/jquery.ui.autocomplete.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js index 25d909f8d..6a16c576e 100644 --- a/ui/jquery.ui.autocomplete.js +++ b/ui/jquery.ui.autocomplete.js @@ -577,7 +577,7 @@ $.widget( "ui.autocomplete", $.ui.autocomplete, { options: { messages: { noResults: "No search results.", - results: function(amount) { + results: function( amount ) { return amount + ( amount > 1 ? " results are" : " result is" ) + " available, use up and down arrow keys to navigate."; } @@ -587,7 +587,7 @@ $.widget( "ui.autocomplete", $.ui.autocomplete, { __response: function( content ) { var message; this._superApply( arguments ); - if ( this.options.disabled || this.cancelSearch) { + if ( this.options.disabled || this.cancelSearch ) { return; } if ( content && content.length ) { From 7e1cb95d379c95ec412dccf6bc1b4e75dd203951 Mon Sep 17 00:00:00 2001 From: kborchers Date: Tue, 31 Jul 2012 00:00:07 -0500 Subject: [PATCH 42/47] Menu: Open submenu on click of parent item and only close menu when clicking item without submenu. --- ui/jquery.ui.menu.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index 75cfac40b..055b13319 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -77,8 +77,11 @@ $.widget( "ui.menu", { mouseHandled = true; this.select( event ); - // Redirect focus to the menu - if ( !this.element.is(":focus") ) { + // Open submenu on click + if ( this.element.has( ".ui-menu" ).length ) { + this.expand( event ); + } else if ( !this.element.is(":focus") ) { + // Redirect focus to the menu this.element.focus(); } } @@ -584,7 +587,9 @@ $.widget( "ui.menu", { // Selecting a menu item removes the active item causing multiple clicks to be missing an item item: this.active || $( event.target ).closest( ".ui-menu-item" ) }; - this.collapseAll( event, true ); + if ( !ui.item.has( ".ui-menu" ).length ) { + this.collapseAll( event, true ); + } this._trigger( "select", event, ui ); } }); From e68bee9b84b16ee8a757a7a1f44d93f4ba78c656 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Tue, 31 Jul 2012 16:27:43 -0400 Subject: [PATCH 43/47] Mouse: Don't try to unbind delegated event handlers if they don't exist. Fixes #8416 - Draggable breaks during drag if any other draggable is removed or destroyed. --- ui/jquery.ui.mouse.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ui/jquery.ui.mouse.js b/ui/jquery.ui.mouse.js index 6f95765f2..dc10d9401 100644 --- a/ui/jquery.ui.mouse.js +++ b/ui/jquery.ui.mouse.js @@ -47,9 +47,11 @@ $.widget("ui.mouse", { // other instances of mouse _mouseDestroy: function() { this.element.unbind('.'+this.widgetName); - $(document) - .unbind('mousemove.'+this.widgetName, this._mouseMoveDelegate) - .unbind('mouseup.'+this.widgetName, this._mouseUpDelegate); + if ( this._mouseMoveDelegate ) { + $(document) + .unbind('mousemove.'+this.widgetName, this._mouseMoveDelegate) + .unbind('mouseup.'+this.widgetName, this._mouseUpDelegate); + } }, _mouseDown: function(event) { From f4e47278ae80f3e56cd9b91f2208ef8ce0a0f20c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn=20Zaefferer?= Date: Thu, 2 Aug 2012 13:46:29 +0200 Subject: [PATCH 44/47] Build: Include *.jquery.json files in release --- grunt.js | 1 + 1 file changed, 1 insertion(+) diff --git a/grunt.js b/grunt.js index a861be2e0..1dc102a9d 100644 --- a/grunt.js +++ b/grunt.js @@ -164,6 +164,7 @@ grunt.initConfig({ "README.md", "grunt.js", "package.json", + "*.jquery.json", "ui/**/*", "demos/**/*", "themes/**/*", From bde439292aa32021c7e0a66fb35fa46c6d900fba Mon Sep 17 00:00:00 2001 From: Corey Frang Date: Sun, 5 Aug 2012 10:05:44 -0500 Subject: [PATCH 45/47] Build: Extending testswarm timeout to 45 minutes --- build/tasks/testswarm.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/tasks/testswarm.js b/build/tasks/testswarm.js index 759dfcb35..29dd74b87 100644 --- a/build/tasks/testswarm.js +++ b/build/tasks/testswarm.js @@ -44,7 +44,7 @@ function submit( commit, tests, configFile, version, done ) { testswarm({ url: config.swarmUrl, pollInterval: 10000, - timeout: 1000 * 60 * 30, + timeout: 1000 * 60 * 45, done: done }, { authUsername: config.authUsername, From 485ca7192ac57d018b8ce4f03e7dec6e694a53b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 9 Aug 2012 10:13:24 -0400 Subject: [PATCH 46/47] Simplify licensing. --- GPL-LICENSE.txt | 278 ------------------------- grunt.js | 5 +- package.json | 8 +- tests/jquery.simulate.js | 2 +- themes/base/jquery.ui.accordion.css | 2 +- themes/base/jquery.ui.all.css | 2 +- themes/base/jquery.ui.autocomplete.css | 2 +- themes/base/jquery.ui.base.css | 2 +- themes/base/jquery.ui.button.css | 2 +- themes/base/jquery.ui.core.css | 2 +- themes/base/jquery.ui.datepicker.css | 2 +- themes/base/jquery.ui.dialog.css | 2 +- themes/base/jquery.ui.menu.css | 2 +- themes/base/jquery.ui.progressbar.css | 2 +- themes/base/jquery.ui.resizable.css | 2 +- themes/base/jquery.ui.selectable.css | 2 +- themes/base/jquery.ui.slider.css | 2 +- themes/base/jquery.ui.spinner.css | 2 +- themes/base/jquery.ui.tabs.css | 2 +- themes/base/jquery.ui.theme.css | 2 +- themes/base/jquery.ui.tooltip.css | 2 +- ui/jquery.ui.accordion.js | 2 +- ui/jquery.ui.autocomplete.js | 2 +- ui/jquery.ui.button.js | 2 +- ui/jquery.ui.core.js | 2 +- ui/jquery.ui.datepicker.js | 2 +- ui/jquery.ui.dialog.js | 2 +- ui/jquery.ui.draggable.js | 2 +- ui/jquery.ui.droppable.js | 2 +- ui/jquery.ui.effect-blind.js | 2 +- ui/jquery.ui.effect-bounce.js | 2 +- ui/jquery.ui.effect-clip.js | 2 +- ui/jquery.ui.effect-drop.js | 2 +- ui/jquery.ui.effect-explode.js | 2 +- ui/jquery.ui.effect-fade.js | 2 +- ui/jquery.ui.effect-fold.js | 2 +- ui/jquery.ui.effect-highlight.js | 2 +- ui/jquery.ui.effect-pulsate.js | 2 +- ui/jquery.ui.effect-scale.js | 2 +- ui/jquery.ui.effect-shake.js | 2 +- ui/jquery.ui.effect-slide.js | 2 +- ui/jquery.ui.effect-transfer.js | 2 +- ui/jquery.ui.effect.js | 2 +- ui/jquery.ui.menu.js | 2 +- ui/jquery.ui.mouse.js | 2 +- ui/jquery.ui.position.js | 2 +- ui/jquery.ui.progressbar.js | 2 +- ui/jquery.ui.resizable.js | 2 +- ui/jquery.ui.selectable.js | 2 +- ui/jquery.ui.slider.js | 2 +- ui/jquery.ui.sortable.js | 2 +- ui/jquery.ui.spinner.js | 2 +- ui/jquery.ui.tabs.js | 2 +- ui/jquery.ui.tooltip.js | 2 +- ui/jquery.ui.widget.js | 2 +- 55 files changed, 55 insertions(+), 340 deletions(-) delete mode 100644 GPL-LICENSE.txt diff --git a/GPL-LICENSE.txt b/GPL-LICENSE.txt deleted file mode 100644 index 11dddd00e..000000000 --- a/GPL-LICENSE.txt +++ /dev/null @@ -1,278 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc. - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. diff --git a/grunt.js b/grunt.js index 1dc102a9d..d244e21cc 100644 --- a/grunt.js +++ b/grunt.js @@ -114,7 +114,7 @@ function createBanner( files ) { "<%= grunt.template.today('isoDate') %>\n" + "<%= pkg.homepage ? '* ' + pkg.homepage + '\n' : '' %>" + "* Includes: " + (files ? fileNames.join(", ") : "<%= stripDirectory(grunt.task.current.file.src[1]) %>") + "\n" + - "* Copyright (c) <%= grunt.template.today('yyyy') %> <%= pkg.author.name %>;" + + "* Copyright <%= grunt.template.today('yyyy') %> <%= pkg.author.name %>;" + " Licensed <%= _.pluck(pkg.licenses, 'type').join(', ') %> */"; } @@ -158,7 +158,6 @@ grunt.initConfig({ dist: { src: [ "AUTHORS.txt", - "GPL-LICENSE.txt", "jquery-*.js", "MIT-LICENSE.txt", "README.md", @@ -204,7 +203,6 @@ grunt.initConfig({ cdn: { src: [ "AUTHORS.txt", - "GPL-LICENSE.txt", "MIT-LICENSE.txt", "ui/*.js", "package.json" @@ -247,7 +245,6 @@ grunt.initConfig({ themes: { src: [ "AUTHORS.txt", - "GPL-LICENSE.txt", "MIT-LICENSE.txt", "package.json" ], diff --git a/package.json b/package.json index 1f3205192..ca71cae2c 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "homepage": "http://jqueryui.com", "author": { "name": "jQuery Foundation and other contributors", - "url": "http://jqueryui.com" + "url": "https://github.com/jquery/jquery-ui/blob/master/AUTHORS.txt" }, "maintainers": [ { @@ -43,11 +43,7 @@ "licenses": [ { "type": "MIT", - "url": "http://www.opensource.org/licenses/MIT" - }, - { - "type": "GPL", - "url": "http://www.opensource.org/licenses/GPL-2.0" + "url": "https://github.com/jquery/jquery-ui/blob/master/MIT-LICENSE.txt" } ], "dependencies": {}, diff --git a/tests/jquery.simulate.js b/tests/jquery.simulate.js index 874d274cc..e281e2fee 100644 --- a/tests/jquery.simulate.js +++ b/tests/jquery.simulate.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license */ diff --git a/themes/base/jquery.ui.accordion.css b/themes/base/jquery.ui.accordion.css index 71319ac28..60975acc2 100644 --- a/themes/base/jquery.ui.accordion.css +++ b/themes/base/jquery.ui.accordion.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Accordion#theming diff --git a/themes/base/jquery.ui.all.css b/themes/base/jquery.ui.all.css index 958dac4be..c92e2a5e7 100644 --- a/themes/base/jquery.ui.all.css +++ b/themes/base/jquery.ui.all.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Theming diff --git a/themes/base/jquery.ui.autocomplete.css b/themes/base/jquery.ui.autocomplete.css index e1b127470..cc85c5a4e 100644 --- a/themes/base/jquery.ui.autocomplete.css +++ b/themes/base/jquery.ui.autocomplete.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Autocomplete#theming diff --git a/themes/base/jquery.ui.base.css b/themes/base/jquery.ui.base.css index 36a5dd274..b1f3d5448 100644 --- a/themes/base/jquery.ui.base.css +++ b/themes/base/jquery.ui.base.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Theming diff --git a/themes/base/jquery.ui.button.css b/themes/base/jquery.ui.button.css index f5453fb9f..1faeff6ab 100644 --- a/themes/base/jquery.ui.button.css +++ b/themes/base/jquery.ui.button.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Button#theming diff --git a/themes/base/jquery.ui.core.css b/themes/base/jquery.ui.core.css index 33a6c96be..8cf4d02ef 100644 --- a/themes/base/jquery.ui.core.css +++ b/themes/base/jquery.ui.core.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Theming/API diff --git a/themes/base/jquery.ui.datepicker.css b/themes/base/jquery.ui.datepicker.css index 0f4e71562..c1f269999 100644 --- a/themes/base/jquery.ui.datepicker.css +++ b/themes/base/jquery.ui.datepicker.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Datepicker#theming diff --git a/themes/base/jquery.ui.dialog.css b/themes/base/jquery.ui.dialog.css index 22523c82c..2937af9b7 100644 --- a/themes/base/jquery.ui.dialog.css +++ b/themes/base/jquery.ui.dialog.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Dialog#theming diff --git a/themes/base/jquery.ui.menu.css b/themes/base/jquery.ui.menu.css index 85c387387..ea4b24e26 100644 --- a/themes/base/jquery.ui.menu.css +++ b/themes/base/jquery.ui.menu.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Menu#theming diff --git a/themes/base/jquery.ui.progressbar.css b/themes/base/jquery.ui.progressbar.css index 877666589..a8b3d7442 100644 --- a/themes/base/jquery.ui.progressbar.css +++ b/themes/base/jquery.ui.progressbar.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Progressbar#theming diff --git a/themes/base/jquery.ui.resizable.css b/themes/base/jquery.ui.resizable.css index bca140eda..291bdb209 100644 --- a/themes/base/jquery.ui.resizable.css +++ b/themes/base/jquery.ui.resizable.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Resizable#theming diff --git a/themes/base/jquery.ui.selectable.css b/themes/base/jquery.ui.selectable.css index 0fa8942aa..e00779d7e 100644 --- a/themes/base/jquery.ui.selectable.css +++ b/themes/base/jquery.ui.selectable.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Selectable#theming diff --git a/themes/base/jquery.ui.slider.css b/themes/base/jquery.ui.slider.css index 39d15b034..5e7a9734f 100644 --- a/themes/base/jquery.ui.slider.css +++ b/themes/base/jquery.ui.slider.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Slider#theming diff --git a/themes/base/jquery.ui.spinner.css b/themes/base/jquery.ui.spinner.css index 41ffe539c..94b73fa05 100644 --- a/themes/base/jquery.ui.spinner.css +++ b/themes/base/jquery.ui.spinner.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Spinner#theming diff --git a/themes/base/jquery.ui.tabs.css b/themes/base/jquery.ui.tabs.css index a2efae8b0..405b6932a 100644 --- a/themes/base/jquery.ui.tabs.css +++ b/themes/base/jquery.ui.tabs.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Tabs#theming diff --git a/themes/base/jquery.ui.theme.css b/themes/base/jquery.ui.theme.css index 86da8a295..343a2f433 100644 --- a/themes/base/jquery.ui.theme.css +++ b/themes/base/jquery.ui.theme.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Theming/API diff --git a/themes/base/jquery.ui.tooltip.css b/themes/base/jquery.ui.tooltip.css index ed29c137a..e293eeb23 100644 --- a/themes/base/jquery.ui.tooltip.css +++ b/themes/base/jquery.ui.tooltip.css @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license */ .ui-tooltip { diff --git a/ui/jquery.ui.accordion.js b/ui/jquery.ui.accordion.js index 7d98886e7..de9e1a3cb 100644 --- a/ui/jquery.ui.accordion.js +++ b/ui/jquery.ui.accordion.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Accordion diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js index 6a16c576e..617aa9c70 100644 --- a/ui/jquery.ui.autocomplete.js +++ b/ui/jquery.ui.autocomplete.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Autocomplete diff --git a/ui/jquery.ui.button.js b/ui/jquery.ui.button.js index 1aa44abdd..5c3fb7589 100644 --- a/ui/jquery.ui.button.js +++ b/ui/jquery.ui.button.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Button diff --git a/ui/jquery.ui.core.js b/ui/jquery.ui.core.js index 3e102f181..0e33f11ed 100644 --- a/ui/jquery.ui.core.js +++ b/ui/jquery.ui.core.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index d54c4fb85..091fe3101 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Datepicker diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index 85e4b3e2b..66c7f4dff 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Dialog diff --git a/ui/jquery.ui.draggable.js b/ui/jquery.ui.draggable.js index 2f05ad6a4..b693dccae 100644 --- a/ui/jquery.ui.draggable.js +++ b/ui/jquery.ui.draggable.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Draggables diff --git a/ui/jquery.ui.droppable.js b/ui/jquery.ui.droppable.js index 17a56787a..36179d6d5 100644 --- a/ui/jquery.ui.droppable.js +++ b/ui/jquery.ui.droppable.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Droppables diff --git a/ui/jquery.ui.effect-blind.js b/ui/jquery.ui.effect-blind.js index a5c41325c..c4ff12fdc 100644 --- a/ui/jquery.ui.effect-blind.js +++ b/ui/jquery.ui.effect-blind.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Blind diff --git a/ui/jquery.ui.effect-bounce.js b/ui/jquery.ui.effect-bounce.js index 0a93bda08..8a03f4f88 100644 --- a/ui/jquery.ui.effect-bounce.js +++ b/ui/jquery.ui.effect-bounce.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Bounce diff --git a/ui/jquery.ui.effect-clip.js b/ui/jquery.ui.effect-clip.js index 6539acf24..0cef7e0ca 100644 --- a/ui/jquery.ui.effect-clip.js +++ b/ui/jquery.ui.effect-clip.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Clip diff --git a/ui/jquery.ui.effect-drop.js b/ui/jquery.ui.effect-drop.js index 674ef41ec..ce02dd3fd 100644 --- a/ui/jquery.ui.effect-drop.js +++ b/ui/jquery.ui.effect-drop.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Drop diff --git a/ui/jquery.ui.effect-explode.js b/ui/jquery.ui.effect-explode.js index 1048b0a42..76e92fac3 100644 --- a/ui/jquery.ui.effect-explode.js +++ b/ui/jquery.ui.effect-explode.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Explode diff --git a/ui/jquery.ui.effect-fade.js b/ui/jquery.ui.effect-fade.js index ee031fcd8..5f5fcbfae 100644 --- a/ui/jquery.ui.effect-fade.js +++ b/ui/jquery.ui.effect-fade.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Fade diff --git a/ui/jquery.ui.effect-fold.js b/ui/jquery.ui.effect-fold.js index 7619285c2..1e0e475f5 100644 --- a/ui/jquery.ui.effect-fold.js +++ b/ui/jquery.ui.effect-fold.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Fold diff --git a/ui/jquery.ui.effect-highlight.js b/ui/jquery.ui.effect-highlight.js index f6868d136..2ae5729dc 100644 --- a/ui/jquery.ui.effect-highlight.js +++ b/ui/jquery.ui.effect-highlight.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Highlight diff --git a/ui/jquery.ui.effect-pulsate.js b/ui/jquery.ui.effect-pulsate.js index 543f6310d..d1e74ea8e 100644 --- a/ui/jquery.ui.effect-pulsate.js +++ b/ui/jquery.ui.effect-pulsate.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Pulsate diff --git a/ui/jquery.ui.effect-scale.js b/ui/jquery.ui.effect-scale.js index 5e1dc8540..4283fe842 100644 --- a/ui/jquery.ui.effect-scale.js +++ b/ui/jquery.ui.effect-scale.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Scale diff --git a/ui/jquery.ui.effect-shake.js b/ui/jquery.ui.effect-shake.js index 51d8e1129..fd9605d0a 100644 --- a/ui/jquery.ui.effect-shake.js +++ b/ui/jquery.ui.effect-shake.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Shake diff --git a/ui/jquery.ui.effect-slide.js b/ui/jquery.ui.effect-slide.js index 134b058c7..5f0aa1e45 100644 --- a/ui/jquery.ui.effect-slide.js +++ b/ui/jquery.ui.effect-slide.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Slide diff --git a/ui/jquery.ui.effect-transfer.js b/ui/jquery.ui.effect-transfer.js index 7d6c10933..ddf8139b6 100644 --- a/ui/jquery.ui.effect-transfer.js +++ b/ui/jquery.ui.effect-transfer.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/Transfer diff --git a/ui/jquery.ui.effect.js b/ui/jquery.ui.effect.js index 7cabe5849..ec8260709 100644 --- a/ui/jquery.ui.effect.js +++ b/ui/jquery.ui.effect.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Effects/ diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index 055b13319..78b602cce 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Menu diff --git a/ui/jquery.ui.mouse.js b/ui/jquery.ui.mouse.js index dc10d9401..a08566b90 100644 --- a/ui/jquery.ui.mouse.js +++ b/ui/jquery.ui.mouse.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Mouse diff --git a/ui/jquery.ui.position.js b/ui/jquery.ui.position.js index 2802b2ce0..eef8a95c9 100644 --- a/ui/jquery.ui.position.js +++ b/ui/jquery.ui.position.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Position diff --git a/ui/jquery.ui.progressbar.js b/ui/jquery.ui.progressbar.js index 74a2d6923..7f1ebf77d 100644 --- a/ui/jquery.ui.progressbar.js +++ b/ui/jquery.ui.progressbar.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Progressbar diff --git a/ui/jquery.ui.resizable.js b/ui/jquery.ui.resizable.js index be174dd7e..584f3a234 100644 --- a/ui/jquery.ui.resizable.js +++ b/ui/jquery.ui.resizable.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Resizables diff --git a/ui/jquery.ui.selectable.js b/ui/jquery.ui.selectable.js index 1da7fffa3..95bc92faa 100644 --- a/ui/jquery.ui.selectable.js +++ b/ui/jquery.ui.selectable.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Selectables diff --git a/ui/jquery.ui.slider.js b/ui/jquery.ui.slider.js index adceb356c..0434d8075 100644 --- a/ui/jquery.ui.slider.js +++ b/ui/jquery.ui.slider.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Slider diff --git a/ui/jquery.ui.sortable.js b/ui/jquery.ui.sortable.js index db24fed38..8d7b6ccb8 100644 --- a/ui/jquery.ui.sortable.js +++ b/ui/jquery.ui.sortable.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Sortables diff --git a/ui/jquery.ui.spinner.js b/ui/jquery.ui.spinner.js index ead3b17be..11377f6a6 100644 --- a/ui/jquery.ui.spinner.js +++ b/ui/jquery.ui.spinner.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Spinner diff --git a/ui/jquery.ui.tabs.js b/ui/jquery.ui.tabs.js index 588b8cdb2..b31ce364a 100644 --- a/ui/jquery.ui.tabs.js +++ b/ui/jquery.ui.tabs.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Tabs diff --git a/ui/jquery.ui.tooltip.js b/ui/jquery.ui.tooltip.js index 8bfe78c05..9f0a8a810 100644 --- a/ui/jquery.ui.tooltip.js +++ b/ui/jquery.ui.tooltip.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * Depends: diff --git a/ui/jquery.ui.widget.js b/ui/jquery.ui.widget.js index b5dfaa344..924d10bc2 100644 --- a/ui/jquery.ui.widget.js +++ b/ui/jquery.ui.widget.js @@ -3,7 +3,7 @@ * http://jqueryui.com * * Copyright 2012 jQuery Foundation and other contributors - * Dual licensed under the MIT or GPL Version 2 licenses. + * Released under the MIT license. * http://jquery.org/license * * http://docs.jquery.com/UI/Widget From 30b579f598a3abdc9b0b7ad18bc76c8b5438d5ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 9 Aug 2012 16:32:16 -0400 Subject: [PATCH 47/47] Datepicker: Unescape double escaped ids when handling events. Fixes #8480 - Datepicker 1.8.22 escaped id does not work. --- ui/jquery.ui.datepicker.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/jquery.ui.datepicker.js b/ui/jquery.ui.datepicker.js index 091fe3101..cd4ffe3ee 100644 --- a/ui/jquery.ui.datepicker.js +++ b/ui/jquery.ui.datepicker.js @@ -1414,7 +1414,7 @@ $.extend(Datepicker.prototype, { */ _attachHandlers: function(inst) { var stepMonths = this._get(inst, 'stepMonths'); - var id = '#' + inst.id; + var id = '#' + inst.id.replace( /\\\\/g, "\\" ); inst.dpDiv.find('[data-handler]').map(function () { var handler = { prev: function () {