From 7f5dee88b6fc1adafb778a31f739434073bfd519 Mon Sep 17 00:00:00 2001 From: pipipi-pikachu Date: Mon, 11 Apr 2022 20:15:54 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E5=AF=BC=E5=87=BAPPTX=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E6=94=AF=E6=8C=81=E6=96=87=E5=AD=97=E9=80=8F=E6=98=8E?= =?UTF-8?q?=E5=BA=A6=E3=80=81=E5=9B=BE=E7=89=87=E9=80=8F=E6=98=8E=E5=BA=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/hooks/useExport.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/hooks/useExport.ts b/src/hooks/useExport.ts index 499c8c8e..93946e47 100644 --- a/src/hooks/useExport.ts +++ b/src/hooks/useExport.ts @@ -291,6 +291,7 @@ export default () => { angle: 45, } } + if (el.opacity !== undefined) options.transparency = (1 - el.opacity) * 100 pptxSlide.addText(textProps, options) } @@ -315,6 +316,7 @@ export default () => { if (index !== -1) options.hyperlink = { slide: index + 1 } } } + if (el.filters?.opacity) options.transparency = 100 - parseInt(el.filters?.opacity) pptxSlide.addImage(options) }