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

[Breaking] fix: Drop Fluent V1 styles #14769

Closed
wants to merge 4 commits into from

Conversation

MartinZikmund
Copy link
Member

@MartinZikmund MartinZikmund commented Dec 10, 2023

GitHub Issue (If applicable): part of #14765

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

Fluent V1 is no longer supported and is buggy.

What is the new behavior?

Drop v1 styles in non-breaking manner.

PR Checklist

Please check if your PR fulfills the following requirements:

This change drops the Fluent V1 styles in a non-breaking manner by redirecting them to the V2 styles. Later we will be able to drop the versioned styles altogether
@github-actions github-actions bot added the area/code-generation Categorizes an issue or PR as relevant to code generation label Dec 10, 2023
@MartinZikmund
Copy link
Member Author

MartinZikmund commented Dec 10, 2023

@jeromelaban @Youssef1313

If I didn't miss something, this should not be breaking (except for behavior breaking, but I doubt any app is still using the old styles anyway):

  • Adjusted V1 styles to link the generated themeresources_v2.xaml, meaning existing libraries which directly reference XamlControlsResourcesV1 in generated code for some reason will still work, just against the V2 styles instead
  • For apps that will be recompiled the logic switches to XamlControlsResourcesV2 for the generated code
  • Using ControlsResourcesVersion.Version1 will still switch to V2 styles

As part of breaking changes we can then safely drop the whole version separation and just keep Uno.UI.FluentTheme library, WinUI3 no longer has any "resources version" concept

@unodevops
Copy link
Contributor

🤖 Your docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-14769/index.html

#endif
break;
// As Fluent Styles V1 are no longer officially supported, prefer V2 styles.
requestedVersion = MaxSupportedResourcesVersion;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this variable used anymore?

Copy link
Contributor

@ajpinedam ajpinedam left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

@Youssef1313 Youssef1313 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but let's wait for @jeromelaban's approval as well

@jeromelaban
Copy link
Member

This might still be breaking for UWP apps, particularly if resources don't match between versions. Building those styles are not impacting the build time that much, and we should not breaking in 5.x.

@MartinZikmund MartinZikmund changed the title fix: Drop Fluent V1 styles (non-breaking) [Breaking] fix: Drop Fluent V1 styles Mar 3, 2024
@MartinZikmund
Copy link
Member Author

Closing for now until breaking changes are addressed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/code-generation Categorizes an issue or PR as relevant to code generation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants