Fix for Bug 2761 (AppThemeResource not finding keys)#3159
Merged
bijington merged 3 commits intoCommunityToolkit:mainfrom Mar 21, 2026
Merged
Fix for Bug 2761 (AppThemeResource not finding keys)#3159bijington merged 3 commits intoCommunityToolkit:mainfrom
bijington merged 3 commits intoCommunityToolkit:mainfrom
Conversation
Contributor
Author
|
@dotnet-policy-service agree |
bijington
requested changes
Mar 19, 2026
Contributor
bijington
left a comment
There was a problem hiding this comment.
@misterspeak thank you for this. Just 2 pretty small comments but the rest looks good to me.
src/CommunityToolkit.Maui.UnitTests/CommunityToolkit.Maui.UnitTests.csproj
Outdated
Show resolved
Hide resolved
src/CommunityToolkit.Maui/Extensions/AppThemeResourceExtension.shared.cs
Outdated
Show resolved
Hide resolved
bijington
approved these changes
Mar 20, 2026
Contributor
bijington
left a comment
There was a problem hiding this comment.
Thanks for this @misterspeak
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
Modified
AppThemeResourceExtension.shared.csto handle application level root (returns as aResourceDictionary, as opposed to an IResourcesProvider which is returned for page level resources).Unit Test
AppThemeResourceExtensionTests.csadded.New Resource Dictionary
AppThemeResourceDictionary.xamlprovided for use with unit test.No sample needed.
Linked Issues
#2761
Additional information
Tested on Windows11 only as this should be platform agnostic?