Showing
2 changed files
with
12 additions
and
8 deletions
sight_harmony/features/wdComponent/src/main/ets/components/comment/view/QualityCommentsComponent.ets
| @@ -37,21 +37,21 @@ export struct QualityCommentsComponent { | @@ -37,21 +37,21 @@ export struct QualityCommentsComponent { | ||
| 37 | aboutToDisappear(): void { | 37 | aboutToDisappear(): void { |
| 38 | // windowClass.setWindowSystemBarProperties({ statusBarColor: '#000' }) | 38 | // windowClass.setWindowSystemBarProperties({ statusBarColor: '#000' }) |
| 39 | this.dialogController = null // 将dialogController置空 | 39 | this.dialogController = null // 将dialogController置空 |
| 40 | - WindowModel.shared.setWindowLayoutFullScreen(false) | 40 | + // WindowModel.shared.setWindowLayoutFullScreen(false) |
| 41 | } | 41 | } |
| 42 | 42 | ||
| 43 | onPageShow(): void { | 43 | onPageShow(): void { |
| 44 | - WindowModel.shared.setWindowLayoutFullScreen(true) | 44 | + // WindowModel.shared.setWindowLayoutFullScreen(true) |
| 45 | } | 45 | } |
| 46 | 46 | ||
| 47 | onPageHide(): void { | 47 | onPageHide(): void { |
| 48 | - WindowModel.shared.setWindowLayoutFullScreen(false) | 48 | + // WindowModel.shared.setWindowLayoutFullScreen(false) |
| 49 | } | 49 | } |
| 50 | 50 | ||
| 51 | aboutToAppear(): void { | 51 | aboutToAppear(): void { |
| 52 | this.getData(); | 52 | this.getData(); |
| 53 | this.showAlert() | 53 | this.showAlert() |
| 54 | - WindowModel.shared.setWindowLayoutFullScreen(true) | 54 | + // WindowModel.shared.setWindowLayoutFullScreen(true) |
| 55 | } | 55 | } |
| 56 | 56 | ||
| 57 | showAlert() { | 57 | showAlert() { |
| @@ -106,6 +106,7 @@ export struct QualityCommentsComponent { | @@ -106,6 +106,7 @@ export struct QualityCommentsComponent { | ||
| 106 | Image($r('app.media.comment_img_banner')).width('100%') | 106 | Image($r('app.media.comment_img_banner')).width('100%') |
| 107 | .height(283) | 107 | .height(283) |
| 108 | // .aspectRatio(375 / 283); | 108 | // .aspectRatio(375 / 283); |
| 109 | + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP]) | ||
| 109 | } | 110 | } |
| 110 | .onAreaChange((oldValue: Area, newValue: Area) => { | 111 | .onAreaChange((oldValue: Area, newValue: Area) => { |
| 111 | if (Number(oldValue.globalPosition.y) == 0 && Number(newValue.globalPosition.y) > 30) { | 112 | if (Number(oldValue.globalPosition.y) == 0 && Number(newValue.globalPosition.y) > 30) { |
| @@ -156,13 +157,15 @@ export struct QualityCommentsComponent { | @@ -156,13 +157,15 @@ export struct QualityCommentsComponent { | ||
| 156 | /*导航栏*/ | 157 | /*导航栏*/ |
| 157 | @Builder | 158 | @Builder |
| 158 | TabbarNormal() { | 159 | TabbarNormal() { |
| 159 | - Column() { | 160 | + Stack({ alignContent: Alignment.Top }) { |
| 160 | Row() { | 161 | Row() { |
| 161 | } | 162 | } |
| 162 | .width('100%') | 163 | .width('100%') |
| 163 | .height(px2vp(this.topSafeHeight)) | 164 | .height(px2vp(this.topSafeHeight)) |
| 164 | .backgroundColor($r('app.color.white')) | 165 | .backgroundColor($r('app.color.white')) |
| 165 | .opacity(this.tileOpacity) | 166 | .opacity(this.tileOpacity) |
| 167 | + .visibility(this.tileOpacity > 0 ? 0 : 1) | ||
| 168 | + .expandSafeArea([SafeAreaType.SYSTEM], [SafeAreaEdge.TOP]) | ||
| 166 | 169 | ||
| 167 | Stack({ alignContent: Alignment.Start }) { | 170 | Stack({ alignContent: Alignment.Start }) { |
| 168 | Row() { | 171 | Row() { |
| @@ -218,6 +221,7 @@ export struct QualityCommentsComponent { | @@ -218,6 +221,7 @@ export struct QualityCommentsComponent { | ||
| 218 | .scrollBar(BarState.Off) | 221 | .scrollBar(BarState.Off) |
| 219 | .edgeEffect(EdgeEffect.None) | 222 | .edgeEffect(EdgeEffect.None) |
| 220 | 223 | ||
| 224 | + .clip(false) | ||
| 221 | // this.TabbarTransparent() | 225 | // this.TabbarTransparent() |
| 222 | this.TabbarNormal() | 226 | this.TabbarNormal() |
| 223 | } | 227 | } |
| @@ -253,7 +257,7 @@ export struct QualityCommentsComponent { | @@ -253,7 +257,7 @@ export struct QualityCommentsComponent { | ||
| 253 | this.currentPage++ | 257 | this.currentPage++ |
| 254 | this.getData() | 258 | this.getData() |
| 255 | }) | 259 | }) |
| 256 | - .margin({ top: 196 }) | 260 | + .margin({ top: 196 - px2vp(this.topSafeHeight) }) |
| 257 | .height("100%") | 261 | .height("100%") |
| 258 | .width("100%") | 262 | .width("100%") |
| 259 | .edgeEffect(EdgeEffect.None) // 必须设置列表为滑动到边缘无效果 | 263 | .edgeEffect(EdgeEffect.None) // 必须设置列表为滑动到边缘无效果 |
| @@ -5,11 +5,11 @@ import { QualityCommentsComponent } from '../comment/view/QualityCommentsCompone | @@ -5,11 +5,11 @@ import { QualityCommentsComponent } from '../comment/view/QualityCommentsCompone | ||
| 5 | @Component | 5 | @Component |
| 6 | struct QualityCommentsPage { | 6 | struct QualityCommentsPage { |
| 7 | onPageShow(): void { | 7 | onPageShow(): void { |
| 8 | - WindowModel.shared.setWindowLayoutFullScreen(true) | 8 | + // WindowModel.shared.setWindowLayoutFullScreen(true) |
| 9 | } | 9 | } |
| 10 | 10 | ||
| 11 | onPageHide(): void { | 11 | onPageHide(): void { |
| 12 | - WindowModel.shared.setWindowLayoutFullScreen(false) | 12 | + // WindowModel.shared.setWindowLayoutFullScreen(false) |
| 13 | } | 13 | } |
| 14 | 14 | ||
| 15 | build() { | 15 | build() { |
-
Please register or login to post a comment