Socket
Socket
Sign inDemoInstall

@img-comparison-slider/react

Package Overview
Dependencies
1
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 8.0.1 to 8.0.2

10

dist/index.js

@@ -27,9 +27,9 @@ "use strict";

}
exports.ImgComparisonSlider = (0, react_1.forwardRef)(({ children, onSlide, ...props }, ref) => {
exports.ImgComparisonSlider = (0, react_1.forwardRef)(({ children, onSlide, value, className, ...props }, ref) => {
const sliderRef = (0, react_1.useRef)();
(0, react_1.useEffect)(() => {
if (props.value !== undefined) {
sliderRef.current.value = parseFloat(props.value.toString());
if (value !== undefined) {
sliderRef.current.value = parseFloat(value.toString());
}
}, [props.value, sliderRef]);
}, [value, sliderRef]);
(0, react_1.useEffect)(() => {

@@ -43,3 +43,3 @@ if (onSlide) {

return (0, react_1.createElement)('img-comparison-slider', Object.assign({
class: props.className ? `${props.className} rendered` : 'rendered',
class: className ? `${className} rendered` : 'rendered',
// Align tabIndex between the web and React components

@@ -46,0 +46,0 @@ // this code could be removed when

{
"name": "@img-comparison-slider/react",
"version": "8.0.1",
"version": "8.0.2",
"description": "React wrapper for img-comparison-slider",

@@ -5,0 +5,0 @@ "homepage": "https://img-comparison-slider.sneas.io",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc