def METHOD_NAME(self, text: str, level: int, **attrs) -> str:
    ident = slugify(text)
    if level > 1:
        text += self._make_tag(
            "a", {"href": f"#{ident}", "class": "anchor"}, "#"
        )
    return self._make_tag(
        f"h{level}", {"id": ident, "class": f"is-size-{level}"}, text
    )