Crear material diseño inspirado notificaciones-material-notificaciones
| Autor: | JacobTheEvans |
|---|---|
| Views Total: | 258 |
| Sitio oficial: | Ir a la web |
| Actualizado: | February 13, 2019 |
| Licencia: | MIT |
Vista prévia
Descripción
Sin embargo, otra biblioteca de JavaScript que se utiliza para crear el estilo de material de diseño Snackbars, mensajes del sistema, notificaciones de banner en la aplicación Web.
Se puede utilizar como plugin Vanilla JavaScript o componente reAct.
Funcionamiento (Vanilla):
Descargue e importe la biblioteca Vanilla-material-notifications. js en el documento.
<script src="./script.js" type="text/javascript"></script>
Crear snackbars de material con varios tipos:
snackbar({
type: 'plain',
position: 'bottomRight',
message: 'Hello this is a plain message',
timeout: 3000
})
snackbar({
type: 'info',
position: 'bottomLeft',
message: 'Hello this is an info message',
timeout: 3500
})
snackbar({
type: 'warning',
position: 'bottomLeft',
message: 'Hello this is a very very long error message. With extra text',
timeout: 2000
})
snackbar({
type: 'alert',
position: 'bottomLeft',
message: 'Hello this is an alert message',
timeout: 2000
})





