Showing
5 changed files
with
21 additions
and
3 deletions
| @@ -20,16 +20,28 @@ export struct TopNavigationComponent { | @@ -20,16 +20,28 @@ export struct TopNavigationComponent { | ||
| 20 | build() { | 20 | build() { |
| 21 | Column() { | 21 | Column() { |
| 22 | RelativeContainer(){ | 22 | RelativeContainer(){ |
| 23 | + Stack({ alignContent: Alignment.Center }){ | ||
| 24 | + | ||
| 25 | + Image($r('app.media.background_search')) | ||
| 26 | + .width('100%') | ||
| 27 | + .height('100%') | ||
| 28 | + .objectFit(ImageFit.Contain) | ||
| 29 | + | ||
| 23 | Row(){ | 30 | Row(){ |
| 24 | Image($r('app.media.icon_search')) | 31 | Image($r('app.media.icon_search')) |
| 25 | .width(18) | 32 | .width(18) |
| 26 | .height(18) | 33 | .height(18) |
| 34 | + | ||
| 35 | + Text('河南大雪') | ||
| 36 | + .fontColor($r('app.color.color_B0B0B0')) | ||
| 37 | + .fontSize($r('app.float.font_size_13')) | ||
| 27 | } | 38 | } |
| 28 | .alignItems(VerticalAlign.Center) | 39 | .alignItems(VerticalAlign.Center) |
| 29 | .justifyContent(FlexAlign.Center) | 40 | .justifyContent(FlexAlign.Center) |
| 41 | + | ||
| 42 | + } | ||
| 30 | .height(30) | 43 | .height(30) |
| 31 | .width(123) | 44 | .width(123) |
| 32 | - .backgroundColor($r('app.color.color_D8D8D8')) | ||
| 33 | .id('search') | 45 | .id('search') |
| 34 | .alignRules({ left: { anchor: "__container__", align: HorizontalAlign.Start }, | 46 | .alignRules({ left: { anchor: "__container__", align: HorizontalAlign.Start }, |
| 35 | center: { anchor: "__container__", align: VerticalAlign.Center } }) | 47 | center: { anchor: "__container__", align: VerticalAlign.Center } }) |
| @@ -50,19 +62,25 @@ export struct TopNavigationComponent { | @@ -50,19 +62,25 @@ export struct TopNavigationComponent { | ||
| 50 | .alignRules({ middle: { anchor: "__container__", align: HorizontalAlign.Center }, | 62 | .alignRules({ middle: { anchor: "__container__", align: HorizontalAlign.Center }, |
| 51 | center: { anchor: "__container__", align: VerticalAlign.Center } }) | 63 | center: { anchor: "__container__", align: VerticalAlign.Center } }) |
| 52 | 64 | ||
| 65 | + Stack({ alignContent: Alignment.Center }){ | ||
| 66 | + Image($r('app.media.background_read_paper_home')) | ||
| 67 | + .width('100%') | ||
| 68 | + .height('100%') | ||
| 69 | + .objectFit(ImageFit.Contain) | ||
| 53 | Row(){ | 70 | Row(){ |
| 54 | Image($r('app.media.icon_read_paper_home')) | 71 | Image($r('app.media.icon_read_paper_home')) |
| 55 | .width(18) | 72 | .width(18) |
| 56 | .height(18) | 73 | .height(18) |
| 57 | Text('早晚报') | 74 | Text('早晚报') |
| 58 | - .fontColor($r('app.color.color_fff')) | 75 | + .fontColor($r('app.color.color_B0B0B0')) |
| 59 | .fontSize($r('app.float.font_size_13')) | 76 | .fontSize($r('app.float.font_size_13')) |
| 60 | } | 77 | } |
| 61 | .alignItems(VerticalAlign.Center) | 78 | .alignItems(VerticalAlign.Center) |
| 62 | .justifyContent(FlexAlign.Center) | 79 | .justifyContent(FlexAlign.Center) |
| 80 | + | ||
| 81 | + } | ||
| 63 | .height(30) | 82 | .height(30) |
| 64 | .width(124) | 83 | .width(124) |
| 65 | - .backgroundColor($r('app.color.color_D8D8D8')) | ||
| 66 | .id('read') | 84 | .id('read') |
| 67 | .alignRules({ right: { anchor: "__container__", align: HorizontalAlign.End }, | 85 | .alignRules({ right: { anchor: "__container__", align: HorizontalAlign.End }, |
| 68 | center: { anchor: "__container__", align: VerticalAlign.Center } }) | 86 | center: { anchor: "__container__", align: VerticalAlign.Center } }) |
-
Please register or login to post a comment