liyubing

Merge remote-tracking branch 'origin/main'

... ... @@ -60,12 +60,12 @@ export struct CarderInteraction {
})
}
if(this.contentDetailData.rmhInfo != null){
if(this.contentDetailData.shareInfo != null && 1 == this.contentDetailData.shareInfo.shareOpen && 1 == this.contentDetailData.rmhInfo.cnShareControl){
this.shareLayout()
if(this.contentDTO.rmhInfo != null){
if(this.contentDTO.shareInfo != null && 1 == this.contentDTO.shareInfo.shareOpen && 1 == this.contentDTO.rmhInfo.cnShareControl){
this.commentLayout()
}
}else{
this.shareLayout()
this.commentLayout()
}
this.builderLike()
... ... @@ -81,7 +81,7 @@ export struct CarderInteraction {
}
@Builder
shareLayout() {
commentLayout() {
Row() {
Image($r('app.media.CarderInteraction_comment'))
.width(18)
... ...
... ... @@ -17,7 +17,7 @@ export struct topicInfoView {
// } as FrontLinkObject
frontLinkObject: FrontLinkObject = {} as FrontLinkObject
@State isExpansion:boolean = false
aboutToAppear() {
}
... ... @@ -32,7 +32,7 @@ export struct topicInfoView {
})
.id('img_cover')
if (this.frontLinkObject.linkUrl.length > 0) {
if (this.frontLinkObject.linkUrl.length > 0 || this.frontLinkObject?.newsId.length > 0) {
Row() {
Text("查看详情")
.fontSize(14)
... ... @@ -54,6 +54,8 @@ export struct topicInfoView {
contentDTO.objectType = this.frontLinkObject?.newsType.toString()
contentDTO.objectId = this.frontLinkObject?.newsId
contentDTO.linkUrl = this.frontLinkObject?.linkUrl
contentDTO.relId = this.frontLinkObject?.newsRelId.toString()
contentDTO.relType = this.frontLinkObject?.newsType.toString()
ProcessUtils.processPage(contentDTO)
})
... ... @@ -65,17 +67,25 @@ export struct topicInfoView {
.id('row_detail')
}
Text(this.frontLinkObject?.summary ?? "")
.margin({ top: 10 })
Row(){
Text(this.frontLinkObject?.summary ?? "")
.fontSize(14)
.fontColor($r('app.color.white'))
.maxLines(3)
.fontColor('#CCFFFFFF')
.maxLines(this.isExpansion?999:3)
.textOverflow({ overflow: TextOverflow.Ellipsis })
Text(this.isExpansion?'收起':'展开').onClick(()=>{
this.isExpansion = !this.isExpansion
})
.fontSize(14)
.fontColor($r('app.color.white'))
}.alignItems(VerticalAlign.Bottom)
.alignRules({
left: { anchor: "__container__", align: HorizontalAlign.Start },
bottom: this.frontLinkObject.linkUrl.length > 0?{ anchor: "row_detail", align: VerticalAlign.Top }:{ anchor: "__container__", align: VerticalAlign.Bottom }
bottom: this.frontLinkObject.linkUrl.length > 0 || this.frontLinkObject?.newsId.length > 0 ?{ anchor: "row_detail", align: VerticalAlign.Top }:{ anchor: "__container__", align: VerticalAlign.Bottom }
})
.margin({ left: 16, right: 16, bottom: this.frontLinkObject.linkUrl.length > 0?0:16})
.margin({top: 10 , left: 16, right: 16, bottom: this.frontLinkObject.linkUrl.length > 0 || this.frontLinkObject?.newsId.length > 0 ?0:16})
.id('txt_summary')
Text(this.frontLinkObject?.title ?? "")
... ...
... ... @@ -112,6 +112,8 @@ interface picProps {
struct createImg {
@Prop fullColumnImgUrls: FullColumnImgUrlDTO[]
@State loadImg: boolean = false;
@State onePicW: number = 0; // 只有一张图时候图片的宽度
@State onePicH: number = 0; // 只有一张图时候图片的高度
async aboutToAppear(): Promise<void> {
if (this.fullColumnImgUrls.length === 4) { // 为了使用栅格布局以便于占用三分之二的宽度,加一个占位
... ... @@ -177,7 +179,7 @@ struct createImg {
Image(this.loadImg ? item.fullUrl || item.url : '')
.backgroundColor(0xf5f5f5)
.width('100%')
.height(172)
.height(198)
.autoResize(true)
.borderRadius(this.caclImageRadius(index))
} else if (this.getPicType(item.weight, item.height) === 2) {
... ... @@ -215,14 +217,18 @@ struct createImg {
}
} else {
GridCol({
span: item.landscape === 1 ? 12 : 8
span: this.onePicW > this.onePicH ? 12 : 8
}) {
Image(this.loadImg ? item.fullUrl : '')
.backgroundColor(0xf5f5f5)
.aspectRatio(item.landscape === 1 ? 343 / 172 : 228 / 305)
.aspectRatio(this.onePicW > this.onePicH ? 343 / 198 : 228 / 305)
.autoResize(true)
.borderRadius(this.caclImageRadius(index))
.opacity(!item.weight && !item.height ? 0 : 1)
.onComplete((event?) => {
this.onePicW = event?.width || 0;
this.onePicH = event?.height || 0;
})
}
}
} else if (this.fullColumnImgUrls.length === 4) {
... ...
... ... @@ -88,7 +88,7 @@ export struct Card6Component {
.fontSize(18)
.lineHeight(27)
.fontWeight(FontWeight.Normal)
.maxLines(this.contentDTO.appStyle === '6' ? 4 : 2)
.maxLines(this.contentDTO.appStyle === '6' ? 4 : 3)
.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(this.contentDTO.appStyle === CompStyle.Card_13 ? 78 : 156)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? '' : 156)
.justifyContent(FlexAlign.SpaceBetween)
... ... @@ -138,7 +138,8 @@ export struct Card6Component {
})
.width(CommonConstants.FULL_WIDTH)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? 106 : 184) .justifyContent(FlexAlign.SpaceBetween)
.height(this.contentDTO.appStyle === CompStyle.Card_13 ? '' : 184)
.justifyContent(FlexAlign.SpaceBetween)
.alignItems(VerticalAlign.Top)
}
}
... ...
... ... @@ -133,6 +133,7 @@ struct MineHomePage {
.backgroundImageSize(ImageSize.Cover)
.padding({left:"17lpx",right:"8lpx"})
.height('35lpx')
.borderRadius({topRight:2,bottomRight:2})
}
Blank()
... ...
... ... @@ -74,7 +74,10 @@ struct ForgetPasswordPage {
})
}.padding({ left: 25, right: 25 }).width('100%')
}.width('100%').height('100%').alignItems(HorizontalAlign.Start)
}.width('100%')
.height('100%')
.alignItems(HorizontalAlign.Start)
.backgroundColor(Color.White)
}
aboutToAppear() {
... ...
... ... @@ -241,7 +241,8 @@ struct LoginPage {
.visibility(this.isProtocol ? Visibility.Visible : Visibility.None)
}.width('100%')
.height('100%').backgroundColor(Color.White)
.height('100%')
.backgroundColor(Color.White)
}
@Builder
... ... @@ -280,6 +281,7 @@ struct LoginPage {
.width('100%')
}.padding({ left: 25, right: 25 }).width('100%').margin({ top: 36 })
.visibility(this.checkCodePage ? Visibility.None : Visibility.Visible)
.backgroundColor(Color.White)
}
... ...
... ... @@ -214,6 +214,17 @@ export struct MultiPictureDetailPageComponent {
left: 16,
right: 0
})
.onClick(() => {
if (this.contentDetailData.rmhInfo?.cnMainControl === 1) {
// 号主页
const params: Params = {
creatorId: this.contentDetailData.rmhInfo.rmhId,
pageID: ''
}
WDRouterRule.jumpWithPage(WDRouterPage.peopleShipHomePage, params)
}
})
Row() {
if (this.followStatus == '0') {
... ...