interface WebformElementAssetInterface in Webform 8.5
Same name and namespace in other branches
- 6.x src/Plugin/WebformElementAssetInterface.php \Drupal\webform\Plugin\WebformElementAssetInterface
Defines the interface for webform elements with CSS and JavaScript assets.
Hierarchy
- interface \Drupal\webform\Plugin\WebformElementAssetInterface
Expanded class hierarchy of WebformElementAssetInterface
All classes that implement WebformElementAssetInterface
2 files declare their use of WebformElementAssetInterface
- Webform.php in src/
Entity/ Webform.php - WebformOptionsCustom.php in modules/
webform_options_custom/ src/ Plugin/ WebformElement/ WebformOptionsCustom.php
File
- src/
Plugin/ WebformElementAssetInterface.php, line 8
Namespace
Drupal\webform\PluginView source
interface WebformElementAssetInterface {
/**
* Determine if the element has assets.
*
* @return bool
* TRUE if the element has assets.
*/
public function hasAssets();
/**
* Returns the webform element's asset ID.
*
* This is used to prevent duplicate CSS and JavaScript from being appended
* to a webform.
*
* @return string
* The webform element's asset ID.
*/
public function getAssetId();
/**
* Returns the webform element's CSS.
*
* @return string
* The webform element's CSS.
*/
public function getCss();
/**
* Returns the webform element's JavaScript.
*
* @return string
* The webform element's CSS.
*/
public function getJavaScript();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
WebformElementAssetInterface:: |
public | function | Returns the webform element's asset ID. | 1 |
WebformElementAssetInterface:: |
public | function | Returns the webform element's CSS. | 1 |
WebformElementAssetInterface:: |
public | function | Returns the webform element's JavaScript. | 1 |
WebformElementAssetInterface:: |
public | function | Determine if the element has assets. | 1 |