mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: restrict drag drop to pin icon, closes #7702
https://github.com/NodeBB/NodeBB/issues/6081
This commit is contained in:
@@ -254,8 +254,7 @@ define('forum/category/tools', [
|
|||||||
}
|
}
|
||||||
|
|
||||||
function handlePinnedTopicSort() {
|
function handlePinnedTopicSort() {
|
||||||
var env = utils.findBootstrapEnvironment();
|
if (!ajaxify.data.privileges.isAdminOrMod) {
|
||||||
if (!ajaxify.data.privileges.isAdminOrMod || env === 'xs' || env === 'sm') {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
app.loadJQueryUI(function () {
|
app.loadJQueryUI(function () {
|
||||||
@@ -263,6 +262,7 @@ define('forum/category/tools', [
|
|||||||
return !$(e).parents('[widget-area]').length;
|
return !$(e).parents('[widget-area]').length;
|
||||||
});
|
});
|
||||||
topicListEl.sortable({
|
topicListEl.sortable({
|
||||||
|
handle: '[component="topic/pinned"]',
|
||||||
items: '[component="category/topic"].pinned',
|
items: '[component="category/topic"].pinned',
|
||||||
update: function () {
|
update: function () {
|
||||||
var data = [];
|
var data = [];
|
||||||
|
|||||||
Reference in New Issue
Block a user