OOUI/Elements/Draggable/fr

OOUI comes with two mixins that wrap around the HTML5 Drag and Drop API, ' et '. These OOUI implementations ease the use of the API. By default: Pour pouvoir fonctionner, un élément déplaçable doit être dans un conteneur qui est un élément de groupe déplaçable.
 * is a.
 * est un.

Un objet DraggableGroupElement va agréger les événements du déplacement (dragend, dragstart, et drop) en écoutant chaque fils, et en les réorganisant en conséquence.

Configuration
A draggable group element can have two different orientations, vertical and horizontal. These orientations control how the draggable elements within the container will be positioned relative to each other.

It's possible to configure what part of a draggable element can be dragged in. By default, the entire element is draggable.
 * When the orientation is vertical, the elements inside will be inline blocks, sitting next to each other and cross over to the next line when the line is filled up.
 * When the orientation is horizontal, the elements will be blocks, sitting on top of each other.

Events
Un objet  émet ces événements de déplacement :


 * indicates that the user released their mouse after dragging an item, which ends the drag operation.
 * indicates that the user clicks and hold their mouse on an item and is starting to drag the item.
 * indicates that the user released their mouse on an item onto a valid target.

Un  émet les éléments de déplacement suivants :


 * indicates that the user is dragging an item to a new position, but hasn't dropped it yet.
 * indicates that the draggable state has changed.

Exemples
The below example shows a drag operation being done inside a vertical-oriented DraggableGroupElement, with handles. This is available from the OOUI demo, which you can interact with.