editor: fix sortable tab/widget list scroll jumps
This commit is contained in:
parent
a91afaef7f
commit
b32aaabe08
2 changed files with 11 additions and 3 deletions
|
|
@ -153,8 +153,8 @@ var editObject = function(container, data, refresh){
|
|||
}
|
||||
|
||||
list.sortable({
|
||||
forcePlaceholderSize: true,
|
||||
items: '.sortables',
|
||||
placeholder: "sortable-placeholder btn small",
|
||||
start:function(){$(this).sortable( "refreshPositions" )},
|
||||
update: function(e,ui){
|
||||
var prevIndex = $(ui.item).attr('data-index')
|
||||
|
|
@ -208,9 +208,9 @@ var editObject = function(container, data, refresh){
|
|||
}
|
||||
|
||||
list.sortable({
|
||||
start:function(){$(this).sortable( "refreshPositions" )},
|
||||
forcePlaceholderSize: true,
|
||||
items: '.sortables',
|
||||
placeholder: "sortable-placeholder btn small",
|
||||
start:function(){$(this).sortable( "refreshPositions" )},
|
||||
update: function(e,ui){
|
||||
var prevIndex = $(ui.item).attr('data-index')
|
||||
var newIndex = $(ui.item).index()
|
||||
|
|
|
|||
|
|
@ -73,9 +73,17 @@
|
|||
flex-direction: column;
|
||||
ul {
|
||||
padding: 1rem 2rem!important;
|
||||
overflow: auto;
|
||||
li:not(:last-child) {
|
||||
margin-bottom: 2rem!important;
|
||||
}
|
||||
.sortable-placeholder {
|
||||
background: transparent;
|
||||
&:after {
|
||||
content:"|";
|
||||
color: transparent;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
.checkbox {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue