added weights and custom sorting for tab-items