Merge pull request #33033 from pea3nut/master

[moveto 1.8.0] update moveto v1.7.0 -> v1.8.0
This commit is contained in:
Andrew Casey
2019-02-20 15:27:16 -08:00
committed by GitHub
2 changed files with 7 additions and 1 deletions
+6 -1
View File
@@ -1,6 +1,7 @@
// Type definitions for moveto 1.7
// Type definitions for moveto 1.8
// Project: https://github.com/hsnaydd/moveTo
// Definitions by: Rostislav Shermenyov <https://github.com/shermendev>
// pea3nut <https://github.com/pea3nut>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare class MoveTo {
@@ -66,6 +67,10 @@ declare namespace MoveTo {
* Ease function name
*/
easing?: string;
/**
* The container been computed and scrolled
*/
container?: Window | HTMLElement;
/**
* The function to be run after scrolling complete. Target passes as the first argument
*/
+1
View File
@@ -2,6 +2,7 @@ const options: MoveTo.MoveToOptions = {
tolerance: 70,
duration: 300,
easing: "easeOutQuart",
container: Math.random() > 0.5 ? window : document.createElement('div'),
callback: () => {}
};