sidebar.styl 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155
  1. @import 'nib'
  2. .sidebar
  3. position: absolute
  4. top: 0
  5. bottom: 0
  6. right: 0
  7. .sidebar-content
  8. padding: 10px 20px
  9. background: white
  10. box-shadow: -10px 0px 5px -10px darken(white, 30%)
  11. z-index: 10
  12. position: absolute
  13. top: 0
  14. bottom: 0
  15. right: 0
  16. left: 0
  17. overflow-x: hidden
  18. overflow-y: auto
  19. h3
  20. color: darken(white, 50%)
  21. hr
  22. margin: 8px 0
  23. .board-sidebar
  24. width: 248px
  25. right: -@width
  26. transition: top .1s, right .1s, width .1s
  27. &.is-open
  28. right: 0
  29. .board-widget-nav
  30. border-radius: 3px
  31. background: #dcdcdc
  32. overflow: hidden
  33. padding: 0
  34. position: relative
  35. .toggle-widget-nav
  36. border-radius: 3px
  37. color: #8c8c8c
  38. margin: 0
  39. padding: 7px 10px
  40. position: relative
  41. cursor: pointer
  42. .toggle-menu-icon
  43. position: absolute
  44. top: 8px
  45. right: 8px
  46. &:hover
  47. background: #ccc
  48. color: #4d4d4d
  49. .nav-list
  50. display: block
  51. opacity: 1
  52. max-height: 400px
  53. hr
  54. margin: 2px 0
  55. color: #ccc
  56. background: #ccc
  57. .nav-list-item
  58. display: block
  59. font-weight: 700
  60. line-height: 30px
  61. overflow: hidden
  62. padding: 0 8px 0 36px
  63. position: relative
  64. text-decoration: none
  65. .icon-type
  66. left: 10px
  67. position: absolute
  68. top: 6px
  69. &:hover
  70. background: #ccc
  71. .icon-type
  72. color: #686868
  73. .nav-list-sub-item
  74. font-weight: 400
  75. color: #666
  76. &:hover
  77. color: #4d4d4d
  78. &.collapsed
  79. .nav-list
  80. max-height: 0
  81. opacity: 0
  82. hr
  83. margin: 0
  84. .toggle-widget-nav
  85. color: #4d4d4d
  86. .board-widget-title
  87. display: block
  88. min-height: 20px
  89. margin-bottom: 6px
  90. .board-widget-content
  91. position: relative
  92. z-index: 1
  93. .board-widget h4
  94. margin: 5px 0
  95. .board-widget-activity
  96. margin-right: -4px
  97. .sidebar-tongue
  98. display: block
  99. width: 30px
  100. height: @width
  101. left: -@width
  102. position: absolute
  103. top: 12px
  104. z-index: 15
  105. background: white
  106. border-radius: left 3px
  107. box-shadow: -4px 0px 7px -4px darken(white, 30%)
  108. color: darken(white, 50%)
  109. transition: left .1s
  110. i.fa
  111. margin: 9px
  112. transition: transform 0.5s
  113. .board-sidebar.is-open &
  114. left: -@width + 2px
  115. // XXX Bug: we should add a padding left
  116. &:hover
  117. left: -@width + 5px
  118. i.fa
  119. transform: rotate(180deg)
  120. &.is-hidden,
  121. .board-sidebar.is-open &.is-hidden
  122. z-index: 0
  123. left: 5px