diff --git a/pages/chat/index.vue b/pages/chat/index.vue index 04d438d..1c9422d 100644 --- a/pages/chat/index.vue +++ b/pages/chat/index.vue @@ -495,9 +495,9 @@ }); chat.showTools = false; // scrollBottom(); - setTimeout(()=>{ + setTimeout(() => { chat.msg = ''; - },100) + }, 100); } // 点击猜你想问 @@ -546,7 +546,7 @@ let emojiFile = selEmojiFile(item); newData = newData.replace( item, - ``, ); @@ -587,6 +587,7 @@ background-size: 750rpx 100%; z-index: 1; } + .chat-wrap { // :deep() { // .ui-navbar-box { @@ -701,10 +702,12 @@ background: #fff; color: #333; } + :deep() { .imgred { width: 100%; } + .imgred, img { width: 100%; @@ -852,3 +855,16 @@ } } + diff --git a/pages/chat/socket.js b/pages/chat/socket.js index b68dfbf..840931c 100644 --- a/pages/chat/socket.js +++ b/pages/chat/socket.js @@ -494,7 +494,7 @@ export function useChatWebSocket(socketConfig) { const img = await readImg(file); const blob = await compressImg(img, file.type); const { data } = await upload(file.name, blob); - let image = ``; + let image = ``; document.execCommand('insertHTML', false, image); } else { document.execCommand('insertHTML', false, paste.getData('text')); @@ -516,7 +516,7 @@ export function useChatWebSocket(socketConfig) { const img = await readImg(file); const blob = await compressImg(img, file.type); const { data } = await upload(file.name, blob); - let image = ``; + let image = ``; document.execCommand('insertHTML', false, image); } else { ElMessage({ @@ -818,4 +818,4 @@ export function useChatWebSocket(socketConfig) { showTime, formatTime, }; -} +} \ No newline at end of file diff --git a/sheep/components/s-goods-column/s-goods-column.vue b/sheep/components/s-goods-column/s-goods-column.vue index 1225884..80f10c5 100644 --- a/sheep/components/s-goods-column/s-goods-column.vue +++ b/sheep/components/s-goods-column/s-goods-column.vue @@ -65,12 +65,7 @@ - + { + let totalHeight = 0; const goodsPriceCard = data[0]; - const card = { - width: goodsPriceCard.width, - height: (goodsPriceCard.width / e.detail.width) * e.detail.height + goodsPriceCard.height, - }; - emits('getHeight', card.height); + if (props.data.image_wh) { + totalHeight = + (goodsPriceCard.width / props.data.image_wh.w) * props.data.image_wh.h + + goodsPriceCard.height; + } else { + totalHeight = goodsPriceCard.width; + } + emits('getHeight', totalHeight); }); } } + onMounted(() => { + nextTick(() => { + getGoodsPriceCardWH(); + }); + });