ai-chat-bot-interface 1.6.8 → 1.6.9
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
|
@@ -117,7 +117,9 @@ const subStr = computed(() => {
|
|
|
117
117
|
return `${props.defMsg.energy}${props.info.energy}kcal,${props.defMsg.protein}${props.info.protein}g,${props.defMsg.fat}${props.info.fat}g,${props.defMsg.carbonwater}${props.info.carbonwater}g`;
|
|
118
118
|
});
|
|
119
119
|
const materialText = computed(() => {
|
|
120
|
-
const list = props.info?.makeMaterialList?.map(
|
|
120
|
+
const list = props.info?.makeMaterialList?.map(
|
|
121
|
+
(item) => item.material + item.usage + 'g',
|
|
122
|
+
);
|
|
121
123
|
return (list || []).join('、');
|
|
122
124
|
});
|
|
123
125
|
const hasDetails = computed(() => {
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
width: fit-content;
|
|
25
25
|
white-space: nowrap;
|
|
26
26
|
font-weight: 400;
|
|
27
|
-
font-size:
|
|
27
|
+
font-size: 14px;
|
|
28
28
|
color: #333;
|
|
29
29
|
line-height: 16px;
|
|
30
30
|
text-align: left;
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
border: 1px solid #d0d0d0;
|
|
34
34
|
}
|
|
35
35
|
.icon {
|
|
36
|
-
font-size:
|
|
36
|
+
font-size: 18px;
|
|
37
37
|
color: @primary-color;
|
|
38
38
|
}
|
|
39
39
|
}
|
|
@@ -245,6 +245,16 @@ const selectTag = (item, type) => {
|
|
|
245
245
|
dialogInfo.value[type].push(item);
|
|
246
246
|
}
|
|
247
247
|
};
|
|
248
|
+
|
|
249
|
+
const selectSport = (item) => {
|
|
250
|
+
dialogInfo.value.sport = item.name;
|
|
251
|
+
handleConfirm();
|
|
252
|
+
};
|
|
253
|
+
|
|
254
|
+
const selectSex = (item) => {
|
|
255
|
+
dialogInfo.value.sex = item;
|
|
256
|
+
handleConfirm();
|
|
257
|
+
};
|
|
248
258
|
</script>
|
|
249
259
|
|
|
250
260
|
<template>
|
|
@@ -269,7 +279,7 @@ const selectTag = (item, type) => {
|
|
|
269
279
|
:class="{ disabled: !isValid }"
|
|
270
280
|
@click.stop="handleSubmit"
|
|
271
281
|
>
|
|
272
|
-
|
|
282
|
+
按身体数据领取7天食谱
|
|
273
283
|
</div>
|
|
274
284
|
</div>
|
|
275
285
|
|
|
@@ -283,13 +293,13 @@ const selectTag = (item, type) => {
|
|
|
283
293
|
<div v-if="dialogInfo.key === 'sex'" class="sex_wrap">
|
|
284
294
|
<div
|
|
285
295
|
:class="{ sex: true, selected: dialogInfo.sex === '男' }"
|
|
286
|
-
@click="
|
|
296
|
+
@click.stop="selectSex('男')"
|
|
287
297
|
>
|
|
288
298
|
男
|
|
289
299
|
</div>
|
|
290
300
|
<div
|
|
291
301
|
:class="{ sex: true, selected: dialogInfo.sex === '女' }"
|
|
292
|
-
@click="
|
|
302
|
+
@click.stop="selectSex('女')"
|
|
293
303
|
>
|
|
294
304
|
女
|
|
295
305
|
</div>
|
|
@@ -302,6 +312,7 @@ const selectTag = (item, type) => {
|
|
|
302
312
|
v-model="dialogInfo[dialogInfo.key]"
|
|
303
313
|
class="input"
|
|
304
314
|
type="text"
|
|
315
|
+
@keyup.enter="handleConfirm"
|
|
305
316
|
placeholder="请输入"
|
|
306
317
|
/>
|
|
307
318
|
<div class="unit">{{ dialogInfo.unit }}</div>
|
|
@@ -311,7 +322,7 @@ const selectTag = (item, type) => {
|
|
|
311
322
|
v-for="item in sportList"
|
|
312
323
|
:key="item.key"
|
|
313
324
|
:class="{ row: true, selected: dialogInfo.sport === item.name }"
|
|
314
|
-
@click.stop="
|
|
325
|
+
@click.stop="selectSport(item)"
|
|
315
326
|
>
|
|
316
327
|
<div class="name">{{ item.name }}</div>
|
|
317
328
|
<div class="sub">{{ item.sub }}</div>
|
|
@@ -360,6 +371,7 @@ const selectTag = (item, type) => {
|
|
|
360
371
|
|
|
361
372
|
&_row {
|
|
362
373
|
display: flex;
|
|
374
|
+
gap: 6px;
|
|
363
375
|
flex-direction: row;
|
|
364
376
|
align-items: center;
|
|
365
377
|
justify-content: space-between;
|
|
@@ -391,7 +403,7 @@ const selectTag = (item, type) => {
|
|
|
391
403
|
display: inline-block;
|
|
392
404
|
font-size: 14px;
|
|
393
405
|
text-align: right;
|
|
394
|
-
width:
|
|
406
|
+
width: 156px;
|
|
395
407
|
text-overflow: ellipsis;
|
|
396
408
|
white-space: nowrap;
|
|
397
409
|
overflow: hidden;
|