Skip to content

Commit

Permalink
wip: fix and moved to net 8
Browse files Browse the repository at this point in the history
  • Loading branch information
emimontesdeoca committed Mar 30, 2024
1 parent 5ba6fe8 commit 28efc3a
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 26 deletions.
8 changes: 4 additions & 4 deletions Taskless.Applications.Web/Taskless.Applications.Web.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.BlazorWebAssembly">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
<BlazorEnableTimeZoneSupport>false</BlazorEnableTimeZoneSupport>
Expand All @@ -24,9 +24,9 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Blazored.LocalStorage" Version="4.3.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="7.0.2" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="7.0.2" PrivateAssets="all" />
<PackageReference Include="Blazored.LocalStorage" Version="4.5.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.3" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.3" PrivateAssets="all" />
</ItemGroup>

<ItemGroup>
Expand Down
35 changes: 19 additions & 16 deletions Taskless.Libraries.Components/TaskApp.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,23 +52,26 @@ protected async override Task OnInitializedAsync()
if (this.HotKeys is not null)
{
this.HotkeyContext = this.HotKeys.CreateContext();
var options = new HotKeyOptions();


this.HotkeyContext
.Add(ModCode.Shift, Code.ArrowUp, async () => { await MoveUp(); })
.Add(ModCode.Shift, Code.ArrowDown, async () => { await MoveDown(); })
.Add(ModCode.Shift, Code.PageUp, async () => { await MoveGroupUp(); })
.Add(ModCode.Shift, Code.PageDown, async () => { await MoveGroupDown(); })
.Add(ModCode.Shift, Code.X, async () => { await ToggleType(); })
.Add(ModCode.Shift, Code.C, async () => { await ToggleChecked(); })
.Add(ModCode.Shift, Code.E, async () => { await ToggleEdit(); })
.Add(ModCode.Shift, Code.R, async () => { await RemoveItem(); })
.Add(ModCode.Shift, Code.N, async () => { await NewItem(); })
.Add(ModCode.Shift, Code.G, async () => { await NewGroup(); })
.Add(ModCode.Shift, Code.T, async () => { await ToggleTheme(); })
.Add(ModCode.Shift, Code.H, async () => { await ShowHelp(); })
.Add(ModCode.Shift, Code.F, async () => { await RestartSelection(); })
.Add(ModCode.Shift, Code.Home, async () => { await GoToFirstInGroup(); })
.Add(ModCode.Shift, Code.End, async () => { await GoToLastInGroup(); })
.Add(ModCode.Shift, Code.S, async () => { await SaveDataAsync(); });
.Add(ModCode.Shift, Code.ArrowUp, MoveUp)
.Add(ModCode.Shift, Code.ArrowDown, MoveDown)
.Add(ModCode.Shift, Code.PageUp, MoveGroupUp)
.Add(ModCode.Shift, Code.PageDown, MoveGroupDown)
.Add(ModCode.Shift, Code.X, ToggleType)
.Add(ModCode.Shift, Code.C, ToggleChecked)
.Add(ModCode.Shift, Code.E, ToggleEdit)
.Add(ModCode.Shift, Code.R, RemoveItem)
.Add(ModCode.Shift, Code.N, NewItem)
.Add(ModCode.Shift, Code.G, NewGroup)
.Add(ModCode.Shift, Code.T, ToggleTheme)
.Add(ModCode.Shift, Code.H, ShowHelp)
.Add(ModCode.Shift, Code.F, RestartSelection)
.Add(ModCode.Shift, Code.Home, GoToFirstInGroup)
.Add(ModCode.Shift, Code.End, GoToLastInGroup)
.Add(ModCode.Shift, Code.S, SaveDataAsync);
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Razor">
<Project Sdk="Microsoft.NET.Sdk.Razor">

<PropertyGroup>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<Nullable>enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
Expand All @@ -12,10 +12,10 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="Blazored.LocalStorage" Version="4.3.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="7.0.2" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.2" />
<PackageReference Include="Toolbelt.Blazor.HotKeys2" Version="1.0.0" />
<PackageReference Include="Blazored.LocalStorage" Version="4.5.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="8.0.3" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="Toolbelt.Blazor.HotKeys2" Version="3.3.0" />
</ItemGroup>

<ItemGroup>
Expand Down

0 comments on commit 28efc3a

Please sign in to comment.