diff --git a/pages/plugins/video/components/search.vue b/pages/plugins/video/components/search.vue index 18409e6c..0a97c596 100644 --- a/pages/plugins/video/components/search.vue +++ b/pages/plugins/video/components/search.vue @@ -4,7 +4,7 @@ - + 搜索 diff --git a/pages/plugins/video/detail/detail.vue b/pages/plugins/video/detail/detail.vue index c7b097cc..a2265b60 100644 --- a/pages/plugins/video/detail/detail.vue +++ b/pages/plugins/video/detail/detail.vue @@ -139,7 +139,13 @@ - + + @{{ comments_data.user.user_name_view }}:{{ comments_data.content }} + + + + + @@ -195,10 +201,27 @@ - - - - + + + + + @{{ comments_data.user.user_name_view }}:{{ comments_data.content }} + + + + + + + + + + + + + + + + @@ -210,6 +233,7 @@ const app = getApp(); import { get_math, isEmpty, video_get_top_left_padding } from '@/common/js/common/common.js'; import commentInfoComponent from '@/pages/plugins/video/components/comment-info.vue'; + import loadingComponent from '@/pages/plugins/video/components/loading.vue'; import commentMoreComponent from '@/pages/plugins/video/components/comment-more.vue'; import searchComponent from '@/pages/plugins/video/components/search.vue'; import componentSharePopup from '@/components/share-popup/share-popup'; @@ -229,7 +253,8 @@ componentSharePopup, componentNoData, componentBottomLine, - componentPopup + componentPopup, + loadingComponent }, data() { return { @@ -291,6 +316,7 @@ is_add_comment: false, // 监听键盘高度变化事件 listener_height: 0, + comments_data: {} }; }, computed: { @@ -836,7 +862,7 @@ }, // 评论输入图片删除 comment_input_img_close(e) { - const { index } = e.currentTarget.dataset; + const index = e?.currentTarget?.dataset?.index || 0; var list = this.form_images_list; list.splice(index, 1); this.setData({ @@ -1247,11 +1273,15 @@ this.active_dropdown_id = null; if (!isEmpty(comments)) { this.setData({ - input_placeholder: `@${comments.user.user_name_view}`, comments_data: comments, }); } }, + comment_data_delete() { + this.setData({ + comments_data: {}, + }); + }, // 评论点赞 comment_like(id) { this.active_dropdown_id = null; @@ -1777,9 +1807,11 @@ .comment-modal { position: fixed; top: 0; - left: 0; + left: 50%; + transform: translateX(-50%); width: 100%; height: 100%; + max-width: 1600rpx; background-color: rgba(0, 0, 0, 0.5); z-index: 99; display: flex; @@ -1856,17 +1888,20 @@ .comment-input-content { flex: 1; border: 2rpx solid #eee; - border-radius: 8rpx; - padding-right: 16rpx; + border-radius: 16rpx; + // padding-right: 16rpx; font-size: 28rpx; } + .pr-16 { + padding-right: 16rpx; + } .comment-input-img-container { padding: 10rpx 16rpx 16rpx 16rpx; } .comment-input-img-close { position: absolute; - right: -10rpx; - top: -10rpx; + right: -15rpx; + top: -15rpx; z-index: 2; } .comment-input-img { @@ -1942,12 +1977,20 @@ left: 0; z-index: 99; background: #fff; - padding: 20rpx 16rpx; + padding: 20rpx; box-sizing: border-box; } .keyboard-input-border { - padding: 16rpx 22rpx; border: 2rpx solid #ddd; - border-radius: 50rpx; + border-radius: 16rpx; + } + .keyboard-input-content { + padding: 16rpx 22rpx; + } + .comment-reply-content { + background-color: rgba(0, 0, 0, 0.6); + padding: 10rpx; + border-radius: 16rpx; + color: #fff; } diff --git a/pages/plugins/video/search/search-record.vue b/pages/plugins/video/search/search-record.vue index 121cda25..8b691200 100644 --- a/pages/plugins/video/search/search-record.vue +++ b/pages/plugins/video/search/search-record.vue @@ -44,14 +44,22 @@ - + {{ index + 1 }} {{ item.title }} - 热度 {{ item.hotness }} + + + + {{ item[search_history_data[hot_current_tab].field] }} + @@ -183,8 +191,19 @@ export default { this.handle_search(value); }, delete_history(e) { - const index = e.currentTarget.dataset.index; - this.search_history.splice(index, 1); + const index = e?.currentTarget?.dataset?.index; + const data = this.show_search_history[index]; + if (!isEmpty(data)) { + const newIndex = this.search_history.findIndex(item => item == data); + this.search_history.splice(newIndex, 1); + } + this.show_search_history.splice(index, 1); + }, + perform_url(e) { + const url = e?.currentTarget?.dataset?.url || ''; + if (!isEmpty(url)) { + app.globalData.url_open(url); + } }, view_more_history() { // 查看更多历史逻辑