breadcrumb

package
v0.0.0-...-8815ff5 Latest Latest
Warning

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

Go to latest
Published: Jan 31, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

templ: version: v0.3.960

templ: version: v0.3.960

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Breadcrumb(args BreadcrumbArgs) templ.Component

Breadcrumb renders the main navigation wrapper

func BreadcrumbEllipsis(args BreadcrumbEllipsisArgs) templ.Component

BreadcrumbEllipsis renders an ellipsis indicator for collapsed breadcrumbs

func BreadcrumbItem(args BreadcrumbItemArgs) templ.Component

BreadcrumbItem renders a list item wrapper for breadcrumb content

func BreadcrumbLink(args BreadcrumbLinkArgs) templ.Component

BreadcrumbLink renders a clickable breadcrumb link

func BreadcrumbList(args BreadcrumbListArgs) templ.Component

BreadcrumbList renders the ordered list container for breadcrumb items

func BreadcrumbPage(args BreadcrumbPageArgs) templ.Component

BreadcrumbPage renders the current page indicator (non-clickable)

func BreadcrumbSeparator(args BreadcrumbSeparatorArgs) templ.Component

BreadcrumbSeparator renders the separator between breadcrumb items

func FromItems

func FromItems(items []BreadcrumbItemData) templ.Component

FromItems creates a breadcrumb navigation from a slice of items This is a higher-level helper that handles the manual construction of breadcrumbs

Types

type BreadcrumbArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes
}

BreadcrumbArgs defines the properties for the Breadcrumb nav component

type BreadcrumbEllipsisArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes
}

BreadcrumbEllipsisArgs defines the properties for the BreadcrumbEllipsis span component

type BreadcrumbItemArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes
}

BreadcrumbItemArgs defines the properties for the BreadcrumbItem li component

type BreadcrumbItemData struct {
	Label string
	Href  string // Empty string means this is the current page (uses BreadcrumbPage instead of BreadcrumbLink)
}

BreadcrumbItemData represents a single breadcrumb item

type BreadcrumbLinkArgs struct {
	// AsChild renders the link as a child element (for composition)
	AsChild bool

	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes

	// Href specifies the URL for the link
	Href string
}

BreadcrumbLinkArgs defines the properties for the BreadcrumbLink a component

type BreadcrumbListArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes
}

BreadcrumbListArgs defines the properties for the BreadcrumbList ol component

type BreadcrumbPageArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes
}

BreadcrumbPageArgs defines the properties for the BreadcrumbPage span component

type BreadcrumbSeparatorArgs struct {
	// Class allows additional CSS classes to be added
	Class string

	// Attributes allows additional HTML attributes to be added
	Attributes templ.Attributes

	// CustomIcon allows overriding the default ChevronRight icon
	CustomIcon bool
}

BreadcrumbSeparatorArgs defines the properties for the BreadcrumbSeparator li component

Jump to

Keyboard shortcuts

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