This is a migrated thread and some comments may be shown as answers.

Empty SelectItems do no display correctly

1 Answer 206 Views
DropDownList
This is a migrated thread and some comments may be shown as answers.
Paul
Top achievements
Rank 1
Paul asked on 08 Aug 2012, 04:13 PM
Hi,

I am using the Kendo DropDownList via the Asp.Net Mvc wrapper and binding it to a SelectList in my Model. If a SelectItem is empty (i.e. Text = "") then it displays with a height of (almost) zero making it appear invisible in the list. This behaviour is different from the Telerik Extensions for Asp.Net Mvc, which displays as I would expect - empty items at the same line height as non-empty items.

Does anyone know of a workaround or if/when this will be fixed?

many thanks.

1 Answer, 1 is accepted

Sort by
0
Dimo
Telerik team
answered on 13 Aug 2012, 11:08 AM
Hi Paul,

The observed problem is easy to fix with the following CSS style:

.k-popup .k-list .k-item {
    min-height: 1.8em;
}

However, I can see the same behavior in the MVC component, probably you already have a similar workaround applied there. On a side note, I recommend avoiding empty list items for selection as unusable - one doesn't know what is selecting, does he?

Regards,
Dimo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
DropDownList
Asked by
Paul
Top achievements
Rank 1
Answers by
Dimo
Telerik team
Share this question
or