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

Add Bootstrap style to button.

3 Answers 659 Views
Upload
This is a migrated thread and some comments may be shown as answers.
Jose Mejia
Top achievements
Rank 1
Jose Mejia asked on 06 Feb 2014, 01:47 PM
Hi.

I want to add to button Bootstrap class='btn btn-primary', but whatever I tried it didn't help.
I tried this:
$(".k-button.k-upload-button").addClass("btn btn-primary");
nothing help, then I tried use templates:
<input name="files"  id="files" type="file"/>
<script id="fileTemplate" type="text/x-kendo-template">
  <div>
     <button type='button' class='btn btn-primary' ></button>
</div>
</script>

and use  template function, but no result.

What I'm doing wrong? 

Thanks in advance.


3 Answers, 1 is accepted

Sort by
0
Accepted
Iliana Dyankova
Telerik team
answered on 07 Feb 2014, 11:49 AM
Hi Jose,

This scenario is not supported out-of-the-box and in order to achieve the same outcome as "btn btn-primary" for Kendo UI Upload button you should explicitly set the styles. As an example: 
.k-button.k-upload-button {
   color:#fff;
   background-color:#428bca;
   border-color:#357ebd
}

Regards,
Iliana Nikolova
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
KEG
Top achievements
Rank 2
answered on 14 Sep 2015, 07:33 PM
This is messed up.  This is one of the primary reasons I dislike the kendo UI/mvc libraries.  All properties should be able to be overwritten with site specific implementations, especially display aspects, i.e. css.
0
Iliana Dyankova
Telerik team
answered on 16 Sep 2015, 02:52 PM
Hi Keith,

Unfortunately, there is no way to ensure integration compatibility with other third-party library styles and in some cases custom overrides are needed.

Regards,
Iliana Nikolova
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Upload
Asked by
Jose Mejia
Top achievements
Rank 1
Answers by
Iliana Dyankova
Telerik team
KEG
Top achievements
Rank 2
Share this question
or