优化应用全局主题逻辑

This commit is contained in:
pipipi-pikachu 2021-01-30 10:58:45 +08:00
parent df23eb6870
commit 2393630318

View File

@ -279,10 +279,12 @@ export default defineComponent({
const { themeColor, backgroundColor, fontColor } = theme.value const { themeColor, backgroundColor, fontColor } = theme.value
for(const slide of newSlides) { for(const slide of newSlides) {
slide.background = { if(!slide.background || slide.background.type !== 'image') {
...slide.background, slide.background = {
type: 'solid', ...slide.background,
color: backgroundColor type: 'solid',
color: backgroundColor
}
} }
const elements = slide.elements const elements = slide.elements