-
Notifications
You must be signed in to change notification settings - Fork 842
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(DragAndDrop): Switch from react-beautiful-dnd to its fork @hello…
…-pangea/dnd (#6868) * feat(DragAndDrop): Switch from react-beautiful-dnd to its fork @hello-pangea/dnd * test(EuiDraggable): add snapshot test for the basic render assertion and rename test cases
- Loading branch information
Showing
17 changed files
with
2,516 additions
and
1,178 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
115 changes: 21 additions & 94 deletions
115
src/components/drag_and_drop/__snapshots__/draggable.test.tsx.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,105 +1,32 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`EuiDraggable can be given ReactElement children 1`] = ` | ||
<div> | ||
exports[`EuiDraggable renders 1`] = ` | ||
<div | ||
class="euiDroppable euiDroppable--noGrow" | ||
data-rfd-droppable-context-id="0" | ||
data-rfd-droppable-id="testDroppable" | ||
data-test-subj="droppable" | ||
> | ||
<div | ||
class="euiDroppable euiDroppable--noGrow" | ||
data-rbd-droppable-context-id="0" | ||
data-rbd-droppable-id="testDroppable" | ||
data-test-subj="droppable" | ||
aria-describedby="rfd-hidden-text-0-hidden-text-0" | ||
class="euiDraggable" | ||
data-rfd-drag-handle-context-id="0" | ||
data-rfd-drag-handle-draggable-id="testDraggable" | ||
data-rfd-draggable-context-id="0" | ||
data-rfd-draggable-id="testDraggable" | ||
data-test-subj="draggable" | ||
draggable="false" | ||
role="button" | ||
tabindex="0" | ||
> | ||
<div | ||
aria-describedby="rbd-hidden-text-0-hidden-text-0" | ||
class="euiDraggable" | ||
data-rbd-drag-handle-context-id="0" | ||
data-rbd-drag-handle-draggable-id="testDraggable" | ||
data-rbd-draggable-context-id="0" | ||
data-rbd-draggable-id="testDraggable" | ||
data-test-subj="draggable" | ||
draggable="false" | ||
role="button" | ||
tabindex="0" | ||
class="euiDraggable__item" | ||
> | ||
<div | ||
class="euiDraggable__item" | ||
> | ||
Hello | ||
</div> | ||
Hello | ||
</div> | ||
<div | ||
class="euiDroppable__placeholder" | ||
/> | ||
</div> | ||
</div> | ||
`; | ||
|
||
exports[`EuiDraggable can be given ReactElement children 2`] = `undefined`; | ||
|
||
exports[`EuiDraggable hasInteractiveChildren renders with role="group" and no tabIndex 1`] = ` | ||
<div> | ||
<div | ||
class="euiDroppable euiDroppable--noGrow" | ||
data-rbd-droppable-context-id="0" | ||
data-rbd-droppable-id="testDroppable" | ||
data-test-subj="droppable" | ||
> | ||
<div | ||
aria-describedby="rbd-hidden-text-0-hidden-text-0" | ||
class="euiDraggable" | ||
data-rbd-drag-handle-context-id="0" | ||
data-rbd-drag-handle-draggable-id="testDraggable" | ||
data-rbd-draggable-context-id="0" | ||
data-rbd-draggable-id="testDraggable" | ||
data-test-subj="draggable" | ||
draggable="false" | ||
role="group" | ||
> | ||
<div | ||
class="euiDraggable__item" | ||
> | ||
Hello | ||
</div> | ||
</div> | ||
<div | ||
class="euiDroppable__placeholder" | ||
/> | ||
</div> | ||
class="euiDroppable__placeholder" | ||
/> | ||
</div> | ||
`; | ||
|
||
exports[`EuiDraggable hasInteractiveChildren renders with role="group" and no tabIndex 2`] = `undefined`; | ||
|
||
exports[`EuiDraggable is rendered 1`] = ` | ||
<div> | ||
<div | ||
class="euiDroppable euiDroppable--noGrow" | ||
data-rbd-droppable-context-id="0" | ||
data-rbd-droppable-id="testDroppable" | ||
data-test-subj="droppable" | ||
> | ||
<div | ||
aria-describedby="rbd-hidden-text-0-hidden-text-0" | ||
class="euiDraggable" | ||
data-rbd-drag-handle-context-id="0" | ||
data-rbd-drag-handle-draggable-id="testDraggable" | ||
data-rbd-draggable-context-id="0" | ||
data-rbd-draggable-id="testDraggable" | ||
data-test-subj="draggable" | ||
draggable="false" | ||
role="button" | ||
tabindex="0" | ||
> | ||
<div | ||
class="euiDraggable__item" | ||
> | ||
Hello | ||
</div> | ||
</div> | ||
<div | ||
class="euiDroppable__placeholder" | ||
/> | ||
</div> | ||
</div> | ||
`; | ||
|
||
exports[`EuiDraggable is rendered 2`] = `undefined`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.