page Cardcomponent { seo { title = "Card component" description = "Reusable card component." } view {
W WRNexusJS
content component

Card

Reusable card component.

@wrnexus/ui 0.2.744 props1 slots0 events

Usage

Components are auto-discovered. Use the component directly in any .wrn view:

<Card
  variant="default"
  padding="md"
  interactive="false"
/>

Legacy mount name: data-component="Card".

Props and attributes

PropTypeRequirementDefault
variantstringOptional"default"
paddingstringOptional"md"
interactivebooleanOptionalfalse
classNamestringOptional""

Slots

  • default

Events

This component does not declare a custom event.

Source contract

Installed source: components/Card.wrn

component Card {
  props {
    variant = "default"
    padding = "md"
    interactive = false
    className = ""
  }
  view {
        <article class="wire-card wire-card--{variant} wire-card--padding-{padding} {interactive ? 'wire-card--interactive' : ''} {className}">
        <slot />
        </article>
    }
}
} }