MCPcopy
hub / github.com/Textualize/rich / create

Method create

rich/markdown.py:416–418  ·  view source on GitHub ↗
(cls, markdown: Markdown, token: Token)

Source from the content-addressed store, hash-verified

414class 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)

Callers 1

__rich_console__Method · 0.45

Calls 1

getMethod · 0.45

Tested by

no test coverage detected