Snackbars are always empty
Closed this issue · 1 comments
JDemler commented
Looking at the demo of snackbars they always seem empty: https://aforemny.github.io/material-components-web-elm/#snackbar
Digging a bit deeper, I am pretty sure that a nameclash during the refactoring process is responsible:
message
vs messages
{-| Snackbar view function
-}
snackbar : (Msg msg -> msg) -> Config msg -> Queue msg -> Html msg
snackbar lift ((Config { additionalAttributes }) as config_) ((Queue { messages }) as queue) =
Html.node "mdc-snackbar"
(List.filterMap identity
[ rootCs
, closeOnEscapeProp config_
, leadingCs message
, stackedCs message
, messageIdProp queue
, timeoutMsProp message
, closedHandler lift
]
++ additionalAttributes
)
[ surfaceElt message ]
Where message
is the function that emits a default message.