##// END OF EJS Templates
use less for tooltip
Matthias BUSSONNIER -
Show More
@@ -3,110 +3,133 b''
3 *
3 *
4 * Author: IPython Development Team
4 * Author: IPython Development Team
5 */
5 */
6
6 /** WARNING IF YOU ARE EDITTING THIS FILE, if this is a .css file, It has a lot
7 /** WARNING IF YOU ARE EDITTING THIS FILE, if this is a .css file, It has a lot
7 * of chance of beeing generated from the ../less/[samename].less file, you can
8 * of chance of beeing generated from the ../less/[samename].less file, you can
8 * try to get back the less file by reverting somme commit in history
9 * try to get back the less file by reverting somme commit in history
9 **/
10 **/
11
10 /*
12 /*
11 * We'll try to get something pretty, so we
13 * We'll try to get something pretty, so we
12 * have some strange css to have the scroll bar on
14 * have some strange css to have the scroll bar on
13 * the left with fix button on the top right of the tooltip
15 * the left with fix button on the top right of the tooltip
14 */
16 */
17
18 // double slash comment are remove by less compilation
19 // **
20 // * Less mixins
21 // **/
22
23 // Four color of the background
24 @import "variables" ;
25
26 .dropshadow(){
27 -moz-box-shadow: 0px 6px 10px -1px #adadad;
28 -webkit-box-shadow: 0px 6px 10px -1px #adadad;
29 box-shadow: 0px 6px 10px -1px #adadad;
30 }
31
32 // smoth height adaptation
33 .smoothheight(@t:1s) {
34 -webkit-transition-property: height;
35 -webkit-transition-duration: 1s;
36 -moz-transition-property: height;
37 -moz-transition-duration: 1s;
38 transition-property: height;
39 transition-duration: 1s;
40 }
41
15 @-moz-keyframes fadeOut {
42 @-moz-keyframes fadeOut {
16 from {
43 from {opacity:1;}
17 opacity: 1;
44 to {opacity:0;}
18 }
19 to {
20 opacity: 0;
21 }
22 }
45 }
46
23 @-webkit-keyframes fadeOut {
47 @-webkit-keyframes fadeOut {
24 from {
48 from {opacity:1;}
25 opacity: 1;
49 to {opacity:0;}
26 }
27 to {
28 opacity: 0;
29 }
30 }
50 }
51
52 //@keyframes fadeOut {
53 // from {opacity:1;}
54 // to {opacity:0;}
55 //}
56
31 @-moz-keyframes fadeIn {
57 @-moz-keyframes fadeIn {
32 from {
58 from {opacity:0;}
33 opacity: 0;
59 to {opacity:1;}
34 }
35 to {
36 opacity: 1;
37 }
38 }
60 }
61
39 @-webkit-keyframes fadeIn {
62 @-webkit-keyframes fadeIn {
40 from {
63 from {opacity:0;}
41 opacity: 0;
64 to {opacity:1;}
42 }
43 to {
44 opacity: 1;
45 }
46 }
47 .ipython_tooltip a {
48 float: right;
49 }
65 }
66
67 //@keyframes fadeIn {
68 // from {opacity:0;}
69 // to {opacity:1;}
70 //}
71
50 /*properties of tooltip after "expand"*/
72 /*properties of tooltip after "expand"*/
51 .bigtooltip {
73 .bigtooltip {
52 overflow: auto;
74 overflow: auto;
53 height: 200px;
75 height: 200px;
54 -webkit-transition-property: height;
76 .smoothheight();
55 -webkit-transition-duration: 1s;
56 -moz-transition-property: height;
57 -moz-transition-duration: 1s;
58 transition-property: height;
59 transition-duration: 1s;
60 }
77 }
78
61 /*properties of tooltip before "expand"*/
79 /*properties of tooltip before "expand"*/
62 .smalltooltip {
80 .smalltooltip{
63 -webkit-transition-property: height;
81 .smoothheight();
64 -webkit-transition-duration: 1s;
82 text-overflow: ellipsis;
65 -moz-transition-property: height;
83 overflow: hidden;
66 -moz-transition-duration: 1s;
84 height:80px;
67 transition-property: height;
68 transition-duration: 1s;
69 text-overflow: ellipsis;
70 overflow: hidden;
71 height: 80px;
72 }
85 }
73 .tooltipbuttons {
86
74 position: absolute;
87 .tooltipbuttons
75 padding-right: 15px;
88 {
76 top: 0px;
89 position: absolute;
77 right: 0px;
90 padding-right : 15px;
91 top : 0px;
92 right:0px;
78 }
93 }
79 .tooltiptext {
80 /*avoid the button to overlap on some docstring*/
81
94
82 padding-right: 30px;
95 .tooltiptext
96 {
97 /*avoid the button to overlap on some docstring*/
98 padding-right:30px
83 }
99 }
100
84 .ipython_tooltip {
101 .ipython_tooltip {
85 max-width: 700px;
102 max-width:700px;
86 border-radius: 4px;
103 /*fade-in animation when inserted*/
87 -moz-box-shadow: 0px 6px 10px -1px #adadad;
104 -webkit-animation: fadeOut 800ms;
88 -webkit-box-shadow: 0px 6px 10px -1px #adadad;
105 -moz-animation: fadeOut 800ms;
89 box-shadow: 0px 6px 10px -1px #adadad;
106 animation: fadeOut 800ms;
90 /*fade-in animation when inserted*/
107 -webkit-animation: fadeIn 800ms;
91
108 -moz-animation: fadeIn 800ms;
92 -webkit-animation: fadeOut 800ms;
109 animation: fadeIn 800ms;
93 -moz-animation: fadeOut 800ms;
110 vertical-align: middle;
94 animation: fadeOut 800ms;
111 background-color: @cell_background;
95 -webkit-animation: fadeIn 800ms;
112
96 -moz-animation: fadeIn 800ms;
113 overflow : visible;
97 animation: fadeIn 800ms;
114 border: @border_color @borderwidth solid;
98 vertical-align: middle;
115 outline: none;
99 background-color: #f7f7f7;
116 padding: 3px;
100 overflow: visible;
117 margin: 0px;
101 border: #bbbbbb 1px solid;
118 padding-left:7px;
102 outline: none;
119 font-family: monospace;
103 padding: 3px;
120 min-height:50px;
104 margin: 0px;
121 position: absolute;
105 padding-left: 7px;
122
106 font-family: monospace;
123 .dropshadow;
107 min-height: 50px;
124 .corner-all;
108 position: absolute;
125
126 a {
127 float:right;
128 }
129
109 }
130 }
131
132
110 .pretooltiparrow {
133 .pretooltiparrow {
111 left: 0px;
134 left: 0px;
112 margin: 0px;
135 margin: 0px;
@@ -115,19 +138,22 b''
115 height: 16px;
138 height: 16px;
116 overflow: hidden;
139 overflow: hidden;
117 position: absolute;
140 position: absolute;
141
118 }
142 }
143
119 .pretooltiparrow:before {
144 .pretooltiparrow:before {
120 background-color: #f7f7f7;
145 background-color : @cell_background;
121 border: 1px #bbbbbb solid;
146 border : @borderwidth @border_color solid;
122 z-index: 11;
147 z-index:11;
123 content: "";
148 content: "";
124 position: absolute;
149 position: absolute;
125 left: 15px;
150 left: 15px;
126 top: 10px;
151 top: 10px;
127 width: 25px;
152 width: 25px;
128 height: 25px;
153 height: 25px;
129 -webkit-transform: rotate(45deg);
154 @theta : 45deg;
130 -moz-transform: rotate(45deg);
155 -webkit-transform: rotate(@theta);
131 -ms-transform: rotate(45deg);
156 -moz-transform: rotate(@theta);
132 -o-transform: rotate(45deg);
157 -ms-transform: rotate(@theta);
158 -o-transform: rotate(@theta);
133 }
159 }
@@ -3,6 +3,7 b''
3 @cell_selected_background: darken(@notebook_background, 2%);
3 @cell_selected_background: darken(@notebook_background, 2%);
4 @cell_background: darken(@notebook_background, 3.2%);
4 @cell_background: darken(@notebook_background, 3.2%);
5 @border_color: darken(@cell_selected_background, 10%);
5 @border_color: darken(@cell_selected_background, 10%);
6 @borderwidth : 1px;
6
7
7
8
8
9
@@ -174,7 +174,7 b' data-notebook-id={{notebook_id}}'
174 </div>
174 </div>
175
175
176 </div>
176 </div>
177 <div id='tooltip' class='ipython_tooltip corner-all' style='display:none'></div>
177 <div id='tooltip' class='ipython_tooltip' style='display:none'></div>
178
178
179
179
180 {% endblock %}
180 {% endblock %}
1 NO CONTENT: file was removed
NO CONTENT: file was removed
General Comments 0
You need to be logged in to leave comments. Login now