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.

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