select2.css 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574
  1. /*
  2. Version: @@ver@@ Timestamp: @@timestamp@@
  3. */
  4. .select2-container {
  5. position: relative;
  6. display: inline-block;
  7. /* inline-block for ie7 */
  8. zoom: 1;
  9. *display: inline;
  10. vertical-align: top;
  11. }
  12. .select2-container,
  13. .select2-drop,
  14. .select2-search,
  15. .select2-search input{
  16. /*
  17. Force border-box so that % widths fit the parent
  18. container without overlap because of margin/padding.
  19. More Info : http://www.quirksmode.org/css/box.html
  20. */
  21. -webkit-box-sizing: border-box; /* webkit */
  22. -khtml-box-sizing: border-box; /* konqueror */
  23. -moz-box-sizing: border-box; /* firefox */
  24. -ms-box-sizing: border-box; /* ie */
  25. box-sizing: border-box; /* css3 */
  26. }
  27. .select2-container .select2-choice {
  28. display: block;
  29. height: 26px;
  30. padding: 0 0 0 8px;
  31. overflow: hidden;
  32. position: relative;
  33. border: 1px solid #aaa;
  34. white-space: nowrap;
  35. line-height: 26px;
  36. color: #444;
  37. text-decoration: none;
  38. -webkit-border-radius: 4px;
  39. -moz-border-radius: 4px;
  40. border-radius: 4px;
  41. -webkit-background-clip: padding-box;
  42. -moz-background-clip: padding;
  43. background-clip: padding-box;
  44. background-color: #fff;
  45. background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, #eeeeee), color-stop(0.5, white));
  46. background-image: -webkit-linear-gradient(center bottom, #eeeeee 0%, white 50%);
  47. background-image: -moz-linear-gradient(center bottom, #eeeeee 0%, white 50%);
  48. background-image: -o-linear-gradient(bottom, #eeeeee 0%, #ffffff 50%);
  49. background-image: -ms-linear-gradient(top, #ffffff 0%, #eeeeee 50%);
  50. filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#ffffff', endColorstr = '#eeeeee', GradientType = 0);
  51. background-image: linear-gradient(top, #ffffff 0%, #eeeeee 50%);
  52. }
  53. .select2-container.select2-drop-above .select2-choice {
  54. border-bottom-color: #aaa;
  55. -webkit-border-radius:0 0 4px 4px;
  56. -moz-border-radius:0 0 4px 4px;
  57. border-radius:0 0 4px 4px;
  58. background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, #eeeeee), color-stop(0.9, white));
  59. background-image: -webkit-linear-gradient(center bottom, #eeeeee 0%, white 90%);
  60. background-image: -moz-linear-gradient(center bottom, #eeeeee 0%, white 90%);
  61. background-image: -o-linear-gradient(bottom, #eeeeee 0%, white 90%);
  62. background-image: -ms-linear-gradient(top, #eeeeee 0%,#ffffff 90%);
  63. filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#ffffff', endColorstr='#eeeeee',GradientType=0 );
  64. background-image: linear-gradient(top, #eeeeee 0%,#ffffff 90%);
  65. }
  66. .select2-container .select2-choice span {
  67. margin-right: 26px;
  68. display: block;
  69. overflow: hidden;
  70. white-space: nowrap;
  71. -ms-text-overflow: ellipsis;
  72. -o-text-overflow: ellipsis;
  73. text-overflow: ellipsis;
  74. }
  75. .select2-container .select2-choice abbr {
  76. display: block;
  77. width: 12px;
  78. height: 12px;
  79. position: absolute;
  80. right: 26px;
  81. top: 8px;
  82. font-size: 1px;
  83. text-decoration: none;
  84. border: 0;
  85. background: url('select2.png') right top no-repeat;
  86. cursor: pointer;
  87. outline: 0;
  88. }
  89. .select2-container .select2-choice abbr:hover {
  90. background-position: right -11px;
  91. cursor: pointer;
  92. }
  93. .select2-drop {
  94. width: 100%;
  95. margin-top:-1px;
  96. position: absolute;
  97. z-index: 9999;
  98. top: 100%;
  99. background: #fff;
  100. color: #000;
  101. border: 1px solid #aaa;
  102. border-top: 0;
  103. -webkit-border-radius: 0 0 4px 4px;
  104. -moz-border-radius: 0 0 4px 4px;
  105. border-radius: 0 0 4px 4px;
  106. -webkit-box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
  107. -moz-box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
  108. -o-box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
  109. box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
  110. }
  111. .select2-drop.select2-drop-above {
  112. margin-top: 1px;
  113. border-top: 1px solid #aaa;
  114. border-bottom: 0;
  115. -webkit-border-radius: 4px 4px 0 0;
  116. -moz-border-radius: 4px 4px 0 0;
  117. border-radius: 4px 4px 0 0;
  118. -webkit-box-shadow: 0 -4px 5px rgba(0, 0, 0, .15);
  119. -moz-box-shadow: 0 -4px 5px rgba(0, 0, 0, .15);
  120. -o-box-shadow: 0 -4px 5px rgba(0, 0, 0, .15);
  121. box-shadow: 0 -4px 5px rgba(0, 0, 0, .15);
  122. }
  123. .select2-container .select2-choice div {
  124. display: block;
  125. width: 18px;
  126. height: 100%;
  127. position: absolute;
  128. right: 0;
  129. top: 0;
  130. border-left: 1px solid #aaa;
  131. -webkit-border-radius: 0 4px 4px 0;
  132. -moz-border-radius: 0 4px 4px 0;
  133. border-radius: 0 4px 4px 0;
  134. -webkit-background-clip: padding-box;
  135. -moz-background-clip: padding;
  136. background-clip: padding-box;
  137. background: #ccc;
  138. background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, #ccc), color-stop(0.6, #eee));
  139. background-image: -webkit-linear-gradient(center bottom, #ccc 0%, #eee 60%);
  140. background-image: -moz-linear-gradient(center bottom, #ccc 0%, #eee 60%);
  141. background-image: -o-linear-gradient(bottom, #ccc 0%, #eee 60%);
  142. background-image: -ms-linear-gradient(top, #cccccc 0%, #eeeeee 60%);
  143. filter: progid:DXImageTransform.Microsoft.gradient(startColorstr = '#eeeeee', endColorstr = '#cccccc', GradientType = 0);
  144. background-image: linear-gradient(top, #cccccc 0%, #eeeeee 60%);
  145. }
  146. .select2-container .select2-choice div b {
  147. display: block;
  148. width: 100%;
  149. height: 100%;
  150. background: url('select2.png') no-repeat 0 1px;
  151. }
  152. .select2-search {
  153. display: inline-block;
  154. width: 100%;
  155. min-height: 26px;
  156. margin: 0;
  157. padding-left: 4px;
  158. padding-right: 4px;
  159. position: relative;
  160. z-index: 10000;
  161. white-space: nowrap;
  162. }
  163. .select2-search-hidden {
  164. display: block;
  165. position: absolute;
  166. left: -10000px;
  167. }
  168. .select2-search input {
  169. width: 100%;
  170. height: auto !important;
  171. min-height: 26px;
  172. padding: 4px 20px 4px 5px;
  173. margin: 0;
  174. outline: 0;
  175. font-family: sans-serif;
  176. font-size: 1em;
  177. border: 1px solid #aaa;
  178. -webkit-border-radius: 0;
  179. -moz-border-radius: 0;
  180. border-radius: 0;
  181. -webkit-box-shadow: none;
  182. -moz-box-shadow: none;
  183. box-shadow: none;
  184. background: #fff url('select2.png') no-repeat 100% -22px;
  185. background: url('select2.png') no-repeat 100% -22px, -webkit-gradient(linear, left bottom, left top, color-stop(0.85, white), color-stop(0.99, #eeeeee));
  186. background: url('select2.png') no-repeat 100% -22px, -webkit-linear-gradient(center bottom, white 85%, #eeeeee 99%);
  187. background: url('select2.png') no-repeat 100% -22px, -moz-linear-gradient(center bottom, white 85%, #eeeeee 99%);
  188. background: url('select2.png') no-repeat 100% -22px, -o-linear-gradient(bottom, white 85%, #eeeeee 99%);
  189. background: url('select2.png') no-repeat 100% -22px, -ms-linear-gradient(top, #ffffff 85%, #eeeeee 99%);
  190. background: url('select2.png') no-repeat 100% -22px, linear-gradient(top, #ffffff 85%, #eeeeee 99%);
  191. }
  192. .select2-drop.select2-drop-above .select2-search input {
  193. margin-top: 4px;
  194. }
  195. .select2-search input.select2-active {
  196. background: #fff url('select2-spinner.gif') no-repeat 100%;
  197. background: url('select2-spinner.gif') no-repeat 100%, -webkit-gradient(linear, left bottom, left top, color-stop(0.85, white), color-stop(0.99, #eeeeee));
  198. background: url('select2-spinner.gif') no-repeat 100%, -webkit-linear-gradient(center bottom, white 85%, #eeeeee 99%);
  199. background: url('select2-spinner.gif') no-repeat 100%, -moz-linear-gradient(center bottom, white 85%, #eeeeee 99%);
  200. background: url('select2-spinner.gif') no-repeat 100%, -o-linear-gradient(bottom, white 85%, #eeeeee 99%);
  201. background: url('select2-spinner.gif') no-repeat 100%, -ms-linear-gradient(top, #ffffff 85%, #eeeeee 99%);
  202. background: url('select2-spinner.gif') no-repeat 100%, linear-gradient(top, #ffffff 85%, #eeeeee 99%);
  203. }
  204. .select2-container-active .select2-choice,
  205. .select2-container-active .select2-choices {
  206. border: 1px solid #5897fb;
  207. outline: none;
  208. -webkit-box-shadow: 0 0 5px rgba(0,0,0,.3);
  209. -moz-box-shadow: 0 0 5px rgba(0,0,0,.3);
  210. -o-box-shadow: 0 0 5px rgba(0,0,0,.3);
  211. box-shadow: 0 0 5px rgba(0,0,0,.3);
  212. }
  213. .select2-dropdown-open .select2-choice {
  214. border: 1px solid #aaa;
  215. border-bottom-color: transparent;
  216. -webkit-box-shadow: 0 1px 0 #fff inset;
  217. -moz-box-shadow: 0 1px 0 #fff inset;
  218. -o-box-shadow: 0 1px 0 #fff inset;
  219. box-shadow: 0 1px 0 #fff inset;
  220. -webkit-border-bottom-left-radius: 0;
  221. -moz-border-radius-bottomleft: 0;
  222. border-bottom-left-radius: 0;
  223. -webkit-border-bottom-right-radius: 0;
  224. -moz-border-radius-bottomright: 0;
  225. border-bottom-right-radius: 0;
  226. background-color: #eee;
  227. background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0, white), color-stop(0.5, #eeeeee));
  228. background-image: -webkit-linear-gradient(center bottom, white 0%, #eeeeee 50%);
  229. background-image: -moz-linear-gradient(center bottom, white 0%, #eeeeee 50%);
  230. background-image: -o-linear-gradient(bottom, white 0%, #eeeeee 50%);
  231. background-image: -ms-linear-gradient(top, #ffffff 0%,#eeeeee 50%);
  232. filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#eeeeee', endColorstr='#ffffff',GradientType=0 );
  233. background-image: linear-gradient(top, #ffffff 0%,#eeeeee 50%);
  234. }
  235. .select2-dropdown-open .select2-choice div {
  236. background: transparent;
  237. border-left: none;
  238. filter: none;
  239. }
  240. .select2-dropdown-open .select2-choice div b {
  241. background-position: -18px 1px;
  242. }
  243. /* results */
  244. .select2-results {
  245. max-height: 200px;
  246. padding: 0 0 0 4px;
  247. margin: 4px 4px 4px 0;
  248. position: relative;
  249. overflow-x: hidden;
  250. overflow-y: auto;
  251. }
  252. .select2-results ul.select2-result-sub {
  253. margin: 0;
  254. }
  255. .select2-results ul.select2-result-sub > li .select2-result-label { padding-left: 20px }
  256. .select2-results ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 40px }
  257. .select2-results ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 60px }
  258. .select2-results ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 80px }
  259. .select2-results ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 100px }
  260. .select2-results ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 110px }
  261. .select2-results ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub ul.select2-result-sub > li .select2-result-label { padding-left: 120px }
  262. .select2-results li {
  263. list-style: none;
  264. display: list-item;
  265. background-image: none;
  266. }
  267. .select2-results li.select2-result-with-children > .select2-result-label {
  268. font-weight: bold;
  269. }
  270. .select2-results .select2-result-label {
  271. padding: 3px 7px 4px;
  272. margin: 0;
  273. cursor: pointer;
  274. }
  275. .select2-results .select2-highlighted {
  276. background: #3875d7;
  277. color: #fff;
  278. }
  279. .select2-results li em {
  280. background: #feffde;
  281. font-style: normal;
  282. }
  283. .select2-results .select2-highlighted em {
  284. background: transparent;
  285. }
  286. .select2-results .select2-no-results,
  287. .select2-results .select2-searching,
  288. .select2-results .select2-selection-limit {
  289. background: #f4f4f4;
  290. display: list-item;
  291. }
  292. /*
  293. disabled look for already selected choices in the results dropdown
  294. .select2-results .select2-disabled.select2-highlighted {
  295. color: #666;
  296. background: #f4f4f4;
  297. display: list-item;
  298. cursor: default;
  299. }
  300. .select2-results .select2-disabled {
  301. background: #f4f4f4;
  302. display: list-item;
  303. cursor: default;
  304. }
  305. */
  306. .select2-results .select2-disabled {
  307. display: none;
  308. }
  309. .select2-more-results.select2-active {
  310. background: #f4f4f4 url('select2-spinner.gif') no-repeat 100%;
  311. }
  312. .select2-more-results {
  313. background: #f4f4f4;
  314. display: list-item;
  315. }
  316. /* disabled styles */
  317. .select2-container.select2-container-disabled .select2-choice {
  318. background-color: #f4f4f4;
  319. background-image: none;
  320. border: 1px solid #ddd;
  321. cursor: default;
  322. }
  323. .select2-container.select2-container-disabled .select2-choice div {
  324. background-color: #f4f4f4;
  325. background-image: none;
  326. border-left: 0;
  327. }
  328. .select2-container.select2-container-disabled .select2-choice abbr {
  329. display: none
  330. }
  331. /* multiselect */
  332. .select2-container-multi .select2-choices {
  333. height: auto !important;
  334. height: 1%;
  335. margin: 0;
  336. padding: 0;
  337. position: relative;
  338. border: 1px solid #aaa;
  339. cursor: text;
  340. overflow: hidden;
  341. background-color: #fff;
  342. background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, color-stop(1%, #eeeeee), color-stop(15%, #ffffff));
  343. background-image: -webkit-linear-gradient(top, #eeeeee 1%, #ffffff 15%);
  344. background-image: -moz-linear-gradient(top, #eeeeee 1%, #ffffff 15%);
  345. background-image: -o-linear-gradient(top, #eeeeee 1%, #ffffff 15%);
  346. background-image: -ms-linear-gradient(top, #eeeeee 1%, #ffffff 15%);
  347. background-image: linear-gradient(top, #eeeeee 1%, #ffffff 15%);
  348. }
  349. .select2-locked {
  350. padding: 3px 5px 3px 5px !important;
  351. }
  352. .select2-container-multi .select2-choices {
  353. min-height: 26px;
  354. }
  355. .select2-container-multi.select2-container-active .select2-choices {
  356. border: 1px solid #5897fb;
  357. outline: none;
  358. -webkit-box-shadow: 0 0 5px rgba(0,0,0,.3);
  359. -moz-box-shadow: 0 0 5px rgba(0,0,0,.3);
  360. -o-box-shadow: 0 0 5px rgba(0,0,0,.3);
  361. box-shadow: 0 0 5px rgba(0,0,0,.3);
  362. }
  363. .select2-container-multi .select2-choices li {
  364. float: left;
  365. list-style: none;
  366. }
  367. .select2-container-multi .select2-choices .select2-search-field {
  368. margin: 0;
  369. padding: 0;
  370. white-space: nowrap;
  371. }
  372. .select2-container-multi .select2-choices .select2-search-field input {
  373. height: 15px;
  374. padding: 5px;
  375. margin: 1px 0;
  376. font-family: sans-serif;
  377. font-size: 100%;
  378. color: #666;
  379. outline: 0;
  380. border: 0;
  381. -webkit-box-shadow: none;
  382. -moz-box-shadow: none;
  383. -o-box-shadow: none;
  384. box-shadow: none;
  385. background: transparent !important;
  386. }
  387. .select2-container-multi .select2-choices .select2-search-field input.select2-active {
  388. background: #fff url('select2-spinner.gif') no-repeat 100% !important;
  389. }
  390. .select2-default {
  391. color: #999 !important;
  392. }
  393. .select2-container-multi .select2-choices .select2-search-choice {
  394. padding: 3px 5px 3px 18px;
  395. margin: 3px 0 3px 5px;
  396. position: relative;
  397. line-height: 13px;
  398. color: #333;
  399. cursor: default;
  400. border: 1px solid #aaaaaa;
  401. -webkit-border-radius: 3px;
  402. -moz-border-radius: 3px;
  403. border-radius: 3px;
  404. -webkit-box-shadow: 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05);
  405. -moz-box-shadow: 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05);
  406. box-shadow: 0 0 2px #ffffff inset, 0 1px 0 rgba(0,0,0,0.05);
  407. -webkit-background-clip: padding-box;
  408. -moz-background-clip: padding;
  409. background-clip: padding-box;
  410. background-color: #e4e4e4;
  411. filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#eeeeee', endColorstr='#f4f4f4', GradientType=0 );
  412. background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), color-stop(100%, #eeeeee));
  413. background-image: -webkit-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);
  414. background-image: -moz-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);
  415. background-image: -o-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);
  416. background-image: -ms-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);
  417. background-image: linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eeeeee 100%);
  418. }
  419. .select2-container-multi .select2-choices .select2-search-choice span {
  420. cursor: default;
  421. }
  422. .select2-container-multi .select2-choices .select2-search-choice-focus {
  423. background: #d4d4d4;
  424. }
  425. .select2-search-choice-close {
  426. display: block;
  427. width: 12px;
  428. height: 13px;
  429. position: absolute;
  430. right: 3px;
  431. top: 4px;
  432. font-size: 1px;
  433. outline: none;
  434. background: url('select2.png') right top no-repeat;
  435. }
  436. .select2-container-multi .select2-search-choice-close {
  437. left: 3px;
  438. }
  439. .select2-container-multi .select2-choices .select2-search-choice .select2-search-choice-close:hover {
  440. background-position: right -11px;
  441. }
  442. .select2-container-multi .select2-choices .select2-search-choice-focus .select2-search-choice-close {
  443. background-position: right -11px;
  444. }
  445. /* disabled styles */
  446. .select2-container-multi.select2-container-disabled .select2-choices{
  447. background-color: #f4f4f4;
  448. background-image: none;
  449. border: 1px solid #ddd;
  450. cursor: default;
  451. }
  452. .select2-container-multi.select2-container-disabled .select2-choices .select2-search-choice {
  453. padding: 3px 5px 3px 5px;
  454. border: 1px solid #ddd;
  455. background-image: none;
  456. background-color: #f4f4f4;
  457. }
  458. .select2-container-multi.select2-container-disabled .select2-choices .select2-search-choice .select2-search-choice-close {
  459. display: none;
  460. }
  461. /* end multiselect */
  462. .select2-result-selectable .select2-match,
  463. .select2-result-unselectable .select2-result-selectable .select2-match {
  464. text-decoration: underline;
  465. }
  466. .select2-result-unselectable .select2-match {
  467. text-decoration: none;
  468. }
  469. .select2-offscreen {
  470. position: absolute;
  471. left: -10000px;
  472. }
  473. /* Retina-ize icons */
  474. @media only screen and (-webkit-min-device-pixel-ratio: 1.5), only screen and (min-resolution: 144dpi) {
  475. .select2-search input, .select2-search-choice-close, .select2-container .select2-choice abbr, .select2-container .select2-choice div b {
  476. background-image: url('select2x2.png') !important;
  477. background-repeat: no-repeat !important;
  478. background-size: 60px 40px !important;
  479. }
  480. .select2-search input {
  481. background-position: 100% -21px !important;
  482. }
  483. }