Check is block of HTML is block-level.
(self, html: str)
| 93 | return text |
| 94 | |
| 95 | def isblocklevel(self, html: str) -> bool: |
| 96 | """ Check is block of HTML is block-level. """ |
| 97 | m = self.BLOCK_LEVEL_REGEX.match(html) |
| 98 | if m: |
| 99 | if m.group(1)[0] in ('!', '?', '@', '%'): |
| 100 | # Comment, PHP etc... |
| 101 | return True |
| 102 | return self.md.is_block_level(m.group(1)) |
| 103 | return False |
| 104 | |
| 105 | def stash_to_string(self, text: str) -> str: |
| 106 | """ Convert a stashed object to a string. """ |
no test coverage detected