Přidání nového projektu - pokus o explorer
This commit is contained in:
1 parent
b0b0b3ee34
commit
d06a9f332b
48 files changed
+1429
No files matched your search
@@ -0,0 +1,31 @@
|
||||
using System;
|
||||
using System.Globalization;
|
||||
|
||||
namespace winui_learning_2.Helpers;
|
||||
|
||||
public static class DashboardFormatting
|
||||
{
|
||||
public static readonly CultureInfo CzechCulture = CultureInfo.GetCultureInfo("cs-CZ");
|
||||
|
||||
public static string CategoryLabel(string category) => category switch
|
||||
{
|
||||
"win" => "Výhra",
|
||||
"loss" => "Prohra",
|
||||
"bet" => "Výzva",
|
||||
"payment" => "Platba",
|
||||
"team" => "Tým",
|
||||
_ => "Jiné"
|
||||
};
|
||||
|
||||
public static string FormatCount(int value) =>
|
||||
value.ToString("N0", CzechCulture);
|
||||
|
||||
public static string FormatCoins(decimal value) =>
|
||||
$"{value.ToString("N2", CzechCulture)} NC";
|
||||
|
||||
public static string FormatDateTime(DateTime value) =>
|
||||
value.ToString("d. M. yyyy HH:mm", CzechCulture);
|
||||
|
||||
public static string FormatIntroDateTime() =>
|
||||
DateTime.Now.ToString("dddd d. MMMM yyyy, HH:mm", CzechCulture);
|
||||
}
|
||||
Reference in new issue
Block a user