2014-01-23 53 views
1

希望我在这里提供的内容足以帮助我解决显示问题。KendoUI日期选择器输入字段显示问题


你可以在行动看到这一点:http://dev.skoovy.com 用户名: [email protected] 密码: test123

这是在的顶部形态页。这是一个正在开发的网站。


当我建立一个输入字段,以提供一个datepicker,它改变输入字段包含旁边的日历图标此添加区域。我找不到为什么会发生这种情况。

下面是它用datepicker初始化的样子。用红笔突出显示的区域是我正在尝试解决的问题。

input fields with datepicker initialized

而且,这里是它lookslike没有日期选择器初始化。

enter image description here

这里是来自调试器窗格中铬(通过元件选择器)作为复制的HTML

<div class="when_range_input" style="display: block;"> 
Start: <span class="k-widget k-datepicker k-header" style=""><span class="k-picker-wrap k-state-default"><input type="text" id="when_range_start" name="wv_drs" value="" data-role="datepicker" class="k-input" role="textbox" aria-haspopup="true" aria-expanded="false" aria-owns="when_range_start_dateview" aria-disabled="false" aria-readonly="false" aria-label="Current focused date is null" style="width: 100%;"><span unselectable="on" class="k-select" role="button" aria-controls="when_range_start_dateview"><span unselectable="on" class="k-icon k-i-calendar">select</span></span></span></span> 
&nbsp;End: <span class="k-widget k-datepicker k-header" style=""><span class="k-picker-wrap k-state-default"><input type="text" id="when_range_end" name="wv_dre" value="" data-role="datepicker" class="k-input" role="textbox" aria-haspopup="true" aria-expanded="false" aria-owns="when_range_end_dateview" aria-disabled="false" aria-readonly="false" aria-label="Current focused date is null" style="width: 100%;"><span unselectable="on" class="k-select" role="button" aria-controls="when_range_end_dateview"><span unselectable="on" class="k-icon k-i-calendar">select</span></span></span></span> 
</div> 

这里是我使用的CSS:

.when_range_input { 
    display:none; 
    position:absolute; 
    width:350px; 
    /** margin-left:320px; **/ 
    border-color:#ffcc00; 
    padding:5px; 
    z-index:9999; 
    font-size:11px; 
    -webkit-box-shadow: 3px 3px 10px rgba(50, 50, 50, 0.55); 
    -moz-box-shadow: 3px 3px 10px rgba(50, 50, 50, 0.55); 
    box-shadow: 3px 3px 10px rgba(50, 50, 50, 0.55); 
    -webkit-border-radius: 3px; 
    -moz-border-radius: 3px; 
    border-radius: 3px; 
    background-color:#ffffff; 
} 

.when_range_input input[type="text"] { 
    background-color: #fff; 
    border-color: #e2e2e2; 
    border-style: solid; 
    border-width: 1px; 
    font-size: 11px; 
    color: #b8b8b8; 
    padding: 2px 1px 2px 1px; 
    line-height: 15px; 
    height: 20px; 
} 
+0

PLease提供给我们一个演示链接 –

+0

我已更新该帖子以包含链接并登录到dev站点。 – kambythet

回答

1

你应该改变输入的最大宽度f ield

.headersearch-flex-container .searchfld.flex-item:nth-child(2) input { 
    width: 90px; 
    max-width: 110px; 
    min-width: 80px; 
} 
+0

太棒了!非常感谢。 – kambythet