王士厅
... ... @@ -299,7 +299,7 @@ export struct DynamicDetailComponent {
}.padding({
left: $r('app.float.vp_16')
, right: $r('app.float.vp_16')
})
}).width('100%')
//标题
Text(this.titleText())
.fontColor($r('app.color.color_222222'))
... ... @@ -1221,6 +1221,11 @@ struct createImg {
}
})
}
.margin({
left: $r('app.float.margin_16'),
right: $r('app.float.margin_16'),
top: $r('app.float.margin_8')
})
}
}
... ...
... ... @@ -25,6 +25,7 @@ export struct ENewspaperPageComponent {
@State picHeight: number = 0
@Provide itemPicWidth: number = 0
@Provide itemPicHeight: number = 0
@State isShowSkeleton:boolean = false
@Provide topMargin: number = DisplayUtils.getDeviceHeight()
... ... @@ -83,6 +84,7 @@ export struct ENewspaperPageComponent {
builder: ENewspaperCalendarDialog({
selectDate: this.selectDate,
onDateChange: (date: RMCalendarBean) => {
this.isShowSkeleton = true
console.log("onDateChange-日历选择弹框", "date:", JSON.stringify(date))
if (date.fullYear && date.month && date.date) {
let month: number = date.month + 1
... ... @@ -254,7 +256,7 @@ export struct ENewspaperPageComponent {
})
.id('e_newspaper_top')
if (!this.newspaperListBean || !this.newspaperListBean.list || this.newspaperListBean.list.length == 0) {
if (!this.newspaperListBean || !this.newspaperListBean.list || this.newspaperListBean.list.length == 0 || this.isShowSkeleton) {
newsSkeleton()
.alignRules({
top: { anchor: "e_newspaper_top", align: VerticalAlign.Bottom },
... ... @@ -476,6 +478,7 @@ export struct ENewspaperPageComponent {
let listBean =
await NewspaperViewModel.getNewspaperList(this.calendarDate, this.itemPicWidth + 'x' + this.itemPicHeight)
this.newspaperListBean = listBean;
this.isShowSkeleton = false
} else {
this.showToastTip('网络出小差了,请检查网络后重试')
}
... ...
... ... @@ -131,11 +131,11 @@ export struct RmhTitle {
build() {
Flex() {
Stack() {
Image(this.loadImg ? this.rmhInfo?.rmhHeadUrl : this.rmhInfo.userType == '1'?$r('app.media.default_head_userPage'):$r('app.media.comment_rmh_tag'))
.alt(this.rmhInfo.userType == '1'?$r('app.media.default_head_userPage'):$r('app.media.comment_rmh_tag'))
Image(this.loadImg ? this.rmhInfo?.rmhHeadUrl : this.rmhInfo.userType == '1'?$r('app.media.default_head_userPage'):$r('app.media.AccountOwner_DefaultIcon'))
.alt(this.rmhInfo.userType == '1'?$r('app.media.default_head_userPage'):$r('app.media.AccountOwner_DefaultIcon'))
.width(36)
.height(36)
.borderRadius(50)
.borderRadius(18)
.border({
width: 0.5,
color: '#0D000000', // 5% 透明度的黑色
... ...
... ... @@ -78,8 +78,8 @@ export struct Card12Component {
CarderInteraction({contentDTO: this.contentDTO})
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -100,8 +100,8 @@ export struct Card14Component {
//TODO 底部的:分享、评论、点赞 功能;需要引用一个公共组件
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -98,8 +98,8 @@ export struct Card15Component {
//TODO 底部的:分享、评论、点赞 功能;需要引用一个公共组件
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -131,8 +131,8 @@ export struct Card16Component {
//TODO 底部的:分享、评论、点赞 功能;需要引用一个公共组件
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: 8,
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -86,8 +86,8 @@ export struct Card19Component {
//TODO 底部的:分享、评论、点赞 功能;需要引用一个公共组件
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -109,8 +109,8 @@ export struct Card20Component {
//TODO 底部的:分享、评论、点赞 功能;需要引用一个公共组件
}
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -105,8 +105,8 @@ export struct Card21Component {
ProcessUtils.processPage(this.contentDTO)
})
.padding({
left: 16,
right: 16,
left: 10,
right: 10,
top: $r('app.float.card_comp_pagePadding_tb'),
bottom: $r('app.float.card_comp_pagePadding_tb')
})
... ...
... ... @@ -124,7 +124,7 @@ export struct Card6Component {
.borderRadius(5)
.aspectRatio(this.contentDTO.appStyle === CompStyle.Card_13 ? 3 / 2 : 3 / 4)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? 78 : 156)
.border({width: 0.5, color: 0xf5f5f5})
.border({width: 0.5, color: '#0D000000'})
.borderStyle(BorderStyle.Solid)
CardMediaInfo({ contentDTO: this.contentDTO })
}
... ...
... ... @@ -65,7 +65,7 @@ export struct ZhCarouselLayout01 {
Logger.info(TAG,
`aboutToAppear, beanList:${this.compDTO?.operDataList?.length}, currentBreakpoint:${this.currentBreakpoint}`);
let list: number[] = []
for (let i = 1; i <= this.compDTO?.operDataList?.length; i++) {
for (let i = 1; i <= this.filterAtv()?.length; i++) {
list.push(i);
}
this.data = new MyDataSource(list)
... ... @@ -84,17 +84,23 @@ export struct ZhCarouselLayout01 {
}
}
filterAtv() {
return this.compDTO.operDataList.filter(((item: ContentDTO) => {
return !item.linkUrl.includes('/h/atv')
}))
}
build() {
if (this.compDTO?.operDataList?.length) {
if (this.compDTO?.operDataList.length > 1) {
Stack() {
Swiper() {
ForEach(this.compDTO?.operDataList, (item: ContentDTO, index: number) => {
ForEach(this.filterAtv(), (item: ContentDTO, index: number) => {
CarouselLayout01CardView({
item: item,
length: this.compDTO.operDataList.length,
showPicBorderRadius: this.compDTO.operDataList.length == 1
length: this.filterAtv().length,
showPicBorderRadius: this.filterAtv().length == 1
})
.onClick((event: ClickEvent) => {
InfomationCardClick.track(this.compDTO, item, this.pageId, this.pageName)
... ... @@ -172,13 +178,13 @@ export struct ZhCarouselLayout01 {
.width(CommonConstants.FULL_WIDTH)
} else {
CarouselLayout01CardView({
item: this.compDTO.operDataList[0],
item: this.filterAtv()[0],
length: 1,
showPicBorderRadius: this.compDTO.operDataList.length == 1
showPicBorderRadius: this.filterAtv().length == 1
})
.onClick((event: ClickEvent) => {
InfomationCardClick.track(this.compDTO, this.compDTO.operDataList[0], this.pageId, this.pageName)
ProcessUtils.processPage(this.compDTO.operDataList[0])
InfomationCardClick.track(this.compDTO, this.filterAtv()[0], this.pageId, this.pageName)
ProcessUtils.processPage(this.filterAtv()[0])
})
.padding({
left: 10,
... ...
... ... @@ -109,7 +109,7 @@ struct PeopleShipHomePage {
topHeight: this.topHeight
})
.width("100%")
.height(this.topHeight)
// .height(this.topHeight)
// 列表
PeopleShipHomeListComponent({
publishCount: this.publishCount,
... ...
... ... @@ -107,7 +107,7 @@ export struct HorizontalStrokeCardThreeTwoRadioForMoreComponent {
.width(this.compDTO.operDataList.length == 2 ? 210 : 150)
.objectFit(ImageFit.Contain)
.borderRadius(4)
.border({width: 0.5, color: 0xf5f5f5})
.border({width: 0.5, color: '#0D000000'})
CardMediaInfo({
livePeopleNum:false,
contentDTO: item
... ...
... ... @@ -168,7 +168,7 @@ export struct LiveHorizontalCardComponent {
})
}
.borderRadius(4)
.border({width: 1, color: 0xf5f5f5})
.border({width: 1, color: '#0D000000'})
Text(item.newsTitle)
.fontSize(15)
... ...