@fastkit/scroller 0.9.0 → 0.10.0
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/dist/scroller.cjs.js
CHANGED
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
3
|
var ev = require('@fastkit/ev');
|
|
6
4
|
var visibility = require('@fastkit/visibility');
|
|
7
5
|
var helpers = require('@fastkit/helpers');
|
|
8
6
|
var tinyLogger = require('@fastkit/tiny-logger');
|
|
9
7
|
var BezierEasing = require('bezier-easing');
|
|
10
8
|
|
|
11
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e["default"] : e; }
|
|
12
|
-
|
|
13
|
-
var BezierEasing__default = /*#__PURE__*/_interopDefaultLegacy(BezierEasing);
|
|
14
|
-
|
|
15
9
|
// export const HAS_WINDOW = typeof window !== 'undefined';
|
|
16
10
|
// export function warn(message: string): void {
|
|
17
11
|
// if (typeof console === 'object' && console.warn) {
|
|
@@ -257,7 +251,7 @@ function scroll(diffX, diffY, options = {}, _computedValues) {
|
|
|
257
251
|
else {
|
|
258
252
|
easingValues = easing;
|
|
259
253
|
}
|
|
260
|
-
const easingFn =
|
|
254
|
+
const easingFn = BezierEasing.apply(BezierEasing, easingValues);
|
|
261
255
|
on($container, abortEvents, abortFn, { passive: true });
|
|
262
256
|
window.requestAnimationFrame(step);
|
|
263
257
|
return result;
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
3
|
var ev = require('@fastkit/ev');
|
|
6
4
|
var visibility = require('@fastkit/visibility');
|
|
7
5
|
var helpers = require('@fastkit/helpers');
|
|
8
6
|
var tinyLogger = require('@fastkit/tiny-logger');
|
|
9
7
|
var BezierEasing = require('bezier-easing');
|
|
10
8
|
|
|
11
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e["default"] : e; }
|
|
12
|
-
|
|
13
|
-
var BezierEasing__default = /*#__PURE__*/_interopDefaultLegacy(BezierEasing);
|
|
14
|
-
|
|
15
9
|
// export const HAS_WINDOW = typeof window !== 'undefined';
|
|
16
10
|
// export function warn(message: string): void {
|
|
17
11
|
// if (typeof console === 'object' && console.warn) {
|
|
@@ -257,7 +251,7 @@ function scroll(diffX, diffY, options = {}, _computedValues) {
|
|
|
257
251
|
else {
|
|
258
252
|
easingValues = easing;
|
|
259
253
|
}
|
|
260
|
-
const easingFn =
|
|
254
|
+
const easingFn = BezierEasing.apply(BezierEasing, easingValues);
|
|
261
255
|
on($container, abortEvents, abortFn, { passive: true });
|
|
262
256
|
window.requestAnimationFrame(step);
|
|
263
257
|
return result;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fastkit/scroller",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.10.0",
|
|
4
4
|
"description": "Library for controlling the scrolling state of DOM elements.",
|
|
5
5
|
"buildOptions": {
|
|
6
6
|
"name": "Scroller"
|
|
@@ -35,9 +35,9 @@
|
|
|
35
35
|
},
|
|
36
36
|
"homepage": "https://github.com/dadajam4/fastkit/tree/main/packages/scroller#readme",
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@fastkit/ev": "0.
|
|
39
|
-
"@fastkit/visibility": "0.
|
|
40
|
-
"@fastkit/tiny-logger": "0.
|
|
38
|
+
"@fastkit/ev": "0.10.0",
|
|
39
|
+
"@fastkit/visibility": "0.10.0",
|
|
40
|
+
"@fastkit/tiny-logger": "0.10.0",
|
|
41
41
|
"bezier-easing": "^2.1.0"
|
|
42
42
|
}
|
|
43
43
|
}
|