class SmartmenusUtil in Smartmenus.js 8
Class SmartmenusUtil @package Drupal\smartmenus
Hierarchy
- class \Drupal\smartmenus\SmartmenusUtil
Expanded class hierarchy of SmartmenusUtil
2 files declare their use of SmartmenusUtil
- SmartMenusBlock.php in src/
Plugin/ Block/ SmartMenusBlock.php - SmartmenusSettingsForm.php in src/
Form/ SmartmenusSettingsForm.php
1 string reference to 'SmartmenusUtil'
1 service uses SmartmenusUtil
File
- src/
SmartmenusUtil.php, line 11
Namespace
Drupal\smartmenusView source
class SmartmenusUtil {
/**
* @var TranslationManager
*/
protected $translation;
/**
* SmartmenusUtil constructor.
* @param TranslationManager $translation
*/
public function __construct(TranslationManager $translation) {
$this->translation = $translation;
}
/**
* @return array|string
* Returns a list of themes supported by the Smartmenus plugin.
*/
public function getAvailableMenuThemesList() : array {
return [
'' => $this->translation
->translate('None'),
'sm-blue' => $this->translation
->translate('Blue'),
'sm-clean' => $this->translation
->translate('Clean'),
'sm-mint' => $this->translation
->translate('Mint'),
'sm-simple' => $this->translation
->translate('Simple'),
];
}
/**
* @return string
*/
public function getConfigFormSettingsName() : string {
return 'smartmenus.smartmenussettings';
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
SmartmenusUtil:: |
protected | property | ||
SmartmenusUtil:: |
public | function | ||
SmartmenusUtil:: |
public | function | ||
SmartmenusUtil:: |
public | function | SmartmenusUtil constructor. |