lungo.widgets.notification.styl 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. /**
  2. * Stylesheet
  3. *
  4. * @namespace Lungo.Widgets
  5. * @class Notification
  6. *
  7. * @author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
  8. */
  9. @import "constants.styl"
  10. OPACITY = rgba(0,0,0,0.75)
  11. LOADING = 104px
  12. WINDOW_WIDTH = 280px
  13. .notification
  14. position: absolute
  15. top: 0
  16. left: 0
  17. width: 100%
  18. height: 100%
  19. z-index: 3
  20. display: none
  21. background-color: OPACITY
  22. & .window
  23. position: relative
  24. opacity: 0
  25. transition (all TRANSITION_TIME)
  26. text-align: center
  27. &.show
  28. opacity: 1
  29. transition-delay(TRANSITION_TIME)
  30. & strong, small
  31. display: block
  32. &.growl
  33. left: 50%
  34. top: 50%
  35. width: LOADING
  36. margin: -(LOADING / 2) auto auto -(LOADING / 2)
  37. padding: 24px 8px
  38. transform(scale(0.2))
  39. &.show
  40. transform(scale(1.0))
  41. & > .icon
  42. font-size: 3.6em
  43. line-height: 1.0em
  44. & ~ strong
  45. margin-bottom: -12px
  46. & small
  47. display: none
  48. &:not(.growl)
  49. width: WINDOW_WIDTH
  50. left: 0
  51. top: 0
  52. margin: (HEADER_FOOTER_HEIGHT / 2) auto 0
  53. transform(translateY(100%))
  54. &.show
  55. transform(translateY(0%))
  56. &:not(.html)
  57. padding-top: 24px
  58. & > .icon
  59. font-size: 4.0em
  60. line-height: 1.0em
  61. & > strong
  62. font-size: FONT_SIZE_BIG
  63. & > strong, & small
  64. padding: 0 16px 16px 16px
  65. &.html
  66. & .close
  67. position: absolute
  68. top: -14px
  69. right: -14px
  70. font-size: 14px
  71. line-height: 24px
  72. font-weight: normal
  73. width: 24px
  74. height: 24px
  75. border-radius: 14px