Skip to content

Add IsValid property to ValidationStateChangedEventArg#67362

Open
vendasankarsf3945 wants to merge 1 commit into
dotnet:mainfrom
vendasankarsf3945:feat-13413-isvalid
Open

Add IsValid property to ValidationStateChangedEventArg#67362
vendasankarsf3945 wants to merge 1 commit into
dotnet:mainfrom
vendasankarsf3945:feat-13413-isvalid

Conversation

@vendasankarsf3945

@vendasankarsf3945 vendasankarsf3945 commented Jun 22, 2026

Copy link
Copy Markdown

Include valid/invalid state in ValidationStateChangedEventArgs

Description

ValidationStateChangedEventArgs currently does not expose whether the affected field is in a valid or invalid state. Consumers handling EditContext.OnValidationStateChanged must re-query validation messages to determine the field’s status.
This PR updates ValidationStateChangedEventArgs to include the current valid/invalid state, allowing event subscribers to react directly to validation outcomes without additional lookups.

Before

  • EditContext.OnValidationStateChanged only indicated that validation state had changed.
  • ValidationStateChangedEventArgs did not contain any information about whether the field was valid or invalid.
  • Consumers were required to:
    • Call EditContext.GetValidationMessages(...), or
    • Perform additional validation checks to infer validity.

After

  • ValidationStateChangedEventArgs includes an IsValid property indicating the field’s validation state.
  • EditContext.OnValidationStateChanged subscribers can directly determine validation results from the event arguments.
  • This simplifies validation-related logic, reduces redundant validation queries, and improves developer ergonomics.

Fixes #13413

@vendasankarsf3945 vendasankarsf3945 requested review from a team and tdykstra as code owners June 22, 2026 08:02
@vendasankarsf3945

Copy link
Copy Markdown
Author

@dotnet-policy-service agree company="Syncfusion, Inc."

@dotnet-policy-service dotnet-policy-service Bot added the community-contribution Indicates that the PR has been added by a community member label Jun 22, 2026
@dotnet-policy-service

Copy link
Copy Markdown
Contributor

Thanks for your PR, @vendasankarsf3945. Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

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

Labels

community-contribution Indicates that the PR has been added by a community member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Include valid/invalid state in ValidationStateChangedEventArgs

1 participant