Modifier la taille de l'image redimensionnée à un cinquième de ses dimensions d'origine
This commit is contained in:
@@ -183,8 +183,8 @@ router.get('/preview/:projectId/:orderId', async (req, res) => {
|
||||
|
||||
// Obtenir les dimensions originales de l'image
|
||||
const metadata = await sharp(imagePath).metadata();
|
||||
const width = Math.floor(metadata.width / 2);
|
||||
const height = Math.floor(metadata.height / 2);
|
||||
const width = Math.floor(metadata.width / 5);
|
||||
const height = Math.floor(metadata.height / 5);
|
||||
|
||||
// Redimensionner l'image à la moitié de ses dimensions d'origine
|
||||
const resizedImage = await sharp(imagePath)
|
||||
|
||||
Reference in New Issue
Block a user