From d11a90f316e6e5bb140301ccea77839bd8f43ba2 Mon Sep 17 00:00:00 2001 From: Nils Pukropp Date: Sun, 20 Apr 2025 22:49:25 +0200 Subject: [PATCH] init --- QuickDish.sln | 55 +++ .../Controllers/WeatherForecastController.cs | 32 ++ src/QuickDish.Api/Program.cs | 25 + .../Properties/launchSettings.json | 41 ++ src/QuickDish.Api/QuickDish.Api.csproj | 18 + src/QuickDish.Api/QuickDish.Api.http | 6 + src/QuickDish.Api/WeatherForecast.cs | 12 + .../appsettings.Development.json | 8 + src/QuickDish.Api/appsettings.json | 9 + src/QuickDish.Application/Class1.cs | 6 + .../QuickDish.Application.csproj | 13 + src/QuickDish.Client/App.xaml | 14 + src/QuickDish.Client/App.xaml.cs | 11 + src/QuickDish.Client/AppShell.xaml | 15 + src/QuickDish.Client/AppShell.xaml.cs | 9 + src/QuickDish.Client/MainPage.xaml | 36 ++ src/QuickDish.Client/MainPage.xaml.cs | 24 + src/QuickDish.Client/MauiProgram.cs | 24 + .../Platforms/Android/AndroidManifest.xml | 6 + .../Platforms/Android/MainActivity.cs | 10 + .../Platforms/Android/MainApplication.cs | 15 + .../Android/Resources/values/colors.xml | 6 + .../Platforms/MacCatalyst/AppDelegate.cs | 9 + .../Platforms/MacCatalyst/Entitlements.plist | 14 + .../Platforms/MacCatalyst/Info.plist | 38 ++ .../Platforms/MacCatalyst/Program.cs | 15 + src/QuickDish.Client/Platforms/Tizen/Main.cs | 16 + .../Platforms/Tizen/tizen-manifest.xml | 15 + .../Platforms/Windows/App.xaml | 8 + .../Platforms/Windows/App.xaml.cs | 24 + .../Platforms/Windows/Package.appxmanifest | 46 ++ .../Platforms/Windows/app.manifest | 15 + .../Platforms/iOS/AppDelegate.cs | 9 + src/QuickDish.Client/Platforms/iOS/Info.plist | 32 ++ src/QuickDish.Client/Platforms/iOS/Program.cs | 15 + .../iOS/Resources/PrivacyInfo.xcprivacy | 51 +++ .../Properties/launchSettings.json | 8 + src/QuickDish.Client/QuickDish.Client.csproj | 65 +++ .../Resources/AppIcon/appicon.svg | 4 + .../Resources/AppIcon/appiconfg.svg | 8 + .../Resources/Fonts/OpenSans-Regular.ttf | Bin 0 -> 107276 bytes .../Resources/Fonts/OpenSans-Semibold.ttf | Bin 0 -> 111184 bytes .../Resources/Images/dotnet_bot.png | Bin 0 -> 69811 bytes .../Resources/Raw/AboutAssets.txt | 15 + .../Resources/Splash/splash.svg | 8 + .../Resources/Styles/Colors.xaml | 45 ++ .../Resources/Styles/Styles.xaml | 427 ++++++++++++++++++ src/QuickDish.Domain/Class1.cs | 6 + src/QuickDish.Domain/QuickDish.Domain.csproj | 9 + src/QuickDish.Infrastructure/Class1.cs | 6 + .../QuickDish.Infrastructure.csproj | 13 + 51 files changed, 1316 insertions(+) create mode 100644 QuickDish.sln create mode 100644 src/QuickDish.Api/Controllers/WeatherForecastController.cs create mode 100644 src/QuickDish.Api/Program.cs create mode 100644 src/QuickDish.Api/Properties/launchSettings.json create mode 100644 src/QuickDish.Api/QuickDish.Api.csproj create mode 100644 src/QuickDish.Api/QuickDish.Api.http create mode 100644 src/QuickDish.Api/WeatherForecast.cs create mode 100644 src/QuickDish.Api/appsettings.Development.json create mode 100644 src/QuickDish.Api/appsettings.json create mode 100644 src/QuickDish.Application/Class1.cs create mode 100644 src/QuickDish.Application/QuickDish.Application.csproj create mode 100644 src/QuickDish.Client/App.xaml create mode 100644 src/QuickDish.Client/App.xaml.cs create mode 100644 src/QuickDish.Client/AppShell.xaml create mode 100644 src/QuickDish.Client/AppShell.xaml.cs create mode 100644 src/QuickDish.Client/MainPage.xaml create mode 100644 src/QuickDish.Client/MainPage.xaml.cs create mode 100644 src/QuickDish.Client/MauiProgram.cs create mode 100644 src/QuickDish.Client/Platforms/Android/AndroidManifest.xml create mode 100644 src/QuickDish.Client/Platforms/Android/MainActivity.cs create mode 100644 src/QuickDish.Client/Platforms/Android/MainApplication.cs create mode 100644 src/QuickDish.Client/Platforms/Android/Resources/values/colors.xml create mode 100644 src/QuickDish.Client/Platforms/MacCatalyst/AppDelegate.cs create mode 100644 src/QuickDish.Client/Platforms/MacCatalyst/Entitlements.plist create mode 100644 src/QuickDish.Client/Platforms/MacCatalyst/Info.plist create mode 100644 src/QuickDish.Client/Platforms/MacCatalyst/Program.cs create mode 100644 src/QuickDish.Client/Platforms/Tizen/Main.cs create mode 100644 src/QuickDish.Client/Platforms/Tizen/tizen-manifest.xml create mode 100644 src/QuickDish.Client/Platforms/Windows/App.xaml create mode 100644 src/QuickDish.Client/Platforms/Windows/App.xaml.cs create mode 100644 src/QuickDish.Client/Platforms/Windows/Package.appxmanifest create mode 100644 src/QuickDish.Client/Platforms/Windows/app.manifest create mode 100644 src/QuickDish.Client/Platforms/iOS/AppDelegate.cs create mode 100644 src/QuickDish.Client/Platforms/iOS/Info.plist create mode 100644 src/QuickDish.Client/Platforms/iOS/Program.cs create mode 100644 src/QuickDish.Client/Platforms/iOS/Resources/PrivacyInfo.xcprivacy create mode 100644 src/QuickDish.Client/Properties/launchSettings.json create mode 100644 src/QuickDish.Client/QuickDish.Client.csproj create mode 100644 src/QuickDish.Client/Resources/AppIcon/appicon.svg create mode 100644 src/QuickDish.Client/Resources/AppIcon/appiconfg.svg create mode 100644 src/QuickDish.Client/Resources/Fonts/OpenSans-Regular.ttf create mode 100644 src/QuickDish.Client/Resources/Fonts/OpenSans-Semibold.ttf create mode 100644 src/QuickDish.Client/Resources/Images/dotnet_bot.png create mode 100644 src/QuickDish.Client/Resources/Raw/AboutAssets.txt create mode 100644 src/QuickDish.Client/Resources/Splash/splash.svg create mode 100644 src/QuickDish.Client/Resources/Styles/Colors.xaml create mode 100644 src/QuickDish.Client/Resources/Styles/Styles.xaml create mode 100644 src/QuickDish.Domain/Class1.cs create mode 100644 src/QuickDish.Domain/QuickDish.Domain.csproj create mode 100644 src/QuickDish.Infrastructure/Class1.cs create mode 100644 src/QuickDish.Infrastructure/QuickDish.Infrastructure.csproj diff --git a/QuickDish.sln b/QuickDish.sln new file mode 100644 index 0000000..23c0569 --- /dev/null +++ b/QuickDish.sln @@ -0,0 +1,55 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.0.31903.59 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "QuickDish.Domain", "src\QuickDish.Domain\QuickDish.Domain.csproj", "{63C229FA-5E13-457A-868E-25B0C9C58AA6}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "QuickDish.Application", "src\QuickDish.Application\QuickDish.Application.csproj", "{A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "QuickDish.Infrastructure", "src\QuickDish.Infrastructure\QuickDish.Infrastructure.csproj", "{86A26505-418B-49A8-99B6-52DE52C1B2F4}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "QuickDish.Api", "src\QuickDish.Api\QuickDish.Api.csproj", "{21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "QuickDish.Client", "src\QuickDish.Client\QuickDish.Client.csproj", "{AAEC702A-326A-40B8-9E02-04767A66D084}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {63C229FA-5E13-457A-868E-25B0C9C58AA6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {63C229FA-5E13-457A-868E-25B0C9C58AA6}.Debug|Any CPU.Build.0 = Debug|Any CPU + {63C229FA-5E13-457A-868E-25B0C9C58AA6}.Release|Any CPU.ActiveCfg = Release|Any CPU + {63C229FA-5E13-457A-868E-25B0C9C58AA6}.Release|Any CPU.Build.0 = Release|Any CPU + {A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B}.Debug|Any CPU.Build.0 = Debug|Any CPU + {A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B}.Release|Any CPU.ActiveCfg = Release|Any CPU + {A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B}.Release|Any CPU.Build.0 = Release|Any CPU + {86A26505-418B-49A8-99B6-52DE52C1B2F4}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {86A26505-418B-49A8-99B6-52DE52C1B2F4}.Debug|Any CPU.Build.0 = Debug|Any CPU + {86A26505-418B-49A8-99B6-52DE52C1B2F4}.Release|Any CPU.ActiveCfg = Release|Any CPU + {86A26505-418B-49A8-99B6-52DE52C1B2F4}.Release|Any CPU.Build.0 = Release|Any CPU + {21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB}.Debug|Any CPU.Build.0 = Debug|Any CPU + {21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB}.Release|Any CPU.ActiveCfg = Release|Any CPU + {21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB}.Release|Any CPU.Build.0 = Release|Any CPU + {AAEC702A-326A-40B8-9E02-04767A66D084}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {AAEC702A-326A-40B8-9E02-04767A66D084}.Debug|Any CPU.Build.0 = Debug|Any CPU + {AAEC702A-326A-40B8-9E02-04767A66D084}.Release|Any CPU.ActiveCfg = Release|Any CPU + {AAEC702A-326A-40B8-9E02-04767A66D084}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(NestedProjects) = preSolution + {63C229FA-5E13-457A-868E-25B0C9C58AA6} = {BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB} + {A53CDB6D-8EAD-4C1D-A175-A64C90CF4B6B} = {BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB} + {86A26505-418B-49A8-99B6-52DE52C1B2F4} = {BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB} + {21F9F0FA-71DD-42ED-AAB4-88AF11F8B6AB} = {BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB} + {AAEC702A-326A-40B8-9E02-04767A66D084} = {BEDF4556-0366-45BC-B0F3-9FF4EB11B9CB} + EndGlobalSection +EndGlobal diff --git a/src/QuickDish.Api/Controllers/WeatherForecastController.cs b/src/QuickDish.Api/Controllers/WeatherForecastController.cs new file mode 100644 index 0000000..a770abe --- /dev/null +++ b/src/QuickDish.Api/Controllers/WeatherForecastController.cs @@ -0,0 +1,32 @@ +using Microsoft.AspNetCore.Mvc; + +namespace QuickDish.Api.Controllers; + +[ApiController] +[Route("[controller]")] +public class WeatherForecastController : ControllerBase +{ + private static readonly string[] Summaries = new[] + { + "Freezing", "Bracing", "Chilly", "Cool", "Mild", "Warm", "Balmy", "Hot", "Sweltering", "Scorching" + }; + + private readonly ILogger _logger; + + public WeatherForecastController(ILogger logger) + { + _logger = logger; + } + + [HttpGet(Name = "GetWeatherForecast")] + public IEnumerable Get() + { + return Enumerable.Range(1, 5).Select(index => new WeatherForecast + { + Date = DateOnly.FromDateTime(DateTime.Now.AddDays(index)), + TemperatureC = Random.Shared.Next(-20, 55), + Summary = Summaries[Random.Shared.Next(Summaries.Length)] + }) + .ToArray(); + } +} diff --git a/src/QuickDish.Api/Program.cs b/src/QuickDish.Api/Program.cs new file mode 100644 index 0000000..48863a6 --- /dev/null +++ b/src/QuickDish.Api/Program.cs @@ -0,0 +1,25 @@ +var builder = WebApplication.CreateBuilder(args); + +// Add services to the container. + +builder.Services.AddControllers(); +// Learn more about configuring Swagger/OpenAPI at https://aka.ms/aspnetcore/swashbuckle +builder.Services.AddEndpointsApiExplorer(); +builder.Services.AddSwaggerGen(); + +var app = builder.Build(); + +// Configure the HTTP request pipeline. +if (app.Environment.IsDevelopment()) +{ + app.UseSwagger(); + app.UseSwaggerUI(); +} + +app.UseHttpsRedirection(); + +app.UseAuthorization(); + +app.MapControllers(); + +app.Run(); diff --git a/src/QuickDish.Api/Properties/launchSettings.json b/src/QuickDish.Api/Properties/launchSettings.json new file mode 100644 index 0000000..fd466a9 --- /dev/null +++ b/src/QuickDish.Api/Properties/launchSettings.json @@ -0,0 +1,41 @@ +{ + "$schema": "http://json.schemastore.org/launchsettings.json", + "iisSettings": { + "windowsAuthentication": false, + "anonymousAuthentication": true, + "iisExpress": { + "applicationUrl": "http://localhost:54692", + "sslPort": 44361 + } + }, + "profiles": { + "http": { + "commandName": "Project", + "dotnetRunMessages": true, + "launchBrowser": true, + "launchUrl": "swagger", + "applicationUrl": "http://localhost:5235", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "https": { + "commandName": "Project", + "dotnetRunMessages": true, + "launchBrowser": true, + "launchUrl": "swagger", + "applicationUrl": "https://localhost:7164;http://localhost:5235", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + }, + "IIS Express": { + "commandName": "IISExpress", + "launchBrowser": true, + "launchUrl": "swagger", + "environmentVariables": { + "ASPNETCORE_ENVIRONMENT": "Development" + } + } + } +} diff --git a/src/QuickDish.Api/QuickDish.Api.csproj b/src/QuickDish.Api/QuickDish.Api.csproj new file mode 100644 index 0000000..75d2448 --- /dev/null +++ b/src/QuickDish.Api/QuickDish.Api.csproj @@ -0,0 +1,18 @@ + + + + net8.0 + enable + enable + + + + + + + + + + + + diff --git a/src/QuickDish.Api/QuickDish.Api.http b/src/QuickDish.Api/QuickDish.Api.http new file mode 100644 index 0000000..12ba3fd --- /dev/null +++ b/src/QuickDish.Api/QuickDish.Api.http @@ -0,0 +1,6 @@ +@QuickDish.Api_HostAddress = http://localhost:5235 + +GET {{QuickDish.Api_HostAddress}}/weatherforecast/ +Accept: application/json + +### diff --git a/src/QuickDish.Api/WeatherForecast.cs b/src/QuickDish.Api/WeatherForecast.cs new file mode 100644 index 0000000..720e144 --- /dev/null +++ b/src/QuickDish.Api/WeatherForecast.cs @@ -0,0 +1,12 @@ +namespace QuickDish.Api; + +public class WeatherForecast +{ + public DateOnly Date { get; set; } + + public int TemperatureC { get; set; } + + public int TemperatureF => 32 + (int)(TemperatureC / 0.5556); + + public string? Summary { get; set; } +} diff --git a/src/QuickDish.Api/appsettings.Development.json b/src/QuickDish.Api/appsettings.Development.json new file mode 100644 index 0000000..0c208ae --- /dev/null +++ b/src/QuickDish.Api/appsettings.Development.json @@ -0,0 +1,8 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + } +} diff --git a/src/QuickDish.Api/appsettings.json b/src/QuickDish.Api/appsettings.json new file mode 100644 index 0000000..10f68b8 --- /dev/null +++ b/src/QuickDish.Api/appsettings.json @@ -0,0 +1,9 @@ +{ + "Logging": { + "LogLevel": { + "Default": "Information", + "Microsoft.AspNetCore": "Warning" + } + }, + "AllowedHosts": "*" +} diff --git a/src/QuickDish.Application/Class1.cs b/src/QuickDish.Application/Class1.cs new file mode 100644 index 0000000..61c2c16 --- /dev/null +++ b/src/QuickDish.Application/Class1.cs @@ -0,0 +1,6 @@ +namespace QuickDish.Application; + +public class Class1 +{ + +} diff --git a/src/QuickDish.Application/QuickDish.Application.csproj b/src/QuickDish.Application/QuickDish.Application.csproj new file mode 100644 index 0000000..a097382 --- /dev/null +++ b/src/QuickDish.Application/QuickDish.Application.csproj @@ -0,0 +1,13 @@ + + + + + + + + net8.0 + enable + enable + + + diff --git a/src/QuickDish.Client/App.xaml b/src/QuickDish.Client/App.xaml new file mode 100644 index 0000000..1c4d5c7 --- /dev/null +++ b/src/QuickDish.Client/App.xaml @@ -0,0 +1,14 @@ + + + + + + + + + + + diff --git a/src/QuickDish.Client/App.xaml.cs b/src/QuickDish.Client/App.xaml.cs new file mode 100644 index 0000000..9f74cd9 --- /dev/null +++ b/src/QuickDish.Client/App.xaml.cs @@ -0,0 +1,11 @@ +namespace QuickDish.Client; + +public partial class App : Application +{ + public App() + { + InitializeComponent(); + + MainPage = new AppShell(); + } +} diff --git a/src/QuickDish.Client/AppShell.xaml b/src/QuickDish.Client/AppShell.xaml new file mode 100644 index 0000000..7b6c791 --- /dev/null +++ b/src/QuickDish.Client/AppShell.xaml @@ -0,0 +1,15 @@ + + + + + + diff --git a/src/QuickDish.Client/AppShell.xaml.cs b/src/QuickDish.Client/AppShell.xaml.cs new file mode 100644 index 0000000..a75dd91 --- /dev/null +++ b/src/QuickDish.Client/AppShell.xaml.cs @@ -0,0 +1,9 @@ +namespace QuickDish.Client; + +public partial class AppShell : Shell +{ + public AppShell() + { + InitializeComponent(); + } +} diff --git a/src/QuickDish.Client/MainPage.xaml b/src/QuickDish.Client/MainPage.xaml new file mode 100644 index 0000000..e486696 --- /dev/null +++ b/src/QuickDish.Client/MainPage.xaml @@ -0,0 +1,36 @@ + + + + + + + +