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

How to remove "Clear" button

3 Answers 1055 Views
DropDownList
This is a migrated thread and some comments may be shown as answers.
Peter
Top achievements
Rank 1
Peter asked on 29 Nov 2016, 04:40 AM

A recent change - probably from here - https://github.com/telerik/kendo-ui-core/issues/1650

Means that all our input boxes now come with what is, for us, an ugly and inappropriate clear button.

Seems especially odd to make it appear on a DropDownList - since all our values are readonly.

Can you advise the best way to remove this feature?

Project wide would be nice.

3 Answers, 1 is accepted

Sort by
2
Rumen
Telerik team
answered on 29 Nov 2016, 11:17 AM
Hello,

You can hide the X icon with the following CSS class:

<style>
  .k-icon.k-i-close
  {
    display: none !important;
  }
</style>

Here you go a dojo sample: http://dojo.telerik.com/@RumenJ/AZazE.

Best regards,
Rumen
Telerik by Progress
Kendo UI is ready for Visual Studio 2017 RC! Learn more.
0
Carol
Top achievements
Rank 1
answered on 27 Apr 2017, 04:28 PM

I had to do this to make it go away...

 

.k-icon.k-clear-value.k-i-close { display: none !important; }
0
C
Top achievements
Rank 1
Iron
answered on 23 Aug 2021, 01:07 AM

You may also need this, otherwise input field is still shortened to leave room for clear button:

.k-combobox-clearable .k-input { padding-right: 0}
Or better yet, set clearButton:false when creating the widget 
Tags
DropDownList
Asked by
Peter
Top achievements
Rank 1
Answers by
Rumen
Telerik team
Carol
Top achievements
Rank 1
C
Top achievements
Rank 1
Iron
Share this question
or