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

[BUG] The SelectAllTextBehavior cannot be referenced from a project that runs .NET without a native runtime #1847

Open
2 tasks done
bijington opened this issue Apr 29, 2024 · 0 comments
Labels
area/behaviors Issue/Discussion/PR that has to do with Behaviors bug Something isn't working unverified

Comments

@bijington
Copy link
Contributor

Is there an existing issue for this?

  • I have searched the existing issues

Did you read the "Reporting a bug" section on Contributing file?

Current Behavior

The SelectAllTextBehavior cannot be referenced from a project that runs .NET without a native runtime. Because of the way unit tests run in Maui, it's common to have a version of .NET as the target framework.

Based on the initial PR for the docs highlighting the behavior (pun intended) MicrosoftDocs/CommunityToolkit#411 (comment)

Expected Behavior

You should be able to refer to SelectAllTextBehavior in a net8.0 project target just like all other Behaviors.

Steps To Reproduce

  1. Open SelectAllTextBehaviorTest/SelectAllTextBehaviorTest.sln
  2. Uncomment the Entry.Behavior in Project2/MyControl
  3. Build the solution for a native runtime, I've been using iOS.
  4. The build will fail saying Error: XLS0414: The type 'toolkit:SelectAllTextBehavior' was not found. Verify that you are not missing an assembly reference and that all referenced assemblies have been built.

Link to public reproduction project repository

https://github.com/TrueMoniker/maui_SelectAllTextBehavior_Test/tree/main

Environment

- .NET MAUI CommunityToolkit: 8.0.1
- OS: macOS
- .NET MAUI: 8.0.x

Anything else?

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/behaviors Issue/Discussion/PR that has to do with Behaviors bug Something isn't working unverified
Projects
None yet
Development

No branches or pull requests

2 participants