Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade WinUI/MUX to 2.7 #8726

Merged
merged 3 commits into from
Oct 26, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "prerelease",
"comment": "Upgrade WinUI/MUX to 2.7",
"packageName": "@react-native-windows/cli",
"email": "jthysell@microsoft.com",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"type": "prerelease",
"comment": "Upgrade WinUI/MUX to 2.7",
"packageName": "react-native-windows",
"email": "jthysell@microsoft.com",
"dependentChangeType": "patch"
}
Original file line number Diff line number Diff line change
Expand Up @@ -421,24 +421,24 @@ test('ensureXAMLDialect - WinUI2xVersion specified in ExperimentalFeatures.props
logging: false,
},
);
al.experimentalFeaturesProps = `<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"><PropertyGroup><UseWinUI3>false</UseWinUI3><WinUI2xVersion>2.6.0-test</WinUI2xVersion></PropertyGroup></Project>`;
al.experimentalFeaturesProps = `<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"><PropertyGroup><UseWinUI3>false</UseWinUI3><WinUI2xVersion>2.7.0-test</WinUI2xVersion></PropertyGroup></Project>`;
al.packagesConfig = `<packages><package id="SuperPkg" version="42"/></packages>`;

const exd = await al.ensureXAMLDialect();
expect(exd).toBeTruthy();

const expectedExperimentalFeatures =
'<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"><PropertyGroup><UseWinUI3>false</UseWinUI3><WinUI2xVersion>2.6.0-test</WinUI2xVersion></PropertyGroup></Project>';
'<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"><PropertyGroup><UseWinUI3>false</UseWinUI3><WinUI2xVersion>2.7.0-test</WinUI2xVersion></PropertyGroup></Project>';
expect(al.experimentalFeaturesProps).toEqual(expectedExperimentalFeatures);

// example packages.config:
// <packages>
// <package id="SuperPkg" version="42"/>
// <package id="Microsoft.UI.XAML" version="2.6.0-test" targetFramework="native"/>
// <package id="Microsoft.UI.XAML" version="2.7.0-test" targetFramework="native"/>
// </packages>
//
expect(al.packagesConfig).toContain('Microsoft.UI.Xaml');
expect(al.packagesConfig).toContain('2.6.0-test');
expect(al.packagesConfig).toContain('2.7.0-test');
expect(al.packagesConfig).toContain('<package id="SuperPkg" version="42"/>');
expect(al.packagesConfig).not.toContain('Microsoft.WinUI');

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.Windows.CppWinRT" version="2.0.210312.4" targetFramework="native"/>
<package id="Microsoft.UI.Xaml" version="2.6.0" targetFramework="native"/>
<package id="Microsoft.UI.Xaml" version="2.7.0" targetFramework="native"/>
<package id="ReactNative.Hermes.Windows" version="0.9.0-ms.4" targetFramework="native"/>
</packages>
2 changes: 1 addition & 1 deletion packages/playground/windows/ExperimentalFeatures.props
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</PropertyGroup>

<PropertyGroup Label="Unpackaged playground-win32" Condition="'$(SolutionName)'=='playground-win32'">
<WinUI2xVersion>2.6.1-prerelease.210709001</WinUI2xVersion>
<WinUI2xVersion>2.7.0-prerelease.210913003</WinUI2xVersion>
</PropertyGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Playground-Win32 is an unpackaged win32 app, and needs to use Microsoft.UI.Xaml from a prerelease, to be able to carry WinUI in-app instead of using the Framework Package
/WARNING
-->
<package id="Microsoft.UI.Xaml" version="2.6.1-prerelease.210709001" targetFramework="native"/>
<package id="Microsoft.UI.Xaml" version="2.7.0-prerelease.210913003" targetFramework="native"/>
<package id="Microsoft.VCRTForwarders.140" version="1.0.2-rc" targetFramework="native"/>
<package id="Microsoft.Windows.CppWinRT" version="2.0.210312.4" targetFramework="native"/>
<package id="ReactNative.Hermes.Windows" version="0.9.0-ms.4" targetFramework="native"/>
Expand Down
2 changes: 1 addition & 1 deletion packages/playground/windows/playground/packages.config
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.Windows.CppWinRT" version="2.0.210312.4" targetFramework="native"/>
<package id="Microsoft.UI.Xaml" version="2.6.0" targetFramework="native"/>
<package id="Microsoft.UI.Xaml" version="2.7.0" targetFramework="native"/>
<package id="ReactNative.Hermes.Windows" version="0.9.0-ms.4" targetFramework="native"/>
</packages>
Original file line number Diff line number Diff line change
Expand Up @@ -187,14 +187,14 @@
<Error Condition="!Exists('$(ReactNativeWindowsDir)\PropertySheets\External\Microsoft.ReactNative.Uwp.CppApp.targets')" Text="$([System.String]::Format('$(ErrorText)', '$(ReactNativeWindowsDir)\PropertySheets\External\Microsoft.ReactNative.Uwp.CppApp.targets'))" />
</Target>
<ImportGroup Label="ExtensionTargets">
<Import Project="..\packages\Microsoft.UI.Xaml.2.6.0\build\native\Microsoft.UI.Xaml.targets" Condition="Exists('..\packages\Microsoft.UI.Xaml.2.6.0\build\native\Microsoft.UI.Xaml.targets')" />
<Import Project="..\packages\Microsoft.UI.Xaml.2.7.0\build\native\Microsoft.UI.Xaml.targets" Condition="Exists('..\packages\Microsoft.UI.Xaml.2.7.0\build\native\Microsoft.UI.Xaml.targets')" />
<Import Project="..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.targets" Condition="Exists('..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.targets')" />
</ImportGroup>
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\Microsoft.UI.Xaml.2.6.0\build\native\Microsoft.UI.Xaml.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.UI.Xaml.2.6.0\build\native\Microsoft.UI.Xaml.targets'))" />
<Error Condition="!Exists('..\packages\Microsoft.UI.Xaml.2.7.0\build\native\Microsoft.UI.Xaml.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.UI.Xaml.2.7.0\build\native\Microsoft.UI.Xaml.targets'))" />
<Error Condition="!Exists('..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.props')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.props'))" />
<Error Condition="!Exists('..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Microsoft.Windows.CppWinRT.2.0.210312.4\build\native\Microsoft.Windows.CppWinRT.targets'))" />
</Target>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.UI.Xaml" version="2.6.0" targetFramework="native" />
<package id="Microsoft.UI.Xaml" version="2.7.0" targetFramework="native" />
<package id="Microsoft.Windows.CppWinRT" version="2.0.210312.4" targetFramework="native" />
</packages>
2 changes: 1 addition & 1 deletion vnext/Microsoft.ReactNative/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<package id="Microsoft.Build.Tasks.Git" version="1.0.0" targetFramework="native" developmentDependency="true" />
<package id="Microsoft.SourceLink.Common" version="1.0.0" targetFramework="native" developmentDependency="true" />
<package id="Microsoft.SourceLink.GitHub" version="1.0.0" targetFramework="native" developmentDependency="true" />
<package id="Microsoft.UI.Xaml" version="2.6.0" targetFramework="native" />
<package id="Microsoft.UI.Xaml" version="2.7.0" targetFramework="native" />
<package id="Microsoft.Windows.CppWinRT" version="2.0.210312.4" targetFramework="native" />
<package id="Microsoft.WinUI" version="3.0.0-preview4.210210.4" targetFramework="native" />
<package id="ReactNative.Hermes.Windows" version="0.9.0-ms.4" targetFramework="native" />
Expand Down
2 changes: 1 addition & 1 deletion vnext/PropertySheets/WinUI.props
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

<PropertyGroup Label="WinUI2x versioning">
<!--This value is also used by the CLI, see /packages/@react-native-windows/generate-windows -->
<WinUI2xVersion Condition="'$(WinUI2xVersion)'==''">2.6.0</WinUI2xVersion>
<WinUI2xVersion Condition="'$(WinUI2xVersion)'==''">2.7.0</WinUI2xVersion>
</PropertyGroup>

<PropertyGroup Condition="'$(UseWinUI3)'=='true'">
Expand Down
2 changes: 1 addition & 1 deletion vnext/Scripts/Microsoft.ReactNative.Managed.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<tags>react react-native react-native-windows native-module microsoft c# csharp</tags>
<dependencies>
<group targetFramework="UAP10.0">
<dependency id="Microsoft.UI.Xaml" version="2.6.0" />
<dependency id="Microsoft.UI.Xaml" version="2.7.0" />
<dependency id="Microsoft.NETCore.UniversalWindowsPlatform" version="6.2.9" />
<dependency id="Microsoft.ReactNative" version="$version$" />
<dependency id="Microsoft.ReactNative.Managed.CodeGen" version="$version$" />
Expand Down