Add link
This commit is contained in:
@@ -154,24 +154,26 @@ func pprint*(x: OrgDocument, indent = 0): string =
|
||||
fields,
|
||||
)
|
||||
|
||||
|
||||
## OrgDocument.PrettyPrinters
|
||||
|
||||
func `$`*(xs: OrgDocument): string = pprint(xs)
|
||||
|
||||
when isMainModule:
|
||||
echo OrgDocument(
|
||||
let doc = OrgDocument(
|
||||
children: @[
|
||||
OrgBlock(
|
||||
kind: orgHeading,
|
||||
children: @[
|
||||
OrgInlineBlock(
|
||||
kind: orgLink,
|
||||
linkUrl: "Foo",
|
||||
linkDescription: "Bar".just(),
|
||||
linkUrl: "https://placeholder.com",
|
||||
linkDescription: "Placeholder".just(),
|
||||
),
|
||||
],
|
||||
),
|
||||
OrgBlock(kind: orgHeading),
|
||||
OrgBlock(kind: orgHeading, level: 1),
|
||||
OrgBlock(kind: orgHeading),
|
||||
]
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user