blob: 72f274245d45547d0d058d41a92c674820c984f8 [file] [log] [blame]
Nils Diewalda944fab2015-04-08 21:02:04 +00001@charset "utf-8";
Nils Diewaldab4d3ca2015-04-17 01:48:43 +00002@import "../util";
Nils Diewalda944fab2015-04-08 21:02:04 +00003
Nils Diewald359a72c2015-04-20 17:40:29 +00004$left-padding: 4em; // 32pt; // 2.8em;
Nils Diewalda944fab2015-04-08 21:02:04 +00005$border-size: 2px;
Nils Diewald359a72c2015-04-20 17:40:29 +00006$bracket-size: .4em; // 4pt;
Nils Diewalda944fab2015-04-08 21:02:04 +00007
Nils Diewald359a72c2015-04-20 17:40:29 +00008/**
9 * Virtual Collection Builder
10 */
Akron5c829e92017-05-12 18:10:00 +020011
Nils Diewalda944fab2015-04-08 21:02:04 +000012.vc {
Nils Diewald359a72c2015-04-20 17:40:29 +000013 margin-top: 4pt;
14
15 /**
16 * Rules for all docGroups
17 */
Nils Diewalda944fab2015-04-08 21:02:04 +000018 .docGroup {
19 position: relative;
20 display: inline-block;
Nils Diewald359a72c2015-04-20 17:40:29 +000021 margin-left: $left-padding; // 28pt
22
23 .docGroup { display: block; }
24
Nils Diewalda944fab2015-04-08 21:02:04 +000025 color: $nearly-white;
Nils Diewald359a72c2015-04-20 17:40:29 +000026 padding: 4pt 2pt 4pt 0pt;
Nils Diewalda944fab2015-04-08 21:02:04 +000027 border: {
28 radius: $standard-border-radius * 2;
29 style: solid;
Nils Diewald359a72c2015-04-20 17:40:29 +000030 width: 0 $bracket-size; // .6em .5em
Nils Diewalda944fab2015-04-08 21:02:04 +000031 }
32
hebasta2d2f6952018-06-29 14:26:00 +020033
Nils Diewald359a72c2015-04-20 17:40:29 +000034 // Whiten on hover
35 &:hover {
36 background-color: rgba(255,255,255,.06);
Nils Diewalda944fab2015-04-08 21:02:04 +000037 }
38
Nils Diewald359a72c2015-04-20 17:40:29 +000039 &[data-operation] {
40 > .doc:first-child::before,
41 > .docGroup:first-child::before {
Akron76c3dd62018-05-29 20:58:27 +020042 content: none;
Nils Diewald359a72c2015-04-20 17:40:29 +000043 }
44 > .doc::before,
45 > .docGroup::before {
Akron76c3dd62018-05-29 20:58:27 +020046 display: inline-block;
47 position: absolute;
48 text-align: right;
49 width: $left-padding;
50 margin-left: -1 * ($left-padding + .5em); // -28pt
51 color: $dark-green;
52 line-height: 1.5em;
53 border-top: $border-size solid transparent;
Nils Diewald359a72c2015-04-20 17:40:29 +000054 }
55 > .docGroup::before {
Akron76c3dd62018-05-29 20:58:27 +020056 margin-left: -1 * ($left-padding + .5em) + (-1 * $bracket-size);
Nils Diewald359a72c2015-04-20 17:40:29 +000057 }
58 }
59
60 // Or operation
61 &[data-operation=or] {
62 border-color: $dark-orange;
63 > .doc::before,
64 > .docGroup::before {
Akron76c3dd62018-05-29 20:58:27 +020065 // This will be overruled by JS!
66 content: "or";
Nils Diewald359a72c2015-04-20 17:40:29 +000067 }
hebasta2d2f6952018-06-29 14:26:00 +020068
69 &:after {
70 .button-stat {
71
72
73
74 > span {
75 cursor: pointer;
76 box-shadow: $choose-box-shadow;
77 font-size: 9pt;
78 line-height: 1.5em;
79 padding: 0 4px;
80 display: inline-block;
81 @include choose-item;
82 border-style: solid;
83 border-width: $border-size 0;
84 &:hover {
85 @include choose-hover;
86 }
87 &:first-child {
88 border: {
89 left-width: $border-size;
90 right-width: $border-size;
91 }
92 }
93
94 }
95}
96
97
98 }
Nils Diewald359a72c2015-04-20 17:40:29 +000099 }
100
101 // And operation
102 &[data-operation=and] {
103 > .doc::before,
104 > .docGroup::before {
Akron76c3dd62018-05-29 20:58:27 +0200105 // This will be overruled by JS!
106 content: "and";
Nils Diewald359a72c2015-04-20 17:40:29 +0000107 }
108 }
109
110
111 /**
112 * All operators on groups
113 */
Nils Diewalda944fab2015-04-08 21:02:04 +0000114 > .operators {
115 position: absolute;
116 display: block;
117 top: 10px;
118 vertical-align: middle;
119 left: 3px;
Nils Diewald359a72c2015-04-20 17:40:29 +0000120 > span:first-child {
Akron76c3dd62018-05-29 20:58:27 +0200121 border: {
122 top-left-radius: 0;
123 bottom-left-radius: 0;
124 }
Nils Diewald359a72c2015-04-20 17:40:29 +0000125 }
Nils Diewalda944fab2015-04-08 21:02:04 +0000126 margin-left: 100%;
127 padding: 0;
128 }
Nils Diewalda944fab2015-04-08 21:02:04 +0000129 }
130
Nils Diewald359a72c2015-04-20 17:40:29 +0000131
132 /**
133 * All document rules
134 */
Nils Diewalda944fab2015-04-08 21:02:04 +0000135 .doc {
Nils Diewald359a72c2015-04-20 17:40:29 +0000136 padding-left: $left-padding;
Nils Diewald4c221252015-04-21 20:19:25 +0000137 > span + span,
Akron79452372018-04-11 14:24:19 +0200138 > span + div + span,
139 > span + ul + span {
Nils Diewalda944fab2015-04-08 21:02:04 +0000140 margin-left: 5pt;
141 }
Nils Diewald9c125062015-05-05 23:54:17 +0000142
Nils Diewalda944fab2015-04-08 21:02:04 +0000143 > span.key,
144 > span.value {
145 font-weight: bold;
Nils Diewald9c125062015-05-05 23:54:17 +0000146 &[data-type=regex] {
Akron76c3dd62018-05-29 20:58:27 +0200147 font-style: italic;
148 &::after,
149 &::before {
150 content: '/';
151 }
Nils Diewald9c125062015-05-05 23:54:17 +0000152 }
Nils Diewalda944fab2015-04-08 21:02:04 +0000153 }
Nils Diewald359a72c2015-04-20 17:40:29 +0000154
155 /**
156 * All operators on docs
157 */
Nils Diewalda944fab2015-04-08 21:02:04 +0000158 > .operators {
159 display: inline-block;
Nils Diewalda944fab2015-04-08 21:02:04 +0000160 margin-left: 10px;
Nils Diewalda944fab2015-04-08 21:02:04 +0000161 }
162 > span.key {
163 position: relative;
164 > ul {
Akron76c3dd62018-05-29 20:58:27 +0200165 margin: 0;
166 margin-left: 3.3em;
Nils Diewalda944fab2015-04-08 21:02:04 +0000167 }
168 }
169 }
170
171 .rewritten {
172 .rewrite {
173 margin-left: 4pt;
174 display: inline-block;
175 color: $dark-orange;
176 &::after {
Akron76c3dd62018-05-29 20:58:27 +0200177 font: {
178 family: FontAwesome;
179 style: normal;
180 weight: normal;
181 }
182 content: $fa-rewrite;
183 text-decoration: underline;
Nils Diewalda944fab2015-04-08 21:02:04 +0000184 }
Akron76c3dd62018-05-29 20:58:27 +0200185 > span {
186 display: none;
Nils Diewalda944fab2015-04-08 21:02:04 +0000187 }
188 }
189 }
190
Nils Diewald4c221252015-04-21 20:19:25 +0000191 .doc > span {
Nils Diewald1fcb2ad2015-04-20 19:19:18 +0000192 cursor: pointer;
Nils Diewald4c221252015-04-21 20:19:25 +0000193 &:hover {
194 color: $dark-green;
195 }
Nils Diewald1fcb2ad2015-04-20 19:19:18 +0000196 }
197
Nils Diewald359a72c2015-04-20 17:40:29 +0000198 /**
199 * All operators
200 */
Nils Diewalda944fab2015-04-08 21:02:04 +0000201 .operators {
202 opacity: 0;
203 white-space: nowrap;
204 padding: 0;
205 font-size: 0;
206 line-height: 0;
Nils Diewalda944fab2015-04-08 21:02:04 +0000207 text-align: center;
Nils Diewalda944fab2015-04-08 21:02:04 +0000208 }
209
210 > .docGroup {
211 margin-left: 0;
212 }
213
Nils Diewalda944fab2015-04-08 21:02:04 +0000214 .doc, .docGroup {
215 &:hover > .operators {
216 opacity: 1;
217 }
218 }
219
Nils Diewald4c221252015-04-21 20:19:25 +0000220 .menu {
221 display: inline-block;
222 }
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000223
224 div.value {
225 position: absolute;
226 display: inline-block;
Akronc1457bf2015-06-11 19:24:00 +0200227 z-index: 8000;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000228 @include choose-item;
229 box-shadow: $choose-box-shadow;
230 padding: 4pt;
Akronc1457bf2015-06-11 19:24:00 +0200231 margin-top: -6pt;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000232 border: {
233 width: $border-size;
234 style: solid;
235 radius: $standard-border-radius;
236 }
237 input {
238 border-width: 0;
239 }
240 > div {
241 padding: 2pt;
242 cursor: pointer;
243 font: {
Akron76c3dd62018-05-29 20:58:27 +0200244 size: 80%;
245 style: italic;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000246 }
247 display: inline-block;
248 @include choose-item;
249 border: {
Akron76c3dd62018-05-29 20:58:27 +0200250 width: $border-size;
251 style: solid;
252 radius: $standard-border-radius;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000253 }
254
255 &:hover {
Akron76c3dd62018-05-29 20:58:27 +0200256 @include choose-hover;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000257 }
258 }
259 &.regex {
Nils Diewald9c125062015-05-05 23:54:17 +0000260 > input {
Akron76c3dd62018-05-29 20:58:27 +0200261 font-style: italic;
Nils Diewald9c125062015-05-05 23:54:17 +0000262 }
263
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000264 > div {
Akron76c3dd62018-05-29 20:58:27 +0200265 @include choose-active;
Nils Diewaldc4c4b832015-05-05 16:00:08 +0000266 }
267 }
268 }
Nils Diewalda944fab2015-04-08 21:02:04 +0000269}
270
271
Nils Diewald359a72c2015-04-20 17:40:29 +0000272/**
273 * The z-index cascade for groups.
274 */
Nils Diewalda944fab2015-04-08 21:02:04 +0000275$dg-index : 30;
Nils Diewalda944fab2015-04-08 21:02:04 +0000276.docGroup {
277 > .operators {
278 z-index: $dg-index;
279 }
280 .docGroup {
281 > .operators {
282 z-index: $dg-index + 1;
283 }
284 .docGroup {
285 > .operators {
Akron76c3dd62018-05-29 20:58:27 +0200286 z-index: $dg-index + 2;
Nils Diewalda944fab2015-04-08 21:02:04 +0000287 }
288 .docGroup {
Akron76c3dd62018-05-29 20:58:27 +0200289 > .operators {
290 z-index: $dg-index + 3;
291 }
292 .docGroup {
293 > .operators {
294 z-index: $dg-index + 4;
295 }
296 .docGroup {
297 > .operators {
298 z-index: $dg-index + 5;
299 }
300 .docGroup {
301 > .operators {
302 z-index: $dg-index + 6;
303 }
304 }
305 }
306 }
Nils Diewalda944fab2015-04-08 21:02:04 +0000307 }
308 }
309 }
310}
Nils Diewaldfccfbcb2015-04-29 20:48:19 +0000311
Akronc1457bf2015-06-11 19:24:00 +0200312#collection {
Nils Diewald7148c6f2015-05-04 15:07:53 +0000313 line-height: 1em;
314 border-radius: $standard-border-radius;
315}
Nils Diewaldfccfbcb2015-04-29 20:48:19 +0000316
Akron5c829e92017-05-12 18:10:00 +0200317
318#vc-choose > span.rewritten {
Nils Diewaldfccfbcb2015-04-29 20:48:19 +0000319 &::after {
Akron5c829e92017-05-12 18:10:00 +0200320 color: $dark-orange;
321 padding: 0;
322 padding-left: 4px;
Akron76c3dd62018-05-29 20:58:27 +0200323 font: {
324 family: FontAwesome;
325 style: normal;
326 weight: normal;
327 }
328 content: $fa-rewrite;
329 text-decoration: underline;
Nils Diewaldfccfbcb2015-04-29 20:48:19 +0000330 }
Akron6bb71582016-06-10 20:41:08 +0200331}
hebasta2d2f6952018-06-29 14:26:00 +0200332
333div.stattable{
334 display: flex;
335 flex-direction: row;
336 }
337
338div.stattable ul.action.image {
339 display: block;
340 li {
341 cursor: pointer;
342 color: $nearly-white;
343 text-decoration: none;
344 > span {
345 @include blind;
346 }
347 border-width: 0;
348 // z-index: 8;
349 text-decoration:none;
350 text-align: center;
351 font-style: normal;
352
353 &.close::after {
354 font-family: 'FontAwesome';
355 content: $fa-close;
356 }
357 }
358}
359
360
361div.stattable > dl {
362 display: flex;
363 flex-flow: row wrap;
364 background-color: $dark-green;
365 //margin-top: 4 * $border-size !important;
366 margin-top:4px;
367 padding-bottom: 0;
368 > div {
369 display: flex;
370 margin-right: 5px;
371 margin-left: 5px;
372 > dt {
373 text-align: right;
374 padding: 1px;
375 margin: 0;
376 &:after {
377 content: ":";
378 }
379 }
380 > dd {
381 text-align: left;
382 padding: 1px;
383 margin: 0;
384 width: 100%;
385 max-width: none;
386 max-height: 6em;
387 margin-left: $border-size;
388 }
389 }
390}
391
392
393
394// TODO -> button-group
395.button-stat {
396 > span {
397 cursor: pointer;
398 //box-shadow: $choose-box-shadow;
399 font-size: 9pt;
400 line-height: 1.5em;
401 padding: 0 4px;
402 display: inline-block;
403 border-top-left-radius: $standard-border-radius;
404 border-bottom-right-radius: $standard-border-radius;
405 border-top-right-radius: $standard-border-radius;
406 border-bottom-left-radius: $standard-border-radius;
407 background-color: $light-grey;
408 border-style: solid;
409
410 border-width: $border-size 0;
411 margin-top:10px;
412 color: $choose-color;
413
414 border-color: $choose-border-color;
415
416 &:hover {
417 @include choose-hover;
418 }
419 &:first-child {
420 border: {
421 left-width: $border-size;
422 right-width: $border-size;
423 }
424 }
425
426 }
427}