Open Closed

Selection box for Blazorise-Autocomplete takes up the full browser page #6488


User avatar
0
karl.ettinger@energieag.at created
  • ABP Framework version: v8.0.1
  • UI Type: Blazor Server
  • Database System: EF Core (SQL Server, Oracle, MySQL, PostgreSQL, etc..) / SQL Server
  • Tiered (for MVC) or Auth Server Separated (for Angular): no
  • Exception message and full stack trace: -
  • Steps to reproduce the issue:

Please download the sample project: https://powershare.energieag.at/s/BB9MiHWAX5PASPa (Please contact me for the password)

In the example project Enter a country in the Book Store/Authors/New author menu in the example project (e.g. Deutschland)

Sourcecode: Acme.BookStore.Blazor/Pages/Authors.razor

By the way, does not work with either


5 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Please share the password, liming.ma@volosoft.com

    Thanks.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Add below styles to your blazor-global-styles.css

    .dropdown > div.dropdown-menu {
      position: fixed !important;
    }
    
    .dropdown.b-is-autocomplete > div.dropdown-menu {
      position: absolute !important;
    }
    
    

  • User Avatar
    0
    karl.ettinger@energieag.at created

    Thanks the autocomplete selection box works now.

    But if a country is entered that is not in the list, the content of <NotFoundContent> is not displayed.

  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    Please use FreeTypingNotFoundTemplate.

    <Field>
        <FieldLabel>
            Countries
        </FieldLabel>
        <Autocomplete
            TItem="string"
            TValue="string"
            Data="@Countries"
            TextField="@( ( item ) => item)"
            ValueField="@( ( item ) => item)"
            @bind-SelectedValue="@SelectedSearchValue"
            @bind-SelectedText="@SelectedAutoCompleteText"
            Placeholder="Search..."
            Filter="AutocompleteFilter.StartsWith"
            FreeTyping>
            <FreeTypingNotFoundTemplate>
                Sorry... @context was not found! : (
            </FreeTypingNotFoundTemplate>
        </Autocomplete>
    </Field>
    

  • User Avatar
    0
    karl.ettinger@energieag.at created

    Great thanks, it works!

Made with ❤️ on ABP v9.1.0-preview. Updated on November 11, 2024, 11:11