Rename hstring.RenderedHTML => hstring.HTML

And add a comment about why it exists.
This commit is contained in:
Bjørn Erik Pedersen
2024-09-01 10:03:10 +02:00
parent 96afea4acc
commit 469124823c
7 changed files with 27 additions and 25 deletions

View File

@@ -41,7 +41,7 @@ type LinkContext interface {
Title() string
// The rendered (HTML) text.
Text() hstring.RenderedHTML
Text() hstring.HTML
// The plain variant of Text.
PlainText() string
@@ -100,7 +100,7 @@ type BlockquoteContext interface {
// The blockquote text.
// If type is "alert", this will be the alert text.
Text() hstring.RenderedHTML
Text() hstring.HTML
/// Returns the blockquote type, one of "regular" and "alert".
// Type "alert" indicates that this is a GitHub type alert.
@@ -166,7 +166,7 @@ type HeadingContext interface {
// Anchor is the HTML id assigned to the heading.
Anchor() string
// Text is the rendered (HTML) heading text, excluding the heading marker.
Text() hstring.RenderedHTML
Text() hstring.HTML
// PlainText is the unrendered version of Text.
PlainText() string
@@ -213,7 +213,7 @@ const (
type GetRendererFunc func(t RendererType, id any) any
type TableCell struct {
Text hstring.RenderedHTML
Text hstring.HTML
Alignment string // left, center, or right
}