From f3e3e58a2b94c58c2710d3aaf4ec1e02ee854058 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sun, 28 Apr 2024 15:41:12 -0400 Subject: [PATCH] Fix --- commands/edit-image-text/tweet.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/commands/edit-image-text/tweet.js b/commands/edit-image-text/tweet.js index b2e35831..b4eb1d0d 100644 --- a/commands/edit-image-text/tweet.js +++ b/commands/edit-image-text/tweet.js @@ -85,8 +85,8 @@ module.exports = class TweetCommand extends Command { imageHeight = imageData.height * imageHeightRatio; const imageCanvas = createCanvas(imageWidth, imageHeight); const imageCtx = imageCanvas.getContext('2d'); - canvas.height += imageHeight + 30; - ctx.fillRect(0, base1.height, canvas.width, linesLen + imageHeight + 30); + canvas.height += imageHeight + 15; + ctx.fillRect(0, base1.height, canvas.width, linesLen + imageHeight + 15); const x = 0; const y = 0; const radius = 15; @@ -106,7 +106,7 @@ module.exports = class TweetCommand extends Command { const bookmarks = randomRange(Math.ceil(userData.followers * 0.000015), Math.ceil(userData.followers * 0.00002)); const views = randomRange(Math.ceil(userData.followers * 10), Math.ceil(userData.followers * 30)); ctx.drawImage(base1, 0, 0); - const base2StartY = base1.height + linesLen + (image ? imageHeight + 30 : 0); + const base2StartY = base1.height + linesLen + (image ? imageHeight + 15 : 0); ctx.drawImage(base2, 0, base2StartY); ctx.textBaseline = 'top'; ctx.font = this.client.fonts.get('ChirpBold.ttf').toCanvasString(18);