8.0.1 • Published 25 days ago
@leafygreen-ui/banner v8.0.1
Banner
View on MongoDB.design
Installation
Yarn
yarn add @leafygreen-ui/banner
NPM
npm install @leafygreen-ui/banner
Example
<Banner>This is the banner content</Banner>
Output HTML
<div role="alert" class="leafygreen-ui-zvv1x8">
<svg
width="16"
height="16"
role="img"
viewBox="0 0 16 16"
class="leafygreen-ui-1e46tsl"
>
<title>Edit Icon</title>
<path
d="M11.352 6.648l-2-2L11 3l2 2-1.648 1.648zM6 12l-3 1 1-3 4.648-4.648 2 2L6 12z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>
<span class="leafygreen-ui-1kr3ls8">This is the banner content.</span>
</div>
Properties
Prop | Type | Description | Default |
---|---|---|---|
variant | 'info' , 'warning' , 'danger' , 'success' | Sets the variant for the Banner | 'info' |
dismissible | boolean | Determines whether or not the Banner is dismissible | false |
onClose | React.MouseEventHandler | Callback fired when dismiss button is clicked | () => {} |
image | React.ReactElement | Illustration that will replace default Icon when the prop is supplied | |
baseFontSize | 13 , 16 | Determines font-size for body copy in Callout component | 13 |
darkMode | boolean | Determines if the component renders in dark theme | false |
... | native div attributes | Any other props will be spread on the root div element |
8.0.1
25 days ago
8.0.0
1 month ago
7.0.20
1 month ago
7.0.19
2 months ago
8.0.0-alpha.0
10 months ago
8.0.0-alpha.1
10 months ago
7.0.12
9 months ago
7.0.13
9 months ago
7.0.10
10 months ago
7.0.11
9 months ago
7.0.18
6 months ago
7.0.16
7 months ago
7.0.17
6 months ago
7.0.14
8 months ago
7.0.15
8 months ago
7.0.8
11 months ago
7.0.7
12 months ago
7.0.9
11 months ago
7.0.8-next.6
12 months ago
7.0.8-next.5
12 months ago
7.0.8-next.7
12 months ago
7.0.8-next.2
12 months ago
7.0.8-next.1
12 months ago
7.0.8-next.4
12 months ago
7.0.8-next.3
12 months ago
7.0.8-next.0
12 months ago
7.0.4
1 year ago
7.0.6
1 year ago
7.0.5
1 year ago
7.0.3
1 year ago
7.0.0
1 year ago
7.0.2
1 year ago
7.0.1
1 year ago
5.0.3
2 years ago
5.0.2
2 years ago
5.0.1
2 years ago
6.0.1
2 years ago
6.0.0
2 years ago
5.0.1-test.0
2 years ago
5.0.0
2 years ago
5.0.1-next.0
2 years ago
5.0.1-next.1
2 years ago
5.0.1-next.2
2 years ago
4.0.1
2 years ago
4.0.0
2 years ago
3.0.9
3 years ago
3.0.8
3 years ago
3.0.7
3 years ago
3.0.6
3 years ago
3.0.5
3 years ago
3.0.4
3 years ago
3.0.3
3 years ago
3.0.2
3 years ago
3.0.1
4 years ago
3.0.0
4 years ago
2.0.4
4 years ago
2.0.3
4 years ago
2.0.2
4 years ago
2.0.1
4 years ago
2.0.0
4 years ago
1.0.1
4 years ago
1.0.0
4 years ago