|
|
@@ -118,12 +118,22 @@
|
|
|
:translations="data.multilingual"
|
|
|
@SubmitTranslation="handleMultilingualTranslation"
|
|
|
/>
|
|
|
- <el-divider v-if="isEnable(data.property.view_pinyin)" content-position="left">拼音效果</el-divider>
|
|
|
+ <el-divider v-if="isEnable(data.property.view_pinyin)" content-position="left"
|
|
|
+ >拼音效果<el-button
|
|
|
+ v-show="isEnable(data.property.view_pinyin)"
|
|
|
+ type="text"
|
|
|
+ icon="el-icon-refresh"
|
|
|
+ title="刷新"
|
|
|
+ class="refresh-pinyin-btn"
|
|
|
+ @click.native="identifyText"
|
|
|
+ /></el-divider>
|
|
|
+
|
|
|
<PinyinText
|
|
|
v-if="isEnable(data.property.view_pinyin)"
|
|
|
:id="'table_pinyin_text'"
|
|
|
ref="PinyinText"
|
|
|
:paragraph-list="data.paragraph_list"
|
|
|
+ :rich-text-list="data.rich_text_list"
|
|
|
:pinyin-position="data.property.pinyin_position"
|
|
|
:pinyin-size="data?.unified_attrib?.pinyin_size"
|
|
|
:font-size="data?.unified_attrib?.font_size"
|
|
|
@@ -309,7 +319,8 @@ export default {
|
|
|
// .replace(/<span class="rich-fill".*?>(.*?)<\/span>|([_]{3,})/gi, '###$1$2###');
|
|
|
});
|
|
|
}
|
|
|
- text += `${items.content.replace(/<[^>]+>/g, '')}\n`;
|
|
|
+ // text += `${items.content.replace(/<[^>]+>/g, '')}\n`;
|
|
|
+ text += `${items.content}\n`;
|
|
|
});
|
|
|
});
|
|
|
if (isEnable(this.data.property.view_pinyin)) {
|
|
|
@@ -322,9 +333,11 @@ export default {
|
|
|
this.data.paragraph_list_parameter.pinyin_proofread_word_list = [];
|
|
|
return;
|
|
|
}
|
|
|
- this.data.paragraph_list_parameter.text = text.replace(/<[^>]+>/g, '');
|
|
|
+ // .replace(/<[^>]+>/g, '')
|
|
|
+ this.data.paragraph_list_parameter.text = text;
|
|
|
this.data.paragraph_list_parameter.is_first_sentence_first_hz_pinyin_first_char_upper_case =
|
|
|
this.data.property.is_first_sentence_first_hz_pinyin_first_char_upper_case;
|
|
|
+ this.data.paragraph_list_parameter.is_rich_text = 'true';
|
|
|
PinyinBuild_OldFormat(this.data.paragraph_list_parameter).then((res) => {
|
|
|
if (res.parsed_text) {
|
|
|
const mergedData = res.parsed_text.paragraph_list.map((outerArr, i) =>
|
|
|
@@ -346,6 +359,7 @@ export default {
|
|
|
),
|
|
|
);
|
|
|
this.data.paragraph_list = mergedData;
|
|
|
+ this.$set(this.data, 'rich_text_list', res.rich_text.text_list);
|
|
|
let pinyin_index = 0;
|
|
|
this.data.option_list.forEach((item, index) => {
|
|
|
item.forEach((items, indexs) => {
|