for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/**
* @author Sergii Bondarenko, <[email protected]>
*/
namespace Drupal\TqExtension\Utils\Wysiwyg;
// Contexts.
use Drupal\TqExtension\Context\RawTqContext;
class TinyMCE extends Wysiwyg
{
public function __construct(RawTqContext $context)
$this->setContext($context);
$this->setObject("tinyMCE.get('%s')");
}
* {@inheritdoc}
public function fill($text, $selector = '')
$this->execute('setContent', $selector, [$text]);
public function type($text, $selector = '')
// Unfortunately, TinyMCE cannot type to an editor.
$this->fill($text, $selector);
public function read($selector = '')
return $this->execute('getContent', $selector);