sorting sidebar elements