##// END OF EJS Templates
fix celltoolbar layout on FF
Matthias BUSSONNIER -
Show More
@@ -3,21 +3,15 b''
3
3
4 .celltoolbar {
4 .celltoolbar {
5 border: thin solid #CFCFCF;
5 border: thin solid #CFCFCF;
6 margin-left: 0px;
7 border-bottom: none;
6 border-bottom: none;
8 margin:0;
9 padding:0;
10 background : #EEE;
7 background : #EEE;
11 border-top-right-radius: 3px;
8 border-top-right-radius: 3px;
12 border-top-left-radius: 3px;
9 border-top-left-radius: 3px;
10 width:100%;
11 -webkit-box-pack: end;
12 height:20px;
13 }
13 }
14
14
15 .celltoolbar div{
16 line-height: 0;
17 margin:0;
18 padding:0;
19 }
20
21
15
22 .no_input_radius {
16 .no_input_radius {
23 border-top-right-radius: 0px;
17 border-top-right-radius: 0px;
@@ -33,12 +27,19 b''
33 }
27 }
34
28
35 .ctb_hideshow {
29 .ctb_hideshow {
36 display: none;
30 display:none;
31 vertical-align:bottom;
32 padding-right: 2px;
33 }
34
35 .celltoolbar > div {
36 padding-top: 0px;
37 }
37 }
38
38
39 .ctb_area {
39 .ctb_area {
40 margin:0;
40 margin:0;
41 padding:0;
41 padding:0;
42 width:100%;
42
43
43 }
44 }
44
45
@@ -47,10 +48,10 b''
47 all or one cell's toolbars.
48 all or one cell's toolbars.
48 */
49 */
49 .ctb_show.ctb_hideshow, .ctb_show .ctb_hideshow {
50 .ctb_show.ctb_hideshow, .ctb_show .ctb_hideshow {
50 display: block;
51 display:block;
51 }
52 }
52
53
53 .ctb_show .ctb_hideshow + div > div.input_area,
54 .ctb_show .input_area,
54 .ctb_show .ctb_hideshow + div.text_cell_input {
55 .ctb_show .ctb_hideshow + div.text_cell_input {
55 border-top-right-radius: 0px;
56 border-top-right-radius: 0px;
56 border-top-left-radius: 0px;
57 border-top-left-radius: 0px;
@@ -62,28 +63,34 b" all or one cell's toolbars."
62 }
63 }
63
64
64 .button_container {
65 .button_container {
65 float: right;
66 margin-top:0;
66 padding-bottom: 1px;
67 margin-bottom:0;
67 }
68 }
68
69
69 .button_container .ui-state-default, .button_container .ui-state-hover, .button_container .ui-state-hover span{
70 .button_container .ui-state-default, .button_container .ui-state-hover, .button_container .ui-state-hover span{
70 border-radius : 0 0 0 0;
71 border-radius : 0 0 0 0;
71 border : none;
72 border : none;
73 margin:0;
72 }
74 }
73
75
74 .celltoolbar .button_container select {
76 .celltoolbar .button_container select {
75 margin: 10px;
77 margin: 10px;
76 margin-top: 0px;
78 margin-top: 1px;
77 margin-bottom: 0px;
79 margin-bottom: 0px;
80 padding:0;
78 font-size: 87%;
81 font-size: 87%;
79 height:18px;
80 display:inline;
81 width:auto;
82 width:auto;
83 display:inline-block;
84 height:18px;
85 line-height:18px;
86 vertical-align:top;
82 }
87 }
83
88
84 .celltoolbar label{
89 .celltoolbar label{
85 display:inline;
90 display:inline-block;
86 line-height:13px;
91 height:15px;
92 line-height:15px;
93 vertical-align:top;
87 }
94 }
88
95
89 .celltoolbar label span {
96 .celltoolbar label span {
@@ -97,7 +104,8 b" all or one cell's toolbars."
97 }
104 }
98
105
99
106
100 .celltoolbar ui-button {
107 .celltoolbar .ui-button {
101 border: none;
108 border: none;
109 vertical-align:top;
110 height:20px;
102 }
111 }
103
@@ -35,14 +35,10 b' var IPython = (function (IPython) {'
35
35
36 CellToolbar.prototype.create_element = function () {
36 CellToolbar.prototype.create_element = function () {
37 this.inner_element = $('<div/>');
37 this.inner_element = $('<div/>');
38 var ctb_element = $('<div/>').addClass('celltoolbar')
38 var ctb_element = $('<div/>').addClass('celltoolbar hbox reverse')
39 .append(this.inner_element);
39 .append(this.inner_element);
40 ctb_element.addClass('box-flex1');
41 var ctb_area = $('<div/>').addClass('ctb_area hbox');
42 var ctb_prompt = $('<div/>').addClass('ctb_prompt prompt');
43 ctb_area.append(ctb_prompt).append(ctb_element);
44 this.element = $('<div/>').addClass('ctb_hideshow')
40 this.element = $('<div/>').addClass('ctb_hideshow')
45 .append(ctb_area);
41 .append(ctb_element);
46 };
42 };
47
43
48
44
@@ -64,11 +64,12 b' var IPython = (function (IPython) {'
64 cell.attr('tabindex','2');
64 cell.attr('tabindex','2');
65
65
66 this.celltoolbar = new IPython.CellToolbar(this);
66 this.celltoolbar = new IPython.CellToolbar(this);
67 cell.append(this.celltoolbar.element);
68
67
69 var input = $('<div></div>').addClass('input hbox');
68 var input = $('<div></div>').addClass('input hbox');
69 var vbox = $('<div/>').addClass('vbox box-flex1')
70 input.append($('<div/>').addClass('prompt input_prompt'));
70 input.append($('<div/>').addClass('prompt input_prompt'));
71 var input_area = $('<div/>').addClass('input_area box-flex1');
71 vbox.append(this.celltoolbar.element);
72 var input_area = $('<div/>').addClass('input_area');
72 this.code_mirror = CodeMirror(input_area.get(0), {
73 this.code_mirror = CodeMirror(input_area.get(0), {
73 indentUnit : 4,
74 indentUnit : 4,
74 mode: 'python',
75 mode: 'python',
@@ -78,7 +79,8 b' var IPython = (function (IPython) {'
78 onKeyEvent: $.proxy(this.handle_codemirror_keyevent,this),
79 onKeyEvent: $.proxy(this.handle_codemirror_keyevent,this),
79 matchBrackets: true
80 matchBrackets: true
80 });
81 });
81 input.append(input_area);
82 vbox.append(input_area);
83 input.append(vbox);
82 var output = $('<div></div>');
84 var output = $('<div></div>');
83 cell.append(input).append(output);
85 cell.append(input).append(output);
84 this.element = cell;
86 this.element = cell;
General Comments 0
You need to be logged in to leave comments. Login now