Skip to content

Commit

Permalink
Fix for Safari and cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
paulmasson committed Jan 16, 2020
1 parent fab9463 commit 8fd5295
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions build/mathcell.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,10 @@ function graphic( id, data, config ) {

var center = config.center ? 'text-align: center' : '';

return `<div style="height: 100%; white-space: nowrap; overflow-x: auto; ${center}">
${JSON.stringify( data ).replace( /\"/g, '' )} </div>`;
return `
<div style="width: 100%; height: 100%; float: left;
white-space: nowrap; overflow-x: auto; ${center}">
${JSON.stringify( data ).replace( /\"/g, '' )} </div>`;

case 'matrix':

Expand Down
6 changes: 4 additions & 2 deletions src/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,10 @@ function graphic( id, data, config ) {

var center = config.center ? 'text-align: center' : '';

return `<div style="height: 100%; white-space: nowrap; overflow-x: auto; ${center}">
${JSON.stringify( data ).replace( /\"/g, '' )} </div>`;
return `
<div style="width: 100%; height: 100%; float: left;
white-space: nowrap; overflow-x: auto; ${center}">
${JSON.stringify( data ).replace( /\"/g, '' )} </div>`;

case 'matrix':

Expand Down

0 comments on commit 8fd5295

Please sign in to comment.