Skip to content

docs: clarify x:Bind literal argument scope - #24267

Open
SergioAlmeida29 wants to merge 2 commits into
unoplatform:masterfrom
SergioAlmeida29:agent/issue-20928
Open

SergioAlmeida29 wants to merge 2 commits into
unoplatform:masterfrom
SergioAlmeida29:agent/issue-20928

Conversation

@SergioAlmeida29

@SergioAlmeida29 SergioAlmeida29 commented Aug 28, 2026 •

Copy link
Copy Markdown
Contributor

GitHub Issue: closes #20928

PR Type:

📚 Documentation content changes

What changed? 🚀

Clarifies that x:True, x:False, and x:Null are literal arguments supported in {x:Bind ...} function calls. These bare function-argument tokens are distinct from the {x:Null} markup extension, which remains supported for properties that accept null.

PR Checklist ✅

  • 🧪 Runtime tests or a manual sample are not applicable to this documentation-only change.
  • 📚 Docs have been updated following the documentation template where applicable.
  • 🖼️ Screenshots Compare Test Run is not applicable to documentation-only changes.
  • ❗ Contains NO breaking changes.
  • 👀 Reviewed 2 other open pull requests.

Validation

  • git diff --check: passed.
  • Markdownlint and cSpell: passed.
  • DocFX: unavailable in the local environment.

Copilot AI lite review requested due to automatic review settings August 28, 2026 15:00

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@unodevops

Copy link
Copy Markdown
Contributor

@morning4coffe-dev morning4coffe-dev left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

[P2] Please distinguish x:Bind argument tokens from the general {x:Null} markup extension. The new sentence currently groups x:Null with x:True/x:False and says it cannot be assigned to arbitrary XAML properties. WinUI explicitly supports <object property="{x:Null}" />: https://learn.microsoft.com/en-us/windows/apps/develop/platform/xaml/x-null-markup-extension . Uno's own ContentPresenter_Content_DataContext.xaml and ContentPresenter_Template.xaml also use Content="{x:Null}". It is fine to explain that a bare function-argument token is not an attribute-value replacement, but the documentation must not imply that the markup extension itself is unavailable.

Copilot AI lite review requested due to automatic review settings October 20, 2026 11:10

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

No unresolved issues were identified that would block approval.

No open issues 🎉

Review effort: Lite

@unodevops

Copy link
Copy Markdown
Contributor

@mergify

mergify Bot commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Tick the box to add this pull request to the merge queue (same as @mergifyio queue). If it does not match the queue conditions yet, it enters the queue once it does.

  • Queue this pull request

@MartinZikmund MartinZikmund left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks @SergioAlmeida29! Checked against the generator: XamlFileGenerator rewrites x:True/x:False/x:Null to C# literals only inside the x:Bind expression text, so they really are function-argument tokens. The {x:Null} markup extension is a separate thing, and the earlier review feedback is addressed.

Optional nit: the linked issue asks where these tokens can be used (e.g. TargetNullValue/FallbackValue). Naming that case explicitly would make the docs answer it directly, but not blocking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[x:True x:False] Clarify where the x extensions for true or false are available

5 participants