`\s]+|"[^"]*+"|\'[^\']*+\'))?+'; /** @var array{2: string, 3: string, 4: string, 5: string} */ private static $simpleContainsEndConditions = [ 2 => '-->', 3 => '?>', 4 => '>', 5 => ']]>' ]; /** @var array */ private static $specialHtmlBlockTags = [ 'script' => true, 'style' => true, 'pre' => true, ]; /** @var string */ private $html; /** @var 1|2|3|4|5|6|7 */ private $type; /** @var bool */ private $closed; /** * @param string $html * @param 1|2|3|4|5|6|7 $type * @param bool $closed */ private function __construct($html, $type, $closed = false) { $this->html = $html; $this->type = $type; $this->closed = $closed; } /** * @param Context $Context * @param Block|null $Block * @param State|null $State * @return static|null */ public static function build( Context $Context, Block $Block = null, State $State = null ) { $text = $Context->line()->text(); $rawLine = $Context->line()->rawLine(); if (\preg_match('/^<(?:script|pre|style)(?:\s++|>|$)/i', $text)) { return new self($rawLine, 1, self::closes12345TypeMarkup(1, $text)); } if (\substr($text, 0, 4) === '