chengen02

Merge remote-tracking branch 'origin/main'

... ... @@ -219,8 +219,7 @@ struct createImg {
}) {
Image(this.loadImg ? item.fullUrl : '')
.backgroundColor(0xf5f5f5)
.width(113)
.height(113)
.aspectRatio(item.landscape === 1 ? 343 / 172 : 228 / 305)
.autoResize(true)
.borderRadius(this.caclImageRadius(index))
.opacity(!item.weight && !item.height ? 0 : 1)
... ...
... ... @@ -88,7 +88,7 @@ export struct Card6Component {
.fontSize(18)
.lineHeight(27)
.fontWeight(FontWeight.Normal)
.maxLines(this.contentDTO.appStyle === '6' ? 5 : 2)
.maxLines(this.contentDTO.appStyle === '6' ? 4 : 2)
.alignSelf(ItemAlign.Start)
.textOverflow({ overflow: TextOverflow.Ellipsis }) // 超出的部分显示省略号。
.textIndent((this.contentDTO.newTags?.length || this.contentDTO.seoTags?.length) > 2 &&
... ... @@ -107,7 +107,7 @@ export struct Card6Component {
}
.alignItems(HorizontalAlign.Start)
.height(78)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? 78 : 156)
.justifyContent(FlexAlign.SpaceBetween)
... ... @@ -119,7 +119,7 @@ export struct Card6Component {
.backgroundColor(this.loadImg ? $r('app.color.color_B0B0B0') : 0xf5f5f5)
.borderRadius(5)
.aspectRatio(this.contentDTO.appStyle === CompStyle.Card_13 ? 3 / 2 : 3 / 4)
.height(78)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? 78 : 156)
CardMediaInfo({ contentDTO: this.contentDTO })
}
... ... @@ -138,8 +138,7 @@ export struct Card6Component {
})
.width(CommonConstants.FULL_WIDTH)
.height(106)
.justifyContent(FlexAlign.SpaceBetween)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? 106 : 184) .justifyContent(FlexAlign.SpaceBetween)
.alignItems(VerticalAlign.Top)
}
}
... ...
... ... @@ -4,7 +4,7 @@ import PageModel from '../../viewmodel/PageModel';
import { CommonConstants, ViewType } from 'wdConstant'
import { EmptyComponent,WDViewDefaultType } from '../view/EmptyComponent'
import { ErrorComponent } from '../view/ErrorComponent'
import { CompDTO, ContentDTO } from 'wdBean'
import { CompDTO, ContentDTO, contentListParams,contentListItem } from 'wdBean'
import NoMoreLayout from './NoMoreLayout'
import { CustomSelectUI } from '../view/CustomSelectUI';
import { CustomBottomFuctionUI } from '../view/CustomBottomFuctionUI';
... ... @@ -149,16 +149,13 @@ struct MyCollectionListPage {
.margin({left:16})
}
Column() {
BigPicCardComponent({compDTO:new CompDTO,contentDTO:compDTO})
BigPicCardComponent({compDTO:new CompDTO,contentDTO:compDTO,pageId:TrackConstants.PageName.My_Collect,pageName:TrackConstants.PageName.My_Collect})
}
}.onVisibleAreaChange([0.0, 1.0], (isVisible: boolean, currentRatio: number) => {
if (isVisible) {
TrackingContent.common(TrackConstants.EventType.Show, TrackConstants.PageName.My_Collect,TrackConstants.PageName.My_Collect, TrackParamConvert.program(compDTO))
}
})
// .onClick(()=>{
// TrackingContent.common(TrackConstants.EventType.Click, TrackConstants.PageName.My_Collect,TrackConstants.PageName.My_Collect, TrackParamConvert.program(compDTO))
// })
}
... ... @@ -262,4 +259,12 @@ struct MyCollectionListPage {
}
}
getContentData(){
for (let index = 0; index < this.allDatas.length; index++) {
const compDTO = this.allDatas[index];
compDTO.isCollection = true ///用于时间展示
this.allDatas.push(compDTO)
}
}
}
\ No newline at end of file
... ...
... ... @@ -15,6 +15,8 @@ const TAG: string = 'BigPicCardComponent';
@Component
export struct BigPicCardComponent {
@ObjectLink compDTO: CompDTO
@State pageId: string = '';
@State pageName: string = '';
contentDTO: ContentDTO = new ContentDTO();
aboutToAppear() {
... ... @@ -110,7 +112,7 @@ export struct BigPicCardComponent {
@Builder
cardBuild() {
CardParser({ compDTO: this.compDTO, contentDTO: this.contentDTO });
CardParser({ compDTO: this.compDTO, contentDTO: this.contentDTO,pageId:this.pageId,pageName:this.pageName});
}
}
... ...
... ... @@ -66,7 +66,7 @@ export struct TopPlayComponent {
* 更新直播播放数据
*/
updateData() {
// 检测等待中的直播预告是否视频资源
// 检测直播等待状态的直播预告是否视频资源
if (this.contentDetailData.liveInfo && this.contentDetailData.liveInfo.previewType === 1
&& this.contentDetailData?.liveInfo?.liveState == 'wait'
&& this.contentDetailData.liveInfo.previewUrl &&
... ... @@ -79,7 +79,6 @@ export struct TopPlayComponent {
if (this.contentDetailData.liveInfo && this.contentDetailData.liveInfo.previewUrl &&
this.contentDetailData.liveInfo.previewUrl.length > 0) {
this.previewUrl = this.contentDetailData.liveInfo.previewUrl
} else if (this.contentDetailData.fullColumnImgUrls && this.contentDetailData.fullColumnImgUrls.length > 0) {
this.previewUrl = this.contentDetailData.fullColumnImgUrls[0].url
}
... ... @@ -126,8 +125,8 @@ export struct TopPlayComponent {
}
// 直播结束
if (this.contentDetailData?.liveInfo?.liveState === 'end') {
this.isHideLoading = true
this.isWait = StringUtils.isNotEmpty(this.playUrl)
this.isHideLoading = !StringUtils.isNotEmpty(this.playUrl)
this.isWait = !StringUtils.isNotEmpty(this.playUrl)
}
... ... @@ -141,7 +140,7 @@ export struct TopPlayComponent {
this.previewUrl = ''
}
}
//Logger.debug(TAG, `---0------>` + this.isWait + ' ->' + this.isHideLoading + ' ->' + this.isEnd+' -->'+this.isVideoSource)
// Logger.debug(TAG, `---0------>` + this.isWait + ' ->' + this.isHideLoading + ' ->' + this.isEnd+' -->'+this.isVideoSource)
}
tryToPlay() {
... ...
... ... @@ -74,6 +74,22 @@ struct LaunchAdvertisingPage {
bottom: 0
})
if (this.defaultModel.isAd === '1'){
Stack({alignContent:Alignment.TopStart}){
Text('广告')
.fontColor(Color.White)
.textAlign(TextAlign.Center)
.fontSize('24lpx')
.width('72lpx')
.height('36lpx')
.borderRadius(2)
.margin({top:'15lpx',left:'19lpx'})
.backgroundColor('#80000000')
}
.width('100%')
.height('100%')
}
Stack({alignContent:Alignment.TopEnd}){
Button(){
Text(this.time + 's 跳过')
... ... @@ -95,22 +111,6 @@ struct LaunchAdvertisingPage {
.width('100%')
.height('100%')
if (this.defaultModel.isAd === '1'){
Stack({alignContent:Alignment.TopStart}){
Text('广告')
.fontColor(Color.White)
.textAlign(TextAlign.Center)
.fontSize('24lpx')
.width('72lpx')
.height('36lpx')
.borderRadius(2)
.margin({top:'15lpx',left:'19lpx'})
.backgroundColor('#80000000')
}
.width('100%')
.height('100%')
}
if(this.defaultModel.screenType != '2'){
//底部logo样式 按钮加载在背景展示图上
Button(){
... ...
... ... @@ -179,7 +179,7 @@ export struct VideoChannelPage {
channelId: item.channelId + '',
autoRefresh: this.autoRefresh
})
.padding({ top: 40 })
.padding({ top: 55 })
.backgroundColor(Color.White)
}
}, (item: TopNavDTO) => item.channelId + '')
... ...