Skip to content

Remove InternalsVisibleTo for Toolkit #28994

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

Merged
merged 4 commits into from
Apr 25, 2025
Merged

Conversation

jfversluis
Copy link
Member

@jfversluis jfversluis commented Apr 15, 2025

Description of Change

Removes the InternalsVisibleTo for the .NET MAUI Community Toolkit. We shouldn't need that, it was done for historic reasons, but to prevent further unintentional breaking changes like #28450 we should remove it.

This PR:

  • Removes the InternalsVisibleTo attribute from all the .NET MAUI projects in regard to the Toolkit
  • Makes some internals that the Toolkit needs public
  • Add XML comments to the APIs that are now public

Issues Fixed

Fixes #28981

@jfversluis jfversluis added the area-architecture Issues with code structure, SDK structure, implementation details label Apr 15, 2025
@jfversluis jfversluis added this to the .NET 10 Planning milestone Apr 15, 2025
jsuarezruiz
jsuarezruiz previously approved these changes Apr 16, 2025
@rmarinho
Copy link
Member

/rebase

rmarinho
rmarinho previously approved these changes Apr 21, 2025
@github-actions github-actions bot force-pushed the net10-remove-ivt-toolkit branch from cf9b02c to d5fc0e3 Compare April 21, 2025 11:07
@jfversluis
Copy link
Member Author

jfversluis commented Apr 22, 2025

Built the .NET MAUI Community Toolkit against this version and seems like these are the APIs that are currently used, but are internal to .NET MAUI:

  • IWindowController
  • IPropertyPropagationController
  • IResourcesProvider
  • IStyleSelectable
  • IStyleElement
  • MergedStyle

From what I can determine the above ones are used in Popup, but will be removed with the new Popups implementation that is in a PR right now.

For the rest:

  • ITextElement: AvatarView, I think we are OK with making this public
  • ILineHeightElement: AvatarView, I think we are OK with making this public
  • ITextAlignmentElement: AvatarView, I think we are OK with making this public
  • ICornerElement: AvatarView, I think we are OK with making this public
  • IProvideParentValues: AppThemeResourceExtension, we don't want to make this one public so created a PR with an alternative implementation on the Toolkit side: Update AppThemeResourceExtension to not use IProvideParentValues CommunityToolkit/Maui#2639

@jfversluis jfversluis dismissed stale reviews from rmarinho and jsuarezruiz via 5387b70 April 24, 2025 14:54
@jfversluis jfversluis force-pushed the net10-remove-ivt-toolkit branch from d5fc0e3 to 5387b70 Compare April 24, 2025 14:54
Copy link
Contributor

🚨 API change(s) detected @davidbritch FYI

@jfversluis jfversluis marked this pull request as ready for review April 24, 2025 15:24
@jfversluis jfversluis requested a review from a team as a code owner April 24, 2025 15:24
@rmarinho rmarinho merged commit 504aa86 into net10.0 Apr 25, 2025
128 checks passed
@rmarinho rmarinho deleted the net10-remove-ivt-toolkit branch April 25, 2025 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-architecture Issues with code structure, SDK structure, implementation details t/breaking 💥
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants