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

Higher index for modal window

4 Answers 413 Views
Window
This is a migrated thread and some comments may be shown as answers.
Seyfor
Top achievements
Rank 1
Seyfor asked on 03 Sep 2016, 08:17 AM
How can I achieve that all modal windows (and all .k-overlay) has z-index greater then 100000? Basically I want to increase z-index for constant(100000) if window is modal.

4 Answers, 1 is accepted

Sort by
0
Dimiter Topalov
Telerik team
answered on 06 Sep 2016, 10:56 AM
Hello Matjaž,

You can overwrite the default Kendo UI styles like this:

.k-overlay {
z-index: 100000 !important;
}
     
.k-widget.k-window {
z-index: 100001 !important;
}

http://dojo.telerik.com/OyEDEC

I hope this helps.

Regards,
Dimiter Topalov
Telerik by Progress
Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
0
Seyfor
Top achievements
Rank 1
answered on 13 Sep 2016, 07:59 AM
No, it does not since I need this only for modal windows.
0
Seyfor
Top achievements
Rank 1
answered on 13 Sep 2016, 08:17 AM

I found solution in adding code to toFront method:

toFront: function (e) {
     var that = this, wrapper = that.wrapper, ...
     if (this.options.modal === true)
            zIndex += 100000;

But I would really like to see kendo solution, since modifying source code is the worst solution if you regularly update sources.

0
Magdalena
Telerik team
answered on 15 Sep 2016, 07:35 AM
Hello Matjaž,

You can use the following selector to apply CSS rules only to a modal window:
.k-overlay,
.k-overlay + .k-window {
    z-index: 100000;
}

Regards,
Magdalena
Telerik by Progress
 
Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
 
Tags
Window
Asked by
Seyfor
Top achievements
Rank 1
Answers by
Dimiter Topalov
Telerik team
Seyfor
Top achievements
Rank 1
Magdalena
Telerik team
Share this question
or