File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change 14
14
pre .prettyprint { padding : 2px ; border : 1px solid # 888 ; display : list }
15
15
16
16
/* Specify class=linenums on a pre to get line numbering */
17
- ol .linenums { margin : 0 }
17
+ ol .linenums { margin-top : 0 ; margin-bottom : 0 } /* IE indents via margin-left */
18
18
li .L0 ,
19
19
li .L1 ,
20
20
li .L2 ,
Original file line number Diff line number Diff line change @@ -1113,7 +1113,8 @@ window['_pr_isIE6'] = function () {
1113
1113
for ( var i = 0 ; i < 10 ; ++ i ) {
1114
1114
lineBreaks [ i ] = lineBreakHtml + '</li><li class="L' + i + '">' ;
1115
1115
}
1116
- var lineNum = numberLines [ 1 ] - 1 || 0 ; // Lines are 1-indexed
1116
+ var lineNum = numberLines [ 1 ] && numberLines [ 1 ] . length
1117
+ ? numberLines [ 1 ] - 1 : 0 ; // Lines are 1-indexed
1117
1118
html . push ( '<ol class="linenums"><li class="L' , ( lineNum ) % 10 , '"' ) ;
1118
1119
if ( lineNum ) {
1119
1120
html . push ( ' value="' , lineNum + 1 , '"' ) ;
You can’t perform that action at this time.
0 commit comments