image



  • Extends basecontrol
  • Syntax

    <div data-juci="image" data-value="/img/image.png"></div>
    <div data-juci="image" data-bind="ref: img" data-uri="true"></div>

    Attributes

    • data-uri {Boolean}
      True for data uri string, else URL reference by default.
    • data-juci {String}
      A string with value image.

    Methods

    • onError(handler, context)
      Registers a handler function to call when the image#error event fires.
      Parameters:
      • handler{Function}
        A handler function to execute when the image#error event fires.
      • context{Object} Optional
        Context in which the handler function should execute.
    • onLoad(handler, context)
      Registers a handler function to call when the image#event:load event fires.
      Parameters:
      • handler{Function}
        A handler function to execute when the image#event:load event fires.
      • context{Object} Optional
        Context in which the handler function should execute.

    Events

    • error(eventObj)
      Fires when the image loading has failed
      Parameters:
    • load(eventObj)
      Fires when the image has loaded in the control
      Parameters: