douaojie

fix: 大专题卡显示音视频信息

... ... @@ -2,6 +2,7 @@ import { ContentDTO, slideShows } from 'wdBean';
import { CommonConstants } from 'wdConstant';
import { ProcessUtils } from 'wdRouter';
import { CardSourceInfo } from '../cardCommon/CardSourceInfo';
import { CardMediaInfo } from '../cardCommon/CardMediaInfo';
/**
* 大专题卡--CompStyle: 10
... ... @@ -23,9 +24,6 @@ export struct Card10Component {
.maxLines(2)
.textOverflow({ overflow: TextOverflow.Ellipsis })
.margin({ bottom: 19 })
.onClick((event: ClickEvent) => {
ProcessUtils.processPage(this.contentDTO)
})
}
// 大图
Stack() {
... ... @@ -111,12 +109,23 @@ export struct Card10Component {
// 右侧图片
if (item.fullColumnImgUrls[0] && item.fullColumnImgUrls[0].url) {
Image(item.fullColumnImgUrls[0].url)
.width(117)
.height(78)
.objectFit(ImageFit.Cover)
.borderRadius($r('app.float.image_border_radius'))
.margin({ left: 12 })
Stack() {
Image(item.fullColumnImgUrls[0].url)
.width(117)
.height(78)
.objectFit(ImageFit.Cover)
.borderRadius($r('app.float.image_border_radius'))
.margin({ left: 12 })
CardMediaInfo({
contentDTO: {
objectType: String(item.objectType),
videoInfo: { videoDuration: Number(item.videoDuration) as number },
photoNum: Number(item.photoNum),
voiceInfo: { voiceDuration: Number(item.voiceDuration) as number }
} as ContentDTO
})
}
.alignContent(Alignment.BottomEnd)
}
}
.padding({ top: 10, bottom: 10 })
... ...