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.

562 lines
12 KiB

11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
  1. /*
  2. * # Semantic - Dropdown
  3. * http://github.com/jlukic/semantic-ui/
  4. *
  5. *
  6. * Copyright 2013 Contributors
  7. * Released under the MIT license
  8. * http://opensource.org/licenses/MIT
  9. *
  10. */
  11. /*******************************
  12. Dropdown
  13. *******************************/
  14. .ui.dropdown {
  15. position: relative;
  16. display: inline-block;
  17. line-height: 1;
  18. -webkit-transition:
  19. border-radius 0.1s ease,
  20. width 0.2s ease
  21. ;
  22. -moz-transition:
  23. border-radius 0.1s ease,
  24. width 0.2s ease
  25. ;
  26. -o-transition:
  27. border-radius 0.1s ease,
  28. width 0.2s ease
  29. ;
  30. -ms-transition:
  31. border-radius 0.1s ease,
  32. width 0.2s ease
  33. ;
  34. transition:
  35. border-radius 0.1s ease,
  36. width 0.2s ease
  37. ;
  38. -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  39. -moz-tap-highlight-color: rgba(0, 0, 0, 0);
  40. tap-highlight-color: rgba(0, 0, 0, 0);
  41. }
  42. /*******************************
  43. Content
  44. *******************************/
  45. /*--------------
  46. Menu
  47. ---------------*/
  48. .ui.dropdown .menu {
  49. position: absolute;
  50. display: none;
  51. top: 100%;
  52. margin: 0em;
  53. background-color: #FFFFFF;
  54. min-width: 100%;
  55. white-space: nowrap;
  56. font-size: 0.875em;
  57. text-shadow: none;
  58. -webkit-box-shadow: 0px 0px 1px 1px rgba(0, 0, 0, 0.1);
  59. -moz-box-shadow: 0px 0px 1px 1px rgba(0, 0, 0, 0.1);
  60. box-shadow: 0px 0px 1px 1px rgba(0, 0, 0, 0.1);
  61. -moz-border-radius: 0px 0px 0.325em 0.325em;
  62. -webkit-border-radius: 0px 0px 0.325em 0.325em;
  63. border-radius: 0px 0px 0.325em 0.325em;
  64. -webkit-transition: opacity 0.2s ease;
  65. -moz-transition: opacity 0.2s ease;
  66. -o-transition: opacity 0.2s ease;
  67. -ms-transition: opacity 0.2s ease;
  68. transition: opacity 0.2s ease;
  69. z-index: 11;
  70. }
  71. /*--------------
  72. Icon
  73. ---------------*/
  74. .ui.dropdown > .dropdown.icon {
  75. width: auto;
  76. margin: 0em 0em 0em 1em;
  77. }
  78. .ui.dropdown > .dropdown.icon:before {
  79. content: "\f0d7";
  80. }
  81. .ui.dropdown .menu .item .dropdown.icon {
  82. width: auto;
  83. float: right;
  84. margin: 0em 0em 0em 0.5em;
  85. }
  86. .ui.dropdown .menu .item .dropdown.icon:before {
  87. content: "\f0da";
  88. }
  89. /*--------------
  90. Text
  91. ---------------*/
  92. .ui.dropdown > .text {
  93. cursor: pointer;
  94. display: inline-block;
  95. -webkit-transition: color 0.2s ease;
  96. -moz-transition: color 0.2s ease;
  97. -o-transition: color 0.2s ease;
  98. -ms-transition: color 0.2s ease;
  99. transition: color 0.2s ease;
  100. }
  101. /* Flyout Direction */
  102. .ui.dropdown .menu {
  103. left: 0px;
  104. }
  105. /*--------------
  106. Sub Menu
  107. ---------------*/
  108. .ui.dropdown .menu .menu {
  109. top: 0% !important;
  110. left: 100% !important;
  111. margin: 0em !important;
  112. border-radius: 0 0.325em 0.325em 0em !important;
  113. }
  114. .ui.dropdown .menu .menu:after {
  115. display: none;
  116. }
  117. .ui.dropdown .menu .item {
  118. cursor: pointer;
  119. border: none;
  120. border-top: 1px solid rgba(0, 0, 0, 0.05);
  121. height: auto;
  122. font-size: 0.875em;
  123. display: block;
  124. color: rgba(0, 0, 0, 0.75);
  125. padding: 0.85em 1em !important;
  126. font-size: 0.875rem;
  127. text-transform: none;
  128. font-weight: normal;
  129. text-align: left;
  130. -webkit-touch-callout: none;
  131. }
  132. .ui.dropdown .menu .item:before {
  133. display: none;
  134. }
  135. .ui.dropdown .menu .item .icon {
  136. margin-right: 0.75em;
  137. }
  138. .ui.dropdown .menu .item:first-child {
  139. border-top: none;
  140. }
  141. /*******************************
  142. Coupling
  143. *******************************/
  144. /* Opposite on last menu on right */
  145. .ui.menu .right.menu .dropdown:last-child .menu,
  146. .ui.buttons > .ui.dropdown:last-child .menu {
  147. left: auto;
  148. right: 0px;
  149. }
  150. .ui.vertical.menu .dropdown.item > .dropdown.icon {
  151. content: "\f0da";
  152. }
  153. .ui.dropdown.icon.button > .dropdown.icon {
  154. margin: 0em;
  155. }
  156. /*******************************
  157. States
  158. *******************************/
  159. /* Dropdown Visible */
  160. .ui.visible.dropdown > .menu {
  161. display: block;
  162. }
  163. /* Menu Item Hover */
  164. .ui.dropdown .menu .item:hover {
  165. background-color: rgba(0, 0, 0, 0.02);
  166. z-index: 12;
  167. }
  168. /* Menu Item Active */
  169. .ui.dropdown .menu .active.item {
  170. box-shadow: none;
  171. background-color: rgba(0, 0, 0, 0.06) !important;
  172. border-left: none;
  173. border-color: transparent !important;
  174. -webkit-box-shadow: none;
  175. -moz-shadow: none;
  176. box-shadow: none;
  177. z-index: 12;
  178. }
  179. /* Default Text */
  180. .ui.dropdown > .default.text,
  181. .ui.default.dropdown > .text {
  182. color: rgba(0, 0, 0, 0.5);
  183. }
  184. .ui.dropdown:hover > .default.text,
  185. .ui.default.dropdown:hover > .text {
  186. color: rgba(0, 0, 0, 0.8);
  187. }
  188. /*******************************
  189. Variations
  190. *******************************/
  191. /*--------------
  192. Simple
  193. ---------------*/
  194. /* Displays without javascript */
  195. .ui.simple.dropdown .menu:before,
  196. .ui.simple.dropdown .menu:after {
  197. display: none;
  198. }
  199. .ui.simple.dropdown .menu {
  200. display: block;
  201. overflow: hidden;
  202. top: -9999px !important;
  203. position: absolute;
  204. opacity: 0;
  205. width: 0;
  206. height: 0;
  207. -webkit-transition: opacity 0.2s ease-out;
  208. -moz-transition: opacity 0.2s ease-out;
  209. -o-transition: opacity 0.2s ease-out;
  210. -ms-transition: opacity 0.2s ease-out;
  211. transition: opacity 0.2s ease-out;
  212. }
  213. .ui.simple.active.dropdown,
  214. .ui.simple.dropdown:hover {
  215. border-bottom-left-radius: 0em !important;
  216. border-bottom-right-radius: 0em !important;
  217. }
  218. .ui.simple.active.dropdown > .menu,
  219. .ui.simple.dropdown:hover > .menu {
  220. overflow: visible;
  221. width: auto;
  222. height: auto;
  223. top: 100% !important;
  224. opacity: 1;
  225. }
  226. .ui.simple.dropdown > .menu .item:active > .menu,
  227. .ui.simple.dropdown:hover > .menu .item:hover > .menu {
  228. overflow: visible;
  229. width: auto;
  230. height: auto;
  231. top: 0% !important;
  232. left: 100% !important;
  233. opacity: 1;
  234. }
  235. .ui.simple.disabled.dropdown:hover .menu {
  236. display: none;
  237. height: 0px;
  238. width: 0px;
  239. overflow: hidden;
  240. }
  241. /*--------------
  242. Selection
  243. ---------------*/
  244. /* Displays like a select box */
  245. .ui.selection.dropdown {
  246. cursor: pointer;
  247. display: inline-block;
  248. word-wrap: break-word;
  249. white-space: normal;
  250. background-color: #FFFFFF;
  251. padding: 0.5em 1em;
  252. line-height: 1.33;
  253. color: rgba(0, 0, 0, 0.8);
  254. -webkit-box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.1) !important;
  255. -moz-box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.1) !important;
  256. box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.1) !important;
  257. -webkit-border-radius: 0.3125em !important;
  258. -moz-border-radius: 0.3125em !important;
  259. border-radius: 0.3125em !important;
  260. }
  261. .ui.selection.dropdown select {
  262. display: none;
  263. }
  264. .ui.selection.dropdown > .dropdown.icon {
  265. opacity: 0.7;
  266. margin: 0.2em 0em 0.2em 1.25em;
  267. -webkit-transition: opacity 0.2s ease-out;
  268. -moz-transition: opacity 0.2s ease-out;
  269. -o-transition: opacity 0.2s ease-out;
  270. -ms-transition: opacity 0.2s ease-out;
  271. transition: opacity 0.2s ease-out;
  272. }
  273. .ui.selection.dropdown,
  274. .ui.selection.dropdown .menu {
  275. top: 100%;
  276. -webkit-transition: box-shadow 0.2s ease-out;
  277. -moz-transition: box-shadow 0.2s ease-out;
  278. -o-transition: box-shadow 0.2s ease-out;
  279. -ms-transition: box-shadow 0.2s ease-out;
  280. transition: box-shadow 0.2s ease-out;
  281. }
  282. .ui.selection.dropdown .menu {
  283. max-height: 312px;
  284. overflow-x: hidden;
  285. overflow-y: auto;
  286. -webkit-box-shadow: 0px 1px 0px 1px #E0E0E0;
  287. -moz-box-shadow: 0px 1px 0px 1px #E0E0E0;
  288. box-shadow: 0px 1px 0px 1px #E0E0E0;
  289. -moz-border-radius: 0px 0px 0.325em 0.325em;
  290. -webkit-border-radius: 0px 0px 0.325em 0.325em;
  291. border-radius: 0px 0px 0.325em 0.325em;
  292. }
  293. .ui.selection.dropdown .menu:after,
  294. .ui.selection.dropdown .menu:before {
  295. display: none;
  296. }
  297. .ui.selection.dropdown .menu img {
  298. height: 2.5em;
  299. display: inline-block;
  300. vertical-align: middle;
  301. margin-right: 0.5em;
  302. }
  303. /* Hover */
  304. .ui.selection.dropdown:hover {
  305. -webkit-box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.2) !important;
  306. -moz-box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.2) !important;
  307. box-shadow: 0px 0px 0px 1px rgba(0, 0, 0, 0.2) !important;
  308. }
  309. .ui.selection.dropdown:hover .menu {
  310. -webkit-box-shadow: 0px 1px 0px 1px #D3D3D3;
  311. -moz-box-shadow: 0px 1px 0px 1px #D3D3D3;
  312. box-shadow: 0px 1px 0px 1px #D3D3D3;
  313. }
  314. .ui.selection.dropdown:hover > .dropdown.icon {
  315. opacity: 1;
  316. }
  317. /* Visible */
  318. .ui.visible.selection.dropdown {
  319. border-bottom-left-radius: 0em !important;
  320. border-bottom-right-radius: 0em !important;
  321. }
  322. /* Active */
  323. .ui.active.selection.dropdown {
  324. -webkit-border-radius: 0.3125em 0.3125em 0em 0em !important;
  325. -moz-border-radius: 0.3125em 0.3125em 0em 0em !important;
  326. border-radius: 0.3125em 0.3125em 0em 0em !important;
  327. }
  328. .ui.active.selection.dropdown > .dropdown.icon {
  329. opacity: 1;
  330. }
  331. .ui.active.selection.dropdown .menu {
  332. }
  333. /*--------------
  334. Fluid
  335. ---------------*/
  336. .ui.fluid.dropdown {
  337. display: block;
  338. }
  339. .ui.fluid.dropdown > .dropdown.icon {
  340. float: right;
  341. }
  342. /*--------------
  343. Inline
  344. ---------------*/
  345. .ui.inline.dropdown {
  346. cursor: pointer;
  347. display: inline-block;
  348. color: inherit;
  349. }
  350. .ui.inline.dropdown .dropdown.icon {
  351. margin: 0em 0.5em 0em 0.25em;
  352. }
  353. .ui.inline.dropdown .text {
  354. font-weight: bold;
  355. }
  356. .ui.inline.dropdown .menu {
  357. cursor: auto;
  358. margin-top: 0.25em;
  359. -webkit-border-radius: 0.325em;
  360. -moz-border-radius: 0.325em;
  361. border-radius: 0.325em;
  362. }
  363. /*--------------
  364. Floating
  365. ---------------*/
  366. .ui.floating.dropdown .menu {
  367. left: 0;
  368. right: auto;
  369. margin-top: 0.5em;
  370. -webkit-border-radius: 0.325em;
  371. -moz-border-radius: 0.325em;
  372. border-radius: 0.325em;
  373. }
  374. /*--------------
  375. Pointing
  376. ---------------*/
  377. .ui.pointing.dropdown .menu {
  378. top: 100%;
  379. margin-top: 0.75em;
  380. -moz-border-radius: 0.325em;
  381. -webkit-border-radius: 0.325em;
  382. border-radius: 0.325em;
  383. }
  384. .ui.pointing.dropdown .menu:after {
  385. display: block;
  386. position: absolute;
  387. pointer-events: none;
  388. content: " ";
  389. visibility: visible;
  390. width: 0.5em;
  391. height: 0.5em;
  392. -moz-box-shadow: -1px -1px 0px 1px rgba(0, 0, 0, 0.05);
  393. -webkit-box-shadow: -1px -1px 0px 1px rgba(0, 0, 0, 0.05);
  394. box-shadow: -1px -1px 0px 1px rgba(0, 0, 0, 0.05);
  395. background-image: none;
  396. background-color: #FFFFFF;
  397. -webkit-transform: rotate(45deg);
  398. -moz-transform: rotate(45deg);
  399. transform: rotate(45deg);
  400. z-index: 2;
  401. }
  402. .ui.pointing.dropdown .menu .active.item:first-child {
  403. background: transparent -webkit-linear-gradient(transparent, rgba(0, 0, 0, 0.03));
  404. background: transparent -moz-linear-gradient(transparent, rgba(0, 0, 0, 0.03));
  405. background: transparent -o-linear-gradient(transparent, rgba(0, 0, 0, 0.03));
  406. background: transparent -ms-linear-gradient(transparent, rgba(0, 0, 0, 0.03));
  407. background: transparent linear-gradient(transparent, rgba(0, 0, 0, 0.03));
  408. }
  409. /* Directions */
  410. .ui.pointing.dropdown .menu:after {
  411. top: -0.25em;
  412. left: 50%;
  413. margin: 0em 0em 0em -0.25em;
  414. }
  415. .ui.top.left.pointing.dropdown .menu {
  416. top: 100%;
  417. bottom: auto;
  418. left: 0%;
  419. right: auto;
  420. margin: 0.75em 0em 0em;
  421. }
  422. .ui.top.left.pointing.dropdown .menu:after {
  423. top: -0.25em;
  424. left: 1.25em;
  425. right: auto;
  426. margin: 0em;
  427. -webkit-transform: rotate(45deg);
  428. -moz-transform: rotate(45deg);
  429. transform: rotate(45deg);
  430. }
  431. .ui.top.right.pointing.dropdown .menu {
  432. top: 100%;
  433. bottom: auto;
  434. right: 0%;
  435. left: auto;
  436. margin: 0.75em 0em 0em;
  437. }
  438. .ui.top.right.pointing.dropdown .menu:after {
  439. top: -0.25em;
  440. left: auto;
  441. right: 1.25em;
  442. margin: 0em;
  443. -webkit-transform: rotate(45deg);
  444. -moz-transform: rotate(45deg);
  445. transform: rotate(45deg);
  446. }
  447. .ui.left.pointing.dropdown .menu {
  448. top: 0%;
  449. left: 100%;
  450. right: auto;
  451. margin: 0em 0em 0em 0.75em;
  452. }
  453. .ui.left.pointing.dropdown .menu:after {
  454. top: 1em;
  455. left: -0.25em;
  456. margin: 0em 0em 0em 0em;
  457. -webkit-transform: rotate(-45deg);
  458. -moz-transform: rotate(-45deg);
  459. transform: rotate(-45deg);
  460. }
  461. .ui.right.pointing.dropdown .menu {
  462. top: 0%;
  463. left: auto;
  464. right: 100%;
  465. margin: 0em 0.75em 0em 0em;
  466. }
  467. .ui.right.pointing.dropdown .menu:after {
  468. top: 1em;
  469. left: auto;
  470. right: -0.25em;
  471. margin: 0em 0em 0em 0em;
  472. -webkit-transform: rotate(135deg);
  473. -moz-transform: rotate(135deg);
  474. transform: rotate(135deg);
  475. }