Grid pagesize combobox not styled

2 posts, 0 answers
  1. Christian
    Christian avatar
    2 posts
    Member since:
    May 2017

    Posted 17 May Link to this post

    What can be a reason that the grid doesn't have a styled pagesize combobox?

    As you can see in the screenshot everything else looks OK.

     

    This is the CSHTML code:

    @(Html.Kendo().Grid(Model.Surveys)
        .Name("grid")
        .Columns(columns =>
        {
            columns.Bound(c => c.ResponseCount);
            columns.Bound(c => c.Description).HtmlAttributes(new { style = "color: green;" });
            columns.Command(c =>
            {
                c.Custom("Preview").Click("goPreview");
                c.Custom("Edit").Click("goEdit");
                c.Custom("Manage").Click("goManage");
            })
            .Title("Design & Manage");
            columns.Bound(c => c.OwnerFullName)
            .Title("Owner");
            columns.Bound(c => c.State);
            columns.Bound(c => c.BuildDateString)
            .Title("Created On");
            columns.Bound(c => c.DeploymentDateString)
            .Title("Last Modified");
        })
        .Sortable()
        .Pageable(pageable => pageable
            .Refresh(true)
            .PageSizes(new [] {"All", "10", "20", "50", "100" })
            .ButtonCount(5))
      )

     

    This is the HTML code of the page size combobox that have copied from the browser:

    <span class="k-pager-sizes k-label">
    <select>
    <option value="all">All</option>
    <option value="10">10</option>
    <option value="20">20</option>
    <option value="50">50</option>
    <option value="100">100</option>
    </select>
    items per page</span>
  2. Christian
    Christian avatar
    2 posts
    Member since:
    May 2017

    Posted 17 May in reply to Christian Link to this post

    Problem solved.

    Somehow the "columns.Command(c => ..." disturbed the styling.
    After removing that part everything looks like expected.

Back to Top