Skip to content

[dev-v5] fix: Invisible value in FluentTextArea when being used in a dialog #4767

@MarvinKlein1508

Description

@MarvinKlein1508

🐛 Bug Report

When you use a FluentTextArea within a dialog then the pre defined value will be invisible most of the time.

💻 Repro or Code Sample

Test.razor

@page "/Debug/Test"
@layout FluentUI.Demo.Client.Layout.EmptyLayout

@inject IDialogService dialogService


<FluentButton OnClick="OpenDialog">Open Dialog</FluentButton>

<FluentDialogProvider />

@code {
    private async Task OpenDialog()
    {
        var options = new DialogOptions
        {
            Modal = true,
        };

        options.Parameters.Add(nameof(TestDialog.Input), new TestInput
        {
            Text = "Test"
        });

        var result = await dialogService.ShowDialogAsync<TestDialog>(options);
    }
}

TestDialog.razor

<FluentDialogBody>

    <TitleTemplate>
        Test
    </TitleTemplate>

    <ChildContent>
        <EditForm Model="Input">
            <FluentTextArea @bind-Value="Input.Text" Label="Text" />
        </EditForm>
    </ChildContent>

    <ActionTemplate>
        <FluentButton OnClick="@(e => Dialog.CancelAsync())">Cancel</FluentButton>
        <FluentButton OnClick="@(e => Dialog.CloseAsync())" Appearance="ButtonAppearance.Primary">OK</FluentButton>
    </ActionTemplate>

</FluentDialogBody>

@code
{
    [Parameter]
    public required TestInput Input { get; set; }

    [CascadingParameter]
    public required IDialogInstance Dialog { get; set; }
}

TestInput.cs

public class TestInput
{
    public string? Text { get; set; }
}

🤔 Expected Behavior

I expect the FluentTextArea to always show Test as value whenever the dialog is open.

😯 Current Behavior

The value is invisible a lot of the times and rarely visible

2026-04-30.13-50-55.mp4

💁 Possible Solution

🔦 Context

I tested FluentTextInput and FluentNumberInput as well. Those are working consistently.

🌍 Your Environment

  • OS & Device: Windows 11 64 Bit
  • Browser latest Firefox, Chrome & Edge
  • latest dev-v5 branch

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions