|
@@ -80,7 +80,7 @@
|
|
|
>
|
|
|
<span class="NNPE-words-box">
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
:class="[
|
|
|
pItem.className ? pItem.className : '',
|
|
@@ -104,7 +104,7 @@
|
|
|
>{{ NumberList.indexOf(pItem.pinyin) == -1 ? pItem.chs : '' }}</span
|
|
|
>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
:class="[
|
|
|
pItem.className ? pItem.className : '',
|
|
@@ -116,7 +116,7 @@
|
|
|
</span>
|
|
|
<span class="NNPE-words-box">
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
style="text-align: left"
|
|
|
:class="[noFont.indexOf(item.wordsList[pIndex + 1].pinyin) > -1 ? 'noFont' : '']"
|
|
@@ -146,7 +146,7 @@
|
|
|
}}</span
|
|
|
>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
:class="[noFont.indexOf(item.wordsList[pIndex + 1].pinyin) > -1 ? 'noFont' : '']"
|
|
|
@click.stop="viewNotes($event, item.wordsList[pIndex + 1].pinyin)"
|
|
@@ -164,7 +164,7 @@
|
|
|
"
|
|
|
>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
:class="[
|
|
|
'NNPE-pinyin',
|
|
|
noFont.indexOf(item.wordsList[pIndex + 2].pinyin) > -1 ? 'noFont' : '',
|
|
@@ -205,7 +205,7 @@
|
|
|
}}</span
|
|
|
>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
:class="[
|
|
|
'NNPE-pinyin',
|
|
|
noFont.indexOf(item.wordsList[pIndex + 2].pinyin) > -1 ? 'noFont' : '',
|
|
@@ -218,7 +218,7 @@
|
|
|
</template>
|
|
|
<template v-else>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'top' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
:class="[
|
|
|
pItem.chs != '“' && pItem.padding ? 'padding' : '',
|
|
@@ -245,7 +245,7 @@
|
|
|
>{{ NumberList.indexOf(pItem.pinyin) == -1 ? pItem.chs : '' }}</span
|
|
|
>
|
|
|
<span
|
|
|
- v-if="curQue.pyPosition == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
+ v-if="curQue.property.pinyin_position == 'bottom' && config.isShowPY && item.dhaspinyin"
|
|
|
class="NNPE-pinyin"
|
|
|
:class="[
|
|
|
pItem.chs != '“' && pItem.padding ? 'padding' : '',
|
|
@@ -300,7 +300,7 @@
|
|
|
</template>
|
|
|
<template v-if="isShow">
|
|
|
<div
|
|
|
- ref="wordcard"
|
|
|
+ ref="dialogueWordcard"
|
|
|
class="NNPE-wordDetail"
|
|
|
:style="{
|
|
|
marginLeft:
|
|
@@ -328,7 +328,7 @@
|
|
|
</template>
|
|
|
<template v-if="isNoteShow">
|
|
|
<div
|
|
|
- ref="notecard"
|
|
|
+ ref="dialogueNotecard"
|
|
|
class="NNPE-wordDetail NNPE-noteDetail"
|
|
|
:style="{
|
|
|
marginLeft: windowWidth > 642 ? '-321px' : '0px',
|
|
@@ -450,7 +450,8 @@ export default {
|
|
|
let _this = this;
|
|
|
if (val) {
|
|
|
setTimeout(() => {
|
|
|
- _this.cardHeight = _this.$refs.wordcard.offsetHeight;
|
|
|
+ console.log(_this.$refs.dialogueWordcard);
|
|
|
+ _this.cardHeight = _this.$refs.dialogueWordcard.offsetHeight;
|
|
|
if (_this.screenHeight - _this.clientY > _this.cardHeight) {
|
|
|
_this.top = _this.clientY + 20;
|
|
|
} else {
|
|
@@ -477,7 +478,7 @@ export default {
|
|
|
let _this = this;
|
|
|
if (val) {
|
|
|
setTimeout(() => {
|
|
|
- _this.cardHeight = _this.$refs.notecard.offsetHeight;
|
|
|
+ _this.cardHeight = _this.$refs.dialogueNotecard.offsetHeight;
|
|
|
if (_this.screenHeight - _this.clientY > _this.cardHeight) {
|
|
|
_this.top = _this.clientY + 20;
|
|
|
} else {
|
|
@@ -678,14 +679,14 @@ export default {
|
|
|
|
|
|
handleNewword() {
|
|
|
let NewWordList = [];
|
|
|
- this.NNPENewWordList.forEach((item) => {
|
|
|
- item.forEach((wItem) => {
|
|
|
- if (wItem.new_word) {
|
|
|
- NewWordList.push(wItem.new_word);
|
|
|
- } else if (wItem.detail && wItem.detail.sentence) {
|
|
|
- NewWordList.push(wItem.detail.sentence);
|
|
|
- }
|
|
|
- });
|
|
|
+ this.NNPENewWordList.forEach((wItem) => {
|
|
|
+ // item.forEach((wItem) => {
|
|
|
+ if (wItem.new_word) {
|
|
|
+ NewWordList.push(wItem.new_word);
|
|
|
+ } else if (wItem.detail && wItem.detail.sentence) {
|
|
|
+ NewWordList.push(wItem.detail.sentence);
|
|
|
+ }
|
|
|
+ // });
|
|
|
});
|
|
|
this.newWordList = JSON.parse(JSON.stringify(NewWordList));
|
|
|
},
|
|
@@ -749,21 +750,21 @@ export default {
|
|
|
this.word = null;
|
|
|
for (let i = 0; i < this.NNPENewWordList.length; i++) {
|
|
|
let pItem = this.NNPENewWordList[i];
|
|
|
- for (let j = 0; j < pItem.length; j++) {
|
|
|
- let item = pItem[j];
|
|
|
- if (item.new_word.trim() == val.trim()) {
|
|
|
- let wordlist = val.split('');
|
|
|
- this.word = JSON.parse(
|
|
|
- JSON.stringify({
|
|
|
- list: wordlist,
|
|
|
- detail: item,
|
|
|
- top: top,
|
|
|
- left: left,
|
|
|
- }),
|
|
|
- );
|
|
|
- break;
|
|
|
- }
|
|
|
+ // for (let j = 0; j < pItem.length; j++) {
|
|
|
+ let item = pItem;
|
|
|
+ if (item.new_word.trim() == val.trim()) {
|
|
|
+ let wordlist = val.split('');
|
|
|
+ this.word = JSON.parse(
|
|
|
+ JSON.stringify({
|
|
|
+ list: wordlist,
|
|
|
+ detail: item,
|
|
|
+ top: top,
|
|
|
+ left: left,
|
|
|
+ }),
|
|
|
+ );
|
|
|
+ break;
|
|
|
}
|
|
|
+ // }
|
|
|
}
|
|
|
this.oldHz = val;
|
|
|
},
|
|
@@ -772,14 +773,14 @@ export default {
|
|
|
_this.clickType = 'note';
|
|
|
let noteIndex = '';
|
|
|
_this.wordPlayMp3 = '';
|
|
|
- _this.NNPENewWordList.forEach((items) => {
|
|
|
- items.forEach((itemn) => {
|
|
|
- if (itemn.new_word === noteNum) {
|
|
|
- _this.wordbgs = itemn.bg;
|
|
|
- _this.wordeds = itemn.ed;
|
|
|
- _this.wordPlayMp3 = itemn.newWordMp3;
|
|
|
- }
|
|
|
- });
|
|
|
+ _this.NNPENewWordList.forEach((itemn) => {
|
|
|
+ // items.forEach((itemn) => {
|
|
|
+ if (itemn.new_word === noteNum) {
|
|
|
+ _this.wordbgs = itemn.bg;
|
|
|
+ _this.wordeds = itemn.ed;
|
|
|
+ _this.wordPlayMp3 = itemn.newWordMp3;
|
|
|
+ }
|
|
|
+ // });
|
|
|
});
|
|
|
if (_this.NumberList.indexOf(noteNum) > -1) {
|
|
|
for (let i = 0; i < _this.NumberList.length; i++) {
|