Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@splidejs/react-splide

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@splidejs/react-splide - npm Package Compare versions

Comparing version 0.2.1 to 0.3.0

webpack.config.js

25

dist/js/components/Splide.js

@@ -165,2 +165,17 @@ "use strict";

/**
* Render the track element.
*
* @return {ReactNode}
*/
}, {
key: "renderTrack",
value: function renderTrack() {
return /*#__PURE__*/_react["default"].createElement("div", {
className: "splide__track"
}, /*#__PURE__*/_react["default"].createElement("ul", {
className: "splide__list"
}, this.props.children));
}
/**
* Render the component.

@@ -175,5 +190,5 @@ *

var _this$props2 = this.props,
children = _this$props2.children,
id = _this$props2.id,
className = _this$props2.className,
hasSliderWrapper = _this$props2.hasSliderWrapper,
hasAutoplayProgress = _this$props2.hasAutoplayProgress,

@@ -191,7 +206,5 @@ hasAutoplayControls = _this$props2.hasAutoplayControls,

ref: this.splideRef
}, /*#__PURE__*/_react["default"].createElement("div", {
className: "splide__track"
}, /*#__PURE__*/_react["default"].createElement("ul", {
className: "splide__list"
}, children)), hasAutoplayProgress && /*#__PURE__*/_react["default"].createElement("div", {
}, hasSliderWrapper && /*#__PURE__*/_react["default"].createElement("div", {
className: "splide__slider"
}, this.renderTrack()), !hasSliderWrapper && this.renderTrack(), hasAutoplayProgress && /*#__PURE__*/_react["default"].createElement("div", {
className: "splide__progress"

@@ -198,0 +211,0 @@ }, /*#__PURE__*/_react["default"].createElement("div", {

@@ -36,7 +36,5 @@ "use strict";

for (var _i = 0, _args = args; _i < _args.length; _i++) {
var className = _args[_i];
args.forEach(function (className) {
if (!className) {
continue;
return;
}

@@ -47,11 +45,10 @@

} else if (_typeof(className) === 'object') {
for (var key in className) {
Object.keys(className).forEach(function (key) {
if (className[key]) {
names.push(key);
}
}
});
}
}
});
return names.join(' ');
}
{
"name": "@splidejs/react-splide",
"version": "0.2.1",
"version": "0.3.0",
"description": "The Splide component for React.",

@@ -39,3 +39,4 @@ "author": "Naotoshi Fujita",

"css-loader": "^3.5.3",
"gulp": "^4.0.2",
"gh-pages": "^3.0.0",
"html-webpack-plugin": "^4.3.0",
"node-sass": "^4.14.1",

@@ -48,8 +49,10 @@ "react": "^16.13.1",

"webpack": "^4.43.0",
"webpack-stream": "^5.2.1"
"webpack-cli": "^3.3.11"
},
"scripts": {
"build:example": "gulp build:js",
"transpile": "babel src/js -d dist/js --copy-files"
"build": "webpack --mode production",
"deploy": "gh-pages -d examples/dist",
"transpile": "babel src/js -d dist/js --copy-files",
"publish": "npm publish"
}
}

@@ -103,2 +103,17 @@ /**

/**
* Render the track element.
*
* @return {ReactNode}
*/
renderTrack() {
return (
<div className="splide__track">
<ul className="splide__list">
{ this.props.children }
</ul>
</div>
);
}
/**
* Render the component.

@@ -110,5 +125,5 @@ *

const {
children,
id,
className,
hasSliderWrapper,
hasAutoplayProgress,

@@ -127,8 +142,10 @@ hasAutoplayControls,

>
<div className="splide__track">
<ul className="splide__list">
{ children }
</ul>
</div>
{ hasSliderWrapper &&
<div className="splide__slider">
{ this.renderTrack() }
</div>
}
{ ! hasSliderWrapper && this.renderTrack() }
{ hasAutoplayProgress &&

@@ -135,0 +152,0 @@ <div className="splide__progress">

@@ -21,5 +21,5 @@ /**

for ( let className of args ) {
args.forEach( className => {
if ( ! className ) {
continue;
return;
}

@@ -30,11 +30,11 @@

} else if ( typeof className === 'object' ) {
for ( let key in className ) {
Object.keys( className ).forEach( key => {
if ( className[ key ] ) {
names.push( key );
}
}
} );
}
}
} );
return names.join( ' ' );
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc