Skip to content

Tags: up209d/GreenSock-JS

Tags

1.19.0

Toggle 1.19.0's commit message
1.19.0

- NEW: You can define most values dynamically using a function as the value, like:

TweenMax.to(".class", 1, {x:function() {
	return Math.random() * 1000; //will randomize x between 0 and 1000
}});

The function will be called once for each target in the tween when it renders the first time. This can be very useful for randomizing things or applying conditional logic. The index number is passed as the first parameter, and the target is the second.

- NEW: ModifiersPlugin allows you to modify the tweening values just before they get applied on each tick, making it easy to create complex effects like wrapping values using modulus, rounding in whatever way you want, etc. For example:

TweenMax.to(".class", 1, {x:1000, y:600, modifiers:{
		x: function(value, target) {
            return value % 100; //wraps the value at 100.
        },
        y: function(value, target) {
        	return Math.round(value / 100) * 100; //rounds to the closest 100
        }
	}
});

- NEW: ScrollToPlugin now recognizes selector text (or a DOM element or jQuery object) as the value so that instead of passing in a number for the scroll position, you just pass it the element itself that you want to scroll into view. For example, TweenMax.to(window, 2, {scrollTo:"#someID"}) or TweenMax.to(window, 2, {scrollTo:{y:".someClass", x:"#someID"}}); You can also optionally pass "offsetX" and/or "offsetY" numeric values if you want to offset the destination from the element (like to give it a little breathing room). For example, scrollTo:{y:"#someID", offsetY:50} would scroll #someID into view with 50 pixels from the top (like a margin).

- NEW: ScrollToPlugin exposes a getOffset() method that returns an object with "x" and "y" properties corresponding to the amount of offset from the container. For example, ScrollToPlugin.getOffset(element, window) might return {x:0, y:310}.

- NEW: You can set ScrollToPlugin.autoKillThreshold (default is 7) which determines how many pixels the scroll position must drift before triggering the autoKill (like if the user starts scrolling while a scrollTo tween is in-progress).

- NEW: SplitText recognizes a new "wordDelimiter" special property that lets you set something other than a space as the delimiter between words, like: var split = new SplitText("#someID", {wordDelimiter:"#"}). Any non-space delimiter will be removed from the final output (it's only used as a delimiter).

- NEW: you can optionally pass in span:true in a SplitText config object to have it use <span> tags instead of <div> tags for wrapping.

- IMPROVED: TimelineMax's tweenTo() and tweenFromTo() methods can now accommodate "repeat", "yoyo", and "repeatDelay" properties in the vars object as long as TweenMax is loaded.

- IMPROVED: slight performance boost for callbacks with fewer than 3 parameters

- FIXED: in 1.18.5 we changed to a relative AMD path value for dependencies which caused some headaches for users of RequireJS so we reverted back to declaring dependencies in the simple absolute format like "TweenLite" (whereas in 1.18.5 it was "../TweenLite" in plugins). This makes it easier to just declare your own paths in tools like RequireJS.

- FIXED: issue that could cause TweenLite and/or some eases not to be exported properly from TweenMax in a Node environment on the module.exports.

- FIXED: if a "tick" listener is added to TweenLite.ticker from within another "tick" event handler, there is no longer a risk that one could be skipped in that rendering cycle.

- FIXED: regression since 1.18.1 that could cause a link (<a>) not to redirect the browser on iOS (only) when the user tapped without dragging and dragClickables was true.

- FIXED: issue that could cause skewY with skewType:"simple" not to work as expected (stretched as well a skewed).

- FIXED: worked around a bug in Safari that caused the vertical portion of backgroundSize to default to 0.

- FIXED: TextPlugin works now with SVG <text> nodes in Microsoft Edge

- FIXED: worked around an inconsistency in Chrome that caused a Draggable of type "scroll" not to scroll to the right properly when dragged left.

- FIXED: Draggable in 1.18.1 through 1.18.5 sometimes didn't handle the native click behavior on iOS Safari properly when dragClickables was true, so toggling a checkbox wouldn't work for example. That's fixed now.

- FIXED: Draggable's liveSnap feature didn't work properly during the "throw" phase since version 1.18.0

- FIXED: if killTweensOf() was called on a tween that was performing an autoRotate bezier tween on a DOM element, and "rotation" was targeted, it wouldn't kill that part of the tween properly.

- FIXED: Apparently bower imposes a 140 character limit in the bower.json description, so we shortened it.

- CHANGED: for function-based values passed to the "cycle" feature of the stagger methods, the target is now passed as the 2nd parameter instead of scoping the function call to the target. In other words, "this" inside the function used to refer to the target, but not any longer - instead, the target is specifically passed in as the 2nd parameter.

- REMOVED: KineticPlugin (KineticJS was discontinued a long time ago, so it was time to sunset this plugin)

1.18.5

Toggle 1.18.5's commit message
1.18.5

- NEW: the "cycle" feature of the stagger methods can now recognize a "duration" property, thus you can have complete control over varying durations as well (array-based or function-based).

- NEW: Draggable.update() accepts a 2nd parameter, "sticky" (boolean) that you can set to true if you want the target to act like it's stuck to the cursor/touch when factoring in any transform changes that were made (this is only relevent when called DURING a drag). For example, if you start dragging an element and then while you're dragging, some other code causes the parent element to rotate or move or scale, perhaps you'd want the target element to adjust its position so that it remains stuck to the cursor/touch. That's possible now. yourDraggable.update(false, true);

- IMPROVED: compatibility with Node and build systems like Webpack and Browserify. You can import individual pieces of TweenMax, for example, in ES6 import statements, like:
import {TweenMax, TimelineMax, Back, Quad} from 'gsap';
//or
var TweenMax = require("./libs/gsap/TweenMax.js");

- IMPROVED: if you set/tween a transform-related property of an element that has its css "display" property set to "none" (or it has no parentNode) but also has a transform applied via CSS, GSAP now works around a browser issue that could cause those to be lost. Some browsers report the computed style of an element with display:none as "none" even if, for example, a CSS transform of "rotate(30deg) scale(0.5, 0.5)" was applied.

- FIXED: using a unit other than "px" when tweening "border" (like border:"10rem solid red") works properly now.

- FIXED: the onStart callback of a zero-duration TimelineLite or TimelineMax fires now.

- FIXED: SplitText ignores extra white space now so that you won't get any extra "lines" where there are carriage returns or line breaks.

- FIXED: removed "TweenLite" dependency in SpliText.

- FIXED: if the last control point in a bezier path is directly on top of the final anchor point (rare), autoRotate could snap to -90 degrees (fixed now).

- FIXED: a non-zero initial rotation of a DOM element that was being animated with a BezierPlugin tween (with autoRotate enabled) didn't get returned properly when the tween was rewound fully.

- FIXED: if you TweenLite.ticker.addEventListener() *before* the first tick, it no longer immediately calls the listener (it waits for the next tick).

1.18.4

Toggle 1.18.4's commit message
1.18.4

- IMPROVED: Draggable's autoScroll feature now handles transformed child elements better (so if you scaled the element that's inside the scrollable area, it could drift as you drag).

- IMPROVED: complex gradients are better handled (although CSSPlugin doesn't claim to fully support cross-browser gradient tweens)

- IMPROVED: supports 2-part borderBottomLeftRadius, borderBottomRightRadius, borderTopLeftRadius, and borderTopRightRadius values

- IMPROVED: now when you update() a Draggable that has autoScroll turned on, it'll force an update of the scroll listeners up the DOM tree (in case, for example, the Draggable was created on an element that has since been reparented)

- FIXED: when animating the width or height of an SVG element, Chrome would log a warning about support for offsetWidth and offsetHeight being deprecated on SVG elements.

- FIXED: regression in 1.18.3 caused clip values like rect(10px,20px,100px,200px) not to get applied properly.

- FIXED: regression in 1.18.3 that caused certain properties like "perspective" not to be applied correctly when a suffix wasn't included.

- FIXED: regression in 1.18.3 that could cause an <svg> element to have its transforms parsed/applied incorrectly in rare situations (treated as if it's SVG artwork rather than a regular DOM element)

- FIXED: regression in 1.18.3 that caused matrix values that were extremely small and reported by the browser in scientific format not to be parsed correctly.

- FIXED: worked around a bug in some browsers that alter an element's offsetTop/offsetLeft/offsetParent when a transform is applied which affected bounds parsing in Draggable.

1.18.3

Toggle 1.18.3's commit message
1.18.3

- IMPROVED: stronger workarounds for Firefox bugs that cause SVG elements that aren't rendered (like <symbol> or <def>) to throw exceptions when transformed. Certain scenarios with transforming SVGs in other browsers also work better now.

- IMPROVED: parsing of decimals that don't have a leading zero (like .5 instead of 0.5) that are nested in complex strings (like "matrix(1,0,0,1,.5,.999)")

- IMPROVED: parsing of mis-matched color formats in complex strings (like "radial-gradient(circle, #FFFFFF, #FF0000)" to "radial-gradient(circle, purple, rgb(0,0,255)")

- IMPROVED: ability to animate complex values like filters in certain cases.

- NEW: can animate multiple backgroundPosition values as long as they match beginning/ending quantities and the units match.

- FIXED: TweenMax.progress() and TweenMax.totalProgress() now accept a "suppressEvents" (2nd) parameter.

- FIXED: tweening "skewY" (with CSSPlugin) could cause subsequent tweens of "rotation" or "skewX" to look inaccurate (skewX, skewY, and rotation are all related in the matrix values).

- FIXED: regression that could cause a Draggable with autoScroll:true not to update the scroll position correctly if update() is called on a Draggable that is NOT being dragged.

- FIXED: if autoRotate was set to true in a BezierPlugin tween it could occasionally (very rarely) render the CSS value incorrectly on a mobile device.

- FIXED: Chrome deprecated offsetWidth/offsetHeight/offsetParent on SVG elements, so we worked around that.

- FIXED: in some cases an onUpdate wouldn't fire on zero-duration tweens that were encountered when running backwards on a parent timeline.

- FIXED: in rare cases a className wouldn't be applied properly if it partially matched another that already was applied.

- FIXED: if a negative delay is used on a tween with immediateRender:true, it now renders at its zero time properly.

- FIXED: if a transform-related value was tweened on an element that originally had a matrix3d() applied with a skew, the skew wasn't parsed out properly (very rare).

- FIXED: if the literal "transform" property of an SVG element was animated and at the same time its transformOrigin or svgOrigin was set, it could jump.

- FIXED: if there was a bezier tween that had no change (like values:[{x:0, y:0}, {x:0, y:0}]), it could result in subsequent x/y tweens on that element not to work. Again, extremely rare.

- FIXED: in a repeating TweenMax or TimelineMax, if you went beyond the first iteration/cycle and then back to that iteration's starting time, it would render at the end instead of the start (technically that's both the start and end time), but now it correctly discerns direction and will choose the start or end, whichever makes more sense in that context.

1.18.2

Toggle 1.18.2's commit message
1.18.2

- 1.18.2 is mostly a push that was necessary due to NodeJS semver/registry complications with the 1.18.1 push. Therefore, we'll include the information about 1.18.1 fixes below as well for convenience.

- FIXED: an onDragStart() could be inadvertently triggered on a Draggable if an update(true) was called from within a callback (regression in 1.14.2)

- FIXED: the bounds may not be updated properly on a Draggable with autoScroll:true and throwProps:true after scrolling and changing the bounds and calling update(true).

- FIXED: in very rare cases, ThrowPropsPlugin's final/onComplete values might be off by an extremely small amount (like 0.0000000001).

- IMPROVED: EasePack's node/amd/commmonjs compatibility

- UPDATED: copyright dates (2016)

--------- 1.18.1 release notes below -----------

- NEW: TweenLite.ticker.wake() optionally accepts a "seamless" parameter (boolean) that will adjust the time so that things appear to seamlessly begin again (no jump according to the elapsed time). So TweenLite.ticker.wake(true) would seamlessly wake/resume the ticker.

- IMPROVED: if GSAP is loaded on a page that's in an inactive tab and the browser is under heavy load, it will not revert to using setTimeout instead of requestAnimateionFrame. Also, if you specifically set TweenLite.ticker.useRAF(true), it will not fall back to setTimeout. You may now set it to "auto" (the default) to have it intelligently select the best option.

- IMPROVED: calling update() on a Draggable instance will cause it to re-analyze the dimensions/limits for auto-scrolling. You can even do this WHILE you're dragging.

- FIXED: if the original property was a string and tweened as a number, it was simply appended to the end in 1.18.0 (regression). For example, if element.style.opacity starts at 0 and then you do TweenLite.to(element.style, 1, {opacity:1}), it would end up at "10". This is fixed now (the initial value is cast as a number). greensock#123

- FIXED: In extremely rare cases, an animation's onComplete wouldn't be called when setting the time of the parent timeline to exactly on top of the end time that happens to be on a value that ends in a decimal like 999999999999 or .00000000000001. Now if you get within 0.0000001 seconds of the end time, it will assume it is complete.

- FIXED: clearProps works on SVG transforms now.

- FIXED: Draggable's hitTest() works better in IE8 when selector text is used.

- FIXED: a "delay" set inside of a TweenMax.staggerTo()/staggerFrom()/staggerFromTo() "cycle" is now honored.

- FIXED: parsing a 3D CSS transform no longer gets flipped in one direction in certain rare scenarios.

- FIXED: setting totalDuration() of a TimelineMax with a repeatDelay larger than the new duration works now.

- FIXED: if you altered the playhead position from inside a callback (like an onComplete) that's in a nested tween inside a TimelineLite/Max, it could be inadvertently called in some (rare) cases. That's fixed now.

- FIXED: a regression in ColorPropsPlugin that caused values not to be set correctly when "format" was "number".

- FIXED: issue in IE10/11 that could cause a brief flash of a scrollbar when the page first loads Draggable.

- FIXED: worked around Firefox issue that could cause a Draggable that's applied to a video not to allow mouse events to affect the video properly. For example, clicking on it to play the video wouldn't cause the video to play, as if Draggable was intercepting the mouse events.

- FIXED: when performing a bezier tween on CSS properties like transforms, rewinding a tween/timeline all the way to a time of 0 could cause the values to revert to their pre-tween state unnecessarily.

- FIXED: when tweening to a CSS value that uses "vw" or "vh" units, it could result in using "px" at the end instead.

- FIXED: if TweenMax.updateTo() was called with a new ease defined, it wouldn't take effect in certain circumstances.

- FIXED: an onRepeat could fire twice in rare circumstances if TweenMax.updateTo() was called from within the onRepeat.

- FIXED: if you altered the bounds of a Draggable via its "vars" object AFTER it was created, and you re-used that vars object on another Draggable instance, they would both be affected. (Not anymore).

- FIXED: setting a complex CSS value like borderBottom:"10px solid red" would use the original non-numeric/non-color piece of the value (in this example, "solid" which may be "none" in the computed style).

- FIXED: in ScrollToPlugin, scrolling to values less than 0 doesn't cause the tween to trigger an autoKill anymore.

- FIXED: DrawSVGPlugin works even if you've got an extra space inside each value pair, like points="0, 0 100, 200" instead of points="0,0 100,200".

- FIXED: regression that caused CSSPlugin to render scaleZ as 1 if there was no rotationX or rotationY.

- FIXED: an ID inside of a complex string is much less likely to be inadvertently interpreted as a hex color value.

- NEW: MorphSVGPlugin records the original path data so that you can tween back to it easily (after morphing to some other value) by targeting the original element itself, like TweenLite.to("#element", 1, {morphSVG:"#element"})

- NEW: MorphSVGPlugin.pathDataToBezier() accepts a new "align" config property that can be set to an element (or selector text) to adjust the values so that the element gets positioned on the path, or "relative" to make all of the values relative (like moving the path to the element).

- NEW: You can set the shapeIndex of a "morphSVG" tween to "log" to have it console.log() the value that's automatically selected. This can be useful in troubleshooting or for optimizing speed because if you set a specific shapeIndex value (rather than "auto"), the plugin can skip several steps of logic that determines the best match.

- NEW: MorphSVGPlugin recognizes a new "precompile" property. When set to "log", it will console.log() a 2-element array of values that you can then copy/paste into the actual tween, replacing precompile:true with precompile:["...","..."] (the values that were logged). Doing so will allow MorphSVGPlugin to instantiate the tween much faster because it can skip all the logic that determines shapeIndex and matches the number of points and shifts them around when necessary to make everything look seamless. That logic only runs on the first render of the tween, so this precompile step just helps the tween START faster, avoiding a potential stutter right when it begins.

1.18.1

Toggle 1.18.1's commit message
1.18.1

- NEW: TweenLite.ticker.wake() optionally accepts a "seamless" parameter (boolean) that will adjust the time so that things appear to seamlessly begin again (no jump according to the elapsed time). So TweenLite.ticker.wake(true) would seamlessly wake/resume the ticker.

- IMPROVED: if GSAP is loaded on a page that's in an inactive tab and the browser is under heavy load, it will not revert to using setTimeout instead of requestAnimateionFrame. Also, if you specifically set TweenLite.ticker.useRAF(true), it will not fall back to setTimeout. You may now set it to "auto" (the default) to have it intelligently select the best option.

- IMPROVED: calling update() on a Draggable instance will cause it to re-analyze the dimensions/limits for auto-scrolling. You can even do this WHILE you're dragging.

- FIXED: if the original property was a string and tweened as a number, it was simply appended to the end in 1.18.0 (regression). For example, if element.style.opacity starts at 0 and then you do TweenLite.to(element.style, 1, {opacity:1}), it would end up at "10". This is fixed now (the initial value is cast as a number). greensock#123

- FIXED: In extremely rare cases, an animation's onComplete wouldn't be called when setting the time of the parent timeline to exactly on top of the end time that happens to be on a value that ends in a decimal like 999999999999 or .00000000000001. Now if you get within 0.0000001 seconds of the end time, it will assume it is complete.

- FIXED: clearProps works on SVG transforms now.

- FIXED: Draggable's hitTest() works better in IE8 when selector text is used.

- FIXED: a "delay" set inside of a TweenMax.staggerTo()/staggerFrom()/staggerFromTo() "cycle" is now honored.

- FIXED: parsing a 3D CSS transform no longer gets flipped in one direction in certain rare scenarios.

- FIXED: setting totalDuration() of a TimelineMax with a repeatDelay larger than the new duration works now.

- FIXED: if you altered the playhead position from inside a callback (like an onComplete) that's in a nested tween inside a TimelineLite/Max, it could be inadvertently called in some (rare) cases. That's fixed now.

- FIXED: a regression in ColorPropsPlugin that caused values not to be set correctly when "format" was "number".

- FIXED: issue in IE10/11 that could cause a brief flash of a scrollbar when the page first loads Draggable.

- FIXED: worked around Firefox issue that could cause a Draggable that's applied to a video not to allow mouse events to affect the video properly. For example, clicking on it to play the video wouldn't cause the video to play, as if Draggable was intercepting the mouse events.

- FIXED: when performing a bezier tween on CSS properties like transforms, rewinding a tween/timeline all the way to a time of 0 could cause the values to revert to their pre-tween state unnecessarily.

- FIXED: when tweening to a CSS value that uses "vw" or "vh" units, it could result in using "px" at the end instead.

- FIXED: if TweenMax.updateTo() was called with a new ease defined, it wouldn't take effect in certain circumstances.

- FIXED: an onRepeat could fire twice in rare circumstances if TweenMax.updateTo() was called from within the onRepeat.

- FIXED: if you altered the bounds of a Draggable via its "vars" object AFTER it was created, and you re-used that vars object on another Draggable instance, they would both be affected. (Not anymore).

- FIXED: setting a complex CSS value like borderBottom:"10px solid red" would use the original non-numeric/non-color piece of the value (in this example, "solid" which may be "none" in the computed style).

- FIXED: in ScrollToPlugin, scrolling to values less than 0 doesn't cause the tween to trigger an autoKill anymore.

- FIXED: DrawSVGPlugin works even if you've got an extra space inside each value pair, like points="0, 0 100, 200" instead of points="0,0 100,200".

- FIXED: regression that caused CSSPlugin to render scaleZ as 1 if there was no rotationX or rotationY.

- FIXED: an ID inside of a complex string is much less likely to be inadvertently interpreted as a hex color value.

- NEW: MorphSVGPlugin records the original path data so that you can tween back to it easily (after morphing to some other value) by targeting the original element itself, like TweenLite.to("#element", 1, {morphSVG:"#element"})

- NEW: MorphSVGPlugin.pathDataToBezier() accepts a new "align" config property that can be set to an element (or selector text) to adjust the values so that the element gets positioned on the path, or "relative" to make all of the values relative (like moving the path to the element).

- NEW: You can set the shapeIndex of a "morphSVG" tween to "log" to have it console.log() the value that's automatically selected. This can be useful in troubleshooting or for optimizing speed because if you set a specific shapeIndex value (rather than "auto"), the plugin can skip several steps of logic that determines the best match.

- NEW: MorphSVGPlugin recognizes a new "precompile" property. When set to true, it will console.log() a 2-element array of values that you can then copy/paste into the actual tween, replacing precompile:true with precompile:["...","..."] (the values that were logged). Doing so will allow MorphSVGPlugin to instantiate the tween much faster because it can skip all the logic that determines shapeIndex and matches the number of points and shifts them around when necessary to make everything look seamless. That logic only runs on the first render of the tween, so this precompile step just helps the tween START faster, avoiding a potential stutter right when it begins.

1.18.0

Toggle 1.18.0's commit message
1.18.0

- NEW: the stagger methods recognize a new "cycle" property that allows you to easily alternate between two or more values, or even use a function to define dynamic values based on your own custom logic. For example, TweenMax.staggerTo(".test", 1, {cycle:{y:[100,-100], scale:function(i) { return Math.random() * 2; }}, ease:Power1.easeInOut}) will animate all elements with a class of ".test" to either 100 or -100 (cycling through the values in the array) creating a zipper effect, and each element will scale to a random value between 0 and 2. A function will receive the index of the element as the only parameter and "this" inside the function refers to the target/element itself. This new feature allows you to create very advanced effects with a tiny amount of code.

- NEW: relative HSL color tweening allows you to use the "+=" and "-=" prefixes to relatively adjust the hue, saturation, and/or brightness of a color. For example:
	//30% darker
	...{backgroundColor:"hsl(+=0, +=0%, -=30%)"

	//to grayscale (0% saturation)
	...{backgroundColor:"hsl(+=0, 0%, +=0%)"

	//opposite color (180 degrees around the other side of the color wheel)
	...{backgroundColor:"hsl(+=180, +=0%, +=0%)"

- NEW: complex string-based values containing multiple numbers can be animated without any extra plugins. For example, "10px 20px 50px" can be animated to "4px 13px 200px". GSAP will find each number in the strings (in order), compare them, and only animate the ones that changed. CSSPlugin already does this for CSS values and it even converts units, but the base engine can now do basic string tweening (no unit conversion). It will also find rgba(...) values and make sure to round them appropriately during animation.

- NEW: "stringFilter" or "TweenLite.defaultStringFilter" can be set to a function that filters/formats string-based values **BEFORE** the engine isolates the numeric values and splits things apart for tweening. For example, consider the object {myProp:"1px 2px rgb(0,0,255)"} and then tweening myProp to "1px 2px #FF0000". The color values aren't normalized; you'd need "#FF0000" to be reformatted to "rgb(255,0,0)" so that the values match up properly. That's what a stringFilter is for. It's just a function that accepts a single parameter which is an 2-element array containing the starting value and the ending value. The function should make whatever changes necessary to the values in that array. You can set a stringFilter on a tween-by-tween basis (like TweenLite.to(..., {prop:"whatever", stringFilter:yourFunction})) or you can set a default one for the entire engine through TweenLite.defaultStringFilter. Note: by itself, TweenLite does not automatically convert non-rgba() values because the logic necessary is too costly kb-wise, but for convenience if TweenLite.defaultStringFilter isn't already defined and you load CSSPlugin and ColorPropsPlugin, they will automatically set it to a function that swaps in rgba(...) values for any color-related strings (in almost any fromat like #FF0000, #F00, red, rgb(255,0,0), hsl(0,100%,50%), etc.) because those plugins already contain most of the logic necessary. If hsl values are sensed in either the start or end values, hsla() format will be used. With this architecture, you can even write your own function and pass it to TweenLite.defaultStringFilter to keep things super lean when you're not loading CSSPlugin or ColorPropsPlugin.

- IMPROVED: CSSPlugin now supports for "rem" units

- IMPROVED: timing accuracy in child animations affected by addPause() has been improved. (http://greensock.com/forums/topic/11905-problems-with-callbacks-execution-order/)

- IMPROVED: WebPack compatibility (greensock#106)

- IMPROVED: you can now set() CSS values that use "vw" or "vh" units.

- IMPROVED: you can now set() backgroundSize to "contain" with CSSPlugin (although it doesn't animate because it was deemed an edge case that would be too costly kb-wise to support)

- IMPROVED: tweening a DOM element to a CSS perspective of 0 results in unintuitive behavior (though technically accurate), so it is left alone in that case.

- FIXED: if a child is removed from a timeline, it no longer gets added back again when resumed/restarted when it hasn't been reparented. (It gets added to the root timeline now).

- FIXED: pausing a tween/timeline immediately from within a nested callback when there's a lazy render in the queue could cause things to render incorrectly. It is fixed now. http://greensock.com/forums/topic/12083-lazytween-makes-tweened-element-stay-1-frame-even-if-i-called-pause0/

- FIXED: progress()/totalProgress() of zero-duration tweens/timelines is reported correctly now.

- FIXED: jquery.gsap.js had a bug that could cause it to call the onComplete function too many times (once for each element instead of once for the entire animation).

- FIXED: worked around Firefox error with Draggable SVGs that weren't attached to the document yet.

- FIXED: worked around bug in Chrome and Firefox touch emulators that could throw an error in Draggable because "currentTarget" wasn't defined properly on the event.

- FIXED: worked around IE8 error that would be thrown when Draggable.hitTest() was used.

- FIXED: when you set a "display" CSS value in the same tween as a transform-related value, it will make sure to apply it first (before getting the transform data) in order to work around a browser bug that causes transform values to be improperly reported when display:none is set.

- FIXED: Draggable.hitTest() didn't factor in the scroll position of the page properly. Fixed now.

- FIXED: Draggable now prevents a recursion error when you call its update() from within an onDrag.

- FIXED: By default, Draggable.update() factors in any positional changes you made manually (you can disable this by passing true as the 2nd parameter).

- FIXED: if you pass null (or selector text that has no results) to Draggable.create(), it no longer throws an error (it silently fails).

1.17.0

Toggle 1.17.0's commit message
1.17.0

- NEW: smoothOrigin feature added to CSSPlugin and is enabled by default. When changing the transformOrigin (or svgOrigin) of an SVG element, CSSPlugin will now automatically record/apply some offsets to ensure that the element doesn't "jump". You can disable this by setting CSSPlugin.defaultSmoothOrigin = false, or you can control it on a per-tween basis using smoothOrigin:true | false. Explanation: The way transforms and transform-origins work in the browser (and according to the official spec), changing the origin causes the element jump in a jarring way. For example, if you rotate 180 degrees when the transform-origin is in the element's top left corner, it ends up at a very different position than if you applied the same rotation around its bottom right corner. Since GSAP is focused on solving real-world problems for animators (most of whom prefer to smoothly alter the transformOrigin), the new smoothOrigin feature in GSAP solves this issue. This also means that if you create SVG artwork in an authoring program like Adobe Illustrator or Flash where it may not be easy/obvious to control where the element's origin is, things will "just work" when you define a transformOrigin via GSAP. Currently, this feature only applies to SVG elements, as that is where it is more commonly a pain-point, and we're eager to see how GSAP users employ the feature and share their feedback/suggestions before we consider adding it to "regular" DOM elements.

- NEW: CSSPlugin now accommodates percentage-based x/y translation on SVG elements. Caveat: it's calculated and then baked into the matrix(), so it's not "live" meaning if you later change the width/height of the SVG element, it doesn't alter the translation but you could certainly just re-apply the translation if you need to.

- NEW: CSSPlugin now parses transform="translate(...)" attribute in SVG elements (previously it only parsed matrix()).

- NEW: AttrPlugin will retain suffixes like "%", meaning you can tween values like <rect width="50%"...>. Caveat: it doesn't do unit conversion (like px to %), but that's rarely needed anyway.

- NEW: You can define the scope for all of the callbacks (onStart, onUpdate, onComplete, onReverseComplete, etc.) using the new "callbackScope" special property. This helps consolidate code and we can't remember ever seeing a case where someone wants to define a different scope for different callbacks. The older callback-specific scope properties are deprecated (but still work): onStartScope, onUpdateScope, onCompleteScope, onReverseCompleteScope, and onRepeatScope)

- NEW: Draggable now dispatches "throwupdate" and "throwcomplete" events (like when you add listeners like myDraggable.addEventListener("throwcomplete", function() {...}))

- NEW: Draggable has a new "isThrowing" property

- NEW: Draggable recognizes a new "callbackScope" special vars property that allows you to define the scope of all callbacks like onDragStart, onDrag, onPress, onDragEnd, onThrowUpdate, onThrowComplete, etc. This also means that the following will be deprecated (although they still work fine): onPressScope, onDragStartScope, onDragScope, onDragEndScope, onThrowUpdateScope, onThrowCompleteScope, onReleaseScope, and onClickScope.

- NEW: Draggable.hitTest() can be used with "window" to figure out if/when an element is in the viewport.

- IMPROVED: accuracy of the rotational transform-origin plotting on SVG elements. In fact, SVG support all-around is improved.

- FIXED: while dragging an element in iOS, if you pressed another finger on the same element and then released, it didn't continue dragging.

- FIXED: In Draggable, if you set overshootTolerance to 0, you may still see a slight overshoot unless you set minDuration to 0. That is now automatically adjusted.

- FIXED: svgOrigin now factors in existing transforms (previously, it plotted the global svgOrigin based on the element's untransformed state).

- FIXED: works around bugs in the way Firefox renders SVGs that have CSS transforms applied by forcing them into the "transform" attribute instead of using CSS styles.

- FIXED: bounds weren't applied properly on SVG elements in IE and some versions of Android.

- FIXED: a Draggable's "x" or "y" value was updated even if that axis wasn't active/allowed (not the Draggable's target - just the recorded value on the Draggable instance itself)

- FIXED: some module systems like Browserify threw an error saying that CSSPlugin wasn't defined inside Draggable.

- FIXED: now if two tweens of the same object and property start at exactly the same time, the overwriting tween's starting values aren't affected by the overwritten tween's first render.

- FIXED: rare bug that could cause transform-origin of SVG elements to render incorrectly.

- FIXED: bug that could cause the final/end value of a roundProps tween of a CSS property not to be rounded.

- FIXED: ThrowPropsPlugin didn't properly handle some situations when minDuration was set to a value higher than 1.

- FIXED: ThrowPropsPlugin now handles roundProps on non-css properties correctly.

- FIXED: DrawSVGPlugin works around a browser rendering bug related to when a <rect> (or other shape) has a stroke along the full length but it looks like the very corner isn't connected perfectly (it now removes the stroke-dasharray in that case completely).

- FIXED: worked around a bug in IE10 and IE11 that (in rare situations) could cause SVG strokes not to animate properly using DrawSVGPlugin. (Browser bug documented here: http://codepen.io/GreenSock/pen/714f215a4a26fcacc1661f61f00d7bcb/?editors=001)

1.16.1

Toggle 1.16.1's commit message
1.16.1

- NEW: Draggable allows you to native touch-scroll in the opposite direction as Draggables that are limited to one axis. For example, a Draggable of type:"x" or "left" would permit native touch-scrolling in the vertical direction, and type:"y" or "top" would permit native horizontal touch-scrolling.

- NEW: Draggable now has an onLockAxis callback.

- NEW: Draggable recognizes a new "allowEventDefault" config property. If it's set to true, Draggable won't call preventDefault() on the mouse/touch events so that you can get the native/default behavior if that's what you prefer, or you can manually call it using yourDraggable.pointerEvent.preventDefault().

- IMPROVED: slight performance boost for transforms

- FIXED: clearProps:"transform" (or any transform property) also clears any data-svg-origin attribute.

- FIXED: issue that could cause transforms that are applied along with className in the same tween to not be applied properly.

- FIXED: issue that could cause a ThrowPropsPlugin tween of a DOM element to overwrite other ThrowPropsPlugin tweens of the same element even if they were for different properties (like "x" and "rotation").

- FIXED: issue that could kill active "x" tweens of a Draggable instance when its enable() method is called.

- FIXED: if you called resume() from inside an addPause() callback on a reversed timeline, it didn't resume properly (the callback would keep getting called).

- FIXED: if you resume()/play() a tween that had already completed, it would keep the ticker alive indefinitely.

- FIXED: in rare cases, a callback that was positioned directly on top of an addPause() in a TimelineLite/Max wouldn't be called when the timeline was played in reverse.

- FIXED: regression in 1.16.0 that caused the ticker to rever to using setTimeout() instead of requestAnimationFrame if there were no animations running at roughly 1.5 seconds after the script instantiated.

- FIXED: if you called disable() on a Draggable, it didn't reset the touch-action properly, so it could still interfere with touch device interaction.

- FIXED: when skewType was set to "simple", skewY was still compensated.

- FIXED: issue with jquery.gsap.js plugin that prevented slideUp() and slideDown() from working properly.

1.16.0

Toggle 1.16.0's commit message
1.16.0

- NEW: Draggable has a new "autoScroll" special property that you can set to a number to enable auto-scrolling when the user drags near the edge of a scrollable container. For example, Draggable.create(element, {autoScroll:1}); will auto-scroll at the default speed, whereas autoScroll:2 would scroll twice as fast≤ etc.

- NEW: Draggable has a new getDirection() method that returns "right", "left", "up", "down", "right-up", "right-down", "left-up", or "left-down". It can compare the current position to either where it was when the drag started (the default), or the moment-by-moment velocity direction, or compare it to another element. Example: myDraggable.getDirection(myElement) or myDraggable.getDirection("velocity");

- NEW: Draggable exposes the lockedAxis property so that you can find out whether it's "x" or "y".

- NEW: Draggable recognizes a new "clickableTest" special property which is a function that gets called when the user presses on an element inside a Draggable. That way, you can return true if the element should be considered "clickable" (like a <button> or <a> or <select>) or false if not.

- NEW: CSSPlugin recognizes a new "svgOrigin" special property that allows you to set the transform origin based on absolute SVG coordinate system which can be more convenient than transformOrigin (which is relative to the element's own top left corner). svgOrigin always trumps transformOrigin if both are set. So you can do TweenLite.to(svgElement, 1, {rotation:270, svgOrigin:"250 100"}) if you'd like to rotate svgElement as though its origin is at x:250, y:100 in the SVG canvas's global coordinates. It also records the value in the data-svg-origin attribute so that it can be parsed back that way as well. svgOrigin doesn't accommodate percentage-based values.

- NEW: jquery.gsap.js plugin now allows you to define legacy properties that should pass through GSAP's processing, like $.gsap.legacyProps("translateX,translateY,scaleX,scaleY"); This helps avoid compatibility problems with other jQuery plugins that also customize animation behavior.

- NEW: ColorPropsPlugin recognizes a new "numFormat" Boolean value that you can set like colorProps:{myProperty:"red", numFormat:true} if you want the value to be **set** using a numeric value instead of a string rgb() or rgba() value. For example, it's perfect if you're using a canvas framework that expects a number like 0xFF0000 instead of "rgb(255,0,0)".

- NEW: You can set TweenLite.autoSleep to the number of frames between garbage collection routines (which is also when the ticker goes to sleep if there are no active tweens left). The default is 120.

- IMPROVED: Draggable's support for SVG has never been better. It plots the rotational origin accurately, for example.

- IMPROVED: several performance optimizations were made to Draggable, particularly for transforms and scrolling.

- IMPROVED: force3D:"auto" will no longer try to toggle back to 2D inbetween repeats in a TweenMax instance. This just helps performance.

- IMPROVED: Elastic eases handle "amplitude" config parameters of less than 1 in a more intuitive way, adjusting period to achieve the effect that the user most likely wanted.

- FIXED: className tweens in Chrome no longer leave several -webkit- prefixed properties contaminating the inline styles after the tween finishes (the problem was caused by an inconsistency in the browser itself)

- FIXED: tweens of boxShadow now prioritize "inset" in the end value instead of the beginning value. Previously, if the beginning value contained "inset", it would force it into the end value.

- FIXED: potential rounding error when setting the "snap" of a Draggable to an array of values.

- FIXED: in some rare cases, a Draggable of type:"scrollTop" | "scrollLeft" | "scroll" would have a small margin at the top (like 15px).

- FIXED: animation of transforms of SVG elements in Safari now default to using the "transform" attribute instead of CSS transforms because of bugs in Safari that'd cause them not to be rendered correctly in certain scenarios.

- FIXED: some problems with parsing SVG element transforms (either CSS-based or transform attribute-based).

- FIXED: skewType:"simple" works on elements that only have 2D transforms

- FIXED: zero-duration tweens or callbacks that are positioned at the very beginning of a TimelineLite or TimelineMax will render their starting values after the timeline has been reversed and the playhead goes past the beginning.

- FIXED: callbacks that are positioned exactly at the same spot as an addPause() on a TimelineLite/Max will fire properly now (previously, it could fire before and after the pause/resume and not at all in reverse)

- FIXED: if a timeline is reversed, finishes reversing, and then reverse() is called again, it could end up preventing the timeline from being removed from a parent timeline that has autoRemoveChildren enabled which means it could prevent it from being eligible for GC and consequently not let the main ticker go to sleep in that particular case.

- FIXED: regression in 1.15.x caused addPause() not to always pause when necessary (it could skip on very rare occasions).

- FIXED: if an addPause() was added to the very beginning of a timeline and then reverse() was called, finished, and then later play() was called, the pause would be in effect until you resumed/played again. That's fixed now.