@digitalmoves/text-scroll-effects-02 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/main.js +1 -1
- package/package.json +5 -1
package/CHANGELOG.md
CHANGED
package/dist/main.js
CHANGED
|
@@ -21,4 +21,4 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
|
21
21
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
22
|
SOFTWARE.
|
|
23
23
|
*/
|
|
24
|
-
(function(
|
|
24
|
+
(function(h){typeof define=="function"&&define.amd?define(h):h()})(function(){"use strict";function h(g,e){const t=u();return h=function(f,l){return f=f-217,t[f]},h(g,e)}const m=h;(function(g,e){const t=h,f=g();for(;;)try{if(-parseInt(t(253))/1*(parseInt(t(225))/2)+parseInt(t(219))/3*(-parseInt(t(257))/4)+-parseInt(t(269))/5+-parseInt(t(233))/6+parseInt(t(232))/7*(-parseInt(t(261))/8)+parseInt(t(289))/9+parseInt(t(238))/10*(parseInt(t(268))/11)===e)break;f.push(f.shift())}catch{f.push(f.shift())}})(u,920619),gsap[m(286)](ScrollTrigger);const M=()=>{const g=m;let e=window[g(266)];typeof e===g(237)&&(window.lenisInstance=e=new Lenis({lerp:.2,smooth:!0})),e.on("scroll",()=>ScrollTrigger.update());const t=f=>{e[g(292)](f),requestAnimationFrame(t)};requestAnimationFrame(t)};function u(){const g=["top bottom+=40%","registerPlugin","center top+=20%","power4","5720679TIduiD","utils","effect-12","raf","effect-6","effect-4","555VuXqdf","transform, filter","end","effect-10","back.out(1.2)","length","31750nSaXMR","center center","center","top bottom-=20%","parentNode","opacity, transform","bottom top+=20%","658987xPLljX","8614146mCtkQo","effect-3","floor","none","undefined","20RNDPGB","entries","abs","50% 0%","transform","top top+=15%","effect","50% 100%","effect-7","top bottom","effect-11","querySelectorAll","data-splitting",".char","bottom top-=50%","11QCGxMA","effect-1","effect-2","set","7700maUHkg","ceil","+=500%","bottom top","88IuRTav","power1.inOut","querySelector","top bottom-=10%","expo","lenisInstance","start","25747557YfRxLE","6971970YHOnXI","forEach","selector","center bottom","power3.in",".word","0% 50%","timeline","setAttribute","push","power2.inOut","mapRange","random","effect-9","fromTo","+=100%"];return u=function(){return g},u()}const w=g=>{const e=m,t={};g[e(270)](r=>{const x=e,c=document[x(263)](r[x(271)]);c&&(c[x(277)](x(250),!0),!t[r[x(244)]]&&(t[r[x(244)]]=[]),t[r[x(244)]][x(278)](c))}),Splitting();const f=t[e(254)]||[],l=t[e(255)]||[],b=t[e(234)]||[],I=t[e(218)]||[],T=t["effect-5"]||[],v=t[e(217)]||[],S=t[e(246)]||[],E=t["effect-8"]||[],X=t[e(282)]||[],q=t[e(222)]||[],k=t[e(248)]||[],O=t[e(291)]||[],z=t["effect-13"]||[],A=t["effect-14"]||[];f[e(270)](r=>{const x=e;gsap.fromTo(r,{transformOrigin:x(275),rotate:3},{ease:x(236),rotate:0,scrollTrigger:{trigger:r,start:x(247),end:"top top",scrub:!0}}),gsap[x(283)](r[x(249)](x(274)),{"will-change":"opacity",opacity:.1},{ease:x(236),opacity:1,stagger:.05,scrollTrigger:{trigger:r,start:x(228),end:x(287),scrub:!0}})}),l[e(270)](r=>{const x=e,c=r.querySelectorAll(x(251));c[x(270)](s=>gsap[x(256)](s[x(229)],{perspective:1e3})),gsap[x(283)](c,{"will-change":"opacity, transform",opacity:0,rotateX:()=>gsap[x(290)][x(281)](-120,120),z:()=>gsap[x(290)].random(-200,200)},{ease:"none",opacity:1,rotateX:0,z:0,stagger:.02,scrollTrigger:{trigger:r,start:x(247),end:x(260),scrub:!0}})}),b[e(270)](r=>{const x=e,c=r[x(249)](".char");c.forEach(s=>gsap.set(s[x(229)],{perspective:1e3})),gsap[x(283)](c,{"will-change":"opacity, transform",opacity:.2,z:-800},{ease:x(223),opacity:1,z:0,stagger:.04,scrollTrigger:{trigger:r,start:x(247),end:x(260),scrub:!0}})}),I.forEach(r=>{const x=e,c=r[x(249)](x(251));c.forEach(s=>gsap[x(256)](s.parentNode,{perspective:1e3})),gsap.fromTo(c,{"will-change":x(230),transformOrigin:"50% 0%",opacity:0,rotationX:-90,z:-200},{ease:"power1",opacity:1,stagger:.05,rotationX:0,z:0,scrollTrigger:{trigger:r,start:"center bottom",end:x(231),scrub:!0}})}),T[e(270)](r=>{const x=e,c=r.querySelectorAll(".char");c[x(270)](s=>gsap[x(256)](s.parentNode,{perspective:1e3})),gsap[x(283)](c,{"will-change":x(230),transformOrigin:x(245),opacity:0,rotationX:90},{ease:x(288),opacity:1,stagger:{each:.03,from:x(281)},rotationX:0,scrollTrigger:{trigger:r,start:x(272),end:x(231),scrub:!0}})}),v.forEach(r=>{const x=e,c=[...r[x(249)](x(274))];for(const s of c){const i=s[x(249)](x(251));i[x(270)](a=>gsap[x(256)](a[x(229)],{perspective:2e3})),gsap[x(283)](i,{"will-change":x(230),opacity:0,y:(a,n,o)=>-40*Math[x(240)](a-o[x(224)]/2),z:()=>gsap[x(290)][x(281)](-1500,-600),rotationX:()=>gsap.utils[x(281)](-500,-200)},{ease:x(262),opacity:1,y:0,z:0,rotationX:0,stagger:{each:.06,from:x(227)},scrollTrigger:{trigger:s,start:x(247),end:x(243),scrub:!0}})}}),S.forEach(r=>{const x=e,c=[...r[x(249)](".word")];for(const s of c){const i=s[x(249)](".char"),a=i[x(224)];i[x(270)](n=>gsap[x(256)](n[x(229)],{perspective:1e3})),gsap[x(283)](i,{"will-change":"transform",x:n=>{const o=x,p=n<Math[o(258)](a/2)?n:Math[o(258)](a/2)-Math.abs(Math.floor(a/2)-n)-1;return(a%2?Math[o(240)](Math[o(258)](a/2)-1-p):Math[o(240)](Math[o(258)](a/2)-p))*200*(n<a/2?-1:1)},y:n=>{const o=x;return(n<Math.ceil(a/2)?n:Math.ceil(a/2)-Math[o(240)](Math[o(235)](a/2)-n)-1)*60},rotationY:-270,rotationZ:n=>{const o=x,p=n<Math[o(258)](a/2)?n:Math[o(258)](a/2)-Math[o(240)](Math[o(235)](a/2)-n)-1;return n<a/2?Math[o(240)](p-a/2)*8:-1*Math.abs(p-a/2)*8}},{ease:x(279),x:0,y:0,rotationZ:0,rotationY:0,scale:1,scrollTrigger:{trigger:s,start:"top bottom+=40%",end:"top top+=15%",scrub:!0}})}}),E[e(270)](r=>{const x=e,c=[...r.querySelectorAll(x(274))];for(const[s,i]of c[x(239)]())gsap[x(283)](i[x(249)](x(251)),{"will-change":x(242),scale:.01,x:(a,n,o)=>{const p=x;return s%2?a*50:(o[p(224)]-a-1)*-50}},{ease:x(288),scale:1,x:0,scrollTrigger:{trigger:i,start:x(272),end:"bottom top-=40%",scrub:!0}})}),X[e(270)](r=>{const x=e,c=r[x(249)](".char"),s=c[x(224)];gsap.fromTo(c,{"will-change":x(242),y:i=>{const a=x,n=i<Math.ceil(s/2)?i:Math[a(258)](s/2)-Math.abs(Math[a(235)](s/2)-i)-1;return(s/2-n+6)*130}},{ease:"elastic.out(.4)",y:0,stagger:{amount:.1,from:x(227)},scrollTrigger:{trigger:r,start:x(247),end:x(252),scrub:!0}})}),q[e(270)](r=>{const x=e;gsap.fromTo(r[x(249)](x(251)),{"will-change":"transform",transformOrigin:x(245),scaleY:0},{ease:x(273),opacity:1,scaleY:1,stagger:.05,scrollTrigger:{trigger:r,start:x(226),end:x(259),scrub:1,pin:r[x(229)][x(229)]}})}),k.forEach(r=>{const x=e,c=[...r.querySelectorAll(x(274))],s=gsap[x(276)]({scrollTrigger:{trigger:r,start:x(226),end:x(284),scrub:!0,pin:r[x(229)]}});for(const[i,a]of c[x(239)]())s.fromTo(a[x(249)](x(251)),{"will-change":x(242),transformOrigin:()=>!i%2?x(241):"50% 100%",scaleY:0},{ease:x(262),scaleY:1,stagger:{amount:.3,from:"center"}},0)}),O[e(270)](r=>{const x=e,c=[...r[x(249)](x(274))];c[x(270)](s=>gsap.set(s[x(229)],{perspective:1e3})),gsap[x(283)](c,{"will-change":"opacity, transform",z:()=>gsap[x(290)].random(500,950),opacity:0,xPercent:s=>gsap[x(290)][x(281)](-100,100),yPercent:s=>gsap[x(290)][x(281)](-10,10),rotationX:()=>gsap[x(290)][x(281)](-90,90)},{ease:x(265),opacity:1,rotationX:0,rotationY:0,xPercent:0,yPercent:0,z:0,scrollTrigger:{trigger:r,start:x(226),end:"+=300%",scrub:!0,pin:r[x(229)]},stagger:{each:.006,from:"random"}})}),z[e(270)](r=>{const x=e,c=[...r[x(249)](".word")];for(const s of c){const i=s[x(249)](".char"),a=i.length;gsap[x(283)](i,{"will-change":x(220),transformOrigin:"50% 100%",scale:n=>{const o=x,p=n<Math[o(258)](a/2)?n:Math[o(258)](a/2)-Math[o(240)](Math[o(235)](a/2)-n)-1;return gsap[o(290)].mapRange(0,Math[o(258)](a/2),.5,2.1,p)},y:n=>{const o=x,p=n<Math[o(258)](a/2)?n:Math.ceil(a/2)-Math.abs(Math[o(235)](a/2)-n)-1;return gsap.utils.mapRange(0,Math[o(258)](a/2),0,60,p)},rotation:n=>{const o=x,p=n<Math[o(258)](a/2)?n:Math.ceil(a/2)-Math[o(240)](Math[o(235)](a/2)-n)-1;return n<a/2?gsap.utils[o(280)](0,Math[o(258)](a/2),-4,0,p):gsap[o(290)][o(280)](0,Math[o(258)](a/2),0,4,p)},filter:"blur(12px) opacity(0)"},{ease:x(279),y:0,rotation:0,scale:1,filter:"blur(0px) opacity(1)",scrollTrigger:{trigger:s,start:x(285),end:"top top+=15%",scrub:!0},stagger:{amount:.15,from:x(227)}})}}),A[e(270)](r=>{const x=e,c=[...r.querySelectorAll(x(274))];for(const[s,i]of c[x(239)]()){const a=i[x(249)](x(251));gsap[x(283)](a,{"will-change":x(242),transformOrigin:(s%2?0:100)+"% "+(s%2?100:0)+"%",scale:0},{ease:x(288),scale:1,stagger:{each:.03,from:s%2?x(221):x(267)},scrollTrigger:{trigger:i,start:x(264),end:"top top",scrub:!0}})}})};function d(g,e){var t=_();return d=function(f,l){f=f-230;var b=t[f];return b},d(g,e)}var y=d;(function(g,e){for(var t=d,f=g();;)try{var l=-parseInt(t(238))/1+-parseInt(t(239))/2+parseInt(t(236))/3*(parseInt(t(241))/4)+-parseInt(t(240))/5*(parseInt(t(235))/6)+-parseInt(t(242))/7*(parseInt(t(234))/8)+parseInt(t(232))/9*(parseInt(t(237))/10)+-parseInt(t(233))/11*(-parseInt(t(230))/12);if(l===e)break;f.push(f.shift())}catch{f.push(f.shift())}})(_,755394);function _(){var g=["3768sVLhoJ","addEventListener","23553CokHHh","99913koHjqg","32GwlGbp","6066EsfpTb","2383389JdhECJ","500nHnLpq","389757jHZGkH","1596794mESdwD","3745EQkCQp","4KTkvIW","1884029JDvNwv","DOMContentLoaded"];return _=function(){return g},_()}document[y(231)](y(243),()=>{M(),w(textScrollPack2Elements)})});
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@digitalmoves/text-scroll-effects-02",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.3",
|
|
5
5
|
"main": "dist/main.js",
|
|
6
6
|
"files": [
|
|
7
7
|
"dist",
|
|
@@ -10,6 +10,10 @@
|
|
|
10
10
|
"LICENSE"
|
|
11
11
|
],
|
|
12
12
|
"license": "UNLICENSED",
|
|
13
|
+
"author": {
|
|
14
|
+
"name": "Harley"
|
|
15
|
+
},
|
|
16
|
+
"homepage": "https://digitalmoves.com.au/plugins/p/text-scroll-animation-pack-01",
|
|
13
17
|
"devDependencies": {},
|
|
14
18
|
"scripts": {
|
|
15
19
|
"dev": "vite",
|