locker-factory
Version:
Content Locker UI Builder
53 lines (45 loc) • 1.44 kB
JavaScript
var Constants = require( './constants/Constants' );
var LockerUtil = {
/* Constants and Stylesheet GETTERS */
getBaseStylesheetUrl: function() {
return Constants.stylesheet.BASE;
},
getContentLockerStylesheetUrl: function() {
return Constants.stylesheet.CONTENT_LOCKER;
},
getOfferWallStylesheetUrl: function() {
return Constants.stylesheet.OFFER_WALL;
},
getTypeStylesheetUrl: function( type ) {
var result = '';
switch( type ) {
case Constants.type.CONTENT_LOCKER:
result = Constants.stylesheet.CONTENT_LOCKER;
break;
case Constants.type.OFFER_WALL:
result = Constants.stylesheet.OFFER_WALL;
break;
default:
// do nothing
}
return result;
},
getLayoutStylesheetUrl: function( layout ) {
var result = '';
switch( layout ) {
case Constants.layout.LIST:
result = Constants.stylesheet.LIST;
break;
case Constants.layout.GRID:
result = Constants.stylesheet.GRID;
break;
case Constants.layout.BILLBOARD:
result = Constants.stylesheet.BILLBOARD;
break;
default:
// do nothing
}
return result;
}
};
module.exports = LockerUtil;