LoadPanel Configuration

An object that defines configuration options for the LoadPanel widget.

animation

An object defining the animation options of the widget.

Type: Object
Default Value: null

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        bindingOptions: { 
            visible: 'loadPanelVisible',
            animation: 'animationConfig'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">Animation Type</div>
            <div class="dx-field-value" dx-select-box="{
                dataSource: animationTypes,
                onValueChanged: typeChanged,
                title: 'Animation type'
            }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false;
    $scope.animationTypes = ["fade", "pop", "slide"];
    $scope.animationConfig = {
        show: { type: "slide", from: { top: -200 }, to: { top: 200 } },
        hide: { type: "slide", from: { top: 200 }, to: { top: -200 } }
    };
    $scope.typeChanged = function (e) {
        switch (e.value) {
            case "slide":
                $scope.animationConfig = {
                    show: { type: "slide", from: { top: -200 }, to: { top: 200 } },
                    hide: { type: "slide", from: { top: 200 }, to: { top: -200 } }
                };
                break;
            case "pop":
                $scope.animationConfig = {
                    show: { type: "pop", from: { scale: 0 }, to: { scale: 1 } },
                    hide: { type: "pop", from: { scale: 1 }, to: { scale: 0 } }
                };
                break;
            case "fade":
                $scope.animationConfig = {
                    show: { type: "fade", from: 0, to: 1 },
                    hide: { type: "fade", from: 1, to: 0 }
                };
                break;
        }
    };
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    animation: animationConfig
}"></div>
<div class="dx-fieldset">
  <div class="dx-field">
    <div class="dx-field-label">Animation Type</div>
    <div class="dx-field-value" data-bind="dxSelectBox: {
      dataSource: animationTypes,
      onValueChanged: typeChanged,
      title: 'Animation type'
    }"></div>
  </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    animationTypes: ["fade", "pop", "slide"],
    animationConfig: ko.observable({}),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    },
    typeChanged: function (e) {
        switch (e.value) {
            case "slide":
                this.animationConfig({
                    show: { type: "slide", from: { top: -200 }, to: { top: 200 } },
                    hide: { type: "slide", from: { top: 200 }, to: { top: -200 } }
                });
                break;
            case "pop":
                this.animationConfig({
                    show: { type: "pop", from: { scale: 0 }, to: { scale: 1 } },
                    hide: { type: "pop", from: { scale: 1 }, to: { scale: 0 } }
                });
                break;
            case "fade":
                this.animationConfig({
                    show: { type: "fade", from: 0, to: 1 },
                    hide: { type: "fade", from: 1, to: 0 }
                });
                break;
        }
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
  <div class="dx-field">
    <div class="dx-field-label">Animation Type</div>
    <div class="dx-field-value" id="animationTypeSelector"></div>
  </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
$("#animationTypeSelector").dxSelectBox({
    dataSource: ["fade", "pop", "slide"],
    onValueChanged: function (e) {
        var animationConfig;
        switch (e.value) {
            case "slide":
                animationConfig = {
                    show: { type: "slide", from: { top: -200 }, to: { top: 200 } },
                    hide: { type: "slide", from: { top: 200 }, to: { top: -200 } }
                };
                break;
            case "pop":
                animationConfig = {
                    show: { type: "pop", from: { scale: 0 }, to: { scale: 1 } },
                    hide: { type: "pop", from: { scale: 1 }, to: { scale: 0 } }
                };
                break;
            case "fade":
                animationConfig = {
                    show: { type: "fade", from: 0, to: 1 },
                    hide: { type: "fade", from: 1, to: 0 }
                };
                break;
        }
        $("#myLoadPanel").dxLoadPanel("instance").option("animation", animationConfig);
    }
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}

closeOnOutsideClick

A Boolean value specifying whether or not the widget is closed if a user clicks outside of the overlapping window.

Type: Boolean| function
Function parameters:
event: jQuery.Event
Holds the jQuery event that caused widget closing.
Return Value: Boolean
The required option value.
Default Value: false

The function passed to this option enables you to specify a custom condition for widget closing. For instance, you can prevent closing until a user clicks a certain element.

JavaScript
var widgetOptions = {
    // ...
    closeOnOutsideClick: function(e) {
        return e.target === $("#someElement").get()[0];
    }
}

deferRendering

Specifies whether widget content is rendered when the widget is shown or when rendering the widget.

Type: Boolean
Default Value: true

If this option is set to true, widget content is rendered when showing the widget. Otherwise, widget content is rendered when rendering the widget.

delay

The delay in milliseconds after which the load panel is displayed.

Type: Number
Default Value: 0

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        bindingOptions: { 
            visible: 'loadPanelVisible',
            delay: 'delayValue'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">delay</div>
            <div class="dx-field-value" ng-model="delayValue" dx-number-box="{
                min: 0,
                max: 2000,
                step: 100,
                showSpinButtons: true
            }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.delayValue = 0,
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button {
    margin: 10px;
}
<div class="button" data-bind="dxButton:{text: 'Load', onClick: startLoading}"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    delay: delayValue
}"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">delay</div>
        <div class="dx-field-value" data-bind="dxNumberBox: {
            min: 0,
            max: 2000,
            step: 100,
            showSpinButtons: true,
            value: delayValue
        }"></div>
    </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    delayValue: ko.observable(0),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button {
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">delay</div>
        <div class="dx-field-value" id="delayField"></div>
    </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false,
    delay: 0
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").show();
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").hide();
}
$("#delayField").dxNumberBox({
    min: 0,
    max: 2000,
    step: 100,
    showSpinButtons: true,
    value: 0,
    onValueChanged: function (e) {
        $("#myLoadPanel").dxLoadPanel("instance").option("delay", e.value);
    }
});
body{
    text-align: center;
}
.button {
    margin: 10px;
}

focusStateEnabled

Specifies whether or not the widget can be focused.

Type: Boolean
Default Value: false

height

The height of the widget.

Type: Number
Default Value: 90

The option can hold a value of the following types.

  • number
    The height of the widget in pixels

  • string
    A CSS measurement of the widget height (e.g., "55px", "80%", "auto" and "inherit")

  • function
    A function returning the widget height (e.g., height:function(){ return baseHeight - 10 + "%"; })

hint

Specifies the text of the hint displayed for the widget.

Type: String
Default Value: undefined

hoverStateEnabled

A Boolean value specifying whether or not the widget changes its state when being hovered by an end user.

Type: Boolean
Default Value: false

indicatorSrc

A URL pointing to an image to be used as a load indicator.

Type: String
Default Value: ''

maxHeight

Specifies the maximum height the widget can reach while resizing.

Type: Number|String| function
Return Value: Number|String
The maximum height value.
Default Value: null

The option can hold a value of the following types.

  • numeric - the height in pixels
  • string - a CSS measurement of the height (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the height (e.g., width:function(){ return baseWidth - 10 + "%"; })

maxWidth

Specifies the maximum width the widget can reach while resizing.

Type: Number|String| function
Return Value: Number|String
The maximum width value.
Default Value: null

The option can hold a value of the following types.

  • numeric - the width in pixels
  • string - a CSS measurement of the width (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the width (e.g., width:function(){ return baseWidth - 10 + "%"; })

message

The text displayed in the load panel.

Type: String
Default Value: 'Loading ...'

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        bindingOptions: { 
            visible: 'loadPanelVisible',
            message: 'loadMessage'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">delay</div>
            <div class="dx-field-value" ng-model="loadMessage" dx-text-box="{ }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.loadMessage = "Loading...",
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{text: 'Load', onClick: startLoading}"></div>
<div data-bind="dxLoadPanel:{
    visible: loadPanelVisible,
    message: loadMessage
}"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">delay</div>
        <div class="dx-field-value" data-bind="dxTextBox: {
            value: loadMessage
        }"></div>
    </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    loadMessage: ko.observable("Loading..."),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label"></div>
        <div class="dx-field-value" id="messageField"></div>
    </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").show();
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").hide();
}
$("#messageField").dxTextBox({
    value: 'Loading...',
    onValueChanged: function (e) {
        $("#myLoadPanel").dxLoadPanel("instance").option("message", e.value);
    }
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}

minHeight

Specifies the minimum height the widget can reach while resizing.

Type: Number|String| function
Return Value: Number|String
The minimum height value.
Default Value: null

The option can hold a value of the following types.

  • numeric - the height in pixels
  • string - a CSS measurement of the height (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the height (e.g., width:function(){ return baseWidth - 10 + "%"; })

minWidth

Specifies the minimum width the widget can reach while resizing.

Type: Number|String| function
Return Value: Number|String
The minimum width value.
Default Value: null

The option can hold a value of the following types.

  • numeric - the width in pixels
  • string - a CSS measurement of the width (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the width (e.g., width:function(){ return baseWidth - 10 + "%"; })

onContentReady

A handler for the contentReady event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action when widget content is ready.

onDisposing

A handler for the disposing event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action when the widget is being removed.

NOTE: The function assigned to this option is executed only if the widget is removed using the remove(), empty(), or html() jQuery methods.

onHidden

A handler for the hidden event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action after the widget is hidden.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        onHidden: loadPanelHidden,
        bindingOptions: { 
            visible: 'loadPanelVisible' 
        }
    }"></div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.loadPanelHidden = function () {
        DevExpress.ui.notify("Load panel is hidden", "success", 1500);
    };
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    onHidden: loadPanelHidden
}"></div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    },
    loadPanelHidden: function () {
        DevExpress.ui.notify("Load panel is hidden", "success", 1500);
    }
}
ko.applyBindings(myViewModel);
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false,
    onHidden: function () {
        DevExpress.ui.notify("Load panel is hidden", "success", 1500);
    }
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}

onHiding

A handler for the hiding event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
cancel: Boolean
Indicates whether to cancel hiding the overlay.
Default Value: null

Assign a function to perform a custom action before hiding the widget.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        onHiding: loadPanelHiding,
        bindingOptions: { 
            visible: 'loadPanelVisible' 
        }
    }"></div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.loadPanelHiding = function () {
        DevExpress.ui.notify("Load panel is being hidden now", "success", 1500);
    };
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    onHiding: loadPanelHiding
}"></div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    },
    loadPanelHiding: function () {
        DevExpress.ui.notify("Load panel is being hidden now", "success", 1500);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false,
    onHiding: function () {
        DevExpress.ui.notify("Load panel is being hidden now", "success", 1500);
    }
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
body{
    text-align: center;
}
.button{
    margin: 10px;
}

onInitialized

A handler for the initialized event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
Default Value: null

Assign a function to perform a custom action when the widget is initialized.

onOptionChanged

A handler for the optionChanged event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
name: String
Specifies the name of the option whose value is changed.
fullName: String
Specifies a full name of the option whose value is changed. The full name is formed by concatenating the names of the options that are presented in the hierarchy of the given option. The names are delimited by commas.
value: any
Specifies a new value for the option.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action after an option of the component is changed.

onShowing

A handler for the showing event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action before showing the widget.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        onShowing: loadPanelShowing,
        bindingOptions: { 
            visible: 'loadPanelVisible' 
        }
    }"></div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.loadPanelShowing = function () {
        DevExpress.ui.notify("Load panel is being shown now", "success", 1500);
    };
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    onShowing: loadPanelShowing
}"></div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    },
    loadPanelShowing: function () {
        DevExpress.ui.notify("Load panel is being shown now", "success", 1500);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false,
    onShowing: function () {
        DevExpress.ui.notify("Load panel is being shown now", "success", 1500);
    }
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
body{
    text-align: center;
}
.button{
    margin: 10px;
}

onShown

A handler for the shown event.

Type: function
Function parameters:
e: Object
Provides function parameters.
Object structure:
component: Object
Provides access to the widget instance.
element: jQuery
An HTML element of the widget.
model: Object
Provides access to the data that is available for binding against the element. Available only in the Knockout approach.
Default Value: null

Assign a function to perform a custom action after the widget is shown.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        onShown: loadPanelShown,
        bindingOptions: { 
            visible: 'loadPanelVisible' 
        }
    }"></div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.loadPanelShown = function () {
        DevExpress.ui.notify("Load panel is shown", "success", 1500);
    };
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    onShown: loadPanelShown
}"></div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    },
    loadPanelShown: function () {
        DevExpress.ui.notify("Load panel is shown", "success", 1500);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false,
    onShown: function () {
        DevExpress.ui.notify("Load panel is shown", "success", 1500);
    }
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
body{
    text-align: center;
}
.button{
    margin: 10px;
}

position

An object defining widget positioning options.

Default Value: { my: 'center', at: 'center', of: window }

rtlEnabled

Specifies whether or not the current component supports a right-to-left representation.

Type: Boolean
Default Value: false

If you need to switch the display of this DevExtreme component to right-to-left, enable a specifically designed configuration option - rtlEnabled. When this option is set to true, the text flows from right to left, and the layout the component's elements is reversed. To switch the entire application/site to a right-to-left representation, use the static DevExpress.rtlEnabled field.

shading

A Boolean value specifying whether or not the main screen is inactive while the widget is active.

Type: Boolean
Default Value: true

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{
        message: 'Loading...',
        bindingOptions: { 
            visible: 'loadPanelVisible',
            shading: 'shadingValue'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">shading</div>
            <div class="dx-field-value" ng-model="shadingValue" dx-switch="{ }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.shadingValue = true,
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{text: 'Load', onClick: startLoading}"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    shading: shadingValue
}"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">shading</div>
        <div class="dx-field-value" data-bind="dxSwitch: {
            value: shadingValue
        }"></div>
    </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    shadingValue: ko.observable(true),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">shading</div>
        <div class="dx-field-value" id="shadingSelector"></div>
    </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    shading: true,
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").show();
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").hide();
}
$("#shadingSelector").dxSwitch({
    value: true,
    onValueChanged: function (e) {
        $("#myLoadPanel").dxLoadPanel("instance").option("shading", e.value);
    }
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}

shadingColor

Specifies the shading color.

Type: String
Default Value: ''
Default for generic: 'transparent',

This option makes sense only if the shading option is set to true.

showIndicator

A Boolean value specifying whether or not to show a load indicator.

Type: Boolean
Default Value: true

If this option is set to true, a message is displayed and a load indicator turns in a circle while the view's content is loaded. Set this option to false to display only the text message. This can help avoid problems with animation used for the load indicator when running on a slow device.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{
        message: 'Loading...',
        bindingOptions: { 
            visible: 'loadPanelVisible',
            showIndicator: 'indicatorVisible'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">showIndicator</div>
            <div class="dx-field-value" ng-model="indicatorVisible" dx-switch="{ }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.indicatorVisible = true,
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{text: 'Load', onClick: startLoading}"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    showIndicator: indicatorVisible
}"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">showIndicator</div>
        <div class="dx-field-value" data-bind="dxSwitch: {
            value: indicatorVisible
        }"></div>
    </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    indicatorVisible: ko.observable(true),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">showIndicator</div>
        <div class="dx-field-value" id="indicatorSelector"></div>
    </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    showIndicator: true,
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").show();
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").hide();
}
$("#indicatorSelector").dxSwitch({
    value: true,
    onValueChanged: function (e) {
        $("#myLoadPanel").dxLoadPanel("instance").option("showIndicator", e.value);
    }
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}

showPane

A Boolean value specifying whether or not to show the pane behind the load indicator.

Type: Boolean
Default Value: true

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{
        message: 'Loading...',
        shading: false,
        bindingOptions: { 
            visible: 'loadPanelVisible',
            showPane: 'paneVisible'
        }
    }"></div>
    <div class="dx-fieldset">
        <div class="dx-field">
            <div class="dx-field-label">showPane</div>
            <div class="dx-field-value" ng-model="paneVisible" dx-switch="{ }"></div>
        </div>
    </div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.paneVisible = true,
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible,
    shading: false,
    showPane: paneVisible
}"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">showPane</div>
        <div class="dx-field-value" data-bind="dxSwitch: {
            value: paneVisible
        }"></div>
    </div>
</div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    paneVisible: ko.observable(true),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body{
    text-align: center;
}
.button{
    margin: 10px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
<div class="dx-fieldset">
    <div class="dx-field">
        <div class="dx-field-label">showPane</div>
        <div class="dx-field-value" id="paneSelector"></div>
    </div>
</div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    showPane: true,
    shading: false,
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").show();
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").hide();
}
$("#paneSelector").dxSwitch({
    value: true,
    onValueChanged: function (e) {
        $("#myLoadPanel").dxLoadPanel("instance").option("showPane", e.value);
    }
});
body{
    text-align: center;
}
.button{
    margin: 10px;
}

visible

A Boolean value specifying whether or not the widget is visible.

Type: Boolean
Default Value: false

You can show and hide the widget by changing the value of an observable variable passed to this option.

Show Example:
AngularJS
Knockout
jQuery
<div ng-controller="demoController" style="height: 100%;">
    <div class="button" dx-button="{ text: 'Load', onClick: startLoading }"></div><br />
    <div id="myLoadPanel" dx-load-panel="{ 
        message: 'Loading...',
        bindingOptions: { 
            visible: 'loadPanelVisible' 
        }
    }"></div>
</div>
var myApp = angular.module('myApp', ['dx']);
myApp.controller("demoController", function ($scope) {
    $scope.loadPanelVisible = false,
    $scope.startLoading = function () {
        $scope.loadPanelVisible = true;
        setTimeout(finishLoading, 3000);
    };
    var finishLoading = function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
    };
});
angular.element(document).ready(function () {
    angular.bootstrap(document, ['myApp']);
});
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}
<div class="button" data-bind="dxButton:{ text: 'Load', onClick: startLoading }"></div>
<div data-bind="dxLoadPanel:{
    message: 'Loading...',
    visible: loadPanelVisible
}"></div>
var myViewModel = {
    loadPanelVisible: ko.observable(false),
    startLoading: function () {
        this.loadPanelVisible(true);
        setTimeout($.proxy(this.finishLoading, this), 3000);
    },
    finishLoading: function () {
        this.loadPanelVisible(false);
    }
}
ko.applyBindings(myViewModel);
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}
<div class="button" id="loadButton"></div><br />
<div id="myLoadPanel"></div>
$("#myLoadPanel").dxLoadPanel({
    message: 'Loading...',
    visible: false
});
$("#loadButton").dxButton({
    text: 'Load',
    onClick: function () {
        $("#myLoadPanel").dxLoadPanel("instance").option("visible", true);
        setTimeout($.proxy(finishLoading, this), 3000);
    }
});
var finishLoading = function () {
    $("#myLoadPanel").dxLoadPanel("instance").option("visible", false);
}
body {
    text-align: center;
}
.button {
    margin-top: 25px;
}

width

The width of the widget.

Type: Number
Default Value: 222

The option can hold a value of the following types.

  • numeric - the widget width in pixels
  • string - a CSS measurement of the widget width (e.g., "55px", "80%", "auto" and "inherit")
  • function - the function returning the widget width (e.g., width:function(){ return baseWidth - 10 + "%"; })