@s-ui/react-molecule-notification
v1.34.0
Published
> Notifications offer users information on the system. The content may confirm that an action has been performed correctly, warn the user of an error or simply give information on certain circumstances.
Downloads
9,207
Maintainers
Keywords
Readme
MoleculeNotification
Notifications offer users information on the system. The content may confirm that an action has been performed correctly, warn the user of an error or simply give information on certain circumstances.
Installation
$ npm install @s-ui/react-molecule-notification --save
Basic usage
import MoleculeNotification, {BRDS_SIZE} from '@s-ui/react-molecule-notification'
// sui-atom-button
const BUTTONS = [
{
type: 'secondary',
children: 'Secondary',
negative: true
},
{
type: 'primary',
children: 'Primary',
negative: true
}
]
// import named export sizes from component as seen above
BRDS_SIZE = {
extraLarge: 'xl',
large: 'l',
medium: 'm',
small: 's',
extraSmall: 'xs'
}
return (
<MoleculeNotification
type='success'
autoclose='short'
buttons={BUTTONS}
roundedCorners={BRDS_SIZE.medium}
>
<p>Lorem fistrum</p>
</MoleculeNotification>
)
Border Radius usage
- Define a
$bdrs-base
Sass var value in your vertical theme to get 5 different border radius sizes. Then import theBRDS_SIZE
object to getextraSmall
,small
,medium
,large
andextraLarge
sizes in declarative way.
Find full description and more examples in the demo page.