renderhelper

package
v0.0.0-...-e61ee7f Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewRenderContextRepoComment

func NewRenderContextRepoComment(ctx context.Context, repo *repo_model.Repository, opts ...RepoCommentOptions) *markup.RenderContext

func NewRenderContextRepoFile

func NewRenderContextRepoFile(ctx context.Context, repo *repo_model.Repository, opts ...RepoFileOptions) *markup.RenderContext

func NewRenderContextRepoWiki

func NewRenderContextRepoWiki(ctx context.Context, repo *repo_model.Repository, opts ...RepoWikiOptions) *markup.RenderContext

func NewRenderContextSimpleDocument

func NewRenderContextSimpleDocument(ctx context.Context, baseLink string) *markup.RenderContext

Types

type RepoComment

type RepoComment struct {
	// contains filtered or unexported fields
}

func (*RepoComment) CleanUp

func (r *RepoComment) CleanUp()

func (*RepoComment) IsCommitIDExisting

func (r *RepoComment) IsCommitIDExisting(commitID string) bool
func (r *RepoComment) ResolveLink(link string, likeType markup.LinkType) (finalLink string)

type RepoCommentOptions

type RepoCommentOptions struct {
	DeprecatedRepoName  string // it is only a patch for the non-standard "markup" api
	DeprecatedOwnerName string // it is only a patch for the non-standard "markup" api
	CurrentRefPath      string // eg: "branch/main" or "commit/11223344"
}

type RepoFile

type RepoFile struct {
	// contains filtered or unexported fields
}

func (*RepoFile) CleanUp

func (r *RepoFile) CleanUp()

func (*RepoFile) IsCommitIDExisting

func (r *RepoFile) IsCommitIDExisting(commitID string) bool
func (r *RepoFile) ResolveLink(link string, likeType markup.LinkType) string

type RepoFileOptions

type RepoFileOptions struct {
	DeprecatedRepoName  string // it is only a patch for the non-standard "markup" api
	DeprecatedOwnerName string // it is only a patch for the non-standard "markup" api

	CurrentRefPath  string // eg: "branch/main"
	CurrentTreePath string // eg: "path/to/file" in the repo
}

type RepoWiki

type RepoWiki struct {
	// contains filtered or unexported fields
}

func (*RepoWiki) CleanUp

func (r *RepoWiki) CleanUp()

func (*RepoWiki) IsCommitIDExisting

func (r *RepoWiki) IsCommitIDExisting(commitID string) bool
func (r *RepoWiki) ResolveLink(link string, likeType markup.LinkType) string

type RepoWikiOptions

type RepoWikiOptions struct {
	DeprecatedRepoName  string // it is only a patch for the non-standard "markup" api
	DeprecatedOwnerName string // it is only a patch for the non-standard "markup" api
	// contains filtered or unexported fields
}

type SimpleDocument

type SimpleDocument struct {
	*markup.SimpleRenderHelper
	// contains filtered or unexported fields
}
func (r *SimpleDocument) ResolveLink(link string, likeType markup.LinkType) string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL