bootstrap

package module
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2022 License: MIT Imports: 5 Imported by: 0

README

Bootstrap Components

Build Status Go Report Card Docs License

This is a library to generate various Bootstrap examples boilerplate for Quicktemplate:

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NavbarHtml(navData Navbar) string

func StreamNavbarHtml

func StreamNavbarHtml(qw422016 *qt422016.Writer, navData Navbar)

func StreamWebpageHTML added in v0.3.0

func StreamWebpageHTML(qw422016 *qt422016.Writer, pageData Webpage)

func WebpageHTML added in v0.3.0

func WebpageHTML(pageData Webpage) string

func WriteNavbarHtml

func WriteNavbarHtml(qq422016 qtio422016.Writer, navData Navbar)

func WriteWebpageHTML added in v0.3.0

func WriteWebpageHTML(qq422016 qtio422016.Writer, pageData Webpage)

Types

type AlbumCell

type AlbumCell struct {
	ImageSrc string
	Text     string
	Button1  string
	Button2  string
	Footnote string
}

type Alert

type Alert int
const (
	Primary Alert = iota
	Secondary
	Success
	Danger
	Warning
	Info
	Light
	Dark
)

func NewAlert

func NewAlert(idx int) Alert

func (Alert) Class

func (a Alert) Class() string

Class returns the class name of the alert ("Primary", "Secondary", ...).

func (Alert) String

func (a Alert) String() string

Class returns the class name of the alert ("Primary", "Secondary", ...).

type AlertColored

type AlertColored int
const (
	PrimaryC AlertColored = iota
	SecondaryC
	SuccessC
	DangerC
	WarningC
	InfoC
)

func NewAlertColored

func NewAlertColored(idx int) AlertColored

func (AlertColored) Class

func (a AlertColored) Class() string

Class returns the class name of the alert ("Primary", "Secondary", ...).

func (AlertColored) DivHTML added in v0.3.0

func (a AlertColored) DivHTML(innerHTML string) string

Class returns the class name of the alert ("Primary", "Secondary", ...).

func (AlertColored) String

func (a AlertColored) String() string

Class returns the class name of the alert ("Primary", "Secondary", ...).

type Link struct {
	Href      string
	InnerHTML string
	Current   bool
	SubLinks  []Link
}
type Navbar struct {
	Title     Link
	MenuLinks []Link
	Search    Search
}
type Search struct {
	Action      string
	Method      string
	Onclick     string
	Placeholder string
	Text        string
}

type Webpage

type Webpage struct {
	Title    string
	Navbar   Navbar
	MainHTML string
}

func (*Webpage) FooterString

func (pg *Webpage) FooterString() string

func (*Webpage) MainString

func (pg *Webpage) MainString() string

func (*Webpage) NavbarString

func (pg *Webpage) NavbarString() string

Directories

Path Synopsis
nav

Jump to

Keyboard shortcuts

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