docs: def _is_replacement_allowed(self, s):
          """Tests whether replacement is allowed on given piece of HTML text."""
          if any(tag in s.parent_tags for tag in self.skipped_tags):
              return False
          if any(tag not in self.textflow_tags for tag in s.involved_tags):
              return False
          return True