Skip to content

Components Reference

Complete reference of all Wireweave components with examples.

Layout

Components that define page structure.

page

Page root container. The starting point for all layouts.

wireframe
page "Dashboard" centered {
  // content
}
AttributeTypeDescription
titlestringPage title
viewportstringViewport size (e.g., "1440x900")
devicestringDevice preset (iphone14, desktop, etc.)
centeredbooleanCenter content
p, px, pynumberPadding
gapnumberGap between children

Page header area. Place navigation, logo, etc.

wireframe
header border {
  row justify=between {
    title "Logo" level=3
    nav { }
  }
}
AttributeTypeDescription
borderbooleanBottom border
p, px, pynumberPadding
gapnumberGap between children
justifystringMain axis alignment
alignstringCross axis alignment

main

Main content area.

wireframe
main {
  // main content
}

Page footer area.

wireframe
footer border {
  text "Copyright 2026" muted
}

Sidebar area.

wireframe
sidebar position=left w=240 {
  nav vertical { }
}
AttributeTypeDescription
positionleft | rightSidebar position
wnumberWidth

section

Section area. Groups content logically.

wireframe
section title="Settings" expanded {
  // content
}
AttributeTypeDescription
titlestringSection title
expandedbooleanExpanded state

Grid

Components for flex layout.

row

Horizontal flex container.

wireframe
row gap=4 justify=between align=center {
  button "Cancel" secondary
  button "Submit" primary
}
AttributeTypeDescription
gapnumberGap between children
justifystart | center | end | between | around | evenlyMain axis alignment
alignstart | center | end | stretch | baselineCross axis alignment
wrapbooleanAllow wrapping

col

Vertical flex container or grid column.

wireframe
row {
  col span=6 { }
  col span=6 { }
}
AttributeTypeDescription
span1-12Grid column width
sm, md, lg, xlnumberResponsive column width
ordernumberFlex order

Container

Components for grouping content.

card

Card component. Groups and displays content.

wireframe
card title="Settings" shadow=md border {
  // content
}
AttributeTypeDescription
titlestringCard title
shadownone | sm | md | lg | xlShadow size
borderbooleanShow border
pnumberPadding

Modal dialog. Displays content over an overlay.

wireframe
modal "Confirm Delete" {
  text "Are you sure?"
  row justify=end gap=2 {
    button "Cancel" secondary
    button "Delete" danger
  }
}
AttributeTypeDescription
titlestringModal title
w, hnumberWidth, height

drawer

Drawer panel. Slides in from the edge of the screen.

wireframe
drawer "Menu" position=left {
  nav vertical { }
}
AttributeTypeDescription
titlestringDrawer title
positionleft | right | top | bottomPosition

accordion

Accordion. Collapsible content panel.

wireframe
accordion "Advanced Settings" {
  // content
}

Text

Components for displaying text.

text

Displays regular text.

wireframe
text "Regular text"
text "Muted description" muted
text "Important" weight=bold size=lg
AttributeTypeDescription
sizexs | sm | base | md | lg | xl | 2xlText size
weightnormal | medium | semibold | boldFont weight
alignleft | center | rightText alignment
mutedbooleanMuted style

title

Title element. Displays h1~h6 headings.

wireframe
title "Main Title" level=1
title "Subtitle" level=2
title "Section" level=3
AttributeTypeDescription
level1-6Heading level
sizestringText size
alignstringText alignment

Displays a clickable hyperlink.

wireframe
link "Learn more" href="/docs"
link "GitHub" href="https://github.com" external
AttributeTypeDescription
hrefstringLink URL
externalbooleanExternal link (new tab)

Input

Components for user input.

input

Input field. Accepts text, email, password, etc.

wireframe
input "Email" type=email placeholder="Enter email"
input "Password" type=password
input "Name" required disabled
AttributeTypeDescription
labelstringLabel text
typetext | email | password | number | tel | url | search | dateInput type
placeholderstringPlaceholder text
valuestringDefault value
disabledbooleanDisabled state
requiredbooleanRequired field
readonlybooleanRead-only
iconstringIcon

textarea

Multi-line input field.

wireframe
textarea "Message" placeholder="Enter your message" rows=4
AttributeTypeDescription
labelstringLabel text
placeholderstringPlaceholder text
rowsnumberNumber of rows
disabledbooleanDisabled state

select

Dropdown select.

wireframe
select "Country" placeholder="Select country"
AttributeTypeDescription
labelstringLabel text
placeholderstringPlaceholder text
disabledbooleanDisabled state

checkbox

Checkbox. Selects true/false value.

wireframe
checkbox "Remember me"
checkbox "I agree to terms" checked
AttributeTypeDescription
labelstringLabel text
checkedbooleanChecked state
disabledbooleanDisabled state

radio

Radio button. Selects one option within a group.

wireframe
radio "Option A" name="options"
radio "Option B" name="options" checked
AttributeTypeDescription
labelstringLabel text
namestringGroup name
checkedbooleanSelected state
disabledbooleanDisabled state

switch

Toggle switch. Toggles on/off state.

wireframe
switch "Dark mode"
switch "Notifications" checked
AttributeTypeDescription
labelstringLabel text
checkedbooleanActive state
disabledbooleanDisabled state

slider

Slider. Selects a value within a range.

wireframe
slider "Volume" min=0 max=100 value=50
AttributeTypeDescription
labelstringLabel text
minnumberMinimum value
maxnumberMaximum value
valuenumberCurrent value
stepnumberStep increment
disabledbooleanDisabled state

button

Button element. Displays a clickable button.

wireframe
button "Submit" primary
button "Cancel" secondary
button "Delete" danger outline
button "Loading..." primary loading
AttributeTypeDescription
primarybooleanPrimary emphasis style
secondarybooleanSecondary style
outlinebooleanOutline style
ghostbooleanGhost/transparent style
dangerbooleanDanger/delete style
sizexs | sm | md | lg | xlButton size
iconstringIcon
disabledbooleanDisabled state
loadingbooleanLoading state

Display

Components for displaying visual elements.

image

Displays an image.

wireframe
image src="/photo.jpg" alt="Photo" w=200 h=150
AttributeTypeDescription
srcstringImage source URL
altstringAlt text
wnumberWidth
hnumberHeight

placeholder

Placeholder for images or content.

wireframe
placeholder "Image" w=300 h=200
AttributeTypeDescription
labelstringLabel text
wnumberWidth
hnumberHeight

avatar

Displays a user profile image.

wireframe
avatar "John Doe"
avatar "JD" size=lg src
AttributeTypeDescription
namestringName (generates initials)
srcbooleanShow image
sizexs | sm | md | lg | xl | numberSize

badge

Displays status or count as a small label.

wireframe
badge "New"
badge "Active" variant=success
badge "3" variant=danger pill
AttributeTypeDescription
variantdefault | primary | secondary | success | warning | danger | infoStyle variant
pillbooleanRounded corners
iconstringIcon
sizexs | sm | md | lgSize

icon

Displays an icon.

wireframe
icon "home"
icon "settings" size=lg muted
AttributeTypeDescription
namestringIcon name
sizexs | sm | md | lg | xl | numberSize
mutedbooleanMuted style

divider

Divider element. Visually separates content.

wireframe
divider
divider my=4
AttributeTypeDescription
m, my, mxnumberMargin

Data

Components for displaying data.

table

Table component. Displays data in tabular format.

wireframe
table striped hover bordered {
  // columns and rows
}
AttributeTypeDescription
stripedbooleanStriped rows
borderedbooleanBordered style
hoverbooleanHover effect

list

List component. Displays items as a list.

wireframe
list {
  // items
}

list ordered {
  // numbered items
}
AttributeTypeDescription
orderedbooleanOrdered list
nonebooleanNo list style
gapnumberItem gap

Feedback

Components for providing feedback to users.

alert

Alert element. Displays a message to users.

wireframe
alert "Operation successful" variant=success
alert "Please check your input" variant=warning
alert "An error occurred" variant=danger dismissible
AttributeTypeDescription
variantsuccess | warning | danger | infoStyle variant
dismissiblebooleanCan be dismissed
iconstringIcon

toast

Toast notification. Displays a temporary message.

wireframe
toast "Saved!" position=top-right variant=success
AttributeTypeDescription
positiontop-left | top-center | top-right | bottom-left | bottom-center | bottom-rightPosition
variantsuccess | warning | danger | infoStyle variant

progress

Progress bar. Displays progress status.

wireframe
progress value=75
progress value=50 label="Uploading..."
progress indeterminate
AttributeTypeDescription
valuenumberProgress value (0-100)
maxnumberMaximum value
labelstringLabel text
indeterminatebooleanIndeterminate state

spinner

Loading spinner. Displays loading state.

wireframe
spinner
spinner size=lg label="Loading..."
AttributeTypeDescription
sizexs | sm | md | lg | xl | numberSize
labelstringLabel text

Overlay

Overlay UI components.

tooltip

Tooltip element. Displays additional info on hover.

wireframe
tooltip "Click to save" position=top {
  button "Save" primary
}
AttributeTypeDescription
contentstringTooltip content
positiontop | right | bottom | leftPosition

popover

Popover. Displays additional content on click.

wireframe
popover title="Options" {
  // content
}
AttributeTypeDescription
titlestringPopover title

Dropdown menu. Expands menu on click.

wireframe
dropdown {
  // menu items
}

Navigation components.

Navigation area. Places menu items.

wireframe
nav {
  // nav items
}

nav vertical gap=2 {
  // vertical menu
}
AttributeTypeDescription
verticalbooleanVertical direction
gapnumberItem gap

tabs

Tab component. Switches between multiple panels.

wireframe
tabs active=0 {
  // tab panels
}
AttributeTypeDescription
activenumberActive tab index

Breadcrumb. Displays current location as a path.

wireframe
breadcrumb {
  // breadcrumb items
}

Released under the MIT License.