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.

457 lines
8.6 KiB

10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
10 years ago
  1. /*
  2. * # Semantic - Sidebar
  3. * http://github.com/semantic-org/semantic-ui/
  4. *
  5. *
  6. * Copyright 2014 Contributors
  7. * Released under the MIT license
  8. * http://opensource.org/licenses/MIT
  9. *
  10. */
  11. /*******************************
  12. Theme
  13. *******************************/
  14. @type : 'module';
  15. @element : 'sidebar';
  16. @import '../../semantic.config';
  17. /*******************************
  18. Sidebar
  19. *******************************/
  20. /* Sidebar Menu */
  21. .ui.sidebar {
  22. position: fixed;
  23. top: 0;
  24. left: 0;
  25. visibility: hidden;
  26. backface-visibility: hidden;
  27. height: 100% !important;
  28. border-radius: 0em !important;
  29. margin: 0 !important;
  30. transition: none;
  31. will-change: transform;
  32. overflow-y: auto !important;
  33. backface-visibility: hidden;
  34. background: @sidebarBackground;
  35. width: @sidebarWidth !important;
  36. }
  37. /*--------------
  38. Direction
  39. ---------------*/
  40. .ui.top.sidebar,
  41. .ui.bottom.sidebar {
  42. width: 100% !important;
  43. height: auto !important;
  44. overflow-y: visible !important;
  45. }
  46. .ui.top.sidebar {
  47. top: 0px !important;
  48. bottom: auto !important;
  49. }
  50. .ui.right.sidebar {
  51. right: 0px !important;
  52. left: auto !important;
  53. }
  54. .ui.bottom.sidebar {
  55. top: auto !important;
  56. bottom: 0px !important;
  57. }
  58. /*--------------
  59. Body
  60. ---------------*/
  61. /* Sets 3D Perspective */
  62. .pushable {
  63. background: @canvasBackground !important;
  64. position: relative;
  65. height: 100%;
  66. overflow-x: hidden;
  67. }
  68. /*--------------
  69. Fixed
  70. ---------------*/
  71. .pushable > .ui.fixed {
  72. position: fixed;
  73. transition: transform @duration @easing;
  74. z-index: @fixedLayer;
  75. }
  76. /*--------------
  77. Pusher
  78. ---------------*/
  79. .pushable > .pusher {
  80. background: @canvasBackground;
  81. height: 100%;
  82. z-index: @middleLayer;
  83. transition: transform @duration @easing;
  84. }
  85. /*--------------
  86. Page
  87. ---------------*/
  88. .pushable > .pusher > .page {
  89. position: relative;
  90. min-height: 100%;
  91. background: @pageBackground;
  92. }
  93. /*--------------
  94. Dimmer
  95. ---------------*/
  96. .pushable > .pusher > .page:after {
  97. position: absolute;
  98. top: 0px;
  99. right: 0px;
  100. content: '';
  101. background-color: @dimmerColor;
  102. width: 0px;
  103. height: 0px;
  104. overflow: hidden;
  105. opacity: 0;
  106. z-index: @dimmerLayer;
  107. transition: opacity @duration;
  108. will-change: opacity;
  109. }
  110. /*--------------
  111. Coupling
  112. ---------------*/
  113. .ui.sidebar.menu .item {
  114. border-radius: 0em !important;
  115. }
  116. /*******************************
  117. States
  118. *******************************/
  119. /*--------------
  120. Pushed
  121. ---------------*/
  122. .pushable.pushed {
  123. overflow-x: hidden;
  124. }
  125. .pushable.pushed > .fixed,
  126. .pushable.pushed > .pusher {
  127. backface-visibility: hidden;
  128. -webkit-overflow-scrolling: touch;
  129. }
  130. .pushable.active > .visible.sidebar {
  131. -webkit-overflow-scrolling: touch;
  132. backface-visibility: hidden;
  133. z-index: @topLayer;
  134. }
  135. /*--------------
  136. Dimmed
  137. ---------------*/
  138. .pushable > .pusher > .page.dimmed:after {
  139. width: 100% !important;
  140. height: 100% !important;
  141. opacity: 1 !important;
  142. }
  143. /*--------------
  144. Animation
  145. ---------------*/
  146. .pushable.show > .pusher,
  147. .pushable.hide > .pusher {
  148. backface-visibility: hidden;
  149. }
  150. .pushable.show > .visible.sidebar,
  151. .pushable.hide > .visible.sidebar {
  152. backface-visibility: hidden;
  153. }
  154. /*--------------
  155. Visible
  156. ---------------*/
  157. .pushable > .visible.ui.sidebar {
  158. visibility: visible;
  159. }
  160. /*******************************
  161. Variations
  162. *******************************/
  163. /*--------------
  164. Styled
  165. ---------------*/
  166. .ui.styled.sidebar {
  167. background-color: #FFFFFF;
  168. padding: 1em 1.25em;
  169. border-right: 1px solid #DDDDDD;
  170. }
  171. /*******************************
  172. Animations
  173. *******************************/
  174. /*--------------
  175. Overlay
  176. ---------------*/
  177. /* Set-up */
  178. .pushable.overlay > .visible.ui.sidebar {
  179. z-index: @topLayer;
  180. }
  181. /* Animation */
  182. .pushable.overlay.show > .visible.ui.sidebar,
  183. .pushable.overlay.hide > .visible.ui.sidebar {
  184. transition: transform @duration @easing;
  185. }
  186. /*--- Left ---*/
  187. /* Set-up */
  188. .left.pushable.overlay > .visible.ui.sidebar {
  189. transform: translate3d(-100%, 0, 0);
  190. }
  191. /* Pushed */
  192. .left.pushable.overlay.pushed .visible.ui.sidebar {
  193. transform: translate3d(0%, 0, 0);
  194. }
  195. /*--- Right ---*/
  196. /* Set-up */
  197. .right.pushable.overlay > .visible.ui.sidebar {
  198. transform: translate3d(100%, 0, 0);
  199. }
  200. /* Pushed */
  201. .right.pushable.overlay.pushed .visible.ui.sidebar {
  202. transform: translate3d(0%, 0, 0);
  203. }
  204. /*--- Top ---*/
  205. /* Set-up */
  206. .top.pushable.overlay > .visible.ui.sidebar {
  207. transform: translate3d(0%, -100%, 0);
  208. }
  209. /* Pushed */
  210. .top.pushable.overlay.pushed .visible.ui.sidebar {
  211. transform: translate3d(0%, 0%, 0);
  212. }
  213. /*--- Bottom ---*/
  214. /* Set-up */
  215. .bottom.pushable.overlay > .visible.ui.sidebar {
  216. transform: translate3d(0%, 100%, 0);
  217. }
  218. /* Pushed */
  219. .bottom.pushable.overlay.pushed .visible.ui.sidebar {
  220. transform: translate3d(0%, 0%, 0);
  221. }
  222. /*--------------
  223. Push
  224. ---------------*/
  225. /* Set-Up */
  226. .pushable.push > .fixed,
  227. .pushable.push > .pusher {
  228. transform: translate3d(0px, 0, 0);
  229. }
  230. .pushable.push > .visible.ui.sidebar {
  231. transform: translate3d(-100%, 0, 0);
  232. }
  233. /* Pushed */
  234. .pushable.push.pushed > .visible.ui.sidebar {
  235. transform: translate3d(0%, 0, 0);
  236. }
  237. .pushable.push.pushed > .fixed,
  238. .pushable.push.pushed > .pusher {
  239. transform: translate3d(@sidebarWidth, 0, 0);
  240. }
  241. .pushable.push.show > .visible.ui.sidebar,
  242. .pushable.push.hide > .visible.ui.sidebar {
  243. transition: transform @duration @easing;
  244. }
  245. /*--------------
  246. Uncover
  247. ---------------*/
  248. /* Set-up */
  249. .pushable.uncover > .fixed,
  250. .pushable.uncover > .pusher {
  251. transform: translate3d(0px, 0px, 0px);
  252. }
  253. .pushable.uncover > .pusher {
  254. z-index: @bottomLayer;
  255. }
  256. .pushable.uncover > .visible.ui.sidebar {
  257. transition: none;
  258. }
  259. /* Pushed */
  260. /*--- Left ---*/
  261. .pushable.left.uncover.pushed > .fixed,
  262. .pushable.left.uncover.pushed > .pusher {
  263. transform: translate3d(@sidebarWidth, 0, 0);
  264. }
  265. /*--- Right ---*/
  266. .pushable.right.uncover.pushed > .fixed,
  267. .pushable.right.uncover.pushed > .pusher {
  268. transform: translate3d(-@sidebarWidth, 0, 0);
  269. }
  270. /*--------------
  271. Slide Along
  272. ---------------*/
  273. /* Set-up */
  274. .pushable.slide.along > .fixed,
  275. .pushable.slide.along > .pusher {
  276. transform: translate3d(0px, 0, 0);
  277. }
  278. .pushable.slide.along > .pusher {
  279. z-index: @bottomLayer;
  280. }
  281. .pushable.slide.along > .visible.ui.sidebar {
  282. transform: translate3d(-50%, 0, 0);
  283. }
  284. /* Pushed */
  285. .pushable.slide.along.pushed > .fixed,
  286. .pushable.slide.along.pushed > .pusher {
  287. transform: translate3d(@sidebarWidth, 0, 0);
  288. }
  289. .pushable.slide.along.pushed > .visible.ui.sidebar {
  290. transform: translate3d(0%, 0, 0);
  291. }
  292. .pushable.slide.along.show > .visible.ui.sidebar,
  293. .pushable.slide.along.hide > .visible.ui.sidebar {
  294. transition: transform @duration @easing;
  295. }
  296. /*--------------
  297. Slide Out
  298. ---------------*/
  299. /* Set-up */
  300. .pushable.slide.out > .fixed,
  301. .pushable.slide.out > .pusher {
  302. transform: translate3d(0px, 0, 0);
  303. }
  304. .pushable.slide.out > .visible.ui.sidebar {
  305. transform: translate3d(50%, 0, 0);
  306. }
  307. /* Pushed */
  308. .pushable.slide.out.pushed > .fixed,
  309. .pushable.slide.out.pushed > .pusher {
  310. transform: translate3d(@sidebarWidth, 0, 0);
  311. }
  312. .pushable.slide.out.pushed .visible.ui.sidebar {
  313. transform: translate3d(0%, 0, 0);
  314. }
  315. .pushable.slide.out.show > .visible.ui.sidebar,
  316. .pushable.slide.out.hide > .visible.ui.sidebar {
  317. transition: transform @duration @easing;
  318. }
  319. /*--------------
  320. Scale Down
  321. ---------------*/
  322. /* Set-up */
  323. .pushable.scale.down > .fixed {
  324. transform: translate3d(0px, 0, 0);
  325. }
  326. .pushable.scale.down > .pusher {
  327. z-index: @bottomLayer;
  328. transform-origin: 75% 50%;
  329. overflow: hidden;
  330. }
  331. .pushable.scale.down > .visible.ui.sidebar {
  332. transform: translate3d(-100%, 0, 0);
  333. z-index: @topLayer;
  334. }
  335. /* Pushed */
  336. .pushable.scale.down.pushed > .pusher {
  337. transform: scale(0.75);
  338. }
  339. .pushable.scale.down.pushed > .visible.ui.sidebar {
  340. transform: translate3d(0, 0, 0);
  341. }
  342. .pushable.scale.down.pushed > .fixed {
  343. transform: translate3d(@sidebarWidth, 0, 0);
  344. }
  345. /* 3D transition cant have duration set until animation */
  346. .pushable.scale.down.show > .visible.ui.sidebar,
  347. .pushable.scale.down.hide > .visible.ui.sidebar {
  348. transition: transform @duration @easing;
  349. }
  350. /*--------------
  351. Safe Mode
  352. ---------------*/
  353. /* Set-Up */
  354. .pushable.safe > .pusher {
  355. position: relative;
  356. transform: none !important;
  357. transition: none !important;
  358. }
  359. .pushable.safe > .pusher {
  360. transform: none !important;
  361. transition: none !important;
  362. }
  363. /* Pushed */
  364. .pushable.safe.pushed {
  365. margin-left: @sidebarWidth !important;
  366. }
  367. .pushable.safe.pushed > .visible.ui.sidebar {
  368. margin-left: -@sidebarWidth;
  369. }
  370. .pushable.safe.pushed > .fixed {
  371. margin-left: @sidebarWidth !important;
  372. }
  373. .pushable.safe.show,
  374. .pushable.safe.hide,
  375. .pushable.safe.show > .fixed,
  376. .pushable.safe.hide > .fixed {
  377. transition: margin @duration @easing !important;
  378. }