diff --git a/ast/inline.go b/ast/inline.go index 7e4c51f..02711de 100644 --- a/ast/inline.go +++ b/ast/inline.go @@ -503,6 +503,11 @@ func (n *AutoLink) Label(source []byte) []byte { return n.value.Text(source) } +// LabelSegment returns a source position of label text in a source text. +func (n *AutoLink) LabelSegment() textm.Segment { + return n.value.Segment +} + // NewAutoLink returns a new AutoLink node. func NewAutoLink(typ AutoLinkType, value *Text) *AutoLink { return &AutoLink{