getHaloDefaultHandle()
function getHaloDefaultHandle(name): HaloHandle;
Builds a React HaloHandle from a built-in ui.Halo default handle
('remove', 'resize', 'rotate', 'fork', 'clone', 'link',
'unlink', 'direction'), with its default tooltip applied. Lets React
callers compose handles without importing ui from @joint/plus.
Parameters
| Parameter | Type | Description |
|---|---|---|
name | DefaultHandles | The built-in default handle name. |
Returns
The React handle config, ready to drop into the <Halo handles> prop.
Example
import { GraphProvider, Paper, Halo, getHaloDefaultHandle } from '@joint/react-plus';
// Keep only the remove and clone handles, relabel the remove button.
<GraphProvider>
<Paper
renderElement={() => (
<Halo
handles={[
{ ...getHaloDefaultHandle('remove'), title: 'Delete' },
getHaloDefaultHandle('clone'),
]}
/>
// Your element rendering here...
)}
/>
</GraphProvider>;