Kern 0.12.0 GitHub
Data

<kern-list-item>

One row of kern-list: optional icon or status at the start, heading and description, meta text (e.g. a time) and actions at the end. With href the row is a link, with clickable a button (kernItemClick); actions in the end slot sit beside it, so clicking them never triggers the row.

Examples

See the examples on kern-list.

Properties

clickabledefault false
boolean

Turns the row into a button that emits kernItemClick.

currentreflectsdefault false
boolean

Marks the link to the open page (aria-current="page"), e.g. in a variant="nav" list.

description
string | undefined
disabledreflectsdefault false
boolean
heading
string | undefined
href
string | undefined

Turns the row into a link.

meta
string | undefined

Right-aligned, muted (time, count, size).

selectedreflectsdefault false
boolean

Marks the selected row (aria-current="true").

target
string | undefined

Events

kernItemClick
CustomEvent<void>

Click or Enter/Space on a clickable row.

kernNavigate
CustomEvent<KernNavigateDetail>

With href: plain left click (no modifier keys, target) before the browser navigates. preventDefault() stops the navigation, so a SPA router can take over.

Slots

(default)

Heading (instead of heading)

description

Second line (instead of description)

end

Actions, e.g. kern-button size="sm" variant="ghost"

meta

Right-aligned meta, e.g. kern-date relative (instead of meta)

start

Icon, kern-status or avatar

CSS parts

row

The link, button or plain row