UNPKG

devextreme

Version:

HTML5 JavaScript Component Suite for Responsive Web Development

58 lines (52 loc) 2.48 kB
/** * DevExtreme (ui/defer_rendering.d.ts) * Version: 20.1.7 * Build date: Tue Aug 25 2020 * * Copyright (c) 2012 - 2020 Developer Express Inc. ALL RIGHTS RESERVED * Read about DevExtreme licensing here: https://js.devexpress.com/Licensing/ */ import { animationConfig } from '../animation/fx'; import '../jquery_augmentation'; import { dxElement } from '../core/element'; import Widget, { WidgetOptions } from './widget/ui.widget'; /** Warning! This type is used for internal purposes. Do not import it directly. */ export interface dxDeferRenderingOptions extends WidgetOptions<dxDeferRendering> { /** Specifies the animation to be used to show the rendered content. */ animation?: animationConfig; /** A function that is executed when the content is rendered but not yet displayed. */ onRendered?: ((e: { component?: dxDeferRendering, element?: dxElement, model?: any }) => any); /** A function that is executed when the content is displayed and animation is completed. */ onShown?: ((e: { component?: dxDeferRendering, element?: dxElement, model?: any }) => any); /** Specifies when the widget content is rendered. */ renderWhen?: Promise<void> | JQueryPromise<void> | boolean; /** Indicates if a load indicator should be shown until the widget's content is rendered. */ showLoadIndicator?: boolean; /** Specifies a jQuery selector of items that should be rendered using a staggered animation. */ staggerItemSelector?: string; } /** The DeferRendering is a widget that waits for its content to be ready before rendering it. While the content is getting ready, the DeferRendering displays a loading indicator. */ export default class dxDeferRendering extends Widget { constructor(element: Element, options?: dxDeferRenderingOptions) constructor(element: JQuery, options?: dxDeferRenderingOptions) } declare global { interface JQuery { dxDeferRendering(): JQuery; dxDeferRendering(options: "instance"): dxDeferRendering; dxDeferRendering(options: string): any; dxDeferRendering(options: string, ...params: any[]): any; dxDeferRendering(options: dxDeferRenderingOptions): JQuery; } } /** Warning! This type is used for internal purposes. Do not import it directly. */ export type Options = dxDeferRenderingOptions; /** @deprecated use Options instead */ /** Warning! This type is used for internal purposes. Do not import it directly. */ export type IOptions = dxDeferRenderingOptions;