forked from jskopek/backbone-folder-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tree.dev.css
165 lines (150 loc) · 4.04 KB
/
tree.dev.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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
/* Copyright (c) 2012 Top Hat Monocle, http://tophatmonocle.com/
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
* INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
* PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
* AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.*/
.tree {
overflow-y: auto;
overflow-x: hidden;
}
.tree::-webkit-scrollbar {
cursor: pointer;
background-color: #AAA;
border-radius: 0 3px 3px 0;
width: 9px;
}
.tree::-webkit-scrollbar-thumb {
cursor: pointer;
background-color: #666;
border-radius: 0 3px 3px 0;
}
.tree ol {
margin: 0;
padding: 0;
}
.tree ol li {
list-style: none;
}
.tree_row {
/*border-top: 1px solid #eee;*/
}
.tree > ol > .tree_row:first-child {
border-top: none;
}
.tree_row > div {
overflow: hidden;
padding-bottom: 4px;
padding-top: 2px;
border-top: 1px solid #ddd;
position: relative;
top: -1px;
background: #fff;
}
.tree_row > div em {
font-style: normal;
}
.tree .empty {
font-style: italic;
padding: .3em;
color: #444
}
.tree_row.placeholder { background: #eee; }
/* spacing for items in tree */
.tree_row > div {
padding-left: 3px;
}
.tree_row > div input[type=checkbox],
.tree_row > div a.toggle_hide,
.tree_row > div em span {
margin-right: 5px;
}
/* drag effect */
.tree .ui-sortable-helper {
width: 200px;
border: 1px solid #000;
cursor: pointer;
}
/*
folder details
*/
li.folder > .folder_details a.toggle_hide,
li.folder > .folder_details em span {
background-image: url(tree_sprite.png);
background-repeat: no-repeat;
text-indent: -5000px;
display: inline-block;
height: 16px;
width: 14px;
/*margin: 0 3px;*/
line-height: 1em;
}
li.folder.hidden > .folder_details a.toggle_hide {
background-position: 0 -14px;
}
li.folder > .folder_details a.toggle_hide {
background-position: -14px -14px;
}
li.folder > .folder_details em span {
background-position: -14px 0px;
}
li.folder.hidden > .folder_details em span {
background-position: 0px 0px;
}
/* answered */
ol > li div .answered {
display: none;
}
/* folder status */
/*ol > li div {*/
/*position: relative;*/
/*padding-right: 30px;*/
/*}*/
/*ol > li div .status {*/
/*position: absolute;*/
/*top: 2px;*/
/*right: 5px;*/
/*display: block;*/
/*width: 30px;*/
/*height: 25px;*/
/*background: red;*/
/*text-indent: -5000px;*/
/*}*/
/*
hide children of a hidden folder, but do not hide the
list itself - this allows us to hover over and drop items into
hidden folders
*/
ol.hidden > li { display: none; }
/*
nested folder widths for up to 5 layers of folders
we set the
*/
ol > li.placeholder.ui-nestedSortable-error { margin-left: 0px; }
ol > li li.placeholder,
ol > li li li li.placeholder.ui-nestedSortable-error,
ol > li li div { margin-left: 20px; }
ol > li li li.placeholder,
ol > li li li li.placeholder.ui-nestedSortable-error,
ol > li li li div { margin-left: 40px; }
ol > li li li li.placeholder,
ol > li li li li li.placeholder.ui-nestedSortable-error,
ol > li li li li div { margin-left: 60px; }
ol > li li li li li.placeholder,
ol > li li li li li li.placeholder.ui-nestedSortable-error,
ol > li li li li li div { margin-left: 80px; }
ol > li li li li li li.placeholder,
ol > li li li li li li li.placeholder.ui-nestedSortable-error,
ol > li li li li li li div { margin-left: 100px; }