chore: update Blazor to .NET 8 (#3514)

* update Blazor to .NET 8

* commont NetAnalyzers

* fix bunit bug

* fix tests
This commit is contained in:
James Yeung 2023-11-16 12:33:01 +08:00 committed by GitHub
parent a2fa9b7926
commit 1409c277b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 15 additions and 15 deletions

View File

@ -43,7 +43,7 @@ jobs:
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x'
dotnet-version: 8.0.100
- uses: actions/setup-node@v1
with:

View File

@ -31,7 +31,7 @@ jobs:
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x'
dotnet-version: 8.0.100
- name: Setup Node.js
uses: actions/setup-node@v1

View File

@ -36,7 +36,7 @@ jobs:
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x'
dotnet-version: 8.0.100
- uses: actions/setup-node@v1
with:

View File

@ -39,7 +39,7 @@ jobs:
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x'
dotnet-version: 8.0.100
- uses: actions/setup-node@v1
with:

View File

@ -39,7 +39,7 @@ jobs:
- name: Setup .NET 8.0
uses: actions/setup-dotnet@v3
with:
dotnet-version: '8.0.x'
dotnet-version: 8.0.100
- uses: actions/setup-node@v1
with:

View File

@ -75,11 +75,11 @@
</ItemGroup>
<ItemGroup Condition="$(TargetFramework) == 'net8'">
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="8.0.0-rc.1.*" />
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="7.0.0">
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="8.0.0" />
<!--<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="8.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</PackageReference>-->
</ItemGroup>
<ItemGroup>

View File

@ -88,7 +88,7 @@ namespace AntDesign
internal void SetBody(RenderFragment body)
{
this.Body = body;
StateHasChanged();
InvokeAsync(StateHasChanged);
}
internal void AddCardAction(CardAction action)

View File

@ -448,7 +448,7 @@ namespace AntDesign
_needUpdateScrollListPosition = true;
_shouldRender = true;
StateHasChanged();
InvokeAsync(StateHasChanged);
}
protected override async Task OnAfterRenderAsync(bool firstRender)

View File

@ -22,8 +22,8 @@
</ItemGroup>
<ItemGroup Condition="$(TargetFramework) == 'net8'">
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.0-rc.1.*" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.0-rc.1.*" PrivateAssets="all" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="8.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="8.0.0" PrivateAssets="all" />
</ItemGroup>
<ItemGroup>

View File

@ -5,7 +5,7 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="8.0.0-rc.1.*" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.Server" Version="8.0.0" />
</ItemGroup>
<ItemGroup>

View File

@ -7,7 +7,7 @@
<ItemGroup>
<PackageReference Include="AntDesign.Charts" Version="0.2.0" />
<PackageReference Include="System.Net.Http.Json" Version="5.0.0" />
<PackageReference Include="System.Net.Http.Json" Version="6.0.0" />
</ItemGroup>
<ItemGroup>

View File

@ -8,7 +8,7 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="bunit.web" Version="1.23.9" />
<PackageReference Include="bunit.web" Version="1.24.9-preview" />
<PackageReference Include="FluentAssertions" Version="6.1.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.3.1" />
<PackageReference Include="Moq" Version="4.16.1" />