Documentation ¶
Overview ¶
Package component contains individual components that can render themselves as HTML.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var RedLogo bool
RedLogo controls whether the logo is displayed in red, rather than its normal color.
Functions ¶
func RepositoryTabNav ¶
Types ¶
type BlankSlate ¶
BlankSlate is a blank slate.
func (BlankSlate) Render ¶
func (bs BlankSlate) Render() []*html.Node
type EllipsisButton ¶
type EllipsisButton struct { // OnClick is the value that the onclick handler gets set to. OnClick string }
EllipsisButton is a button with a horizontal ellipsis. It can be used to expand/collapse additional details.
func (EllipsisButton) Render ¶
func (b EllipsisButton) Render() []*html.Node
type Header ¶
type Header struct { CurrentUser users.User NotificationCount uint64 // Only needed if CurrentUser.ID != 0. ReturnURL string }
Header is a header component that displays current user and notifications.
type Notifications ¶
type Notifications struct { // Count is the number of unread notifications the user has. Count uint64 }
Notifications is an icon for displaying if user has unread notifications. It links to "/notifications".
func (Notifications) Render ¶
func (n Notifications) Render() []*html.Node
Render implements htmlg.Component.
type PostButton ¶
PostButton is a button that performs a POST action.
func (PostButton) Render ¶
func (b PostButton) Render() []*html.Node
type RepositoryTab ¶
type RepositoryTab uint8
const ( NoTab RepositoryTab = iota PackagesTab HistoryTab IssuesTab ChangesTab )
Click to show internal directories.
Click to hide internal directories.