Skip to content

Latest commit

 

History

History
30 lines (22 loc) · 1.27 KB

scomp_lazy.rst

File metadata and controls

30 lines (22 loc) · 1.27 KB

django

Custom tag which adds a 'loader' image to the page and performs a one-time action when loader comes into view.

mod_geomap uses this to load the map Javascript once the admin widget has been opened by the user.

Example:

<div id="{{ #lazy }}">
  {% lazy action={update target=#lazy id=id template="_geomap_admin_location_map.tpl"} %}
</div>

lazy accepts the following arguments:

Argument Description Example
image The source of the image tag. Defaults to /lib/images/spinner.gif. image="/lib/images/loading.gif"
class The css class of the image. Defaults to z-lazy. class="loader"