cxmo пре 11 месеци
родитељ
комит
4f1ccc56e8
2 измењених фајлова са 9 додато и 4 уклоњено
  1. 4 2
      src/lang/modules/Slides/pptPresent.js
  2. 5 2
      src/views/ppt_manage/mixins/pptEditorMixins.js

+ 4 - 2
src/lang/modules/Slides/pptPresent.js

@@ -103,7 +103,8 @@ export const presentEn = {
   apply_to_the_entire:'Apply to the entire PPT',
   apply_to_the_entire:'Apply to the entire PPT',
   title_style_fontfamily:"Font Family",
   title_style_fontfamily:"Font Family",
   title_style_fontsize:'Font Size',
   title_style_fontsize:'Font Size',
-  title_style_color:'Font Color'
+  title_style_color:'Font Color',
+  title_paste_hint:'The clipboard is empty, please paste the text',
 };
 };
 
 
 /* 中文 */
 /* 中文 */
@@ -207,7 +208,8 @@ export const presentZh = {
   apply_to_the_entire:'应用至整个PPT',
   apply_to_the_entire:'应用至整个PPT',
   title_style_fontfamily:"字体设置",
   title_style_fontfamily:"字体设置",
   title_style_fontsize:'字号设置',
   title_style_fontsize:'字号设置',
-  title_style_color:'字体颜色'
+  title_style_color:'字体颜色',
+  title_paste_hint:'粘贴板获取为空,请粘贴文本',
 };
 };
 
 
 /**
 /**

+ 5 - 2
src/views/ppt_manage/mixins/pptEditorMixins.js

@@ -93,8 +93,11 @@ export default{
         e.preventDefault()
         e.preventDefault()
         //只获取文字
         //只获取文字
         const text = e.clipboardData.getData('text/plain')
         const text = e.clipboardData.getData('text/plain')
-        e.target.innerHTML = text
-        item.title = text
+        if(!text.trim().length){
+            this.$message.warning(this.$t('Slides.title_paste_hint'))
+        }
+        e.target.innerHTML += text.trim()
+        item.title += text.trim()
     },
     },
     testInput(e,item){
     testInput(e,item){
         const text = e.target.innerHTML
         const text = e.target.innerHTML