markdownx

package
v0.0.0-...-b5fadd1 Latest Latest
Warning

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

Go to latest
Published: Oct 31, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var FullMatchHtmlTagClassMap = map[string]string{
	"p":   "my-2 mx-2",
	"ol":  "pl-1 list-decimal list-inside",
	"ul":  "pl-4 list-disc",
	"li":  "ml-4 my-2",
	"pre": "my-4",

	"code": "bg-gray-100 text-orange-600",

	"blockquote": "mt-2 pl-2 py-1 border-l-8 border-green-200 bg-green-100",

	"table": "table-auto border-collapse border border-gray-500",
	"tr":    "odd:bg-white even:bg-gray-100",
	"th":    "border border-gray-500 px-4 py-2",
	"td":    "border border-gray-500 px-4 py-2",
}
View Source
var PrefixMatchHtmlTagClassMap = map[string]string{
	"h1":  "mt-6 mb-4 font-semibold text-3xl",
	"h2":  "mt-6 mb-4 font-semibold text-2xl",
	"h3":  "mt-6 mb-4 font-semibold text-xl",
	"h4":  "mt-6 mb-4 font-semibold text-lg",
	"h5":  "mt-6 mb-4 font-semibold text-base",
	"h6":  "mt-6 mb-4 font-semibold text-base text-gray-600",
	"img": "my-6",
	"a":   "text-blue-500",
}

Functions

func ToHTML

func ToHTML(content []byte) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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