Class CQ_Analytics.MobileSliderUtils
| Package: | CQ_Analytics |
| Class: | MobileSliderUtils |
| Extends: | Object |
| Clientlib: | personalization.stores, personalization.stores.surferinfo |
A helper class providing a set of utility methods for the mobile slider.
This class is a singleton and cannot be created directly.
Added in CQ 5.5.
Public Properties
| |
MobileSliderUtils.CONFIG : Object
<static> Mobile slider config per application. Sample config:
window.CQMobileSlider["geometrixx-outdoors"] = {
...
<static> Mobile slider config per application. Sample config:
window.CQMobileSlider["geometrixx-outdoors"] = {
//CSS used by desktop that need to be removed when mobile
DESKTOP_CSS: [
"/etc/designs/${app}/clientlibs_desktop_v1.css"
],
//CSS used by mobile that need to be removed when desktop
MOBILE_CSS: [
"/etc/designs/${app}/clientlibs_mobile_v1.css"
],
//id of the content that needs to be removed when mobile
DESKTOP_MAIN_ID: "main",
//id of the content that needs to be removed when desktop
MOBILE_MAIN_ID: "main",
//body classes used by desktop that need to be removed when mobile
DESKTOP_BODY_CLASS: [
"page"
],
//body classes used by mobile that need to be removed when desktop
MOBILE_BODY_CLASS: [
"page-mobile"
]
};
|
MobileSliderUtils |
Public Methods
| |
getConfig( String app, String property ) : void
Returns a mobile slider config property. See CONFIG.
Returns a mobile slider config property. See CONFIG.
|
MobileSliderUtils |
| |
injectCss( String url ) : void
Injects a CSS into the DOM.
Injects a CSS into the DOM.
|
MobileSliderUtils |
| |
injectDesktopBodyClass( String app ) : void
Injects desktop classes on the body and removes mobile classes from the body.
Injects desktop classes on the body and removes mobile classes from the body.
|
MobileSliderUtils |
| |
injectDesktopCss( String app ) : void
Injects desktop CSS and removes mobile CSS.
Injects desktop CSS and removes mobile CSS.
|
MobileSliderUtils |
| |
injectMobileBodyClass( String app ) : void
Injects mobile classes on the body and removes desktop classes from the body.
Injects mobile classes on the body and removes desktop classes from the body.
|
MobileSliderUtils |
| |
injectMobileCss( String app ) : void
Injects mobile CSS and removes mobile CSS.
Injects mobile CSS and removes mobile CSS.
|
MobileSliderUtils |
| |
removeCss( String url ) : void
Removes a CSS from the DOM.
Removes a CSS from the DOM.
|
MobileSliderUtils |
| |
switchToDesktop( String app ) : void
Switches the UI to the desktop version: injects desktop CSS/classes and removes mobile CSS/classes.
Switches the UI to the desktop version: injects desktop CSS/classes and removes mobile CSS/classes.
|
MobileSliderUtils |
| |
switchToMobile( String app ) : void
Switches the UI to the mobile version: injects mobile CSS/classes and removes desktop CSS/classes.
Switches the UI to the mobile version: injects mobile CSS/classes and removes desktop CSS/classes.
|
MobileSliderUtils |
Public Events
This class has no public events.