Skip to content

Commit

Permalink
Round off sizes for "string" pageSizes
Browse files Browse the repository at this point in the history
  • Loading branch information
tarzzz committed Sep 24, 2019
1 parent 5c1f71d commit f2a2bad
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/component/plotly-dash-preview/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ module.exports = {
maxRenderingTries: 100,
pixelsInMicron: pixelsInInch / micronsInInch,
sizeMapping: {
'A3': { 'width': 11.7 * pixelsInInch, 'height': 16.5 * pixelsInInch },
'A4': { 'width': 8.3 * pixelsInInch, 'height': 11.7 * pixelsInInch },
'A5': { 'width': 5.8 * pixelsInInch, 'height': 8.3 * pixelsInInch },
'Letter': { 'width': 8.5 * pixelsInInch, 'height': 11 * pixelsInInch },
'Legal': { 'width': 8.5 * pixelsInInch, 'height': 14 * pixelsInInch },
'Tabloid': { 'width': 11 * pixelsInInch, 'height': 17 * pixelsInInch }
'A3': { 'width': Math.ceil(11.7 * pixelsInInch), 'height': Math.ceil(16.5 * pixelsInInch) },
'A4': { 'width': Math.ceil(8.3 * pixelsInInch), 'height': Math.ceil(11.7 * pixelsInInch) },
'A5': { 'width': Math.ceil(5.8 * pixelsInInch), 'height': Math.ceil(8.3 * pixelsInInch) },
'Letter': { 'width': Math.ceil(8.5 * pixelsInInch), 'height': Math.ceil(11 * pixelsInInch) },
'Legal': { 'width': Math.ceil(8.5 * pixelsInInch), 'height': Math.ceil(14 * pixelsInInch) },
'Tabloid': { 'width': Math.ceil(11 * pixelsInInch), 'height': Math.ceil(17 * pixelsInInch) }
},
statusMsg: {
525: 'dash preview generation failed',
Expand Down

0 comments on commit f2a2bad

Please sign in to comment.