fix sorting for dokuwiki syntax
This commit is contained in:
@@ -131,6 +131,10 @@ function orderStringSorter(a,b) {
|
|||||||
var bValue=b.children[1].innerHTML.substring(0,3);
|
var bValue=b.children[1].innerHTML.substring(0,3);
|
||||||
if ( aValue == "[x]" && bValue == "[ ]" ) return 1;
|
if ( aValue == "[x]" && bValue == "[ ]" ) return 1;
|
||||||
if ( aValue == "[ ]" && bValue == "[x]" ) return -1;
|
if ( aValue == "[ ]" && bValue == "[x]" ) return -1;
|
||||||
|
var aDone = new RegExp("\\(.+\\)$").test(a.children[1].innerHTML);
|
||||||
|
var bDone = new RegExp("\\(.+\\)$").test(b.children[1].innerHTML);
|
||||||
|
if ( aDone && ! bDone ) return 1;
|
||||||
|
if ( bDone && ! aDone ) return -1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -149,4 +153,3 @@ document.onscroll = function(event) {
|
|||||||
document.cookie = "position=" + window.scrollY + "; path=" + window.location.pathname;
|
document.cookie = "position=" + window.scrollY + "; path=" + window.location.pathname;
|
||||||
}
|
}
|
||||||
window.onload = scrollBack;
|
window.onload = scrollBack;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user