[Issue#283] Shows list items that have preferences at the top

I added another document fragment which gets all the elements that have their data-pref attribute set and then goes on to append itself at the top of the list when the user sorts it.