askbot-dragon 1.3.52 → 1.3.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "askbot-dragon",
3
- "version": "1.3.52",
3
+ "version": "1.3.54",
4
4
  "scripts": {
5
5
  "serve": "vue-cli-service serve",
6
6
  "build": "vue-cli-service build",
@@ -55,16 +55,23 @@ export default {
55
55
  setTimeout(() => {
56
56
  console.log(this._$(`#audioTagCom_${this.msg.content.extInfos[0].avCurrentTime}`)[0]);
57
57
  this.activeAudio = this._$(`#audioTagCom_${this.msg.content.extInfos[0].avCurrentTime}`)[0];
58
+ this.activeAudio.load()
58
59
  this.time = "00:00";
59
- this.otherTime = this.transTime(this.activeAudio.duration);
60
- this.durationNum = this.activeAudio.duration;
61
- console.log(this.activeAudio.duration);
62
- this.allTime = this.transTime(this.activeAudio.duration);
63
- if (this.activeAudio.duration >= 60) {
64
- this.boxWidth = 240;
65
- } else {
66
- this.boxWidth = 160 + this.activeAudio.duration;
67
- }
60
+ new Promise(resolve => {
61
+ this.activeAudio.addEventListener('durationchange', () =>{
62
+ this.otherTime = this.transTime(this.activeAudio.duration);
63
+ this.durationNum = this.activeAudio.duration;
64
+ console.log(this.activeAudio.duration);
65
+ this.allTime = this.transTime(this.activeAudio.duration);
66
+ if (this.activeAudio.duration >= 60) {
67
+ this.boxWidth = 240;
68
+ } else {
69
+ this.boxWidth = 160 + this.activeAudio.duration;
70
+ }
71
+ resolve()
72
+ });
73
+ // this.activeAudio.addEventListener('canplay', resolve);
74
+ })
68
75
  this._$(`#audioTagCom_${this.msg.content.extInfos[0].avCurrentTime}`).on("loadedmetadata", (e) => {
69
76
  console.log(e.currentTarget);
70
77
  this.time = "00:00";
@@ -119,18 +119,38 @@ export default {
119
119
  return {
120
120
  black:'',
121
121
  answerVoiceObj: {
122
- id: "643f8e7c235d0d20541170d712",
123
- intentId: 152859,
124
- nodeId: "643ce95db62c5d38f1706242",
125
- type: "answer_voice",
126
- content: {
127
- filenName: "二月兰.mp3",
128
- url: "https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/front-oss/6b11f188b3cb4d73ba8305039f32d0da/2023/04/19/14/47/5ffbef1135ae52eb2bb5029323f5404c/二月兰.mp3",
129
- extInfo: [{
130
- avCurrentTime: 123
131
- }]
132
- }
133
- },
122
+ "actionCategory": "START_NODE",
123
+ "apiKey": "81d9d6c3f13d4e1aa239cacee3192475",
124
+ "content": {
125
+ "filenName": "合成配音.mp3",
126
+ "extInfos": [
127
+ {
128
+ "duration": 4.752,
129
+ "avCurrentTime": 1683272364032,
130
+ "isShowUploadVideo": true,
131
+ "videoUploadPercent": 0,
132
+ "videoFlag": false
133
+ }
134
+ ],
135
+ "recommend": {
136
+ "description": "",
137
+ "list": [
138
+ {
139
+ "ext": {
140
+ "intentValue": []
141
+ },
142
+ "id": "",
143
+ "text": "",
144
+ "type": 0
145
+ }
146
+ ],
147
+ "status": false
148
+ },
149
+ "url": "https://guoranopen-zjk.oss-cn-zhangjiakou.aliyuncs.com/front-oss/31623ccfe9dd4957bbd59c5823878bbe/2023/05/05/15/39/8755f665880695ca44e7ac7d2cf10d9e/voice_88755f665880695ca44e7ac7d2cf10d9.mp3"
150
+ },
151
+ "id": "6454b2c4cb83047f0816f4b9",
152
+ "type": "answer_voice"
153
+ },
134
154
  answerVoiceObj1: {
135
155
  id: "643f8e7c235d0d20541170d712",
136
156
  intentId: 152859,