Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 1, 2025

  • Fix JsonResourceManager constructors to work with the new string[] ResourcesPath
  • Update old constructor taking string to wrap it in an array when calling new constructor
  • Fix constructor taking string[] to properly chain to the main constructor
  • Update test cases to use string[] for ResourcesPath
  • All 45 unit tests + 5 functional tests passing
Original prompt

This section details on the original issue you should resolve

<issue_title>Culture Fallback should respect FallBackToParentUICultures</issue_title>
<issue_description></issue_description>

Comments on the Issue (you are @copilot in this section)

@hishamco Injecting `IOptions` will introduce a breaking change, we need a way to make this happen without breaking changes, otherwise will go into `3.0.0`

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI changed the title [WIP] Fix culture fallback to respect FallBackToParentUICultures Add FallBackToParentUICultures option to JsonLocalizationOptions Dec 1, 2025
Copilot AI requested a review from hishamco December 1, 2025 01:31
@hishamco hishamco marked this pull request as ready for review December 10, 2025 01:13
/// <remarks>
/// Defaults to <c>true</c> to maintain backward compatibility.
/// </remarks>
public bool FallBackToParentUICultures { get; set; } = true;
Copy link
Owner

Choose a reason for hiding this comment

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

@copilot use RequestLocalizationOptions.FallBackToParentUICultures instead

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done in 5e22a6b. Now using RequestLocalizationOptions.FallBackToParentUICultures via optional constructor injection, maintaining backward compatibility with the existing constructor.

@hishamco
Copy link
Owner

@copilot resolve the conflicts

Copilot AI changed the title Add FallBackToParentUICultures option to JsonLocalizationOptions Respect RequestLocalizationOptions.FallBackToParentUICultures for culture fallback Dec 10, 2025
Copilot AI requested a review from hishamco December 10, 2025 01:56
Copy link
Contributor Author

Copilot AI commented Dec 10, 2025

@copilot resolve the conflicts

Conflicts resolved in d2026ee. Fixed JsonResourceManager constructors to work with the new string[] ResourcesPath type from the merge, and updated tests accordingly. All 50 tests passing.

@hishamco hishamco merged commit 25c824c into main Dec 10, 2025
1 check passed
@hishamco hishamco deleted the copilot/fix-culture-fallback-issue-again branch December 10, 2025 03:18
@hishamco hishamco added this to the 4.0.0 milestone Dec 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Culture Fallback should respect FallBackToParentUICultures

2 participants