diff options
author | Pekka Hyvönen <pekka@vaadin.com> | 2017-05-18 14:11:03 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-18 14:11:03 +0300 |
commit | 88429109c2f8e77fb3a9ef7b5ab51d51e7dcaa58 (patch) | |
tree | c2743e0febb57817f7137cbbe7a1e896e277ef23 /themes | |
parent | 548650bfe02f6e2582f06cecee2333099d951718 (diff) | |
download | vaadin-framework-88429109c2f8e77fb3a9ef7b5ab51d51e7dcaa58.tar.gz vaadin-framework-88429109c2f8e77fb3a9ef7b5ab51d51e7dcaa58.zip |
Show drop hints when dropping in empty Grid (#9353)
Also makes sure that the drop location and target row return something sensible in drop event.
Clarifies docs on drop location.
Diffstat (limited to 'themes')
-rw-r--r-- | themes/src/main/themes/VAADIN/themes/valo/components/_grid.scss | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/themes/src/main/themes/VAADIN/themes/valo/components/_grid.scss b/themes/src/main/themes/VAADIN/themes/valo/components/_grid.scss index 541c38c314..2f6be4a584 100644 --- a/themes/src/main/themes/VAADIN/themes/valo/components/_grid.scss +++ b/themes/src/main/themes/VAADIN/themes/valo/components/_grid.scss @@ -861,7 +861,7 @@ $v-grid-drag-indicator-color: $v-focus-color; top: 0; left: 0; bottom: 0; - right: 0; + right: 2px; border: 2px solid $v-grid-drag-indicator-color; pointer-events: none; } @@ -879,8 +879,22 @@ $v-grid-drag-indicator-color: $v-focus-color; // Expand Grid's body to cover the whole Grid .#{$primary-stylename}-body-droptarget { - width: 100%; - height: 100%; + top: 0; + right: 0; + bottom: 0; + left: 0; + } + // Show drop hint when the grid is empty or, + // if the DropMode.ON_TOP is used and dragging below last row + .#{$primary-stylename}-body-drag-top:after { + content: ""; + position: absolute; + top: 0; + right: 2px; + bottom: 0; + left: 0; + pointer-events: none; + border: 2px solid $v-grid-drag-indicator-color; } } |