Skip to content

Commit

Permalink
3.4.1
Browse files Browse the repository at this point in the history
- NEW: ScrollTrigger.sort() method. You should generally create your ScrollTriggers in the order they'd happen on the page (top-to-bottom or left-to-right), but if that's not possible you can use ScrollTrigger.sort() to either use your own custom method for sorting or if none is provided, it'll sort by "refreshPriority" first, then by each ScrollTrigger's "start" value. So, for example, a ScrollTrigger with refreshPriority: 1 will get refreshed earlier than one with refreshPriority: 0 (the default). You're welcome to use negative numbers too.

- NEW: each media query function in the object passed to ScrollTrigger.matchMedia() can now [optionally] return a function which will be called when the media query becomes inactive, so it's a great place to put cleanup code.

- IMPROVED: you can now make multiple calls to ScrollTrigger.matchMedia() with the same media query string(s). It's generally not useful/necessary, but in some component-based environments it can be quite handy.

- IMPROVED: if you set once: true on a ScrollTrigger that has a scrub value, it will honor that and only scrub once to completion.

- FIXED: the "float" CSS property of a ScrollTrigger-pinned element wasn't copied to the pin-spacer.

- FIXED: added missing TypeScript definition for MotionPathPlugin.cacheRawPathMeasurements(). See #396

- FIXED: a regression in ScrollTrigger's invalidateOnRefresh: true prevented it from working properly in some cases. See https://greensock.com/forums/topic/24765-multiple-scrolltriggers-in-multiple-each-functions-jquery/?tab=comments#comment-118817

- FIXED: if you disable() a ScrollTrigger that has a pinned element, its measurements may still inadvertently affect other ScrollTriggers that have the SAME pin element (very rare).

- FIXED: if a ScrollTrigger was disabled, later when it gets re-enabled it may revert to the previous scroll position (not generally desirable).

- FIXED: if you pin the same element multiple times, but at least one of those times it was NOT the "trigger", it could throw off the start/end calculations. See https://greensock.com/forums/topic/24811-pining-multiple-elements/

- FIXED: if there were multiple ScrollTriggers back-to-back that pin the same element, when you scroll backwards it may appear "stuck" in certain situations.

- FIXED: under certain conditions, a paused animation that was scrubbed may act as though invalidate() kept getting called on it (basically it wouldn't init while paused).

- FIXED: if you define a "render" function in a MorphSVGPlugin tween, it was interpreted as a function-based value (thus it would get called for each target and the RESULT of that function was used).
  • Loading branch information
jackdoyle committed Jul 19, 2020
1 parent c7e6623 commit 73a92fa
Show file tree
Hide file tree
Showing 62 changed files with 483 additions and 320 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

#### Professional-grade animation for the modern web

GSAP is a JavaScript library for building high-performance animations that work in **every** major browser. Animate CSS, SVG, canvas, React, Vue, WebGL, colors, strings, motion paths, generic objects...anything JavaScript can touch! The ScrollTrigger plugin lets you create jaw-dropping scroll-based animations with minimal code. No other library delivers such advanced sequencing, reliability, and tight control while solving real-world problems on millions of sites. GSAP works around countless browser inconsistencies; your animations **just work**. At its core, GSAP is a high-speed property manipulator, updating values over time with extreme accuracy. It's up to 20x faster than jQuery! See https://greensock.com/why-gsap/ for what makes GSAP so special.
GSAP is a JavaScript library for building high-performance animations that work in **every** major browser. Animate CSS, SVG, canvas, React, Vue, WebGL, colors, strings, motion paths, generic objects...anything JavaScript can touch! The <a href="https://greensock.com/scrolltrigger">ScrollTrigger</a> plugin lets you create jaw-dropping scroll-based animations with minimal code. No other library delivers such advanced sequencing, reliability, and tight control while solving real-world problems on millions of sites. GSAP works around countless browser inconsistencies; your animations **just work**. At its core, GSAP is a high-speed property manipulator, updating values over time with extreme accuracy. It's up to 20x faster than jQuery! See https://greensock.com/why-gsap/ for what makes GSAP so special.

### What is GSAP? (video)

Expand All @@ -18,7 +18,7 @@ View the <a href="https://greensock.com/docs">full documentation here</a>, inclu

### CDN
```html
<script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.4.0/gsap.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.4.1/gsap.min.js"></script>
```
Click the green "Get GSAP Now" button at <a href="https://greensock.com/?download=GSAP-JS">greensock.com</a> for more options and installation instructions, including CDN URLs for various plugins.

Expand Down
4 changes: 2 additions & 2 deletions dist/CSSRulePlugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
}(this, (function (exports) { 'use strict';

/*!
* CSSRulePlugin 3.4.0
* CSSRulePlugin 3.4.1
* https://greensock.com
*
* @license Copyright 2008-2020, GreenSock. All rights reserved.
Expand Down Expand Up @@ -51,7 +51,7 @@
};

var CSSRulePlugin = {
version: "3.4.0",
version: "3.4.1",
name: "cssRule",
init: function init(target, value, tween, index, targets) {
if (!_checkRegister() || typeof target.cssText === "undefined") {
Expand Down
4 changes: 2 additions & 2 deletions dist/CSSRulePlugin.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/CSSRulePlugin.min.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/Draggable.js
Original file line number Diff line number Diff line change
Expand Up @@ -2909,7 +2909,7 @@
});

Draggable.zIndex = 1000;
Draggable.version = "3.4.0";
Draggable.version = "3.4.1";
_getGSAP() && gsap.registerPlugin(Draggable);

exports.Draggable = Draggable;
Expand Down
4 changes: 2 additions & 2 deletions dist/Draggable.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/Draggable.min.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/EasePack.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
}(this, (function (exports) { 'use strict';

/*!
* EasePack 3.4.0
* EasePack 3.4.1
* https://greensock.com
*
* @license Copyright 2008-2020, GreenSock. All rights reserved.
Expand Down Expand Up @@ -201,7 +201,7 @@

for (var p in EasePack) {
EasePack[p].register = _initCore;
EasePack[p].version = "3.4.0";
EasePack[p].version = "3.4.1";
}

_getGSAP() && gsap.registerPlugin(SlowMo);
Expand Down
Loading

0 comments on commit 73a92fa

Please sign in to comment.