mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-09 17:55:37 +02:00
Additional *manual* unicorn/prefer-ternary
changes
Not all cases could be automatically fixed, and the changes also triggered a number of `prefer-const` errors that needed to be handled manually.
This commit is contained in:
parent
674e7ee381
commit
c0fe96b8fe
13 changed files with 20 additions and 55 deletions
|
@ -854,8 +854,7 @@ function genericComposeSMask(
|
|||
const g0 = hasBackdrop ? backdrop[1] : 0;
|
||||
const b0 = hasBackdrop ? backdrop[2] : 0;
|
||||
|
||||
let composeFn;
|
||||
composeFn =
|
||||
const composeFn =
|
||||
subtype === "Luminosity" ? composeSMaskLuminosity : composeSMaskAlpha;
|
||||
|
||||
// processing image in chunks to save memory
|
||||
|
@ -2254,8 +2253,7 @@ class CanvasGraphics {
|
|||
}
|
||||
}
|
||||
|
||||
let charWidth;
|
||||
charWidth = vertical
|
||||
const charWidth = vertical
|
||||
? width * widthAdvanceScale - spacing * fontDirection
|
||||
: width * widthAdvanceScale + spacing * fontDirection;
|
||||
x += charWidth;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue