Showing
1 changed file
with
18 additions
and
9 deletions
| @@ -2,6 +2,7 @@ import { ContentDTO, slideShows } from 'wdBean'; | @@ -2,6 +2,7 @@ import { ContentDTO, slideShows } from 'wdBean'; | ||
| 2 | import { CommonConstants } from 'wdConstant'; | 2 | import { CommonConstants } from 'wdConstant'; |
| 3 | import { ProcessUtils } from 'wdRouter'; | 3 | import { ProcessUtils } from 'wdRouter'; |
| 4 | import { CardSourceInfo } from '../cardCommon/CardSourceInfo'; | 4 | import { CardSourceInfo } from '../cardCommon/CardSourceInfo'; |
| 5 | +import { CardMediaInfo } from '../cardCommon/CardMediaInfo'; | ||
| 5 | 6 | ||
| 6 | /** | 7 | /** |
| 7 | * 大专题卡--CompStyle: 10 | 8 | * 大专题卡--CompStyle: 10 |
| @@ -23,9 +24,6 @@ export struct Card10Component { | @@ -23,9 +24,6 @@ export struct Card10Component { | ||
| 23 | .maxLines(2) | 24 | .maxLines(2) |
| 24 | .textOverflow({ overflow: TextOverflow.Ellipsis }) | 25 | .textOverflow({ overflow: TextOverflow.Ellipsis }) |
| 25 | .margin({ bottom: 19 }) | 26 | .margin({ bottom: 19 }) |
| 26 | - .onClick((event: ClickEvent) => { | ||
| 27 | - ProcessUtils.processPage(this.contentDTO) | ||
| 28 | - }) | ||
| 29 | } | 27 | } |
| 30 | // 大图 | 28 | // 大图 |
| 31 | Stack() { | 29 | Stack() { |
| @@ -111,12 +109,23 @@ export struct Card10Component { | @@ -111,12 +109,23 @@ export struct Card10Component { | ||
| 111 | 109 | ||
| 112 | // 右侧图片 | 110 | // 右侧图片 |
| 113 | if (item.fullColumnImgUrls[0] && item.fullColumnImgUrls[0].url) { | 111 | if (item.fullColumnImgUrls[0] && item.fullColumnImgUrls[0].url) { |
| 114 | - Image(item.fullColumnImgUrls[0].url) | ||
| 115 | - .width(117) | ||
| 116 | - .height(78) | ||
| 117 | - .objectFit(ImageFit.Cover) | ||
| 118 | - .borderRadius($r('app.float.image_border_radius')) | ||
| 119 | - .margin({ left: 12 }) | 112 | + Stack() { |
| 113 | + Image(item.fullColumnImgUrls[0].url) | ||
| 114 | + .width(117) | ||
| 115 | + .height(78) | ||
| 116 | + .objectFit(ImageFit.Cover) | ||
| 117 | + .borderRadius($r('app.float.image_border_radius')) | ||
| 118 | + .margin({ left: 12 }) | ||
| 119 | + CardMediaInfo({ | ||
| 120 | + contentDTO: { | ||
| 121 | + objectType: String(item.objectType), | ||
| 122 | + videoInfo: { videoDuration: Number(item.videoDuration) as number }, | ||
| 123 | + photoNum: Number(item.photoNum), | ||
| 124 | + voiceInfo: { voiceDuration: Number(item.voiceDuration) as number } | ||
| 125 | + } as ContentDTO | ||
| 126 | + }) | ||
| 127 | + } | ||
| 128 | + .alignContent(Alignment.BottomEnd) | ||
| 120 | } | 129 | } |
| 121 | } | 130 | } |
| 122 | .padding({ top: 10, bottom: 10 }) | 131 | .padding({ top: 10, bottom: 10 }) |
-
Please register or login to post a comment