public function WebformAnnounceCommand::render in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Ajax/WebformAnnounceCommand.php \Drupal\webform\Ajax\WebformAnnounceCommand::render()
Return an array to be run through json_encode and sent to the client.
Overrides CommandInterface::render
File
- src/
Ajax/ WebformAnnounceCommand.php, line 47
Class
- WebformAnnounceCommand
- Provides an Ajax command to trigger audio UAs to read the supplied text.
Namespace
Drupal\webform\AjaxCode
public function render() {
return [
'command' => 'webformAnnounce',
'text' => $this->text,
'priority' => $this->priority,
];
}