Hierarchy

  • DomHelper

Constructors

Methods

  • Includes the CSS from the given URL in the document.
    Can be used for dynamic laoding of web fonts, ...

    Parameters

    • url: string

    Returns void

  • Includes the JavaScript from the given URL in the document. Uses async loading where supported by the browser.

    Parameters

    • url: string
    • Optional callback: Function

      Called after loaded successfully

    Returns void

  • Copies either the given text or the content of the given DOM element to the clipboard

    Returns

    Wether copying was successful or not

    Parameters

    • src: string | HTMLElement

    Returns boolean

  • Defer the execution of the given method until the control has actually been rendered (the afterrender event has been fired)

    Parameters

    • ctrl: Cbn.ctrls.Base
    • method: Function

      The method which should be executed after the control has been rendered

    • Optional args: any[]

      Arguments which should be passed to the method after the control has been rendered

    • Optional event: string

      Custom event to use instead of afterrender.

    Returns void

  • Extends the Ext.ComponentQuery.query method by only returning the first result instead of an array with results.
    See ExtJS docu of Ext.ComponentQuery.query for parameter description...

    Parameters

    Returns undefined | ExtComponent

  • Scrolls the given element into view

    !!! Note !!!

    This function hasn't been tested & used a lot so far which means that it could easily be that it won't work under all conditions (e.g. horizontal scrolling, elements with absolute positioning etc)

    Parameters

    • el: HTMLElement
    • scrollEl: HTMLElement

      The element which contains the scrollbars

    • Optional pos: "Center" | "Top" | "Bottom"

      'Top', 'Center' or 'Bottom'

    • Optional ifNeeded: boolean

      If true, only scrolls if the given is el isn't already visible.

    • Optional animateDuration: number

      Animation duration in [ms].
      Not animated if not given.

    Returns void

Generated using TypeDoc