Skip to content
W WRNexusJS
core component

Pill

Reusable pill component.

@wrnexus/ui 0.2.673 props1 slots0 events

Usage

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

<Pill
  label="Pill"
  variant="default"
/>

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

Props and attributes

PropTypeRequirementDefault
labelstringOptional"Pill"
variantstringOptional"default"
classstringOptional""

Slots

  • default

Events

This component does not declare a custom event.

Source contract

Installed source: components/Pill.wrn

component Pill {
  props {
    label = "Pill"
    variant = "default"
    class = ""
  }
  view {
        <span class="wire-badge wire-badge--{variant} wire-catalog-badge wire-catalog-badge--pill {class}">{label}<slot />
        </span>
    }
}