root / snf-cyclades-app / synnefo / ui / new_ui / ui / sass / _common.scss @ eda4930e
History | View | Annotate | Download (12.8 kB)
1 |
/* Table of Contents |
---|---|
2 |
|
3 |
- Clearfix |
4 |
- Mixins |
5 |
- Buttons and Links |
6 |
- Layout |
7 |
- Header |
8 |
- Actions Bar |
9 |
- Icon Navigation |
10 |
- Top Info |
11 |
- Progress Bar |
12 |
- Responsive |
13 |
- Scroll Bar |
14 |
- Images from sprites |
15 |
|
16 |
*/ |
17 |
|
18 |
/* Clearfix -------------------------------------------- */ |
19 |
|
20 |
.clearfix { |
21 |
zoom:1; |
22 |
&:before, &:after { |
23 |
content: "\0020"; |
24 |
display: block; |
25 |
height: 0; |
26 |
overflow: hidden; |
27 |
} |
28 |
&:after { |
29 |
clear: both; |
30 |
} |
31 |
} |
32 |
|
33 |
/* Mixins ----------------------------------------------- */ |
34 |
|
35 |
@mixin marginPaddingZero() { |
36 |
margin: 0; |
37 |
padding: 0; |
38 |
} |
39 |
|
40 |
|
41 |
// Establishes the prequisits for sprite with background-image. |
42 |
// Background-position for normal and hover states need to |
43 |
// be declared separetely |
44 |
@mixin sprite($image, $width, $height){ |
45 |
background:url($image) no-repeat center center; |
46 |
width: $width; |
47 |
height:$height; |
48 |
display: inline-block; |
49 |
text-indent: -2000px; |
50 |
overflow: hidden; |
51 |
|
52 |
} |
53 |
|
54 |
// Transition for css properties |
55 |
@mixin transition($transition-property, $transition-time, $method) { |
56 |
-webkit-transition: $transition-property $transition-time $method; |
57 |
-moz-transition: $transition-property $transition-time $method; |
58 |
-ms-transition: $transition-property $transition-time $method; |
59 |
-o-transition: $transition-property $transition-time $method; |
60 |
transition: $transition-property $transition-time $method; |
61 |
} |
62 |
|
63 |
// Box-shadow property. For no box-shadow use box-shadow(none) |
64 |
@mixin box-shadow($shadows...) { |
65 |
-moz-box-shadow: $shadows; |
66 |
-webkit-box-shadow: $shadows; |
67 |
box-shadow: $shadows; |
68 |
} |
69 |
|
70 |
@mixin placeholder { |
71 |
&.placeholder { @content; } |
72 |
&:-moz-placeholder { @content; } |
73 |
&::-moz-placeholder { @content; } |
74 |
&::-webkit-input-placeholder { @content; } |
75 |
} |
76 |
|
77 |
// keyframes mixin |
78 |
@mixin keyframes($name) { |
79 |
@-webkit-keyframes #{$name} { |
80 |
@content; |
81 |
} |
82 |
@-moz-keyframes #{$name} { |
83 |
@content; |
84 |
} |
85 |
@-ms-keyframes #{$name} { |
86 |
@content; |
87 |
} |
88 |
@keyframes #{$name} { |
89 |
@content; |
90 |
} |
91 |
} |
92 |
|
93 |
|
94 |
// style .lt-bar |
95 |
|
96 |
@mixin ltbar($width:$lt-bar-width, $bgcolor: #fff ){ |
97 |
position: fixed; |
98 |
width: $width; |
99 |
left:50%; |
100 |
top:$header-height + $bar-height; |
101 |
padding:15px 10px; |
102 |
margin-left:-($row-width - 2*$main-padding-horizontal)/2; |
103 |
@include box-shadow(3px -2px 8px #ccc); |
104 |
background: $bgcolor; |
105 |
z-index: 3; |
106 |
} |
107 |
|
108 |
@mixin square($side, $bgcolor) { |
109 |
width: $side; |
110 |
height: $side; |
111 |
background-color: $bgcolor; |
112 |
display: inline-block; |
113 |
} |
114 |
|
115 |
@mixin circle($radius, $bgcolor: $primary-color) { |
116 |
display:inline-block; |
117 |
-webkit-border-radius: 999px; |
118 |
-moz-border-radius: 999px; |
119 |
border-radius: 999px; |
120 |
width: $radius * 2; |
121 |
height: $radius * 2; |
122 |
background-color: $bgcolor; |
123 |
behavior: url(PIE.htc); |
124 |
} |
125 |
|
126 |
@mixin stateColor($color) { |
127 |
.img-wrap { |
128 |
.snf-pc-full, |
129 |
.snf-network-full, .snf-font { |
130 |
color:$color; |
131 |
} |
132 |
} |
133 |
.status { |
134 |
color: $color; |
135 |
} |
136 |
} |
137 |
|
138 |
/* Circle and Tags ----------------------------------------------- */ |
139 |
|
140 |
|
141 |
.tags { |
142 |
text-align:center; |
143 |
.tag { |
144 |
@include circle(6px); |
145 |
margin:0 3px; |
146 |
&.tag1 { background-color:$error-color;} |
147 |
&.tag2 { background-color:$success-color;} |
148 |
&.tag3 { background-color:$alert-color;} |
149 |
} |
150 |
} |
151 |
|
152 |
|
153 |
/* Buttons and Links ----------------------------------------------- */ |
154 |
|
155 |
|
156 |
a { |
157 |
color:$link-color; |
158 |
&:hover, &.current, &.active { |
159 |
color:$link-color-hover; |
160 |
@include transition(background, 300ms, ease-out); |
161 |
} |
162 |
|
163 |
|
164 |
} |
165 |
|
166 |
.inactive { |
167 |
color:$inactive-color!important; |
168 |
&:hover { |
169 |
color:$inactive-color; |
170 |
cursor:default; |
171 |
} |
172 |
} |
173 |
|
174 |
.btn1 { |
175 |
border:1px solid $link-color; |
176 |
color:$link-color; |
177 |
display:inline-block; |
178 |
height:$btn-height; |
179 |
text-align:center; |
180 |
font-size:emCalc(12px); |
181 |
&:hover, |
182 |
&:focus { |
183 |
color: $link-color; |
184 |
span { |
185 |
border-color: $link-color; |
186 |
} |
187 |
} |
188 |
&.current { |
189 |
span { |
190 |
background-color: $link-color; |
191 |
} |
192 |
color:#fff; |
193 |
} |
194 |
span { |
195 |
border: 1px solid transparent; |
196 |
display: block; |
197 |
padding:0 20px; |
198 |
line-height:$btn-height - 4px; |
199 |
height:100%; |
200 |
|
201 |
} |
202 |
} |
203 |
|
204 |
.btn2 { |
205 |
@extend .btn1; |
206 |
color:$secondary-color; |
207 |
background:#fff; |
208 |
border-color:$secondary-color; |
209 |
&:hover, |
210 |
&.current, |
211 |
&:focus { |
212 |
background:transparent; |
213 |
border-color:#fff; |
214 |
} |
215 |
} |
216 |
|
217 |
.btn3 { |
218 |
@extend .btn1; |
219 |
color:#fff; |
220 |
border-color:#fff; |
221 |
&:hover, |
222 |
&.current, |
223 |
&:focus { |
224 |
color:$secondary-color; |
225 |
background:#fff; |
226 |
border-color:#fff; |
227 |
} |
228 |
} |
229 |
|
230 |
|
231 |
.btn4 { |
232 |
border:1px solid white; |
233 |
color:white; |
234 |
display:inline-block; |
235 |
height:$btn-height; |
236 |
text-align:center; |
237 |
font-size:emCalc(12px); |
238 |
&:hover, |
239 |
&:focus { |
240 |
color: #fff; |
241 |
span { |
242 |
border-color: white; |
243 |
} |
244 |
} |
245 |
&.current { |
246 |
span { |
247 |
background-color: white; |
248 |
} |
249 |
background:white; |
250 |
color:$secondary-color; |
251 |
} |
252 |
span { |
253 |
border: 1px solid transparent; |
254 |
display: block; |
255 |
padding:0 20px; |
256 |
line-height:$btn-height - 4px; |
257 |
height:100%; |
258 |
|
259 |
} |
260 |
} |
261 |
|
262 |
.btn5 { |
263 |
border:1px solid white; |
264 |
color:white; |
265 |
display:inline-block; |
266 |
height:$btn-height; |
267 |
text-align:center; |
268 |
font-size:emCalc(12px); |
269 |
&:hover, |
270 |
&:focus { |
271 |
span { |
272 |
border-color: white; |
273 |
color: white; |
274 |
} |
275 |
} |
276 |
&.current { |
277 |
span { |
278 |
background-color: white; |
279 |
} |
280 |
background:white; |
281 |
color:$secondary-color; |
282 |
} |
283 |
span { |
284 |
border: 1px solid transparent; |
285 |
display: block; |
286 |
padding:0 20px; |
287 |
line-height:$btn-height - 4px; |
288 |
height:100%; |
289 |
|
290 |
} |
291 |
} |
292 |
|
293 |
.btn-img { |
294 |
@extend .btn1; |
295 |
border-color:$secondary-color; |
296 |
&:hover, |
297 |
&:focus { |
298 |
background:transparent; |
299 |
} |
300 |
a { |
301 |
img,span { |
302 |
margin-left:5px; |
303 |
} |
304 |
} |
305 |
} |
306 |
|
307 |
|
308 |
/* Layout ----------------------------------------------- */ |
309 |
html,body { |
310 |
height:100%; |
311 |
} |
312 |
|
313 |
body { |
314 |
padding-top:$header-height+$bar-height; |
315 |
} |
316 |
|
317 |
.body-wrapper { |
318 |
min-height:100%; |
319 |
} |
320 |
|
321 |
.main { |
322 |
padding:0 $main-padding-horizontal; |
323 |
} |
324 |
|
325 |
/* Header ----------------------------------------------- */ |
326 |
|
327 |
.header { |
328 |
position:fixed; |
329 |
top:0; |
330 |
left:0; |
331 |
right:0; |
332 |
width:100%; |
333 |
height:$header-height; |
334 |
line-height:$header-height; |
335 |
padding:0 $header-padding-horizontal; |
336 |
background:white; |
337 |
z-index:100; |
338 |
.icons-nav { |
339 |
position:absolute; |
340 |
left:$header-padding-horizontal; |
341 |
height:$header-height; |
342 |
line-height:$header-height; |
343 |
top:0; |
344 |
li { |
345 |
line-height: $header-height; |
346 |
} |
347 |
} |
348 |
.logo { |
349 |
text-align: center; |
350 |
a { |
351 |
position: relative; |
352 |
// top:-5px; |
353 |
} |
354 |
img { |
355 |
height: 40px; |
356 |
} |
357 |
h2 { |
358 |
display: none; |
359 |
margin:0; |
360 |
font-size: 1em; |
361 |
color:$primary-color; |
362 |
font-weight: normal; |
363 |
} |
364 |
} |
365 |
.login { |
366 |
position:absolute; |
367 |
top:25px; |
368 |
right:$header-padding-horizontal; |
369 |
|
370 |
.wrap { |
371 |
$wr-padd-top:12px; |
372 |
border:1px solid $body-font-color; |
373 |
background: white; |
374 |
font-size:emCalc(12px); |
375 |
padding:$wr-padd-top 30px; |
376 |
line-height:100%; |
377 |
ul { |
378 |
padding:0; |
379 |
margin:0; |
380 |
list-style: none outside none; |
381 |
display: none; |
382 |
li { |
383 |
list-style: none outside none; |
384 |
padding:0; |
385 |
padding-top:$wr-padd-top; |
386 |
} |
387 |
} |
388 |
} |
389 |
} |
390 |
|
391 |
} |
392 |
|
393 |
/* Actions Bar ----------------------------------------------- */ |
394 |
|
395 |
.actions-bar { |
396 |
position:fixed; |
397 |
left:0; |
398 |
top:$header-height; |
399 |
width:100%; |
400 |
z-index:15; |
401 |
text-align:center; |
402 |
height:$bar-height; |
403 |
line-height:$bar-height; |
404 |
background-color: $gray-4; |
405 |
h2 { |
406 |
float: left; |
407 |
margin:0 0 0 15px; |
408 |
font-size: emCalc(12px); |
409 |
line-height: $bar-height; |
410 |
font-weight: normal; |
411 |
a { |
412 |
&:after { |
413 |
content: " >"; |
414 |
} |
415 |
} |
416 |
} |
417 |
.filter-menu { |
418 |
float:right; |
419 |
position: relative; |
420 |
.filter { |
421 |
padding: 0 10px; |
422 |
font-size:emCalc(12px); |
423 |
position: relative; |
424 |
top:-1px; |
425 |
} |
426 |
.options { |
427 |
display: none; |
428 |
position: absolute; |
429 |
right: 0; |
430 |
top:$bar-height; |
431 |
width: 120px; |
432 |
list-style-type: none; |
433 |
padding: 10px 15px 15px; |
434 |
text-align: left; |
435 |
margin:0; |
436 |
} |
437 |
&.current { |
438 |
.options { |
439 |
background-color: lighten($primary-color,10%); |
440 |
display: inline-block; |
441 |
a { |
442 |
color: white; |
443 |
} |
444 |
} |
445 |
} |
446 |
|
447 |
|
448 |
} |
449 |
|
450 |
.row { |
451 |
position: relative; |
452 |
height: $bar-height; |
453 |
} |
454 |
|
455 |
.hd-search { |
456 |
$icon-dim :24px; |
457 |
width: $icon-dim; |
458 |
overflow:hidden; |
459 |
position:relative; |
460 |
float: right; |
461 |
height: $bar-height; |
462 |
margin-right: -6px; |
463 |
@include transition(width, 0.3s, linear); |
464 |
-webkit-backface-visibility: hidden; |
465 |
.hd-icon-search { |
466 |
display: block; |
467 |
width: $bar-height; |
468 |
height: $bar-height; |
469 |
line-height: $bar-height; |
470 |
float: right; |
471 |
color: $link-color; |
472 |
&:hover { |
473 |
color: $link-color-hover; |
474 |
cursor:pointer; |
475 |
} |
476 |
z-index:1; |
477 |
position: relative; |
478 |
background: $gray-4; |
479 |
} |
480 |
.hd-search-input { |
481 |
border: transparent; |
482 |
background-color: white; |
483 |
padding: 0 10px; |
484 |
width: 160px; |
485 |
font-size: emCalc(10px); |
486 |
box-shadow: none; |
487 |
height:0.7* $bar-height; |
488 |
line-height: 0.7* $bar-height; |
489 |
position: absolute; |
490 |
top:4px; |
491 |
left:0; |
492 |
} |
493 |
&.hd-open { |
494 |
width: 190px; |
495 |
} |
496 |
} |
497 |
.rt-actions { |
498 |
float: right; |
499 |
margin-right:15px; |
500 |
.current, a:hover { |
501 |
color: $secondary-color; |
502 |
} |
503 |
a { |
504 |
float: left; |
505 |
span { |
506 |
position: relative; |
507 |
&.snf-listview { |
508 |
font-size: emCalc(18px); |
509 |
} |
510 |
&.snf-gridview { |
511 |
font-size: emCalc(18px); |
512 |
} |
513 |
&.snf-trash-outline { |
514 |
} |
515 |
&.snf-folder-create-outline { |
516 |
font-size: emCalc(18px); |
517 |
} |
518 |
&.snf-refresh-outline { |
519 |
font-size: emCalc(12px); |
520 |
top: -2px; |
521 |
} |
522 |
} |
523 |
&:not(:last-child) { |
524 |
margin-right: 10px; |
525 |
} |
526 |
} |
527 |
.single { |
528 |
@include square(12px , $link-color); |
529 |
margin-top: 9px; |
530 |
&.current, |
531 |
&:hover { |
532 |
background-color: $secondary-color; |
533 |
} |
534 |
} |
535 |
|
536 |
} |
537 |
} |
538 |
|
539 |
.no-vm { |
540 |
.actions-bar { |
541 |
.rt-actions, .hd-search, .filter { |
542 |
display: none; |
543 |
} |
544 |
} |
545 |
} |
546 |
|
547 |
/* Icons Navigation ----------------------------------------------- */ |
548 |
|
549 |
.icons-nav { |
550 |
@include marginPaddingZero(); |
551 |
li { |
552 |
display: inline-block; |
553 |
margin-right:$icons-nav-margin-horizontal; |
554 |
font-size: emCalc(26px); |
555 |
line-height: 1em; |
556 |
} |
557 |
} |
558 |
|
559 |
|
560 |
|
561 |
|
562 |
/* Top info ----------------------------------------------- */ |
563 |
|
564 |
.top-info { |
565 |
padding:50px 100px; |
566 |
position: relative; |
567 |
z-index:10; |
568 |
display:none; |
569 |
.close { |
570 |
position: absolute; |
571 |
right:$header-padding-horizontal; |
572 |
top:50px; |
573 |
@include sprite('../images/info-close.png', 31px, 30px); |
574 |
} |
575 |
} |
576 |
|
577 |
|
578 |
.info.error { |
579 |
background:$error-color; |
580 |
color:#fff; |
581 |
} |
582 |
|
583 |
|
584 |
.info.alert { |
585 |
background:$alert-color; |
586 |
color:#fff; |
587 |
} |
588 |
|
589 |
.info.warning { |
590 |
background:$primary-color; |
591 |
color:#fff; |
592 |
} |
593 |
|
594 |
.info.success { |
595 |
background:$success-color; |
596 |
color:#fff; |
597 |
} |
598 |
|
599 |
.border-bottom-style1 { |
600 |
padding-bottom:20px; |
601 |
margin-bottom:20px; |
602 |
border-bottom:1px dashed $primary-color; |
603 |
} |
604 |
|
605 |
|
606 |
/* Progress Bar ----------------------------------------------- */ |
607 |
|
608 |
.progress-bar { |
609 |
position: fixed; |
610 |
bottom:0; |
611 |
left:0; |
612 |
border-top:1px solid $secondary-color; |
613 |
width:100%; |
614 |
background:#fff; |
615 |
padding:20px 0 20px 310px; |
616 |
color:$primary-color; |
617 |
span.counter { |
618 |
display: inline-block; |
619 |
margin-right:20px; |
620 |
float:left; |
621 |
} |
622 |
div.progress-wrap { |
623 |
display:inline-block; |
624 |
float:left; |
625 |
width:40%; |
626 |
margin-right:60px; |
627 |
.progress { |
628 |
position: relative; |
629 |
top:2px; |
630 |
} |
631 |
} |
632 |
span.more { |
633 |
display: inline-block; |
634 |
} |
635 |
} |
636 |
|
637 |
.storage-progress { |
638 |
display: none; |
639 |
position: fixed; |
640 |
bottom: 0; |
641 |
left: 0; |
642 |
right: 0; |
643 |
background: $turquoise-1; |
644 |
color: #fff; |
645 |
z-index: 50; |
646 |
overflow-y: auto; |
647 |
@include transition(background-color, 500ms, linear); |
648 |
&.ready { |
649 |
background: $green-1; |
650 |
} |
651 |
.wrap { |
652 |
position: relative; |
653 |
padding: 10px; |
654 |
} |
655 |
.loader { |
656 |
position: absolute; |
657 |
height: 5px; |
658 |
left: 0; |
659 |
top: 0; |
660 |
background: $yellow-1; |
661 |
width: 0%; |
662 |
} |
663 |
.summary { |
664 |
padding-left: $lt-bar-width + $check-w + $img-wrap-w; |
665 |
margin: 0; |
666 |
font-size: emCalc(12px); |
667 |
span { |
668 |
background-color: #fff; |
669 |
color: $turquoise-1; |
670 |
padding: 2px 6px; |
671 |
margin-right: 10px; |
672 |
@include transition(opacity, 500ms, linear); |
673 |
&.animated { |
674 |
opacity: 0; |
675 |
} |
676 |
} |
677 |
} |
678 |
.details { |
679 |
display: none; |
680 |
} |
681 |
} |
682 |
|
683 |
|
684 |
/* Responive ------------------------------------------------ */ |
685 |
@media only screen and (max-width: $small-mobile) { |
686 |
} |
687 |
|
688 |
@media only screen and (max-width: $small-screen) { |
689 |
body { |
690 |
padding-top:0 |
691 |
} |
692 |
.header, .actions-bar { |
693 |
position:static; |
694 |
z-index: auto; |
695 |
} |
696 |
.actions-bar { |
697 |
top:2*$header-height; |
698 |
} |
699 |
.header { |
700 |
height: $header-height-responsive; |
701 |
line-height:50px; |
702 |
.icons-nav { |
703 |
position: static; |
704 |
} |
705 |
} |
706 |
} |
707 |
|
708 |
/* Scroll Bar -------------------------------------------- */ |
709 |
|
710 |
body .jspVerticalBar { |
711 |
background-color: transparent; |
712 |
width: 14px; |
713 |
padding: 1px; |
714 |
border-left: 1px solid #c2bebe; |
715 |
border-right: 1px solid #c2bebe; |
716 |
.jspTrack { |
717 |
background-color: #e6e5e5; |
718 |
.jspDrag { |
719 |
-webkit-border-radius: 5px; |
720 |
-moz-border-radius: 5px; |
721 |
border-radius: 5px; |
722 |
background-color: #c2bebe; |
723 |
} |
724 |
} |
725 |
.jspArrow { |
726 |
background-color: transparent; |
727 |
@include sprite('../images/arrows.png', 14px, 14px); |
728 |
overflow: hidden; |
729 |
&.jspArrowDown{ |
730 |
background-position: -18px; |
731 |
} |
732 |
|
733 |
&.jspArrowUp { |
734 |
background-position: 0px; |
735 |
} |
736 |
} |
737 |
} |
738 |
|
739 |
@mixin files-icon($bg-position) { |
740 |
background: url(../images/file-types.png) no-repeat top left; |
741 |
background-position: $bg-position; |
742 |
width: 30px; |
743 |
height: 35px; |
744 |
display: block; |
745 |
margin: 0 auto; |
746 |
} |
747 |
.folder { |
748 |
background: url(file-types.png) no-repeat top left; |
749 |
background-position: 0 -165px; |
750 |
width: 35px; |
751 |
height: 28px; |
752 |
} |
753 |
/* to put in use |
754 |
.folder-open { |
755 |
background: url(file-types.png) no-repeat top left; |
756 |
background-position: 0 --243px; |
757 |
width: 35px; |
758 |
height: 28px; |
759 |
} |
760 |
*/ |
761 |
.txt { |
762 |
@include files-icon(0 -486px); |
763 |
} |
764 |
.pdf { |
765 |
@include files-icon(0 -321px); |
766 |
} |
767 |
.excel { |
768 |
@include files-icon(0 -85px); |
769 |
} |
770 |
.word { |
771 |
@include files-icon(0 -571px); |
772 |
} |
773 |
.powerpoint { |
774 |
@include files-icon(0 -406px); |
775 |
} |
776 |
.ai { |
777 |
@include files-icon(0 0); |
778 |
} |