mirror of
https://github.com/DrMboga/WotBlitzStatisticsBlazor.git
synced 2026-10-23 19:30:06 +02:00
feat: Search player component implemented. Plus Winrate color schale implementation
This commit is contained in:
1 parent
edfc9aa139
commit
4fb56c3b16
10 files changed
+160
-4
No files matched your search
@@ -0,0 +1,21 @@
|
||||
namespace WotBlitzStatisticsPro.Blazor.Helpers
|
||||
{
|
||||
public static class ScaleHelper
|
||||
{
|
||||
public static string ScaleColor(this int winRate)
|
||||
{
|
||||
return winRate switch
|
||||
{
|
||||
( > 0 ) and ( < 45) => Constants.ScaleVeryBadColor,
|
||||
( >= 45 ) and ( < 47 ) => Constants.ScaleBadColor,
|
||||
( >= 47 ) and ( < 49 ) => Constants.ScaleBelowAverageColor,
|
||||
( >= 49 ) and ( < 52 ) => Constants.ScaleAverageColor,
|
||||
( >= 52 ) and ( < 54 ) => Constants.ScaleGoodColor,
|
||||
( >= 54 ) and ( < 56 ) => Constants.ScaleVeryGoodColor,
|
||||
( >= 56 ) and ( < 60 ) => Constants.ScaleGreatColor,
|
||||
( >= 60 ) and ( < 65 ) => Constants.ScaleUnicumColor,
|
||||
_ => Constants.ScaleSuperUnicumColor
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user