forked from FormstoneClassic/Selecter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jquery.fs.selecter.css
68 lines (56 loc) · 3.71 KB
/
jquery.fs.selecter.css
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/*
* Selecter Plugin [Formstone Library]
* @author Ben Plum
* @version 1.9.8
*
* Copyright © 2013 Ben Plum <mr@benplum.com>
* Released under the MIT License <http://www.opensource.org/licenses/mit-license.php>
*/
.selecter-element { *left: -999999px; position: absolute; opacity: 0; }
.selecter { display: block; margin: 10px 0; position: relative; max-width: 30%; z-index: 1; }
.selecter .selecter-selected { background: #F9F9F9 url(fs-selecter-arrow.png) no-repeat right center; border: 1px solid #ccc; border-radius: 3px; color: #333; cursor: pointer; display: block; font-size: 13px; margin: 0; overflow: hidden; padding: 8px 10px; position: relative; text-overflow: clip; z-index: 49; }
.selecter .selecter-options { border: 1px solid #ccc; border-width: 0 1px 1px; background-color: #fefefe; border-radius: 0 0 3px 3px; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15); display: none; left: 0; margin: 0; max-height: 260px; overflow: auto; overflow-x: hidden; padding: 0; position: absolute; top: 100%; width: 100%; *width: auto; z-index: 50; }
.selecter .selecter-group { background: #F9F9F9; border-bottom: 1px solid #e3e3e3; color: #999; display: block; font-size: 11px; padding: 5px 10px 4px; text-transform: uppercase; }
.selecter .selecter-item { background: #fff; border-bottom: 1px solid #e3e3e3; color: #666; cursor: pointer; display: block; font-size: 13px; margin: 0; overflow: hidden; padding: 8px 10px; text-overflow: ellipsis; width: 100%; }
.selecter .selecter-item.selected { background: #F9F9F9; }
.selecter .selecter-item.first { border-radius: 0; }
.selecter .selecter-item.last { border-radius: 0 0 2px 2px; border-bottom: 0; }
@media screen and (min-width: 740px) {
.selecter .selecter-item:hover,
.selecter .selecter-item.selected:hover { background-color: #f3f3f3; }
.selecter:hover .selecter-selected { background-color: #fff; }
.selecter.disabled .selecter-item:hover { background: #fff; }
}
/* Open */
.selecter.open { z-index: 3; }
.selecter.open .selecter-selected { border-radius: 3px 3px 0 0; z-index: 51; }
.selecter.open .selecter-selected,
.selecter.focus .selecter-selected { background-color: #fff; }
/* 'Cover' Positioning */
.selecter.cover .selecter-options { border-radius: 3px; border-width: 1px; top: 0; }
.selecter.cover .selecter-options .selecter-item.first { border-radius: 3px 3px 0 0; }
.selecter.cover.open .selecter-selected { border-radius: 3px 3px 0 0; z-index: 49; }
/* 'Bottom' Positioning */
.selecter.bottom .selecter-options { border-width: 1px 1px 0; bottom: 100%; top: auto; }
.selecter.bottom .selecter-item.last { border: none; }
.selecter.bottom.open .selecter-selected { border-radius: 0 0 3px 3px; }
.selecter.bottom.open .selecter-options { border-radius: 3px 3px 0 0; }
/* 'Bottom' + 'Cover' Positioning */
.selecter.bottom.cover .selecter-options { bottom: 0; top: auto; }
.selecter.bottom.cover.open .selecter-selected { border-radius: 3px; }
.selecter.bottom.cover.open .selecter-options { border-radius: 3px; }
/* Multiple Select */
.selecter.multiple .selecter-options { border-radius: 3px; border-width: 1px; box-shadow: none; display: block; position: static; width: 100%; }
/* 'Disabled' State */
.selecter.disabled .selecter-selected { background: #fff; border-color: #eee; color: #ccc; cursor: default; }
.selecter.disabled .selecter-options { background: #fff; border-color: #eee; }
.selecter.disabled .selecter-group,
.selecter.disabled .selecter-item { border-color: #eee; color: #ccc; cursor: default; }
.selecter.disabled .selecter-item.selected { background: #fafafa; }
/* Media Queries */
@media screen and (max-width: 740px) {
.selecter { max-width: 40%; }
}
@media screen and (max-width: 500px) {
.selecter { max-width: 100%; }
}