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

Function onMove

examples/s2-next-macros/src/app/page.tsx:213–219  ·  view source on GitHub ↗
(e)

Source from the content-addressed store, hash-verified

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

Callers

nothing calls this directly

Calls 2

moveBeforeMethod · 0.65
moveAfterMethod · 0.65

Tested by

no test coverage detected