def visit_title(self, node: Element) -> None:
    if (not self.seen_title):
        self.seen_title = True
        raise nodes.SkipNode
    parent = node.parent
    if isinstance(parent, nodes.table):
        return
    if isinstance(parent, (nodes.Admonition, nodes.sidebar, nodes.topic)):
        raise nodes.SkipNode
    elif (not isinstance(parent, nodes.section)):
        logger.warning(__('encountered title node not in section, topic, table, admonition or sidebar'), location=node)
        self.visit_rubric(node)
    else:
        try:
            heading = self.headings[self.section_level]
        except IndexError:
            heading = self.headings[(- 1)]
        self.body.append(('\n%s ' % heading))
def visit_title(self, node: Element) -> None:
    if (not self.seen_title):
        self.seen_title = True
        raise nodes.SkipNode
    parent = node.parent
    if isinstance(parent, nodes.table):
        return
    if isinstance(parent, (nodes.Admonition, nodes.sidebar, nodes.topic)):
        raise nodes.SkipNode
    elif (not isinstance(parent, nodes.section)):
        logger.warning(__('encountered title node not in section, topic, table, admonition or sidebar'), location=node)
        self.visit_rubric(node)
    else:
        try:
            heading = self.headings[self.section_level]
        except IndexError:
            heading = self.headings[(- 1)]
        self.body.append(('\n%s ' % heading))