Monitus UI Library

util  4

Monitus UI Library > util > jMUI.util.ui
Search:
 
Filters

static Class jMUI.util.ui

These utilities provide ui elments.

Methods

badge_image

static void badge_image ( pBadgeURL , pSelectorOrObject , pPosition )
Badge an image: adds an image (badge) over another image (target).
Parameters:
pBadgeURL <url> url of the badge image; the image should be a file with a transparent background.
pSelectorOrObject <string|jquery object> the jquery selector to find the target image to badge OR the target image directly, as a jquery object.
pPosition <string> one of: jMUI.util.top_right (default), jMUI.util.top_center, jMUI.util.top_left, jMUI.util.bottom_right, jMUI.util.bottom_center or jMUI.util.bottom_left
Returns: void

badge_images

static void badge_images ( pBadgeURL , pPredicate , pPosition )
Badge a collection of images: adds an image (badge) over another image (target).
Parameters:
pBadgeURL <url> url of the badge image; the image should be a file with a transparent background.
pPredicate <string> a jquery selector or an array of jquery selectors.
pPosition <string> one of: jMUI.util.top_right (default), jMUI.util.top_center, jMUI.util.top_left, jMUI.util.bottom_right, jMUI.util.bottom_center or jMUI.util.bottom_left
Returns: void

countdown

static void countdown ( pCountdownSelector , pStart , pCountdownOverSelector )
Show a countdown timer.
Parameters:
pCountdownSelector <string> a jquery selector to the dom element where the counter should be drawn; inside it, there should be a span with the class "countdown"
pStart <int> number of seconds left.
pCountdownOverSelector <string> a jquery selector to the dom element shown once countdown is over. Optional. Default: null
Returns: void

create_pop_up

static button create_pop_up ( pText , pImage , pPlaceholderSelector , pPopUpID , pPopUpFc )
Create a pop-up div; these pop-ups are not blocked by pop-up blockers, as they are not in a separate window.
Parameters:
pText <string> title of the button to show the pop-up.
pImage <url> url of the image used on the button. Optional.
pPlaceholderSelector <string> jquery selector of the element into which the button shoudl be placed.
pPopUpID <string> ID of the div to show as the pop-up content. If the div does not exist, one will be created.
pPopUpFc <function> function to be called when the button is clicked.
Returns: button
a reference to the created button; the button will have a "popup" property, for quick access to the popup div.


Copyright © 2017 Yahoo! Inc. All rights reserved.