Skip to content

DangerBrush for TextBox not applied #192

@dthoeni

Description

@dthoeni

Describe the bug

In the latest release a TextBox inside A GridView wont get rendered with a red border on error.
I suspect this bug was introduced with the following commit:

Commit: 8e707a6 [8e707a6]
Parents: 322e366
Author: NaBian 836904362@qq.com
Date: Montag, 23. Jänner 2023 22:27:50
Committer: NaBian
Commit Date: Sonntag, 29. Jänner 2023 23:49:17
enhance: optimize input elements.

Steps to reproduce the bug

Put a handyControl:TextBox inside a DataGrid and provoke a ValidationError

<DataGridTemplateColumn Header="Name"> <DataGridTemplateColumn.CellTemplate> <DataTemplate> <hc:TextBox MinWidth="75" hc:InfoElement.ShowClearButton="True" Text="{Binding Name, ValidatesOnDataErrors=True, UpdateSourceTrigger=PropertyChanged}"/> </DataTemplate> </DataGridTemplateColumn.CellTemplate> </DataGridTemplateColumn>

Expected behavior

Like in release 3.4.4 DangerBrush should be applied to the control.

Screenshots

Version 3.4.4
image

Version 3.4.5
image

NuGet package version

HandyControls (Custom version) 3.4.5

IDE

Visual Studio 2022

Framework type

.Net 7.0

Windows version

Windows 11 (22621)

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions