Okay, well I made something although it's not exactly what you wanted, it's similar and with some editing I'm sure you can acheive what you want. Although the way I've done this I believe isn't the best and effecient way, it gets the job done. Sorry I couldn't help anymore.
HTML
Code:
<ul id="list">
<li value="100">100</li>
<li value="32">32</li>
<li value="68">68</li>
<li value="5">5</li>
</ul>
<input id="submit" type="submit" value="Add List Item">
<input id="value" type="text" value="20">
JavaScript
Code:
function sortDesc(a, b)
{
return (b - a);
}
$('#submit').click(function(){
var value = $('#value').val();
$('#list').append('<li value="'+value+'">'+value+'</li>\n');
list = new Array();
jQuery.each($('#list > li'), function(){
list = list.concat($(this).attr('value'))
});
list.sort(sortDesc);
$('#list').children().remove();
jQuery.each(list, function(){
$('#list').append('<li value="'+this+'">'+this+'</li>\n');
});
});
Should be noted I don't believe the value attribute is valid.. so maybe look into something else?
Preview: http://pastebin.me/49dda6757604b