From ef360476df3f81f88ea85bc31cfc9ff9ab9a36c9 Mon Sep 17 00:00:00 2001
From: schneefux <schneefux+commit@schneefux.xyz>
Date: Fri, 13 Jul 2018 12:30:25 +0200
Subject: HeroTalentTable: Sort by rarity

---
 src/HeroTalentTable.vue | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

(limited to 'src/HeroTalentTable.vue')

diff --git a/src/HeroTalentTable.vue b/src/HeroTalentTable.vue
index dc2098c..c4a1c5f 100644
--- a/src/HeroTalentTable.vue
+++ b/src/HeroTalentTable.vue
@@ -61,7 +61,8 @@ export default Vue.component('hero-talent-table', {
     },
     heroReport: function() {
       return ReportService.getReport(this.selectedMode)
-          .filter((entry) => entry.Actor == this.selectedActor);
+          .filter((entry) => entry.Actor == this.selectedActor)
+          .sort((entry1, entry2) => maps.getTalentRarityIndex(entry1.Talent) - maps.getTalentRarityIndex(entry2.Talent));
     },
     totalHeroPicks: function() {
       return this.heroReport
-- 
cgit v1.3.1

