(cls, markdown: Markdown, token: Token)
| 414 | class Link(TextElement): |
| 415 | @classmethod |
| 416 | def create(cls, markdown: Markdown, token: Token) -> MarkdownElement: |
| 417 | url = token.attrs.get("href", "#") |
| 418 | return cls(token.content, str(url)) |
| 419 | |
| 420 | def __init__(self, text: str, href: str): |
| 421 | self.text = Text(text) |