style: add inactive message style
This commit is contained in:
parent
e60d125e05
commit
280de86865
@ -10,6 +10,8 @@
|
||||
--color-success-dark: #1ca64c
|
||||
--color-info: #c4c4c4
|
||||
--color-info-dark: #919191
|
||||
--color-nonactive: #efefef
|
||||
--color-nonactive-dark: #9a989e
|
||||
--color-lightblack: #1A2A36
|
||||
--color-lightwhite: #fcfffa
|
||||
--color-grey: #B1B5C0
|
||||
@ -740,6 +742,9 @@ section
|
||||
.notification-success
|
||||
color: var(--color-success-dark)
|
||||
|
||||
.notification-nonactive
|
||||
color: var(--color-nonactive)
|
||||
|
||||
// "Heated" element.
|
||||
// Set custom property "--hotness" to a value from 0 to 1 to turn
|
||||
// the element's background to a color on a gradient from green to red.
|
||||
@ -1476,6 +1481,9 @@ a.breadcrumbs__home
|
||||
|
||||
&--success
|
||||
border-left-color: var(--color-success)
|
||||
|
||||
&--disabled
|
||||
border-left-color: var(--color-nonactive)
|
||||
|
||||
|
||||
.active-allocations__wrapper
|
||||
|
||||
@ -133,6 +133,7 @@ MessageError: Fehler
|
||||
MessageWarning: Warnung
|
||||
MessageInfo !ident-ok: Information
|
||||
MessageSuccess: Erfolg
|
||||
MessageNonactive: Inaktiv
|
||||
ShortFieldPrimary: HF
|
||||
ShortFieldSecondary: NF
|
||||
SheetGradingPassPoints': Bestehen nach Punkten
|
||||
|
||||
@ -133,6 +133,7 @@ MessageError: Error
|
||||
MessageWarning: Warning
|
||||
MessageInfo: Information
|
||||
MessageSuccess: Success
|
||||
MessageNonactive: Inactive
|
||||
ShortFieldPrimary: Mj
|
||||
ShortFieldSecondary: Mn
|
||||
SheetGradingPassPoints': Passing by points
|
||||
|
||||
@ -30,10 +30,11 @@ notification nType Message{ messageIcon = messageIcon', .. }
|
||||
where
|
||||
messageIcon = fromMaybe defaultIcon messageIcon'
|
||||
defaultIcon = case messageStatus of
|
||||
Success -> IconNotificationSuccess
|
||||
Info -> IconNotificationInfo
|
||||
Warning -> IconNotificationWarning
|
||||
Error -> IconNotificationError
|
||||
Success -> IconNotificationSuccess
|
||||
Info -> IconNotificationInfo
|
||||
Warning -> IconNotificationWarning
|
||||
Error -> IconNotificationError
|
||||
Nonactive -> IconNotificationNonactive
|
||||
|
||||
notificationWidget :: Yesod site
|
||||
=> NotificationType
|
||||
|
||||
@ -72,6 +72,7 @@ data Icon
|
||||
| IconNotificationInfo
|
||||
| IconNotificationWarning
|
||||
| IconNotificationError
|
||||
| IconNotificationNonactive
|
||||
| IconFavourite
|
||||
| IconLanguage
|
||||
| IconNavContainerClose | IconPageActionChildrenClose
|
||||
@ -150,6 +151,7 @@ iconText = \case
|
||||
IconNotificationInfo -> "info-circle"
|
||||
IconNotificationWarning -> "exclamation-circle"
|
||||
IconNotificationError -> "exclamation-triangle"
|
||||
IconNotificationNonactive -> "info"
|
||||
IconFavourite -> "star"
|
||||
IconLanguage -> "flag-alt"
|
||||
IconNavContainerClose -> "chevron-up"
|
||||
|
||||
@ -29,7 +29,7 @@ import Text.Blaze.Html.Renderer.Text (renderHtml)
|
||||
import Text.HTML.SanitizeXSS (sanitizeBalance)
|
||||
|
||||
|
||||
data MessageStatus = Error | Warning | Info | Success
|
||||
data MessageStatus = Error | Warning | Info | Success | Nonactive
|
||||
deriving (Eq, Ord, Enum, Bounded, Show, Read, Lift, Generic, Typeable)
|
||||
deriving anyclass (Universe, Finite, NFData)
|
||||
|
||||
@ -219,7 +219,7 @@ messageTooltip Message{..} = let urgency = statusToUrgencyClass messageStatus
|
||||
Utils.Message.Error -> IconProblem
|
||||
Utils.Message.Warning -> IconWarning
|
||||
Utils.Message.Success -> IconOK
|
||||
Utils.Message.Info -> IconTooltipDefault)
|
||||
_ -> IconTooltipDefault)
|
||||
messageIcon
|
||||
tooltip = toWidget messageContent :: WidgetFor site ()
|
||||
isInlineTooltip = False
|
||||
|
||||
Reference in New Issue
Block a user