src/Tokens/Elements/Dfn.php 1 location
|
@@ 29-39 (lines=11) @@
|
26 |
|
} |
27 |
|
} |
28 |
|
|
29 |
|
protected function removeInvalidSelf(LoggerInterface $logger) |
30 |
|
{ |
31 |
|
$dfn = new self($this->configuration); |
32 |
|
if ($this->hasAncestor($dfn)) { |
33 |
|
$logger->debug('Removing ' . $child . '. Element "dfn" cannot contain "dfn" elements.'); |
34 |
|
|
35 |
|
return true; |
36 |
|
} |
37 |
|
|
38 |
|
return false; |
39 |
|
} |
40 |
|
} |
41 |
|
|
src/Tokens/Elements/Form.php 1 location
|
@@ 36-46 (lines=11) @@
|
33 |
|
); |
34 |
|
} |
35 |
|
|
36 |
|
protected function removeInvalidSelf(LoggerInterface $logger) |
37 |
|
{ |
38 |
|
$form = new self($this->configuration, 'form'); |
39 |
|
if ($this->hasAncestor($form)) { |
40 |
|
$logger->debug('Removing ' . $this . '. Cannot be have a "form" element ancestor.'); |
41 |
|
|
42 |
|
return true; |
43 |
|
} |
44 |
|
|
45 |
|
return false; |
46 |
|
} |
47 |
|
} |
48 |
|
|
src/Tokens/Elements/Hgroup.php 1 location
|
@@ 43-55 (lines=13) @@
|
40 |
|
} |
41 |
|
} |
42 |
|
|
43 |
|
protected function removeInvalidSelf(LoggerInterface $logger) |
44 |
|
{ |
45 |
|
foreach ($this->children as $child) { |
46 |
|
if ($child instanceof HeadingContent) { |
47 |
|
return false; |
48 |
|
} |
49 |
|
} |
50 |
|
|
51 |
|
// Handle no child HeadingContent. |
52 |
|
$logger->debug('Removing ' . $this . '. Must contain at least one of the following elements: "h1", "h2", "h3", "h4", "h5", "h6", or "template".'); |
53 |
|
|
54 |
|
return true; |
55 |
|
} |
56 |
|
} |
57 |
|
|
src/Tokens/Elements/Label.php 1 location
|
@@ 32-42 (lines=11) @@
|
29 |
|
); |
30 |
|
} |
31 |
|
|
32 |
|
protected function removeInvalidSelf(LoggerInterface $logger) |
33 |
|
{ |
34 |
|
$label = new self($this->configuration, 'label'); |
35 |
|
if ($this->hasAncestor($label)) { |
36 |
|
$logger->debug('Removing ' . $this . '. Cannot be have "label" element ancestor.'); |
37 |
|
|
38 |
|
return true; |
39 |
|
} |
40 |
|
|
41 |
|
return false; |
42 |
|
} |
43 |
|
|
44 |
|
public function isInteractiveContent() |
45 |
|
{ |
src/Tokens/Elements/Meter.php 1 location
|
@@ 34-44 (lines=11) @@
|
31 |
|
); |
32 |
|
} |
33 |
|
|
34 |
|
protected function removeInvalidSelf(LoggerInterface $logger) |
35 |
|
{ |
36 |
|
$meter = new self($this->configuration, 'meter'); |
37 |
|
if ($this->hasAncestor($meter)) { |
38 |
|
$logger->debug('Removing ' . $this . '. "Meter" element cannot contain other "meter" elements.'); |
39 |
|
|
40 |
|
return true; |
41 |
|
} |
42 |
|
|
43 |
|
return false; |
44 |
|
} |
45 |
|
} |
46 |
|
|