public function ScrollToElementCommand::__construct in Paragraphs Features 2.x
Same name and namespace in other branches
- 8 src/Ajax/ScrollToElementCommand.php \Drupal\paragraphs_features\Ajax\ScrollToElementCommand::__construct()
Constructs a ScrollToElementCommand object.
Parameters
string $elementSelector: The data-drupal-selector for the paragraphs element.
string $parentSelector: The data-drupal-selector for the paragraphs field.
File
- src/
Ajax/ ScrollToElementCommand.php, line 36
Class
- ScrollToElementCommand
- Provides an AJAX command for scrolling an element into the view.
Namespace
Drupal\paragraphs_features\AjaxCode
public function __construct(string $elementSelector, string $parentSelector) {
$this->elementSelector = $elementSelector;
$this->parentSelector = $parentSelector;
}