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

react-native-drag-sort

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-drag-sort - npm Package Compare versions

Comparing version 1.3.5 to 1.3.6

28

DragSortableView.js

@@ -9,6 +9,2 @@ import React, {Component} from 'react'

const touchZIndex = 99
const maxScale = 1.1
const minOpacity = 0.8
const scaleDuration = 100
const slideDuration = 300

@@ -72,4 +68,4 @@ export default class DragSortableView extends Component{

{
toValue: maxScale,
duration: scaleDuration,
toValue: this.props.maxScale,
duration: this.props.scaleDuration,
}

@@ -189,3 +185,3 @@ ).start(()=>{

toValue: {x: parseInt(nextItem.originLeft+0.5),y: parseInt(nextItem.originTop+0.5)},
duration: slideDuration,
duration: this.props.slideDuration,
easing: Easing.out(Easing.quad),

@@ -214,3 +210,3 @@ }

toValue: 1,
duration: scaleDuration,
duration: this.props.scaleDuration,
}

@@ -291,3 +287,3 @@ ).start()

}
//防止RN不绘制开头和结尾
// Prevent RN from drawing the beginning and end
const startItem = this.state.dataSource[startIndex]

@@ -377,4 +373,4 @@ this.state.dataSource[startIndex].position.setValue({

opacity: item.scaleValue.interpolate({
inputRange:[1,maxScale],
outputRange:[1,minOpacity]
inputRange:[1,this.props.maxScale],
outputRange:[1,this.props.minOpacity]
}),

@@ -429,3 +425,7 @@ transform: [transformObj]

isDragFreely: PropTypes.bool,
onDragging: PropTypes.func
onDragging: PropTypes.func,
maxScale: PropTypes.number,
minOpacity: PropTypes.number,
scaleDuration: PropTypes.number,
slideDuration: PropTypes.number
}

@@ -443,2 +443,6 @@

isDragFreely: false,
maxScale: 1.1,
minOpacity: 0.8,
scaleDuration: 100,
slideDuration: 300,
}

@@ -445,0 +449,0 @@

@@ -27,4 +27,9 @@ import React, { Component } from 'react'

onDragging?: (gestureState: any,left: number,top: number) => void;
maxScale?: number;
minOpacity?: number;
scaleDuration?: number;
slideDuration?: number;
}
export default class DragSortableView extends Component<IProps>{}
{
"name": "react-native-drag-sort",
"version": "1.3.5",
"version": "1.3.6",
"description": "Drag and drop sort control for react-native",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -107,2 +107,6 @@ # react-native-drag-sort

- **isDragFreely**: PropTypes.bool, // Whether to limit the drag space
- **onDragging**: PropTypes.func
- **onDragging**: PropTypes.func
- **maxScale**: PropTypes.number;
- **minOpacity**: PropTypes.number;
- **scaleDuration**: PropTypes.number;
- **slideDuration**: PropTypes.number;

Sorry, the diff of this file is not supported yet

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