All Downloads are FREE. Search and download functionalities are using the official Maven repository.

package.dist.prod.animations.scroll.js.map Maven / Gradle / Ivy

{
  "version": 3,
  "sources": ["../../../src/animations/scroll.ts"],
  "sourcesContent": ["import animate, { duration } from \"./animate.js\";\n\nconst scroll = (element: HTMLElement, dx: number, dy: number) => {\n\tlet scrollLeft: number;\n\tlet scrollTop: number;\n\n\treturn animate({\n\t\tbeforeStart: () => {\n\t\t\tscrollLeft = element.scrollLeft;\n\t\t\tscrollTop = element.scrollTop;\n\t\t},\n\t\tduration,\n\t\telement,\n\t\tadvance: progress => {\n\t\t\telement.scrollLeft = scrollLeft + (progress * dx); // easing - linear\n\t\t\telement.scrollTop = scrollTop + (progress * dy); // easing - linear\n\t\t},\n\t});\n};\n\nexport default scroll;\n"],
  "mappings": "aAAA,OAAOA,GAAW,YAAAC,MAAgB,eAElC,MAAMC,EAAS,CAACC,EAAsBC,EAAYC,IAAe,CAChE,IAAIC,EACAC,EAEJ,OAAOP,EAAQ,CACd,YAAa,IAAM,CAClBM,EAAaH,EAAQ,WACrBI,EAAYJ,EAAQ,SACrB,EACA,SAAAF,EACA,QAAAE,EACA,QAASK,GAAY,CACpBL,EAAQ,WAAaG,EAAcE,EAAWJ,EAC9CD,EAAQ,UAAYI,EAAaC,EAAWH,CAC7C,CACD,CAAC,CACF,EAEA,eAAeH",
  "names": ["animate", "duration", "scroll", "element", "dx", "dy", "scrollLeft", "scrollTop", "progress"]
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy