New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

embla-carousel

Package Overview
Dependencies
Maintainers
1
Versions
236
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

embla-carousel - npm Package Compare versions

Comparing version

to
2.2.1

6

lib/components/animation.d.ts
export declare type Animation = {
start: () => Animation;
stop: () => Animation;
proceed: () => Animation;
start: () => void;
stop: () => void;
proceed: () => void;
};
export declare function Animation(callback: FrameRequestCallback): Animation;

@@ -11,3 +11,3 @@ import { Direction } from './direction';

direction: Direction;
update: () => Mover;
update: () => void;
seek: (target: Vector1D) => Mover;

@@ -14,0 +14,0 @@ settle: (target: Vector1D) => boolean;

@@ -15,8 +15,8 @@ import { Animation } from './animation';

export declare type Scroller = {
toNext: () => Scroller;
toPrevious: () => Scroller;
toIndex: (target: number) => Scroller;
toDistance: (force: number) => Scroller;
toNext: () => void;
toPrevious: () => void;
toIndex: (target: number) => void;
toDistance: (force: number) => void;
};
export declare function Scroller(params: Params): Scroller;
export {};
import { Vector1D } from './vector1d';
declare type Translates = 'x' | 'x3d';
export declare type Translate = {
to: (vector: Vector1D) => Translate;
useType: (type: Translates) => Translate;
to: (vector: Vector1D) => void;
};
export declare function Translate(node: HTMLElement): Translate;
export {};

@@ -765,7 +765,3 @@ (function webpackUniversalModuleDefinition(root, factory) {

if (!loop) slider.edgeGuard.constrain(target);
if (slider.mover.settle(target)) {
slider.animation.stop();
slider.translate.useType('x');
}
if (slider.mover.settle(target)) slider.animation.stop();
}

@@ -778,3 +774,3 @@

slider.translate.to(slider.mover.location).useType('x3d');
slider.translate.to(slider.mover.location);
slider.animation.proceed();

@@ -929,3 +925,2 @@ }; // Shared

if (active === !!state.animationFrame) cb();
return self;
};

@@ -1476,3 +1471,2 @@ }

acceleration.multiply(0);
return self;
}

@@ -1483,3 +1477,2 @@

acceleration.add(force);
return self;
}

@@ -1661,4 +1654,2 @@

}
return self;
}

@@ -1669,3 +1660,2 @@

scrollTo(next);
return self;
}

@@ -1676,3 +1666,2 @@

scrollTo(next);
return self;
}

@@ -1683,3 +1672,2 @@

findIndex(next, 0);
return self;
}

@@ -1690,3 +1678,2 @@

findIndex(next, -1);
return self;
}

@@ -1697,3 +1684,2 @@

findIndex(next, 1);
return self;
}

@@ -1928,15 +1914,5 @@

function Translate(node) {
var translate = {
type: 'x'
};
var translates = {
x: x,
x3d: x3d
};
var nodeStyle = node.style;
function x(xValue) {
return "translateX(".concat(xValue, "%)");
}
function x3d(xValue) {
return "translate3d(".concat(xValue, "%,0px,0px)");

@@ -1946,16 +1922,7 @@ }

function to(vector) {
var t = translate.type;
var v = vector.get();
node.style.transform = translates[t](v);
return self;
nodeStyle.transform = x(vector.get());
}
function useType(type) {
translate.type = type;
return self;
}
var self = {
to: to,
useType: useType
to: to
};

@@ -1962,0 +1929,0 @@ return Object.freeze(self);

{
"name": "embla-carousel",
"version": "2.2.0",
"version": "2.2.1",
"author": "David Cetinkaya",

@@ -48,24 +48,24 @@ "private": false,

"devDependencies": {
"@babel/core": "^7.4.4",
"@babel/core": "^7.5.4",
"@babel/plugin-transform-object-assign": "^7.2.0",
"@babel/preset-env": "^7.4.4",
"@types/jest": "^24.0.12",
"@babel/preset-env": "^7.5.4",
"@types/jest": "^24.0.15",
"@types/jest-diff": "^20.0.0",
"autoprefixer": "^9.5.1",
"autoprefixer": "^9.6.1",
"awesome-typescript-loader": "^5.2.1",
"babel-loader": "^8.0.5",
"babel-loader": "^8.0.6",
"clean-webpack-plugin": "^1.0.1",
"jest": "^24.7.1",
"jest": "^24.8.0",
"node-sass": "^4.12.0",
"npm-run-all": "^4.1.5",
"postcss-cli": "^6.1.2",
"prettier": "^1.17.0",
"postcss-cli": "^6.1.3",
"prettier": "^1.18.2",
"ts-jest": "^23.10.5",
"tslint": "^5.16.0",
"tslint": "^5.18.0",
"tslint-config-prettier": "^1.18.0",
"typescript": "^3.4.5",
"webpack": "^4.30.0",
"webpack-cli": "^3.3.1",
"webpack-dev-server": "^3.3.1"
"typescript": "^3.5.3",
"webpack": "^4.35.3",
"webpack-cli": "^3.3.6",
"webpack-dev-server": "^3.7.2"
}
}