Aller au contenu

box-selection

Ce contenu n’est pas encore disponible dans votre langue.

Interfaces

BoxSelectionParams

Parameters of the box selection Svelte action.

Properties

enabled?
optional enabled: boolean;

Is the box selection active.

Defined in

tmp/commons/src/lib/actions/box-selection.ts:9

holder?
optional holder: HTMLElement;

Element containing the elements to select.

Defined in

tmp/commons/src/lib/actions/box-selection.ts:14

onselection()?
optional onselection: (nodes) => void;

Selection callback.

Parameters

nodes: Element[]

Returns

void

Defined in

tmp/commons/src/lib/actions/box-selection.ts:11

threshold?
optional threshold: number;

Treshold for elements to be considered inside the box selection. Defaults to 0.9.

Defined in

tmp/commons/src/lib/actions/box-selection.ts:17

Functions

boxSelection()

function boxSelection<Node>(...args): void | ActionReturn<undefined | BoxSelectionParams, Record<never, any>>

Action to enable box selection on an element.

Type Parameters

Node extends HTMLElement

Parameters

• …args: [Node, BoxSelectionParams]

Returns

void | ActionReturn<undefined | BoxSelectionParams, Record<never, any>>

Svelte action

Defined in

tmp/commons/src/lib/actions/box-selection.ts:26