Components

Component API

The properties and callbacks of every component on one page, grouped by category. Each name links to the full page with previews and examples.

Every component is imported from one library:

import 'package:jx_cli/ui.dart';

Actions

JxButton

Property Type Default
children List<Component> required
variant JxButtonVariant primary
size JxButtonSize md
href String? null
type ButtonType button
disabled bool false
loading bool false
fullWidth bool false
classes String? null
attributes Map<String, String>? null
onClick VoidCallback? callback

Layout

JxCard

Property Type Default
children List<Component> required
title String? null
titleLevel int 3
description String? null
footer List<Component>? null
classes String? null

JxDivider

Property Type Default
label String? null
classes String? null

JxAccordion

Property Type Default
items List<JxAccordionItem> required
exclusive bool false
name String? null
classes String? null

Forms

JxTextField

Property Type Default
id String required
label String required
type InputType text
name String? null
value String? null
placeholder String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onInput ValueChanged<String>? callback

JxTextArea

Property Type Default
id String required
label String required
rows int 4
name String? null
value String? null
placeholder String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onInput ValueChanged<String>? callback

JxSelect

Property Type Default
id String required
label String required
options List<JxOption> required
value String? null
placeholder String? null
name String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onChange ValueChanged<String>? callback

JxCheckbox

Property Type Default
id String required
label String required
description String? null
error String? null
required bool false
name String? null
value String? null
checked bool false
disabled bool false
classes String? null
onChange ValueChanged<bool>? callback

JxSwitch

Property Type Default
id String required
label String required
name String? null
checked bool false
disabled bool false
classes String? null
onChange ValueChanged<bool>? callback

JxRadioGroup

Property Type Default
name String required
legend String required
options List<JxOption> required
value String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onChange ValueChanged<String>? callback

JxCombobox

Property Type Default
id String required
label String required
suggestions List<String> required
name String? null
value String? null
placeholder String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onInput ValueChanged<String>? callback

JxSegmentedControl

Property Type Default
name String required
legend String required
options List<JxOption> required
value String? null
hideLegend bool false
disabled bool false
classes String? null
onChange ValueChanged<String>? callback

JxSlider

Property Type Default
id String required
label String required
value num required
min num 0
max num 100
step num 1
name String? null
unit String ''
showValue bool true
showBounds bool false
hint String? null
disabled bool false
classes String? null
onInput ValueChanged<num>? callback

JxDateField

Property Type Default
id String required
label String required
type JxDateType date
value String? null
min String? null
max String? null
name String? null
hint String? null
error String? null
required bool false
disabled bool false
classes String? null
onInput ValueChanged<String>? callback

Feedback

JxAlert

Property Type Default
children List<Component> required
tone JxTone info
title String? null
classes String? null

JxBadge

Property Type Default
label String required
tone JxTone neutral
classes String? null

JxSpinner

Property Type Default
size JxSpinnerSize md
label String? 'Loading'
classes String? null

JxProgress

Property Type Default
value num? null
label String required
max num 100
showValue bool true
classes String? null

JxSkeleton

Property Type Default
classes String? 'h:4 w:full'

JxEmptyState

Property Type Default
title String required
text String? null
icon Component? null
action Component? null
classes String? null

JxToast

Property Type Default
message String required
title String? null
tone JxTone neutral
action Component? null
dismissLabel String 'Dismiss'
classes String? null
onDismiss VoidCallback? callback

Data display

JxAvatar

Property Type Default
name String required
src String? null
size JxAvatarSize md
classes String? null

JxTooltip

Property Type Default
text String required
child Component required
id String? null
classes String? null

JxKbd

Property Type Default
keyLabel String required
classes String? null

JxDataTable

Property Type Default
columns List<JxColumn> required
rows List<List<Component>> required
caption String? null
striped bool true
hover bool true
dense bool false
stickyHeader bool false
sortColumn int? null
sortAscending bool true
emptyText String 'No data'
classes String? null
onSort ValueChanged<int>? callback

JxStat

Property Type Default
label String required
value String required
change String? null
trend JxTrend neutral
description String? null
trendLabels Map<JxTrend, String> Increase / Decrease
classes String? null

JxBreadcrumbs

Property Type Default
items List<JxBreadcrumb> required
classes String? null

JxPagination

Property Type Default
page int required
pageCount int required
href String Function(int)? null
label String 'Pagination'
previousLabel String 'Previous'
nextLabel String 'Next'
classes String? null
onChange ValueChanged<int>? callback

JxTabs

Property Type Default
tabs List<JxTab> required
id String required
label String? null
initialIndex int 0
orientation JxTabsOrientation horizontal
classes String? null
onChange ValueChanged<int>? callback

JxSteps

Property Type Default
steps List<JxStep> required
current int required
label String 'Progress'
completeLabel String 'completed'
classes String? null

Overlays

JxModal

Property Type Default
children List<Component> required
id String required
title String required
description String? null
actions List<Component>? null
size JxModalSize md
dismissible bool true
closeLabel String 'Close'
classes String? null

JxDrawer

Property Type Default
children List<Component> required
id String required
title String required
description String? null
actions List<Component>? null
side JxDrawerSide right
dismissible bool true
closeLabel String 'Close'
classes String? null

JxDropdownMenu

Property Type Default
id String required
label String required
items List<JxMenuItem> required
variant JxButtonVariant outline
size JxButtonSize md
align JxMenuAlign start
classes String? null