mirror of
https://github.com/NoRedInk/noredink-ui.git
synced 2024-12-22 13:12:04 +03:00
Rename Message.Warning -> Message.Alert
This commit is contained in:
parent
eb36e2a862
commit
fb6e4222ae
@ -17,7 +17,7 @@ upgrade_Nri_Ui_Alert_V4_error content =
|
||||
|
||||
|
||||
upgrade_Nri_Ui_Alert_V4_warning content =
|
||||
Message.tiny Message.Warning (Message.Markdown content)
|
||||
Message.tiny Message.Alert (Message.Markdown content)
|
||||
|
||||
|
||||
upgrade_Nri_Ui_Alert_V4_tip content =
|
||||
@ -39,7 +39,7 @@ upgrade_Nri_Ui_Alert_V4_somethingWentWrong errorMessageForEngineers =
|
||||
|
||||
|
||||
upgrade_Nri_Ui_BannerAlert_V6_alert content maybeOnDismiss =
|
||||
Message.banner Message.Warning
|
||||
Message.banner Message.Alert
|
||||
(Message.Html content)
|
||||
(List.filterMap identity
|
||||
[ Maybe.map Message.onDismiss maybeOnDismiss
|
||||
|
@ -31,11 +31,11 @@ import Nri.Ui.Svg.V1 as NriSvg exposing (Svg)
|
||||
import Nri.Ui.UiIcon.V1 as UiIcon
|
||||
|
||||
|
||||
{-| `Error` / `Warning` / `Tip` / `Success`
|
||||
{-| `Error` / `Alert` / `Tip` / `Success`
|
||||
-}
|
||||
type Theme
|
||||
= Error
|
||||
| Warning
|
||||
| Alert
|
||||
| Tip
|
||||
| Success
|
||||
| Custom
|
||||
@ -108,7 +108,7 @@ tiny theme content =
|
||||
, alertString Colors.purple content
|
||||
]
|
||||
|
||||
Warning ->
|
||||
Alert ->
|
||||
[ exclamation Colors.red
|
||||
, alertString Colors.redDark content
|
||||
]
|
||||
@ -169,7 +169,7 @@ large theme content =
|
||||
|> NriSvg.withLabel "Error"
|
||||
}
|
||||
|
||||
Warning ->
|
||||
Alert ->
|
||||
{ backgroundColor = Colors.sunshine
|
||||
, fontColor = Colors.navy
|
||||
, icon =
|
||||
@ -289,7 +289,7 @@ banner theme content attr =
|
||||
|> NriSvg.toHtml
|
||||
}
|
||||
|
||||
Warning ->
|
||||
Alert ->
|
||||
{ backgroundColor = Colors.sunshine
|
||||
, color = Colors.navy
|
||||
, icon =
|
||||
|
@ -35,10 +35,10 @@ init =
|
||||
Control.record ExampleConfig
|
||||
|> Control.field "theme"
|
||||
(Control.choice
|
||||
[ ( "Error / Warning / Tip / Success"
|
||||
[ ( "Error / Alert / Tip / Success"
|
||||
, Control.value
|
||||
[ Message.Error
|
||||
, Message.Warning
|
||||
, Message.Alert
|
||||
, Message.Tip
|
||||
, Message.Success
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user