askbot-dragon 0.6.25 → 0.6.29

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": "0.6.25",
3
+ "version": "0.6.29",
4
4
  "scripts": {
5
5
  "serve": "vue-cli-service serve",
6
6
  "build": "vue-cli-service build",
@@ -13,6 +13,26 @@
13
13
  .button-item:last-child{
14
14
  margin-bottom: 0!important;
15
15
  }
16
+ .buttonClassItem{
17
+ width: 178px;
18
+ /* padding: 0px 30px;*/
19
+ height: 30px;
20
+ background: #FFFFFF;
21
+ border: 1px solid #BBCDFF;
22
+ border-radius: 14px;
23
+ color: #366aff;
24
+ display: flex;
25
+ align-content: center;
26
+ justify-content: center;
27
+ overflow: hidden;
28
+ text-overflow: ellipsis;
29
+ white-space: nowrap;
30
+ cursor: pointer;
31
+ .btn-name{
32
+ display: flex;
33
+ align-items: center;
34
+ }
35
+ }
16
36
  .isCompayClass{
17
37
  .el-divider--horizontal{
18
38
  margin: 8px 0 0 0 !important;
@@ -28,14 +48,6 @@
28
48
  }
29
49
  }
30
50
  }
31
- .buttonClassItem{
32
- font-weight: 600;
33
- text-align: center;
34
- border-top: 1.5px solid #DCDFE6;
35
- padding: 8px 0;
36
- color: #366aff;
37
- cursor: pointer;
38
- }
39
51
  .singleClass{
40
52
  padding: 8px 0;
41
53
  div, h1, h2, h3, h4, h5, h6, li, dt, dd, p, blockquote, pre, form, fieldset, table, th, td{
@@ -71,7 +83,7 @@
71
83
  overflow: hidden;
72
84
  img{
73
85
  width: 100%;
74
- height:calc(80vw / 2.35);
86
+ height:calc((100vw - 120px) / 2.35);
75
87
  object-fit: contain;
76
88
  }
77
89
  }
@@ -127,22 +139,6 @@
127
139
  }
128
140
  }
129
141
  }
130
- .buttonClassItem{
131
- /* width: 178px;*/
132
- padding: 0px 30px;
133
- height: 30px;
134
- background: #FFFFFF;
135
- border: 1px solid #BBCDFF;
136
- border-radius: 14px;
137
- color: #366aff;
138
- display: flex;
139
- align-content: center;
140
- justify-content: center;
141
- .btn-name{
142
- display: flex;
143
- align-items: center;
144
- }
145
- }
146
142
  }
147
143
  .singleClass{
148
144
  display: flex;
@@ -31,7 +31,8 @@
31
31
  <!-- 满意或不满意-->
32
32
  <bot-action-satisfactor :msg="botActionSatis"></bot-action-satisfactor>
33
33
  <answer-dissatisfaction :msg="answerDiss"></answer-dissatisfaction>
34
-
34
+ <feed-back :feedBack="feedBack"></feed-back>
35
+ <voice-compontent></voice-compontent>
35
36
  <!-- <FileType :urls="urls" :color="black"></FileType>-->
36
37
  <!-- <FileType :urls="urls" :color="black"></FileType>
37
38
  <chat-content :messageList="messageList"></chat-content>-->
@@ -55,6 +56,7 @@ import LoadingProcess from "./loadingProcess";
55
56
  import BotActionSatisfactor from "./botActionSatisfactor";
56
57
  import AnswerDissatisfaction from "./answerDissatisfaction";
57
58
  import ActionSendToBot from "./actionSendToBot";
59
+ import VoiceCompontent from './voiceComponent'
58
60
  /* import TicketMessage from "@/components/message/TicketMessage";
59
61
  import TicketMessage from "@/components/message/TicketMessage";
60
62
  import TextMessage from "@/components/message/TextMessage";
@@ -63,7 +65,7 @@ import FeedBack from "@/components/feedBack";*/
63
65
  /*import ActionAlert from "@/components/message/ActionAlertIframe";*/
64
66
  /*import FileType from "@/components/FileType";
65
67
  import ChatContent from "./chatContent";*/
66
-
68
+ import FeedBack from "@/components/feedBack"
67
69
  export default {
68
70
  name: "ConversationContainer",
69
71
  components: {
@@ -80,7 +82,8 @@ export default {
80
82
  AnswerRadio,
81
83
  FormTemplate,
82
84
  TextMessage,
83
-
85
+ FeedBack,
86
+ VoiceCompontent
84
87
 
85
88
 
86
89
  },
@@ -1197,6 +1200,7 @@ export default {
1197
1200
  <style scoped lang="less">
1198
1201
  @import "../assets/less/converSationContainer/converSatonContainer";
1199
1202
  #conversation{
1203
+ background-color:#F5F7FB ;
1200
1204
  }
1201
1205
  .img_div{
1202
1206
  position: relative;
@@ -18,7 +18,7 @@
18
18
  满意<i class="arsenal_icon arsenalangle-right-solid"></i>
19
19
  </p>
20
20
  <p
21
- class="statisfaction-item end"
21
+ class="statisfaction-item"
22
22
  @click="
23
23
  sendSatisfaction(
24
24
  'USER_ACTION_TO_SATISFACTION_V2',
@@ -2,14 +2,11 @@
2
2
  <div
3
3
  class="action-send-to-bot"
4
4
  >
5
- <p class="other" v-html="msg.content.description"></p>
5
+ <p class="bot-des" v-html="msg.content.description"></p>
6
6
  <div class="options-list">
7
7
  <p
8
8
  v-for="(option, index) in msg.content.options"
9
- v-bind:class="[
10
- index == msg.content.options.length - 1 ? 'end' : '',
11
- 'options-item',
12
- ]"
9
+ class="options-item"
13
10
  :key="msg.nodeId + '_' + index"
14
11
  @click="$emit('onRadioClick2', option.content, option.name, msg.apiKey)"
15
12
  >
@@ -29,7 +26,7 @@
29
26
 
30
27
  <style scoped lang="less">
31
28
  .action-send-to-bot{
32
- .other {
29
+ .bot-des {
33
30
  word-wrap: break-word;
34
31
  word-break: break-all;
35
32
  overflow: hidden;
@@ -50,10 +47,9 @@
50
47
  display: flex;
51
48
  align-items: center;
52
49
  justify-content: space-between;
53
- }
54
- .end{
55
- border-bottom-left-radius: 25px !important;
56
- border-bottom-right-radius: 25px !important;
50
+ i{
51
+ padding-left: 10px;
52
+ }
57
53
  }
58
54
  }
59
55
  }
@@ -3,7 +3,7 @@
3
3
  <p class="satisfaction-reply-text" v-html="msg.content.replyText"></p>
4
4
  <p
5
5
  v-for="(option, index) in msg.content.replyOptions"
6
- v-bind:class="[ index == msg.content.replyOptions.length - 1 ? 'end' : '','statisfaction-item']"
6
+ class="statisfaction-item"
7
7
  :key="index"
8
8
  @click="sendDissatisfaction(option,msg.apiKey)">
9
9
  {{ option.name }}<i class="arsenal_icon arsenalangle-right-solid"></i>
@@ -22,11 +22,12 @@ export default {
22
22
  props:['msg'],
23
23
  methods:{
24
24
  sendDissatisfaction(option,apiKey){
25
- let value = JSON.stringify({
25
+ this.$emit('sendDissatisfaction',option,apiKey)
26
+ /*let value = JSON.stringify({
26
27
  input: option.name,
27
28
  reply_text: option.answer
28
29
  });
29
- this.$emit('sendMessage','USER_ACTION_TO_DISSATISFACTION_V2',value,null,apiKey);
30
+ this.$emit('sendMessage','USER_ACTION_TO_DISSATISFACTION_V2',value,null,apiKey);*/
30
31
  }
31
32
  }
32
33
  }
@@ -1,13 +1,10 @@
1
1
  <template>
2
2
  <div id="answer-radio">
3
- <p class="other" v-html="msg.content.description"></p>
3
+ <p class="radio-description" v-html="msg.content.description"></p>
4
4
  <div class="options-list">
5
5
  <div
6
6
  v-for="(option, index) in msg.content.options"
7
- v-bind:class="[
8
- index == msg.content.options.length - 1 ? 'end' : '',
9
- 'options-item',
10
- ]"
7
+ class="options-item"
11
8
  :key="msg.nodeId + '_' + index"
12
9
  @click="
13
10
  $emit(
@@ -33,11 +30,12 @@ export default {
33
30
 
34
31
  <style scoped lang="less">
35
32
  #answer-radio{
36
- .other {
33
+ .radio-description {
37
34
  word-wrap: break-word;
38
35
  word-break: break-all;
39
36
  overflow: hidden;
40
- padding: 8px 10px 10px 0;
37
+ /*padding: 8px 10px 10px 0;*/
38
+ padding-bottom: 10px;
41
39
  height: auto;
42
40
  border-bottom: 1px solid #EEEEEE;
43
41
  }
@@ -54,6 +52,9 @@ export default {
54
52
  display: flex;
55
53
  align-items: center;
56
54
  justify-content: space-between;
55
+ i{
56
+ padding-left: 10px;
57
+ }
57
58
  }
58
59
  .end{
59
60
  border-bottom-left-radius: 25px !important;
@@ -4,15 +4,15 @@
4
4
  <p v-html="msg.content.replace(/\#[\u4E00-\u9FA5]{1,3}\;/gi, emotion)"></p>
5
5
  </div>
6
6
  <div v-if=" (msgType === 'answer_welcofmetext' || msgType === 'answer_text') && (msg.recommend&& msg.recommend.status)">
7
- <p class="media-body-ps-text-box" v-html="msg.content.replace(/\#[\u4E00-\u9FA5]{1,3}\;/gi, emotion)"></p>
8
- <recommend :msg="msg"></recommend>
7
+ <p v-html="msg.content.replace(/\#[\u4E00-\u9FA5]{1,3}\;/gi, emotion)" class="answer-rich-text"></p>
8
+ <Recommend :msg="msg" @onRadioClickReco="onRadioClickReco"></Recommend>
9
9
  </div>
10
10
  <div v-if="msg.type === 'answer_rich_text' && !(msg.content.recommend != undefined && msg.content.recommend.status)">
11
11
  <p v-html="$options.filters.imageStyle(msg.content.html)"></p>
12
12
  </div>
13
13
  <div v-else-if="msg.type == 'answer_rich_text' && (msg.content.recommend != undefined && msg.content.recommend.status)">
14
- <p style="padding: 12px 0" v-html="$options.filters.imageStyle(msg.content.html)"></p>
15
- <recommend :msg="msg.content"></recommend>
14
+ <p v-html="$options.filters.imageStyle(msg.content.html)" class="answer-rich-text"></p>
15
+ <Recommend :msg="msg.content" @onRadioClickReco="onRadioClickReco"></Recommend>
16
16
  </div>
17
17
  <div v-else-if="msgType === 'answer_image'" >
18
18
  <div
@@ -26,17 +26,14 @@
26
26
  class="img-class"
27
27
  />
28
28
  </div>
29
- <recommend :msg="msg"></recommend>
29
+ <Recommend :msg="msg" @onRadioClickReco="onRadioClickReco"></Recommend>
30
30
  </div>
31
- <div v-else-if="msgType === 'answer_video' || msgType === 'user_video' || msgType === 'VIDEO'"
32
- class="media-body-ps1">
31
+ <div v-else-if="msgType === 'answer_video' || msgType === 'user_video' || msgType === 'VIDEO'">
33
32
  <div class="association-img">
34
33
  <ask-video :msg="msg" :url="msg.content.url" :local-url="msg.content.localUrl"
35
34
  :progress="msg.content.progress"></ask-video>
36
35
  </div>
37
- <div class="media-body-ps" style="border-radius: 0 0 32px 32px;">
38
- <recommend :msg="msg"></recommend>
39
- </div>
36
+ <Recommend :msg="msg" @onRadioClickReco="onRadioClickReco"></Recommend>
40
37
  </div>
41
38
  </div>
42
39
  </template>
@@ -71,8 +68,12 @@
71
68
  let index = list.indexOf(word)
72
69
  return `<img height="20px" src="https://guoranim.oss-cn-beijing.aliyuncs.com/emoji/${index+1}.png" align="middle">`
73
70
  },
74
- onRadioClickReco(){},
75
- onImageClick(){},
71
+ onRadioClickReco(id, name, apikey) {
72
+ this.$emit("onRadioClick", id, name, apikey);
73
+ },
74
+ onImageClick(url){
75
+ console.debug('onImageClick',url)
76
+ },
76
77
  }
77
78
  }
78
79
  </script>
@@ -85,6 +86,13 @@
85
86
  /*display: flex;
86
87
  align-items: center;
87
88
  justify-content: center;*/
89
+ .options-list{
90
+ padding-top: 8px;
91
+ }
92
+ }
93
+ .answer-rich-text{
94
+ padding-bottom: 12px;
95
+ border-bottom: 1px solid #EEEEEE;
88
96
  }
89
97
  }
90
98
 
@@ -9,10 +9,7 @@
9
9
  <p
10
10
 
11
11
  v-for="(option, index) in msg.content.reply_options"
12
- v-bind:class="[
13
- index == msg.content.reply_options.length - 1 ? 'end' : '',
14
- 'statisfaction-item',
15
- ]"
12
+ class="statisfaction-item"
16
13
  :key="index"
17
14
  @click="
18
15
  onSatisfactionClick(
@@ -234,7 +234,8 @@
234
234
  display: flex;
235
235
  -ms-flex-align: start;
236
236
  align-items: flex-start;
237
- max-width: 80%;
237
+ /*max-width: 80%;*/
238
+ max-width: calc(100vw - 50px);
238
239
  .media-body-image{
239
240
  background-color: #F4F8FC;
240
241
  border: 1px solid #F4F8FC;
@@ -1,12 +1,12 @@
1
1
  <template>
2
2
  <div id="feedBack" class="companyNotRem" :class="{phoneClass:isPhone,companyClass:isCompany,notClick:isDisabled===true}">
3
- <span class="feed-positive-button" >
4
- <el-button round class="btnClass" @click="positiveFeedback(feedBack,1)" v-html="feedBack.positiveFeedback.text" v-if="positiveClick ===false">{{feedBack.positiveFeedback.text}}</el-button>
5
- <el-button round class="btnClassActive" v-html="feedBack.positiveFeedback.text" v-if="positiveClick ===true">{{feedBack.positiveFeedback.text}}</el-button>
3
+ <span :class="!positiveClick?'feed-positive-button':'feed-check-positive-button'">
4
+ <el-button round class="btnClass" @click="positiveFeedback(feedBack,1)" v-html="feedBack.positiveFeedback.text" v-if="!positiveClick">{{feedBack.positiveFeedback.text}}</el-button>
5
+ <el-button round class="btnClassActive" v-html="feedBack.positiveFeedback.text" v-else>{{feedBack.positiveFeedback.text}}</el-button>
6
6
  </span>
7
- <span class="feed-negative-button">
8
- <el-button round class="btnClass" @click="positiveFeedback(feedBack,2)" v-html="feedBack.negativeFeedback.text" v-if="negativeClick ===false">{{feedBack.negativeFeedback.text}}</el-button>
9
- <el-button round class="btnClassActive" v-html="feedBack.negativeFeedback.text" v-if="negativeClick ===true">{{feedBack.negativeFeedback.text}}</el-button>
7
+ <span :class="!negativeClick?'feed-negative-button':'feed-check-negative-button'">
8
+ <el-button round class="btnClass" @click="positiveFeedback(feedBack,2)" v-html="feedBack.negativeFeedback.text" v-if="!negativeClick">{{feedBack.negativeFeedback.text}}</el-button>
9
+ <el-button round class="btnClassActive" v-html="feedBack.negativeFeedback.text" v-else>{{feedBack.negativeFeedback.text}}</el-button>
10
10
  </span>
11
11
  </div>
12
12
  </template>
@@ -93,6 +93,25 @@ name: "feedBack",
93
93
  font-weight: 400;
94
94
  }
95
95
  }
96
+ .feed-check-positive-button{
97
+ margin-right: 8px;
98
+ /deep/.el-button{
99
+ border: 1px solid #4C61E1;
100
+ color: #FFFFFF;
101
+ background-color: #4C61E1;
102
+ border-radius: 14px;
103
+ font-weight: 400;
104
+ }
105
+ }
106
+ .feed-check-negative-button{
107
+ /deep/.el-button{
108
+ border: 1px solid #4C61E1;
109
+ color: #FFFFFF;
110
+ background-color: #4C61E1;
111
+ border-radius: 14px;
112
+ font-weight: 400;
113
+ }
114
+ }
96
115
  .feed-negative-button{
97
116
  background: #FFFFFF;
98
117
  /deep/.el-button{
@@ -117,10 +136,6 @@ name: "feedBack",
117
136
  line-height: 0.9;
118
137
  }
119
138
  }
120
- .btnClassActive{
121
- color: #ffffff;
122
- background-color: #4C61E1
123
- }
124
139
  .companyClass{
125
140
  /* min-width: 300px;*/
126
141
  width: 370px;
@@ -136,10 +151,4 @@ name: "feedBack",
136
151
  .notClick{
137
152
  pointer-events: none;
138
153
  }
139
- .positiveActive{
140
- color: red;
141
- }
142
- .negativeActive{
143
- color: red;
144
- }
145
154
  </style>
@@ -337,11 +337,11 @@ export default {
337
337
  if(flag){
338
338
  this.isPhone=true
339
339
  let el=this.$el
340
- el.style.width='80vw'
340
+ el.style.width='calc(100vw - 120px)'
341
341
  let swiper=document.getElementsByClassName('swiper')
342
342
  for (let i=0;i<swiper.length;i++)
343
343
  {
344
- swiper[i].style.width='80vw'
344
+ swiper[i].style.width='calc(100vw - 120px)'
345
345
  console.log(swiper[i].style.width)
346
346
  }
347
347
 
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <div class="media-body-loading">
2
+ <div class="media-body-loadings">
3
3
  <svg viewBox="0 0 120 120" width="30px" height="30px" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
4
4
  <g id="circle" class="g-circles g-circles--v1">
5
5
  <circle id="12" transform="translate(35, 16.698730) rotate(-30) translate(-35, -16.698730) " cx="35" cy="16.6987298" r="10"></circle>
@@ -56,7 +56,7 @@ export default {
56
56
  .circle__svg {
57
57
  transform: rotate(-90deg);
58
58
  }
59
- .media-body-loading {
59
+ .media-body-loadings {
60
60
  background-color: #DEE3F0;
61
61
  /* background-color: #f4f8fc;*/
62
62
  /* border: 1px solid #f4f8fc;*/
@@ -1,13 +1,11 @@
1
1
  <template>
2
2
  <div class="text-recommed-intent">
3
- <p class="other" v-if="msg.recommend&&msg.recommend.description" v-html="msg.recommend.description"></p>
3
+ <p class="intent-des" v-if="msg.recommend&&msg.recommend.description" v-html="msg.recommend.description"></p>
4
4
  <div v-if="msg.recommend.list" class="options-list">
5
5
  <p
6
6
  v-for="(option, index) in msg.recommend.list"
7
- v-bind:class="[
8
- index == msg.recommend.list.length - 1 ? 'end' : '',
9
- 'options-item',
10
- ]"
7
+ class="options-item"
8
+ :class="index!==msg.recommend.list.length -1?'recommend-item':'last-item'"
11
9
  :key="msg.nodeId + '_' + index"
12
10
  @click="
13
11
  $emit(
@@ -43,21 +41,23 @@ export default {
43
41
  <style scoped lang="less">
44
42
  .text-recommed-intent{
45
43
  /* max-width: 300px;*/
46
- .other{
44
+ background-color: white;
45
+ .intent-des{
47
46
  word-wrap: break-word;
48
47
  word-break: break-all;
49
48
  overflow: hidden;
50
- padding: 14px 0;
49
+ padding: 10px 0;
51
50
  height: auto;
52
51
  border-bottom: 1px solid #EEEEEE;
53
52
  color: #A9B3C6;
54
53
  font-size: 13px;
54
+ background-color: white;
55
55
  }
56
56
  .options-list{
57
- padding-top: 8px;
57
+ /*padding-top: 8px;*/
58
58
  /*padding-right: 10px;*/
59
59
  .options-item{
60
- padding: 8px 0;
60
+
61
61
  height: 25px;
62
62
  line-height: 25px;
63
63
  background-color: #ffffff;
@@ -66,6 +66,15 @@ export default {
66
66
  display: flex;
67
67
  align-items: center;
68
68
  justify-content: space-between;
69
+ i{
70
+ padding-left: 10px;
71
+ }
72
+ }
73
+ .recommend-item{
74
+ padding: 8px 0;
75
+ }
76
+ .last-item{
77
+ padding-top: 8px;
69
78
  }
70
79
  .end{
71
80
  border-bottom-left-radius: 25px !important;
@@ -41,6 +41,7 @@ export default {
41
41
  bottom: 0;
42
42
  width: 100%;
43
43
  z-index: 9999;
44
+ left: 0;
44
45
  #voice-component-container{
45
46
  position: relative;
46
47
  #voice-component-c{
@@ -48,7 +49,7 @@ export default {
48
49
  width: 130%;
49
50
  position: relative;
50
51
  left: -15%;
51
- background: linear-gradient(180deg, #E7E7E7, #FFFFFF);
52
+ background: linear-gradient(180deg, #f2f2f2, #FFFFFF);
52
53
  border: 2px solid white;
53
54
  border-radius: 100% 100% 0 0;
54
55
  border-bottom: none;