ThemePicker
Table of Contents
Constants
- BEHAVIOUR_APPLY = 'apply'
- BEHAVIOUR_RETURN = 'return'
- DEFAULT_THEME_ID = 'light:gravity'
- ENTITY_TYPE_SONET_GROUP = 'SONET_GROUP'
- ENTITY_TYPE_USER = 'USER'
- MAX_CUSTOM_THEMES = 40
- MAX_IMAGE_HEIGHT = 5000
- MAX_IMAGE_WIDTH = 5000
- MAX_UPLOAD_SIZE = 20971520
- VALID_BEHAVIOUR_LIST = [self::BEHAVIOUR_APPLY, self::BEHAVIOUR_RETURN]
- VALID_ENTITY_TYPE_LIST = [self::ENTITY_TYPE_USER, self::ENTITY_TYPE_SONET_GROUP]
Methods
- __construct() : mixed
- Theme constructor.
- canSetDefaultTheme() : bool
- create() : mixed
- getAjaxHandlerPath() : mixed
- getBaseThemes() : mixed
- getBehaviour() : mixed
- getContext() : mixed
- getCurrentBaseThemeId() : mixed
- getCurrentSubThemeId() : mixed
- getCurrentTheme() : mixed
- getCurrentThemeId() : mixed
- getCurrentThemeOptionName() : mixed
- getCustomTheme() : mixed
- getCustomThemePrefix() : mixed
- getCustomThemes() : mixed
- getCustomThemesOptionName() : mixed
- getDefaultTheme() : mixed
- getDefaultThemeId() : mixed
- getDefaultThemeOptionName() : mixed
- getEntityId() : mixed
- getEntityType() : string
- getHintOptionName() : mixed
- getInitialDefaultThemeId() : string
- getInstance() : ThemePicker
- getLastThemesOptionName() : mixed
- getList() : mixed
- getPatternThemes() : array<string|int, mixed>
- getSiteId() : mixed
- getStandardTheme() : mixed
- getStandardThemes() : mixed
- getTemplateId() : mixed
- getTemplatePath() : mixed
- getTheme() : mixed
- getThemesPath() : mixed
- getUserId() : mixed
- getZoneId() : mixed
- hideHint() : mixed
- isAdmin() : mixed
- isAvailable() : mixed
- isCustomThemeId() : mixed
- remove() : mixed
- setCurrentThemeId() : bool
- setDefaultTheme() : bool
- setThemeForCurrentPage() : mixed
- shouldShowHint() : mixed
- showBodyAssets() : mixed
- showHeadAssets() : void
Constants
BEHAVIOUR_APPLY
public
mixed
BEHAVIOUR_APPLY
= 'apply'
BEHAVIOUR_RETURN
public
mixed
BEHAVIOUR_RETURN
= 'return'
DEFAULT_THEME_ID
public
mixed
DEFAULT_THEME_ID
= 'light:gravity'
ENTITY_TYPE_SONET_GROUP
public
mixed
ENTITY_TYPE_SONET_GROUP
= 'SONET_GROUP'
ENTITY_TYPE_USER
public
mixed
ENTITY_TYPE_USER
= 'USER'
MAX_CUSTOM_THEMES
public
mixed
MAX_CUSTOM_THEMES
= 40
MAX_IMAGE_HEIGHT
public
mixed
MAX_IMAGE_HEIGHT
= 5000
MAX_IMAGE_WIDTH
public
mixed
MAX_IMAGE_WIDTH
= 5000
MAX_UPLOAD_SIZE
public
mixed
MAX_UPLOAD_SIZE
= 20971520
VALID_BEHAVIOUR_LIST
public
mixed
VALID_BEHAVIOUR_LIST
= [self::BEHAVIOUR_APPLY, self::BEHAVIOUR_RETURN]
VALID_ENTITY_TYPE_LIST
public
mixed
VALID_ENTITY_TYPE_LIST
= [self::ENTITY_TYPE_USER, self::ENTITY_TYPE_SONET_GROUP]
Methods
__construct()
Theme constructor.
public
__construct(string $templateId[, bool $siteId = false ][, mixed $userId = 0 ][, string $entityType = self::ENTITY_TYPE_USER ][, int $entityId = 0 ][, mixed $params = [] ]) : mixed
Parameters
- $templateId : string
- $siteId : bool = false
- $userId : mixed = 0
- $entityType : string = self::ENTITY_TYPE_USER
- $entityId : int = 0
- $params : mixed = []
canSetDefaultTheme()
public
static canSetDefaultTheme() : bool
Return values
boolcreate()
public
create(array<string|int, mixed> $fields) : mixed
Parameters
- $fields : array<string|int, mixed>
getAjaxHandlerPath()
public
getAjaxHandlerPath() : mixed
getBaseThemes()
public
getBaseThemes() : mixed
getBehaviour()
public
getBehaviour() : mixed
getContext()
public
getContext() : mixed
getCurrentBaseThemeId()
public
getCurrentBaseThemeId() : mixed
getCurrentSubThemeId()
public
getCurrentSubThemeId() : mixed
getCurrentTheme()
public
getCurrentTheme() : mixed
getCurrentThemeId()
public
getCurrentThemeId() : mixed
getCurrentThemeOptionName()
public
getCurrentThemeOptionName() : mixed
getCustomTheme()
public
getCustomTheme(mixed $customThemeId[, mixed $userId = false ]) : mixed
Parameters
- $customThemeId : mixed
- $userId : mixed = false
getCustomThemePrefix()
public
getCustomThemePrefix() : mixed
getCustomThemes()
public
getCustomThemes() : mixed
getCustomThemesOptionName()
public
getCustomThemesOptionName() : mixed
getDefaultTheme()
public
getDefaultTheme() : mixed
getDefaultThemeId()
public
getDefaultThemeId() : mixed
getDefaultThemeOptionName()
public
getDefaultThemeOptionName() : mixed
getEntityId()
public
getEntityId() : mixed
getEntityType()
public
getEntityType() : string
Return values
stringgetHintOptionName()
public
getHintOptionName() : mixed
getInitialDefaultThemeId()
public
getInitialDefaultThemeId() : string
Return values
stringgetInstance()
public
static getInstance([string $entityType = self::ENTITY_TYPE_USER ]) : ThemePicker
Parameters
- $entityType : string = self::ENTITY_TYPE_USER
Return values
ThemePickergetLastThemesOptionName()
public
getLastThemesOptionName() : mixed
getList()
public
getList() : mixed
getPatternThemes()
public
getPatternThemes() : array<string|int, mixed>
Return values
array<string|int, mixed>getSiteId()
public
getSiteId() : mixed
getStandardTheme()
public
getStandardTheme(mixed $themeId) : mixed
Parameters
- $themeId : mixed
getStandardThemes()
public
getStandardThemes() : mixed
getTemplateId()
public
getTemplateId() : mixed
getTemplatePath()
public
getTemplatePath() : mixed
getTheme()
public
getTheme(mixed $themeId[, mixed $userId = false ]) : mixed
Parameters
- $themeId : mixed
- $userId : mixed = false
getThemesPath()
public
getThemesPath() : mixed
getUserId()
public
getUserId() : mixed
getZoneId()
public
getZoneId() : mixed
hideHint()
public
hideHint() : mixed
isAdmin()
public
static isAdmin() : mixed
isAvailable()
public
static isAvailable() : mixed
isCustomThemeId()
public
isCustomThemeId(mixed $themeId) : mixed
Parameters
- $themeId : mixed
remove()
public
remove(mixed $themeId) : mixed
Parameters
- $themeId : mixed
setCurrentThemeId()
public
setCurrentThemeId(mixed $themeId[, mixed $currentUserId = 0 ]) : bool
Parameters
- $themeId : mixed
- $currentUserId : mixed = 0
Return values
boolsetDefaultTheme()
public
setDefaultTheme(mixed $themeId[, mixed $currentUserId = 0 ]) : bool
Parameters
- $themeId : mixed
- $currentUserId : mixed = 0
Return values
boolsetThemeForCurrentPage()
public
setThemeForCurrentPage(mixed $themeId) : mixed
Parameters
- $themeId : mixed
shouldShowHint()
public
shouldShowHint() : mixed
showBodyAssets()
public
showBodyAssets() : mixed
showHeadAssets()
public
showHeadAssets() : void