Update dependency canvas-constructor to v7 #7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
5.0.2
->7.0.2
Release Notes
kyranet/canvas-constructor (canvas-constructor)
v7.0.2
Compare Source
🐛 Bug Fixes
📝 Documentation
v7.0.1
Compare Source
🐛 Bug Fixes
globalThis
(#560) (a83af48)📝 Documentation
v7.0.0
Compare Source
🏠 Refactor
loadImage
from@napi-rs/canvas
(#516) (c5ad068)loadImage
function is now an async function returning aPromise
v6.0.2
Compare Source
🐛 Bug Fixes
v6.0.1
Compare Source
🐛 Bug Fixes
resetTransform
(352a24e)loadImage
rather thanresolveImage
(ef0be31)📝 Documentation
@napi-rs/canvas
(3ddf9f6)v6.0.0
Compare Source
🏠 Refactor
registerFont
toloadFont
(0019ee7)resolveImage
toloadImage
(a0db7bb)📝 Documentation
@note
s defining which methods are engine-specific (54dcb08)🚀 Features
svgAsync()
(ff40a27)pngAsync()
(7b78a77)pdfAsync()
(dbe42de)jpegAsync()
(8eed23c)pngAsync()
(1b83681)png()
(1f6d30f)pdfAsync()
(d799c0e)pdf()
(f6759c4)jpegAsync()
(0073dce)jpeg()
(6f023f9)printConicStrokeGradient()
(955f8ba)printConicColorGradient()
(e50a13e)createConicGradient()
(90ccf01)createImageData()
(1783a3a)/napi-rs
engine (#480) (22047df)💥 Breaking Changes:
cb
parameter ingetImageData()
cb
parameter inmeasureText()
cb
parameter increatePattern()
cb
parameter inwrapText()
createJPEGStream()
tojpegStream()
createPDFStream()
topdfStream()
createPNGStream()
topngStream()
setAntiAliasing()
tosetAntialiasMode()
jpg()
now returns a synchronous responsepdf()
now returns a synchronous responsepng()
now returns a synchronous responsesvg()
now returns a synchronous responsecb
parameter ingetFontVariant()
cb
parameter ingetTextTracking()
cb
parameter ingetTextWrap()
getPages()
toget pages
jpg()
tojpeg()
newPages()
toaddPage()
5.0.2 (2022-01-22)
Bug Fixes
printResponsiveText
(#388) (08c3418)5.0.1 (2021-07-30)
Bug Fixes
5.0.0 (2021-07-27)
⚠ BREAKING CHANGES
Removed main export at
canvas-constructor
.Dropped Node 8, 10, and 12 support
specify breaking changes (3a2aece)
4.1.0
Added
options.fit
inCanvas#printCircularImage
.4.0.0
Added
hex
util to format hexadecimal strings into a valid color string.rgb
util to format the parameters into a valid color string.rgba
util to format the parameters into a valid color string.hsl
util to format the parameters into a valid color string.hsla
util to format the parameters into a valid color string.color
util to provide type safety when picking colors.Canvas#createEllipseClip
.Canvas#process
.Canvas#toBuffer{Async}
.Canvas#toDataURL{Async}
.Canvas#toBlob{Async}
.Changed
createRectClip
tocreateRectangleClip
.clearPixels
toclearRectangle
.addRect
toprintRectangle
.addStrokeRect
toprintStrokeRectangle
.addCircle
toprintCircle
.addText
toprintText
.addStrokeText
toprintStrokeText
.addWrappedText
toprintWrappedText
.addResponsiveText
toprintResponsiveText
.addBeveledRect
toprintRoundedRectangle
.addCircularImage
toprintCircularImage
.addBeveledImage
toprintRoundedImage
.addPattern
toprintPattern
.createRoundPath
tocreateCircularPath
.createRoundClip
tocreateCircularClip
.createRectPath
tocreateRectanglePath
.createRectClip
tocreateRectangleClip
.createBeveledPath
tocreateRoundedPath
.createBeveledClip
tocreateRoundedClip
.addLinearColorGradient
toprintLinearColorGradient
.addLinearStrokeGradient
toprintLinearStrokeGradient
.addRadialColorGradient
toprintRadialColorGradient
.addRadialStrokeGradient
toprintRadialStrokeGradient
.createEllipse
tocreateEllipsePath
.addImage
toprintImage
.addImage
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.addCircularImage
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.addBeveledImage
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.addPattern
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.createPattern
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.printPattern
to takeImage | Canvas
instead ofBuffer | Image
, you must useloadImage
.Fixed
canvas
, since they added typings recently.this
parameter is now typed.Removed
addImage
. UseprintCircularImage
orprintRoundedImage
instead.addRoundImage
. UseprintCircularImage
instead, beware that (x, y) is the centre and not top-left.registerFont
fromCanvas
, use the export fromcanvas
instead.canvas-prebuilt
.canvas
already comes with them.3.0.3
Fixed
handlebars@4.1.2
.3.0.2
Fixed
Canvas#resetShadows()
not clearing shadows.3.0.1
Fixed
3.0.0
Added
Canvas#wrapText()
.Changed
Canvas#addMultilineText()
not wrap lines.Canvas.getCanvas()
toCanvas.internalCanvas
.Canvas.fromCanvas()
toCanvas.from()
.void
tounknown
for strict rules to allow return.2.1.1
Fixed
2.1.0
Added
Canvas#{toBlob,toBlobAsync}
for browser support.Canvas.fromCanvas()
for browser support (this is a must in browsers as you can't constructHTMLCanvasElement
).Fixed
2.0.0
Changed
restore
argument now default totrue
instead offalse
, the previous default kept functionality from pre-releases and 1.x but I couldn't change it under a minor version, only with a major one. But now I decided it's enough, and made it default to the intuitive, and very often most-wanted choice:true
.Fixed
addCircularImage()
adding the circular clip in the wrong center.canvas@2.x
.Removed
addBevelImage
has been removed. As per the deprecation added over 2 months ago, it has been renamed toaddBeveledImage
.1.1.2
Fixed
addCircularImage()
adding the circular clip in the wrong center.1.1.1
Fixed
addCircularImage()
not adding a circular clip before adding the image.1.1.0
Added
toDataURL()
andtoDataURLAsync()
.addCircularImage()
, similar toaddCircle()
.setTextSize()
, similar tosetTextFont()
but changes the font size only (not the font itself).addImage()
.addImage()
.Changed
createBeveledPath()
now accepts an object typeBeveledRadiusOptions
.addBevelImage()
toaddBeveledImage()
to prevent confusions (naming inconsistency). The old method is still available but it's deprecated and will be removed in the next major update.1.0.0
Added
addTextFont()
for canvas 1.6.x compatibility.Removed
METHODS.md
in favor of the new docs.0.4.0
Added
addMultilineText()
to print texts that are too long to be displayed.0.3.1
Added
printLinearGradient()
andprintRadialGradient()
to have chainable methods.createLinearGradient()
andcreateRadialGradient()
, steps, which is typeofGradientStep[]
.Changed
createLinearGradient()
andcreateRadialGradient()
are not longer chainable, they'll returnCanvasGradient
instead.0.3.0
Added
createBeveledPath()
same usage ascreateBeveledClip()
, but does not create clips (so you can use shadows and fill to colorize it).createRoundPath()
same usage ascreateRoundClip()
, but does not create clips (so you can use shadows and fill to colorize it).clip()
(how come this was not implemented?).Changed
0.2.0
Changed
addResponsiveText()
changed the parser to be passive, faster, and more accurate.Removed
setTextFont()
.0.1.7
Added
changeCanvasSize()
to change the canvas' width/height.changeCanvasWidth()
to change the canvas' width.changeCanvasHeigth()
to change the canvas' height.Removed
registerTextFont()
as canvas-constructor relies oncanvas@1.6.6
, this method is useless.0.1.6
Added
setStrokeWidth()
to change stroke/line's width.beginPath()
to start making paths.closePath()
to start closing paths.createLinearGradient()
to create linear gradients.createRadialGradient()
to create radial gradients.arc()
andarcTo()
, to create arcs.quadraticCurveTo()
to create quadratic Bèzier curves.bezierCurveTo()
to create cubic Bèzier curves.lineTo()
to connect lines.moveTo()
to move the starting point of a path to any (x, y) coordinates.Changed
'#​000000'
for thesetStroke()
method.addImage()
removedthis.save()
andthis.restore()
so users can use their own paths.Fixed
measureText()
.0.1.5
Added
save()
To save the current state onto a stack.rotate()
To add a rotation to the transformation matrix.scale()
To perform scaling transformations.traslate()
To perform translating transformations.fill()
To fill the current/given path.stroke()
To stroke the current/given path.addStrokeText()
To add stroked text.measureText()
To measure in pixels a text. Be careful, if you do not provide a callback (second argument), this method will return an Integer value instead of being chainable.setTextBaseline()
To set the text's baseline.setShadowOffsetX()
To set the shadow offset for the axis X.setShadowOffsetY()
To set the shadow offset for the axis Y.setGlobalAlpha()
To set the global alpha value for the next elements.clearCircle()
To clear the pixels with a circle shape.clearPixels()
To clear the pixels with a rectangle shape. (Usage isidentical to
addRect()
).Changed
fillRect()
->addRect()
| To keep consistency.addText()
now accepts a third argument:maxWidth
.addImage()
now saves and restores the context.Fixed
addRoundImage()
now points toaddImage()
with the correct arguments.addBevelImage()
now points toaddImage()
with the correct arguments.0.1.4
Changed
README.md
.0.1.3
Fixed
in
operator inaddImage()
0.1.0
Added
addFont()
method for retro-compatibility with old versions of Canvas.(Thanks to York in
PR#1)
Changed
README.md
.Fixed
options
argument foraddImage()
.Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.