@nosferatu500/react-sortable-tree
Advanced tools
Comparing version 6.0.0-alpha.1 to 6.0.0-alpha.2
@@ -893,3 +893,3 @@ import React, { Component, Children, cloneElement } from 'react'; | ||
rowHeight, | ||
disableDropOutside: _disableDropOutside, | ||
disableDropFromOutside: _disableDropFromOutside, | ||
treeId: _treeId, | ||
@@ -1087,3 +1087,3 @@ getPrevRow: _getPrevRow, | ||
} | ||
if (monitor.getItem().treeId !== treeId && dropTargetProps.disableDropOutside) | ||
if (monitor.getItem().treeId !== treeId && dropTargetProps.disableDropFromOutside) | ||
return false; | ||
@@ -1541,3 +1541,3 @@ const rowAbove = dropTargetProps.getPrevRow(); | ||
} | ||
renderRow(row, { listIndex, style, getPrevRow, matchKeys, swapFrom, swapDepth, swapLength, disableDropOutside }) { | ||
renderRow(row, { listIndex, style, getPrevRow, matchKeys, swapFrom, swapDepth, swapLength, disableDropFromOutside }) { | ||
const { node, parentNode, path, lowerSiblingCounts, treeIndex } = row; | ||
@@ -1578,3 +1578,3 @@ const { canDrag, generateNodeProps, scaffoldBlockPxWidth, searchFocusOffset, rowHeight } = mergeTheme( | ||
swapFrom, | ||
disableDropOutside, | ||
disableDropFromOutside, | ||
swapLength, | ||
@@ -1661,3 +1661,3 @@ swapDepth, | ||
swapLength, | ||
disableDropOutside: this.props.disableDropOutside | ||
disableDropFromOutside: this.props.disableDropFromOutside | ||
}) | ||
@@ -1688,3 +1688,3 @@ }); | ||
}, | ||
disableDropOutside: false, | ||
disableDropFromOutside: false, | ||
placeholderRenderer: void 0, | ||
@@ -1691,0 +1691,0 @@ scaffoldBlockPxWidth: void 0, |
@@ -65,3 +65,3 @@ /// <reference types="react" /> | ||
scaffoldBlockPxWidth?: number; | ||
disableDropOutside?: boolean; | ||
disableDropFromOutside?: boolean; | ||
maxDepth?: number; | ||
@@ -92,3 +92,3 @@ searchMethod?: (params: SearchParams) => boolean; | ||
canNodeHaveChildren?: (node: any) => boolean; | ||
shouldCopyOnOutsideDrop?: (params: ShouldCopyOnOutsideDropParams) => boolean | boolean; | ||
shouldCopyOnOutsideDrop?: ((params: ShouldCopyOnOutsideDropParams) => boolean) | boolean; | ||
onVisibilityToggle?: (params: OnVisibilityToggleParams) => void; | ||
@@ -95,0 +95,0 @@ dndType?: string; |
12
index.js
@@ -1140,3 +1140,3 @@ 'use strict'; | ||
rowHeight, | ||
disableDropOutside: _disableDropOutside, | ||
disableDropFromOutside: _disableDropFromOutside, | ||
treeId: _treeId, | ||
@@ -1371,3 +1371,3 @@ getPrevRow: _getPrevRow, | ||
if (monitor.getItem().treeId !== treeId && dropTargetProps.disableDropOutside) return false; | ||
if (monitor.getItem().treeId !== treeId && dropTargetProps.disableDropFromOutside) return false; | ||
const rowAbove = dropTargetProps.getPrevRow(); | ||
@@ -1931,3 +1931,3 @@ const abovePath = rowAbove ? rowAbove.path : []; | ||
swapLength, | ||
disableDropOutside | ||
disableDropFromOutside | ||
}) { | ||
@@ -1978,3 +1978,3 @@ const { | ||
swapFrom: swapFrom, | ||
disableDropOutside: disableDropOutside, | ||
disableDropFromOutside: disableDropFromOutside, | ||
swapLength: swapLength, | ||
@@ -2082,3 +2082,3 @@ swapDepth: swapDepth, | ||
swapLength, | ||
disableDropOutside: this.props.disableDropOutside | ||
disableDropFromOutside: this.props.disableDropFromOutside | ||
}) | ||
@@ -2111,3 +2111,3 @@ }); | ||
onVisibilityToggle: () => {}, | ||
disableDropOutside: false, | ||
disableDropFromOutside: false, | ||
placeholderRenderer: undefined, | ||
@@ -2114,0 +2114,0 @@ scaffoldBlockPxWidth: undefined, |
{ | ||
"name": "@nosferatu500/react-sortable-tree", | ||
"version": "6.0.0-alpha.1", | ||
"version": "6.0.0-alpha.2", | ||
"description": "Drag-and-drop sortable component for nested data and hierarchies", | ||
@@ -5,0 +5,0 @@ "main": "./index.js", |
@@ -65,3 +65,3 @@ /// <reference types="react" /> | ||
scaffoldBlockPxWidth?: number; | ||
disableDropOutside?: boolean; | ||
disableDropFromOutside?: boolean; | ||
maxDepth?: number; | ||
@@ -92,3 +92,3 @@ searchMethod?: (params: SearchParams) => boolean; | ||
canNodeHaveChildren?: (node: any) => boolean; | ||
shouldCopyOnOutsideDrop?: (params: ShouldCopyOnOutsideDropParams) => boolean | boolean; | ||
shouldCopyOnOutsideDrop?: ((params: ShouldCopyOnOutsideDropParams) => boolean) | boolean; | ||
onVisibilityToggle?: (params: OnVisibilityToggleParams) => void; | ||
@@ -95,0 +95,0 @@ dndType?: string; |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
234608