MCPcopy Create free account
hub / github.com/adobe/react-spectrum / onMove

Function onMove

examples/s2-parcel-example/src/App.js:209–215  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

207 }),
208 getAllowedDropOperations: () => ['move'],
209 onMove(e) {
210 if (e.target.dropPosition === 'before') {
211 treeData.moveBefore(e.target.key, e.keys);
212 } else if (e.target.dropPosition === 'after') {
213 treeData.moveAfter(e.target.key, e.keys);
214 }
215 }
216 });
217 return (
218 <TreeView

Callers

nothing calls this directly

Calls 2

moveBeforeMethod · 0.65
moveAfterMethod · 0.65

Tested by

no test coverage detected