CodeBeam.MudBlazor.Extensions icon indicating copy to clipboard operation
CodeBeam.MudBlazor.Extensions copied to clipboard

NoWrap Parameter does not correctly truncate values in MudSelectExtended

Open sean-mcl opened this issue 1 year ago • 0 comments
trafficstars

Description:

When setting NoWrap to true, I expect the values to be correctly truncated and the control to maintain its width. However, this does not seem to be happening. Below are the parameters I am using:

<MudSelectExtended 
    ItemCollection="Items" 
    T="SelectItem" 
    NoWrap="true" 
    MultiSelection="true" 
    Clearable="true"
    Label="DataSources" 
    Placeholder="DataSources" 
    SelectedValues="SelectedItems" 
    SelectedValuesChanged="SetSelectedValues" 
    SearchBoxVariant="Variant.Text" 
    Disabled="!Items.Any()"
    SearchFunc="@((item, s) => item.Label?.Contains(s, StringComparison.OrdinalIgnoreCase) ?? false)" 
    SearchBox="true" 
    SearchBoxAutoFocus="true" 
    SearchBoxClearable="true"
/>
 public record SelectItem
 {
     public string Label { get; set; }

     public object Value { get; set; }

     /// <inheritdoc />
     public override string ToString()
     {
         return Label;
     }
 }

Expected Behavior:

When NoWrap is set to true:

  • The values should be correctly truncated.
  • The control should maintain its width.

Actual Behavior:

  • The values are not truncated as expected.
  • The control width does not remain consistent.

image

Steps to Reproduce:

  1. Use the MudSelectExtended component with the parameters provided above.
  2. Set NoWrap to true.
  3. Observe the behavior of the control and the values displayed.

Environment:

  • Version: 7.0.0-rc.1
  • Browser Microsoft Edge

sean-mcl avatar Jul 02 '24 16:07 sean-mcl