contentcard

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2026 License: MIT Imports: 5 Imported by: 0

README

ContentCard

Container with header, body, and footer sections.

Import

"github.com/tinywasm/components/contentcard"

Usage

import (
    "github.com/tinywasm/components/contentcard"
    . "github.com/tinywasm/html"
)

c := &contentcard.ContentCard{
    Header: H3("Card Title"),
    Body:   P("Content goes here..."),
    Footer: Small("Last updated: today"),
}

Properties

  • Header (dom.Component): Content for header section.
  • Body (dom.Component): Main content.
  • Footer (dom.Component): Footer content.

Back to Catalog

Documentation

Index

Constants

View Source
const (
	PartHeader = widget.Part("header")
	PartBody   = widget.Part("body")
	PartFooter = widget.Part("footer")
)
View Source
const NameContentCard = widget.Name("contentcard")

NameContentCard is the widget name.

Variables

This section is empty.

Functions

This section is empty.

Types

type ContentCard

type ContentCard struct {
	Element
	Header Component
	Body   Component
	Footer Component
}

func (*ContentCard) Render

func (c *ContentCard) Render() *Element

func (*ContentCard) RenderCSS

func (c *ContentCard) RenderCSS() *css.Stylesheet

RenderCSS defines the visual sheet for contentcard.

func (*ContentCard) WidgetKind added in v0.1.13

func (c *ContentCard) WidgetKind() widget.Kind

func (*ContentCard) WidgetName added in v0.1.13

func (c *ContentCard) WidgetName() widget.Name

Jump to

Keyboard shortcuts

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