lungo.layout.nav.styl 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  1. /**
  2. * Stylesheet
  3. *
  4. * @namespace Lungo.Layout
  5. * @class Nav
  6. *
  7. * @author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
  8. */
  9. @import "constants.styl"
  10. HEADER_GROUPBAR_HEIGHT = 32px
  11. nav
  12. &.groupbar, footer &
  13. display-box()
  14. box-pack(justify)
  15. width: 100%
  16. & > a
  17. box-flex(1)
  18. header &
  19. & a
  20. padding: 0px 11px !important
  21. z-index: 1000
  22. float: left
  23. & .button, button
  24. margin: 6px 2px 0 2px
  25. line-height: 31px !important
  26. & > .icon
  27. font-size: 1.5em
  28. position: relative
  29. top: 3px
  30. height: SIZE = 20px
  31. width: SIZE
  32. line-height: SIZE
  33. display: inline-block
  34. &.right a.button:last-child
  35. margin-right: 6px
  36. &:not(.right) a.button:first-child
  37. margin-left: 6px
  38. & a:not(.button)
  39. height: HEADER_HEIGHT
  40. & > .icon
  41. font-size: 1.8em
  42. & .tag
  43. position: relative
  44. top: -12px
  45. left: -12px
  46. margin-right: -20px
  47. & abbr
  48. font-size: FONT_SIZE_SMALL
  49. font-weight: 700
  50. & .icon ~ abbr
  51. margin-left: 4px
  52. float: right
  53. & .loading
  54. margin-top: .5em
  55. font-size: 1.6em
  56. & + .icon
  57. display: none
  58. &.groupbar
  59. // position: relative
  60. // top: HEADER_HEIGHT
  61. height: HEADER_GROUPBAR_HEIGHT
  62. width: 100%
  63. z-index: 2
  64. line-height: HEADER_GROUPBAR_HEIGHT
  65. & > a
  66. padding: 0px
  67. margin: 0px
  68. height: HEADER_GROUPBAR_HEIGHT !important
  69. display: block
  70. text-align: center
  71. & .icon
  72. font-size: 1.0em
  73. margin-right: 2px
  74. & .tag
  75. position: relative
  76. top: -1px
  77. left: 2px
  78. footer &
  79. & a
  80. text-align: center
  81. display: block
  82. padding: 0
  83. height: HEADER_HEIGHT
  84. & .icon
  85. font-size: 2.0em !important
  86. line-height: HEADER_HEIGHT
  87. width: 32px
  88. display: inline-block
  89. & .tag
  90. top: -42px
  91. left: 4px
  92. & .loading
  93. top: 0
  94. font-size: 1.4em
  95. abbr
  96. display: none
  97. & .tag
  98. position: relative
  99. top: -12px
  100. left: -12px
  101. margin-right: -20px
  102. &.with-labels
  103. & .icon
  104. line-height: 36px
  105. & abbr
  106. display: block !important
  107. margin-top: -8px
  108. z-index: 1
  109. font-size: 11px
  110. line-height: 14px
  111. overflow: hidden
  112. white-space: nowrap
  113. text-overflow: ellipsis
  114. /* ========================================================================= */
  115. /* ================================= MENU ================================== */
  116. /* ========================================================================= */
  117. &[data-control=menu]
  118. position: absolute
  119. left: 0px
  120. top: HEADER_HEIGHT
  121. visibility: hidden
  122. z-index: 2
  123. width: inherit
  124. font-size: FONT_SIZE_BIG
  125. text-align: center
  126. transform translateY(-120%)
  127. transition-property transform
  128. transition-duration TRANSITION_TIME
  129. transition-timing-function DEFAULT_TRANSITION
  130. backface-visibility hidden
  131. &.show
  132. visibility: visible
  133. transform translateY(0%)
  134. & > a
  135. display: block
  136. position: relative
  137. padding: 14px 10px
  138. text-shadow 0 1px 0 #111
  139. &:active
  140. border-color: transparent
  141. & > .icon
  142. position: absolute
  143. left: 0.5em
  144. font-size: 1.5em