Skip to content

Commit 126f14d

Browse files
authored
Component package updates (#23371)
* Stop cross-compiling Component packages * Remove Microsoft.JSInterop reference from M.A.Components * Update RCL template Fixes #23124 Fixes #23351
1 parent b446ab7 commit 126f14d

23 files changed

+33
-126
lines changed

src/Components/Authorization/ref/Microsoft.AspNetCore.Components.Authorization.csproj

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,9 @@
11
<!-- This file is automatically generated. -->
22
<Project Sdk="Microsoft.NET.Sdk">
33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFrameworks>$(DefaultNetCoreTargetFramework)</TargetFrameworks>
65
</PropertyGroup>
7-
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
8-
<Compile Include="Microsoft.AspNetCore.Components.Authorization.netstandard2.0.cs" />
9-
<Reference Include="Microsoft.AspNetCore.Authorization" />
10-
<Reference Include="Microsoft.AspNetCore.Components" />
11-
</ItemGroup>
12-
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
6+
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
137
<Compile Include="Microsoft.AspNetCore.Components.Authorization.netcoreapp.cs" />
148
<Reference Include="Microsoft.AspNetCore.Authorization" />
159
<Reference Include="Microsoft.AspNetCore.Components" />

src/Components/Authorization/src/Microsoft.AspNetCore.Components.Authorization.csproj

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
<Project Sdk="Microsoft.NET.Sdk.Razor">
22

33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
65
<IsAspNetCoreApp>true</IsAspNetCoreApp>
76
<Description>Authentication and authorization support for Blazor applications.</Description>
87
<GenerateDocumentationFile>true</GenerateDocumentationFile>
9-
<RazorLangVersion>3.0</RazorLangVersion>
108
</PropertyGroup>
119

1210
<ItemGroup>

src/Components/Components/ref/Microsoft.AspNetCore.Components.csproj

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
<!-- This file is automatically generated. -->
22
<Project Sdk="Microsoft.NET.Sdk">
33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFrameworks>$(DefaultNetCoreTargetFramework)</TargetFrameworks>
65
<Nullable>annotations</Nullable>
76
</PropertyGroup>
8-
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
9-
<Compile Include="Microsoft.AspNetCore.Components.netstandard2.0.cs" />
10-
<Compile Include="Microsoft.AspNetCore.Components.Manual.cs" />
11-
<Compile Include="../src/Properties/AssemblyInfo.cs" />
12-
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
13-
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
14-
<Reference Include="System.Buffers" />
15-
</ItemGroup>
16-
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
7+
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
178
<Compile Include="Microsoft.AspNetCore.Components.netcoreapp.cs" />
189
<Compile Include="Microsoft.AspNetCore.Components.Manual.cs" />
1910
<Compile Include="../src/Properties/AssemblyInfo.cs" />

src/Components/Components/src/Microsoft.AspNetCore.Components.csproj

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
65
<Description>Components feature for ASP.NET Core.</Description>
76
<GenerateDocumentationFile>true</GenerateDocumentationFile>
87
<IsAspNetCoreApp>true</IsAspNetCoreApp>
@@ -16,19 +15,12 @@
1615
<ItemGroup>
1716
<Reference Include="Microsoft.Extensions.Logging.Abstractions" />
1817
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
19-
20-
<Compile Include="$(SharedSourceRoot)HashCodeCombiner\*.cs" />
21-
</ItemGroup>
22-
23-
<ItemGroup Condition="'$(TargetFramework)'=='netstandard2.0'">
24-
<Reference Include="System.Buffers" />
2518
</ItemGroup>
2619

2720
<!-- These references were removed in 3.0 -->
2821
<ItemGroup>
2922
<SuppressBaselineReference Include="Microsoft.AspNetCore.Components.Analyzers" />
3023
<SuppressBaselineReference Include="Microsoft.AspNetCore.Authorization" />
31-
<SuppressBaselineReference Include="Microsoft.JSInterop" />
3224
<SuppressBaselineReference Include="System.ComponentModel.Annotations" />
3325
</ItemGroup>
3426

@@ -37,27 +29,25 @@
3729
BuildInParallel="$(BuildInParallel)"
3830
Projects="
3931
../../Analyzers/src/Microsoft.AspNetCore.Components.Analyzers.csproj;
40-
../../../JSInterop/Microsoft.JSInterop/src/Microsoft.JSInterop.csproj;
4132
../../../Security/Authorization/Core/src/Microsoft.AspNetCore.Authorization.csproj">
4233
<Output TaskParameter="TargetOutputs" ItemName="_ProjectPathWithVersion" />
4334
</MSBuild>
4435
<ItemGroup>
4536
<NuspecProperty Include="@(_ProjectPathWithVersion->WithMetadataValue('PackageId', 'Microsoft.AspnetCore.Components.Analyzers')->'componentAnalyzerPackageVersion=%(PackageVersion)')" />
4637
<NuspecProperty Include="@(_ProjectPathWithVersion->WithMetadataValue('PackageId', 'Microsoft.AspnetCore.Authorization')->'authorizationPackageVersion=%(PackageVersion)')" />
47-
<NuspecProperty Include="@(_ProjectPathWithVersion->WithMetadataValue('PackageId', 'Microsoft.JSInterop')->'jsInteropPackageVersion=%(PackageVersion)')" />
4838
</ItemGroup>
4939
</Target>
5040

5141
<!-- Pack settings -->
5242
<PropertyGroup>
53-
<NuspecFile>Microsoft.AspNetCore.Components.multitarget.nuspec</NuspecFile>
54-
<NuspecFile Condition="'$(DotNetBuildFromSource)' == 'true'">Microsoft.AspNetCore.Components.netcoreapp.nuspec</NuspecFile>
43+
<NuspecFile>Microsoft.AspNetCore.Components.netcoreapp.nuspec</NuspecFile>
5544
<GenerateNuspecDependsOn>$(GenerateNuspecDependsOn);_GetNuspecDependencyPackageVersions</GenerateNuspecDependsOn>
5645
</PropertyGroup>
5746

5847
<ItemGroup>
5948
<NuspecProperty Condition="'$(DotNetBuildFromSource)' != 'true'" Include="systemComponentModelAnnotationsPackageVersion=$(SystemComponentModelAnnotationsPackageVersion)" />
6049
<NuspecProperty Include="AssemblyName=$(AssemblyName)" />
50+
<NuspecProperty Include="DefaultNetCoreTargetFramework=$(DefaultNetCoreTargetFramework)" />
6151
<NuspecProperty Include="OutputPath=$(OutputPath)" />
6252
<NuspecProperty Include="PackageThirdPartyNoticesFile=$(PackageThirdPartyNoticesFile)" />
6353
</ItemGroup>

src/Components/Components/src/Microsoft.AspNetCore.Components.multitarget.nuspec

Lines changed: 0 additions & 26 deletions
This file was deleted.

src/Components/Components/src/Microsoft.AspNetCore.Components.netcoreapp.nuspec

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,14 @@
66
<group targetFramework=".net5.0">
77
<dependency id="Microsoft.AspNetCore.Components.Analyzers" version="$componentAnalyzerPackageVersion$" />
88
<dependency id="Microsoft.AspNetCore.Authorization" version="$authorizationPackageVersion$" exclude="Build,Analyzers" />
9-
<dependency id="Microsoft.JSInterop" version="$jsInteropPackageVersion$" exclude="Build,Analyzers" />
109
</group>
1110
</dependencies>
1211
</metadata>
1312
<files>
1413
$CommonFileElements$
15-
<file src="$OutputPath$**\$AssemblyName$.dll" target="lib\" />
16-
<file src="$OutputPath$**\$AssemblyName$.pdb" target="lib\" />
17-
<file src="$OutputPath$**\$AssemblyName$.xml" target="lib\" />
14+
<file src="$OutputPath$$AssemblyName$.dll" target="lib\$DefaultNetCoreTargetFramework$\" />
15+
<file src="$OutputPath$$AssemblyName$.pdb" target="lib\$DefaultNetCoreTargetFramework$\" />
16+
<file src="$OutputPath$$AssemblyName$.xml" target="lib\$DefaultNetCoreTargetFramework$\" />
1817
<file src="$PackageThirdPartyNoticesFile$" target=".\THIRD-PARTY-NOTICES.txt" />
1918
</files>
2019
</package>

src/Components/Components/src/Routing/RouteTableFactory.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ public bool Equals(Key other)
221221

222222
public override int GetHashCode()
223223
{
224-
var hash = new HashCodeCombiner();
224+
var hash = new HashCode();
225225

226226
if (Assemblies != null)
227227
{
@@ -231,7 +231,7 @@ public override int GetHashCode()
231231
}
232232
}
233233

234-
return hash;
234+
return hash.ToHashCode();
235235
}
236236
}
237237
}

src/Components/Forms/ref/Microsoft.AspNetCore.Components.Forms.csproj

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,10 @@
11
<!-- This file is automatically generated. -->
22
<Project Sdk="Microsoft.NET.Sdk">
33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFrameworks>$(DefaultNetCoreTargetFramework)</TargetFrameworks>
65
<Nullable>annotations</Nullable>
76
</PropertyGroup>
8-
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
9-
<Compile Include="Microsoft.AspNetCore.Components.Forms.netstandard2.0.cs" />
10-
<Reference Include="Microsoft.AspNetCore.Components" />
11-
<Reference Include="System.ComponentModel.Annotations" />
12-
</ItemGroup>
13-
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
7+
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
148
<Compile Include="Microsoft.AspNetCore.Components.Forms.netcoreapp.cs" />
159
<Reference Include="Microsoft.AspNetCore.Components" />
1610
</ItemGroup>
Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFramework>$(DefaultNetCoreTargetFramework)</TargetFramework>
65
<IsAspNetCoreApp>true</IsAspNetCoreApp>
76
<Description>Forms and validation support for Blazor applications.</Description>
87
<GenerateDocumentationFile>true</GenerateDocumentationFile>
@@ -13,8 +12,4 @@
1312
<Reference Include="Microsoft.AspNetCore.Components" />
1413
</ItemGroup>
1514

16-
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'" >
17-
<Reference Include="System.ComponentModel.Annotations" />
18-
</ItemGroup>
19-
2015
</Project>

src/Components/Web/ref/Microsoft.AspNetCore.Components.Web.csproj

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
<!-- This file is automatically generated. -->
22
<Project Sdk="Microsoft.NET.Sdk">
33
<PropertyGroup>
4-
<TargetFrameworks>netstandard2.0;$(DefaultNetCoreTargetFramework)</TargetFrameworks>
5-
<TargetFrameworks Condition="'$(DotNetBuildFromSource)' == 'true'">$(DefaultNetCoreTargetFramework)</TargetFrameworks>
4+
<TargetFrameworks>$(DefaultNetCoreTargetFramework)</TargetFrameworks>
65
<Nullable>annotations</Nullable>
76
</PropertyGroup>
8-
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
9-
<Compile Include="Microsoft.AspNetCore.Components.Web.netstandard2.0.cs" />
10-
<Compile Include="../src/Properties/AssemblyInfo.cs" />
11-
<Reference Include="Microsoft.AspNetCore.Components" />
12-
<Reference Include="Microsoft.AspNetCore.Components.Forms" />
13-
<Reference Include="Microsoft.Extensions.DependencyInjection" />
14-
<Reference Include="Microsoft.JSInterop" />
15-
</ItemGroup>
16-
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
7+
<ItemGroup Condition="'$(TargetFramework)' == '$(DefaultNetCoreTargetFramework)'">
178
<Compile Include="Microsoft.AspNetCore.Components.Web.netcoreapp.cs" />
189
<Compile Include="../src/Properties/AssemblyInfo.cs" />
1910
<Reference Include="Microsoft.AspNetCore.Components" />

0 commit comments

Comments
 (0)