diff --git a/package-lock.json b/package-lock.json index 39deb5a0..b639878a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24,7 +24,7 @@ "number-precision": "^1.6.0", "pinia": "^2.1.7", "pptxgenjs": "^3.12.0", - "pptxtojson": "^1.2.0", + "pptxtojson": "^1.2.1", "prosemirror-commands": "^1.6.0", "prosemirror-dropcursor": "^1.8.1", "prosemirror-gapcursor": "^1.3.2", @@ -4177,9 +4177,9 @@ } }, "node_modules/pptxtojson": { - "version": "1.2.0", - "resolved": "https://registry.npmmirror.com/pptxtojson/-/pptxtojson-1.2.0.tgz", - "integrity": "sha512-mDroIVEt6nbsUPI9mrxWzJhU0hNHS614ra/MktMZOMYF5Nh/LwksXRC5J/kr0hZObxa98TqmhUJCktTwcQ2cSg==", + "version": "1.2.1", + "resolved": "https://registry.npmmirror.com/pptxtojson/-/pptxtojson-1.2.1.tgz", + "integrity": "sha512-ECYH2jc8hh2kzmrpQLHDEKrnCMlDdqu/diOqeSQ6luwTZVOGtdjk20ooUa1GWgrzXGBlNf2b6SCjnWqyAwVyjw==", "dependencies": { "jszip": "^3.10.1", "tinycolor2": "1.6.0", @@ -8393,9 +8393,9 @@ } }, "pptxtojson": { - "version": "1.2.0", - "resolved": "https://registry.npmmirror.com/pptxtojson/-/pptxtojson-1.2.0.tgz", - "integrity": "sha512-mDroIVEt6nbsUPI9mrxWzJhU0hNHS614ra/MktMZOMYF5Nh/LwksXRC5J/kr0hZObxa98TqmhUJCktTwcQ2cSg==", + "version": "1.2.1", + "resolved": "https://registry.npmmirror.com/pptxtojson/-/pptxtojson-1.2.1.tgz", + "integrity": "sha512-ECYH2jc8hh2kzmrpQLHDEKrnCMlDdqu/diOqeSQ6luwTZVOGtdjk20ooUa1GWgrzXGBlNf2b6SCjnWqyAwVyjw==", "requires": { "jszip": "^3.10.1", "tinycolor2": "1.6.0", diff --git a/package.json b/package.json index 3b99e134..f7c0fe43 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "number-precision": "^1.6.0", "pinia": "^2.1.7", "pptxgenjs": "^3.12.0", - "pptxtojson": "^1.2.0", + "pptxtojson": "^1.2.1", "prosemirror-commands": "^1.6.0", "prosemirror-dropcursor": "^1.8.1", "prosemirror-gapcursor": "^1.3.2", diff --git a/src/hooks/useImport.ts b/src/hooks/useImport.ts index 70ac612d..25922a0a 100644 --- a/src/hooks/useImport.ts +++ b/src/hooks/useImport.ts @@ -182,12 +182,12 @@ export default () => { background = { type: 'gradient', gradient: { - type: 'linear', + type: value.path === 'line' ? 'linear' : 'radial', colors: value.colors.map(item => ({ ...item, pos: parseInt(item.pos), })), - rotate: value.rot, + rotate: value.rot + 90, }, } } @@ -309,7 +309,7 @@ export default () => { } const gradient: Gradient | undefined = el.fill?.type === 'gradient' ? { - type: 'linear', + type: el.fill.value.path === 'line' ? 'linear' : 'radial', colors: el.fill.value.colors.map(item => ({ ...item, pos: parseInt(item.pos),