diff --git a/apps/spreadsheeteditor/main/app/view/PivotSettings.js b/apps/spreadsheeteditor/main/app/view/PivotSettings.js index cad6fdc1b..e72fbd574 100644 --- a/apps/spreadsheeteditor/main/app/view/PivotSettings.js +++ b/apps/spreadsheeteditor/main/app/view/PivotSettings.js @@ -216,12 +216,12 @@ define([ onDragItemEnter: function (item, index, event) { event.preventDefault(); - item.$el.css({'border-top-color': '#b7b7b7'}); + item.$el.addClass('insert'); this.indexMoveTo = index; }, onDragItemLeave: function (item, index, event) { - item.$el.css({'border-top-color': '#fafafa'}); + item.$el.removeClass('insert'); this.indexMoveTo = undefined; }, @@ -231,7 +231,7 @@ define([ } else { event.preventDefault(); // Necessary. Allows us to drop. event.originalEvent.dataTransfer.dropEffect = 'move'; - item.$el.css({'border-top-color': '#b7b7b7'}); + item.$el.addClass('insert'); this.indexMoveTo = index; return false; } @@ -248,13 +248,13 @@ define([ } else { event.preventDefault(); // Necessary. Allows us to drop. event.originalEvent.dataTransfer.dropEffect = 'move'; - listview.$el.find('.item').last().css({'border-bottom-color': '#b7b7b7'}); + listview.$el.find('.item').last().addClass('insert last'); return false; } }, onDragLeave: function (listview, event) { - listview.$el.find('.item').css({'border-top-color': '#fafafa', 'border-bottom-color': '#ddd'}); + listview.$el.find('.item').removeClass('insert last'); }, onDrop: function (event) { diff --git a/apps/spreadsheeteditor/main/resources/less/rightmenu.less b/apps/spreadsheeteditor/main/resources/less/rightmenu.less index 2d16d42e1..7e14a0537 100644 --- a/apps/spreadsheeteditor/main/resources/less/rightmenu.less +++ b/apps/spreadsheeteditor/main/resources/less/rightmenu.less @@ -388,8 +388,18 @@ button:active:not(.disabled) .btn-change-shape {background-position: -56px - width: 95px; height: 130px; - .item { + .listview:not(.disabled) > .item { padding: 3px; + border-top: none; + &.insert { + background: linear-gradient(to bottom, #656565, #fff 5%); + &.last { + background: linear-gradient(to top, #656565, #fff 5%); + } + } + &:hover { + border-top: none; + } } .list-item > div:nth-child(1) {