select2.css 18 KB

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