Commit 147aa704 by 毛勇泽

修改tab

parent 13ac7a1f
...@@ -4,7 +4,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable' ...@@ -4,7 +4,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable'
@Entry @Entry
@Component @Component
struct AddConversionPage { struct AddConversionPage {
@State fontColor: string = '#182431' @State fontColor: string = '#0FA983'
@State selectedFontColor: string = '#fff' @State selectedFontColor: string = '#fff'
@State currentIndex: number = 0 @State currentIndex: number = 0
private controller: TabsController = new TabsController() private controller: TabsController = new TabsController()
...@@ -14,14 +14,12 @@ struct AddConversionPage { ...@@ -14,14 +14,12 @@ struct AddConversionPage {
Text(name) Text(name)
.fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor) .fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor)
.fontSize(21) .fontSize(21)
.lineHeight(22) .lineHeight(36)
.margin({ top: 17, bottom: 7 }) } .width('100%')
Divider() .height(45)
.strokeWidth(2) .border({ width: 2, color: 'rgb(15, 169, 131)' })
.color('#fff') .borderRadius(3)
.width(50) .backgroundColor(this.currentIndex === index ? this.fontColor : '#00000000')
.opacity(this.currentIndex === index ? 1 : 0)
}.width('100%')
} }
@Builder VoucherRow() { @Builder VoucherRow() {
...@@ -270,7 +268,7 @@ struct AddConversionPage { ...@@ -270,7 +268,7 @@ struct AddConversionPage {
this.WzInfoRow() this.WzInfoRow()
}.width("100%") }.width("100%")
}.tabBar(this.TabBuilder(1, '物资信息')) }.tabBar(this.TabBuilder(1, '物资信息'))
}.margin({left:15,right:15}) }.margin({left:15,right:15,top:15})
.onChange((index: number) => { .onChange((index: number) => {
this.currentIndex = index this.currentIndex = index
}) })
......
...@@ -12,7 +12,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable' ...@@ -12,7 +12,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable'
@Entry @Entry
@Component @Component
export struct AddTemporaryInPage { export struct AddTemporaryInPage {
@State fontColor: string = '#182431' @State fontColor: string = '#0FA983'
@State selectedFontColor: string = '#fff' @State selectedFontColor: string = '#fff'
@State currentIndex: number = 0 @State currentIndex: number = 0
private controller: TabsController = new TabsController() private controller: TabsController = new TabsController()
...@@ -21,14 +21,12 @@ export struct AddTemporaryInPage { ...@@ -21,14 +21,12 @@ export struct AddTemporaryInPage {
Text(name) Text(name)
.fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor) .fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor)
.fontSize(21) .fontSize(21)
.lineHeight(22) .lineHeight(36)
.margin({ bottom: 7 }) } .width('100%')
Divider() .height(45)
.strokeWidth(2) .border({ width: 2, color: 'rgb(15, 169, 131)' })
.color('#fff') .borderRadius(3)
.width(50) .backgroundColor(this.currentIndex === index ? this.fontColor : '#00000000')
.opacity(this.currentIndex === index ? 1 : 0)
}.width('100%')
} }
@Builder VoucherRow() { @Builder VoucherRow() {
...@@ -278,7 +276,7 @@ export struct AddTemporaryInPage { ...@@ -278,7 +276,7 @@ export struct AddTemporaryInPage {
}.width("100%") }.width("100%")
}.tabBar(this.TabBuilder(1, '物资信息')) }.tabBar(this.TabBuilder(1, '物资信息'))
} }
.margin({left:15,right:15}) .margin({left:15,right:15,top:15})
.onChange((index: number) => { .onChange((index: number) => {
this.currentIndex = index this.currentIndex = index
}) })
......
...@@ -12,7 +12,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable' ...@@ -12,7 +12,7 @@ import { BasicTable } from '../../view/BasicTable/BasicTable'
@Entry @Entry
@Component @Component
struct AddTemporaryOutPage{ struct AddTemporaryOutPage{
@State fontColor: string = '#182431' @State fontColor: string = '#0FA983'
@State selectedFontColor: string = '#fff' @State selectedFontColor: string = '#fff'
@State currentIndex: number = 0 @State currentIndex: number = 0
private controller: TabsController = new TabsController() private controller: TabsController = new TabsController()
...@@ -21,14 +21,12 @@ struct AddTemporaryOutPage{ ...@@ -21,14 +21,12 @@ struct AddTemporaryOutPage{
Text(name) Text(name)
.fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor) .fontColor(this.currentIndex === index ? this.selectedFontColor : this.fontColor)
.fontSize(21) .fontSize(21)
.lineHeight(22) .lineHeight(36)
.margin({bottom: 7 }) } .width('100%')
Divider() .height(45)
.strokeWidth(2) .border({ width: 2, color: 'rgb(15, 169, 131)' })
.color('#fff') .borderRadius(3)
.width(50) .backgroundColor(this.currentIndex === index ? this.fontColor : '#00000000')
.opacity(this.currentIndex === index ? 1 : 0)
}.width('100%')
} }
@Builder VoucherRow() { @Builder VoucherRow() {
...@@ -279,7 +277,7 @@ struct AddTemporaryOutPage{ ...@@ -279,7 +277,7 @@ struct AddTemporaryOutPage{
}.width("100%") }.width("100%")
}.tabBar(this.TabBuilder(1, '物资信息')) }.tabBar(this.TabBuilder(1, '物资信息'))
} }
.margin({left:15,right:15}) .margin({left:15,right:15,top:15})
.onChange((index: number) => { .onChange((index: number) => {
this.currentIndex = index this.currentIndex = index
}) })
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论