mirror of
https://github.com/DorkSquadRR/DorkNet.git
synced 2026-10-26 15:38:45 -07:00
cce20ebdb6
- Implemented main application structure using .NET MAUI. - Added App class to manage navigation between Login and Admin pages. - Created AppDesign class for consistent UI styling. - Developed pages: LoginPage, DashboardPage, PlayersPage, RoomsPage, SettingsPage, and AdminTabbedPage. - Integrated AdminApiClient for API interactions and SecureAdminSettings for secure storage of sensitive data. - Configured Android and iOS platform-specific files including manifest and app delegate. - Added README with build instructions and authentication details.
40 lines
1.0 KiB
C#
40 lines
1.0 KiB
C#
using Microsoft.Extensions.DependencyInjection;
|
|
using Microsoft.Maui.Controls;
|
|
using DorkNet.AdminMobile.Design;
|
|
using DorkNet.AdminMobile.Pages;
|
|
|
|
namespace DorkNet.AdminMobile;
|
|
|
|
public class App : Application
|
|
{
|
|
public App(LoginPage loginPage)
|
|
{
|
|
UserAppTheme = AppTheme.Dark;
|
|
MainPage = new NavigationPage(loginPage)
|
|
{
|
|
BarBackgroundColor = AppDesign.Canvas,
|
|
BarTextColor = AppDesign.Text,
|
|
};
|
|
}
|
|
|
|
public static void ShowAdmin()
|
|
{
|
|
Current!.MainPage = new NavigationPage(
|
|
AppServices.Services.GetRequiredService<AdminTabbedPage>())
|
|
{
|
|
BarBackgroundColor = AppDesign.Canvas,
|
|
BarTextColor = AppDesign.Text,
|
|
};
|
|
}
|
|
|
|
public static void ShowLogin()
|
|
{
|
|
Current!.MainPage = new NavigationPage(
|
|
AppServices.Services.GetRequiredService<LoginPage>())
|
|
{
|
|
BarBackgroundColor = AppDesign.Canvas,
|
|
BarTextColor = AppDesign.Text,
|
|
};
|
|
}
|
|
}
|