#74 - Integration with Bookmarks core plugin and support for indirect drag & drop arrangement
- adjusted bookmarks integration to the merged from master multi-level sorting support and its implications
This commit is contained in:
parent
d8874629ba
commit
e866023bbf
|
@ -595,13 +595,14 @@ export const determineBookmarksOrderIfNeeded = (folderItems: Array<FolderItemFor
|
|||
if (!plugin) return
|
||||
|
||||
folderItems.forEach((item) => {
|
||||
const folderDefaultSortRequiresBookmarksOrder: boolean = !!(sortingSpec.defaultOrder && sortOrderNeedsBookmarksOrder(sortingSpec.defaultOrder))
|
||||
const folderDefaultSortRequiresBookmarksOrder: boolean = !!(sortingSpec.defaultOrder && sortOrderNeedsBookmarksOrder(sortingSpec.defaultOrder, sortingSpec.defaultSecondaryOrder))
|
||||
let groupSortRequiresBookmarksOrder: boolean = false
|
||||
if (!folderDefaultSortRequiresBookmarksOrder) {
|
||||
const groupIdx: number | undefined = item.groupIdx
|
||||
if (groupIdx !== undefined) {
|
||||
const groupOrder: CustomSortOrder | undefined = sortingSpec.groups[groupIdx].order
|
||||
groupSortRequiresBookmarksOrder = sortOrderNeedsBookmarksOrder(groupOrder)
|
||||
const groupSecondaryOrder: CustomSortOrder | undefined = sortingSpec.groups[groupIdx].secondaryOrder
|
||||
groupSortRequiresBookmarksOrder = sortOrderNeedsBookmarksOrder(groupOrder, groupSecondaryOrder)
|
||||
}
|
||||
}
|
||||
if (folderDefaultSortRequiresBookmarksOrder || groupSortRequiresBookmarksOrder) {
|
||||
|
|
|
@ -223,7 +223,6 @@ const expectedSortSpecsExampleA: { [key: string]: CustomSortSpec } = {
|
|||
type: CustomSortGroupType.ExactName
|
||||
},
|
||||
{
|
||||
order: CustomSortOrder.byBookmarkOrder,
|
||||
type: CustomSortGroupType.Outsiders
|
||||
}
|
||||
],
|
||||
|
|
Loading…
Reference in New Issue