shadow
Reorder
je komponent, ktorý umožňuje pomocou funkcionality Drag&Drop, zmeniť poradie položky ReorderItem
v skupine.
Atribút disabled
sa používa na zakázanie možnosti preusporiadania položiek v rámci Reorder
. Keď je tento atribút nastavený, používateľ nebude môcť ťahať položky na zmenu ich poradia.
Pridaním elementu do slotu handle
položky ReorderItem, môžete definovať špecifickú oblasť, ktorá bude slúžiť ako rukoväť pre ťahanie a preusporiadanie položiek. Toto umožňuje používateľom intuitívnejšie interakcie pri zmene poradia položiek.
Atribút reverse
sa používa na zmenu smeru preusporiadania položiek v rámci Reorder
.
DropZone je komponent, ktorý predstavuje zónu určenú pre preusporiadanie obsahu.
Description | If true , rearrangement is disabled. |
Attribute | disabled |
Type | boolean |
Default | false |
Description | If true , the direction of rearrangement is reversed (bottom-up). |
Attribute | reverse |
Type | boolean |
Default | false |
Name | Description |
---|
wje-reorder:change | Invoked when changing the order of elements. |
Description | Connects event listeners to the element. |
Signature | attachEventListeners(element) => void |
Description | Initializes the pull process for the reorderable element. |
Signature | startDragging(clientX, clientY, target) => void |
Description | Updates the position of the dragged element and manages the reordering logic based on the mouse position. |
Signature | moveElement(pageX, pageY) => void |
Description | Stops the element from dragging. |
Signature | stopDragging() => void |
Description | Transmits a custom event signaling that a rearrangement has occurred. |
Signature | dispatchChange(from, to, order) => void |
Name | Description |
---|
native | The native part of the reorder component, containing the slot. |
Name | Description |
---|
--flex-direction | Direction of flexbox for container |
Name | Description |
---|
`` | The default location of the element content. This includes elements of type wje-reorder-item. |