release: WRNexusJS 0.6.0
This commit is contained in:
@@ -1,38 +1,41 @@
|
||||
component Badge {
|
||||
props {
|
||||
label = "Badge"
|
||||
size = "md"
|
||||
color = "primary"
|
||||
variant = "solid"
|
||||
shape = "pill"
|
||||
class = ""
|
||||
|
||||
icon = ""
|
||||
iconPosition = "start"
|
||||
dot = false
|
||||
dotOnly = false
|
||||
dotLabel = "Status"
|
||||
animated = false
|
||||
|
||||
avatarSrc = ""
|
||||
avatarAlt = ""
|
||||
dismissible = false
|
||||
dismissLabel = "Remove badge"
|
||||
truncate = false
|
||||
maxWidth = "12rem"
|
||||
|
||||
anchorLabel = ""
|
||||
anchorIcon = ""
|
||||
placement = "inline"
|
||||
anchorLabelText = "Badge anchor"
|
||||
|
||||
@event dismiss = function
|
||||
outputs {
|
||||
dismiss(payload: { sourceEvent?: Event; [key: string]: string | number | boolean | null | object })
|
||||
}
|
||||
|
||||
state visible = true
|
||||
props {
|
||||
label: string = "Badge"
|
||||
size: string = "md"
|
||||
color: string = "primary"
|
||||
variant: string = "solid"
|
||||
shape: string = "pill"
|
||||
class: string = ""
|
||||
|
||||
icon: string = ""
|
||||
iconPosition: string = "start"
|
||||
dot: boolean = false
|
||||
dotOnly: boolean = false
|
||||
dotLabel: string = "Status"
|
||||
animated: boolean = false
|
||||
|
||||
avatarSrc: string = ""
|
||||
avatarAlt: string = ""
|
||||
dismissible: boolean = false
|
||||
dismissLabel: string = "Remove badge"
|
||||
truncate: boolean = false
|
||||
maxWidth: string = "12rem"
|
||||
|
||||
anchorLabel: string = ""
|
||||
anchorIcon: string = ""
|
||||
placement: string = "inline"
|
||||
anchorLabelText: string = "Badge anchor"
|
||||
|
||||
}
|
||||
|
||||
state visible: boolean = true
|
||||
|
||||
functions {
|
||||
function dismissBadge(sourceEvent, root, customEvent) {
|
||||
client function dismissBadge(sourceEvent, root, customEvent) {
|
||||
visible = false
|
||||
root = sourceEvent.currentTarget.closest("[data-wrn-badge]")
|
||||
customEvent = document.createEvent("CustomEvent")
|
||||
|
||||
Reference in New Issue
Block a user