Atom components
Atoms are core UI components that are re-used in all of our modals.
#
Input#
Propslabel
#
string
The input label.
required
#
boolean
Adds a "*" beside the label.
id
#
string
Input id, also added to the htmlFor
label attribute.
error
#
string
Will add an error paragraph at the bottom of the input & display the error styling.
errorId
#
string
The error paragraph id.
className
#
string
Appended to the input field className attribute.
labelClassName
#
string
Appended to the label className attribute.
errorClassName
#
string
Appended to the error paragraph className attribute.
wrapperClassName
#
string
Appended to the input wrapper className attribute.
info
Also accepts any prop that HTML input element supports.
#
TextArea#
Propslabel
#
string
The input label.
required
#
boolean
Adds a "*" beside the label.
id
#
string
Input id, also added to the htmlFor
label attribute.
error
#
string
Will add an error paragraph at the bottom of the input & display the error styling.
errorId
#
string
The error paragraph id.
className
#
string
Appended to the input field className attribute.
labelClassName
#
string
Appended to the label className attribute.
errorClassName
#
string
Appended to the error paragraph className attribute.
wrapperClassName
#
string
Appended to the input wrapper className attribute.
info
Also accepts any prop that HTML input element supports.
#
Button#
Propsvariant
#
"solid"|"outline"|"icon"|"ghost"
The button style varient, default is "solid"
.
icon
#
Element
Prefixes the button with an icon.
isLoading
#
boolean
Triggers loading & disable state.
disabled
#
boolean
Triggers disabled state.
className
#
string
Appended to the button className attribute.
info
Also accepts any prop that HTML button element supports.
#
Checkbox#
PropsclassName
#
string
Appended to the checkbox className attribute.
labelClassName
#
string
Appended to the label className attribute.
id
#
string
The checkbox element id.
info
Also accepts any prop that HTML input element supports.
#
Radio#
PropsclassName
#
string
Appended to the radio className attribute.
labelClassName
#
string
Appended to the label className attribute.
id
#
string
The radio element id.
info
Also accepts any prop that HTML input element supports.
#
DatePicker#
Propslabel
#
string
The input label.
required
#
boolean
Adds a "*" beside the label.
id
#
string
Input id, also added to the htmlFor
label attribute.
error
#
string
Will add an error paragraph at the bottom of the input & display the error styling.
errorId
#
string
The error paragraph id.
tooltipText
#
string
Adds a tooltip icon next to the label that displays the given text when on hover.
className
#
string
Appended to the input field className attribute.
labelClassName
#
string
Appended to the label className attribute.
errorClassName
#
string
Appended to the error paragraph className attribute.
wrapperClassName
#
string
Appended to the input wrapper className attribute.
info
Also accepts any prop that HTML input element supports.
#
Link#
Propshref
#
string
The anchor tag href
.
isButton
#
boolean
Sets the anchor role
as button
.
className
#
string
Appended to the anchor tag className attribute.
info
Also accepts any prop that anchor element supports.
#
Select#
Propslabel
#
string
The input label.
required
#
boolean
Adds a "*" beside the label.
id
#
string
Input id, also added to the htmlFor
label attribute.
error
#
string
Will add an error paragraph at the bottom of the input & display the error styling.
errorId
#
string
The error paragraph id.
className
#
string
Appended to the input field className attribute.
labelClassName
#
string
Appended to the label className attribute.
errorClassName
#
string
Appended to the error paragraph className attribute.
wrapperClassName
#
string
Appended to the select wrapper className attribute.
info
Also accepts any prop that HTML input element supports.
#
ModalUsed to create custom modals.
#
Propsid
#
string
Modal container id attribute, also used in analytics to identify the modal.
onDisplay
#
() โ void
Callback function called when the modal is first displayed.
onClose
#
() โ void
Callback function called when the modal is closed.
className
#
string
Appended to the modal container className attribute.
hideCloseButton
#
boolean
Hides the modal's close button when true.
#
NotificationShow a toast notification. this component is a wrapper around react-hot-toast's Toaster component, and the notify
function is an alias for it's toast function.
If you're using the PelcroModalController then you can add the Notification
component as a child component, and then you can call notify
anywhere, even outside React, to show a notification
#
Props#
Tooltip#
Propsvalue
#
string
The value displayed when hovering on the tooltip icon.
className
#
string
Appended to the tooltip container className attribute.