You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.0 KiB

  1. <template lang='pug'>
  2. v-snackbar.nav-notify(
  3. :color='notification.style'
  4. top
  5. multi-line
  6. v-model='notificationState'
  7. )
  8. .text-left
  9. v-icon.mr-3(dark) mdi-{{ notification.icon }}
  10. span {{ notification.message }}
  11. </template>
  12. <script>
  13. import { get, sync } from 'vuex-pathify'
  14. export default {
  15. data() {
  16. return { }
  17. },
  18. computed: {
  19. notification: get('notification'),
  20. notificationState: sync('notification@isActive')
  21. }
  22. }
  23. </script>
  24. <style lang='scss'>
  25. .nav-notify {
  26. // top: 60px;
  27. z-index: 999;
  28. .v-snack__wrapper {
  29. border-top-left-radius: 0;
  30. border-top-right-radius: 0;
  31. }
  32. .v-snack__content {
  33. position: relative;
  34. &::after {
  35. content: '';
  36. display: block;
  37. width: 100%;
  38. height: 2px;
  39. background-color: rgba(255,255,255,.4);
  40. position: absolute;
  41. bottom: 0;
  42. left: 0;
  43. animation: nav-notify-anim 6s linear;
  44. }
  45. }
  46. }
  47. @keyframes nav-notify-anim {
  48. 0% {
  49. width: 100%;
  50. }
  51. 100% {
  52. width: 0%;
  53. }
  54. }
  55. </style>