diff --git a/pages/mine/components/topicItemNew/topicItemNew.js b/pages/mine/components/topicItemNew/topicItemNew.js new file mode 100644 index 0000000..6734f51 --- /dev/null +++ b/pages/mine/components/topicItemNew/topicItemNew.js @@ -0,0 +1,25 @@ +const app = getApp() + +Component({ + data: { + imagesList: ['../../../../images/mine/timg.jpg'] + }, + properties: { + topicObj: { + type: Object, + value: {} + } + }, + methods:{ + toDetail (e) { + this.triggerEvent('toTopicDetail', { topicId: e.currentTarget.dataset.topicid}) + }, + previewImage (e) { + app.globalData.previewImage = true + wx.previewImage({ + urls: this.data.topicObj.images, + current: e.currentTarget.dataset.src + }) + } + } +}) \ No newline at end of file diff --git a/pages/mine/components/topicItemNew/topicItemNew.json b/pages/mine/components/topicItemNew/topicItemNew.json new file mode 100644 index 0000000..32640e0 --- /dev/null +++ b/pages/mine/components/topicItemNew/topicItemNew.json @@ -0,0 +1,3 @@ +{ + "component": true +} \ No newline at end of file diff --git a/pages/mine/components/topicItemNew/topicItemNew.wxml b/pages/mine/components/topicItemNew/topicItemNew.wxml new file mode 100644 index 0000000..b886ff1 --- /dev/null +++ b/pages/mine/components/topicItemNew/topicItemNew.wxml @@ -0,0 +1,37 @@ + + + + + {{topicObj.nickname}} + {{topicObj.createdTime}} + + + {{topicObj.topicContent}} + + + + + + + + + {{topicObj.supportNum}} + + + + {{topicObj.commentNum}} + + + + + {{item_.username}}:{{item_.content}} + + \ No newline at end of file diff --git a/pages/mine/components/topicItemNew/topicItemNew.wxss b/pages/mine/components/topicItemNew/topicItemNew.wxss new file mode 100644 index 0000000..883a9ab --- /dev/null +++ b/pages/mine/components/topicItemNew/topicItemNew.wxss @@ -0,0 +1,211 @@ +.item-list { + /* width: calc(100% - 40rpx); */ + padding: 40rpx 29rpx 20rpx 29rpx; + background: #fff; + margin-top: 20rpx; + border-radius: 16rpx; +} + +.user-info { + /* width: calc(100% - 58rpx); */ + height: 64rpx; + display: flex; + align-items: center; +} + +.user-info image { + border-radius: 50rpx; + width: 64rpx; + height: 64rpx; +} + +.user-info .name-date { + margin-left: 14rpx; + height: 100%; + display: flex; + flex-direction: column; +} + +.user-info .name-date .name { + font-size: 28rpx; + font-weight: bold; + color: rgba(51, 51, 51, 1); +} + +.user-info .name-date .date { + font-size: 20rpx; + font-weight: 500; + color: rgba(153, 153, 153, 1); +} + +.details-info { + /* width: calc(100% - 58rpx); */ + font-size: 36rpx; + font-weight: 500; + color: rgba(51, 51, 51, 1); + line-height: 54rpx; +} + +.image-list { + /* width: calc(100% - 58rpx); */ + margin-top: 30rpx; + display: grid; + grid-template-columns: repeat(auto-fit, minmax(216rpx, 1fr)); + grid-gap: 7rpx; +} + +.image-list .image-item { + width: 100%; + height: 100%; + object-fit: cover; + border-radius: 8rpx; +} + +.attitude { + /* width: calc(100% - 300rpx); */ + margin-top: 21rpx; + display: flex; + align-items: center; + justify-content: space-between; + /* justify-content: center; */ + height: 28rpx; + padding: 0 50rpx; +} + +.attitude .all { + display: flex; + align-items: center; +} + +.attitude .all image { + width: 28rpx; + height: 28rpx; +} + +.attitude .all .give-data { + font-size: 24rpx; + font-weight: 500; + color: rgba(51, 51, 51, 1); + margin-left: 9rpx; + /* width: 196rpx; */ +} + +.attitude .all .give-data.color { + color: #FFB103; +} + +.comment { + /* width: calc(100% - 98rpx); */ + padding: 26rpx 20rpx; + background: #F2F2F2; + border-radius: 8rpx; + margin-top: 25rpx; +} + +.comment .comment-list { + width: 100%; + margin-top: 11rpx; + font-size: 28rpx; + color: #999999; +} + +.comment .comment-list text { + color: #333333; +} + +/* 评论样式 */ +.release { + align-items: flex-end; + /*底部对齐*/ + box-sizing: border-box; + position: fixed; + left: 0; + bottom: 0; + width: 100%; + padding: 13rpx 20rpx; + background-color: #fff; + font-size: 28rpx; + z-index: 999; +} + +.replyinfo1 { + display: flex; + justify-content: space-between; + /*两端对齐*/ + font-size: 35rpx; +} + +.replyinfo2 { + display: flex; + justify-content: space-between; + /*两端对齐*/ +} + +.release textarea { + /* width: calc(100% - 200rpx); */ + min-height: 34rpx; + max-height: 102rpx; + /*最多显示三行*/ + border-width: 15rpx 20rpx; + /*使用padding与预期留白不一致,故使用border*/ + border-style: solid; + border-color: #F2F2F2; + line-height: 34rpx; + font-size: 28rpx; + background-color: #F2F2F2; + border-radius: 4rpx; +} + +.release .text { + font-size: 40rpx; + color: #c9c9c9; +} + +.cancel { + width: 240rpx; + height: 64rpx; + line-height: 64rpx; + text-align: center; + color: #6c0; + margin: 0 3px; + padding: 0; +} + +.release .submit { + width: 160rpx; + height: 60rpx; + line-height: 60rpx; + text-align: center; + margin: 0 3px; + padding: 0; + font-size: 32rpx; + font-weight: 500; + color: rgba(255, 255, 255, 1); + background: linear-gradient(to right, #e95027, #db1a1f); + border-radius: 50rpx; +} + + +.pro-box .info .text .delete { + color: #f68135; + border-radius: 50rpx; + border: 1px solid #f68135; + font-size: 28 rpx; + width: 150rpx; + height: 48rpx; + text-align: center; +} + +.addIssue { + width: 178rpx; + height: 178rpx; + position: fixed; + bottom: 30%; + right: 14rpx; +} + +.addIssue image { + width: 100%; + height: 100%; + object-fit: cover; +} \ No newline at end of file diff --git a/pages/mine/mine.js b/pages/mine/mine.js index 482efaa..b217722 100644 --- a/pages/mine/mine.js +++ b/pages/mine/mine.js @@ -283,14 +283,14 @@ Page({ }) }, // 话题列表 跳转详情 - toTopicDetail(e) { - const { - topicId - } = e.detail - wx.navigateTo({ - url: `/subpages/association/pages/topicDetail/topicDetail?detailId=${topicId}` - }) - }, + // toTopicDetail(e) { + // const { + // topicId + // } = e.detail + // wx.navigateTo({ + // url: `/subpages/association/pages/topicDetail/topicDetail?detailId=${topicId}` + // }) + // }, // 我有事说 addIssue() { if (this.data.infoCompleted == 0) { diff --git a/pages/mine/mine.json b/pages/mine/mine.json index a660765..4aa93e3 100644 --- a/pages/mine/mine.json +++ b/pages/mine/mine.json @@ -5,7 +5,7 @@ "preload-issue-item": "./components/preloadIssueItem/preloadIssueItem", "project-item": "./components/projectItem/projectItem", "preload-project-item": "./components/preloadProjectItem/preloadProjectItem", - "topic-item": "./components/topicItem/topicItem", + "topic-item": "./components/topicItemNew/topicItemNew", "preload-topic-item": "./components/preloadTopicItem/preloadTopicItem", "load-more": "../../components/loadMore/loadMore", "completeInfo-dialog": "../../components/completeInfoDialog/completeInfoDialog"