Message.V1 replaces Alert.V4.warning

This commit is contained in:
Aaron VonderHaar 2020-04-27 15:25:18 -07:00
parent a78b29f7ba
commit 4498ec54bf
3 changed files with 11 additions and 1 deletions

View File

@ -10,6 +10,10 @@ upgrade_Nri_Ui_Alert_V4_error content =
Message.tiny Message.Error (Message.Markdown content)
upgrade_Nri_Ui_Alert_V4_warning content =
Message.tiny Message.Warning (Message.Markdown content)
upgrade_Nri_Ui_Alert_V4_success content =
Message.tiny Message.Success (Message.Markdown content)

View File

@ -28,6 +28,7 @@ import Nri.Ui.Svg.V1 as NriSvg exposing (Svg)
type Theme
= Error
| Warning
| Success
@ -47,6 +48,11 @@ tiny theme content =
, alertString Colors.purple content
]
Warning ->
[ exclamation Colors.red
, alertString Colors.redDark content
]
Success ->
[ iconContainer
[ Css.color Colors.white

View File

@ -51,7 +51,7 @@ example =
\state ->
[ Heading.h3 [] [ text "Message.tiny" ]
, Message.tiny Message.Error (Message.Markdown "This is an **error**")
, Alert.warning "This is a **warning**"
, Message.tiny Message.Warning (Message.Markdown "This is a **warning**")
, Alert.tip "This is a **tip**"
, Message.tiny Message.Success (Message.Markdown "This is a **success**")
, Html.hr [] []