Constructor
# <AlertBar type heading message done />
PropTypes:
Name | Type | Required | Description | Default |
---|---|---|---|---|
type |
enum | Yes | The type of AlertBar to display (determines the color). See types. | |
heading |
string | Yes | The heading to display | |
message |
string | Yes | The message to display | |
done |
func | Yes | Tells Redux that this component is no longer needed (i.e. done) |
Extends
- Component
Members
number
# _DISPLAY_TIME_MS
The amount of time that the AlertBar component is displayed (no including transition time).
Time is in ms.
number
# _TRANSITION_TIME_MS
The amount of time that the AlertBar component takes to transition.
Time is in ms.
If this constant is changed, be sure to change the equivalent time in the SCSS file for this component.
# state
AlertBar component state
Properties:
Name | Type | Description |
---|---|---|
transition |
module:alertBarTransitionOptions | The current CSS transition |
Methods
# clearComponentTimeouts()
Clears all timeouts for AlertBar positions/transitions
# closeButttonClickedHandler()
Slides the AlertBar up before the display time has passed
# componentDidMount()
Starts AlertBar component timeouts
# componentWillUnmount()
Stops asynchronous tasks
# createComponentTimeouts()
Creates timeouts for AlertBar positions/transitions
# getBackgroundColorStyle() → {string}
Gets the CSS background color class name
The background color class name
string
# getTransitionStyle() → {string}
Gets the CSS current transition class name
The transition class name
string